Open YukinoHayakawa opened 1 year ago
Please, try the new version (v3.6.15)
I'm sorry but after the upgrade (I'm pretty sure that I actually upgraded the package as I checked the python scripts to make sure they match with your latest commit and my plugin_host.exe run with the correct package folder) but it appears to me that the problem persists in the very same way 😢
This patch if you checkout a new branch locally and apply it, should fix the issue, although it's a rather inelegant & brute-force approach
Hi. I'd say the ability to edit MediaWiki pages with Sublime Text provided by this extension is wonderful and very useful to me and thank you very much for developing it! However I've encountered a weird issue during my daily use.
I have a private wiki setup like this:
By private I mean one must login in order to read and edit. When I first open Sublime Text or have triggered a reconnection to the site, everything works fine. e.g. If I triggers:
or
Then I'll be able to see
However, if I leave the editor for somewhile, later operations will always fail reporting
The message had been confusing me for a while, until I finally tried to read the source code and found that some attempts to read the page were made before a logged-in connection is ensured, basically trying to anonymously read the page before the operation like open/save actually proceeds. The only workaround is to relaunch the editor or modify the connection setting in order to force a reconnection. Either way is equally annoying. Is there any error in my configuration? Or what would you suggest? Thank you in advance.
Edit:
I suspect there might be something to do with the site's session alive time/etc. Because even when I'm editing the wiki on webpage, if I have kept the page open for too long, when I submit the change it will also report something like session expired and let me retry. The thing is the
get_connect()
function in mw_utils.py doesn't seem to check whether the connection is still valid when it returns a cached connection. I don't know whether this check will be trivial to do with mwclient. What I'm doing now is to comment out the lines of code that return cached connections and always make a new one.