starlightknown / Cyberon

Cyberon- a discord bot for hackathon servers made by using discord.py
https://starlightknown.github.io/Cyberon/#/
MIT License
19 stars 12 forks source link

Re write #76

Closed starlightknown closed 3 years ago

starlightknown commented 3 years ago

closes #ISSUE-NO

What does this PR do?

Some Description of Task to be completed?

How can this be manually tested?

Any background context you want to provide?

What is the relevant issue link?

Screenshots (if appropriate here)

Any Questions you have:

sourcery-ai[bot] commented 3 years ago

Sourcery Code Quality Report

❌  Merging this PR will decrease code quality in the affected files by 12.45%.

Quality metrics Before After Change
Complexity 3.49 ⭐ 9.56 🙂 6.07 👎
Method Length 58.29 ⭐ 97.38 🙂 39.09 👎
Working memory 9.62 🙂 10.87 😞 1.25 👎
Quality 69.02% 🙂 56.57% 🙂 -12.45% 👎
Other metrics Before After Change
Lines 1066 266 -800
Changed files Quality Before Quality After Quality Change
bot.py 67.72% 🙂 56.57% 🙂 -11.15% 👎

Here are some functions in these files that still need a tune-up:

File Function Complexity Length Working Memory Quality Recommendation
bot.py on_message 19 😞 346 ⛔ 15 😞 26.92% 😞 Refactor to reduce nesting. Try splitting into smaller methods. Extract out complex expressions
bot.py on_message_edit 10 🙂 108 🙂 24 ⛔ 44.05% 😞 Extract out complex expressions
bot.py on_member_remove 11 🙂 150 😞 11 😞 50.41% 🙂 Try splitting into smaller methods. Extract out complex expressions
bot.py on_member_join 9 🙂 141 😞 11 😞 53.21% 🙂 Try splitting into smaller methods. Extract out complex expressions
bot.py on_message_delete 3 ⭐ 77 🙂 14 😞 62.69% 🙂 Extract out complex expressions

Legend and Explanation

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!