pikax / gin-downloader

download manga from public websites
MIT License
11 stars 1 forks source link

kissmanga.images Error: Malformed UTF-8 data #10

Closed calgara12 closed 7 years ago

calgara12 commented 7 years ago

Whenever i try to retrieve images from Kissmanga i get the Error: Malformed UTF-8 data.

Is there something i can do about it? Here is the code i'm using:

gin.kissmanga.images("Gintama", 1)
    .then(x=>{
        console.log('starting...')
        console.log('getting %d images', x.length);
        return x.map(p=>{

            p.then(r=>{
                //this will run as soon each promise is resolved
                //r contains url
                console.log(r);
            })
        });
    })
    .then(x=>Promise.all(x))
    .then(x=>console.log('resolved'))
    .catch(console.error);

And this is the Error message:

evalmachine.<anonymous>:4
Error: Malformed UTF-8 data
for (var img in lstImages) imgs.push(wrapKA(lstImages[img]).toString());
    at Object.stringify (evalmachine.<anonymous>:1:7704)
                                                           ^
    at init.toString (evalmachine.<anonymous>:1:4960)

    at wrapKA (evalmachine.<anonymous>:2:4746)
TypeError: Cannot read property 'toString' of undefined
    at evalmachine.<anonymous>:4:38
    at ContextifyScript.Script.runInContext (vm.js:53:29)
    at evalmachine.<anonymous>:4:60
    at Parser.imagesList 
    at ContextifyScript.Script.runInContext (vm.js:53:29)
    at KissManga.<anonymous>
    at Parser.imagesList 
    at KissManga.<anonymous>
    at step 
    at Object.next 
    at step 
    at Object.next
    at fulfilled 
    at fulfilled 
    at <anonymous>
    at process._tickCallback 

Thanks for your hard work and have a nice day! :)

pikax commented 7 years ago

Hi,

Sorry just got time to look to this issue, I can't reproduce it.

Can you check wich version you have installed?

npm list gin-downloader

The latest is 1.0.3, please upgrade if you have a different one.

If the issue is still there, let me know.

Thanks for open the issue :)

calgara12 commented 7 years ago

It appears that i am on the latest version.

unbenannt

Thank you :)

pikax commented 7 years ago

does still happen?

can you go to the Gintama kissmanga and open first chapter from the website?

calgara12 commented 7 years ago

yes, the same problem still occurs as described in the post above.

Opening the first chapter in the webbrowser works perfectly fine.

pikax commented 7 years ago

I manage to reproduce using a proxy from USA, I published a fix, just update to 1.0.4.

thank you, let me know if is working

calgara12 commented 7 years ago

Yep that fixed it. Thank you :)