/qa/ - Questions and Answers

Communication between site staff and (you)

Mode: Reply
Name
Subject
Message

Max message length: 4096

Files

Max file size: 4.00 MB

Max files: 5

E-mail
Password

(used to delete files and postings)

Misc

Remember to follow the rules



(822.76 KB 514x449 Working.gif)
Tools and scripts mys_elf Board owner 06/29/2021 (Tue) 02:17:18 Id:2dfb77 No. 4
Some tools and scripts that pertain to the site. >(you) persist userscript. https://gitgud.io/mys_elf/nhnb-you-persist For when you don't like to store browser data but would like to preserve your (you)s. Not totally happy with the operation of it, but it works well enough for now. Will update at some point in the future. >Private Boards addon https://gitgud.io/mys_elf/Private-Boards An addon to require login on certain boards. >PenMod https://gitgud.io/mys_elf/PenMod The frontend for this site. Uncreative name included. >Lynxscripts https://gitgud.io/mys_elf/lynxscripts A couple of scripts contained here. archiveLimiter.py can prune the archive to a set number of threads. fileLimiter.py will prune the oldest images first to keep disk space usage within a set amount. Useful when operating on limited disk space. autoLynx.sh is a shell script to automatically set up a Lynxchan instance. Useful for setting up a testing environment. >Super simple Python scraper https://gitgud.io/mys_elf/nhnb-scraper Dumps threads into .json files, dumps images into /media/. >Thread Resumer userscript https://gitgud.io/mys_elf/nhnb-thread-resumer Remembers where you left off in a thread and places you back at that point when you return. >Dice https://gitgud.io/mys_elf/dice Adds dice to LynxChan, forked from another dice addon with few changes.
Just came across this: https://gitgud.io/Codexx/channel_changer Appears to be a chan scraper supporting multiple softwares (including LynxChan) with the ability to import into your own LynxChan instance. I haven't tried it yet but it sure looks cool.
Tried out using the simple scraper, end up getting the following. Any ideas? Downloading 59dd2d0dc5073378dc5e65d432e1bc0ce7c3dd75455978ec622a39bbb15b9f98.png Downloading /fim/custom.spoiler Traceback (most recent call last): File "[REDACTED]\NHNB-Scraper.py", line 122, in <module> scrape() File "[REDACTED]\NHNB-Scraper.py", line 118, in scrape catalogLoader(b) File "[REDACTED]\NHNB-Scraper.py", line 29, in catalogLoader threadLoader(board, toUp) File "[REDACTED]\NHNB-Scraper.py", line 48, in threadLoader saveMedia(board, postData['files']) File "[REDACTED]\NHNB-Scraper.py", line 57, in saveMedia saveFile(board, tURL) File "[REDACTED]\NHNB-Scraper.py", line 65, in saveFile with open('NHNB/' + board + '/media/' + file.replace('/.media/', ''), 'wb') as out_file: FileNotFoundError: [Errno 2] No such file or directory: 'NHNB/fim/media//fim/custom.spoiler'
>>291 This looked a lot better, so I gave it a try. Starts to work but quickly stops because of the following. [REDACTED]\channel_changer-master>change-channel.py -s nhnb.org -b fim -o test Threads |▎⚠ | (!) 1/118 [1%] in 0.4s (2.76s (0.0 Traceback (most recent call last): File "[REDACTED]\channel_changer-master\change-channel.py", line 658, in <module> scrapeLynxchanBoard(args, json_catalog, output_root) File "[REDACTED]\channel_changer-master\change-channel.py", line 288, in scrapeLynxchanBoard for result, thread_size in results: File "[REDACTED]\Python\Python310\lib\multiprocessing\pool.py", line 870, in next raise value File "[REDACTED]\Python\Python310\lib\multiprocessing\pool.py", line 125, in worker result = (True, func(*args, **kwds)) File "[REDACTED]\channel_changer-master\change-channel.py", line 189, in scrapeThread output_html.write(html_thread) File "[REDACTED]\Python\Python310\lib\encodings\cp1252.py", line 19, in encode return codecs.charmap_encode(input,self.errors,encoding_table)[0] UnicodeEncodeError: 'charmap' codec can't encode character '\u266a' in position 18698: character maps to <undefined> Taking a short look on google about the problem, it seems like a simple unicode encoding issue with a simple fix, but I have no real experience with python to implement it properly. Would be nice to get something working so the things here can get archived.
>>408 I've pushed a fix to the repo, should work now. https://gitgud.io/mys_elf/nhnb-scraper >>409 I still haven't gotten around to testing out Channel Changer, so I can't really offer much help. I will say that it would probably be the better option if it can be made to work.
An addon that makes subscription boards or "paying members only" boards possible. Users will have to login to use and every post will show the user's login name. It will give site owners the chance to monetize.
>>483 >Paying to use a dead board. The activity in /fim/ is already pretty slow, imagine how dead a board that only 1 or 2 users pay to use would be. Still would be more active than /clop/ if the one schitzo likes rambling to himself about being the king of NHNB because he pays or something.
An addon that automatically shows login names may please namefags.
Namefags are motivated not only by names but also badges. If you give them the badge "king", they may make 1000 posts a day.
>>485 >>486 I think the only person on the board who intentionally namefags is ISleepNow, everyone else just uses a name or multiple names for practical reasons and occasionally forgets to clear the name field when posting in another thread. >Le king of NHNB This isn't a discord server; gangsta status is earned here and flexing it with a flashy marker is against the ethos.
>>485 >>486 >>483 nice bait

Delete
Report