forked from discord-net/Discord.Net
-
Notifications
You must be signed in to change notification settings - Fork 0
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
01 #1
Merged
Merged
01 #1
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
If the current reset time is in the past, then somebody else in the current bucket must have made a request before we were able to. To prevent accidental ratelimits, we fall-back to the second sleep branch, as if the reset time wasn't specified at all. Additionally Extracts the minimum sleep time to a constant, and also bumps it to 750ms.
* Added PublishAsync to Messages. * Added missing implementation. * 1. Aligned with naming standards 2. Clarified xml docs 3. Properly threw exceptions instead of failing silently. * Additional documentation included. * Removed un-needed comments. Co-authored-by: Matt Smith <v-matsm@microsoft.com>
* Updating webhook regex for discord.com Updates webhook URL regex matching for discordapp.com and discord.com * Fixing comment * Whitespace
* Add GetUsersAsync to SocketGuild * Fix IGuild return * Do not download unless needed
* Check Dictionary Check Dictionary instead of creating a new IReadOnlyCollection and looping in it * Add Remark to MutualGuilds
## Summary If PartyId isn't present, Discord.Net will throw an InvalidOperationException and not raise `MessageReceived`. Got this a few times with my bot, stacktrace: ``` System.InvalidOperationException: This property has no value set. at Discord.Optional`1.get_Value() in ...\Discord.Net\src\Discord.Net.Core\Utils\Optional.cs:line 20 at Discord.WebSocket.SocketMessage.Update(ClientState state, Message model) in ...\Discord.Net\src\Discord.Net.WebSocket\Entities\Messages\SocketMessage.cs:line 157 at Discord.WebSocket.SocketUserMessage.Update(ClientState state, Message model) in ...\Discord.Net\src\Discord.Net.WebSocket\Entities\Messages\SocketUserMessage.cs:line 58 at Discord.WebSocket.SocketUserMessage.Create(DiscordSocketClient discord, ClientState state, SocketUser author, ISocketMessageChannel channel, Message model) in ...\Discord.Net\src\Discord.Net.WebSocket\Entities\Messages\SocketUserMessage.cs:line 53 at Discord.WebSocket.DiscordSocketClient.ProcessMessageAsync(GatewayOpCode opCode, Nullable`1 seq, String type, Object payload) in ...\Discord.Net\src\Discord.Net.WebSocket\DiscordSocketClient.cs:line 1210 ``` After looking all properties, this is the only one that could be blamed and was already fixed for `RestMessage`s, see #1337 ## Changes - `Value` to `GetValueOrDefault()` for `PartyId`
…moteAsync (#1544) * Add event and method * Simplify convert to IEmote
The GuildHelper.CreateRoleAsync() was sending 2 requests to create a role. One to create the role, and one to modify the role that was created. This can be done in one request. So i have moved it to a single request to lower the amount of requests send to the api. This will also solve issue #1451.
CreateGuildRoleParams is identical to ModifyGuildRoleParams, so just use the latter when creating new roles.
* Give proper values to flag enum * Add zero value * Initialize lists * Update xml docs
* Support Gateway Intents Allows supplying gateway intents through DiscordSocketConfig which will be passed through the IDENTIFY payload, in order to choose what gateway events you want to receive. * Fixing enum casing * Feedback * Updating comment for GuildSubscriptions * Comment update
* Add Direction.Around to GetMessagesAsync * Reuse the method * Reuse GetMany * Fix limit when getting from cache without message id * Fix limit when getting from rest without message id * Change cache return It will return in a similar way to REST
* Add AllowedMentions to SendFileAsync * Update xml reference and mocked channels
…dUsers (#1548) * Fix Ready and AlwaysDownloadUsers Ready could fire before downloading all guild data and downloading guild users one guild per time without gateway intents is a waste of a gateway request that can support up to 1000. * Reduce batchSize and fix count * Fix typo * Split xml docs line Co-authored-by: Christopher Felegy <cfelegy@riseup.net>
* Updating comments for privileged intents * Moving updated comments to remarks * Formatting
* Update build.yml * Update azure-pipelines.yml * Update examples to NC3.1
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
No description provided.