00:00:01 | * | junland quit (Quit: %ZNC Disconnected%) |
00:03:16 | * | junland joined #nim |
00:06:39 | FromDiscord | <exelotl> Hey, the compiler guide mentions setting e.g. `arm.linux.gcc.exe = "arm-linux-gcc"` in your nim.cfg file, in order to use a cross compiler toolchain |
00:07:10 | * | Lord_Nightmare joined #nim |
00:07:13 | FromDiscord | <exelotl> what would be the equivalent line in a `config.nims` file? |
00:10:01 | FromDiscord | <Clyybber> @exelotl Probably switch("arm.linux.gcc.exe", "arm-linux-gcc") |
00:11:25 | * | sealmove quit (Quit: WeeChat 2.7) |
00:11:29 | FromDiscord | <exelotl> that doesn't seem right, cause it's not `--arm.linux.gcc.exe = ...` |
00:12:18 | FromDiscord | <Clyybber> hmm, right. does it work though? |
00:12:27 | FromDiscord | <exelotl> I'll give it a try |
00:12:42 | FromGitter | <matrixbot> `arkaroo` hrm, interestingly |
00:12:50 | disruptek | how is it that travis lets nimph clone a tree on windows but then won't let nimph remove that very same tree. |
00:12:53 | FromDiscord | <exelotl> (well I'm just getting started with a fairly dauting build script so it's a bit hard to confirm if it works lol) |
00:13:06 | FromGitter | <matrixbot> `arkaroo` it seems it's only the smembers function that's not gc safe, at least of the redis functions I'm currently using |
00:13:24 | disruptek | arkaroo: just mark it as safe and run it with --gc:boehm. |
00:14:35 | FromGitter | <matrixbot> `arkaroo` @disruptek: the redis library isn't mine, it's the official one, I'd have to submit a PR to mark it as safe. but riddle me this if you're willing to indulge: why would this be GC-safe: https://github.com/nim-lang/redis/blob/master/src/redis.nim#L534 but this not: https://github.com/nim-lang/redis/blob/master/src/redis.nim#L880 |
00:15:00 | disruptek | arkaroo: install nimph, type `nimph fork redis`, make your changes, call it good. |
00:15:32 | disruptek | it doesn't matter if it's safe or not: you're gonna rely upon boehm to protect you. |
00:16:25 | FromGitter | <matrixbot> `arkaroo` looks like nimph assumes I'm using github? |
00:16:36 | disruptek | it does. |
00:16:52 | FromGitter | <matrixbot> `arkaroo` RIP, I run my own gitlab instance |
00:17:08 | disruptek | your local git can be wherever you want. |
00:17:12 | FromDiscord | <exelotl> @Clyybber oh, it's `put` |
00:17:13 | FromDiscord | <exelotl> https://nim-lang.github.io/Nim/nimscript.html#put%2Cstring%2Cstring |
00:17:35 | disruptek | fork just forks it at github and then sets your remotes for you. you can just do it manually. |
00:18:06 | FromDiscord | <Clyybber> @exelotl Ah, good to know |
00:18:53 | FromGitter | <matrixbot> `arkaroo` I'm not a fan of forking things like this, it sets me up to have to keep fixing it every 6 months or so as I reintegrate |
00:19:14 | FromGitter | <matrixbot> `arkaroo` seems I'm not the only one with this kind of issue: https://github.com/dom96/nim-in-action-code/issues/6#issuecomment-484755006 |
00:19:14 | disruptek | there's no accounting for taste. |
00:19:16 | disbot | ➥ not GC-safe ; snippet at 12https://play.nim-lang.org/#ix=26qK |
00:19:44 | FromGitter | <matrixbot> `arkaroo` that guy's got basically the same problem, except with sqlite. |
00:20:18 | disruptek | he sounds cute. |
00:20:31 | FromGitter | <matrixbot> `arkaroo` I might be able to wrap my redis calls in a generic proc that is marked as gc-safe and takes an argument for what it should do, and then use boehm |
00:21:35 | FromGitter | <matrixbot> `arkaroo` BTW, if the default gc has cycle detection, what extra protection does boehm give in exchange for the stop-the-world operation (not that it matters since it's not a real time app, just curious) |
00:21:44 | FromGitter | <matrixbot> `arkaroo` * BTW, if the default gc has cycle detection, what extra protection does boehm give in exchange for the stop-the-world operation? (not that it matters since it's not a real time app, just curious) |
00:22:08 | disruptek | it's smarter wrt threads. |
00:23:38 | FromGitter | <matrixbot> `arkaroo` hrm, apparently it gives a shared heap too, although that sounds like a landmine of a feature to rely on in a threaded environment |
00:24:28 | disruptek | yes, that's the idea. |
00:24:52 | disruptek | it's a shoehorn that could get you running faster. |
00:34:02 | * | ng0 quit (Quit: leaving) |
00:34:19 | * | ng0 joined #nim |
00:35:57 | FromGitter | <matrixbot> `arkaroo` aaah, now I know why smembers is a problem, it's because it returns a sequence and apparently that make them "garbage collected objects" according to this guy: https://github.com/nim-lang/RFCs/issues/142#issuecomment-471486518 |
00:35:59 | disbot | ➥ Proposal to remove the `.gcsafe` effect from Nim ; snippet at 12https://play.nim-lang.org/#ix=26qX |
00:36:07 | FromGitter | <matrixbot> `arkaroo` is there anywhere with good reading on this stuff? |
00:36:37 | disruptek | are you able to use devel? |
00:37:12 | FromGitter | <matrixbot> `arkaroo` for testing things out, sure |
00:37:20 | FromGitter | <matrixbot> `arkaroo` has this behavior changed in devel? |
00:37:29 | disruptek | well, you could try --gc:arc in devel. |
00:37:33 | disruptek | !rfc memory |
00:37:35 | disbot | https://github.com/nim-lang/RFCs/issues/177 -- 3Unify Nim's GC/memory management options 7& 29 more... |
00:39:01 | disruptek | i would expect to still have to hack a bit, but arc is the future. |
00:39:24 | FromGitter | <matrixbot> `arkaroo` I can give it a spin but I don't know that it'll solve my immediate problem, since ultimately that comes from the fact that jester is marked up with gcsafe pragmas and redis is not. Ironically it doesn't actually have much to do with whether either library is *actually* gcsafe |
00:39:52 | FromGitter | <matrixbot> `arkaroo` unless I don't understand something, which is very possible |
00:39:58 | rayman22201 | you hit the nail on the head arkaroo... That's it |
00:40:18 | disruptek | yes, but this is the state of things right now. |
00:40:35 | rayman22201 | unfortunately, you have to hack it one way or the other atm. |
00:40:48 | FromGitter | <matrixbot> `arkaroo` yeah, seems that way |
00:41:25 | FromDiscord | <Clyybber> gn8 peeps |
00:41:28 | FromGitter | <matrixbot> `arkaroo` issue #142 says something about being able to use a {.gcsafe.} pragma in the middle of a proc to hint something to the compiler, but I've never seen pragmas anywhere except in proc definition signatures |
00:41:29 | disbot | https://github.com/nim-lang/Nim/issues/142 -- 5Can't compile dialogs.nim |
00:41:48 | FromGitter | <matrixbot> `arkaroo` is that standard syntax that I just haven't stumbled across? |
00:43:23 | * | couven92 quit (Ping timeout: 260 seconds) |
00:43:57 | rayman22201 | where do you see that? |
00:44:32 | FromGitter | <matrixbot> `arkaroo` https://github.com/nim-lang/RFCs/issues/142#issuecomment-471432179 |
00:44:34 | disbot | ➥ Proposal to remove the `.gcsafe` effect from Nim ; snippet at 12https://play.nim-lang.org/#ix=26qX |
00:44:59 | FromGitter | <matrixbot> `arkaroo` if I follow the issue correctly, araq is proposing taking existing syntax and changing what it does? |
00:45:47 | rayman22201 | arc supersedes that. arc will in theory smooth out a lot of these kinds of annoying thread issues. But arc is very new. It's going to take time to move the ecosystem. |
00:46:33 | FromGitter | <matrixbot> `arkaroo` yeah, but arc won't magically make my gcsafe pragma problem go away, so I still need to find some way to write code which lies to the compiler about whether the smembers call is gcsafe |
00:46:54 | FromGitter | <matrixbot> `arkaroo` I'm basically trying to wrap the redis call inside another proc which is marked as gcsafe, but the compilers having none of it :P |
00:47:11 | rayman22201 | it will make it go away, b/c arc ignore .gcsafe. iirc |
00:47:35 | FromGitter | <matrixbot> `arkaroo` oh, interesting. stand by and I'll test it |
00:47:40 | rayman22201 | yeah, no cheating :-P Nim tracks it with the effect system. |
00:48:50 | rayman22201 | I have never seen a pragma used outside of a proc definition like that. The closest thing I can think of is the push/pop pragma. |
00:48:51 | rayman22201 | https://nim-lang.org/docs/manual.html#pragmas-push-and-pop-pragmas |
00:49:08 | rayman22201 | idk what that comment was getting at |
00:49:09 | FromGitter | <matrixbot> `arkaroo` I might just be misreading the issue |
00:50:27 | FromGitter | <matrixbot> `arkaroo` alright, cover your ears while all my dependencies explode into tiny pieces :P |
00:50:47 | rayman22201 | other option. Spawn a separate thread by hand, do all redis calls in that seperate thread, and communicate back to the main thread with channels |
00:50:48 | rayman22201 | https://nim-lang.org/docs/channels.html |
00:51:39 | FromGitter | <matrixbot> `arkaroo` that's a go solution if ever I heard one, but maybe not a bad idea |
00:52:06 | rayman22201 | I call it "DIY erlang" :-P |
00:52:06 | FromGitter | <matrixbot> `arkaroo` if arc doesn't work I'll pencil that one down to explore tomorrow |
00:52:36 | rayman22201 | 👍 |
00:52:58 | FromGitter | <matrixbot> `arkaroo` this will be the sixth time I have done a shitty reimplementation of erlang in another language, and I have become exceedingly efficient at it :D |
00:53:09 | rayman22201 | lol |
00:54:38 | FromGitter | <matrixbot> `arkaroo` huh, nice |
00:55:13 | FromGitter | <matrixbot> `arkaroo` yep, looks like arc has moved past the gcsafe pragmas, which has now revealed that the prometheus library has a bug in it >_< |
00:56:32 | rayman22201 | 🎉 great success :-P |
00:58:00 | FromGitter | <matrixbot> `arkaroo` deepCopy hasn't been removed or anything, right? |
00:59:09 | rayman22201 | I'm not sure :/ |
00:59:53 | FromGitter | <matrixbot> `arkaroo` `/root/.nimble/pkgs/metrics-#master/metrics.nim(221, 9) Error: undeclared identifier: 'deepCopy'` getting that from the metrics library :/ |
01:00:06 | FromGitter | <matrixbot> `arkaroo` that might be enough for me to hang up my hat for the night I think |
01:00:22 | FromGitter | <matrixbot> `arkaroo` cheers for the help all |
01:00:40 | rayman22201 | gn |
01:25:14 | FromDiscord | <exelotl> anyone know how to stop the vscode-nim plugin from checking my config.nims file? |
01:25:15 | FromDiscord | <exelotl> https://cdn.discordapp.com/attachments/371759389889003532/663191242149986315/unknown.png |
01:26:43 | FromDiscord | <exelotl> (either making it understand the nimscript environment or disabling the checks altogether for this file) |
01:27:23 | * | ng0 quit (Quit: leaving) |
01:28:23 | FromGitter | <matrixbot> `arkaroo` I lied about sleep, sleep is for the weak |
01:28:45 | FromGitter | <matrixbot> `arkaroo` @rayman22201 I've found an example of that inline gcsafe pragma in the wild: https://github.com/status-im/nim-metrics/blob/f2199d9285e5f626be0c30b3293b3d76b548ab54/metrics.nim#L853 |
01:29:27 | FromGitter | <matrixbot> `arkaroo` looks like the deepcopy issue is a breaking change with the devel version of the nim compiler, something about a nimv2 runtime |
01:30:08 | rayman22201 | Interesting. It looks like an unnamed block |
01:31:22 | FromGitter | <matrixbot> `arkaroo` I'm going to go back to release nim and try to use that kind of syntax to bypass the GC issue, seems easier than shimming something to solve the deepcopy issue |
01:31:31 | rayman22201 | Hrmmm. You might need Araq or Clyybber to help with the deepcopy business. |
01:32:38 | FromGitter | <matrixbot> `arkaroo` I don't think it's a problem as such, I found some changes in the threadpool lib from araq that had conditionals that switched from some new behavior to deepcopy behavior depending on whether the nimv2 runtime state was set |
01:33:01 | FromGitter | <matrixbot> `arkaroo` so I think it's a deliberate breaking change in the devel branch? |
01:33:27 | rayman22201 | That's correct. I just don't remember the exact details of the change. 🤔 |
01:33:43 | disruptek | i think the intention is to reimpl it in the new runtime eventually. |
01:34:03 | rayman22201 | Ah ok |
01:34:15 | FromGitter | <matrixbot> `arkaroo` that'd make sense, I was wondering if we were going to go to a nimv2 so soon after the v1 release |
01:34:47 | rayman22201 | it's all definitely experimental stuff at this stage. |
01:34:51 | FromGitter | <matrixbot> `arkaroo` but either way, there's nothing for me to do there, a production library not being compatible with the devel branch is kinda no ones problem but mine :P |
01:36:43 | FromGitter | <matrixbot> `arkaroo` holy hell, it compiled |
01:36:46 | FromGitter | <matrixbot> `arkaroo` brace yourselves |
01:36:54 | rayman22201 | Nice! |
01:37:05 | rayman22201 | TIL |
01:41:30 | FromGitter | <matrixbot> `arkaroo` ` get "/someroute/?": ⏎ ⏎ ```{.gcsafe.}: ⏎ let things_from_redis: seq[string] = redisClient.smembers("some_key")```` [https://gitter.im/nim-lang/Nim?at=5e113eca865af87363bdba0d] |
01:41:43 | FromGitter | <matrixbot> `arkaroo` bah, rip my intenting |
01:41:57 | FromGitter | <matrixbot> `arkaroo` ``` get "/someroute/?": ⏎ ⏎ ```{.gcsafe.}: ⏎ let things_from_redis: seq[string] = redisClient.smembers("some_key")`````` [https://gitter.im/nim-lang/Nim?at=5e113ee54e9ea12051b76ecf] |
01:42:11 | FromGitter | <matrixbot> `arkaroo` * ``` ⏎ get: ⏎ ⏎ `````` [https://gitter.im/nim-lang/Nim?at=5e113ef3016ca663c19090fb] |
01:42:39 | FromGitter | <matrixbot> `arkaroo` * ``` ⏎ get "/someroute/?": ⏎ ⏎ `````` [https://gitter.im/nim-lang/Nim?at=5e113f0f809bc77efeeddf34] |
01:42:41 | FromGitter | <matrixbot> `arkaroo` that's valid syntax, it seems |
01:43:00 | FromGitter | <matrixbot> `arkaroo` and I'm getting metrics \o/ |
01:43:20 | FromGitter | <matrixbot> `arkaroo` so yeah, redisClient is a threadvar declared outside of the jester routes block |
01:43:41 | FromGitter | <matrixbot> `arkaroo` and then for a given route I can put the entire route code inside that gcsafe pragma |
01:43:43 | rayman22201 | it's block expression syntax I think.... https://nim-lang.org/docs/manual.html#statements-and-expressions-block-expression |
01:44:08 | rayman22201 | another place the docs could probably be improved. I don't think that syntax is documented anywhere :-/ |
01:44:19 | rayman22201 | but anyway. Yay! glad you got it working! |
01:44:26 | FromGitter | <matrixbot> `arkaroo` yeah, feels a bit like black magic ATM |
01:44:42 | FromGitter | <matrixbot> `arkaroo` I'll take it, but I don't know if I'm using a feature or a bug :P |
01:48:42 | FromGitter | <matrixbot> `arkaroo` oh well, at least my webserver is multithreaded now, that's probably a worthwhile improvement |
01:48:57 | FromGitter | <matrixbot> `arkaroo` k, bedtime for reals this time! |
01:49:15 | disruptek | gc:arc will only improve; it's not going to get removed. |
01:49:20 | rayman22201 | it is documented. I'll be damned: https://nim-lang.org/docs/manual.html#threads-gc-safety |
01:49:36 | rayman22201 | yeah. arc will make all this nonsense much better in the near future tm |
01:50:09 | rayman22201 | gn and congrats again |
02:51:11 | * | endragor joined #nim |
02:54:26 | * | dwdv quit (Ping timeout: 240 seconds) |
02:56:04 | * | endragor quit (Ping timeout: 258 seconds) |
02:56:49 | * | laaron quit (Remote host closed the connection) |
03:15:00 | * | deniel joined #nim |
03:15:23 | * | deniel is now known as Guest21700 |
03:16:12 | * | Guest21700 quit (Remote host closed the connection) |
03:16:24 | * | deniel joined #nim |
03:16:48 | * | deniel is now known as Guest93425 |
03:28:17 | * | endragor joined #nim |
03:36:26 | * | endragor quit (Remote host closed the connection) |
03:36:32 | * | endragor joined #nim |
03:49:15 | * | endragor quit (Remote host closed the connection) |
03:49:44 | * | Guest93425 quit (Remote host closed the connection) |
03:49:57 | * | deniel joined #nim |
03:50:21 | * | deniel is now known as Guest97696 |
04:00:17 | * | muffindrake quit (Ping timeout: 260 seconds) |
04:02:14 | * | muffindrake joined #nim |
04:23:50 | * | endragor joined #nim |
04:29:08 | * | endragor quit (Ping timeout: 260 seconds) |
04:37:02 | * | chemist69 quit (Ping timeout: 246 seconds) |
04:39:10 | * | chemist69 joined #nim |
04:39:41 | disruptek | my arc bug seems to have something to do with iteration where the yielded type is Result, ie. a union of value/error. i have to look at more carefully, but it could be due to instantiating what feels like two different types among different yield statements. |
04:41:22 | disruptek | apparently, nimble thinks that "2.1" as a version specification means "2.1.0", not "2.1.*". |
04:41:57 | disruptek | of course, it doesn't understand "2.1.*", so what did i expect? |
04:42:00 | disruptek | i mean, honestly... |
04:45:14 | * | Guest97696 quit (Remote host closed the connection) |
05:22:44 | * | laaronp joined #nim |
06:10:03 | * | dddddd quit (Ping timeout: 260 seconds) |
06:11:38 | * | narimiran joined #nim |
06:23:53 | * | laaronp quit (Quit: ZNC 1.7.5 - https://znc.in) |
06:24:14 | * | laaronp joined #nim |
06:26:39 | * | laaronp- joined #nim |
06:26:40 | * | laaronp quit (Client Quit) |
06:28:59 | * | laaronp- quit (Client Quit) |
06:29:31 | * | kitech1 joined #nim |
07:08:50 | * | seerix quit (Ping timeout: 240 seconds) |
07:26:52 | * | seerix joined #nim |
07:57:12 | * | nsf joined #nim |
08:00:00 | * | gmpreussner quit (Quit: kthxbye) |
08:03:46 | * | solitudesf joined #nim |
08:05:00 | * | gmpreussner joined #nim |
08:16:59 | * | endragor joined #nim |
08:32:32 | * | neceve joined #nim |
08:33:50 | FromDiscord | <Rika> can i store an async proc inside an object |
08:44:22 | * | ptdel quit (Ping timeout: 260 seconds) |
09:11:36 | * | Vladar joined #nim |
09:26:15 | * | nsf quit (Quit: WeeChat 2.7) |
09:31:22 | * | endragor quit (Remote host closed the connection) |
09:36:26 | zedeus | Araq: I replied to your comment regarding my httpclient streaming PR with a possible implementation, let me know what you think |
09:38:36 | FromDiscord | <Skaruts> I was reading on templates and macros, and I'm wondering: how would a template look like for initializing 2D sequences of arbitrary types... in one line? |
09:39:22 | FromDiscord | <Skaruts> (to replace the nested for loops and newSeq calls) |
09:40:59 | fireglow | can nim be written using tabs instead of spaces? |
09:41:53 | fireglow | aah dang. Found the FAQ |
09:46:38 | * | endragor joined #nim |
09:49:15 | * | tane joined #nim |
09:56:13 | * | letto quit (Quit: Konversation terminated!) |
09:57:53 | * | letto joined #nim |
10:02:52 | * | ng0 joined #nim |
10:11:16 | * | xet7 quit (Quit: Leaving) |
10:14:16 | * | xet7 joined #nim |
10:16:20 | Araq | disruptek: can you tell us the commit that broke nimph with --gc:arc? |
10:19:58 | FromDiscord | <mratsim> @Skaruts don't use a sequence of sequence, use a 1d sequence indexed with row*numCols+col |
10:20:27 | FromDiscord | <mratsim> otherwise newSeqWith(row, newSeqWith(col, )) |
10:20:39 | FromDiscord | <mratsim> newSeqWith(row, newSeqWith(col, 123)) |
10:21:06 | FromDiscord | <mratsim> but 1d sequence will be much more friendly to your memory, your cache and the Nim GC |
10:22:00 | Araq | indeed, an Nim provides really good support for overloading [] IMHO |
10:26:34 | * | Hideki_ joined #nim |
10:31:14 | Araq | zedeus: go for it, it should be possible to keep the old API and simply add a new, better one |
10:31:21 | Araq | use the .since annotation for it |
10:33:55 | * | dddddd joined #nim |
10:41:50 | * | dwdv joined #nim |
10:46:16 | * | nsf joined #nim |
10:46:27 | * | ng0 quit (Quit: leaving) |
10:50:28 | * | narimiran quit (Ping timeout: 240 seconds) |
10:54:40 | Araq | any C++ experts around? |
10:54:43 | * | Hideki_ quit (Ping timeout: 268 seconds) |
11:28:31 | FromDiscord | <Skaruts> @mratsim true. I tend to be lazy about it... |
11:36:24 | * | NimBot joined #nim |
11:41:13 | lqdev[m] | if an object with a string field is copied, is the string copied along with the object? |
11:41:29 | FromGitter | <mratsim> Yes |
11:41:53 | FromGitter | <mratsim> String and seq have value semantics they are deep coied by default |
11:42:09 | lqdev[m] | dang it. is there any way one could make a string or seq have ref semantics? |
11:42:32 | lqdev[m] | would I just do `ref string` |
11:42:32 | lqdev[m] | ? |
11:46:04 | * | kitech1 quit (Max SendQ exceeded) |
11:46:22 | * | kitech1 joined #nim |
11:47:01 | * | kitech1 quit (Max SendQ exceeded) |
11:47:33 | * | kitech1 joined #nim |
11:48:02 | * | kitech1 quit (Max SendQ exceeded) |
11:48:22 | * | kitech1 joined #nim |
12:08:16 | arecaceae | I guess there's no `method iterator` |
12:14:20 | arecaceae | I guess I can use generics in my case |
12:14:30 | lqdev[m] | arecaceae: there is. create a method that returns a closure iterator |
12:14:55 | FromDiscord | <KcVinu> Hi all, how can i use an array in a case statement ?, i mean, can i use an "in" key word ? Like "of in myArray : " |
12:15:25 | lqdev[m] | @KcVinu you can't, you must use a set |
12:15:36 | lqdev[m] | or an if statement |
12:15:41 | FromDiscord | <KcVinu> A set ? Ok |
12:32:40 | * | sealmove joined #nim |
12:33:00 | * | couven92 joined #nim |
12:39:44 | sealmove | lqdev/lqdev[m]: need your help with implementing what you suggested the other day (for getting type of complex expression) |
12:44:22 | lqdev[m] | sure |
12:44:45 | sealmove | thanks! :) |
12:45:18 | sealmove | so please elaborate on mechanics |
12:46:08 | lqdev[m] | so what you have now is a single macro that parses your DSL, right? |
12:46:23 | * | arecaceae quit (Remote host closed the connection) |
12:46:29 | lqdev[m] | and generates that expression |
12:46:39 | lqdev[m] | using NimNodes |
12:46:54 | sealmove | the way i have it set up is very simple. I use procs which return `NimNode`s to construct everything. The macro is just 5 lines. |
12:47:01 | sealmove | macro injectParser*(path: static[string]) = |
12:47:03 | sealmove | mt = parse(path) |
12:47:05 | sealmove | result = newStmtList( |
12:47:07 | sealmove | types(), |
12:47:09 | sealmove | property(), |
12:47:11 | sealmove | reads(), |
12:47:13 | sealmove | destructors(), |
12:47:15 | sealmove | api()) |
12:47:17 | * | arecaceae joined #nim |
12:47:34 | sealmove | yes, basically what you said |
12:47:59 | lqdev[m] | ok, the place where you generate the expression is types()? |
12:48:03 | sealmove | yup |
12:48:15 | sealmove | wait |
12:48:40 | lqdev[m] | and based on that expression's type, you need to generate an object declaration? |
12:49:19 | sealmove | no, the expressions are generated in reads()... |
12:49:26 | sealmove | but |
12:49:34 | sealmove | I can generate them in types(), it's no problem |
12:50:02 | sealmove | and yes, I need to generate object fields' declaration in types() |
12:50:39 | sealmove | the expressions are available everywhere after parse() |
12:50:44 | lqdev[m] | I assume the expressions you generate are valid expressions you could possibly `echo` out? |
12:51:22 | lqdev[m] | (not that we're going to use echo, you'll see what I mean in a sec) |
12:52:27 | sealmove | not sure because they might include identifiers |
12:52:45 | sealmove | which are actually assigned values in reads() |
12:53:02 | sealmove | the general idea is the following: |
12:54:12 | sealmove | in the DSL, you define linearly some fields. each fields usually has a type based on which its declaration is generated. but there is a special case where it might not have type but an expression instead, based on which the type can be derived automatically |
12:54:41 | sealmove | and that expression might use previous fields |
12:55:07 | lqdev[m] | all right, makes sense |
12:55:47 | sealmove | and currently I don't have a symbolTable |
12:56:08 | lqdev[m] | that makes things a little bit harder |
12:56:25 | sealmove | i can implement a symbolTable is absolutely necessary |
12:56:29 | sealmove | if* |
12:57:48 | sealmove | so yeah... now that I think of it, each expression depends on previous ones. it's not autonomous |
12:58:32 | lqdev[m] | I think you'll have to. the general working principle would be that when a field is generated, you add (name -> type) to the table, and then other expressions can reference it |
12:58:48 | sealmove | yeah, per-object symbol table |
12:59:07 | lqdev[m] | I assume forward references are not supported? that wouldn't really make sense in a binary file parser |
12:59:13 | * | Vladar quit (Quit: Leaving) |
12:59:52 | sealmove | hmm, there is the concept of instances, where parsing is lazy |
13:00:18 | lqdev[m] | oh no, even more complexity |
13:00:23 | lqdev[m] | let's just solve this first |
13:00:29 | lqdev[m] | focus on one task |
13:01:00 | sealmove | the way I generate the code atm is set up in a way that reads() works |
13:01:18 | lqdev[m] | so now, what you'd do in your expression generator is generate default(T) instead of these idents, where T is the type of the field in the expression |
13:01:24 | sealmove | because the expressions are written in the correct order, and in nim level the identifiers are valid |
13:04:49 | lqdev[m] | after you've generated the expressions, the idea is to defer everything else to another macro, I'll call it `genObject` |
13:06:08 | * | krux02 joined #nim |
13:06:15 | sealmove | so I have a `seq[tuple[fieldName, exprToDeriveType NimNode]]` for each object right? |
13:06:25 | lqdev[m] | yes |
13:07:22 | lqdev[m] | and the idea is to generate a call to a different macro that can get the type of your expression |
13:08:30 | lqdev[m] | assuming you have a list of names, types, and expressions, where at least the type or the expression must be present, you could do that by passing 3 openarrays to the other macro |
13:09:03 | lqdev[m] | where the first two could be untyped, but the third one (with the expressions) would be typed |
13:09:33 | sealmove | so seq[typed] |
13:09:54 | sealmove | never used typed before |
13:10:28 | sealmove | with typed you can call getType() on any Node? |
13:10:34 | lqdev[m] | yes |
13:10:41 | sealmove | I see, great |
13:11:20 | sealmove | hmm, it sounds like `typed` macros are not expanded purely at CT |
13:11:22 | lqdev[m] | on any nnkSym to be precise |
13:11:32 | lqdev[m] | what do you mean? |
13:12:33 | lqdev[m] | all macros are expanded at compile time |
13:12:59 | lqdev[m] | what happens with typed macro parameters is what we're after: semchecking |
13:13:01 | sealmove | nvm, it's still CT, but the fact that they need type info means they have to be work concurrently with semantic pass? |
13:13:11 | lqdev[m] | yes |
13:13:30 | lqdev[m] | typed params are semchecked, which turns nnkIdent into nnkSym |
13:13:41 | lqdev[m] | and you can do cool things with nnkSyms |
13:13:42 | sealmove | damn, how did Araq manage all this? :3 |
13:14:06 | Araq | I had help |
13:14:14 | lqdev[m] | my theory is that macro expansion is done iteratively |
13:14:35 | lqdev[m] | so it expands one level, then another, etc. until it doesn't have anything to expand |
13:15:56 | sealmove | there is one problem |
13:16:22 | lqdev[m] | what is it? |
13:16:39 | sealmove | during object declaration the expressions have to *run* right? |
13:16:58 | lqdev[m] | no |
13:17:12 | lqdev[m] | they're not executed, they're only checked |
13:17:34 | sealmove | how does Nim knows to check them in corrent order |
13:17:40 | lqdev[m] | unless you mean that you need them to run |
13:17:46 | sealmove | no |
13:18:11 | lqdev[m] | can you give an example? |
13:18:33 | sealmove | I mean, what is the nnkCall you mentioned for? |
13:18:48 | sealmove | i am not sure I get it |
13:18:52 | lqdev[m] | to invoke another macro expansion pass |
13:19:04 | sealmove | in which we do what? |
13:19:16 | lqdev[m] | hmm, how do I describe this |
13:19:26 | lqdev[m] | let me give you an example |
13:19:30 | sealmove | generate series of `let fieldName = expr` ? |
13:19:39 | lqdev[m] | no |
13:20:30 | lqdev[m] | say we have a macro `pass1`, which generates an nnkCall(bindSym"pass2") |
13:20:49 | lqdev[m] | the macro `pass2` returns an `echo "test"` |
13:21:13 | lqdev[m] | we call the first macro, and we have `pass1()` |
13:21:32 | lqdev[m] | pass1 executes, we end up with `pass2()` |
13:21:45 | lqdev[m] | pass2 executes, we end up with `echo "test"` |
13:22:04 | sealmove | ok |
13:22:31 | lqdev[m] | so essentially, macros generate code (duh) |
13:22:45 | sealmove | in what form do we obtain the inferred types? |
13:23:34 | lqdev[m] | after we pass our expressions to the second macro through an nnkCall, they get semantically checked, so all idents are resolved to syms |
13:24:02 | lqdev[m] | thus, we can call `getType` on the expression and get its type without problem |
13:25:45 | sealmove | ah, and this is done through side-effects I suppose, so the NimNodes change by calling the macro |
13:27:33 | lqdev[m] | read this https://nim-lang.org/docs/manual.html#templates-typed-vs-untyped-parameters |
13:27:58 | sealmove | lastly, pass2() is called once (not 1 pass2() call for each field), and there no need to do anything in its body? |
13:28:49 | lqdev[m] | pass2 gets an array of names, types, and expressions, and it generates the object declaration |
13:30:49 | sealmove | i see, but still don't get how nim knows how to resolve the types of idents. we do have a seq of expressions but how does Nim knows to check them in order, just because we pass them as typed params? |
13:31:27 | sealmove | because the expressions are not actually generated |
13:31:49 | sealmove | and they are separated from the corresponding name of field |
13:32:08 | lqdev[m] | wait a sec, I'll write a complete example and show you this way |
13:50:31 | lqdev[m] | dang, macros are annoying sometimes |
13:52:36 | lqdev[m] | sealmove: it just checks them left to right, symbol resolving does not generate code and is a separate pass in the compiler |
13:53:24 | sealmove | I see, this is quite handy |
13:53:24 | lqdev[m] | I tried to write that minimal example btw, but parameter passing between macros is confusing |
13:54:24 | sealmove | lemme give it a try with what I understood through your tutoring :D |
13:55:45 | lqdev[m] | I'm not good at teaching, but give it a shot and see what you can come up with |
13:56:05 | lqdev[m] | for some reason nobody understands what I say. :P |
13:56:55 | lqdev[m] | but once you understand this deferring to other macros fully, everything magically clicks into place |
13:57:48 | sealmove | it's a bit convoluted concepts |
13:57:55 | * | ng0 joined #nim |
13:58:13 | sealmove | concept* |
13:59:44 | lqdev[m] | yeah, macros are convoluted in general |
13:59:59 | lqdev[m] | and it's really useful to have some experience in language implementations |
14:01:14 | sealmove | I only started programming (excluding minimal exprerience in school) 2.5 years ago |
14:14:20 | * | narimiran joined #nim |
14:20:50 | sealmove | lqdev: when generating the nnkCall, how to pass the arguments? I am thinking something like:https://play.nim-lang.org/#ix=26u3 |
14:21:15 | * | endragor quit (Remote host closed the connection) |
14:22:31 | lqdev[m] | passing seq[NimNode] is not possible in this case, you need to create an nnkPrefix(ident"@", nnkBracket(elements)) |
14:22:37 | lqdev[m] | to pass a seq here |
14:23:18 | lqdev[m] | problem is, seqs are semchecked even if you ask for untyped, so you may want to convert any idents to strLits when passing them to the other macro |
14:28:12 | * | lritter joined #nim |
14:30:09 | sealmove | a simple question: when constructing nodes, do they have to be var? or you can use let because they are ref objects? |
14:35:13 | * | Trustable joined #nim |
14:35:14 | lqdev[m] | doesn't matter |
14:35:31 | lqdev[m] | I always use var for the ones I modify, though |
14:40:31 | disruptek | good thinking. |
14:51:36 | * | Hideki_ joined #nim |
14:52:19 | blackbeard420 | with asyncnet, i accept a client and process the message. then i spawn off a long running task in the threadpool. is it possible to send the result to the AsyncSocket from another thread? |
14:55:51 | * | couven92 quit (Quit: Disconnecting) |
14:55:58 | * | Hideki_ quit (Ping timeout: 258 seconds) |
15:01:22 | disruptek | my arc issue arrived with this "fix" that sinks a manually alloc'd C type into a proc that may free/realloc it elsewhere, wrapping it in a Result: https://github.com/disruptek/gittyup/commit/2ebc3d18cd60df06eeca5894e4165348e94aca4f |
15:01:30 | * | Vladar joined #nim |
15:01:46 | disruptek | it seemed simple at the time. |
15:03:28 | disruptek | btw, this causes windows to hang. linux/osx c compiler crash. |
15:06:51 | disruptek | https://travis-ci.com/disruptek/gittyup/builds/143060149 |
15:13:13 | * | ng0 quit (Ping timeout: 258 seconds) |
15:14:13 | sealmove | lqdev: I think I grapped the concept. Still getting errors though. Will try more later |
15:14:20 | sealmove | grasped* |
15:15:05 | * | ng0 joined #nim |
15:15:05 | * | ng0 quit (Changing host) |
15:15:05 | * | ng0 joined #nim |
15:15:41 | lqdev[m] | nice to hear that :) feel free to ask any more questions |
15:17:38 | sealmove | you are the best ^^ |
15:21:39 | FromGitter | <Albus70007> it seems like sockets.recv() decode the data by their self, how can i avoid it or use another formatting |
15:22:34 | FromGitter | <deech> disruptek, had no idea you could qualify with std like this: https://github.com/disruptek/gittyup/blob/master/gittyup.nim#L8. Nice tip! |
15:22:42 | lqdev[m] | @Albus70007 recv() receives raw bytes into a string, it does not do any decoding/encoding |
15:23:02 | disruptek | i just find it a little easier to read. |
15:25:26 | FromGitter | <Albus70007> then why i receive data as bytes, but it gets printed as a decoded string? |
15:26:47 | FromGitter | <deech> I'm curious how that works, is the 'std' namespace special? Also I would have expected to see 'import std/pure/strutils' in that example. |
15:27:03 | disruptek | it's magic, yes. |
15:27:46 | FromGitter | <deech> And presumably Bad Things happen if I have a local module in a directory called 'std'? |
15:28:45 | disruptek | fair question; i would expect it to work, actually, as i think it turns std/ into config.libPath in the search and then will proceed to searchPaths, lazyPaths. |
15:29:02 | disruptek | but it's worth testing. |
15:35:00 | FromGitter | <deech> Just tested with a local module `std/strutils.nim`, it's ignored when I `import std/strutils` and `import strutils`. |
15:35:25 | disruptek | right, but what if it's name std/foo |
15:35:32 | FromGitter | <deech> It finds it. |
15:35:36 | disruptek | good. |
15:36:22 | FromGitter | <deech> A warning that a local module was ignored would be nice. |
15:36:42 | disruptek | nimph will warn of shadowed modules. |
15:37:16 | disruptek | actually, i don't think i check stdlib for shadows. |
15:37:33 | FromGitter | <deech> oh nice! |
15:38:00 | disruptek | i wonder if it makes sense to do that. |
15:38:08 | FromGitter | <deech> Package qualified imports would also be nice. |
15:38:28 | disruptek | what do you mean? |
15:39:57 | FromGitter | <deech> Like if you shadow a dependency's directory structure, you could do `import "mydep" a/b`as an example. |
15:40:40 | disruptek | if you shadow a dep, you just `import a/b`. |
15:40:58 | FromGitter | <deech> How do you get to the dep's `a/b`? |
15:41:08 | disruptek | ie. the shadows happen at the level of the package directory. |
15:42:18 | disruptek | there's no way to selectively replace a shadow when the foo author specifies foo/bar, afaik. |
15:44:03 | lqdev[m] | @Albus70007 because that's what recv() returns. you can use strutils.toHex if you wish to print hex bytes. |
15:49:00 | * | marmotini_ joined #nim |
15:57:03 | FromGitter | <deech> disruptek, btw when I moved `strutils` to the same directory as the module importing it doing `import strutils` uses that instead of the standard lib. |
16:00:34 | FromGitter | <Albus70007> @lqdev[m] thank you, although i think it should just give you the raw data they sent |
16:06:22 | disruptek | deech: as expected. |
16:11:08 | * | krux02 quit (Remote host closed the connection) |
16:17:47 | * | sealmove quit (Quit: WeeChat 2.7) |
16:19:29 | * | Trustable quit (Remote host closed the connection) |
16:26:09 | disruptek | i think i have to trust that the programmer knows what's in the stdlib and is shadowing stuff intentionally, as opposed to warning them needlessly. |
16:27:23 | narimiran | deech, disruptek you can do `import strutils` for local one, and `import std/strutils` for stdlib one |
16:27:40 | disruptek | yeah, that's what we're talking about. |
16:28:11 | disruptek | nimph doesn't sniff for "std/" imports, though, so i'd either have to start grokking code, running nimsuggest, or looking at artifacts. |
16:28:16 | disruptek | i think it's too much ask. |
16:28:50 | disruptek | there has to be a line where we assume the programmer is smarter than we are. by staying kinda dumb, we define that line. |
16:28:54 | disruptek | we're a tool, after all. |
16:29:08 | FromGitter | <deech> From your explanation of 'std/' I now get why it works out that way but a warning would still save someone's sanity in the future I think. :) I say this as someone who's been bitten by shadowing before. |
16:29:32 | disruptek | so how does it work? tell me the story. |
16:30:51 | FromGitter | <deech> From your explanation it special cases 'std/' when that's not there it looks around in local scope first. |
16:31:07 | disruptek | i mean, how can nimph warn you when it should? |
16:32:21 | FromGitter | <deech> I wasn't refering to nimph, I meant a warning for nim itself. |
16:32:42 | disruptek | nim has a lib called "events". it's deprecated, but it could easily clash with a package's "events" submodule. |
16:33:27 | disruptek | nim could warn of shadows, yes. i would impl it if araq liked it. |
16:33:45 | disruptek | much cleaner to do it in the compiler. |
16:36:28 | dom96 | this is why you should always import packages with an "absolute" import, i.e. `import pkgName/events` |
16:37:29 | FromGitter | <deech> Oh wait, Nim does have package qualified imports? That's awesome. |
16:39:16 | disruptek | dom96: if that's the case, why can't nimble build nimph? |
16:39:43 | dom96 | hrm? how are the two related? |
16:40:09 | disruptek | nimph imports nimph/foo but nimble cannot build it because it cannot find nimph/foo before nimph is installed. |
16:40:49 | dom96 | where are the files that import `nimph/foo`? |
16:41:13 | disruptek | in the nimble-dictated subdirectory src/nimph. |
16:42:23 | dom96 | ahh yes, in that case you're screwed :) |
16:44:03 | dom96 | would be nice if we could come up with a solution to this |
16:45:23 | disruptek | the solution is for nimble to inject the path to the source. |
16:45:56 | dom96 | sure, but then compilation via `nim` will break |
16:46:07 | disruptek | why? |
16:46:29 | dom96 | because it would also need to inject this path? |
16:46:46 | disruptek | once the package is installed, it's a non-issue. |
16:47:06 | disruptek | nimble/nimph can create a nim.cfg, etc. |
16:47:32 | disruptek | if it's installed to a --nimblePath, it'll already get picked up by nim. |
16:47:59 | disruptek | this is from nimph's installation "bootstrap.sh": nimble install "--passNim:--path:\"`pwd`/src\" --outdir:\"`pwd`\"" |
16:48:39 | dom96 | you could surely say the same thing about Nimble failing to build it |
16:48:42 | disruptek | nimph.nimble also specifies the srcDir. |
16:48:57 | * | federico2 joined #nim |
16:49:53 | disruptek | yes, i wish nimble could build it. |
16:50:54 | dom96 | but you don't care if`nim` can, right? |
16:51:15 | disruptek | nim doesn't have a problem with it. |
16:51:38 | dom96 | maybe I'm misunderstanding, but if Nim doesn't have a problem then Nimble also doesn't |
16:51:52 | disruptek | well, if you have git on your machine, you can try it for yourself. |
16:52:07 | dom96 | Nim also has the same problem: you need to install Nimph to build it, no? |
16:52:15 | disruptek | nah. |
16:52:44 | disruptek | with no --path to the src in nim.cfg, just `nim c src/nimph.nim` |
16:53:27 | * | federico2 quit (Client Quit) |
16:53:36 | dom96 | Can you explain how Nim works in this case? |
16:53:47 | dom96 | is it some flag that Nimble passes that makes the build fail? |
16:54:01 | disruptek | probably. |
16:54:36 | disruptek | nim uses the projectPath for resolution so that you can `import foo` and import a local-to-the-source 'foo.nim'. |
16:54:49 | disruptek | thus, 'nimph/foo' imports nimph/foo.nim. |
16:55:10 | * | ptdel joined #nim |
16:56:04 | disruptek | thus, 'import nimph/foo' imports src/nimph/foo.nim, i should say. |
16:56:24 | dom96 | Okay, so this is once you've installed nimph |
16:56:33 | disruptek | nope. |
16:56:42 | dom96 | most definitely |
16:56:47 | dom96 | there is no other way it could work |
16:56:56 | * | ng0 quit (Quit: leaving) |
16:57:03 | disruptek | i have never "installed" nimph, so i'm pretty confident on this. |
16:57:28 | dom96 | your bootstrap.sh installs it, so maybe you did by accident |
16:57:54 | disruptek | my .nimble directory doesn't exist. |
16:59:07 | disruptek | actually, it exists, but it's unreadable and unexecutable. |
16:59:39 | dom96 | https://gist.github.com/dom96/b6032baa2ebb6ad3801854b0c898f306 |
17:00:00 | disruptek | it's hard to build without dependencies, isn't it? |
17:00:08 | dom96 | oh yeah |
17:00:11 | dom96 | my bad |
17:00:17 | disruptek | 😉 |
17:01:01 | disruptek | the next problem you'll run into is that you cannot install hybrid packages (binary + library). |
17:01:20 | disruptek | !search nimble hybrid |
17:01:22 | disbot | https://github.com/nim-lang/nimble/issues/582 -- 3nim project complains about missing src/ prefix in hybrid package 7& 22 more... |
17:01:44 | dom96 | https://gist.github.com/dom96/ec27e50730b22d5cbf2bfd063137bcb4 |
17:01:47 | * | dom96 gives up |
17:02:26 | disruptek | it's pretty tough. |
17:02:41 | disruptek | see if the bootstrap works for you. |
17:02:43 | dom96 | It would be helpful if you could find out which command line flags Nimble uses that break it |
17:03:11 | disruptek | i'd rather fix arc for gittyup. |
17:03:35 | disruptek | but feel free to create an issue in nimble. |
17:04:32 | * | Kaivo quit (Quit: WeeChat 2.7) |
17:07:27 | dom96 | https://gist.github.com/dom96/8ca782fbd7dcb800ac2866082de78d17 |
17:07:47 | dom96 | am I missing some magic? |
17:08:28 | FromGitter | <deech> dom96, https://github.com/nim-lang/nimble/blob/master/src/nimble.nim#L1065? |
17:09:16 | dom96 | hrm? That's for `test` |
17:09:41 | FromGitter | <deech> oops |
17:11:18 | disruptek | you are missing the nimph.nim.cfg. |
17:11:46 | disruptek | see the "# fix nimble?" attempt at the bottom. 😉 |
17:13:11 | * | vesper quit (Quit: ZNC 1.7.4 - https://znc.in) |
17:13:53 | dom96 | ... |
17:14:28 | dom96 | so you've fixed `nim` yourself |
17:14:32 | dom96 | just say so next time |
17:14:32 | * | vesper11 joined #nim |
17:15:07 | disruptek | i don't follow... |
17:15:38 | dom96 | The reason you can compile this way with `nim` is because you've supplied it with a --path flag |
17:15:39 | disruptek | the compiler works fine. it's nimble that breaks the build. |
17:15:47 | disruptek | yes. |
17:16:32 | dom96 | so for whatever reason Nimble causes Nim to ignore this nim.cfg file |
17:16:44 | dom96 | but in addition you think Nimble should just do this implicitly, right? |
17:17:02 | dom96 | (this meaning what you've specified in your nim.cfg file) |
17:17:12 | disruptek | no; i don't think nimble should be used to build nim software. |
17:17:34 | dom96 | No? Why not? |
17:17:51 | * | filcuc joined #nim |
17:17:52 | disruptek | because it's not a compiler and can offer nothing over what already exists in the compiler. |
17:18:11 | disruptek | in fact, i think we've demonstrated numerous problems with its behavior. |
17:18:33 | disruptek | nimph used to ship a nim.cfg and the "fix nimble" comment dates back to then. |
17:18:45 | disruptek | nim.cfg is now expected to be ephemeral. |
17:18:54 | dom96 | You've demonstrated a bug |
17:19:18 | dom96 | And you're making it sound like Nimble is deviating from Nim's behaviour, where you've had to modify Nim's config to make it do what you want |
17:19:18 | disruptek | can you give me an example of a benefit to building with nimble? |
17:19:47 | dom96 | Yes, dependencies are installed and managed for you automatically |
17:20:00 | disruptek | what does that have to do with building? |
17:20:27 | dom96 | Everything. Without dependencies you cannot build the software |
17:21:21 | disruptek | i guess there's nothing to talk about, then. |
17:22:30 | * | filcuc is now known as help |
17:22:36 | * | help is now known as filippo |
17:24:02 | dom96 | I created https://github.com/nim-lang/nimble/issues/760 in any case |
17:24:03 | disbot | ➥ Nimble ignores nim.cfg? |
17:25:02 | FromGitter | <sheerluck> I know what to do. @dom96 and @disruptek run `$ nimble list -i | wc -l` Larger number wins. Mine is 14 ^_^ |
17:25:54 | disruptek | mine doesn't produce any output. what's it supposed to do? |
17:26:10 | dom96 | 397 :D |
17:26:28 | disruptek | mine is probably broken. |
17:26:39 | * | filippo is now known as filcuc |
17:27:01 | disruptek | nimble has more open bugs than nimph has tickets. |
17:27:16 | solitudesf | thats a weird metric |
17:27:24 | dom96 | that's a poor metric |
17:27:40 | disruptek | it's not a metric. |
17:27:53 | disruptek | i'm saying that i don't assume that any behavior is correct. |
17:28:23 | FromGitter | <sheerluck> Friends. That was a joke. Why so serious? |
17:29:03 | * | marmotini_ quit (Remote host closed the connection) |
17:29:38 | * | marmotini_ joined #nim |
17:33:49 | * | marmotini_ quit (Read error: Connection reset by peer) |
17:33:54 | * | marmotin_ joined #nim |
17:33:56 | FromGitter | <Albus70007> ok guys, i know receive a proper header, but when i try to receive the rest of the buffer, the program will just stop, thinking but not returning me anything |
17:34:07 | FromGitter | <Albus70007> (i can send the code if you want) |
17:34:46 | disruptek | !search nimble pass-through |
17:34:48 | disbot | https://github.com/disruptek/nimph/issues/107 -- 3nimble pass-through doesn't pass all options 7& 29 more... |
17:36:47 | skrylar[m] | i bring gifts https://github.com/Skrylar/skcbor 🎉 |
17:37:23 | FromGitter | <Albus70007> proc recievePacket(): JsonNode = ⏎ ⏎ ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5e121ed3be6bab58cd7ac680] |
17:37:36 | disruptek | skrylar[m]: neat, does it work with arc? |
17:38:00 | skrylar[m] | i have no idea. |
17:38:11 | disruptek | want me to setup travis on it? |
17:38:18 | * | marmotin_ quit (Remote host closed the connection) |
17:38:26 | skrylar[m] | i dont use travis but you can test it if you want to |
17:38:28 | FromGitter | <Albus70007> the program breaks at let more_data ... |
17:38:38 | * | marmotini_ joined #nim |
17:38:55 | skrylar[m] | in a couple days i'll go put the sax interface on top of it. right now its just parsing primitives |
17:39:05 | disruptek | albus70007: i cannot read gitter, but most likely you need to specify the length to read as parsed from the header. |
17:39:25 | disruptek | skrylar: good contribution, thank you. |
17:40:16 | FromGitter | <Albus70007> could you show me how? |
17:40:29 | disruptek | see how i do it in here: |
17:40:32 | disruptek | !repo swayipc |
17:40:33 | disbot | https://github.com/disruptek/swayipc -- 9swayipc: 11swayipc (i3ipc) for Nim 15 3⭐ 0🍴 |
17:41:29 | shashlick | why does compiler still need -d:nimOldCaseObjects in debug mode? |
17:45:52 | FromGitter | <Albus70007> disruptek, i am not sure wdym, i do specify a length to read |
17:46:17 | disruptek | as i said, i cannot read gitter. |
17:46:25 | FromGitter | <Albus70007> ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5e1220f1809bc77efef37935] |
17:46:33 | disruptek | LOUDER |
17:46:49 | FromGitter | <Albus70007> *while len(recieved).uint16 < fromHexuint16 (header): ⏎ ⏎ ```code paste, see link``` ⏎ ⏎ var packet: JsonNode = json.parseJson(recieved) ... [https://gitter.im/nim-lang/Nim?at=5e122108865af87363c382f4] |
17:49:10 | FromGitter | <Albus70007> it freezes at more_data, and doesnt move |
17:49:41 | disruptek | you might share code via a pastebin service such as gist or ix. |
17:50:37 | FromGitter | <Albus70007> i will try |
17:51:51 | federico3 | https://github.com/nim-lang/c2nim <-- the URL in the description gives 404 |
17:56:17 | FromGitter | <Albus70007> https://pastebin.com/CMyGhmZU here you go, i commented and explained the problem |
17:57:06 | * | abm joined #nim |
17:57:23 | disruptek | you need to keep decrementing the amount of data that remains to be read such that the final read succeeds even if reading less than 1k. |
17:57:53 | FromGitter | <Albus70007> but i am not able to read even once |
17:58:06 | disruptek | then there is less than 1024 to read, most likely. |
17:58:30 | disruptek | fwiw, `received` is mispelled. |
17:58:42 | FromGitter | <Albus70007> so how should i do it, (ups) |
17:59:17 | disruptek | read min(1024, total-received.len) |
17:59:32 | FromGitter | <Albus70007> ill try that |
18:02:47 | FromGitter | <Albus70007> no luck :( |
18:02:58 | disruptek | lemme see. |
18:03:05 | FromGitter | <Albus70007> output? |
18:03:11 | disruptek | code |
18:03:42 | FromGitter | <Albus70007> let more_data: string = socket.recv(fromHexint (header) - len(recived)) |
18:03:54 | FromGitter | <Albus70007> int is between [ ] |
18:04:33 | disruptek | i think you should output some of these values and confirm that they match your expectations. |
18:08:14 | FromGitter | <Albus70007> ok, i think i got it |
18:08:18 | disruptek | nice. |
18:09:06 | FromGitter | <Albus70007> still having problems with parsing to json. but i will see, thx |
18:17:14 | * | endragor joined #nim |
18:22:25 | * | endragor quit (Ping timeout: 268 seconds) |
18:23:38 | * | filcuc quit (Ping timeout: 240 seconds) |
18:27:54 | Araq | once again, any C++ experts around? |
18:30:21 | FromDiscord | <demotomohiro> I have used C++ for about 10 years before start using Nim. |
18:30:39 | FromDiscord | <demotomohiro> But I don't know much about C++17 or newer |
18:31:00 | Araq | https://stackoverflow.com/questions/8920699/why-am-i-getting-non-aggregate-cannot-be-initialized-with-initializer-list we have a similar problem in the Nim C++ codegen |
18:31:38 | Araq | and I wonder if there is a good fix beyond emitting toplevel vars with explicit assignment statements |
18:35:02 | FromDiscord | <demotomohiro> Nim C++ codegen need to initialize std::map or other container class? |
18:36:33 | Araq | a Nim object that uses inheritance |
18:36:46 | Araq | and we map Nim's inheritance to C++'s inheritance |
18:37:03 | Araq | mostly in order to play nice with C++'s aliasing rules. |
18:50:05 | FromDiscord | <demotomohiro> Do you want to generate c++ code like this in older C++ standard? |
18:50:06 | FromDiscord | <demotomohiro> https://wandbox.org/permlink/SWjJ0gmX7WPf8Wpt |
18:51:37 | FromDiscord | <demotomohiro> It works with -std=c++17 but doesn't with -std=c++14 |
18:53:16 | * | Hideki_ joined #nim |
18:53:58 | Araq | yeah, like that |
18:57:14 | * | Hideki_ quit (Ping timeout: 240 seconds) |
18:58:17 | * | marmotini_ quit (Remote host closed the connection) |
19:02:23 | * | cyraxjoe quit (Ping timeout: 265 seconds) |
19:08:20 | FromDiscord | <demotomohiro> I have no idea other than initializing struct or class type with constructors, or explicit assignment statements. |
19:11:18 | Araq | hmm we could generate a constructor |
19:12:09 | Araq | I never considered that |
19:15:36 | FromGitter | <deech> It follows logically but Nim implicit initialization of `ref` to `nil` is a little surprising: ⏎ ⏎ ```proc f():ref int = discard ⏎ echo f()[]``` [https://gitter.im/nim-lang/Nim?at=5e1235d8809bc77efef40c8f] |
19:16:45 | Araq | being addressed with our not-nil RFC. |
19:17:32 | FromDiscord | <demotomohiro> It uses C++11 feature but you can set default value to member variables. |
19:17:32 | FromDiscord | <demotomohiro> https://wandbox.org/permlink/Ixcx1HROGIEQYVfL |
19:17:32 | FromDiscord | <demotomohiro> I don't know it works in the Nim C++ codegen. |
19:17:44 | Araq | however, after all these years I know one thing for sure, a small set of consistent rules that lead to occasional surprises is much better than a set rules always expanding to capture human "intuitions" |
19:17:46 | FromGitter | <deech> Araq, nice! |
19:18:00 | * | cyraxjoe joined #nim |
19:18:40 | FromGitter | <deech> Araq, yes agreed. But maybe worth a warning. I learned that stuffing "human intuition" violations in warnings is a nice compromise. |
19:18:53 | disruptek | what's your intuition for a ref? |
19:19:14 | Araq | that's true too, warnings can help |
19:19:21 | disruptek | that it perform a heap alloc? what if it's a type that requires initialization? |
19:19:54 | Araq | disruptek: that it doesn't compiler, nobody expects even more secret allocs |
19:20:00 | Araq | *compile+ |
19:20:21 | disruptek | oh, it should fail to compile if it's not initialized? |
19:21:01 | FromGitter | <deech> That it's initialized to `nil` but implicit `result` initialization had me scratching my head for a second. I can't think of an instance where that isn't a mistake so good to warn. |
19:21:56 | skrylar[m] | i see that password reset on the forum is still broken. bummer. |
19:22:30 | disruptek | i can think of instances where nil makes sense for result; how about "i cannot create that type" |
19:24:17 | disruptek | i am looking forward to notnil, though. |
19:25:04 | skrylar[m] | this is where Option types are nice /shrug |
19:25:36 | disruptek | yes, but technically you have the same problem. |
19:25:58 | skrylar[m] | those can at least differentiate "i returned nothing" from "i returned something: it was a nil" |
19:26:42 | disruptek | i like nim-result. i think it belongs in stdlib. although, it might not work with arc properly yet. |
19:26:58 | * | krux02 joined #nim |
19:27:47 | FromGitter | <deech> A warning that says something to the effect of "I'm returning the default initialized value for the result because you haven't read/assigned to it" would be the gist of what I'm suggesting. |
19:28:54 | skrylar[m] | i kinda do that lately by having an `unbox` function that accepts an output, optional default, and returns true or false based on if it gave you the default or the genuine value, which reads a little ugly but the semantics work :b |
19:30:15 | skrylar[m] | poking around with the promise/future model ... might be interesting to shove default checking in those too |
19:30:26 | skrylar[m] | bleh.then(..).default(..) |
19:32:15 | Araq | disruptek: so ... nimph worked with arc and then it didn't anymore? |
19:32:16 | FromGitter | <deech> It sounds like a trivial thing but it just happened to me when I `echo`ed what I intended to return for debugging purposes, forgot to remove it and got a `nil` when I called the function. In a small code base it's fine, in a large one when you're tired a warning is much appreciated. |
19:32:35 | disruptek | gittyup stopped working in that commit i linked. want another link? |
19:32:47 | Araq | I missed the link |
19:33:03 | disruptek | https://github.com/disruptek/gittyup/commit/2ebc3d18cd60df06eeca5894e4165348e94aca4f |
19:33:53 | Araq | ok but you said it's an arc regression |
19:34:01 | Araq | not that you changed your code |
19:34:16 | disruptek | nah, i said "it worked yesterday" 😉 |
19:34:33 | Araq | just imagine I could say on the forum, "first big project (nimph) compiles and run with arc" |
19:34:36 | disruptek | anyway, i am working on it. tightening up memory. |
19:34:39 | * | Araq needs a success |
19:35:12 | disruptek | it was working in 2.0.4, and i think that release has the same iterator semantics. |
19:35:50 | disruptek | so i think it has to do with manual alloc somehow. |
19:37:16 | Araq | it produced wrong C code, right? |
19:37:28 | disruptek | on linux/osx, yes. on windows, compilation hangs. |
19:37:51 | Araq | for the same reason, invalid C code |
19:37:55 | disruptek | https://github.com/disruptek/gittyup/runs/373100299 |
19:38:04 | Araq | it's just that osproc hangs for too much C compiler output |
19:38:10 | disruptek | ahh. |
19:38:32 | disruptek | when i looked at the code, it seemed that two Result types weren't matching up. |
19:38:50 | Araq | (and before you bash Windows once again, the other OSes merely have bigger buffers and osproc is just as broken on them too) |
19:38:56 | disruptek | noted. |
19:39:34 | disruptek | also, i'm yielding a template that builds the Result. so that's another possible wrinkle, i guess. |
19:40:11 | Araq | does it produce valid C code with the default GC? |
19:40:15 | disruptek | yeah. |
19:40:38 | Araq | I almost bet it doesn't but C is forgiving enough so we don't notice |
19:41:50 | disruptek | can't rule it out. |
19:50:35 | disruptek | i've never used a dev environment that was as friendly to my workflow. |
19:50:43 | disruptek | everyone should take the time to develop their own tooling. |
19:54:14 | FromDiscord | <mratsim> that's the reason why I maintain my own packages for data science: https://github.com/mratsim/arch-Data-Science |
19:54:27 | FromDiscord | <mratsim> instead of using the awful pip or conda |
19:55:06 | Araq | I wrote my own scatter plots via putPixel for this reason |
19:55:24 | Araq | was easier than figuring out matplotlib's clusterfuck API |
19:55:43 | disruptek | you and 100 other grumpy devs. |
19:55:44 | FromDiscord | <mratsim> don't use matplotlib |
19:56:06 | FromDiscord | <mratsim> it's like using Asembly |
19:56:38 | Araq | assembler is nice, matplotlib is more like computing with Roman numerals |
19:57:08 | FromDiscord | <mratsim> Assembler is nice when you have the tooling |
19:57:16 | FromDiscord | <mratsim> good luck with pure hexadecimal assembler |
19:57:25 | Araq | ah that's what you mean |
20:05:37 | Araq | once again, shall we add codegen support for suspension/yield points? |
20:06:22 | Araq | in the end it's what it comes down to, async transforms proc calls into isolated tasks you can run anywhere |
20:07:08 | Araq | no cactus stacks required, no split stacks, we have N threads that run tasks |
20:07:32 | Zevv | how should the codegen figure out what the "right" spots are to put those in? |
20:07:57 | Araq | put them into loops |
20:08:08 | Zevv | I don't want them in my inner tight loops probably? |
20:08:35 | Araq | put them in the outermost loop and also offer a .nosuspend pragma |
20:10:05 | Araq | Java uses loop strip mining to get the overhead into noise levels |
20:10:06 | disruptek | prefer truthy syntax like .yieldable versus .unyielding |
20:10:10 | Zevv | Pff that's a though one. You risk slowing down a lot of loops inadvertently |
20:10:25 | Zevv | disruptek: yes, but then you might just as well put an explict yield() in there |
20:10:49 | disruptek | i just mean that .no might not add anything syntactically. |
20:10:57 | Araq | as I said, it's well explored ground in Java |
20:10:59 | disruptek | let's not say what it isn't; let's say what it is. |
20:11:05 | * | endragor joined #nim |
20:11:19 | Zevv | I have zero java experience, so nothing to add here |
20:12:30 | disruptek | i think performance is always something you add, so .nosuspend is probably the right semantic. i just wish there was a better term. |
20:12:41 | FromDiscord | <mratsim> no idea, I prefer leaving that in developer hands |
20:12:55 | FromDiscord | <mratsim> when you use parallelFor you automatically get suspension points in Weave |
20:13:33 | Zevv | but we're talking async only here, right? |
20:13:36 | FromDiscord | <mratsim> but for example in state of the art matrix multiplication, I have 6 loops nesting level |
20:13:52 | FromDiscord | <mratsim> it's about inserting async suspension point in CPU-bound tasks |
20:14:00 | FromDiscord | <mratsim> to unify CPU and IO |
20:14:15 | FromDiscord | <mratsim> so that within a CPU-bound task you don't delay IO too much |
20:14:38 | Araq | exactly |
20:14:47 | Zevv | Sure, but especially with async I'd like my yields explicit |
20:15:14 | Zevv | there is no locking in place or other synchronization mechanisms, so by choosing my yield points one keeps code atomic and invariants invariant |
20:15:33 | FromDiscord | <mratsim> so going back to matmul, if you insert a suspension point in the inner loop, you're going to flush my handcrafter register allocations where I precisely use 12 registers for matmul and 4 registers for loop bounds, and you're going to kill my perf by a huge factor (I expect way more than 50%) |
20:15:53 | * | endragor quit (Ping timeout: 268 seconds) |
20:16:05 | FromDiscord | <mratsim> so i only insert my suspension points on the 2nd inner loop |
20:16:13 | FromDiscord | <mratsim> 2nd loop around the inner kernel* |
20:16:26 | Zevv | right, that's what I said, and that sounds pretty hard for the compiler to guess right |
20:16:47 | Zevv | and if I don't know where my code will yield, thinking about async gets harder |
20:16:53 | FromDiscord | <mratsim> yes |
20:16:59 | FromDiscord | <mratsim> explicit is better i think |
20:17:12 | FromDiscord | <mratsim> and after long experience, maybe we can think about making it implicit |
20:17:31 | FromDiscord | <mratsim> or having a pragma or template magic that does that |
20:17:41 | FromDiscord | <mratsim> {.implicitYield.} |
20:18:37 | FromDiscord | <mratsim> the whole deal about me writing linear algebra kernel from scratch is that compiler don't know how to generate fast code from them if I don't do 95% of the job |
20:18:44 | Zevv | How does this work in other languages? If there are 'hidden' yields, how do you sync your code? There are no locks, but my code gets preempted anyway? |
20:26:50 | Araq | well in some sense whenever you run 2 threads there is potential preemption |
20:27:10 | Araq | without you being aware of it, it works fine |
20:29:28 | FromDiscord | <mratsim> in anycase, weave doesn't need implicit yield, I can have a proc hook that threads trigger in my "loadBalance" proc or a closure iterator |
20:30:48 | FromDiscord | <mratsim> and asyncdispatch chronos can expose a "setAsyncDispatch" callback that allows them to be plugged into anything |
20:35:37 | FromDiscord | <mratsim> btw, do we want to keep the type name "Promise" for async? for now I will be using "Pledge" for CPU-bound task promises |
20:38:51 | disruptek | makes sense to me. |
20:39:09 | skrylar[m] | "cactus stacks" kek |
20:39:42 | FromDiscord | <inv> Hello, I found that playground has white text-color on white background in output. is it only my problem ? |
20:39:59 | skrylar[m] | was watching the talk on promise/a+ and some tooling they built with generators on top of that for async functions the other day actually |
20:47:01 | Zevv | So now we have Promises, AsyncFutures, Futures and Pledges. |
20:47:40 | Zevv | Sound like my kids. Tons of pledges and promises. Buy in the end, all of them get cancelled |
20:48:11 | disruptek | maybe they should be less suggestive of success. |
20:48:20 | disruptek | Wishes, Hopes, Dreams |
20:49:06 | Zevv | That would be pretty cool actually, so my code can there be sitting, waiting on a dream |
20:50:36 | FromDiscord | <mratsim> for now Weave pledges cannot be cancelled 😉 |
20:51:08 | FromDiscord | <mratsim> and you have Futures and Flowvars |
20:51:12 | FromGitter | <Albus70007> I have this two types: ⏎ ⏎ 1) 'type PlayerInputs* = object ⏎ ⏎ ```name*: string ⏎ rootsocket*: Socket ⏎ inputs*: PlayerInputs'*``` ... [https://gitter.im/nim-lang/Nim?at=5e124c40c23234403cd4c7df] |
20:52:26 | Zevv | araq: I was trying to get my Nim-in-linux-kernel-space running with arc, is there a shortcut to get --gc:arc on --os:standalone not to use theHeap, but lie directly on top of malloc()/free() for allocations? I'd like to get rid of the 32Mb allocation |
21:04:40 | FromGitter | <deech> What am I doing wrong here? If I wrap the inner `proc` on line 5 in parens it works: https://play.nim-lang.org/#ix=26vU |
21:07:06 | Zevv | I think I hit that once, the workaround is - you guessed - wrapping it inside parens |
21:07:13 | Zevv | It was noted it was a quirk of the nim parser |
21:09:10 | FromGitter | <deech> Ok, that's odd. |
21:11:03 | FromGitter | <deech> This doesn't work either `run f, proc (s:string) = echo s`. |
21:12:13 | FromGitter | <deech> And neither does: ⏎ ⏎ ```run "hello world": ⏎ proc (s:string) = ⏎ echo s``` [https://gitter.im/nim-lang/Nim?at=5e12512d6dda2430fed56962] |
21:13:16 | * | sschwarzer joined #nim |
21:14:43 | sschwarzer | What's a recommended way to convert a string like "abc" to a sequence of strings like @["a", "b", "c"] ? I could write a loop of course, but I wonder if there's a simpler way. |
21:15:45 | FromGitter | <deech> Try `toSeq(items("abc"))` , you need to import `strutils` and `sequtils`. |
21:15:47 | sschwarzer | "abc".toSeq() gives me a sequence of chars, which isn't quite what I want. |
21:16:22 | Zevv | !eval echo "abc".distribute(3) |
21:16:24 | NimBot | Compile failed: /usercode/in.nim(1, 11) Error: attempting to call undeclared routine: 'distribute' |
21:16:32 | Zevv | !eval import sequtils; echo "abc".distribute(3) |
21:16:34 | NimBot | Compile failed: /usercode/in.nim(1, 28) Error: type mismatch: got <string, int literal(3)> |
21:16:42 | Zevv | daaang |
21:16:49 | FromGitter | <deech> How about `toSeq(items("abc")).mapIt($it)`? |
21:17:18 | sschwarzer | deech: I tried something like that, but let me check |
21:18:58 | sschwarzer | deech: It works, thanks. I had used this (almost), but written $It instead of $it . |
21:19:36 | sschwarzer | Actually I have now "abc".toSeq().mapIt($it) , without `items` |
21:19:56 | Zevv | !eval import npeg; echo patt(+>1).match("abc").captures |
21:20:00 | NimBot | @["a", "b", "c"] |
21:20:04 | Zevv | bwah that's ugly |
21:20:08 | sschwarzer | Zevv: oh dear :) |
21:20:23 | Zevv | don't go there :) |
21:20:43 | sschwarzer | Zevv: "abc".toSeq().mapIt($it) works, so I'm set. :-) |
21:20:59 | Zevv | you should! I was hoping distribute works with strings, but it's limited to seq[T] |
21:21:00 | sschwarzer | Unless there's an even simpler way |
21:21:14 | * | ltriant joined #nim |
21:21:25 | Zevv | which makes me wonder again why nim does not treat strings and seq[char] the same, since technically they are |
21:21:38 | Zevv | is it the trailing '\0'? |
21:22:01 | sschwarzer | I'm really enjoying Nim. I'm also experimenting with the cligen package, very interesting. |
21:23:16 | Zevv | Always good to hear! Please also enjoy our *fine* community services at #nim and forum.nim-lang.org! |
21:24:32 | FromGitter | <deech> Free continental breakfast |
21:25:51 | Zevv | there is no such thing as a free breakfast |
21:26:28 | sschwarzer | Zevv: I've written several forum postings already (both questions and answers) :) |
21:27:49 | sschwarzer | It seems cblake isn't here? Or under a different name? |
21:36:15 | sschwarzer | Thanks for your help, bye! |
21:36:34 | * | sschwarzer quit (Quit: leaving) |
21:38:01 | * | luis_ joined #nim |
21:39:35 | * | ltriant quit (Read error: Connection reset by peer) |
21:39:47 | * | nsf quit (Quit: WeeChat 2.7) |
21:40:26 | * | narimiran quit (Ping timeout: 240 seconds) |
21:41:23 | FromDiscord | <exelotl> uuh, the nim compiler appears to be stuck on a CC step |
21:41:30 | FromDiscord | <exelotl> |
21:41:30 | FromDiscord | <exelotl> https://cdn.discordapp.com/attachments/371759389889003532/663497321610477568/unknown.png |
21:41:46 | FromDiscord | <exelotl> anyone know how I can debug this? :\ |
21:42:42 | * | ltriant joined #nim |
21:42:44 | FromDiscord | <exelotl> previously I was using `--compileOnly` and relying on a makefile to compile the C files |
21:45:49 | FromDiscord | <exelotl> ohh it's this issue https://forum.nim-lang.org/t/5396#33815 |
21:58:58 | * | tane quit (Quit: Leaving) |
21:59:36 | * | filcuc joined #nim |
21:59:49 | zedeus | ahh finally! I got MultipartData file streaming working smoothly without any API changes |
22:08:04 | * | luis_ quit (Ping timeout: 248 seconds) |
22:15:54 | * | ng0 joined #nim |
22:15:54 | * | ng0 quit (Changing host) |
22:15:54 | * | ng0 joined #nim |
22:17:21 | * | luis_ joined #nim |
22:17:21 | * | luis_ quit (Remote host closed the connection) |
22:17:50 | * | luis_ joined #nim |
22:18:34 | * | luis_ quit (Client Quit) |
22:33:16 | * | neceve quit (Remote host closed the connection) |
22:36:47 | shashlick | Araq: when you get a chance, curious about https://github.com/nim-lang/Nim/issues/13047 |
22:36:49 | disbot | ➥ Compiler still needs -d:nimOldCaseObjects in non-danger mode ; snippet at 12https://play.nim-lang.org/#ix=26wx |
22:38:47 | disruptek | got a new bot feature for you all. |
22:39:00 | disruptek | Define a footnote with `~term is /some text here/` and fetch definitions with `~term`. |
22:40:27 | shashlick | you need a web page with bot features documented along with examples |
22:41:38 | disruptek | ~rfc is a `Request For Comments`; a proposal for discussion, such as you might find at https://github.com/nim-lang/RFCs |
22:41:49 | disruptek | ~rfc |
22:42:10 | disruptek | hmm, i guess it should share it with the whole channel. |
22:42:53 | FromDiscord | <mratsim> someone has a clever workaround for this? https://github.com/nim-lang/Nim/issues/13048 |
22:42:55 | disbot | ➥ recursive default call in type sections: invalid type in this context for proc ; snippet at 12https://play.nim-lang.org/#ix=26wy |
22:45:27 | FromDiscord | <mratsim> I guess I have to write a macro with getImpl |
22:53:33 | skrylar[m] | Zevv: some day the password reset on the forums will even work :^) |
22:54:45 | * | Hideki_ joined #nim |
22:59:18 | * | Hideki_ quit (Ping timeout: 268 seconds) |
23:03:34 | * | solitudesf quit (Ping timeout: 258 seconds) |
23:04:46 | * | abm quit (Quit: Leaving) |
23:04:47 | disruptek | it's confusing that when you login to the forum, the dialog isn't dismissed. i have to refresh the page to discover that the login worked. |
23:06:32 | FromDiscord | <mratsim> yep |
23:06:50 | FromDiscord | <mratsim> found a workaround for my issue, ugly macros to the rescue |
23:10:25 | * | federico3 quit (Quit: http://quassel-irc.org - Chat comfortably. Anywhere.) |
23:12:18 | dom96 | disruptek, which dialog? |
23:12:37 | disruptek | the authentication dialog presented when i click the signin button. |
23:12:53 | * | lmariscal06 quit (Quit: I'm Out!) |
23:13:13 | dom96 | in what way is it not dismissed? |
23:13:18 | * | uu91 quit (Remote host closed the connection) |
23:13:25 | dom96 | I just logged in and it went away as soon as I was logged in |
23:13:48 | disruptek | i guess in a different way to that. |
23:13:57 | disruptek | chrome 72. |
23:13:59 | dom96 | you see any errors in console? |
23:14:06 | dom96 | guess karax is failing |
23:14:15 | dom96 | I'm on FF |
23:14:20 | disruptek | Uncaught Error: Error: unhandled exception: same(kxi.currentTree, getElementById(document, kxi.rootId), 0) [AssertionError] |
23:14:24 | dom96 | yep |
23:15:03 | disruptek | i can run chrome 80, but it's not as fast as 72. |
23:15:29 | * | lmariscal06 joined #nim |
23:15:55 | disruptek | seems to produce the same error, though. |
23:16:22 | dom96 | it's possible this has been fixed in latest Karax, the forum's front end hasn't been rebuilt in a while |
23:16:32 | disruptek | yeah, looks like ~17mos. |
23:19:40 | disruptek | ~forum is Nim has a forum at https://forum.nim-lang.org/ -- ask @dom96 for help with any account issues. |
23:19:40 | disbot | Nim has a forum at https://forum.nim-lang.org/ -- ask @dom96 for help with any account issues. |
23:25:03 | zedeus | dom96: please take a look at #12982 when you have time |
23:25:04 | disbot | https://github.com/nim-lang/Nim/pull/12982 -- 3Implement file streaming for httpclient's MultipartData |
23:30:02 | * | Vladar quit (Quit: Leaving) |
23:32:45 | * | federico3 joined #nim |
23:37:37 | * | NimBot joined #nim |
23:49:08 | * | endragor joined #nim |