Closed sourcery-ai[bot] closed 2 years ago
✅ Merging this PR will increase code quality in the affected files by 0.34%.
Quality metrics | Before | After | Change |
---|---|---|---|
Complexity | 8.33 ⭐ | 8.05 ⭐ | -0.28 👍 |
Method Length | 76.76 🙂 | 76.08 🙂 | -0.68 👍 |
Working memory | 10.12 😞 | 10.05 😞 | -0.07 👍 |
Quality | 61.49% 🙂 | 61.83% 🙂 | 0.34% 👍 |
Other metrics | Before | After | Change |
---|---|---|---|
Lines | 6327 | 6092 | -235 |
Changed files | Quality Before | Quality After | Quality Change |
---|---|---|---|
api_hax.py | 67.69% 🙂 | 68.71% 🙂 | 1.02% 👍 |
api_leetcode.py | 74.37% 🙂 | 74.06% 🙂 | -0.31% 👎 |
api_motto.py | 84.12% ⭐ | 89.76% ⭐ | 5.64% 👍 |
api_news.py | 52.90% 🙂 | 55.37% 🙂 | 2.47% 👍 |
api_ran_time.py | 82.08% ⭐ | 83.77% ⭐ | 1.69% 👍 |
api_rssbot.py | 35.29% 😞 | 35.37% 😞 | 0.08% 👍 |
api_weather.py | 44.07% 😞 | 44.78% 😞 | 0.71% 👍 |
ck_acfun.py | 72.05% 🙂 | 72.83% 🙂 | 0.78% 👍 |
ck_airport.py | 50.16% 🙂 | 52.17% 🙂 | 2.01% 👍 |
ck_baidu_url_submit.py | 70.64% 🙂 | 72.10% 🙂 | 1.46% 👍 |
ck_bilibili.py | 48.38% 😞 | 46.71% 😞 | -1.67% 👎 |
ck_ccava.py | 87.59% ⭐ | 88.30% ⭐ | 0.71% 👍 |
ck_cloud189.py | 57.38% 🙂 | 57.30% 🙂 | -0.08% 👎 |
ck_csdn.py | 76.03% ⭐ | 77.22% ⭐ | 1.19% 👍 |
ck_duokan.py | 66.44% 🙂 | 66.68% 🙂 | 0.24% 👍 |
ck_enshan.py | 85.03% ⭐ | 85.15% ⭐ | 0.12% 👍 |
ck_euserv.py | 48.47% 😞 | 50.40% 🙂 | 1.93% 👍 |
ck_everphoto.py | 72.25% 🙂 | 73.81% 🙂 | 1.56% 👍 |
ck_fmapp.py | 71.77% 🙂 | 71.94% 🙂 | 0.17% 👍 |
ck_freenom.py | 56.53% 🙂 | 56.60% 🙂 | 0.07% 👍 |
ck_game163.py | 90.09% ⭐ | 90.93% ⭐ | 0.84% 👍 |
ck_glados.py | 68.69% 🙂 | 68.76% 🙂 | 0.07% 👍 |
ck_haidilao.py | 65.36% 🙂 | 65.19% 🙂 | -0.17% 👎 |
ck_heytap.py | 41.51% 😞 | 41.56% 😞 | 0.05% 👍 |
ck_hifini.py | 82.80% ⭐ | 82.95% ⭐ | 0.15% 👍 |
ck_hlx.py | 73.92% 🙂 | 74.34% 🙂 | 0.42% 👍 |
ck_hostloc.py | 77.12% ⭐ | 77.27% ⭐ | 0.15% 👍 |
ck_jegotrip.py | 71.93% 🙂 | 73.19% 🙂 | 1.26% 👍 |
ck_juejin.py | 84.42% ⭐ | 84.89% ⭐ | 0.47% 👍 |
ck_kgqq.py | 39.77% 😞 | 39.77% 😞 | 0.00% |
ck_meizu.py | 62.35% 🙂 | 62.09% 🙂 | -0.26% 👎 |
ck_mimotion.py | 62.00% 🙂 | 61.34% 🙂 | -0.66% 👎 |
ck_music163.py | 63.60% 🙂 | 66.45% 🙂 | 2.85% 👍 |
ck_nga.py | 61.70% 🙂 | 61.99% 🙂 | 0.29% 👍 |
ck_oneplusbbs.py | 64.61% 🙂 | 64.58% 🙂 | -0.03% 👎 |
ck_picacomic.py | 70.09% 🙂 | 71.87% 🙂 | 1.78% 👍 |
ck_pojie.py | 82.90% ⭐ | 82.77% ⭐ | -0.13% 👎 |
ck_sfacg.py | 67.75% 🙂 | 67.76% 🙂 | 0.01% 👍 |
ck_site.py | 41.39% 😞 | 41.64% 😞 | 0.25% 👍 |
ck_tieba.py | 69.93% 🙂 | 70.49% 🙂 | 0.56% 👍 |
ck_toolu.py | 87.18% ⭐ | 88.15% ⭐ | 0.97% 👍 |
ck_v2ex.py | 59.50% 🙂 | 59.47% 🙂 | -0.03% 👎 |
ck_weibo.py | 69.91% 🙂 | 71.21% 🙂 | 1.30% 👍 |
ck_wps.py | 64.18% 🙂 | 64.22% 🙂 | 0.04% 👍 |
ck_www2nzz.py | 71.23% 🙂 | 74.64% 🙂 | 3.41% 👍 |
ck_wzyd.py | 81.02% ⭐ | 80.36% ⭐ | -0.66% 👎 |
ck_youdao.py | 62.07% 🙂 | 62.47% 🙂 | 0.40% 👍 |
ck_zhiyoo.py | 71.52% 🙂 | 74.92% 🙂 | 3.40% 👍 |
utils_env.py | 69.80% 🙂 | 68.51% 🙂 | -1.29% 👎 |
Here are some functions in these files that still need a tune-up:
File | Function | Complexity | Length | Working Memory | Quality | Recommendation |
---|---|---|---|---|---|---|
ck_bilibili.py | BiliBili.main | 57 ⛔ | 604 ⛔ | 27 ⛔ | 3.69% ⛔ | Refactor to reduce nesting. Try splitting into smaller methods. Extract out complex expressions |
ck_heytap.py | Heytap.do_task_and_draw | 49 ⛔ | 435 ⛔ | 23 ⛔ | 6.90% ⛔ | Refactor to reduce nesting. Try splitting into smaller methods. Extract out complex expressions |
ck_site.py | Site.signin | 37 ⛔ | 597 ⛔ | 18 ⛔ | 12.26% ⛔ | Refactor to reduce nesting. Try splitting into smaller methods. Extract out complex expressions |
ck_heytap.py | Heytap.daily_viewgoods | 36 ⛔ | 253 ⛔ | 16 ⛔ | 19.69% ⛔ | Refactor to reduce nesting. Try splitting into smaller methods. Extract out complex expressions |
ck_heytap.py | Heytap.daily_bonus | 30 😞 | 272 ⛔ | 17 ⛔ | 20.40% ⛔ | Refactor to reduce nesting. Try splitting into smaller methods. Extract out complex expressions |
The emojis denote the absolute quality of the code:
The 👍 and 👎 indicate whether the quality has improved or gotten worse with this pull request.
Please see our documentation here for details on how these metrics are calculated.
We are actively working on this report - lots more documentation and extra metrics to come!
Help us improve this quality report!
Branch
master
refactored by Sourcery.If you're happy with these changes, merge this Pull Request using the Squash and merge strategy.
See our documentation here.
Run Sourcery locally
Reduce the feedback loop during development by using the Sourcery editor plugin:
Review changes via command line
To manually merge these changes, make sure you're on the
master
branch, then run:Help us improve this pull request!