Git Product home page Git Product logo

4chan-downloader's People

Contributors

exceen avatar nachtalb avatar onioneffect avatar shakes4cc avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

4chan-downloader's Issues

auto download/ all images in one folder?

i want all the images of a certian tag to go into just one folder instead of each individual one, is there a way to do that?
also is there a feature to autodownload threads in the queue text file when one appears

Filenames...

I've run into a few issues with filenames. One of them isn't entirely Windows specific, and I have an idea of what needs to be done to fix it, but no idea how to. Duplicate filenames within a thread simply overwrite any preceding files. Usually Spoiler_Image or file.png.

The other issue is Windows specific and I've managed to solve it at least locally by:

from django.utils.text import get_valid_filename
...snip...
                img_path = ntpath.join(directory, get_valid_filename(img))
...snip...

The issue in question, filenames like this used to make the script halt on Windows:

C:\vtai>inb4404.py -c -d -l -t https://boards.4channel.org/vt/thread/34806758
[2022-10-11 07:50:46 PM] [  9/278] vt/34806758/[sound=files.catbox.moe%2F7a2f1v.m4a]{{takanashi kiara}}, {{{1girl}}}, {begging},[[[lipstick]]],[[[lip gloss]]],kusogaki,closed eyes,{{pov}}, {{incoming kiss}}, close-up, {{horny}}, blushing, solo, puffy sleeves, orange skirt, aqua choker, orange hair, ba.png
Traceback (most recent call last):
  File "C:\vtai\inb4404.py", line 171, in <module>
    main()
  File "C:\vtai\inb4404.py", line 31, in main
    download_thread(thread, args)
  File "C:\vtai\inb4404.py", line 112, in download_thread
    with open(img_path, 'wb') as f:
OSError: [Errno 22] Invalid argument: 'C:\\vtai\\downloads\\vt\\34806758\\[sound=files.catbox.moe%2F7a2f1v.m4a]{{takanashi kiara}}, {{{1girl}}}, {begging},[[[lipstick]]],[[[lip gloss]]],kusogaki,closed eyes,{{pov}}, {{incoming kiss}}, close-up, {{horny}}, blushing, solo, puffy sleeves, orange skirt, aqua choker, orange hair, ba.png'

After importing it appears to work.

Rewrite/Convert to python3?

The 2to3 tool should automate this as far as possible. I think the script should be converted to python3 because this is the new standard, support for python2 will be dropped in near future.

multiple threads from file error

File "Python\Python38-32\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
Process Process-1:
File "Python\Python38-32\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "4chdl\inb4404.py", line 44, in download_thread
if args.use_names or os.path.exists(os.path.join(workpath, 'downloads', board, thread_tmp)):
AttributeError: 'NoneType' object has no attribute 'use_names'
Traceback (most recent call last):
File "Python\Python38-32\lib\multiprocessing\process.py", line 315, in _bootstrap
self.run()
File "Programs\Python\Python38-32\lib\multiprocessing\process.py", line 108, in run
self._target(*self._args, **self._kwargs)
File "4chdl\inb4404.py", line 44, in download_thread
if args.use_names or os.path.exists(os.path.join(workpath, 'downloads', board, thread_tmp)):
AttributeError: 'NoneType' object has no attribute 'use_names'

"Something went wrong"

Regardless of thread, board, script location, drive letter, attribute, or host machine the script returns "Something went wrong" and times out after several tries.
image
Above picture showing different threads and boards and different attribute flags, all three failing almost immediately.
image
Interestingly however it works fine on an arch install. I've tried it on two machines running Windows 10, reinstalled python 3 as well
Not entirely sure why it's dropping almost immediately on Windows. Assume this is a Windows problem, but nothing changed since I used it yesterday. will close if I find a solution to using it on windows.
sorry there isn't much information to go off of.

how the fuck do i run it

when i run the shitty python file it immediately closes, and the instructions are ass and dont tell me how to run it

Change Default Directory

I'm not versed in Python. how can I change the directory from workpath\downloads\(board)\(thread) to something like this C:\Users\Me\Downloads\Video\(board)\(thread)
Thanks.

Unknown Missing Module Causing -t (--title) To Not Work

with running a command:

python inb4404.py -t [Thread URL]

Terminal returns with:

Could not import the required modules! Disabling --title option...

Program continues & runs fine, but files are downloaded with non original names.

Script can't download files from a thread with a other thread quoted (Cross-thread)

NSFW

How to reproduce:

1° Try to download from this link: https://boards.4chan.org/gif/thread/13521437

This error appears

File TTT Part 2 Top Tier Titties \1527053877481.webm from https://i.4cdn.org/gif/1536882732639.webm UNKNOWN ERROR OCCURRED [WinError 183] cannot create an existing file: 'C:\\Users\\mario\\4channer\\TTT Part 2 Top Tier Titties '

But the "TTT Part 2 Top Tier Tittiles" and the two .webm files doens't exist. Using a custom folder location doens't work.

invalid syntax?

I guess I miss something very simple, but cannot figure it out, so here goes nothing

I followed the instructions to in README.md and typed

$ python inb4404.py http://boards.4chan.org/w/thread/2096591/lain-thread-anyone-have-any-arisu

The only result was:

File "inb4404.py", line 129
print(line.replace(link, '-' + link), end='')
^
SyntaxError: invalid syntax

And I'm too dumb to know if this is a typo to fix or I should use a different URL (direct one to the first pic in thread maybe?).

(After hundreds of shameful edits): also the output points at end='' equation, but for love of god I have no idea how to paste it here so markdown does not cut out all spaces.

Is it dead?

I mean it seems so. The download.py is gone from the main repo and the one I have has started to 404

Add requirements.txt file

Make a requirements file so that it's easier to download the necessary python libraries. Suggested example attached to this comment. Please add anything I might have missed.
requirements.txt

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.