1
0
Fork 0
mirror of https://github.com/diamondburned/arikawa.git synced 2024-12-11 16:05:00 +00:00
Commit graph

27 commits

Author SHA1 Message Date
Samuel Hernandez 40e1a3757d *: Migrated Go Modules to v3 2021-06-01 19:59:01 -07:00
Maximilian von Lindern 428ef4ac70 rate: Add rate.AcquireOptions 2021-05-29 22:25:52 -07:00
diamondburned 050c1b6497 Webhook: Add rate limiter and WithContext 2021-03-05 20:01:33 -08:00
diamondburned 2f6ab0d451 API: Fix atomic SIGSEGV in ARM 2020-12-31 10:24:51 -08:00
diamondburned d65807ce15 API: Potential rate limit fix for reactions 2020-12-11 17:58:52 -08:00
Maximilian von Lindern 0a8b24339b
API: Added timeout if deadline is after rate limit (#173)
* Rate: don't sleep if sleep exceeds context deadline

* Httputil: add Client.Timeout

* Bot: set default API timeout to 5 minutes

* Rate: reduce calls to time.Now in Acquire

* API: Optimize to use deadline instead of recalculating

Co-authored-by: diamondburned <datutbrus@gmail.com>
2020-11-25 12:08:42 -08:00
diamondburned 75df94d9f4 *: Migrated Go Modules to v2 2020-10-28 15:39:59 -07:00
diamondburned f9f254148f API: Fixed rate limiting tests 2020-10-28 15:23:47 -07:00
diamondburned 2af51c9a5a API: V8 breaking rate limit changes
This commit updates Retry-After to be seconds-accurate instead of the
previous millisecond-accurate. Another issue (#153) is opened to get a
more accurate number, which is in the JSON body instead of the header.

This commit also removed the rate limit precision header. It also uses a
more accurate calculation algorithm to derive the reset time.
2020-10-28 14:31:15 -07:00
diamondburned 94cca0adca httputil: Fixed unlock of unlocked mutex bug 2020-08-04 14:09:43 -07:00
Maximilian von Lindern 1585797b52 *: Linting and typo fixes (#134)
* Linting and typo fixes

* Linting and typo fixes

* revert comma fix
2020-07-29 16:58:33 -07:00
Maximilian von Lindern 32789bb6e2 *: Separate utils and internal (#129)
* Utils: move package utils/heart to internal/heart

* Utils: move package utils/moreatomic to internal/moreatomic

* Utils: move package utils/zlib to internal/zlib
2020-07-29 16:58:33 -07:00
mavolin 41ce1f389e
make all error messages lowercase 2020-05-16 23:14:49 +02:00
diamondburned (Forefront) f22d6eaa9f Utils/API: Replaced semaphore-mutex API 2020-05-06 00:40:31 -07:00
diamondburned (Forefront) e07784a03a Utils: Swapped go-csync with /x/sync/semaphore 2020-05-06 00:32:21 -07:00
diamondburned (Forefront) 748ad5641c API: Added AllowedMentions and more tests 2020-04-19 16:35:37 -07:00
diamondburned (Forefront) 14b9d8f43a API: Fixed unlock of unlocked mutex bug 2020-03-01 14:25:54 -08:00
diamondburned (Forefront) 8e3826e5d6 State: Fixed an error related to the last commit 2020-02-10 20:28:36 -08:00
diamondburned (Forefront) f33dc2ee75 API: Fixed major rate limiters not working 2020-02-09 12:54:16 -08:00
diamondburned ce752a0230 API: Improved the rate limit parser 2020-02-07 08:37:01 -08:00
diamondburned f3b4362ada API: Added reactions into rate limit parsers 2020-02-07 08:31:10 -08:00
diamondburned (Forefront) 73f5cdec9e Added HTTP retry, fixed async JSON body corrupting 2020-01-20 11:28:55 -08:00
diamondburned (Forefront) ff0bc7b98b Tweaks to tests and CI 2020-01-20 03:15:41 -08:00
diamondburned (Forefront) 532a8ba8b4 Apparently I don't need reaction rate limits 2020-01-19 09:52:43 -08:00
diamondburned (Forefront) 67450c4872 Added wsutil 2020-01-08 21:24:45 -08:00
diamondburned af87f116cd Integrated rate limiter 2020-01-08 10:43:15 -08:00
diamondburned (Forefront) e4cd4f9b69 Experimenting with rate limits 2020-01-07 23:10:37 -08:00