installed:
mingw-w64-x86_64-python-pip 21.0.1-2
mingw-w64-x86_64-python 3.8.8-2
environment variable:
PATH=/mingw64/bin:/usr/bin:/mingw64/lib/python3.8/lib-dynload:/usr/bin/site_perl:/usr/bin/vendor_perl:/usr/bin/core_perl
$ pip --version
Traceback (most recent call last):
File "C:\bin\msys64\mingw64\bin\pip-script.py", line 33, in <module>
sys.exit(load_entry_point('pip==21.0.1', 'console_scripts', 'pip')())
File "C:\bin\msys64\mingw64\bin\pip-script.py", line 25, in importlib_load_entry_point
return next(matches).load()
File "C:/bin/msys64/mingw64/lib/python3.8/importlib/metadata.py", line 77, in load
module = import_module(match.group('module'))
File "C:/bin/msys64/mingw64/lib/python3.8/importlib/__init__.py", line 127, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 1014, in _gcd_import
File "<frozen importlib._bootstrap>", line 991, in _find_and_load
File "<frozen importlib._bootstrap>", line 975, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 671, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 783, in exec_module
File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
File "C:/bin/msys64/mingw64/lib/python3.8/site-packages/pip/_internal/cli/main.py", line 8, in <module>
from pip._internal.cli.autocompletion import autocomplete
File "C:/bin/msys64/mingw64/lib/python3.8/site-packages/pip/_internal/cli/autocompletion.py", line 9, in <module>
from pip._internal.cli.main_parser import create_main_parser
File "C:/bin/msys64/mingw64/lib/python3.8/site-packages/pip/_internal/cli/main_parser.py", line 7, in <module>
from pip._internal.cli import cmdoptions
File "C:/bin/msys64/mingw64/lib/python3.8/site-packages/pip/_internal/cli/cmdoptions.py", line 22, in <module>
from pip._internal.cli.progress_bars import BAR_TYPES
File "C:/bin/msys64/mingw64/lib/python3.8/site-packages/pip/_internal/cli/progress_bars.py", line 9, in <module>
from pip._internal.utils.logging import get_indentation
File "C:/bin/msys64/mingw64/lib/python3.8/site-packages/pip/_internal/utils/logging.py", line 14, in <module>
from pip._internal.utils.misc import ensure_dir
File "C:/bin/msys64/mingw64/lib/python3.8/site-packages/pip/_internal/utils/misc.py", line 20, in <module>
from pip._vendor import pkg_resources
File "C:/bin/msys64/mingw64/lib/python3.8/site-packages/pip/_vendor/pkg_resources/__init__.py", line 35, in <module>
import plistlib
File "C:/bin/msys64/mingw64/lib/python3.8/plistlib.py", line 65, in <module>
from xml.parsers.expat import ParserCreate
File "C:/bin/msys64/mingw64/lib/python3.8/xml/parsers/expat.py", line 4, in <module>
from pyexpat import *
ImportError: DLL load failed while importing pyexpat: ▒Ҳ▒▒▒ָ▒▒▒▒ģ▒顣
[0x7FF8AD8DE0A4] ANOMALY: use of REX.w is meaningless (default operand size is 64)
[0x7FF8AD8DE0A4] ANOMALY: use of REX.w is meaningless (default operand size is 64)
please help me, big brother
Related
I am trying to deploy my Django project that uses React on the frontend inside Django app to railway. The app was deployed on Heroku before but after adding a whisper package from openAI the slug size became too big to use it there so I opted to use railway instead. I have another Django project with React running there so the problem comes from the packages.
The problem comes from package called gpt-index which uses pandas package and that's where the error occurs.
What can I do to fix this?
Nix-packs setup:
[phases.setup]
nixPkgs = ['nodejs-16_x', 'npm-8_x ', 'python310', 'postgresql', 'gcc ']
[phases.install]
cmds = ['npm i ', 'python -m venv /opt/venv && . /opt/venv/bin/activate && pip install -r requirements.txt']
[phases.build]
cmds = ['npm run build']
[start]
cmd = '. /opt/venv/bin/activate && python manage.py migrate && gunicorn backend.wsgi'
Full traceback:
Traceback (most recent call last):
File "/app/manage.py", line 22, in <module>
main()
File "/app/manage.py", line 18, in main
execute_from_command_line(sys.argv)
File "/opt/venv/lib/python3.10/site-packages/django/core/management/__init__.py", line 446, in execute_from_command_line
utility.execute()
File "/opt/venv/lib/python3.10/site-packages/django/core/management/__init__.py", line 420, in execute
django.setup()
File "/opt/venv/lib/python3.10/site-packages/django/__init__.py", line 24, in setup
apps.populate(settings.INSTALLED_APPS)
File "/opt/venv/lib/python3.10/site-packages/django/apps/registry.py", line 91, in populate
app_config = AppConfig.create(entry)
File "/opt/venv/lib/python3.10/site-packages/django/apps/config.py", line 193, in create
import_module(entry)
File "/nix/store/al6g1zbk8li6p8mcyp0h60d08jaahf8c-python3-3.10.9/lib/python3.10/importlib/__init__.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 1050, in _gcd_import
File "<frozen importlib._bootstrap>", line 1027, in _find_and_load
File "<frozen importlib._bootstrap>", line 1006, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 688, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 883, in exec_module
File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
File "/opt/venv/lib/python3.10/site-packages/gpt_index/__init__.py", line 18, in <module>
from gpt_index.indices.keyword_table import (
File "/opt/venv/lib/python3.10/site-packages/gpt_index/indices/__init__.py", line 4, in <module>
from gpt_index.indices.keyword_table.base import GPTKeywordTableIndex
File "/opt/venv/lib/python3.10/site-packages/gpt_index/indices/keyword_table/__init__.py", line 4, in <module>
from gpt_index.indices.keyword_table.base import GPTKeywordTableIndex
File "/opt/venv/lib/python3.10/site-packages/gpt_index/indices/keyword_table/base.py", line 16, in <module>
from gpt_index.indices.keyword_table.utils import extract_keywords_given_response
File "/opt/venv/lib/python3.10/site-packages/gpt_index/indices/keyword_table/utils.py", line 7, in <module>
import pandas as pd
File "/opt/venv/lib/python3.10/site-packages/pandas/__init__.py", line 48, in <module>
from pandas.core.api import (
File "/opt/venv/lib/python3.10/site-packages/pandas/core/api.py", line 47, in <module>
from pandas.core.groupby import (
File "/opt/venv/lib/python3.10/site-packages/pandas/core/groupby/__init__.py", line 1, in <module>
from pandas.core.groupby.generic import (
File "/opt/venv/lib/python3.10/site-packages/pandas/core/groupby/generic.py", line 76, in <module>
from pandas.core.frame import DataFrame
File "/opt/venv/lib/python3.10/site-packages/pandas/core/frame.py", line 172, in <module>
from pandas.core.generic import NDFrame
File "/opt/venv/lib/python3.10/site-packages/pandas/core/generic.py", line 169, in <module>
from pandas.core.window import (
File "/opt/venv/lib/python3.10/site-packages/pandas/core/window/__init__.py", line 1, in <module>
from pandas.core.window.ewm import (
File "/opt/venv/lib/python3.10/site-packages/pandas/core/window/ewm.py", line 15, in <module>
import pandas._libs.window.aggregations as window_aggregations
ImportError: libstdc++.so.6: cannot open shared object file: No such file or directory
Error in sys.excepthook:
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 72, in apport_excepthook
from apport.fileutils import likely_packaged, get_recent_crashes
File "/usr/lib/python3/dist-packages/apport/__init__.py", line 5, in <module>
from apport.report import Report
File "/usr/lib/python3/dist-packages/apport/report.py", line 32, in <module>
import apport.fileutils
File "/usr/lib/python3/dist-packages/apport/fileutils.py", line 12, in <module>
import os, glob, subprocess, os.path, time, pwd, sys, requests_unixsocket
File "/usr/lib/python3/dist-packages/requests_unixsocket/__init__.py", line 1, in <module>
import requests
File "<frozen importlib._bootstrap>", line 991, in _find_and_load
File "<frozen importlib._bootstrap>", line 975, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 655, in _load_unlocked
File "<frozen importlib._bootstrap>", line 618, in _load_backward_compatible
File "<frozen zipimport>", line 259, in load_module
File "/usr/share/python-wheels/requests-2.22.0-py2.py3-none-any.whl/requests/__init__.py", line 95, in <module>
File "<frozen importlib._bootstrap>", line 991, in _find_and_load
File "<frozen importlib._bootstrap>", line 975, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 655, in _load_unlocked
File "<frozen importlib._bootstrap>", line 618, in _load_backward_compatible
File "<frozen zipimport>", line 259, in load_module
File "/usr/share/python-wheels/urllib3-1.25.8-py2.py3-none-any.whl/urllib3/contrib/pyopenssl.py", line 46, in <module>
File "/usr/lib/python3/dist-packages/OpenSSL/__init__.py", line 8, in <module>
from OpenSSL import crypto, SSL
File "/usr/lib/python3/dist-packages/OpenSSL/crypto.py", line 1553, in <module>
class X509StoreFlags(object):
File "/usr/lib/python3/dist-packages/OpenSSL/crypto.py", line 1573, in X509StoreFlags
CB_ISSUER_CHECK = _lib.X509_V_FLAG_CB_ISSUER_CHECK
AttributeError: module 'lib' has no attribute 'X509_V_FLAG_CB_ISSUER_CHECK'
I installed snowflake-sqlalchemy package in server after that
While importing from snowflake.sqlalchemy import URL in server it throughs this error.
I am using python3.8 and pip version.22. In spark shell also while importing this URL it throws the
same error.
AttributeError: module 'lib' has no attribute 'X509_V_FLAG_CB_ISSUER_CHECK'
ubuntu version 20
I tried to install django in my vscode, but the output is like this
(my ubuntu version is 20.04),is there something wrong with my ubuntu or my python?
pipenv install djangoTraceback (most recent call last):File "/usr/bin/pipenv", line 6, in <module>from pkg_resources import load_entry_pointFile "/usr/lib/python3/dist-packages/pkg_resources/_init_.py", line 3254, in <module>def _initialize_master_working_set():File "/usr/lib/python3/dist-packages/pkg_resources/_init_.py", line 3237, in _call_asidef(*args, **kwargs)File "/usr/lib/python3/dist-packages/pkg_resources/_init_.py", line 3266, in _initialize_master_working_setworking_set = WorkingSet._build_master()File "/usr/lib/python3/dist-packages/pkg_resources/_init_.py", line 584, in _build_masterws.require(_requires_)File "/usr/lib/python3/dist-packages/pkg_resources/_init_.py", line 901, in requireneeded = self.resolve(parse_requirements(requirements))File "/usr/lib/python3/dist-packages/pkg_resources/_init_.py", line 787, in resolveraise DistributionNotFound(req, requirers)pkg_resources.DistributionNotFound: The 'pathlib' distribution was not found and is required by pipenv
I tried use this
`sudo pip install --upgrade pip`
but i got this
Traceback (most recent call last):
File "/usr/bin/pip", line 11, in <module>
load_entry_point('pip==20.0.2', 'console_scripts', 'pip')()
File "/usr/lib/python3/dist-packages/pip/_internal/cli/main.py", line 73, in main
command = create_command(cmd_name, isolated=("--isolated" in cmd_args))
File "/usr/lib/python3/dist-packages/pip/_internal/commands/__init__.py", line 96, in create_command
module = importlib.import_module(module_path)
File "/usr/lib/python3.10/importlib/__init__.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 1050, in _gcd_import
File "<frozen importlib._bootstrap>", line 1027, in _find_and_load
File "<frozen importlib._bootstrap>", line 1006, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 688, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 883, in exec_module
File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
File "/usr/lib/python3/dist-packages/pip/_internal/commands/install.py", line 24, in <module>
from pip._internal.cli.req_command import RequirementCommand
File "/usr/lib/python3/dist-packages/pip/_internal/cli/req_command.py", line 15, in <module>
from pip._internal.index.package_finder import PackageFinder
File "/usr/lib/python3/dist-packages/pip/_internal/index/package_finder.py", line 21, in <module>
from pip._internal.index.collector import parse_links
File "/usr/lib/python3/dist-packages/pip/_internal/index/collector.py", line 12, in <module>
from pip._vendor import html5lib, requests
ImportError: cannot import name 'html5lib' from 'pip._vendor' (/usr/lib/python3/dist-packages/pip/_vendor/__init__.py)
When I deploy a python3 application using Google App Engine Flex I get the following error:
File "<frozen importlib._bootstrap>", line 994, in _gcd_import
File "<frozen importlib._bootstrap>", line 971, in _find_and_load
File "<frozen importlib._bootstrap>", line 955, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 665, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 678, in exec_module
File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
File "/home/vmagent/app/run.py", line 8, in <module>
app = create_app(os.getenv('FLASK_CONFIG') or 'default')
File "/home/vmagent/app/application/__init__.py", line 43, in create_app
from .main import main as main_blueprint
File "/home/vmagent/app/application/main/__init__.py", line 5, in <module>
from . import cron_jobs, views
File "/home/vmagent/app/application/main/cron_jobs.py", line 4, in <module>
from google.cloud import datastore
File "/env/lib/python3.6/site-packages/google/cloud/datastore/__init__.py", line 60, in <module>
from google.cloud.datastore.batch import Batch
File "/env/lib/python3.6/site-packages/google/cloud/datastore/batch.py", line 24, in <module>
from google.cloud.datastore import helpers
File "/env/lib/python3.6/site-packages/google/cloud/datastore/helpers.py", line 29, in <module>
from google.cloud.datastore_v1.proto import datastore_pb2
File "/env/lib/python3.6/site-packages/google/cloud/datastore_v1/__init__.py", line 18, in <module>
from google.cloud.datastore_v1.gapic import datastore_client
File "/env/lib/python3.6/site-packages/google/cloud/datastore_v1/gapic/datastore_client.py", line 18, in <module>
import google.api_core.gapic_v1.client_info
File "/env/lib/python3.6/site-packages/google/api_core/gapic_v1/__init__.py", line 26, in <module>
from google.api_core.gapic_v1 import method_async # noqa: F401
File "/env/lib/python3.6/site-packages/google/api_core/gapic_v1/method_async.py", line 20, in <module>
from google.api_core import general_helpers, grpc_helpers_async
File "/env/lib/python3.6/site-packages/google/api_core/grpc_helpers_async.py", line 145, in <module>
class _WrappedStreamUnaryCall(_WrappedUnaryResponseMixin, _WrappedStreamRequestMixin, aio.StreamUnaryCall):
AttributeError: module 'grpc.experimental.aio' has no attribute 'StreamUnaryCall'
My requirements.txt file include the following:
google-cloud-datastore==1.12.0
grpcio==1.27.2
The reason I am using grpcio version 1.27.2 instead of the most recent 1.29.0 is because of the information shown here
Can somebody help?
I just encountered the same issue, so this may help you out. I've noticed that google-api-core is also a dependency and it was recently updated (specifically around the grpc_helpers_async), so I just pinned it to version 1.17.0 and it resolved the issue. Just add this to your requirements:
google-api-core==1.17.0
I try to use Scrapy for the first time in a Bash On Ubuntu On Windows 10 and get this error when i start a new project:
(myvenv) mothinx#DESKTOP-4M9JDPL:~/laplanetebleue$ scrapy startproject laplanetebleue
Traceback (most recent call last):
File "/home/mothinx/laplanetebleue/myvenv/bin/scrapy", line 11, in <module>
sys.exit(execute())
File "/home/mothinx/laplanetebleue/myvenv/lib/python3.5/site-packages/scrapy/cmdline.py", line 128, in execute
cmds = _get_commands_dict(settings, inproject)
File "/home/mothinx/laplanetebleue/myvenv/lib/python3.5/site-packages/scrapy/cmdline.py", line 46, in _get_commands_dict
cmds = _get_commands_from_module('scrapy.commands', inproject)
File "/home/mothinx/laplanetebleue/myvenv/lib/python3.5/site-packages/scrapy/cmdline.py", line 29, in _get_commands_from_module
for cmd in _iter_command_classes(module):
File "/home/mothinx/laplanetebleue/myvenv/lib/python3.5/site-packages/scrapy/cmdline.py", line 19, in _iter_command_classes
for module in walk_modules(module_name):
File "/home/mothinx/laplanetebleue/myvenv/lib/python3.5/site-packages/scrapy/utils/misc.py", line 71, in walk_modules
submod = import_module(fullpath)
File "/usr/lib/python3.5/importlib/__init__.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 986, in _gcd_import
File "<frozen importlib._bootstrap>", line 969, in _find_and_load
File "<frozen importlib._bootstrap>", line 958, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 673, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 665, in exec_module
File "<frozen importlib._bootstrap>", line 222, in _call_with_frames_removed
File "/home/mothinx/laplanetebleue/myvenv/lib/python3.5/site-packages/scrapy/commands/version.py", line 6, in <module>
import OpenSSL
File "/home/mothinx/laplanetebleue/myvenv/lib/python3.5/site-packages/OpenSSL/__init__.py", line 8, in <module>
from OpenSSL import crypto, SSL
File "/home/mothinx/laplanetebleue/myvenv/lib/python3.5/site-packages/OpenSSL/crypto.py", line 16, in <module>
from OpenSSL._util import (
File "/home/mothinx/laplanetebleue/myvenv/lib/python3.5/site-packages/OpenSSL/_util.py", line 6, in <module>
from cryptography.hazmat.bindings.openssl.binding import Binding
File "/home/mothinx/laplanetebleue/myvenv/lib/python3.5/site-packages/cryptography/hazmat/bindings/openssl/binding.py", line 13, in <module>
from cryptography.hazmat.bindings._openssl import ffi, lib
ImportError: /home/mothinx/laplanetebleue/myvenv/lib/python3.5/site-packages/cryptography/hazmat/bindings/_openssl.abi3.so: cannot enable executable stack as shared object requires: Invalid argument
pip freeze:
asn1crypto==0.22.0
attrs==17.2.0
Automat==0.6.0
cffi==1.11.0
constantly==15.1.0
cryptography==2.0.3
cssselect==1.0.1
hyperlink==17.3.1
idna==2.6
incremental==17.5.0
lxml==4.0.0
parsel==1.2.0
pkg-resources==0.0.0
pyasn1==0.3.5
pyasn1-modules==0.1.4
pycparser==2.18
PyDispatcher==2.0.5
pyOpenSSL==17.3.0
queuelib==1.4.2
Scrapy==1.4.0
service-identity==17.0.0
six==1.11.0
Twisted==17.5.0
w3lib==1.18.0
zope.interface==4.4.2
Is it a problem with crypto or pyOpenSSL ? Pretty new here in python, can someone decrypt me the Traceback ?