Closed schenxia closed 1 year ago
这个大概率是 strava 那边识别的问题
好的,我看了一下stravalib里面的client.upload_activity https://github.com/stravalib/stravalib/blob/main/src/stravalib/client.py#L841 然后试着在我的fork里面把这一行变成 https://github.com/yihong0618/running_page/blob/59ff75a7f09189273c42cac0c863217965ca94d1/scripts/utils.py#L96
r = client.upload_activity(activity_file=f, data_type=data_type, activity_type="run")
然后在CI里面得到了这个error msg
black . --check
shell: /usr/bin/bash -e {0}
env:
pythonLocation: /opt/hostedtoolcache/Python/[3](https://github.com/schenxia/running_page/actions/runs/6226943652/job/16900530082#step:7:3).8.18/x6[4](https://github.com/schenxia/running_page/actions/runs/6226943652/job/16900530082#step:7:4)
LD_LIBRARY_PATH: /opt/hostedtoolcache/Python/3.8.18/x[6](https://github.com/schenxia/running_page/actions/runs/6226943652/job/16900530082#step:7:6)4/lib
would reformat /home/runner/work/running_page/running_page/scripts/utils.py
Oh no! 💥 💔 💥
1 file would be reformatted, 33 files would be left unchanged.
Error: Process completed with exit code 1.
能麻烦您帮我看一下是什么问题吗?多谢了!
black . 然后 add commit push
多谢,加了activity_type="run"之后问题解决了
我们看看怎么在代码里支持
最近一两周才出现的新问题,每个跑步记录在strava都变成了workout类型,名字也从Morning Run 变成了Morning Workout