Closed shaonianche closed 9 months ago
same here.. :-(
yes we know that issue, will try to fix it these days
今天刚出现的,昨天还是好的
yes.. it was good yesterday. Many other packages also broken from some changes at Garmin
maybe need some big change, so we need to wait....
修复了,按照如下步骤实验
python run_page/garmin_sync.py ${email} ${password}
if cn python run_page/garmin_sync.py ${email} ${password} --is-cn
to get the secret_string按照我的能成功么?
按照我的能成功么?
可以了
可惜是 python 版本,ts 版本怎么修
一样啊,看懂代码其实是现在用 header 验证了 url 改了,不难修的
- python run_page/garmin_sync.py ${email} ${password} --is-cn
Get 403 error when obtain secret_string by following command.
python3 scripts/garmin_sync.py xxx@gmail.com xxx --is-cn
httpcore.ConnectError: SSL handshake is taking longer than 60.0 seconds: aborting the connection
The above exception was the direct cause of the following exception:
httpx.ConnectError: SSL handshake is taking longer than 60.0 seconds: aborting the connection
During handling of the above exception, another exception occurred:
httpx.HTTPStatusError: 403 Client Error: Forbidden for url: https://connect.garmin.cn/proxy/activitylist-service/activities/search/activities?start=0&limit=100
/opt/homebrew/lib/python3.9/site-packages/httpx/_client.py:1778: UserWarning: Unclosed <httpx.AsyncClient object at 0x1077562b0>. See https://www.python-httpx.org/async/#opening-and-closing-clients for details.
just check it work fine here, and its based on https://github.com/matin/garth you can use this to check its ssl error...please check internet, and ssl things
@yihong0618
换用了 scret 去请求 garmin 数据,当天没问题,第 2 天会有问题,怀疑是 secret 过期了?
code 这里是不是应该先获取 secret_string 再用实时获取的 secret 去请求数据呢?
@zerosrat 确实,我这里研究下。
@zerosrat 那样的话我害怕多次请求。。。。容易 ban 号,我研究下为什么 研究了一下,我觉得可以改成之前的账号密码形式。
@zerosrat 修复了,拉取最新代码就行
requirements.txt 中添加了garth 出现下面的错误
requirements.txt 中添加了garth 出现下面的错误
需要大于 3.8
python run_page/garmin_sync.py ${{ secrets.GARMIN_SECRET_STRING_CN }} --only-run --is-cn
secrets.GARMIN_SECRET_STRING_CN 这个是要在secret中自己定义吗? 格式是什么呢? “佳明的用户名 密码” 吗?
secrets.GARMIN_SECRET_STRING_CN 这个是要在secret中自己定义吗? 格式是什么呢?
是需要自己定义的,这是个使用用戶名密码获取的字符串。步骤参见下文: https://github.com/yihong0618/running_page/issues/504#issuecomment-1735815795
本地获取secret的时候报错,麻烦看下
PS C:\Users\limia\Downloads\running_page-master\run_page> python get_garmin_secret.py ${XXXX@hotmail.com} ${XXXX} --is-cn Traceback (most recent call last): File "C:\Users\limia\AppData\Local\Programs\Python\Python310\lib\site-packages\garth\http.py", line 127, in request self.last_resp.raise_for_status() File "C:\Users\limia\AppData\Local\Programs\Python\Python310\lib\site-packages\requests\models.py", line 960, in raise_for_status raise HTTPError(http_error_msg, response=self) requests.exceptions.HTTPError: 401 Client Error: Unauthorized for url: https://sso.garmin.cn/sso/signin?id=gauth-widget&embedWidget=true&gauthHost=https%3A%2F%2Fsso.garmin.cn%2Fsso%2Fembed&service=https%3A%2F%2Fsso.garmin.cn%2Fsso%2Fembed&source=https%3A%2F%2Fsso.garmin.cn%2Fsso%2Fembed&redirectAfterAccountLoginUrl=https%3A%2F%2Fsso.garmin.cn%2Fsso%2Fembed&redirectAfterAccountCreationUrl=https%3A%2F%2Fsso.garmin.cn%2Fsso%2Fembed
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\Users\limia\Downloads\running_page-master\run_page\get_garmin_secret.py", line 18, in
secrets.GARMIN_SECRET_STRING_CN 这个是要在secret中自己定义吗? 格式是什么呢?
是需要自己定义的,这是个使用用戶名密码获取的字符串。步骤参见下文: #504 (comment)
成功了,谢谢
本地获取secret的时候报错,麻烦看下
@outcastveron 检查一下您的用戶名密码是否正确,运行脚本的时候可以用引号包含一下用戶名密码 python get_garmin_secret.py "用戶名" "密码" --is-cn
@shaonianche 感谢回复,已经解决!