[issue40632] AttributeError: type object 'Callable' has no attribute '_abc_registry'

2020-05-15 Thread Ivan Levkivskyi


Ivan Levkivskyi  added the comment:

I think a better question is why the `typing` in site packages is ever 
imported? I thought that an stdlib module always takes precedence over an 
installed one with the same name.

--
nosy: +levkivskyi

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40632] AttributeError: type object 'Callable' has no attribute '_abc_registry'

2020-05-15 Thread Дилян Палаузов

Дилян Палаузов  added the comment:

I used python 3.6, I exported all dependencies with `pip list`, then upgraded 
to python 3.8 and imported the exported dependencies.

Uninstalling the “typing” module has helped.

Do you mean, that python 3.8 includes the “typing” modules, so that it may not 
be re-installed over pip?

Why pip does not prevent the user from installing the “typing” modules on 
python 3.8?

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40632] AttributeError: type object 'Callable' has no attribute '_abc_registry'

2020-05-15 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

You seem to use typing backport that has this issue : 
https://github.com/python/typing/issues/573

--
nosy: +xtreak

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40632] AttributeError: type object 'Callable' has no attribute '_abc_registry'

2020-05-15 Thread Дилян Палаузов

New submission from Дилян Палаузов :

I have the newest cpython 3.8 (07bd5cf3d9551ae), installed with `./configure 
--enable-loadable-sqlite-extensions --disable-ipv6 --with-system-expat 
--with-system-libmpdec --enable-shared && make && make install`.

Calling `pip-20.1 install -U meson` prints:

Collecting meson
  Using cached meson-0.54.2.tar.gz (1.7 MB)
  Installing build dependencies: started
  Installing build dependencies: finished with status 'error'
  ERROR: Command errored out with exit status 1:
   command: /usr/local/bin/python3 /usr/local/lib/python3.8/site-packages/pip 
install --ignore-installed --no-user --prefix 
/tmp/pip-build-env-to_qzg_r/overlay --no-warn-script-location --no-binary 
:none: --only-binary :none: -i https://pypi.org/simple -- setuptools wheel
   cwd: None
  Complete output (44 lines):
  Traceback (most recent call last):
File "/usr/local/lib/python3.8/runpy.py", line 194, in _run_module_as_main
  return _run_code(code, main_globals, None,
File "/usr/local/lib/python3.8/runpy.py", line 87, in _run_code
  exec(code, run_globals)
File "/usr/local/lib/python3.8/site-packages/pip/__main__.py", line 26, in 

  sys.exit(_main())
File "/usr/local/lib/python3.8/site-packages/pip/_internal/cli/main.py", 
line 73, in main
  command = create_command(cmd_name, isolated=("--isolated" in cmd_args))
File 
"/usr/local/lib/python3.8/site-packages/pip/_internal/commands/__init__.py", 
line 104, in create_command
  module = importlib.import_module(module_path)
File "/usr/local/lib/python3.8/importlib/__init__.py", line 127, in 
import_module
  return _bootstrap._gcd_import(name[level:], package, level)
File "", line 1014, in _gcd_import
File "", line 991, in _find_and_load
File "", line 975, in _find_and_load_unlocked
File "", line 671, in _load_unlocked
File "", line 783, in exec_module
File "", line 219, in _call_with_frames_removed
File 
"/usr/local/lib/python3.8/site-packages/pip/_internal/commands/install.py", 
line 24, in 
  from pip._internal.cli.req_command import RequirementCommand, with_cleanup
File 
"/usr/local/lib/python3.8/site-packages/pip/_internal/cli/req_command.py", line 
16, in 
  from pip._internal.index.package_finder import PackageFinder
File 
"/usr/local/lib/python3.8/site-packages/pip/_internal/index/package_finder.py", 
line 21, in 
  from pip._internal.index.collector import parse_links
File 
"/usr/local/lib/python3.8/site-packages/pip/_internal/index/collector.py", line 
14, in 
  from pip._vendor import html5lib, requests
File 
"/usr/local/lib/python3.8/site-packages/pip/_vendor/requests/__init__.py", line 
114, in 
  from . import utils
File 
"/usr/local/lib/python3.8/site-packages/pip/_vendor/requests/utils.py", line 
25, in 
  from . import certs
File 
"/usr/local/lib/python3.8/site-packages/pip/_vendor/requests/certs.py", line 
15, in 
  from pip._vendor.certifi import where
File 
"/usr/local/lib/python3.8/site-packages/pip/_vendor/certifi/__init__.py", line 
1, in 
  from .core import contents, where
File "/usr/local/lib/python3.8/site-packages/pip/_vendor/certifi/core.py", 
line 12, in 
  from importlib.resources import read_text
File "/usr/local/lib/python3.8/importlib/resources.py", line 11, in 
  from typing import Iterable, Iterator, Optional, Set, Union   # noqa: F401
File "/usr/local/lib/python3.8/site-packages/typing.py", line 1357, in 

  class Callable(extra=collections_abc.Callable, metaclass=CallableMeta):
File "/usr/local/lib/python3.8/site-packages/typing.py", line 1005, in 
__new__
  self._abc_registry = extra._abc_registry
  AttributeError: type object 'Callable' has no attribute '_abc_registry'
  
ERROR: Command errored out with exit status 1: /usr/local/bin/python3 
/usr/local/lib/python3.8/site-packages/pip install --ignore-installed --no-user 
--prefix /tmp/pip-build-env-to_qzg_r/overlay --no-warn-script-location 
--no-binary :none: --only-binary :none: -i https://pypi.org/simple -- 
setuptools wheel Check the logs for full command output.

--
components: Installation
messages: 368941
nosy: dilyan.palauzov
priority: normal
severity: normal
status: open
title: AttributeError: type object 'Callable' has no attribute '_abc_registry'
type: behavior
versions: Python 3.8

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com