00:06:06 | * | mahsav joined #nim |
00:08:29 | * | nohusuro left #nim (#nim) |
00:18:37 | FromGitter | <zacharycarter> @genotrance : ⏎ ⏎ ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=59c456ddcfeed2eb6538e138] |
00:19:30 | FromGitter | <genotrance> that's WIndows specific so that I could read giant files without running out of memory |
00:20:19 | FromGitter | <zacharycarter> hrm |
00:20:34 | FromGitter | <zacharycarter> probably not going to work on my macbook pro then :P |
00:20:59 | FromGitter | <genotrance> there's some bug with Nim file reading: https://github.com/nim-lang/Nim/issues/6031 |
00:21:43 | FromGitter | <genotrance> i'm replacing that code with standard Nim since I am going to use nimSHA2 to do the file hashing, I no longer need to read the whole file in memory (I hope nimSHA2 isn't storing it all in memory and digests it right away) |
00:36:36 | * | pilne joined #nim |
00:41:29 | * | mahmudov joined #nim |
00:45:48 | * | mahmudov quit (Ping timeout: 240 seconds) |
00:48:38 | * | zachk quit (Quit: night night...zzzzzZZZZzzzz) |
01:02:24 | * | dhalinar joined #nim |
01:21:34 | * | Jesin quit (Quit: Leaving) |
01:31:19 | * | yglukhov joined #nim |
01:36:18 | * | yglukhov quit (Ping timeout: 240 seconds) |
01:53:59 | * | chemist69 quit (Ping timeout: 255 seconds) |
02:07:48 | * | chemist69 joined #nim |
02:08:24 | * | Snircle quit (Quit: Textual IRC Client: www.textualapp.com) |
02:12:08 | * | endragor quit (Remote host closed the connection) |
02:15:29 | * | ipjk quit (Read error: Connection reset by peer) |
02:23:24 | * | Etheco- joined #nim |
02:23:24 | * | Etheco quit (Read error: Connection reset by peer) |
02:40:49 | * | endragor joined #nim |
02:41:20 | * | endragor quit (Remote host closed the connection) |
02:43:08 | * | endragor joined #nim |
03:02:05 | * | Serenit0r joined #nim |
03:05:37 | * | Serenitor quit (Ping timeout: 248 seconds) |
03:14:21 | * | gokr quit (Ping timeout: 252 seconds) |
03:22:27 | * | pilne quit (Quit: Quitting!) |
03:34:56 | * | yglukhov joined #nim |
03:39:47 | * | yglukhov quit (Ping timeout: 260 seconds) |
03:48:23 | * | Serenitor joined #nim |
03:49:17 | * | Serenit0r quit (Ping timeout: 240 seconds) |
05:16:01 | * | jsgrant quit (Ping timeout: 240 seconds) |
05:24:59 | * | vendethiel- joined #nim |
05:25:22 | * | Ven`` quit (Ping timeout: 260 seconds) |
05:34:57 | * | mahsav quit (Ping timeout: 248 seconds) |
05:35:16 | * | mahsav joined #nim |
05:36:58 | * | yglukhov joined #nim |
05:41:12 | * | yglukhov quit (Ping timeout: 252 seconds) |
05:43:03 | * | jsgrant joined #nim |
05:47:09 | * | jsgrant quit (Client Quit) |
05:47:32 | * | jsgrant joined #nim |
05:50:31 | * | Vladar joined #nim |
06:20:22 | * | gokr joined #nim |
06:21:19 | * | fastrom1 quit (Quit: Leaving.) |
06:24:39 | * | mwbrown quit (Ping timeout: 252 seconds) |
06:24:55 | * | mwbrown joined #nim |
06:27:55 | * | rauss quit (Quit: WeeChat 1.9) |
06:35:40 | FromGitter | <mratsim> I think nimsuggest dying often with VScode is eating my disk space |
06:37:03 | * | nsf joined #nim |
06:39:20 | * | solitudesf joined #nim |
06:42:31 | FromGitter | <ephja> @mratsim nimsuggest tends to leak memory atm. you could run a script that periodically kills nimsuggest processes. why is it wasting disk space? is it because the page file is getting bigger? |
06:47:35 | FromGitter | <mratsim> maybe the swap |
07:07:08 | * | MyMind quit (Ping timeout: 240 seconds) |
07:07:23 | * | Pisuke joined #nim |
07:19:00 | * | PMunch joined #nim |
07:19:03 | * | claudiuinberlin joined #nim |
07:20:18 | * | yglukhov joined #nim |
07:20:23 | * | yglukhov quit (Remote host closed the connection) |
07:20:38 | * | yglukhov joined #nim |
07:37:38 | * | jsgrant quit (Quit: jsgrant) |
07:44:33 | * | jsgrant joined #nim |
07:44:51 | gokr | Hacking some Nim on Raspbian, anyone else using Nim on Rpi? |
07:45:19 | gokr | Seems to work perfectly fine, as I hoped of course, it's just Linux after all. |
07:46:00 | gokr | dom96: Perhaps choosenim should be extended to support it, I suspect it would just work out of the box. |
07:47:09 | * | jsgrant quit (Client Quit) |
07:47:33 | * | jsgrant joined #nim |
07:52:37 | Tanger | gokr: Ooh, what are ya putting on the Rpi? |
07:53:44 | gokr | I am making a little server that will talk MQTT and REST (Jester) - and make calls out to other tools |
07:54:17 | Tanger | Coolsies. How's Jester workin' for ya? I haven't gotten around to checking it out yet |
07:54:53 | gokr | Jester is nice, I haven't done much with it yet - but I consider it to be the "standard" tool for such a job in Nim. |
07:55:14 | gokr | Dominik has kinda proved that it's maintained by now ;) |
07:56:00 | gokr | For MQTT I am using the wrapper of Paho C lib, unfortunately it doesn't do websockets AFAICT. It's also not listed in nimble, which it should be. |
07:56:17 | * | Ven`` joined #nim |
07:56:19 | gokr | There is also a lower level "Nim only" MQTT implementation, but I suspect it may be less hardened ;) |
07:56:41 | * | vendethiel- quit (Ping timeout: 240 seconds) |
07:57:33 | gokr | This job could just as easily be done in nodejs of course, but... well, Nim fits the bill. |
08:02:54 | * | Etheco_ joined #nim |
08:03:34 | * | vlad1777d joined #nim |
08:05:01 | * | Xe quit (Ping timeout: 240 seconds) |
08:05:01 | * | federico3 quit (Ping timeout: 240 seconds) |
08:05:19 | * | federico3 joined #nim |
08:05:35 | * | obadz quit (Ping timeout: 240 seconds) |
08:05:38 | Tanger | Haha, you could use node.js... But it not as fun XD |
08:06:01 | * | Etheco- quit (Ping timeout: 240 seconds) |
08:06:54 | PMunch | What are you using it for? a MQTT/REST bridge? |
08:12:39 | * | Xe joined #nim |
08:19:12 | * | obadz joined #nim |
08:19:50 | gokr | No, the server is meant to offer the "same" API over either MQTT or REST. |
08:20:30 | * | Trustable joined #nim |
08:20:36 | gokr | The work it performs is to compile and flash connected arduinos. |
08:24:34 | * | vendethiel- joined #nim |
08:25:06 | * | Ven`` quit (Ping timeout: 252 seconds) |
08:25:18 | * | claudiuinberlin quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
08:31:12 | * | solitudesf quit (Ping timeout: 246 seconds) |
08:37:29 | * | claudiuinberlin joined #nim |
08:37:38 | * | jsgrant quit (Quit: jsgrant) |
08:41:36 | * | salewski joined #nim |
08:43:13 | salewski | Is there already a way to get the current module name? |
08:44:10 | * | claudiuinberlin quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
08:44:28 | * | jsgrant joined #nim |
08:44:52 | salewski | Have to write connect(app, "activate", example7.activate) is really no big fun for all the examples. |
08:45:33 | salewski | connect(app, "activate", THISMODULE.activate) would be OK for me. |
08:47:26 | salewski | And is there really a good change that the module name prefix will be unneeded when I rewrite the macro with AST API? |
08:48:04 | salewski | s/change/chance/ |
08:48:44 | Araq | no sure but your string hacks are a time bomb, rewrite it already |
08:50:05 | salewski | Yes, but I am not sure how long rewriting will take for me. The macro is not that easy, so maybe it will take a week or longer for me. |
08:51:15 | salewski | So can we regard parseStmt() some sort of deprecated? |
08:52:09 | * | jsgrant quit (Quit: jsgrant) |
08:52:31 | * | jsgrant joined #nim |
08:59:20 | Araq | no, for string interpolation parseExpr/parseStmt are the right tools |
09:00:11 | salewski | OK. |
09:01:10 | * | thomasross quit (Remote host closed the connection) |
09:01:32 | * | salewski quit (Quit: WeeChat 1.9) |
09:01:33 | * | claudiuinberlin joined #nim |
09:01:34 | * | thomasross joined #nim |
09:04:39 | * | claudiuinberlin quit (Client Quit) |
09:05:10 | * | yglukhov_ joined #nim |
09:07:47 | * | yglukhov quit (Ping timeout: 240 seconds) |
09:09:37 | * | kobi7 joined #nim |
09:12:28 | * | solitudesf joined #nim |
09:21:30 | * | Vladar quit (Remote host closed the connection) |
09:22:56 | * | skrylar joined #nim |
09:25:28 | * | Vladar joined #nim |
09:26:21 | skrylar | y'know, the weird thing i noticed with fltk is how light it was |
09:26:37 | skrylar | i made the same program with FLTK once and ported it over to wx. The wx version used 3x the memory and did nothing more. |
09:26:47 | skrylar | Although it did look native, whereas fltk doesn't :\ |
09:27:17 | skrylar | Wonder what extra things wx is doing |
09:33:53 | * | claudiuinberlin joined #nim |
09:40:48 | kobi7 | hi guys, is there a debug for the vscode plugin? if yes, how to enable/use it? |
09:40:54 | FromGitter | <zacharycarter> no |
09:40:59 | FromGitter | <zacharycarter> use lldb / gdb |
09:41:14 | FromGitter | <zacharycarter> why does nimsuggest leak memory and how do we fix it so it does not? |
09:41:18 | FromGitter | <zacharycarter> because it's super annoying |
09:41:24 | kobi7 | i never tried gdb :( |
09:41:47 | gokr | IIRC QtCreator worked nice for debugging, but any gdb based frontend should work. |
09:41:47 | FromGitter | <zacharycarter> kobi7: what os are you on? |
09:41:56 | FromGitter | <zacharycarter> QtCreator can work |
09:42:03 | gokr | It did work nicely earlier. |
09:42:17 | kobi7 | stepping in code lines, setting break points and looking at variables value is enough for a debug experience (for me) |
09:42:26 | gokr | And wasn't that hard to configure to get going - not sure if I blogged about it, or someone else did perhaps. |
09:42:28 | kobi7 | I'm on linux |
09:42:28 | FromGitter | <zacharycarter> you can do all of that with gdb or lldb |
09:42:33 | FromGitter | <zacharycarter> okay so gdb then |
09:42:40 | FromGitter | <zacharycarter> try compiling your program like this |
09:42:48 | gokr | I ran it on Linux - the only thing you will have issues with is... deeper inspection of Nim stuff. |
09:43:00 | gokr | breakpoints and all works nicely. |
09:43:15 | FromGitter | <zacharycarter> nim c --debuginfo --lineDir:on foo.nim |
09:43:17 | gokr | But gdb isn't aware of seq, string etc, so... variable inspection is a bit "so so". |
09:43:28 | kobi7 | gokr, is there something like a gui frontend? |
09:43:43 | gokr | kobi7: QtCreator is exactly that - it's a full blown C++ IDE. |
09:43:59 | gokr | KDE-whateveritscallde worked too IIRC. |
09:44:20 | kobi7 | so you run the cpp binary in it? |
09:44:38 | gokr | One can implement some gdp plugin in Python I think to get proper var inspection too - but I don't think anyone has done it yet. |
09:44:44 | gokr | You debug it, yeah. |
09:44:48 | gokr | It works great. |
09:44:55 | gokr | But was a while since I did it. |
09:45:14 | kobi7 | and you got correct nim-code lines? |
09:45:23 | kobi7 | line numbers |
09:45:27 | gokr | Look at this: https://forum.nim-lang.org/t/1229 |
09:46:09 | gokr | Ah, its in QtCreator proper now - right: https://codereview.qt-project.org/#/c/123629 |
09:46:59 | kobi7 | yay! |
09:47:09 | gokr | Nim support was added officially in 4.1.0: http://blog.qt.io/blog/2016/08/25/qt-creator-4-1-0-released/ |
09:47:22 | gokr | But... filcuc is not around here I see. It's his work. |
09:47:51 | gokr | Now that you bring it up... I will try it next week :) |
09:48:07 | FromGitter | <zacharycarter> my recommendation is use gdb and learn how to debug with the commandl ine |
09:48:19 | FromGitter | <zacharycarter> you may not always have qt creator at your disposal but you'll most likely have gdb | lldb |
09:48:28 | FromGitter | <zacharycarter> then use something like QtCreator if you must have a visual debugger |
09:48:32 | gokr | Sure, agreed. |
09:48:37 | FromGitter | <zacharycarter> I get along fine without one, and QtCreator / the QtFramework is a huge install |
09:48:38 | FromGitter | <zacharycarter> fyi |
09:48:39 | gokr | But... it's so painful :) |
09:48:40 | skrylar | zacharycarter: is it stuff getting stored in caches? |
09:49:05 | FromGitter | <zacharycarter> skrylar maybe - I haven't dug through the nimsuggest source I guess i'll do that now |
09:49:31 | skrylar | nods |
09:49:42 | skrylar | i would suspect caches before leaks. not that gcs make leaks impossible but |
09:50:08 | skrylar | one complaint i always have with gc apps is they don't act like other programs might exist, so they just kinda all use memory and hope the OS magically solves it |
09:50:24 | FromGitter | <zacharycarter> right |
09:50:41 | * | solitudesf quit (Ping timeout: 240 seconds) |
09:50:48 | FromGitter | <zacharycarter> well hopefully araq finishes that crazy algorithm implementation he was going to implement and allows the gc to be turned off |
09:50:55 | FromGitter | <zacharycarter> I can't remember wtf it was called |
09:51:00 | skrylar | arc? |
09:51:09 | Araq | memory regions? |
09:51:41 | FromGitter | <zacharycarter> no |
09:51:46 | skrylar | i don't have issues with the gc tho. i turn it off at the start and just have the incremental run between frames |
09:52:04 | FromGitter | <zacharycarter> I'll try to find the document again |
09:52:19 | FromGitter | <zacharycarter> Araq you said it was just an experimental thing you were looking into |
09:52:32 | skrylar | he also said he wanted r-trees for something :p |
09:52:36 | FromGitter | <zacharycarter> and you linked to a paper by someone about something - I know that's super helpful / |
09:53:00 | * | mal`` quit (Quit: Leaving) |
09:53:05 | FromGitter | <zacharycarter> basically what are the plans for going GCless with Nim? or are there any? |
09:53:33 | skrylar | i always thought turning the gc off was more about microcode than a general goal |
09:53:46 | * | gokr quit (Remote host closed the connection) |
09:54:17 | FromGitter | <zacharycarter> I don't know what the polls showed - I think I remember Araq saying it sounded like most people were fine with the current GC options - I for one would like the ability to forego GC all together |
09:54:34 | FromGitter | <zacharycarter> and I think the other options mentioned in the poll were like ARC, and then maybe some other options too |
09:54:57 | skrylar | i don't believe gcs are inherently evil |
09:55:04 | skrylar | they just need OS support >:| |
09:55:14 | Araq | well... |
09:55:22 | FromGitter | <zacharycarter> :popcorn: |
09:56:08 | skrylar | i saw some whitepaper come across that was suggesting an ocaml GC was faster than boost pointers. and read some old lisp things that were talking about being more aggressive with code gen when they didn't have to maintain the whole deref logic |
09:56:37 | skrylar | and most complaints about a GC are that they are acting randomly instead of on predictable cue |
09:57:20 | skrylar | like arc is continuously having to stop and do atomic writes |
09:57:40 | * | mal`` joined #nim |
09:58:00 | skrylar | but i'm not a GC god so, dunno. |
09:58:06 | Araq | I still want memory regions but to make them safe the overhead is comparable to a good GC |
09:58:17 | FromGitter | <zacharycarter> wow |
09:58:46 | Araq | and they are never a "program and forget" solution |
09:58:53 | FromGitter | <zacharycarter> didn't realize it was that much work |
09:58:55 | FromGitter | <zacharycarter> right |
09:59:12 | Araq | if we go for unsafe regions things are smooth though :-) |
09:59:44 | FromGitter | <zacharycarter> so unsafe memory regions are already available and usable right? |
09:59:54 | Araq | kind of. |
10:00:02 | Araq | bootstrapping works |
10:00:09 | Araq | takes 2GB |
10:00:46 | FromGitter | <zacharycarter> dayum |
10:02:20 | FromGitter | <zacharycarter> You know what's super annoying? I'm trying to compile zengine for emscripten and remove all references to OS packages / shit that emscripten can't handle. But I just get errors like - ⏎ ⏎ ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=59c4dfac7b7d98d30d24e1a8] |
10:03:31 | FromGitter | <zacharycarter> can't tell where the bad import is |
10:03:45 | skrylar | speaking of zengine |
10:04:16 | skrylar | i am currently on a mind trip trying to understand sparse virtual textures and these weird adaptively sampled distance fields |
10:04:28 | skrylar | they seem like they would go together in some horrifying-yet-awesome way |
10:05:04 | FromGitter | <zacharycarter> had never heard of sparse virtual textures before |
10:05:09 | * | madmalik joined #nim |
10:05:10 | FromGitter | <zacharycarter> may have to give this a go |
10:05:13 | skrylar | its carmacks megatexture |
10:05:21 | skrylar | http://www.silverspaceship.com/src/svt/ |
10:05:42 | FromGitter | <zacharycarter> yeah was just reading that page |
10:05:57 | skrylar | there's also Mischief which allegedly uses these weird distance field octrees |
10:06:03 | skrylar | their gimmick is you can zoom infinitely and sketch |
10:06:21 | skrylar | i guess they're recording strokes as vector lines and then putting those in some weird old data format |
10:07:23 | skrylar | i remember back in like 2000 having dreams of nurbs/bezier models because that was when people were doing these model updates for deus ex. and it was like you know if anyone invested R&D in those you could just set your game to potato mode or something |
10:07:35 | skrylar | i think they're kinda going that way with substance now |
10:07:38 | * | jsgrant quit (Quit: jsgrant) |
10:07:57 | FromGitter | <zacharycarter> yeah I think you're right |
10:08:02 | skrylar | procedural textures are taking off, a little |
10:08:34 | skrylar | Saurbraten actually stored their maps like this now that i recall |
10:08:49 | FromGitter | <zacharycarter> yup! |
10:08:53 | skrylar | it was an octree with cube deformation edges and could subdivide. that seem very similar to what ADFs are |
10:09:20 | skrylar | anyway sorry. wall of texted again |
10:11:18 | skrylar | https://graphics.stanford.edu/courses/cs468-03-fall/Papers/frisken00adaptively.pdf |
10:12:30 | * | jsgrant joined #nim |
10:14:01 | skrylar | megatexture didn't really work that well though, as fascinating as it is |
10:14:28 | * | kobi7 quit (Ping timeout: 240 seconds) |
10:14:45 | * | kobi7 joined #nim |
10:15:10 | * | dddddd joined #nim |
10:17:38 | FromGitter | <Yardanico> I see araq is doing some things with strings and codegen :P |
10:24:34 | skrylar | zacharycarter: now here's a pipedream for you. if there was a way for the UVs to survive conversion to ADFs, and i donno if there is or not, you could *theoretically* just cram any random scene in one |
10:24:42 | skrylar | would still be a static scene, but hey. |
10:24:59 | FromGitter | <zacharycarter> would be cool |
10:25:11 | skrylar | well in the paper they talk about you can simplify geometry by just not recursing |
10:25:47 | skrylar | it might still result in some weird geometry tho, as LOD algos always do |
10:25:57 | kobi7 | hmm, I stumbled upon: https://marketplace.visualstudio.com/items?itemName=ms-vscode.cpptools |
10:28:08 | FromGitter | <Yardanico> yeah you can use that |
10:28:25 | FromGitter | <Yardanico> also I highly recommend this - https://github.com/cooldome/Nim-gdb |
10:29:18 | FromGitter | <zacharycarter> ugh still not sure how to diagnose these emscripten compilation errors |
10:31:02 | FromGitter | <Yardanico> take a look at this |
10:31:03 | FromGitter | <Yardanico> https://github.com/Jipok/Nim-SDL2-and-Emscripten/blob/master/nim.cfg |
10:31:16 | FromGitter | <Yardanico> you should use "emcc" compiler btw |
10:32:09 | FromGitter | <zacharycarter> I am |
10:32:50 | FromGitter | <Yardanico> well try adding "-Iemscripten" to passC and passL |
10:33:06 | FromGitter | <zacharycarter> I don't think that's my issue |
10:33:14 | FromGitter | <zacharycarter> something in my code is importing modules emscripten doesn't support I imagine |
10:33:21 | FromGitter | <Yardanico> no |
10:33:24 | FromGitter | <Yardanico> stdbool is fine |
10:33:26 | FromGitter | <Yardanico> it should work |
10:33:39 | kobi7 | Is there something like a makefile for nim? IOW, some preferred nim way to build? |
10:33:54 | FromGitter | <zacharycarter> oh weird okay |
10:34:23 | FromGitter | <Yardanico> kobi7: yourproject.nim.cfg or yourproject.nims |
10:34:29 | FromGitter | <zacharycarter> GOOD CALL @Yardanico |
10:34:33 | FromGitter | <Yardanico> ? |
10:34:35 | FromGitter | <zacharycarter> it wasn't picking up my nim.cfg |
10:34:39 | FromGitter | <zacharycarter> thank you! |
10:35:18 | euantor | kobi7: Usually just use Nimble and do `nimble build` |
10:35:40 | FromGitter | <Yardanico> yeah, nimble should be sufficient |
10:35:55 | euantor | or `nimble install` for a release build |
10:36:01 | FromGitter | <Yardanico> but sometimes you need to define some things |
10:36:02 | FromGitter | <Yardanico> like -d:ssl |
10:36:06 | FromGitter | <Yardanico> does nimble file allow that? |
10:36:43 | euantor | you can put that in a `nim.cfg`, not sure about a `.nimble` |
10:37:06 | FromGitter | <Yardanico> but yeah, kobi7, .nimble file + nim.cfg is higher-level than makefile :) |
10:37:08 | FromGitter | <Yardanico> so easier to use |
10:37:13 | kobi7 | Thanks, Yardanico |
10:37:36 | kobi7 | how can I choose the output binary filename? |
10:37:48 | euantor | use the `-o` option |
10:38:00 | euantor | or set the `bin` key in the `.nimble` file |
10:38:14 | kobi7 | thanks, it doesn't show up in `nim --help` |
10:41:38 | FromGitter | <zacharycarter> I'm getting there... |
10:41:51 | FromGitter | <zacharycarter> (https://files.gitter.im/nim-lang/Nim/e6Dg/Screen-Shot-2017-09-22-at-6.41.33-AM.png) |
10:42:14 | FromGitter | <zacharycarter> it's creating a window! |
10:47:05 | kobi7 | ok, so I hoped I could set breakpoints in the nim file, and the cpp extension for vscode would stop at the right point. |
10:47:32 | kobi7 | it currently just runs gdb, but it's likely i don't know yet how to configure it |
10:52:00 | FromGitter | <Yardanico> Yes you can do that |
10:52:13 | FromGitter | <Yardanico> You can set breakpoints |
10:57:36 | * | rusua joined #nim |
10:59:59 | * | fastrom joined #nim |
11:03:41 | skrylar | i think i understand the concept of these things now. |
11:03:52 | skrylar | what i still don't yet understand is how you turn distance fields in to geometry o.O |
11:10:01 | * | claudiuinberlin quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
11:11:53 | * | claudiuinberlin joined #nim |
11:12:30 | skrylar | zacharycarter: i don't think they actually DO. the paper talks about a raytracer. hrm |
11:19:16 | * | fastrom quit (Ping timeout: 255 seconds) |
11:19:17 | * | vlad1777d quit (Ping timeout: 240 seconds) |
11:19:25 | skrylar | Yea, they don't. So you have to use marching cube/tetra to get geometry back out. And those make some gnarly geometry. |
11:19:29 | skrylar | bah |
11:22:01 | * | Trustable quit (Remote host closed the connection) |
11:24:08 | * | fastrom joined #nim |
11:32:07 | * | vlad1777d joined #nim |
11:34:32 | FromGitter | <mratsim> @Yardanico You can do switch("define","ssl") in a nimble file but only for tasks, it doesn't work on "import yourproject" or I didn't find it. |
11:43:50 | * | Yardanico joined #nim |
11:48:02 | * | vendethiel- quit (Ping timeout: 260 seconds) |
11:52:28 | * | ShalokShalom_ joined #nim |
11:53:24 | * | endragor quit (Remote host closed the connection) |
11:55:45 | * | ShalokShalom quit (Ping timeout: 252 seconds) |
11:57:24 | * | dhalinar quit (Ping timeout: 252 seconds) |
11:58:38 | * | claudiuinberlin quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
12:02:40 | * | claudiuinberlin joined #nim |
12:03:32 | * | Snircle joined #nim |
12:07:52 | * | vlad1777d quit (Ping timeout: 260 seconds) |
12:11:23 | * | fastrom quit (Ping timeout: 255 seconds) |
12:11:50 | * | endragor joined #nim |
12:16:17 | * | endragor quit (Ping timeout: 240 seconds) |
12:17:30 | * | kobi7 quit (Quit: Leaving) |
12:18:07 | * | claudiuinberlin quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
12:19:12 | * | claudiuinberlin joined #nim |
12:21:36 | * | claudiuinberlin quit (Client Quit) |
12:23:53 | skrylar | hm |
12:24:03 | skrylar | pondering a fltk wrapper for nim |
12:24:21 | * | Yardanico quit (Ping timeout: 240 seconds) |
12:24:21 | skrylar | its better than libui at least, lol |
12:24:57 | skrylar | libui could have been pretty good actually, it just lacked some really basic stuff |
12:25:14 | * | Yardanico joined #nim |
12:26:03 | FromGitter | <zacharycarter> skrylar: maybe consider contributing to NiGUI ? |
12:28:14 | skrylar | i just googled that |
12:28:37 | skrylar | i could, although that puts me back in the same pit i was trying to avoid regarding wrapping gtk3's bajillion headers |
12:28:58 | Yardanico | well this is not entirely a wrapper |
12:29:05 | Yardanico | it wraps only low-level stuff of winapi and gtk3 |
12:29:17 | Yardanico | and does other stuff by itself |
12:29:20 | Yardanico | e.g. layouts |
12:29:29 | skrylar | i keep meaning to do miglayout in nim |
12:29:35 | skrylar | i almost did it in Go once |
12:30:00 | skrylar | http://www.migcalendar.com/miglayout/cheatsheet.html |
12:30:53 | skrylar | between mig and hirise you don't need any other layout stuff |
12:31:06 | FromGitter | <zacharycarter> I think the plan is to eventually ditch gtk3 |
12:31:08 | FromGitter | <zacharycarter> for NiGUI |
12:31:09 | Yardanico | omg this website has so small font size :P |
12:31:11 | FromGitter | <zacharycarter> and go native |
12:31:18 | Yardanico | what do you mean by "native" ? :) |
12:31:27 | skrylar | gtk is native to half of linux |
12:31:36 | Yardanico | and "winapi" is native to all windows |
12:31:49 | FromGitter | <zacharycarter> like for osx I don't think he wants to use gtk |
12:32:01 | skrylar | they drink cocoa over there. |
12:32:07 | FromGitter | <zacharycarter> aye |
12:32:13 | skrylar | i miss being a mac nerd. |
12:33:02 | skrylar | unfortunately the imac on my desk now is only good for office work. it won't run Substance or any shader 3 stuff. |
12:33:27 | Yardanico | install windows on it ? :P |
12:33:32 | FromGitter | <zacharycarter> heh |
12:33:37 | Yardanico | or it has an old GPU? |
12:33:40 | skrylar | old gpu |
12:33:48 | skrylar | the box is 9 years old |
12:33:50 | Yardanico | oh |
12:34:45 | skrylar | hirise is neat but i still don't grok the math. |
12:35:01 | skrylar | they're basically modeling constraints in a matrix and doing some thing on it to solve a linear system |
12:35:27 | * | Yardanico quit (Remote host closed the connection) |
12:35:45 | skrylar | but i used somethintg like it in freepascal/lazarus, it's quite nice. you just like, have your text labels auto-size (DPI scaling, etc) and then the whole UI is specified relative to everything |
12:35:54 | skrylar | "this is 3px to the right of that label" |
12:36:25 | * | gmpreussner quit (Quit: kthxbye) |
12:36:58 | skrylar | Anything that isn't one of those two, basically, is Wrong(tm). Not because I hate fun, but absolute positioning doesn't DPI/retina scale |
12:37:16 | skrylar | and those weird box sizers require a lot of BS |
12:39:17 | * | gmpreussner joined #nim |
12:40:13 | FromGitter | <zacharycarter> interesting - it looks like I can use the OpenGL bindings with emscripten |
12:40:17 | FromGitter | <zacharycarter> I'm just limited to a 2.0 context |
12:42:31 | skrylar | really? i thought webgl was 3 |
12:42:35 | skrylar | although egl is 2 so i guess so |
12:42:40 | skrylar | webgl is basically egl |
12:42:44 | FromGitter | <zacharycarter> yeah |
12:42:59 | skrylar | I continue to say whoever is propagating this should be trout slapped viciously. |
12:43:09 | * | claudiuinberlin joined #nim |
12:43:16 | skrylar | "i will not perform math intensive operations in a scripting language and shove it on to the gpu slowly" |
12:43:16 | FromGitter | <zacharycarter> basically if I don't do - glSetAttribute(SDL_GL_CONTEXT_MAJOR_VERSION, VERISON_NUMBER) |
12:43:28 | FromGitter | <zacharycarter> it creates a 2.0 context automatically |
12:43:40 | skrylar | it creates whatever context the OS decides you get iirc |
12:43:47 | skrylar | which on a mac is going to be 3.0 |
12:44:24 | FromGitter | <zacharycarter> it def doesn't work with a 3.0 context |
12:45:37 | skrylar | and once again krita has decided to be an unstable piece of crap |
12:45:40 | skrylar | oh well ._. |
12:46:01 | * | claudiuinberlin quit (Client Quit) |
12:51:35 | FromGitter | <krux02> isn't that the kde paint clone? |
12:51:56 | FromGitter | <krux02> how about grafx2? |
12:58:08 | skrylar | it used to be a gimp clone, now its a decently respected paint program |
12:58:18 | skrylar | except somehow i always get a broken version on linux |
12:58:30 | skrylar | it worked fine but now it segfaults when you try to save files :v |
12:59:03 | FromGitter | <krux02> hmm |
12:59:11 | FromGitter | <krux02> I mixed up krita and pinta |
12:59:16 | Vladar | what version? Krita works fine for me for a while |
12:59:17 | FromGitter | <krux02> pinta is a paint clone |
12:59:47 | skrylar | Vladar, all of them. i tried a git version, there's some crash in libkritastore |
12:59:56 | skrylar | i'll see if a reboot fixes it later, done with art for now |
13:00:07 | FromGitter | <krux02> I personally think gimp is unnecessarily complicated with too much loading time, I have no opinion about krita, but mypaint is nice and simple |
13:00:23 | FromGitter | <krux02> and I like grafx2, but I am no artist |
13:00:43 | FromGitter | <krux02> so don't put too much weight in my opinion :P |
13:01:05 | Vladar | as for _painting_ Krita is the leader if we are talking linux-wise, |
13:01:18 | skrylar | mypaint is what i used because it has always worked |
13:01:39 | skrylar | i had a friend who was trying to get in to krita and it kept dying at random moments |
13:01:59 | Vladar | mypaint is not bad, but dat krita's brush engine… |
13:02:10 | FromGitter | <krux02> is there a way to translate an identifier into a string within a template? |
13:02:11 | skrylar | krita is using mypaints engine lol |
13:02:13 | Araq | that is a nice one: https://github.com/nim-lang/Nim/issues/6416 |
13:02:22 | Araq | krux02: astToStr |
13:02:31 | FromGitter | <krux02> thanks |
13:02:35 | Vladar | skrylar, do you have a source for this? |
13:02:44 | * | ShalokShalom_ is now known as ShalokShalom |
13:02:51 | Araq | maybe we should get rid of exceptions :P |
13:03:35 | skrylar | Vladar, https://github.com/KDE/krita/search?utf8=✓&q=mypaint&type= well, they used to. |
13:03:51 | skrylar | I remember in earlier versions you could select 'mypaint brush' as a brush engine when editin them |
13:05:00 | FromGitter | <krux02> I don't really use exceptions, so I would not miss them |
13:05:05 | FromGitter | <zacharycarter> +1 |
13:05:20 | skrylar | do you want every call to be if geterr hell |
13:05:31 | FromGitter | <krux02> nope |
13:05:54 | FromGitter | <krux02> I think a result type for functions that might fails does handle it pretty well |
13:06:07 | FromGitter | <krux02> Result[string] |
13:06:23 | skrylar | gonna bog the cpu down in cmp's doing that :\ |
13:06:29 | FromGitter | <krux02> result would either be a string, or the exception as a value |
13:06:52 | FromGitter | <krux02> if you try to get the value when it actually is an exception, then it would print the stack trace and exit |
13:07:05 | * | mwbrown quit (Ping timeout: 240 seconds) |
13:07:31 | FromGitter | <krux02> or create a dump for the debugger |
13:07:46 | FromGitter | <krux02> or whatever is best for workflow |
13:08:11 | * | adeohluwa joined #nim |
13:08:14 | adeohluwa | Im back again |
13:08:23 | skrylar | wb |
13:08:30 | FromGitter | <krux02> skrylar: I don't think so |
13:08:35 | adeohluwa | I need something like beautiful parser for nim language |
13:08:35 | FromGitter | <krux02> it's just a boolean chelk |
13:08:38 | FromGitter | <krux02> check |
13:08:44 | adeohluwa | :) |
13:09:04 | FromGitter | <krux02> adeohluwa: what do you mean? |
13:09:08 | FromGitter | <krux02> parse stuff? |
13:09:24 | adeohluwa | yes |
13:09:27 | adeohluwa | parse html |
13:09:43 | adeohluwa | for a , h4 & the likes using. CSS selector |
13:09:46 | adeohluwa | or xpath |
13:09:50 | * | mwbrown joined #nim |
13:12:26 | adeohluwa | :( |
13:12:31 | adeohluwa | |
13:13:08 | * | claudiuinberlin joined #nim |
13:13:24 | * | claudiuinberlin quit (Client Quit) |
13:13:47 | * | jjido joined #nim |
13:13:49 | adeohluwa | helllllllpppp |
13:14:01 | FromGitter | <krux02> I found htmltidy |
13:14:05 | FromGitter | <krux02> but it is a C library |
13:14:10 | adeohluwa | :( |
13:14:13 | FromGitter | <krux02> C can easily be wrapped |
13:14:25 | adeohluwa | I'm not skilled in programming-fu |
13:14:32 | adeohluwa | C-fu |
13:14:38 | adeohluwa | nim has HTML parser |
13:14:45 | adeohluwa | but its scanty on examples |
13:15:10 | adeohluwa | I find myself quickly going to see Rosetta code for fast examples |
13:15:26 | FromGitter | <krux02> well there is always a time to become skilled at programming-fu |
13:15:42 | FromGitter | <krux02> I don't use rosetta code at all |
13:16:45 | adeohluwa | are there some incantations I need to chant on the terminal? |
13:18:31 | * | dhalinar joined #nim |
13:22:39 | FromGitter | <Yardanico> Ah |
13:22:49 | FromGitter | <Yardanico> If you want to use css selectors |
13:22:56 | FromGitter | <Yardanico> There's a Nim library for that |
13:23:18 | FromGitter | <Yardanico> https://github.com/GULPF/nimquery/ |
13:30:47 | * | claudiuinberlin joined #nim |
13:31:46 | FromGitter | <Yardanico> you could easily find it in nimble |
13:32:39 | FromGitter | <Yardanico> or not :P |
13:32:47 | FromGitter | <Yardanico> ah yes |
13:32:54 | FromGitter | <Yardanico> "nimble install nimquery" |
13:34:07 | FromGitter | <Yardanico> and yes, nim examples at rosetta are very outdated |
13:34:18 | FromGitter | <Yardanico> many of them still have typeless arguments :) |
13:37:46 | FromGitter | <mratsim> untyped template outputting a body do not have access to global var? |
13:38:11 | * | vlad1777d joined #nim |
13:39:15 | FromGitter | <Yardanico> they do |
13:39:29 | FromGitter | <Yardanico> with "bind" or a dirty template :) |
13:39:37 | FromGitter | <Yardanico> I may be wrong though |
13:40:11 | FromGitter | <mratsim> I’ll try with mixin |
13:40:12 | * | claudiuinberlin quit (Quit: Textual IRC Client: www.textualapp.com) |
13:40:24 | FromGitter | <Yardanico> ah |
13:40:27 | FromGitter | <Yardanico> you don't even need "bind" |
13:40:37 | FromGitter | <Yardanico> ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=59c512d5bac826f054e9d9c3] |
13:40:39 | FromGitter | <Yardanico> it works |
13:40:53 | FromGitter | <Yardanico> or it's not like this in your code? |
13:41:10 | FromGitter | <mratsim> actually it’s because I forgot an include on my server :/ |
13:41:56 | * | rauss joined #nim |
13:42:03 | FromGitter | <mratsim> (I have a headless machine with a Cuda GPU, so I code on my machine and pass update through, but sometimes I forgot things) |
13:42:38 | FromGitter | <Yardanico> you can use cuda on your mac, no? |
13:44:16 | FromGitter | <Yardanico> http://www.nvidia.com/object/mac-driver-archive.html |
13:44:22 | FromGitter | <Yardanico> http://www.nvidia.com/object/macosx-cuda-8.0.90-driver.html |
13:46:37 | * | endragor joined #nim |
13:46:42 | * | solitudesf joined #nim |
13:47:26 | * | endragor_ joined #nim |
13:51:17 | * | endragor quit (Ping timeout: 255 seconds) |
13:57:35 | * | PMunch quit (Quit: Leaving) |
14:02:07 | * | endragor_ quit (Remote host closed the connection) |
14:02:42 | * | endragor joined #nim |
14:05:21 | * | werwer joined #nim |
14:05:34 | * | werwer quit (Client Quit) |
14:06:39 | * | vlad1777d quit (Ping timeout: 252 seconds) |
14:07:34 | * | endragor quit (Ping timeout: 264 seconds) |
14:07:34 | FromGitter | <mratsim> The last mac with a nvidia GPU is from 2013 ;) |
14:08:12 | FromGitter | <Yardanico> aand ? :) |
14:08:13 | FromGitter | <mratsim> And buying a enclosure for external GPU is something like €500 |
14:09:10 | FromGitter | <Yardanico> well now you see the good side of PCs and windows laptops :) |
14:12:00 | skrylar | windows laptops don't have egpu tho |
14:13:22 | adeohluwa | Yardanico: yeah you are right but its pretty easy to mentally edit them & get going... |
14:15:42 | FromGitter | <Yardanico> skrylar: I mean "all laptops which are used with windows" by "windows laptops" |
14:15:48 | FromGitter | <Yardanico> not surface laptops |
14:17:00 | FromGitter | <Yardanico> ah, you're about egpu |
14:17:15 | FromGitter | <Yardanico> well no, some laptops have egpu support |
14:19:07 | * | vlad1777d joined #nim |
14:23:34 | * | skrylar quit (Remote host closed the connection) |
14:27:44 | * | solitudesf quit (Ping timeout: 255 seconds) |
14:35:01 | FromGitter | <mratsim> Linux > Windows for computation on GPU and Deep Learning anyway :P |
14:38:41 | Araq | if you say so. |
14:38:53 | Araq | I wouldn't touch GPUs on Linux. |
14:39:19 | FromGitter | <Yardanico> @mratsim my main point was: there's better hardware in cheaper laptops/pcs :) |
14:39:52 | FromGitter | <Yardanico> than in Mac Books/iMacs |
14:41:03 | FromGitter | <mratsim> Oh for games linux is … hum no comment… but for scientific/numerical computing there is much less overhead than on Windows, the difference can be days for month-long computation. |
14:41:03 | federico3 | anyway most GPU computation is not done on laptop or desktops |
14:45:33 | * | vlad1777d quit (Remote host closed the connection) |
14:46:21 | * | nsf quit (Quit: WeeChat 1.9) |
14:55:42 | * | vlad1777d joined #nim |
15:00:22 | * | gangstacat quit (Quit: Ĝis!) |
15:02:35 | FromGitter | <Yardanico> ehmn |
15:02:36 | FromGitter | <Yardanico> https://github.com/nim-lang/Nim/issues/6417#issuecomment-331461294 |
15:02:49 | FromGitter | <Yardanico> it seems that asynchttpserver is not very crash-prone :) |
15:03:34 | dom96 | Yeah, and judging by how long it took for this issue to be reported this really does not matter |
15:03:42 | dom96 | (You should be running it behind nginx anyway) |
15:04:06 | FromGitter | <Yardanico> well maybe put a warning in docs? |
15:04:50 | FromGitter | <Yardanico> "Don't use this module in production without apache/nginx, because it can't handle malformed HTTP requests" |
15:04:52 | * | enthus1ast- joined #nim |
15:04:53 | dom96 | There already is a warning in the docs... |
15:04:59 | enthus1ast- | hey ho |
15:05:12 | yglukhov_ | Yardanico: i don't think that closing client socket in the handler is a common use-case. for me its not clear whats the intention of it |
15:05:30 | FromGitter | <Yardanico> well it's not only about closing client socket |
15:05:36 | federico3 | what was the library to write Nim on a GPU? nimcuda? |
15:05:40 | FromGitter | <Yardanico> https://github.com/nim-lang/Nim/issues/6416#issuecomment-331458996 |
15:05:43 | enthus1ast- | yglukhov_: most of the lines crashes it withoth the line |
15:06:08 | enthus1ast- | have a bad hand cant code :*( |
15:06:38 | * | vivus joined #nim |
15:07:14 | yglukhov_ | enthus1ast, Yardanico: oh ok then its pretty critical imo... |
15:08:38 | enthus1ast- | the closing was a simulation of another piece of code that does that and keept crashes. |
15:08:42 | yglukhov_ | dunno if nginx will protect against content-length 13078194637136627572 |
15:11:11 | * | xet7 quit (Quit: Leaving) |
15:11:56 | * | relax joined #nim |
15:17:27 | dom96 | yglukhov_: ooh, I see you've written an article on Reel Valley. Nice. |
15:17:34 | dom96 | HN material? :) |
15:18:22 | * | vlad1777d quit (Ping timeout: 264 seconds) |
15:19:10 | yglukhov_ | dom96: dunno... if you read it and think its worth hn... |
15:19:15 | FromGitter | <Yardanico> link please ? :) |
15:19:27 | FromGitter | <Yardanico> ah |
15:19:27 | FromGitter | <Yardanico> https://yglukhov.github.io/Making-ReelValley-Overview/ |
15:20:18 | dom96 | Your "Nim" link points to Crystal's website D: |
15:20:31 | dom96 | But yeah, I think it's worth a try to submit it :) |
15:21:59 | yglukhov_ | dom96: thanks, fixed. |
15:23:22 | yglukhov_ | well... never submitted anything to hn. can anyone do it for me please? =) |
15:24:40 | * | xet7 joined #nim |
15:25:05 | dom96 | sure, i'll do it |
15:25:11 | * | vlad1777d joined #nim |
15:26:06 | dom96 | need a good title |
15:26:23 | dom96 | Not that your title isn't good, but I think it needs to mention Nim :) |
15:26:35 | dom96 | "The making of Reel Valley, a game built using Nim"? |
15:27:10 | FromGitter | <Yardanico> well it's in the article :) |
15:28:27 | dom96 | Yardanico: what is? |
15:28:53 | FromGitter | <Yardanico> ". The game is done in almost 100% pure Nim" |
15:29:27 | dom96 | Yes, but people have no idea what Reel Valley is on HN |
15:29:31 | dom96 | Some of them will know what Nim is |
15:29:35 | * | vlad1777d quit (Ping timeout: 240 seconds) |
15:29:49 | dom96 | yglukhov_: what are your thoughts about this title? |
15:30:23 | yglukhov_ | can't you just set the proper title for hn post? |
15:30:47 | dom96 | Like I said, I think it should mention Nim |
15:31:15 | yglukhov_ | i mean the hn link shoul definitely mention nim, just not the title on my page |
15:31:25 | yglukhov_ | is that waht you mean? |
15:31:39 | dom96 | yeah, you don't need to change the title of your blog post |
15:31:51 | yglukhov_ | ok cool |
15:31:54 | dom96 | I'm just asking if you're happy with that title for the submission |
15:33:49 | dom96 | So are you? |
15:35:24 | dom96 | yglukhov_: ^ |
15:35:42 | yglukhov_ | dom96: sure, its fine |
15:35:53 | dom96 | ok submitted |
15:35:59 | yglukhov_ | thanks man |
15:36:01 | dom96 | You can see it here: https://news.ycombinator.com/newest |
15:36:16 | dom96 | I'll tweet about it too :) |
15:36:41 | FromGitter | <Yardanico> upvoted |
15:37:06 | FromGitter | <Yardanico> is hackernews something like reddit, but more IT related ? :) |
15:37:22 | dom96 | More startup related |
15:37:43 | dom96 | It's literally run by Y Combinator (a startup accelerator) |
15:38:00 | yglukhov_ | bbl |
15:40:06 | FromGitter | <Yardanico> free karma for dom :P |
15:40:41 | dom96 | muahaha |
15:41:23 | FromGitter | <Yardanico> btw, who is https://www.reddit.com/user/_Sharp_ ? :) |
15:41:30 | FromGitter | <Yardanico> he posts a lot of things in nim subreddit |
15:42:07 | * | yglukhov_ quit (Remote host closed the connection) |
15:42:56 | * | vlad1777d joined #nim |
15:43:48 | * | vivus quit (Ping timeout: 246 seconds) |
15:44:03 | * | gangstacat joined #nim |
15:44:57 | dom96 | 5 points already, I feel like it should be on the front page already |
15:45:45 | * | yglukhov_ joined #nim |
15:46:18 | FromGitter | <Yardanico> it's not yet :) |
15:47:28 | * | BigEpsilon quit (Ping timeout: 240 seconds) |
15:48:24 | dom96 | I submitted to r/programming too |
15:48:53 | * | jjido quit (Read error: Connection reset by peer) |
15:49:04 | FromGitter | <Yardanico> link? |
15:49:48 | dom96 | https://www.reddit.com/r/programming/new/ |
15:50:25 | * | yglukhov_ quit (Ping timeout: 248 seconds) |
15:51:03 | * | endragor joined #nim |
15:51:55 | * | endragor_ joined #nim |
15:52:10 | * | jjido joined #nim |
15:55:05 | * | gangstacat quit (Quit: Ĝis!) |
15:55:17 | * | endragor quit (Ping timeout: 240 seconds) |
15:57:07 | * | relax quit (Ping timeout: 260 seconds) |
15:57:54 | FromGitter | <ephja> "almost 100% Nim" ain't good enough! |
16:00:37 | * | gangstacat joined #nim |
16:01:38 | * | solitudesf joined #nim |
16:03:33 | * | vivus joined #nim |
16:04:44 | FromGitter | <mratsim> > *<federico3>** what was the library to write Nim on a GPU? nimcuda? ⏎ ⏎ nimcuda is on nimble and gives you binding to every routines nvidia created (matrix multiplication, fast fourier transform, memory allocation, etc …) ⏎ cudanim is just on Github and seems to be research on metaprogramming custom GPU kernels with pure Nim code and AST manipulation. ⏎ ... [https:/ |
16:04:44 | FromGitter | ... /gitter.im/nim-lang/Nim?at=59c5349bc101bc4e3af8e86d] |
16:06:09 | FromGitter | <Yardanico> you can disable optimizations with pragmas, no? |
16:08:16 | FromGitter | <mratsim> when I said optimisation it was replacing a + b by a pointer to host memory or things like that. cudanim found a clever way to avoid that but to be honest i couldn’t understand all of what was going on in their code |
16:10:56 | * | TjYoco joined #nim |
16:20:34 | dom96 | well that's disappointing. It didn't make it to the front page. |
16:21:19 | subsetpark | dom96: did you submit to lobsters? |
16:21:25 | subsetpark | hn is a wasteland |
16:21:25 | dom96 | nope |
16:21:33 | subsetpark | i can do it if you like |
16:21:36 | dom96 | go for it |
16:23:10 | subsetpark | https://lobste.rs/s/qy40hj/making_reelvalley_web_game_written_nim |
16:25:11 | dom96 | lobste.rs always felt way too quiet for my taste |
16:26:27 | * | Jesin joined #nim |
16:27:53 | * | dhalinar quit (Remote host closed the connection) |
16:28:48 | subsetpark | Definitely less active. But I find the level of discourse so much higher. Not only are people generally better commenters, but specifically it's lacking that hivemind trend-chasing that HN is SO guilty of |
16:29:13 | subsetpark | There's much less FUD and blindly repeating received ideas |
16:32:40 | * | astronavt joined #nim |
16:49:01 | * | zachk joined #nim |
16:52:47 | * | jjido quit (Ping timeout: 248 seconds) |
16:52:55 | FromGitter | <Jipok> Hi. I recently found this project. It can serve as good gui for small utilities ⏎ https://github.com/DeXP/nuklear_cross |
16:59:34 | FromGitter | <Yardanico> yeah, I saw post on habrahabr |
16:59:54 | FromGitter | <Yardanico> but btw, imgui does the same thing as nuklear+ |
17:00:15 | FromGitter | <Yardanico> well there are predefined backends for imgui |
17:01:48 | FromGitter | <Yardanico> @Jipok make a nim wrapper for it :) |
17:03:12 | FromGitter | <Yardanico> there's already a nuklear wrapper |
17:03:40 | FromGitter | <zacharycarter> ehhhh not a fan of nuklear_cross |
17:03:50 | FromGitter | <zacharycarter> and yes nuklear bindings exist already |
17:03:58 | * | dhalinar joined #nim |
17:04:10 | FromGitter | <Yardanico> @zacharycarter why not? |
17:04:37 | FromGitter | <zacharycarter> because it's just various backends for nuklear which are easy enough to write yourself |
17:04:47 | FromGitter | <zacharycarter> and besides which one backend doesn't necessarily suit every use case for nuklear |
17:05:04 | FromGitter | <zacharycarter> the point of nuklear is it is supposed to be api-agnostic |
17:05:33 | FromGitter | <Yardanico> well but if you want to write a simple gui utility, you don't want to waste your time writing a nuklear backend :) |
17:06:20 | * | BitPuffin|osx joined #nim |
17:06:24 | FromGitter | <zacharycarter> you also don't necessarily want as your only backend optoins |
17:06:26 | FromGitter | <zacharycarter> options* |
17:06:30 | FromGitter | <zacharycarter> (https://files.gitter.im/nim-lang/Nim/hTIS/Screen-Shot-2017-09-22-at-6.41.33-AM.png) |
17:06:33 | FromGitter | <zacharycarter> damnit wrong screenshot |
17:06:58 | FromGitter | <zacharycarter> if you're using a library like allegro or bgfx or something else this project won't help at all |
17:07:06 | * | jjido joined #nim |
17:07:18 | FromGitter | <Yardanico> well nuklear_cross is supposed to help you if you want to write some GUI utility in C :) |
17:07:56 | FromGitter | <zacharycarter> (https://files.gitter.im/nim-lang/Nim/pdvU/Screen-Shot-2017-09-22-at-1.06.14-PM.png) |
17:08:13 | FromGitter | <zacharycarter> it's fine as long as you're using one of ^ |
17:08:42 | FromGitter | <Yardanico> yeah |
17:08:59 | FromGitter | <Yardanico> and they cover all major platforms |
17:09:21 | FromGitter | <Yardanico> SDL, GLFW - multiplatform, xlib - Linux, gdiplus - windows |
17:13:54 | FromGitter | <zacharycarter> yeah you're right - I still wouldn't write bindings to them though the backends are trivial enough that you could and should just implement them in Nim |
17:14:34 | * | solitudesf quit (Remote host closed the connection) |
17:14:55 | * | vegai joined #nim |
17:15:33 | dom96 | https://github.com/dom96/choosenim/blob/master/analytics.md |
17:15:40 | dom96 | So what do you guys think? |
17:16:48 | FromGitter | <zacharycarter> awesome idea |
17:16:50 | FromGitter | <zacharycarter> <3 it |
17:17:08 | FromGitter | <Yardanico> nice |
17:17:40 | FromGitter | <Yardanico> dom96: is there any progress on nim community survey analysis ? :) |
17:18:26 | TjYoco | I usually opt-out of these things but I don't see a reason not to have this feature |
17:18:45 | dom96 | Yardanico: No, I'm mostly putting it off |
17:18:49 | dom96 | It's a boring job :) |
17:19:53 | dom96 | glad you guys like this though :) |
17:21:40 | FromGitter | <Yardanico> well if I use google all the time, what could be worse ? :) |
17:21:49 | FromGitter | <Yardanico> things like this only send anonymous data |
17:25:07 | * | zahary_ quit (Quit: Connection closed for inactivity) |
17:25:29 | * | dhalinar quit (Ping timeout: 255 seconds) |
17:27:55 | * | jjido quit (Remote host closed the connection) |
17:28:22 | * | dhalinar joined #nim |
17:28:40 | * | dhalinar quit (Remote host closed the connection) |
17:30:27 | FromGitter | <Yardanico> dom96: maybe release raw data as open-source? or it contains some private info? |
17:30:36 | FromGitter | <Yardanico> I'm about survey |
17:31:21 | shodan45 | nim needs some endorsements, like on https://myrlang.org/release-notes/ |
17:32:04 | FromGitter | <Yardanico> endorsements? |
17:33:43 | FromGitter | <Yardanico> website looks like something from 2000's :) |
17:34:10 | shodan45 | Yes. Isn't it awesome? ;) |
17:34:30 | FromGitter | <Yardanico> well they're not for my personal preference :) |
17:35:44 | shodan45 | also.... this "Gitter" thing breaks tab completing their nicks >_> |
17:35:56 | FromGitter | <Yardanico> I like this: "Libregex handles regexes. It implements a simple but powerful regex syntax, and has working Unicode support." |
17:36:03 | FromGitter | <Yardanico> working unicode support :) |
17:37:01 | shodan45 | ugh. just now finding out what gitter is. *why*. |
17:37:21 | FromGitter | <Yardanico> Gitter is a chat with rooms, mostly for github projects |
17:37:36 | FromGitter | <Yardanico> "Gitter is an open source instant messaging and chat room system for developers and users of GitHub repositories." |
17:37:42 | FromGitter | <Yardanico> you can log-in via twitter or github |
17:38:08 | shodan45 | I see that. And I'm still lost at to why it's better than IRC. |
17:38:40 | FromGitter | <Yardanico> you can embed images! |
17:38:48 | FromGitter | <Yardanico> and it's easier-to-use really |
17:38:55 | FromGitter | <Yardanico> it has specific github support |
17:39:05 | shodan45 | IRC is hard? |
17:39:23 | FromGitter | <Yardanico> I don't mean "hard" |
17:39:45 | FromGitter | <Yardanico> example about github support : https://github.com/nim-lang/Nim/issues/6412 |
17:39:55 | FromGitter | <Yardanico> this will be displayed as "nim-lang/Nim#6412" on gitter |
17:39:57 | * | rauss quit (Quit: WeeChat 1.9) |
17:40:02 | * | mahmudov joined #nim |
17:40:12 | shodan45 | I use quassel, which is relatively complicated to setup. And I managed. |
17:40:45 | FromGitter | <Yardanico> also you can use gitter in the browser. yeah, I know about different web clouds, but with gitter you don't need to connect again after leaving the website |
17:41:10 | FromGitter | <Yardanico> also gitter has full markdown support :) |
17:41:17 | shodan45 | that sounds a bit like what quassel does |
17:41:23 | shodan45 | not the markdown part |
17:41:28 | FromGitter | <Yardanico> also "Integrations for Trello, Jenkins, Travis CI, Heroku, Sentry, BitBucket, HuBoard, Logentries, Pagerduty & Sprintly are available." |
17:42:16 | shodan45 | I wouldn't mind it if it didn't screw with how IRC already works |
17:42:23 | shodan45 | but it does. |
17:42:26 | FromGitter | <Yardanico> how ? :) |
17:42:32 | shodan45 | o_O |
17:42:56 | FromGitter | <Yardanico> I use IRC from linux, and gitter from windows |
17:43:01 | FromGitter | <Yardanico> And I don't see any issues from both sides |
17:43:29 | shodan45 | you aren't logged in to freenode as your own user |
17:43:38 | FromGitter | <Yardanico> I'm from windows right now |
17:43:40 | shodan45 | "FromGitter" |
17:43:47 | FromGitter | <Yardanico> yes |
17:44:09 | FromGitter | <Yardanico> since this bridge is made by gitter, not by freenode |
17:44:20 | shodan45 | anyway, I gtg. |
17:44:23 | FromGitter | <Yardanico> so they can't use your logins |
17:44:34 | * | shodan45 twitches |
17:44:58 | shodan45 | (I'll still appear online, since I use quassel.) |
17:45:08 | FromGitter | <Yardanico> well I don't see that you're online anyway :P |
17:47:50 | * | TjYoco quit (Quit: Leaving) |
17:51:58 | FromGitter | <Tyler-Yocolano> Had to try Gitter since you were talking about it. A lot prettier than IRC lol |
17:52:40 | FromGitter | <Yardanico> and you don't need to host your own server to save logs! |
17:53:20 | FromGitter | <mratsim> There is no good IRC client for Mac so … Gitter it is |
17:53:29 | * | yglukhov joined #nim |
17:54:29 | FromGitter | <Yardanico> textual is a pretty good one? |
17:54:34 | FromGitter | <Yardanico> dom96 uses it :) |
17:54:55 | dom96 | It costs money |
17:54:57 | FromGitter | <Yardanico> https://www.codeux.com/textual/ ⏎ ⏎ you can buy it or compile it for free :) |
17:55:09 | dom96 | and I don't use it anymore |
17:55:11 | FromGitter | <mratsim> By the way @dom96, you could put the result of the Nim survey as open dataset on Kaggle: https://www.kaggle.com/datasets. I have lots of friends there that can give you excellent visualization |
17:55:27 | FromGitter | <Yardanico> dom96: what do you use now? |
17:55:34 | dom96 | mratsim: I'd rather not. |
17:55:41 | dom96 | Yardanico: XChat Azure |
17:57:18 | * | nsf joined #nim |
17:57:32 | FromGitter | <zacharycarter> hrm weird my calls to glClearColor for emscripten aren't working :/ |
17:57:52 | * | yglukhov quit (Ping timeout: 260 seconds) |
17:58:28 | FromGitter | <Yardanico> @zacharycarter maybe you use something like "glVertex2d" too ? |
17:58:42 | FromGitter | <mratsim> Myrlang is fun: https://myrlang.org/lang-checklist.html |
17:59:05 | FromGitter | <Yardanico> we need to write something like this for nim :D |
17:59:39 | adeohluwa | back like my spinal cord! |
17:59:55 | FromGitter | <Yardanico> lol, "[x] The compiler crashes if you look at it funny" |
18:00:16 | * | BitPuffin|osx quit (Remote host closed the connection) |
18:00:20 | adeohluwa | the parsecsv module looks like it parses CSV |
18:00:28 | FromGitter | <Yardanico> yes |
18:00:31 | adeohluwa | I'm looking for something to write to CSV |
18:01:07 | FromGitter | <Yardanico> well you can just write it "by hand" :D |
18:01:48 | FromGitter | <zacharycarter> there is something that writes csv |
18:01:53 | FromGitter | <zacharycarter> I use it at work |
18:01:56 | adeohluwa | hmm... since its just comma separated |
18:02:01 | dom96 | I just stumbled on this: https://www.reddit.com/r/programming/comments/3vscie/i_am_a_developer_behind_ritchie_a_language_that/ |
18:02:09 | dom96 | Wondering how the hell it got 1.4k upvotes on Reddit |
18:02:13 | adeohluwa | thought as much |
18:02:15 | * | yglukhov joined #nim |
18:02:29 | FromGitter | <Yardanico> yet another language, yay! |
18:02:49 | dom96 | it looks dead anyway |
18:02:52 | FromGitter | <mratsim> @Yardanico I compiled Textual actually, and I tried to connect to #Nim but somehow I got into a room with 5 people only :/ |
18:02:52 | adeohluwa | Zachary: what's the name of the module? |
18:02:53 | FromGitter | <Yardanico> dom96: company support :P |
18:02:54 | dom96 | but it's goals are basically aligned with Nim's |
18:03:02 | FromGitter | <Yardanico> @mratsim maybe #nim, not #Nim ? |
18:03:09 | FromGitter | <mratsim> oooohhh |
18:03:18 | dom96 | lol, I don't think IRC is case sensitive |
18:03:19 | FromGitter | <zacharycarter> adeohluwa: Nim data |
18:03:25 | dom96 | That would be craz |
18:03:26 | dom96 | y |
18:03:33 | * | yglukhov quit (Remote host closed the connection) |
18:03:43 | FromGitter | <Yardanico> @zacharycarter a little bit of overhead :) |
18:03:45 | * | yglukhov joined #nim |
18:03:50 | FromGitter | <zacharycarter> just a little |
18:03:52 | FromGitter | <Yardanico> https://github.com/bluenote10/NimData |
18:04:07 | FromGitter | <zacharycarter> I think that's what I"m using anyway let me check |
18:04:25 | FromGitter | <zacharycarter> oh |
18:04:27 | FromGitter | <zacharycarter> no I'm using this |
18:04:35 | FromGitter | <zacharycarter> https://github.com/unicredit/csvtools |
18:04:36 | FromGitter | <zacharycarter> sorry |
18:04:40 | adeohluwa | zacharycarter: awesome man, thanks! |
18:04:48 | FromGitter | <mratsim> NimData is impressive. I was wondering back in February if I should start a DataFrame or a multidimensional array library … then 1 week after came NimData |
18:04:50 | FromGitter | <zacharycarter> I'm using Nim adta too |
18:04:56 | FromGitter | <Yardanico> @zacharycarter oh, fine then! |
18:04:57 | FromGitter | <zacharycarter> Nim data too* |
18:05:06 | FromGitter | <zacharycarter> I'm using all the modules! |
18:05:14 | FromGitter | <Yardanico> we need to update awesome-nim |
18:05:21 | FromGitter | <Yardanico> https://github.com/VPashkov/awesome-nim |
18:05:54 | * | endragor_ quit (Remote host closed the connection) |
18:06:37 | FromGitter | <mratsim> There is no science/data/numerical computing section |
18:06:49 | FromGitter | <Yardanico> yeah |
18:06:51 | FromGitter | <Yardanico> so we need to add it |
18:06:59 | FromGitter | <Yardanico> hmm, I don't see any "real" examples here https://github.com/riolet/rix/tree/master/examples |
18:07:01 | FromGitter | <Yardanico> they're too small |
18:07:26 | FromGitter | <zacharycarter> there's no gaming section either :rollseyes: |
18:08:16 | FromGitter | <mratsim> lol |
18:08:50 | FromGitter | <mratsim> one of the other interesting language with a meta programming focus and easy C-C++ FFI I saw was terralang: http://terralang.org/ |
18:10:02 | FromGitter | <Yardanico> yeah, it's highly integrated with lua |
18:10:38 | FromGitter | <Yardanico> so it doesn't have it's own VM |
18:10:41 | FromGitter | <Yardanico> it just uses Lua :) |
18:10:52 | FromGitter | <Yardanico> actually not bad |
18:12:38 | * | jsgrant quit (Quit: jsgrant) |
18:19:36 | * | jsgrant joined #nim |
18:19:59 | * | vegai left #nim (#nim) |
18:25:06 | FromGitter | <edubart> noted you mentioning terralua, I've considered using terralang before, I do code in lua a lot even today for a game that uses an open game engine that I created (the engine is in one of my github public repos) |
18:26:20 | FromGitter | <edubart> lua is not a bad lang, its simple, compact, you can almost embed everywhere, do easy C bindings |
18:26:53 | Araq | it's also error prone as fuck, every typo is a bug |
18:26:56 | FromGitter | <edubart> and terralang make its more powerful, although I doesn't seems active |
18:27:09 | * | jsgrant quit (Quit: jsgrant) |
18:27:12 | Araq | but when you do live coding maybe it doesn't matter |
18:27:30 | * | jsgrant joined #nim |
18:28:44 | FromGitter | <edubart> this depends on the person, nim is every error prone for me, but mostly because I am not familiar |
18:30:44 | Araq | so ... your Nim typos produce bugs? |
18:30:56 | Araq | never heard that before from anybody. |
18:32:23 | FromGitter | <Yardanico> well yeah, it's mostly the issue with interpreted languages |
18:32:30 | FromGitter | <Yardanico> they don't usually bother checking source code a lot |
18:32:43 | FromGitter | <Yardanico> maybe just check the syntax, and run the code |
18:34:06 | FromGitter | <Yardanico> so with Nim, if you have come type errors: try to compile, fail, fix, try again |
18:34:25 | FromGitter | <Yardanico> in python: run it and wait for needed code to execute, fail, fix, try again |
18:34:36 | FromGitter | <Yardanico> well it's actually true for most modern compiled languages |
18:37:08 | adeohluwa | @ araq is so blunt it always sound like he's joking :D |
18:38:39 | adeohluwa | @edubart I'll disagree & I'm also not super familiar with nim but I'm able to run just by glancing @ docs & Rosetta code example quick check |
18:39:04 | adeohluwa | naming conventions actually make sense |
18:39:13 | * | nsf quit (Quit: WeeChat 1.9) |
18:39:14 | adeohluwa | HTML parser is called HTML parser |
18:40:06 | adeohluwa | can u imagine y its not called the same in other languages beats me |
18:41:22 | adeohluwa | u can say maybe error messages hasn't gotten to master QA level yet |
18:49:13 | federico3 | Error: use the {.experimental.} pragma to enable 'parallel' <-- what? |
18:51:08 | Araq | edubart: btw the newSeqOfCap optimization is in the works, as I said, requires no API changes |
18:52:38 | * | jsgrant quit (Quit: jsgrant) |
18:53:25 | * | jsgrant joined #nim |
18:55:01 | FromGitter | <edubart> @Araq would be a plus if you fix it and also add newSeqUninitialized(len) and maybe a getCap(seq) function too |
18:55:57 | Araq | you haven't convinced me of the merits |
18:56:01 | FromGitter | <edubart> and newSeqOfCap is not completely broken, I did see my RAM memory growing when using it |
18:56:10 | * | Sembei joined #nim |
18:56:43 | * | jsgrant quit (Remote host closed the connection) |
18:56:45 | Araq | your FFI use cases were all covered by setLen() |
18:57:37 | * | Pisuke quit (Ping timeout: 248 seconds) |
18:57:39 | FromGitter | <mratsim> newSeqUninitialized would be nice when we want to memcopy lots of data from GPU, images and other binary format |
18:59:42 | * | jsgrant joined #nim |
19:00:27 | FromGitter | <zacharycarter> anyone have any ideas why my call to glClearColor wouldn't work w/ emscripten? |
19:00:45 | FromGitter | <zacharycarter> is it because I didn't call loadextensions? which I can't call anyway w/ emscripten |
19:01:39 | FromGitter | <mratsim> When I say a lot, the goal is to saturate all your GPU memory so, 8GB~12GB every 10 seconds or so |
19:01:51 | * | Serenitor quit (Ping timeout: 248 seconds) |
19:06:10 | FromGitter | <zacharycarter> nm figured it out |
19:08:20 | shodan45 | lol, "You have reinvented Brainfuck but non-ironically" |
19:08:42 | shodan45 | (from https://myrlang.org/lang-checklist.html ) |
19:09:00 | adeohluwa | seems like I need to write a bot |
19:11:51 | adeohluwa | a quick google search shows nimbot |
19:12:04 | FromGitter | <Yardanico> IRC bot? |
19:12:58 | adeohluwa | social media bot |
19:13:04 | FromGitter | <Yardanico> oh |
19:13:21 | FromGitter | <Yardanico> then you would use asyncdispatch + httpclient + json :) |
19:13:30 | FromGitter | <Yardanico> so it will talk with users through social network? or what? |
19:14:39 | * | yglukhov quit (Remote host closed the connection) |
19:16:15 | dom96 | Anyone want to spearhead this? https://docs.travis-ci.com/user/languages/community-supported-languages/ |
19:17:59 | FromGitter | <Yardanico> for someone who wants to do this - examples for other languages: https://github.com/travis-ci/travis-build/tree/master/lib/travis/build/script |
19:19:59 | FromGitter | <Yardanico> oh, they have crystal support |
19:20:06 | FromGitter | <Yardanico> in community :) |
19:20:50 | dom96 | yep |
19:20:58 | dom96 | Nim should be there too |
19:21:21 | FromGitter | <Yardanico> sadly we don't have nightly builds :( |
19:22:01 | FromGitter | <Yardanico> ah |
19:22:06 | FromGitter | <Yardanico> it seems we can compile nim too |
19:22:43 | adeohluwa | Yardanico: yes... you are bn really useful |
19:25:02 | FromGitter | <Yardanico> hmm I don't really think we can compile nim every time |
19:25:13 | FromGitter | <Yardanico> probably it would only support stable builds (from ubuntu launchpad) |
19:26:52 | FromGitter | <Yardanico> dom96: we can use choosenim btw |
19:26:58 | FromGitter | <Yardanico> rust version uses rustup: https://github.com/travis-ci/travis-build/blob/master/lib/travis/build/script/rust.rb |
19:27:29 | * | yglukhov joined #nim |
19:27:44 | federico3 | Yardanico https://github.com/nim-lang/Nim/wiki/BuildServices |
19:27:47 | dom96 | Yardanico: Yes, I am aware. You'd think I would already know that, seeing as I've written choosenim... |
19:28:03 | FromGitter | <Yardanico> federico3: these scripts are different |
19:28:04 | federico3 | however CircleCI support docker images... |
19:28:09 | dom96 | You can cache the builds, like I do for choosenim. |
19:28:20 | adeohluwa | dom96: did I mention choosenim throws error on my Ubuntu 17:04 |
19:28:27 | dom96 | https://github.com/dom96/choosenim/blob/master/.travis.yml |
19:28:29 | dom96 | adeohluwa: no? |
19:28:33 | FromGitter | <Yardanico> can you do caching with travis language script? |
19:29:33 | dom96 | No idea |
19:30:01 | dom96 | You can use docker though https://docs.travis-ci.com/user/docker/ |
19:30:18 | FromGitter | <Bennyelg> Hey, I wanted to create some proc which can return something depends on the string passed into the proc |
19:30:26 | dom96 | adeohluwa: Please report it. |
19:30:29 | FromGitter | <Yardanico> dom96: you can't here |
19:30:40 | FromGitter | <Yardanico> @Bennyelg you can only do that if string is known at compile-time |
19:30:54 | FromGitter | <Yardanico> (if you mean different types) |
19:30:54 | FromGitter | <Bennyelg> it is, |
19:31:08 | FromGitter | <Bennyelg> I need use the "when" |
19:31:08 | FromGitter | <Bennyelg> ? |
19:31:10 | FromGitter | <Yardanico> then change "string" to "static[string]" in procedure arguments |
19:31:13 | FromGitter | <Yardanico> and use when |
19:31:21 | FromGitter | <Bennyelg> i thought to use case |
19:31:22 | FromGitter | <Bennyelg> :| |
19:31:38 | FromGitter | <Yardanico> and declare return type like this: "int | string" |
19:31:40 | dom96 | You probably want an object variant |
19:31:45 | adeohluwa | dom96: unhandled exception: can not open /home/user/.nimble/bin/nim [IO Error] |
19:32:09 | FromGitter | <Bennyelg> example |
19:32:18 | FromGitter | <Yardanico> @Bennyelg what exactly you want to do? |
19:32:39 | dom96 | adeohluwa: Gonna need more info. |
19:34:08 | FromGitter | <Bennyelg> @Yardanico ⏎ Im creating something like this: ⏎ ⏎ ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=59c565b0c101bc4e3af9e1c4] |
19:34:35 | FromGitter | <Bennyelg> then I want to call this client("s3") |
19:34:52 | FromGitter | <Yardanico> why not just use static enum instead of string ? :) |
19:34:55 | FromGitter | <Yardanico> it would be more convenient |
19:35:12 | FromGitter | <Bennyelg> I came from python which has not concept of enum :D |
19:35:27 | FromGitter | <Bennyelg> I need to get use into that concept |
19:35:36 | dom96 | I don't think you should do this |
19:35:40 | dom96 | Why are you doing this? |
19:35:54 | FromGitter | <Bennyelg> what do you mean why? |
19:36:17 | dom96 | I mean, why don't you just call initS3Request() or initEC2Request() depending on what you need? |
19:36:31 | * | voiceftp quit (Quit: Leaving) |
19:37:36 | FromGitter | <Bennyelg> this is going to be extended but for now this is what it is, I want to initiate instance depends on the user request |
19:38:56 | adeohluwa | dom96: can you give me specifics that you want |
19:39:02 | adeohluwa | thats all the error I get |
19:39:09 | adeohluwa | it doesn't install |
19:39:24 | adeohluwa | Ubuntu 17:04, 64 bit |
19:39:25 | dom96 | adeohluwa: what are you running? |
19:39:36 | dom96 | Are you installing for the first time? |
19:39:42 | dom96 | Are you attempting to execute 'nim'? |
19:40:02 | dom96 | Best thing to do is to just copy your terminal's output |
19:40:12 | dom96 | and create a gist and send me the link |
19:40:27 | adeohluwa | first time install , curl https://nim-lang.org/choosenim/init.sh -sSf | sh |
19:40:44 | adeohluwa | alright will do that |
19:42:52 | * | Vladar quit (Quit: Leaving) |
19:48:42 | * | vlad1777d quit (Ping timeout: 260 seconds) |
19:50:39 | dom96 | wow https://www.reddit.com/r/programming/comments/71ruk1/making_reel_valley_a_game_built_using_nim/dnd9ftu/?context=3 |
19:51:25 | FromGitter | <Yardanico> cc @yglukhov :D |
19:51:36 | dom96 | That's just rude. |
19:51:54 | federico3 | trolls will be trolls |
19:52:04 | FromGitter | <Yardanico> well he already got -3 |
19:52:14 | FromGitter | <Yardanico> -5 |
19:52:16 | adeohluwa | dom96: https://gist.github.com/Adeohluwa/6c86d6d761a2e490937ce19a0446ce85 |
19:52:20 | federico3 | also reddit is reddit |
19:52:38 | FromGitter | <Yardanico> adeohluwa: ah, you already have nim & nimble |
19:52:51 | * | vivus quit (Quit: Leaving) |
19:52:56 | FromGitter | <Yardanico> maybe it's because you're running it as root? |
19:53:23 | adeohluwa | I tried without root too |
19:54:04 | dom96 | that's really weird |
19:55:02 | dom96 | Can you do `curl https://nim-lang.org/choosenim/init.sh -sSf > init.sh` and then edit this line: https://github.com/dom96/choosenim/blob/master/scripts/choosenim-unix-init.sh#L50 |
19:55:07 | dom96 | just add "--debug" |
19:55:29 | dom96 | then run with 'sh init.sh' |
19:56:30 | * | astronavt quit (Remote host closed the connection) |
19:59:27 | adeohluwa | yes , let me do that now |
19:59:27 | * | voiceftp joined #nim |
20:00:54 | adeohluwa | so I ran & got an init.sh on my box |
20:00:59 | * | vlad1777d joined #nim |
20:01:10 | adeohluwa | running the sh init.sh gives same error as earlier |
20:01:41 | dom96 | no other output? |
20:02:13 | adeohluwa | where should I add the debug option? |
20:02:17 | adeohluwa | --debug |
20:02:24 | FromGitter | <Yardanico> "/$temp_prefix/$filename" stable --firstInstall --debug < /dev/tty |
20:03:24 | dom96 | ^^ |
20:04:01 | adeohluwa | dom96: no other output |
20:05:05 | dom96 | so do you have 'nim' in ~/.nimble/bin? |
20:07:54 | FromGitter | <Yardanico> yes he does |
20:08:02 | FromGitter | <Yardanico> ah, maybe not |
20:08:15 | FromGitter | <Yardanico> nim doesn't put its binary in .nimble/bin by default |
20:08:46 | dom96 | indeed |
20:09:13 | FromGitter | <Yardanico> maybe it failed to create "nim" binary? |
20:10:12 | adeohluwa | dom96: no I dont |
20:10:17 | adeohluwa | but I have nimcr there |
20:10:41 | adeohluwa | Yardanico : it doesn't create a nim binary |
20:13:06 | * | rusua quit (Quit: Connection closed for inactivity) |
20:13:27 | FromGitter | <Yardanico> I mean it "failed" to create a nim binary |
20:15:12 | adeohluwa | it fails on my server too |
20:15:28 | adeohluwa | it downloads nim on the server |
20:15:30 | adeohluwa | extracts |
20:15:34 | dom96 | it should begin by downloading though |
20:15:37 | adeohluwa | & fails to build |
20:15:45 | dom96 | that sounds like a separate problem |
20:15:53 | dom96 | show me the output of that as well please |
20:16:21 | dom96 | on your computer though, something you could do to investigate this is run `strace` |
20:22:20 | adeohluwa | https://gist.github.com/Adeohluwa/a49409d249d9f09a4a69b8efd867fb28 |
20:22:28 | adeohluwa | thats for the server |
20:22:43 | adeohluwa | copied out the whole error |
20:23:41 | dom96 | interesting |
20:23:46 | dom96 | is your server missing linenoise |
20:23:47 | dom96 | ? |
20:24:23 | yglukhov | Yardanico: thanks, answered. =) |
20:24:31 | FromGitter | <mratsim> The guy on reddit should have said horseshit :P |
20:28:16 | FromGitter | <mratsim> I’d like to add yglukhov, I read a lot of Python production codebase and proc are littered with “isInstance()” pixie dust (isInstance(String), else if isInstance(Int) ... |
20:29:07 | adeohluwa | dom96: how do I check for line noise? |
20:29:53 | yglukhov | mratsim: true. dom96's answer is somewhat close to your point, imo. |
20:30:15 | dom96 | adeohluwa: hrm, no, it seems that linenoise is statically compiled in |
20:31:20 | dom96 | Try running `gcc -c -w -pthread -O3 -fno-strict-aliasing -I/root/.choosenim/toolchains/nim-0.17.2/lib -o nimsuggest/nimcache/linenoise.o /root/.choosenim/toolchains/nim-0.17.2/lib/wrappers/linenoise/linenoise.c` |
20:33:01 | * | solitudesf joined #nim |
20:34:15 | adeohluwa | error no such file or directory |
20:34:36 | adeohluwa | Fatal error: no input files |
20:34:52 | adeohluwa | compilation terminated |
20:36:35 | dom96 | oh, it's because choosenim cleaned it :/ |
20:38:19 | * | nsf joined #nim |
20:40:00 | dom96 | adeohluwa: I don't suppose you could give me access to this server so that I could try to figure it out? |
20:40:08 | * | vlad1777d quit (Ping timeout: 240 seconds) |
20:40:57 | FromGitter | <Yardanico> @yglukhov , wow! https://github.com/yglukhov/android |
20:41:12 | FromGitter | <Yardanico> can I make a guess - you made this firstly for your game? |
20:41:17 | FromGitter | <Yardanico> and then open-sourced it ? :) |
20:41:29 | * | Ven`` joined #nim |
20:41:38 | FromGitter | <Yardanico> ah, sorry, you made it earlier |
20:42:54 | adeohluwa | dom96: I will man! |
20:44:16 | dom96 | oh, actually I just got an idea about what it might be. |
20:44:30 | dom96 | The VPS has 512mb of RAM, to compile Nim you might need more |
20:45:55 | FromGitter | <Yardanico> well choosenim should display a compiler error maybe? |
20:46:01 | FromGitter | <Yardanico> if compiler exit code isn't 0 |
20:46:49 | dom96 | It does. |
20:48:12 | * | vlad1777d joined #nim |
20:49:29 | FromGitter | <Yardanico> btw I use choosenim on windows :) |
20:49:39 | FromGitter | <Yardanico> because I don't use it often |
20:51:19 | * | libman joined #nim |
20:52:53 | adeohluwa | dom96: oh, okay |
20:53:02 | adeohluwa | will spin up 1 GB & try it |
20:53:08 | adeohluwa | will report here |
20:57:05 | * | vlad1777d quit (Ping timeout: 240 seconds) |
21:01:42 | * | manjaro-kde5- quit (Quit: Konversation terminated!) |
21:02:13 | FromGitter | <mratsim> What’s the proper way to unit test if a proc is properly defined? ⏎ ⏎ ```code paste, see link``` ⏎ ⏎ when not compile doesn’t want my proc definition [https://gitter.im/nim-lang/Nim?at=59c57a55b59d55b823295fa0] |
21:02:35 | FromGitter | <Yardanico> when compiles(stuff) ? |
21:03:55 | FromGitter | <Yardanico> @mratsim btw, did you try to run Arraymancer on windows? |
21:06:00 | FromGitter | <mratsim> I can’t do when compile(proc boo … multiline …), and just declaring the proc will stop the whole test suite (which is ugly but well, if it’s not possible to have the test suite continue, I’ll take it) |
21:06:34 | FromGitter | <mratsim> I didn’t try on Windows but there is Appveyor CI so it should work. I do have to configure CI for cuda builds on Windows and Linux |
21:07:15 | FromGitter | <Yardanico> well what blas library did you install? |
21:08:01 | FromGitter | <Yardanico> @mratsim you can do when compiles inside of a proc? |
21:08:11 | FromGitter | <mratsim> OpenBLAS |
21:08:34 | FromGitter | <Yardanico> @mratsim yeah, I've placed it in one folder with arraymancer example, but it still says that it can't load blas.dll |
21:12:24 | * | vlad1777d joined #nim |
21:12:47 | FromGitter | <mratsim> I think you have to rename libopenblas.dll, this is the Appveyor script. I’ll check if nimblas has more info on the windows build ⏎ ⏎ 1) ps: nuget install OpenBLAS -o "${env:APPVEYOR_BUILD_FOLDER}" ⏎ 2) ps: cp OpenBLAS.0.2.14.1/lib/native/bin/x64/libopenblas.dll blas.dll [https://gitter.im/nim-lang/Nim?at=59c57ccf7b7d98d30d27e4a3] |
21:13:58 | FromGitter | <mratsim> Otherwise you can modify nimblas nimble file with switches: ⏎ ⏎ switch("clibdir", "/usr/local/opt/openblas/lib") ⏎ switch("cincludes", "/usr/local/opt/openblas/include") [https://gitter.im/nim-lang/Nim?at=59c57d167b7d98d30d27e5ff] |
21:17:12 | * | Trustable joined #nim |
21:26:04 | * | Serenitor joined #nim |
21:42:15 | * | jsn- joined #nim |
21:43:34 | FromGitter | <Yardanico> Lol |
21:43:37 | FromGitter | <Yardanico> https://github.com/thepowersgang/mrustc |
21:48:52 | Serenitor | I've got a table with 37 items in it (len) but the keys iterator only goes over 30 of them... anyone experienced something similar know what's going on here? |
21:49:37 | dom96 | Share your code :) |
21:54:49 | * | madmalik quit (Quit: Connection closed for inactivity) |
21:55:49 | * | Jesin quit (Quit: Leaving) |
21:57:14 | Serenitor | alright there's probably a lot of stuff in here that's not relevant but if you could have look at wipeAssetTable() please |
21:57:16 | Serenitor | https://hastebin.com/emarikaley.nim |
21:57:40 | Serenitor | num items in asset table before wipe: 37 |
21:57:40 | Serenitor | items iterated over: 30 |
21:57:40 | Serenitor | items passed to free(): 30 |
21:57:40 | Serenitor | num items in asset table after wipe: 7 |
21:58:02 | dom96 | Well first thing would be to reproduce this |
21:58:05 | dom96 | outside of your script |
21:58:07 | dom96 | try that first |
21:58:17 | dom96 | Then second thing would be changing the casing of your types |
21:58:28 | dom96 | The convention is to start with UpperCase letters for types. |
21:59:36 | obadz | is there an easy way to turn a string in a array[N, char] ? cstring() gives a type error. Do I need to loop? |
22:01:33 | Serenitor | i'll see to it to set up a test case. though i'd like to have be type's casing consistent with the default types (int, float, ...). i use uppercase for constants and enums values |
22:02:12 | * | jsgrant quit (Quit: jsgrant) |
22:02:13 | FromGitter | <zacharycarter> obadz: ⏎ ⏎ ```let s = "Hello World" ⏎ ⏎ echo @s``` [https://gitter.im/nim-lang/Nim?at=59c58865b59d55b823299bea] |
22:02:23 | dom96 | Serenitor: those are primitive types |
22:02:25 | FromGitter | <zacharycarter> not an array but a seq |
22:02:35 | * | jsgrant joined #nim |
22:02:38 | dom96 | Every other type in the stdlib starts with upper case |
22:03:38 | obadz | @zacharycarter: type mismatch: got (seq[char]) but expected 'array[0..9, char] |
22:04:27 | FromGitter | <zacharycarter> obadz: like I said that wil produce a seq not an array |
22:04:32 | FromGitter | <zacharycarter> array size must be known at compile time |
22:04:53 | obadz | yes but there could still be a function that copy seq to array and throws if size isn't appropriate |
22:05:33 | FromGitter | <Yardanico> Well why do you need an array? |
22:05:59 | FromGitter | <zacharycarter> then - ⏎ ⏎ ```let s = "Hello World" ⏎ ⏎ echo repr cast[array[10, char]](s)``` [https://gitter.im/nim-lang/Nim?at=59c58947c101bc4e3afa7b96] |
22:06:01 | obadz | @Yardanico: C FFI |
22:06:12 | FromGitter | <zacharycarter> just use a seq and pass |
22:06:18 | FromGitter | <zacharycarter> addr seq[0] |
22:06:21 | obadz | for k, v in pairs("..."): a[k] = v works.. |
22:06:28 | FromGitter | <Yardanico> Yes, you don't need an array here |
22:06:40 | FromGitter | <Yardanico> You can pass your seq to C |
22:06:43 | obadz | ah ok |
22:07:09 | * | jsgrant quit (Client Quit) |
22:07:33 | * | jsgrant joined #nim |
22:08:04 | FromGitter | <zacharycarter> webgl is super annoying |
22:08:32 | FromGitter | <zacharycarter> all my drawing code looks correct but of course nothing is rendering |
22:08:44 | FromGitter | <zacharycarter> at least I can clear the window different colors :P |
22:09:00 | * | claudiuinberlin joined #nim |
22:12:13 | obadz | I guesshmmm |
22:12:16 | obadz | let s = "blah"; let x = cast[array[10, char]](s); echo "Array: ", $x |
22:12:20 | obadz | this produces garbage |
22:12:42 | obadz | or is $ not going to work on an array of chars? |
22:13:45 | FromGitter | <zacharycarter> mind posting code representing what you're trying to do with C FFI |
22:13:51 | FromGitter | <zacharycarter> might be able to help more |
22:14:40 | obadz | first time I'm asked for the code mess when I've boiled it down to the 1-line repro :) |
22:14:51 | obadz | I'm trying to call ioctl() |
22:15:16 | obadz | it takes an ifreq struct that has tons of submembers with unions, arrays, etc. |
22:15:30 | obadz | I've used c2nim and fiddles with the result until it compiled |
22:16:14 | obadz | but now I struggle to instantiate values of this type (I'm a nim newb). I've figured out how to deal with unions but not sure how to deal with arrays. |
22:16:16 | FromGitter | <zacharycarter> all I really need to see is the proc signature you've produced for binding and how you're trying to call it |
22:17:03 | FromGitter | <zacharycarter> maybe you need an unchecked array? |
22:17:05 | FromGitter | <zacharycarter> not sure |
22:17:19 | obadz | I'm calling Posix.ioctl, but passing stuff in the untyped varargs |
22:17:28 | obadz | so I don't think the signature will help |
22:18:02 | obadz | https://gist.github.com/obadz/f4d8a1ed3974c1330bc964835148ad24 ⇐ this is the ifreq type |
22:18:18 | obadz | ifrn_name for instance is an array[IFNAMSIZ, char] |
22:18:27 | obadz | how should I instantiate that? |
22:22:36 | FromGitter | <zacharycarter> it's weird ifr_ifrn_union is a union |
22:22:47 | FromGitter | <zacharycarter> because it's apparently not unioning anything? |
22:22:48 | FromGitter | <zacharycarter> but uh |
22:23:03 | obadz | it's unioning all the members below? |
22:23:08 | obadz | oh |
22:23:11 | obadz | sorry yes |
22:23:15 | obadz | I named that one badly |
22:23:36 | obadz | let me check why c2nim made it a union |
22:25:29 | obadz | https://github.com/torvalds/linux/blob/master/include/uapi/linux/if.h#L230-L252 ⇐ I guess c2nim is doing what it's told… |
22:26:24 | obadz | anyway the union isn't the issue here. I don't understand why this snippet corrupts memory: let s = "blah"; let x = cast[array[10, char]](s); echo "Array: ", $x |
22:26:44 | FromGitter | <zacharycarter> we probably need Araq for this convo, or someone with more Nim knowledge than myself |
22:27:11 | obadz | k, thanks for trying. |
22:27:46 | FromGitter | <zacharycarter> sure thing, sorry I can't be of more use |
22:28:52 | obadz | lol so if I do let x = cast[array[10, char]]("hi".cstring) |
22:29:03 | obadz | x[0] == "R" and x[1] == "C" |
22:29:09 | obadz | I assume that's for refcount? ;-) |
22:30:19 | * | yglukhov_ joined #nim |
22:33:12 | * | yglukhov quit (Ping timeout: 260 seconds) |
22:34:11 | Serenitor | @dom96 I've been able to reproduce my issue in a little test case. is this more helpful? https://hastebin.com/alajahiyak.nim |
22:35:18 | dom96 | Serenitor: yes, please report it on github |
22:35:28 | Serenitor | will do |
22:35:47 | * | claudiuinberlin quit (Quit: Textual IRC Client: www.textualapp.com) |
22:38:31 | obadz | so casting to a pointer works |
22:38:33 | obadz | let s = "blah"; let x = cast[ptr array[10, char]](s.cstring); echo "Array: ", $x[] |
22:38:48 | * | dhalinar joined #nim |
22:38:50 | obadz | this does not produce garbage |
22:40:56 | obadz | so I can get my actual array by doing ( cast[ptr array[10, char]](s.cstring) )[] — god knows what the lifetime of this thing is |
22:41:02 | obadz | there must be a better way. |
22:41:05 | * | solitudesf quit (Ping timeout: 248 seconds) |
22:41:59 | * | vivus joined #nim |
22:54:01 | dom96 | aww yeah, Linux + OSX binaries built by Travis |
23:01:10 | * | nsf quit (Quit: WeeChat 1.9) |
23:09:19 | * | zachk quit (Quit: have a good evening....) |
23:09:24 | FromGitter | <zacharycarter> dom96: NICE! |
23:10:31 | obadz | dom96: seems your book states that putting x on last line of function, or writing return x, or result = x are all equivalent. I'm observing otherwise. |
23:10:47 | dom96 | oh? |
23:11:36 | FromGitter | <zacharycarter> they should be equivalent |
23:11:42 | obadz | dom96: https://gist.github.com/obadz/f30ba172e301d6fe638a43b743dbbbe8 |
23:12:54 | obadz | is it possible that the implicit returns aren't forcing a copy? |
23:15:11 | FromGitter | <zacharycarter> def seems like a bug |
23:16:01 | obadz | if dom96 seconds that, I'll file a report |
23:17:43 | dom96 | yeah, I dunno |
23:17:45 | dom96 | file it anyway |
23:20:02 | obadz | https://github.com/nim-lang/Nim/issues/6422 |
23:23:52 | * | relax joined #nim |
23:26:37 | * | ipjk joined #nim |
23:30:19 | FromGitter | <genotrance> @zacharycarter: I've posted an updated version of autodup that should hopefully compile on Mac now https://www.dropbox.com/s/149gz1k3taoehp8/autodup.zip?dl=0, it still crashes after running for a while with autodup -M <path to music library> |
23:34:49 | FromGitter | <zacharycarter> @genotrance seems to build fine |
23:35:03 | FromGitter | <zacharycarter> and run fine too |
23:35:41 | FromGitter | <zacharycarter> going to leave it running and see what happens |
23:36:29 | FromGitter | <genotrance> thanks! |
23:36:41 | FromGitter | <zacharycarter> np! |
23:37:09 | FromGitter | <genotrance> I tried to use a native Nim SHA256 library but they are super slow |
23:37:35 | FromGitter | <genotrance> tried both nimSHA2 and sha3 and they were hogging the CPU and took a long time for small files |
23:37:58 | FromGitter | <genotrance> replaced it with native C code and it works great now |
23:38:45 | FromGitter | <zacharycarter> :/ |
23:38:54 | FromGitter | <genotrance> https://sourceforge.net/p/mailfs/svn/50/tree/trunk/mailfs/modules/hash/sha256.c |
23:39:15 | FromGitter | <zacharycarter> I wonder why the native nim modules are slow |
23:39:45 | FromGitter | <genotrance> i don't know why the Nim versions were so bad - like literally 50 times slower - I am turning on full debugging but even without that they are slow compared to sha256sum which is almost instantaneous |
23:40:10 | FromGitter | <zacharycarter> did you try release mode? |
23:40:28 | FromGitter | <genotrance> yes |
23:40:37 | FromGitter | <zacharycarter> hrm I have no idea then |
23:41:35 | FromGitter | <Varriount> Have you tried enabling link time optimizations? |
23:42:34 | FromGitter | <genotrance> @Varriount: not sure how to do that and what it does |
23:44:48 | FromGitter | <Varriount> @genotrance `--passC:'-flto'` |
23:45:32 | FromGitter | <Varriount> Also, I would be interested in looking at the code that was using NimSHA |
23:45:44 | FromGitter | <genotrance> let me put together a test and share |
23:46:18 | FromGitter | <genotrance> what's a good way to time execution in Nim? |
23:49:56 | dom96 | Choosenim 0.3.0 now out :D |
23:50:23 | FromGitter | <Varriount> @genotrance https://stackoverflow.com/questions/36577570/how-to-benchmark-few-lines-of-code-in-nim |
23:51:29 | FromGitter | <genotrance> @Varriount: thank you |
23:53:23 | * | Trustable quit (Remote host closed the connection) |
23:54:09 | FromGitter | <Varriount> I'd probably use a standard C benchmarking program |