Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

请问可以推出腾讯云函数版本或如何部署到腾讯云函数 #13

Open
DeepFal opened this issue Sep 4, 2021 · 6 comments
Open

Comments

@DeepFal
Copy link

DeepFal commented Sep 4, 2021

如题 github的服务器经常Network is unreachable 导致打卡失败

@DeepFal
Copy link
Author

DeepFal commented Sep 4, 2021

##groupRun python MoGuDing.py
36;1mpython MoGuDing.py�0m
shell: /usr/bin/bash -e 0
env:
pythonLocation: /opt/hostedtoolcache/Python/3.9.6/x64
LD_LIBRARY_PATH: /opt/hostedtoolcache/Python/3.9.6/x64/lib
PERSONAL_INFORMATION: ***
SERVERPUSHKEY: ***
TG_BOT_TOKEN:
TG_USER_ID:
BARK:
PUSHPLUS:
ACCESSTOKEN:
CORPID:
CORPSECRET:
TOUSER:
AGENTID:
THUMB_MEDIA_ID:
AUTHOR:
##endgroup
欢迎使用MoGuDing-Auto!
Traceback (most recent call last):
File "/opt/hostedtoolcache/Python/3.9.6/x64/lib/python3.9/site-packages/urllib3/connection.py", line 169, in _new_conn
conn = connection.create_connection(
File "/opt/hostedtoolcache/Python/3.9.6/x64/lib/python3.9/site-packages/urllib3/util/connection.py", line 96, in create_connection
raise err
File "/opt/hostedtoolcache/Python/3.9.6/x64/lib/python3.9/site-packages/urllib3/util/connection.py", line 86, in create_connection
sock.connect(sa)
OSError: Errno 101 Network is unreachable

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/opt/hostedtoolcache/Python/3.9.6/x64/lib/python3.9/site-packages/urllib3/connectionpool.py", line 699, in urlopen
httplib_response = self._make_request(
File "/opt/hostedtoolcache/Python/3.9.6/x64/lib/python3.9/site-packages/urllib3/connectionpool.py", line 382, in _make_request
self._validate_conn(conn)
File "/opt/hostedtoolcache/Python/3.9.6/x64/lib/python3.9/site-packages/urllib3/connectionpool.py", line 1010, in _validate_conn
conn.connect()
File "/opt/hostedtoolcache/Python/3.9.6/x64/lib/python3.9/site-packages/urllib3/connection.py", line 353, in connect
conn = self._new_conn()
File "/opt/hostedtoolcache/Python/3.9.6/x64/lib/python3.9/site-packages/urllib3/connection.py", line 181, in _new_conn
raise NewConnectionError(
urllib3.exceptions.NewConnectionError: <urllib3.connection.HTTPSConnection object at 0x7f4e9ddd4370>: Failed to establish a new connection: Errno 101 Network is unreachable

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/opt/hostedtoolcache/Python/3.9.6/x64/lib/python3.9/site-packages/requests/adapters.py", line 439, in send
resp = conn.urlopen(
File "/opt/hostedtoolcache/Python/3.9.6/x64/lib/python3.9/site-packages/urllib3/connectionpool.py", line 755, in urlopen
retries = retries.increment(
File "/opt/hostedtoolcache/Python/3.9.6/x64/lib/python3.9/site-packages/urllib3/util/retry.py", line 574, in increment
raise MaxRetryError(_pool, url, error or ResponseError(cause))
urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='api.moguding.net', port=9000): Max retries exceeded with url: /usercenter/user/v1/info (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7f4e9ddd4370>: Failed to establish a new connection: Errno 101 Network is unreachable'))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/home/runner/work/MoGuDing-Auto/MoGuDing-Auto/MoGuDing.py", line 308, in
main()
File "/home/runner/work/MoGuDing-Auto/MoGuDing-Auto/MoGuDing.py", line 279, in main
getPlanByStu()
File "/home/runner/work/MoGuDing-Auto/MoGuDing-Auto/MoGuDing.py", line 114, in getPlanByStu
getUserInfo()
File "/home/runner/work/MoGuDing-Auto/MoGuDing-Auto/MoGuDing.py", line 79, in getUserInfo
response = requests.post(url=url, headers=GlobalVariable.headers, data=json.dumps(requestsBody), verify=False)
File "/opt/hostedtoolcache/Python/3.9.6/x64/lib/python3.9/site-packages/requests/api.py", line 117, in post
return request('post', url, data=data, json=json, **kwargs)
File "/opt/hostedtoolcache/Python/3.9.6/x64/lib/python3.9/site-packages/requests/api.py", line 61, in request
return session.request(method=method, url=url, **kwargs)
File "/opt/hostedtoolcache/Python/3.9.6/x64/lib/python3.9/site-packages/requests/sessions.py", line 542, in request
resp = self.send(prep, **send_kwargs)
File "/opt/hostedtoolcache/Python/3.9.6/x64/lib/python3.9/site-packages/requests/sessions.py", line 655, in send
r = adapter.send(request, **kwargs)
File "/opt/hostedtoolcache/Python/3.9.6/x64/lib/python3.9/site-packages/requests/adapters.py", line 516, in send
raise ConnectionError(e, request=request)
requests.exceptions.ConnectionError: HTTPSConnectionPool(host='api.moguding.net', port=9000): Max retries exceeded with url: /usercenter/user/v1/info (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7f4e9ddd4370>: Failed to establish a new connection: Errno 101 Network is unreachable'))
##errorProcess completed with exit code 1.

@leifengwl
Copy link
Owner

将文件打包下载,在云函数那边设置好变量和python3环境

@DeepFal
Copy link
Author

DeepFal commented Sep 7, 2021

将文件打包下载,在云函数那边设置好变量和python3环境

请问有没有具体的方法呀,执行方法怎么填qwq

@DeepFal
Copy link
Author

DeepFal commented Sep 8, 2021

将文件打包下载,在云函数那边设置好变量和python3环境
{"errorCode":-1,"errorMessage":"user code exception caught","requestId":"f5e6eedf-7237-4a36-b69c-ee78279c5ffc","stackTrace":"Traceback (most recent call last):\nTypeError: main() takes 0 positional arguments but 2 were given","statusCode":430}

@leifengwl
Copy link
Owner

没配置好,有时间我再发教程吧,周末可能有空

@zjusername
Copy link

没配置好,有时间我再发教程吧,周末可能有空

这周周末吗,我这里GitHub一直打卡失败

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants