maaaaz / webscreenshot

A simple script to screenshot a list of websites
GNU Lesser General Public License v3.0
653 stars 162 forks source link

Domain does not gets formatted automatically due to which command fails #66

Open 0cirius0 opened 3 years ago

0cirius0 commented 3 years ago

I tried to execute it from within a python code but it kept failing. I tried took the DEBUG output and matched it wih when the command is run directly from shell. I tcame out to be that when I provide a list of domains from within another python code then the domains aren't being converted from google.com to http://google.com:80 due to which the command fails.

Screenshot when ran inside python Screenshot from 2020-12-15 19-23-54

Screenshot when ran directly Screenshot from 2020-12-15 19-24-52

maaaaz commented 3 years ago

Hello @hellrider9,

It fails because the list of targets you pass (through lines variable) is not properly parsed and formatted. You should pass lines like http://google.com and not google.com :

In a next release, I will upgrade the parse_targets function to be able to accept to parse a programmatic list as parameter, not only the options parameter, and then update the wiki. Basically after this change:

Cheers.

0cirius0 commented 3 years ago

Thanks.

Just for the heads up, when can I expect then next release.