[Unsupported] Leech training script


#243

Oh! I’d completely missed that and must have had an older version. I’ll make an update to my version when I get a chance.


#244

There’s a version 1.01 now on Greasyfork.


#245

So does the new Leech Training script by @rosshendry work now? Because I’m still getting the same old error page returning when trying to access the leech.

I’ve uninstalled both the original and new one, reinstall, but nothing works so far.


#246

Which error page?


#247

@CollateralGroove, did the update work? Given it’s been working okay for me before, I can’t see any difference in behaviour.


#248

The leech number won’t show up. When clicked, nothing happens. (obviously)

And this error page is what I mean. Same as when using the original script one.


#249

@rosshendry Shin Wanikani Leech Trainer works purrfectly for me now! Thank you! Much love!!


How to remember new Kanji?
#250

That means it’s still trying to connect to the now defunct server, which there’s no reference to in the updated script at all. I know that Curious wrote a lot of scripts, and some they didn’t write may rely on their server as well, so it could be that one of those is interfering with it.

It’s a laborious process, but try disabling everything other than the Shin script and see if it works then. If so, re-enable them one by one and see which one interferes.

If the ‘WaniKani SRS Level Progress’ does it, I also put an updated version of that up: https://greasyfork.org/en/scripts/372093-shin-wanikani-srs-level-progress


#251

As what you explained.
I didn’t notice that the old server was now long gone. @_@
And after checking the script, I just realized your script is using a new server, and I’m not logged in just yet. That’s the main reason why the leech trainer won’t load.

Now the script works perfectly! I have also installed that Shin SRS level progress as well.
Thank you very much for your help.


#252

@rosshendry Tried installing Shin WaniKani Leech Trainer. I logged into the heroku app page, but the leeches circle is empty. Looking at the network console, I see a lot of 500s from https://wk-stats.herokuapp.com/leeches/lesson?api_key=[api-key-here].

The response text is:
{“error”:“apiKey = [api-key-here] | url = https://api.wanikani.com/v2/study_materials?updated_after= | resp.StatusCode = 422 | resp.Status = 422 Unprocessable Entity | resp.Body = {“error”:“The updated_after parameter must be a valid ISO8601 format”,“code”:422}\n”}

Any idea on what I’m doing wrong?


#253

That probably means the wanikani API has changed so I’ll need to attempt to update the server. Will take a look this morning.


#254

Try it now. I haven’t done anything special, just restarted the server! I’m not really up on how it all hangs together, so debugging issues is pretty hard. I couldn’t see any ISO dates in the cache that weren’t valid, but I figure starting again from scratch isn’t too painful.


#255

Hmm, still giving me the same error. I noticed that earlier in this thread someone else mentioned the same problem, but I didn’t see a post stating a solution. But that means it’s probably something existing and not a new change.


#256

Ah, sorry. If I have some time I’ll try and dig into it a little more. At the moment I’m slowly building a browser extension to replace the user script which will remove the need for the server entirely. Slowly, slowly…


#257

Looking at the code for the server from github, it seem like the only time that updated_after should show up without an argument is when ‘data_updated_at’ is an empty string in the JSON file. I don’t have access to the server side cache file for my api key to confirm this though, I could be reading the code wrong. No worries if you can’t dig into it, I’ve never used it before so its not like I’m missing anything I had before.


#258

I figured it was either empty or a bad string. Weird thing is there doesn’t seem to be a cache file for any API keys, which is what I was expecting from reading the code. This is possibly then hitting this function and hitting the WK API again.

I can try adding some logging in, or if you’re a go-coder I can give you access to the repo and heroku app.


#259

I’m pretty familiar with go, but haven’t actually coded with it in a while. Might be a nice refresher if you want to get it off your plate.


#260

My intention was to get it up and running again so that I could use the scripts, but not maintain it long term. Got a github account? I should be able to add you as a collaborator on it


#261

Yeah, my github username is the same as here. https://github.com/someone972

Don’t blame you for not wanting to maintain it long-term; I’m glad you’ve gotten it back up and running though. Hopefully the community can keep these useful scripts alive even after the initial developer moves on to other things.


#262

Accepted the github invitation and am set up on the repo. I see that there’s an environments tab which has wk-stats deployed, but I don’t see anything which will let me access the files on the server. If you have instructions on how to do that let me know. I don’t think github or wanikani have a private message system, so if there’s somewhere else I should be asking all these questions, let me know.