Skip to content
This repository has been archived by the owner on Dec 26, 2022. It is now read-only.

🐛 gateway no longer starts multiple instances #354

Merged
merged 6 commits into from
Jan 8, 2022

Conversation

Lunarmagpie
Copy link
Member

@Lunarmagpie Lunarmagpie commented Jan 7, 2022

Changes

  • fixed: Disconnect bug where it started 5k times 💀 should be patched

Tested for ~5 hours at the time of making this PR and I forced a reconnect by unplugging my wifi xD to make sure it went smoothly.
Opcode 9 hasn't been tested since I haven't gotten the payload. Should work as it functions the same as the heartbeat disconnect.

Notes
close code 1001 was changed to 4000 because 1001 would turn the bot offline. 4000 is also a websocket close close officially available to application, discord uses it for unknown disconnects, and it isn't 1000.
__should_reconnect was renamed to __should_resume because that was what it actually did.
Line 325 was changed because I missed that in the docs when I read it the first time.

Check off the following

  • I have tested my changes with the current requirements
  • My Code follows the pep8 code style.

@codecov
Copy link

codecov bot commented Jan 7, 2022

Codecov Report

Merging #354 (4ea63a8) into main (255cc3a) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##             main     #354   +/-   ##
=======================================
  Coverage   90.54%   90.54%           
=======================================
  Files           8        8           
  Lines          74       74           
=======================================
  Hits           67       67           
  Misses          7        7           

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 255cc3a...4ea63a8. Read the comment docs.

pincer/core/gateway.py Outdated Show resolved Hide resolved
@Lunarmagpie Lunarmagpie merged commit 515d4a8 into Pincer-org:main Jan 8, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants