Open sentience opened 3 years ago
Turns out it was something obvious: I had my username wrong.
I guess this is what happens when you specify a non-existent username. Might be good to catch that and display a better error.
Same error occurs if the user is private (as I was -- just made myself public to run this and worked successfully)
Not sure if more verbose error codes/messages are received that could provide some more help?
Not sure if more verbose error codes/messages are received that could provide some more help?
I'll have a quick look, but "unexpected end of json input" makes me think it's probably just an empty 404. Nevertheless it should definitely be handled more gracefully.
@bbeesley Any plans to convert the JavaScript to Typescript? I pulled the code down and my VS code setup complained about the use of types
in non-TS files. I started refactoring. I can work on a PR if you're interested?
@bbeesley Any plans to convert the JavaScript to Typescript? I pulled the coffee down and my VS code setup complained about the use of
types
in non-TS files. I started refactoring. I can work on a PR if you're interested?
lmao, yeah, I haven't looked at this repo in ages and basically did the same thing earlier today, started refactoring. I'm at work at the moment so I've got other stuff to do right now, but after work I'll create a next
branch with the stuff I started doing, I'll give you a shout when I've done that if you wanna help out.
@cbserra ok, I've done a bunch of tidying up, migrated it to typescript, and moved the ci over to github actions. Should be in a good state now if you wanna improve the error handling or do some refactoring. I didn't change any of the functionality, just build/test/publish stuff.
fyi, I've moved it over to pnpm as well; aint nobody got time for npm ci.
Trying trakt-to-letterboxd for the first time, this is what I'm getting:
I can crack open the Node debugger to inspect the JSON responses if necessary, but I thought I'd make sure I'm not missing anything obvious.