Closed Acnologla closed 2 years ago
PR title does not match the new requirements: https://github.com/andersfylling/disgord/blob/master/CONTRIBUTING.md#pr-title
Minor changes in addition to the resource design and update methods. Really nice contribution though, needed this for a long time.
Also, I switched to the master branch now. So please adjust the PR towards master. (right under the title). Might have to do a fast forward merge, but shouldn't be any serious conflicts.
Hey, I thought a bit about the httd.Method* consts and figured they're a bit silly. I removed them here: https://github.com/andersfylling/disgord/pull/430
so please use http.Method* instead :+1:
You see the WithContext method at the end? you need one as well for WithFlags.
Then you remove the flags parameters from the rest endpoints
Why are the tests failing? the function receives a []Flag not a Flag
It's a single Flag not a slice. It's a binary flag essentially, so in your WithFlags method you should do
c.flags = mergeFlags(flags)
and update the struct definition to only hold flags Flag
.
I wondwr if your code is perhaps a little outdated? Or i forgot to adjust a func signature.
I remember i removed those flag slices a while back.
On Thu, 26 Aug 2021, 18:44 Acnologla, @.***> wrote:
Why are the tests failing? the function receives a []Flag not a Flag
[image: image] https://user-images.githubusercontent.com/35548489/131002525-46112e88-f4c6-4e25-81a5-cbaf438a9221.png
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/andersfylling/disgord/pull/429#issuecomment-906572584, or unsubscribe https://github.com/notifications/unsubscribe-auth/AB346VBXIGPRXHMRSGPJ44DT6ZVPLANCNFSM5CTFKVNA . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&utm_campaign=notification-email .
i think it's all right now
I wondwr if your code is perhaps a little outdated? Or i forgot to adjust a func signature. I remember i removed those flag slices a while back. … On Thu, 26 Aug 2021, 18:44 Acnologla, @.***> wrote: Why are the tests failing? the function receives a []Flag not a Flag [image: image] https://user-images.githubusercontent.com/35548489/131002525-46112e88-f4c6-4e25-81a5-cbaf438a9221.png — You are receiving this because you commented. Reply to this email directly, view it on GitHub <#429 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/AB346VBXIGPRXHMRSGPJ44DT6ZVPLANCNFSM5CTFKVNA . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&utm_campaign=notification-email .
The PR is based on the develop branch, I believe develop is not up to date with master
I wondwr if your code is perhaps a little outdated? Or i forgot to adjust a func signature. I remember i removed those flag slices a while back. …
The PR is based on the develop branch, I believe develop is not up to date with master
This is true. I'm eventually removing the develop branch. Master is now main branch of this repository.
This is just a decision that was done when I started trying to make this project more predictable / simpler.
Hope this helps: https://github.com/andersfylling/disgord/commit/d0894f42da544f0f1e661d9075da7e836081be82
Merging #429 (d0894f4) into master (931a8b4) will decrease coverage by
0.64%
. The diff coverage isn/a
.:exclamation: Current head d0894f4 differs from pull request most recent head 96522c7. Consider uploading reports for the commit 96522c7 to get more accurate results
@@ Coverage Diff @@
## master #429 +/- ##
==========================================
- Coverage 39.06% 38.42% -0.65%
==========================================
Files 54 56 +2
Lines 6236 6317 +81
==========================================
- Hits 2436 2427 -9
- Misses 3536 3625 +89
- Partials 264 265 +1
Flag | Coverage Δ | |
---|---|---|
integration | 29.98% <ø> (-0.90%) |
:arrow_down: |
unit | 30.33% <ø> (-0.30%) |
:arrow_down: |
Flags with carried forward coverage won't be shown. Click here to find out more.
Impacted Files | Coverage Δ | |
---|---|---|
member.go | 21.51% <0.00%> (-2.88%) |
:arrow_down: |
user.go | 26.38% <0.00%> (-2.62%) |
:arrow_down: |
rest.go | 29.94% <0.00%> (-0.45%) |
:arrow_down: |
guild.go | 18.80% <0.00%> (-0.38%) |
:arrow_down: |
emoji.go | 0.00% <0.00%> (ø) |
|
invite.go | 0.00% <0.00%> (ø) |
|
struct.go | 32.07% <0.00%> (ø) |
|
gateway.go | 41.32% <0.00%> (ø) |
|
webhook.go | 0.00% <0.00%> (ø) |
|
reaction.go | 0.00% <0.00%> (ø) |
|
... and 8 more |
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 931a8b4...96522c7. Read the comment docs.
@Acnologla you have to run "go generate" to get the code to compile.
nice! the CI here should show you what the remaining issue is.
Description
This pull request adds discord application commands structures and functions.
Example:
Breaking Change?
no
Benchmarks
Checklist: