wakatime / sublime-wakatime

Sublime Text 2 & 3 plugin for automatic time tracking and metrics generated from your programming activity.
https://wakatime.com/sublime-text
BSD 3-Clause "New" or "Revised" License
526 stars 47 forks source link

Overwrites default urllib opener #110

Closed rchl closed 2 years ago

rchl commented 2 years ago

Just noticed a very bad thing that this package does. It sets some custom urlopener handler globally here:

https://github.com/wakatime/sublime-wakatime/blob/847223cdcee6e2339fa4c9a77296c579a4562fcd/WakaTime.py#L859-L865

This affects every other package running in the same ST host thus causing issues due to adding the If-Modified-Since header.

Please only apply custom opener for your own requests. I haven't investigated how this should be done but it must be possible one way or another.

alanhamlett commented 2 years ago

Fixed with da17125b975c15aa37b24d828d12c3a35c9cd96a.