gpt4 book ai didi

python - 运行时警告 - Greenlet.greenlet 大小已更改?

转载 作者:行者123 更新时间:2023-12-03 17:06:36 27 4
gpt4 key购买 nike

我正在运行一个可以在这里找到的模块:https://github.com/danieliu/play-scraper

我在python文件中的代码如下:

导入 play_scraper

print(play_scraper.collection(
collection='TOP_FREE',
category='COMMUNICATION',
results=5,
page=1))

我不太关注终端中的错误消息,我不确定如何或在哪里搜索以继续前进。
File "app-store-scraper.py", line 1, in <module>
import play_scraper
ImportError: No module named play_scraper
Sams-MacBook-Air-2:cm-leadgen samframpton$ python3 app-store-scraper.py
/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/importlib/_bootstrap.py:219: RuntimeWarning: greenlet.greenlet size changed, may indicate binary incompatibility. Expected 144, got 128
return f(*args, **kwds)
/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/importlib/_bootstrap.py:219: RuntimeWarning: greenlet.greenlet size changed, may indicate binary incompatibility. Expected 144, got 128
return f(*args, **kwds)
/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/importlib/_bootstrap.py:219: RuntimeWarning: greenlet.greenlet size changed, may indicate binary incompatibility. Expected 144, got 128
return f(*args, **kwds)
/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/importlib/_bootstrap.py:219: RuntimeWarning: greenlet.greenlet size changed, may indicate binary incompatibility. Expected 144, got 128
return f(*args, **kwds)
/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/importlib/_bootstrap.py:219: RuntimeWarning: greenlet.greenlet size changed, may indicate binary incompatibility. Expected 144, got 128
return f(*args, **kwds)
/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/importlib/_bootstrap.py:219: RuntimeWarning: greenlet.greenlet size changed, may indicate binary incompatibility. Expected 144, got 128
return f(*args, **kwds)
/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/importlib/_bootstrap.py:219: RuntimeWarning: greenlet.greenlet size changed, may indicate binary incompatibility. Expected 144, got 128
return f(*args, **kwds)
/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/grequests.py:21: MonkeyPatchWarning: Monkey-patching ssl after ssl has already been imported may lead to errors, including RecursionError on Python 3.6. It may also silently lead to incorrect behaviour on Python 3.7. Please monkey-patch earlier. See https://github.com/gevent/gevent/issues/1016. Modules that had direct imports (NOT patched): ['urllib3.util (/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/urllib3/util/__init__.py)', 'urllib3.contrib.pyopenssl (/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/urllib3/contrib/pyopenssl.py)'].
curious_george.patch_all(thread=False, select=False)
Traceback (most recent call last):
File "app-store-scraper.py", line 7, in <module>
page=1))
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/play_scraper/api.py", line 41, in collection
return s.collection(collection, category, **kwargs)
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/play_scraper/scraper.py", line 394, in collection
response = send_request('POST', url, data, params)
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/play_scraper/utils.py", line 124, in send_request
allow_redirects=allow_redirects)
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/requests/api.py", line 58, in request
return session.request(method=method, url=url, **kwargs)
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/requests/sessions.py", line 503, in request
prep.url, proxies, stream, verify, cert
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/requests/sessions.py", line 676, in merge_environment_settings
env_proxies = get_environ_proxies(url, no_proxy=no_proxy)
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/requests/utils.py", line 760, in get_environ_proxies
if should_bypass_proxies(url, no_proxy=no_proxy):
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/requests/utils.py", line 744, in should_bypass_proxies
bypass = proxy_bypass(parsed.hostname)
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/urllib/request.py", line 2610, in proxy_bypass
return proxy_bypass_macosx_sysconf(host)
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/urllib/request.py", line 2587, in proxy_bypass_macosx_sysconf
return _proxy_bypass_macosx_sysconf(host, proxy_settings)
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/urllib/request.py", line 2560, in _proxy_bypass_macosx_sysconf
hostIP = socket.gethostbyname(hostonly)
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/gevent/_socketcommon.py", line 163, in gethostbyname
return get_hub().resolver.gethostbyname(hostname)
File "src/gevent/_hub_local.py", line 73, in gevent.__hub_local.get_hub_noargs
File "src/gevent/_hub_local.py", line 80, in gevent.__hub_local.get_hub_noargs
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/gevent/hub.py", line 390, in __init__
WaitOperationsGreenlet.__init__(self, None, None)
File "src/gevent/_greenlet_primitives.py", line 42, in gevent.__greenlet_primitives.TrackedRawGreenlet.__init__
SystemError: /Users/sysadmin/build/v3.7.0/Objects/dictobject.c:1439: bad argument to internal function
Sams-MacBook-Air-2:cm-leadgen samframpton$

任何帮助将不胜感激。

最佳答案

对于那些收到以下错误消息的人。
您可能会遇到由 gevent 和 greenlet 的库更新引起的问题。

RuntimeWarning: greenlet.greenlet size changed, may indicate binary incompatibility. Expected 144, got 128
return f(*args, **kwds)
请参阅下文了解更多详细信息。
https://github.com/gevent/gevent/issues/1260
greenlet gevent gunicorn 之间报告的兼容版本是(为我工作)
gunicorn==19.9.0
gevent==1.3.4
greenlet==0.4.13
下面还有其他报告也可能有效(我尚未对此进行测试)。
gevent==20.9.0
greenlet==0.4.17

关于python - 运行时警告 - Greenlet.greenlet 大小已更改?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/51496550/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com