Kumar-Saksham / CSMM-CLI

A simple CLI based mod manager for Cities: Skylines.
MIT License
7 stars 4 forks source link

Error when trying to download a collection #3

Closed spakkko closed 4 years ago

spakkko commented 4 years ago

The console return me this error whenever i try to download a steam collection of mod

Error while grabbing data: Evaluation failed: TypeError: Cannot read property 'innerText' of null at puppeteer_evaluation_script:9:7

immagine

Kumar-Saksham commented 4 years ago

I cannot reproduce the error. Are you on the latest version of csmm-cli ? You can update using npm i -g csmm-cli command. Let me know if the problem persists.

spakkko commented 4 years ago

I ran the update command but I get the same error when I try to download a collection

immagine

Kumar-Saksham commented 4 years ago

So, just to be sure. This doesn't happen when you install a single item/mod?

spakkko commented 4 years ago

no problem with single mods so far

Kumar-Saksham commented 4 years ago

Published a patch, which should fix this issue. Update csmm-cli (version will be >=0.5.1).

I am still not able to reproduce the error you are getting. I added few fallback method in case error occurs. Hopefully this fixes the issue.

View changes (Fix commit: 38743965ec971d33d013a97ef7bae74a4b955e44)

guihleao commented 4 years ago

I'm also having the same problem =/

Executing prompt as administrator with csmm-cli 0.5.1

image

Kumar-Saksham commented 4 years ago

Which version of node are you using? you can check with node -v command

guihleao commented 4 years ago

node v12.16.3 and npm 6.14.4

Kumar-Saksham commented 4 years ago

It seems like the problem was caused by incorrectly identifying collection id as an item id. Differentiation between item and collection was done on the basis of whether "collection" keyword appears on the steam page, which most probably will be different for different languages. Thanks @guihleao for the screenshot in Portuguese. A new version 0.6.0 is published which should fix this issue.

guihleao commented 4 years ago

@Kumar-Saksham thank you very much!

It's downloading now, but it keeps repeating forever, something about this:

image

It looks like it can't register that the file was downloaded.

Should I open another issue?

guihleao commented 4 years ago

@Kumar-Saksham thank you very much!

It's downloading now, but it keeps repeating forever, something about this:

image

It looks like it can't register that the file was downloaded.

Should I open another issue?

So what I've done to solve it: Change system language to English temporarily, installed the mods and then back to my native language.

Kumar-Saksham commented 4 years ago

can you send me screenshots of these 2 urls @guihleao https://steamcommunity.com/workshop/filedetails/?id=1625704117 https://steamcommunity.com/workshop/filedetails/?id=1625704117&l=english

guihleao commented 4 years ago

Sure,

PT-BR: image

ENG: image

Kumar-Saksham commented 4 years ago

I have forced english language while fetching the data, so it should fix the last issue @guihleao mentioned. Update to 0.6.1

guihleao commented 4 years ago

yeeee perfect! thank you very much again!

Kumar-Saksham commented 4 years ago

I am closing the issue now. @spakkko, let me know if the fix didn't work for you.