/g/ - Technology & Programming

>>3309637 #
Chromium 64.0.3282.86, Windows x86-64, have a few addons but the issue persisted even in a new profile so I don't think they're relevant.
Problem was reproducible on Chromium but not Firefox.
>>3310228 #
>>3310138 #
Why are you on the beta channel? Switch to stable and see, if you can reproduce.


「Image-Dumping/Multi file upload script」

AnonymousExpandLast 100
GIqSnWaDsEx68 KB822x252multi-upload.png

New fixes and features
>shuffle file list
>you can now post text while dumping. just type while it's uploading an image and the post won't auto-submit, dump will continue after closing the post
>FF57 and Greasemonkey 4 compatibility

Older features
>automatic detection of multi-file drop (single-file is handled natively by meguca)
>filename editing
>file deduplication (queue and current thread)
>adjustable delay between posts
>numeric sort by filename

I dev and dogfood on firefox, feedback from other browsers welcome.
4 posts and 2 images omitted See all
I don't know, if this is present in the latests version, because that does not work on Chrome, but dragging some images, while a set is already dumping, will produce two separate timers (setTimeout) dumping the same set of images.
Pushed a new version to deal with dedposting. Might still have issues with chrome, I have only tested with FF nightly and GM 4.1
Ok, tested with chromium, werks too.
Everything werks, sankyuu.
And fixed again now that liveposting is back. )version 2.13)

Pay me for a better one. Cheap is cheap.
Put a crypto miner on the website

This one is only one virtualized server rented from a VPS provider. I don't have the cash to deploy and manage my own.


「I broke meguca with 1 character」

Mega MilkExpandLast 100
GIqSnWaDsEx252 KB373x56769868751b40437ab8664e86df57914c4-imagepng.png
I posted unicode that crashed meguca. I will not post this character as in the wrong hands will destroy your site. There is an exploit in Chrome based browsers that don't allow a certain Unicode character to be posted.

The bug is being reported to Google so it should be fixed soon. Be careful guys. Use Firefox on any realtime imageboard until this is confirmed to be fixed.

Mods should sticky this as a warning on the front page.

- Your friends at mewch.net
>>2717599 #>>3210359 #
Server is written in go, so a Unicode character breaking it is pretty unlikely.
Breaking the c++ mess that is chrome seems more likely.

>>2905181 #
I also tested on a Tegra running Linux and it also does only 8 bit sadly.
But it might be that platform legit can't do more than 8 bit.
>wanting us to post on a different board
Unlikely, anon-chan.


「DistChan or TagChan」

AnonymousExpandLast 100
GIqSnWaDs37 KB540x500network-distributed.gif
I'm thinking about writing an ultra light imageboard engine for distributed chans. I can write JavaScript, since I wrote CatChan, but I'm not webdev and I don't know PHP, SQLite, CSS, Captcha, Apache or Nginx, so anyone who provide technical advice are welcome. However, it will be an conceptual one, so I'll refuse all conceptual advice probably. Anyway, helps or advice are welcome. And also, anyone who want to try this in your site are also welcome.
95 posts and 0 images omitted See all
GIqSnWaDsEx37 KB624x526go_sql.png
>>2854900 #
> I am currently writing an image board in haskell
Can we share formats of JSON/API or DB?

Now I'm trying to write distchan in Golang for test, and I may give 3 languages to distchan; PHP, Node.js and Go. All 3 languages use the same DB, so users of distchan can change their platform as they wish at anytime. If you could share DB format, users can select Haskell or Erlang also, though I don't know both languages.

BTW, Why doesn't golang give a method fit for "SELECT * FROM table;"? I'm really disappointed and confused. Pic related.
As far as my investigation, Node.js may be slower than PHP at large data. It's faster at small data.

@about 100 posts
Node 1.723 [ms] -36.2%
PHP 2.702 [ms]

@about 1360 posts
Node 2.936 [ms] -7.8%
PHP 3.184 [ms]

@about 6700 posts
Node 4.384 [ms] -14.1%
PHP 5.104 [ms]

@about 15800 posts
Node 6.198 [ms] -1.8%
PHP 6.314 [ms]

@352 threads in /v/, 636 threads in whole.
Node 11.246 [ms], 11.363ms with debug-interface.
PHP 9.862 [ms]

This might be caused by NOT using cluster, but Node.js was not so fast. However, Node.js coul.d use shared memory easily, so I could build software cache in JavaScript, and it was ultra fast as you can imagine.

@748 threads in all, 352 threads in /v/.
Node 11.880 [ms] (queued)
Node 7.484 [ms] (queued, cached) -37%
Node 3.986 [ms] (not queued, cached) -66% (52.77%: json_out, 27.25%: createWriteReq, 5.27%: writeUtf8String ...)

The last case above just did JSON.stringify(), and it needed nearly 4ms. I think this is slow.
Now I'm trying to make it in Golang, but I'm confused as I wrote, Golang is NOT suitable for web or JSON.
>>2886712 #
I'll explain my thought about transparency for discussion of invite only boards in meguca/dev thread.

Transparency is achieved by,

1. Users can know who can moderate their posts before post.
2. Users can know who did moderate their posts after moderation.
3. Users can know how and why the posts were moderated.

And for system easiness, I'll implement reports and bans as posts for /rep/ and /ban/. Moderation will be posts /rep/ or /ban/. Therefore users can know,
4. How many reports are there about a post.
5. Users can know whether mods had read the report if mods post in /rep/ usually.
(/rep/ is also a normal board where everyone can read/post in. Therefore they can discuss about the posts and reports there. We can separate meta discussions from threads by this.)

In my opinion, this is fair and this had been working well in our 2ch.net, where all reports and ban procedures can be read by users. However, reports CANNOT be read by users in chans, this may bring confusions. So I may provide hidden or invite only board feature for /rep/. Then, such boards will be preceded by _, like /_rep/. And uses can know which boards are public or invited only easily. Invite only users' boards will be a decision of site's owner.

So, does invite only board feature need?
I got the results as I said in >>2861365 #

@239 threads in /v/, 423 threads in /all/.
Node 8.119 [ms] +10.6%
PHP 7.342 [ms]
Go 6.272 [ms] -14.6%
Node 2.611 [ms] -64.4% (not queued, cached) 4.731ms(=7.342-2.611) is needed for access to SQLite.
Go [ms] -79.0% (1.541ms=6.272-4.731 is estimated from Node's result,
x2 faster than Node at JSON.stringify;
27.25%+5.25%=:=1/3(this is fixed), 1.541/2.611=:=0.6, 0.6-(1/3)/0.5(from52.77%)=0.53
while this might be caused by my using dual core CPU.)

So, Golang is fast, but shit. I don't give distchan in Golang.

Golang was not as fast as I expected, and it requires quite many lines. It is not suitable for prototyping.
>>2886715 ➡ #
bump for keep

>>2588303 #
Custom CSS code to use for the meantime (use on Ashita)
part 1/2
body {
margin: 0;
padding: 0;
font-family: Monaco, "Andale Mono", Courier, monospace;
font-size: 10pt;
background-color: #000;
#threads:not(.custom-BG) section > article.editing:not(:first-child) {
background-color: #B2B2B2;
border-color: #B2B2B2;
color: #000;
#threads.custom-BG section > article.editing {
background-color: #B2B2B2;
border-color: #B2B2B2;
color: #000;
#threads:not(.custom-BG) section > article.editing:not(:first-child) code.code-tag {
background: #000;
#threads.custom-BG section > article.editing code.code-tag {
background: #000;
>>2588329 #
>>2588320 #
part 2/2
article.preview.editing code.code-tag {
background: #000;
code.code-tag {
background-color: #000;
article.preview.editing {
background-color: #B2B2B2;
border-color: #B2B2B2;
color: #000;
.side-panel {
background-color: #000;
border: 1px solid #000;
.embed {
background-color: rgba(0,0,0,0.4);
color: white;

For better horizontal posting (imo) add >>2114143 # either to the top or the bottom of your custom CSS
#thread-container {display:flex;flex-direction: row;flex-wrap: wrap;align-items: stretch;}
Just thought I'd post it here in case someone is looking for how to do it. It's pretty obvious yeah, but if someone just wants to fix their custom CSS for the catalog and doesn't know how to do it, here you go.

I just tried it thinking it would look better, but that's not the case IMO. It evens out the thread boxes in the catalog.
#catalog article {
height: 300px;
workaround for lock to bottom, i.e. if you never want to lock to bottom:

#page-container {margin-bottom:1000px;}

It simply adds enough space to the bottom to avoid hitting it most of the time.

bump for keep.

>>2939368 #
No such language as Lisp. There is common Lisp and closure Lisp, but on its own Lisp doesn't exist.
>>2939415 #
>>2939372 #
I never said Lisp is a language. Lisp is a group of languages.


>>2873454 #
Can you try using go build and then running the binary? It should not make a difference, but >Windows, so I don't know. Maybe.

>it's difficult for me to use Golang to do generic programming
Go does not have generics. It does have optional dynamic typing and reflection though. Use simple interfaces like in the io package for polymorphism. Use the reflect package and type switches for dynamic typing. But if you want actual static dispatch and generics, don't use Go. I keep saying this, but you should be using it like a statically typed faster Python or similar - perfect for many applications.
>>2886715 #>>2886734 #
>>2873890 #
Thanks. I got the result finally. See >>2886712 ➡ #

> go build or go install
Nothing was changed. 'go run' needs 85 seconds, and even 'go help' needs 2 seconds. ('go help' needed 15 seconds yesterday. I don't know why go is fast today.) Go is not sutable for windows.
> No generic abilities
This is shit. I had to write extra codes to get results from a SQL;"SELECT * FROM threads;" This is quite obnoxious. I'll use PHP or Node.js for prototyping. Anyway, thanks.
>>2887480 #>>2904997 #
>>2886715 #
My personal opinion is that dynamically typed languages are all trash, but whatever.
>>2886715 #

I've used Go on Windows for about two years now, the tooling performs just fine on my boxes. Not sure what was killing your perf but I never had a serious Windows specific issue.


「Firefox bug.」

AnonymousExpandLast 100
GIqSnWaDsEx816 KB916x606Screenshot_20171008_104048.png
Hey lat. Opening and closing the file selection for Firefox crashes it. On Manjaro KDE x86_64. Don't know if this is Linux specific or not, but seems like it. It could be an issue with KMozillaHelper.
That is in no way a meguca issue. You should open up a an issue on either of those projects' bug trackers.