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

Implement application command permissions v2 #1183

Merged
merged 45 commits into from
May 5, 2022
Merged

Conversation

BobDotCom
Copy link
Member

@BobDotCom BobDotCom commented Mar 19, 2022

Implements the new permissions system.
Original PR: #1129

@BobDotCom BobDotCom added this to the v2.0 milestone Mar 19, 2022
@BobDotCom BobDotCom marked this pull request as draft March 19, 2022 21:19
@TurnrDev
Copy link
Contributor

Just to be clear, what will this PR bring? What are the new changes to the permissions system?

@Dorukyum
Copy link
Member

Dorukyum commented Mar 24, 2022

This allows bot devs & server managers to choose permission requirements (such as "manage messages") for commands

discord/commands/core.py Outdated Show resolved Hide resolved
discord/commands/core.py Outdated Show resolved Hide resolved
@Lulalaby Lulalaby added status: awaiting review Awaiting review from a maintainer and removed status: in progress Work in Progess labels May 5, 2022
Lulalaby
Lulalaby previously approved these changes May 5, 2022
@codecov codecov bot deleted a comment from codecov-commenter May 5, 2022
@codecov
Copy link

codecov bot commented May 5, 2022

Codecov Report

Merging #1183 (dfb9e2b) into master (217da10) will increase coverage by 0.09%.
The diff coverage is 16.66%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1183      +/-   ##
==========================================
+ Coverage   33.42%   33.52%   +0.09%     
==========================================
  Files          93       93              
  Lines       17615    17558      -57     
==========================================
- Hits         5888     5886       -2     
+ Misses      11727    11672      -55     
Flag Coverage Δ
pytest 33.52% <16.66%> (+0.09%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
discord/audit_logs.py 28.57% <ø> (ø)
discord/bot.py 18.87% <ø> (+1.37%) ⬆️
discord/commands/core.py 17.52% <0.00%> (-0.23%) ⬇️
discord/commands/permissions.py 28.57% <21.05%> (+10.38%) ⬆️
discord/enums.py 78.19% <33.33%> (-0.27%) ⬇️
discord/http.py 23.41% <40.00%> (+0.03%) ⬆️
discord/state.py 14.56% <50.00%> (+0.06%) ⬆️
discord/types/interactions.py 99.28% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 217da10...dfb9e2b. Read the comment docs.

Lulalaby
Lulalaby previously approved these changes May 5, 2022
@plun1331
Copy link
Member

plun1331 commented May 5, 2022

Pretty much done except for gateway events

@Lulalaby Lulalaby disabled auto-merge May 5, 2022 21:21
@Lulalaby Lulalaby enabled auto-merge (squash) May 5, 2022 21:21
@Lulalaby
Copy link
Member

Lulalaby commented May 5, 2022

@krittick wanna resolve mr conflicts?

@krittick
Copy link
Contributor

krittick commented May 5, 2022

@krittick wanna resolve mr conflicts?

Working on it now.

# Conflicts:
#	discord/commands/core.py
@Lulalaby Lulalaby merged commit 5fb96c5 into master May 5, 2022
krittick added a commit that referenced this pull request May 5, 2022
krittick added a commit that referenced this pull request May 5, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation needed priority: high High Priority status: awaiting review Awaiting review from a maintainer
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants