00:25:53 | * | vicfred_ quit (Quit: Leaving) |
00:26:12 | * | vicfred joined #nim |
00:40:07 | * | Trustable quit (Remote host closed the connection) |
01:01:24 | * | Zevv quit (Ping timeout: 256 seconds) |
01:08:11 | * | Zevv joined #nim |
01:11:55 | * | theelous3 quit (Ping timeout: 240 seconds) |
01:12:39 | * | kenran joined #nim |
01:17:23 | * | kenran quit (Ping timeout: 240 seconds) |
01:40:26 | disruptek | to quote durian dan, "i smell like i code." |
01:41:25 | * | apahl quit (Ping timeout: 240 seconds) |
01:43:46 | * | apahl joined #nim |
02:15:37 | * | waleee-cl quit (Quit: Connection closed for inactivity) |
02:24:27 | * | muffindrake quit (Ping timeout: 260 seconds) |
02:26:40 | * | muffindrake joined #nim |
03:06:34 | * | arecacea1 quit (Remote host closed the connection) |
03:06:57 | * | arecacea1 joined #nim |
03:13:54 | * | kenran joined #nim |
03:14:45 | * | thomasross quit (Ping timeout: 265 seconds) |
03:18:11 | * | kenran quit (Ping timeout: 240 seconds) |
03:25:27 | FromDiscord | <iWonderAboutTuatara> Hey, is there a relatively easy way to use py libraries in Nim? |
03:25:36 | FromDiscord | <iWonderAboutTuatara> If I have to rewrite it's probably not worth it |
03:25:40 | FromDiscord | <Kaynato> I've had good experience with nimpy |
03:25:53 | FromDiscord | <iWonderAboutTuatara> I've heard it works well |
03:26:02 | FromDiscord | <iWonderAboutTuatara> I'm trying to get moviepy though |
03:26:24 | FromDiscord | <iWonderAboutTuatara> Or anything else in Nim that can cut videos with ffmpeg |
03:29:03 | * | rockcavera quit (Remote host closed the connection) |
03:33:13 | * | arecacea1 quit (Remote host closed the connection) |
03:33:38 | * | arecacea1 joined #nim |
04:06:01 | * | supakeen quit (Quit: WeeChat 2.9) |
04:06:38 | * | supakeen joined #nim |
04:33:54 | * | krux02_ quit (Remote host closed the connection) |
04:35:42 | * | narimiran joined #nim |
04:42:24 | * | krux02 joined #nim |
05:00:34 | * | krux02 quit (Remote host closed the connection) |
05:14:28 | * | kenran joined #nim |
05:19:56 | * | kenran quit (Ping timeout: 265 seconds) |
05:21:40 | kinkinkijkin | iWonderAboutTuatara is there a set of libav[codec] bindings for nim that you can find? |
05:23:03 | kinkinkijkin | hmm i found some though they're from 2017 and auto-generated |
05:24:44 | * | kenran joined #nim |
05:40:35 | voltist | Here's a super weird problem: Starting any network manager (NetworkManager, wpa_supplicant, etc.) when I have a USB wifi dongle plugged in stalls all gui applications and sudo without using any RAM |
05:40:42 | voltist | I think my computer is haunted |
05:41:08 | FromDiscord | <Elegant Beef> Just a tad bit |
05:43:22 | * | apahl quit (Ping timeout: 260 seconds) |
05:43:50 | FromDiscord | <Rika> its reinstall time |
05:44:02 | * | apahl joined #nim |
05:44:23 | voltist | Noooooo! |
05:44:52 | FromDiscord | <Elegant Beef> Time to install X distro |
05:45:06 | FromDiscord | <Elegant Beef> X being the distro that the reader prefers |
05:45:58 | voltist | Of course |
05:48:42 | FromDiscord | <Rika> `echo &"{134.693:>3.0f}"` how can i get this number with no trailing decimal point? |
05:48:50 | FromDiscord | <Rika> without stripping it out manually, of course |
05:52:32 | FromDiscord | <Elegant Beef> I dont see a way to output the integer part of the float |
05:52:59 | FromDiscord | <Elegant Beef> Oh guess it also rounds |
05:53:21 | FromDiscord | <Rika> rounding is fine |
05:53:31 | FromDiscord | <Rika> i just dont want the damn trailing decimal point |
05:54:19 | narimiran | `echo (&"{134.693:>3.0f}").strip(chars = {'.'})` :D |
05:54:40 | FromDiscord | <Elegant Beef> Simpler to just `echo &"{134.693.round.int}"` |
05:54:42 | FromDiscord | <Rika> > without stripping it out manually, of course |
05:55:15 | FromDiscord | <Rika> this is probably one reason why we cant just remove round i guess |
05:55:34 | FromDiscord | <Elegant Beef> There are only two references to decimal points both just talk about characters. |
05:55:38 | FromDiscord | <Elegant Beef> Why would you remove round? |
05:55:53 | FromDiscord | <Rika> theres a lot of discussion to remove round |
05:56:02 | narimiran | beCaUsE it Is nOt eXaCT |
05:56:17 | FromDiscord | <Rika> kru_ told me it wasnt that |
05:56:29 | FromDiscord | <Rika> or idk who told me exactly actually |
05:59:03 | * | Zevv quit (Quit: leaving) |
05:59:12 | FromDiscord | <Elegant Beef> both round procs are from C Libs |
05:59:16 | * | Zevv joined #nim |
05:59:51 | narimiran | if you want only `134` (without rounding), i think the simplest thing to do is just `int 134.693` |
06:01:18 | FromDiscord | <Rika> what would i do if i do? the strip part? |
06:02:33 | narimiran | i don't understand the question |
06:07:30 | * | endragor quit (Remote host closed the connection) |
06:07:57 | * | endragor joined #nim |
06:10:11 | FromDiscord | <Rika> what would i do if i wanted rounding |
06:14:07 | FromDiscord | <Elegant Beef> I'd assume use the round to int method or striip |
06:14:37 | * | endragor quit (Ping timeout: 264 seconds) |
06:18:32 | narimiran | @Rika `round.int` solution mentioned before |
06:21:03 | FromDiscord | <Rika> okay |
06:21:27 | * | solitudesf joined #nim |
06:21:30 | * | endragor joined #nim |
06:32:31 | FromDiscord | <Rika> wish i could do optional dependencies in nimble |
06:36:06 | FromDiscord | <Elegant Beef> couldnt you use `when compiles( import module)` |
06:36:37 | FromDiscord | <Rika> i mean when someone installs the library they'd see that there are optional dependencies available |
06:36:47 | FromDiscord | <Rika> that would be nice kinda |
06:37:11 | FromDiscord | <Rika> dont want to require installing `stint` for a fuckin progress bar |
06:37:29 | FromDiscord | <Rika> actually wait just realized i dont need that |
06:37:37 | FromDiscord | <Rika> i need another package, something for float128 |
06:37:37 | FromDiscord | <Elegant Beef> Cant you use the when compiles for where you'd use the module |
06:37:50 | FromDiscord | <Rika> i can but they would never realize that there are optional deps |
06:37:53 | FromDiscord | <Rika> until they read the code |
06:38:10 | FromDiscord | <Elegant Beef> Well put it on your readme no? |
06:38:28 | FromDiscord | <Elegant Beef> *if you require X module in your nimble you can use Y* |
06:38:31 | FromDiscord | <Rika> i guess |
06:39:14 | FromDiscord | <Rika> huh nim has no "pure" big float libraries |
06:39:24 | FromDiscord | <Rika> or maybe im not searching hard enough |
06:40:00 | FromDiscord | <Rika> guess its time to implement it myself or something |
06:40:57 | FromDiscord | <Elegant Beef> this exists https://github.com/JohnAD/decimal128 |
06:41:11 | FromDiscord | <Rika> okay thats good enough, should have float tag imo |
06:42:08 | FromDiscord | <Elegant Beef> When pmunch looked at it for smalltalk it lacked anything but addition/subtraction so no clue if it's changed |
06:42:36 | FromDiscord | <Elegant Beef> lol smalltalk, my brain is dumb, stacklang |
06:42:46 | FromDiscord | <Rika> last commit 2 months ago so |
06:43:01 | FromDiscord | <Rika> ah its not a float |
06:43:15 | FromDiscord | <Rika> its literally a decimal type; i dont know if i need decimal accuracy |
06:43:20 | FromDiscord | <Rika> i only need bigger floats ๐ |
06:43:41 | FromDiscord | <Rika> wonder if using float128 is faster than a dec128 |
06:45:28 | FromDiscord | <Elegant Beef> Is speed really an issue when it comes to a TUI progress bar? |
06:46:26 | FromDiscord | <Rika> no its not, hence my "wondering" |
06:46:40 | FromDiscord | <Rika> it would be nice to learn how to make this though |
06:46:54 | FromDiscord | <Elegant Beef> float 128? |
06:47:06 | * | ptdel quit (Quit: https://quassel-irc.org - Chat comfortably. Anywhere.) |
06:47:32 | FromDiscord | <Rika> yeah |
06:55:52 | FromDiscord | <Rika> perhaps ill focus on making this threaded instead of contemplating |
07:18:19 | FromDiscord | <Admin> How would i change the available elliptic curves for a http client ? |
07:20:42 | * | Senketsu joined #nim |
07:25:11 | * | Senketsu quit (Ping timeout: 256 seconds) |
07:28:30 | FromDiscord | <Elegant Beef> Eliptical curves for http? |
07:31:06 | * | krux02 joined #nim |
07:34:38 | FromDiscord | <Admin> yes |
07:34:55 | FromDiscord | <Admin> the ssl context |
07:39:26 | FromDiscord | <mratsim> same question as yesterday, same answer, you need to tinker with the OpenSSL wrapper low-level internals |
07:39:41 | FromDiscord | <mratsim> https://nim-lang.org/docs/openssl.html |
07:42:05 | FromDiscord | <Admin> sorry feel asleep yday |
07:42:13 | FromDiscord | <Admin> yea i looked at that but i dont see the settin |
07:42:14 | FromDiscord | <Admin> (edit) 'settin' => 'setting' |
07:46:40 | * | andinus joined #nim |
07:47:01 | Zevv | alehander92: what about targetting webassmbly |
07:47:55 | * | apahl quit (Ping timeout: 240 seconds) |
07:49:12 | * | apahl joined #nim |
07:51:44 | * | PMunch joined #nim |
07:53:37 | PMunch | @Elegant, it was mostly trig functions and such I was missing |
07:53:51 | PMunch | Basically I wanted a drop in replacement for the math module |
07:54:02 | FromDiscord | <Elegant Beef> I did say anything but add/subtract |
07:54:14 | PMunch | Because everything in the math module is available in stacklang :) |
07:54:23 | PMunch | Ah, just skimmed the log :P |
07:54:31 | PMunch | I think it has multiplication and division as well |
07:54:51 | FromDiscord | <Elegant Beef> When you going to accept my optionutils PR, or are you? |
07:55:52 | PMunch | Hmm, lets see |
07:55:52 | FromDiscord | <Elegant Beef> *The code quality is subpar and looks like a monkey wrote it* That's what i expect to see in response |
07:56:33 | PMunch | Why do you do this instead of body[6]: body.findChild(it.kind == nnkStmtList) |
07:57:20 | FromDiscord | <Elegant Beef> Was uncertain if it'd move position |
07:57:43 | PMunch | Nah, they're stable |
07:57:55 | PMunch | You can also use the macroutils module I wrote and just do body.body |
07:58:06 | FromDiscord | <Elegant Beef> ah |
07:58:12 | PMunch | (But `body` is a but poorly named :P) |
07:58:49 | FromDiscord | <Elegant Beef> it's the body of the proc def ๐ |
07:59:24 | PMunch | No I meant the argument to withSome, that should just be called `procDef` or something |
07:59:37 | FromDiscord | <Elegant Beef> probably |
07:59:38 | PMunch | Then it would be `procDef.body` if you were using macroutils |
07:59:49 | PMunch | Which is quite readable :) |
08:00:58 | FromDiscord | <Elegant Beef> But that adds a dependancy to the repo which you previously didnt have ๐ |
08:05:29 | PMunch | That's true |
08:05:41 | PMunch | But libraries are written to be used :) |
08:12:37 | FromDiscord | <Elegant Beef> So those are you only complaints? |
08:12:54 | FromDiscord | <Rika> people hate large dependencies, not dependencies in general, right? |
08:12:58 | PMunch | Hold on, I'm leaving my feedback as a review on GitHub :) |
08:13:56 | FromDiscord | <Elegant Beef> I think they hate the spiderweb of dependancies |
08:14:56 | FromDiscord | <Elegant Beef> Also no clue if you noticed pmunch but i didnt `if(a)` |
08:15:16 | FromDiscord | <Elegant Beef> I wrote mostly nimidiotic code |
08:16:13 | * | hnOsmium0001 quit (Quit: Connection closed for inactivity) |
08:18:56 | PMunch | `if(a)`? |
08:19:22 | stisa[m] | is there somewhere I can read about how sets are implemented in nim? `echo sizeof({1})` gives me 8192 and i'd like to understand why |
08:19:32 | FromDiscord | <Elegant Beef> i typically use C like if statements |
08:19:42 | * | awe00 joined #nim |
08:19:47 | FromDiscord | <Elegant Beef> Where they're wrapped in `()` |
08:19:58 | PMunch | Aaah, right |
08:20:31 | FromDiscord | <mratsim> @stisa, sets can hold up to int16 (enum are at most 2 bytes) |
08:21:19 | FromDiscord | <Varriount> @stisa They are implemented as bit sets |
08:22:07 | FromDiscord | <mratsim> i.e. I think if you use a set for an integer it assumes you may have up to int16 value inside, though it doesn't seem to fit with 8192 in size since 2 bytes can hold 65536 values |
08:22:43 | FromDiscord | <mratsim> anyway it's all there: https://github.com/nim-lang/Nim/blob/devel/compiler/bitsets.nim |
08:23:08 | FromDiscord | <Varriount> I really do like Nim's built-in sets they are quite useful |
08:23:22 | stisa[m] | thanks, I'll have a look |
08:23:34 | stisa[m] | I was searching for nkCurly in the compiler and got a little lost |
08:23:36 | FromDiscord | <mratsim> ah sorry this seems a fallback |
08:23:50 | FromDiscord | <mratsim> for bootstrapping maybe |
08:24:00 | ForumUpdaterBot | New thread by Halloleo: How to know where a proc is defined - or: Newbie tries to get used to unqualified imports, see https://forum.nim-lang.org/t/6728 |
08:24:20 | FromDiscord | <Varriount> https://en.m.wikipedia.org/wiki/Bit_array |
08:24:35 | FromDiscord | <Varriount> @stisa ^ |
08:25:23 | FromDiscord | <mratsim> I'm pretty sure Nim bitsets are stack allocated: https://github.com/nim-lang/Nim/blob/v1.2.6/compiler/bitsets.nim#L15 |
08:25:30 | FromDiscord | <mratsim> Was i wrong? |
08:25:54 | PMunch | They are implemented as bitsets as you say so if the value 0 is in the set then the first bit is set. If the value uint16.high is in the set then the topmost bit is set. So it requires one bit per value, uint16 can store 65536 different values, and at 8 bits per byte that is 65536/8 = 8192 bytes |
08:25:59 | PMunch | It all makes sense |
08:26:33 | FromDiscord | <mratsim> ah right |
08:27:27 | stisa[m] | ok, thanks! I was just a little surprised, but it makes sense yeah |
08:28:04 | FromDiscord | <Varriount> @stisa It might seem limiting, but you'd be surprised at how many things can be represented using enums |
08:31:51 | stisa[m] | I know I know, I was just trying to understand them better to implement them in my toy webassembly backend |
08:33:15 | * | fowl_ quit (Read error: Connection reset by peer) |
08:33:26 | * | sirn quit (Read error: Connection reset by peer) |
08:33:54 | * | kwilczynski quit (Ping timeout: 260 seconds) |
08:35:04 | * | sirn joined #nim |
08:36:31 | * | sirn quit (Max SendQ exceeded) |
08:36:47 | FromDiscord | <mratsim> I should probably write a bitarray or packed array library |
08:38:31 | FromDiscord | <mratsim> It's actually super simple once you figure out the math: https://github.com/mratsim/constantine/blob/master/constantine/elliptic/ec_endomorphism_accel.nim#L70-L102 |
08:38:38 | * | sirn joined #nim |
08:39:17 | * | fowl_ joined #nim |
08:40:21 | * | kwilczynski joined #nim |
08:40:44 | FromDiscord | <Rika> how do i check if threads is off again |
08:42:31 | FromDiscord | <Elegant Beef> Also pmunch turnsout base `macros` has a body accessor |
08:48:52 | FromDiscord | <Clyybber> @Rika compileOption("threads") |
08:49:20 | FromDiscord | <Rika> okay thanks |
08:51:07 | * | quetzalb quit (Remote host closed the connection) |
08:52:07 | FromGitter | <alehander92> zevv well |
08:52:12 | FromGitter | <alehander92> maybe ? i am not sure |
08:52:12 | FromDiscord | <Elegant Beef> But anywho pmunch should fit your entire review |
09:01:22 | * | rakgew[m] joined #nim |
09:03:25 | PMunch | Oh yes, that was added at some point |
09:03:49 | PMunch | macroutils is a lot more comprehensive though, it has all the accessors you would ever need |
09:13:18 | * | rakgew[m] sent a long message: < https://matrix.org/_matrix/media/r0/download/matrix.org/sDFAQqACVSNeMBBjhMTdhkts/message.txt > |
09:21:47 | FromDiscord | <Rika> @rakgew https://nim-lang.org/docs/nimc.html#cross-compilation you need to further move the c sources and compile on the machine itself or use a c cross compiler |
09:23:55 | FromDiscord | <Rika> also i think its `aarch64` and not arm64, but i dont know |
09:25:47 | * | pangey quit (Ping timeout: 240 seconds) |
09:26:04 | * | lritter joined #nim |
09:27:56 | rakgew[m] | thank you Rika. is it not possible to use build it on the amd64 machine via cross compiler tool chain as mentioned in the docs? |
09:28:34 | * | pangey joined #nim |
09:29:36 | * | rakgew[m] sent a long message: < https://matrix.org/_matrix/media/r0/download/matrix.org/PBHmtbrFnbtEULuMzNjzKIqe/message.txt > |
09:30:54 | rakgew[m] | I tried aarch64 earlier, but the the compiler told me aarch64 would not be available but arm64 was listed. |
09:36:01 | FromDiscord | <lqdev> what happens if nim fails to load some dynlib? does it kill the program? |
09:38:49 | FromDiscord | <dom96> yes |
09:38:56 | FromDiscord | <lqdev> damn |
09:39:52 | FromDiscord | <lqdev> i'm trying to load Xlib but make it _optional_ |
09:39:58 | FromDiscord | <mratsim> @rakgew, you need to use arm64 not aarch64, and there is a recent post detailing cross compilation via Github Actions in the forum |
09:40:01 | PMunch | @Elegant, added another comment |
09:40:08 | FromDiscord | <lqdev> guess i'll have to load it myself using the dynlib module |
09:46:33 | Araq | lqdev: doesn't sound like a good idea |
09:47:17 | Araq | make up your mind if you need Xlib or not |
09:47:31 | Araq | and in the worst case, provide two separate binaries |
09:47:44 | Araq | so that your users can understand the consequences |
09:48:21 | Araq | "huh, my experience with the software just got so much shitter, why is that?" is not good design |
09:49:26 | FromDiscord | <lqdev> i need xlib in case it's installed on the user's PC |
09:49:28 | FromDiscord | <lqdev> otherwise wayland |
09:51:36 | FromDiscord | <lqdev> and also, i don't want to force X11 users to install wayland |
09:53:23 | Araq | I'd build two binaries and maybe a startup dispatch script |
09:54:23 | Araq | the script can then fail in all sort of mysterious ways and the resulting Unix experience will make people happy |
09:54:49 | FromDiscord | <lqdev> but i'm not building an app, i'm building a library |
09:55:02 | FromDiscord | <lqdev> i don't want my users to have to do some weird business with scripts and whatnot. |
09:57:07 | Araq | I don't want my libraries to do runtime dependency detection |
09:57:17 | Araq | can't QA that |
09:57:34 | Araq | better offer a --define switch |
09:58:30 | rakgew[m] | mratsim thank you for the pointer! I will search for that forum post. |
10:04:21 | * | theelous3 joined #nim |
10:04:46 | * | eery quit (Ping timeout: 256 seconds) |
10:09:53 | * | eery joined #nim |
10:11:44 | * | tane joined #nim |
10:18:29 | Zevv | PMunch: repo changed to https://github.com/zevv/fixedpoint. I made a stupid hacky solution for the generic converter problem: a template is used to both define the type, and to create a toType() proc for converting static[float] to that specific type |
10:19:59 | Zevv | it's pretty tedious to create all the operators for mixed fp sizes tho :) |
10:24:06 | PMunch | "Mixing different fixed point types in operations is someimes supported." haha :P |
10:38:28 | planetis[m] | why did you switch to object from distinct? |
10:40:41 | * | FromDiscord quit (Remote host closed the connection) |
10:40:56 | * | FromDiscord joined #nim |
10:42:55 | Zevv | to avoid confusion if people try to convert |
10:43:03 | Zevv | that just shouldnt work |
10:43:40 | FromGitter | <alehander92> guys |
10:43:48 | FromGitter | <alehander92> do you want to solve the collatz conjecture |
10:47:09 | * | awe00 quit (Ping timeout: 258 seconds) |
10:48:46 | PMunch | Well, yes |
10:49:03 | Zevv | oh i did some time ago, but i guess i forgot how |
10:49:04 | PMunch | Zevv, is your package in nimble? |
10:49:34 | Zevv | nope. just nimble git it for now. im not even sure its fit for consumption |
10:49:48 | Zevv | its more like an experiment to see how far typing can take this |
10:50:59 | Zevv | i think the mechanics work, but the implementation is tricky and testing is a pita |
10:51:45 | * | awe00 joined #nim |
10:52:05 | Araq | https://github.com/nim-lang/RFCs/issues/247 arrived |
10:52:08 | disbot | โฅ Flexible serialization with a mild focus on JSON ; snippet at 12https://play.nim-lang.org/#ix=2vhM |
10:52:18 | PMunch | I guess I'll test it in production and see :) |
10:54:29 | FromGitter | <alehander92> finally |
10:55:42 | FromDiscord | <Rika> thats a nice rfc |
10:55:52 | FromGitter | <alehander92> btw the json issue is more subtle for enums |
10:56:03 | FromGitter | <alehander92> in the javascript backend it's so much easier to just map them to integers |
10:56:19 | FromGitter | <alehander92> because then the direct javascript parse generates a value |
10:56:27 | FromGitter | <alehander92> that can be usually cast-ed to the nim type |
10:56:39 | FromGitter | <alehander92> but i guess this isn't so important indeed |
10:57:14 | FromGitter | <alehander92> but why not `to(Type, ..)` similarly to the status serialization |
10:57:57 | FromDiscord | <Rika> json is meant to be human readable right? so that means enums should map to strings no? |
10:58:30 | FromDiscord | <Rika> imagine having an object that has fields that are of different enums |
10:58:49 | FromDiscord | <Rika> the integer mess you'd have after converting to json... |
10:59:37 | FromGitter | <alehander92> yeah i agree, it's just a note |
11:00:29 | Zevv | oh look PMunch, I accidentally gave you full access to the repo |
11:00:32 | Zevv | how convenient |
11:00:41 | PMunch | Haha :P |
11:00:50 | PMunch | Not wanting to deal with PRs? |
11:01:34 | Zevv | im on holidays remember |
11:01:54 | PMunch | Oooh right |
11:15:36 | planetis[m] | now i wonder if unsigned ints should be used for fixed point |
11:15:54 | planetis[m] | i think all the libraries i saw used signed ints |
11:17:51 | planetis[m] | you need to take care of the sign bit manually when using uints |
11:23:48 | planetis[m] | do you specifically need to be able to do ops between different number formats? |
11:30:28 | planetis[m] | i should benchmark the distinct version versus the object, i suspect distinct might be faster |
11:41:25 | Zevv | well, just use signed for signed and unsigned for unsigned, right |
11:41:41 | Zevv | and ops between formats is power |
11:42:01 | Zevv | like for pmunchs game. speed is s8.2, position is u16.4 |
11:44:38 | FromDiscord | <19> is it normal to take 5.193 sec to compile `echo "hello world"`? |
11:44:57 | FromDiscord | <lqdev> not really |
11:45:08 | FromDiscord | <Recruit_main707> the first time maybe |
11:45:21 | FromDiscord | <Recruit_main707> if your pc is not very fast |
11:45:42 | FromDiscord | <19> i have a fast machine |
11:46:30 | FromDiscord | <Rika> it should be sub-second afaik |
11:47:35 | FromDiscord | <19> weird |
11:47:57 | FromDiscord | <19> in vcc it takes 5.193, in gcc it takes 3.284 |
11:49:13 | FromDiscord | <Rika> thats oddly high |
11:49:30 | FromDiscord | <Rika> what machine are you using |
11:49:43 | FromDiscord | <19> win 10, threadripper 2990wx |
11:50:24 | FromDiscord | <Rika> god damn okay |
11:50:28 | FromDiscord | <Rika> that is weird |
11:54:03 | Zevv | how did you install nim?\ |
11:55:06 | FromDiscord | <19> downloaded the zip and extracted them |
11:55:17 | FromDiscord | <19> then ran the finish.exe |
11:55:25 | Araq | with unsigned you'll never find all the overflow bugs, sounds dangerous |
11:55:53 | Zevv | true, but didn't inent to :) |
11:59:44 | narimiran | @19 do you have antivirus? |
12:00:17 | FromDiscord | <19> no |
12:00:58 | FromDiscord | <19> it compiles an sdl app faster than a hello world app |
12:01:19 | FromDiscord | <Recruit_main707> how can i define a radian type, so that it will go down to cero if it reaches 2*pi? maybe with a concept? |
12:02:10 | * | NimBot joined #nim |
12:05:52 | FromDiscord | <19> sdl app: 32005 LOC; 2.797 sec; 24.684MiB peakmem;โตhello world app: 14209 LOC; 2.636 sec; 16.078MiB peakmem; โตok its back to 2.6 secโตtbh i dont really care xD |
12:06:01 | * | supakeen quit (Quit: WeeChat 2.9) |
12:06:46 | * | supakeen joined #nim |
12:09:18 | * | theelous3_ joined #nim |
12:23:40 | PMunch | @19, that still sounds high |
12:24:07 | PMunch | On my machine (i7 4770K) it takes 0.47s to compile `echo "hello world"` |
12:24:34 | PMunch | To compile a release build it takes 1.3s |
12:24:47 | PMunch | Do you have a nim.cfg with some weird parameters in it? |
12:25:40 | PMunch | Hmm, I think it's time to refactor this project now.. |
12:26:15 | PMunch | Part of the GameJam challenge was to have pretty code, but since it's a microcontroller that sometimes have to yield to efficiency |
12:26:48 | PMunch | Now I just need to find the perfect set of templates to hide all the optimisations and make the code super clean and readable |
12:26:57 | FromDiscord | <19> i only change the nimcfg cc parameter to either vcc or gcc |
12:27:11 | PMunch | Hmm |
12:27:16 | PMunch | My tests where done with GCC |
12:27:28 | PMunch | But I'm on Linux, so that might change something |
12:39:32 | * | rockcavera joined #nim |
12:39:53 | PMunch | Can you do a `case` on a static enum and have it work as a series of when statements? |
12:40:26 | Araq | nah |
12:40:32 | Araq | unfortunately not |
12:40:37 | ForumUpdaterBot | New thread by Krisppurg: Dimscord: Library for interacting with the Discord API., see https://forum.nim-lang.org/t/6729 |
12:41:24 | PMunch | Hmm, bummer |
12:41:47 | PMunch | Guess I could make some kind of macro for it... |
12:42:04 | PMunch | Too bad `of` isn't parseable unless it's in a case statement.. |
12:44:09 | * | lritter quit (Quit: Leaving) |
12:45:13 | Araq | it is parsable |
12:45:19 | Araq | foobar: |
12:45:22 | Araq | action |
12:45:27 | Araq | of x: |
12:45:29 | Araq | ... |
12:47:33 | * | FromDiscord quit (Remote host closed the connection) |
12:47:47 | * | FromDiscord joined #nim |
12:52:12 | * | theelous3__ joined #nim |
12:52:37 | PMunch | Really? |
12:52:42 | PMunch | I seem to remember it wasn't |
12:55:14 | * | theelous3 quit (Ping timeout: 260 seconds) |
12:57:23 | PMunch | Og nice, this is perfect! |
13:04:29 | FromDiscord | <dom96> Araq: huh, I see in your RFC that the concept syntax isn't the currently implemented one |
13:04:36 | FromDiscord | <dom96> are you planning to finally change the syntax? |
13:20:20 | FromDiscord | <lqdev> PMunch: yeah `of` is just a regular operator that you can use both in prefix and infix form |
13:21:51 | * | krux02 quit (Remote host closed the connection) |
13:30:56 | Araq | dom96: couldn't be bothered to write it in today's concept syntax |
13:31:26 | FromDiscord | <dom96> can we prioritise fixing concepts? ๐ |
13:31:50 | Araq | I'm considering it now that I wrote this RFC |
13:31:54 | FromDiscord | <dom96> yay |
13:32:10 | Araq | it's telling I couldn't even remember the current syntax enough to write my RFC |
13:33:17 | FromDiscord | <dom96> I tried to use concepts for my thrift lib and gave up: https://media.discordapp.net/attachments/371759389889003532/748173222255656981/Screen_Shot_2020-08-26_at_14.32.09.png |
13:38:07 | FromDiscord | <Kiloneie> Is there document describing the use cases/pros/cons of each memory management system available in Nim ? |
13:41:42 | * | waleee-cl joined #nim |
13:42:28 | FromDiscord | <Kiloneie> Also is Orc meant to be Nim's default GC in the future ? |
13:42:46 | FromDiscord | <Recruit_main707> i think so |
13:42:57 | * | arecacea1 quit (Remote host closed the connection) |
13:43:26 | * | arecacea1 joined #nim |
13:43:42 | FromDiscord | <Recruit_main707> https://forum.nim-lang.org/t/5232 |
13:43:56 | FromDiscord | <Recruit_main707> this talks about the gcs available. |
13:44:44 | bung | https://nim-lang.org/docs/gc.html |
13:45:02 | FromDiscord | <Kiloneie> Okay i will read about it |
13:46:34 | FromDiscord | <Kiloneie> https://nim-lang.org/docs/gc.html This does not give much information. Like with boehm GC, first off it says it's based on it, meaning it's probably not exactly 100% boehm, and secondly you gotta go somewhere else to read more about it... No quick comparison there. |
13:46:48 | Zevv | *very* preliminary, but i hope to address more of this in here: http://zevv.nl/nim-memory/nim-arc.html |
13:47:00 | Zevv | probably not of much use for you now yet :/ |
13:47:44 | FromDiscord | <Kiloneie> Nice, this work in progress is what i want to see, and would help others to decide on the memory management solution to use |
13:47:51 | FromDiscord | <Clyybber> The current concept syntax is fine, its not arbitrary or complex |
13:48:16 | FromDiscord | <Clyybber> The syntax you want should be enabled via a macro |
13:51:35 | FromDiscord | <Kiloneie> I should probably do a video on this in the future(making videos is my way of gathering data with explanations for myself) |
14:02:42 | FromDiscord | <Kiloneie> Why is Orc going to replace the current Deffered reference counting GC ? (I read some on ARC, but i don't really understand it just yet) |
14:04:05 | FromDiscord | <Clyybber> because its simpler and sometimes faster |
14:05:01 | FromGitter | <alehander92> dom96 sorry about that: i also think the concept syntax is ok though |
14:05:20 | FromGitter | <alehander92> maybe with a bit better error messages |
14:05:53 | FromDiscord | <Kiloneie> That's odd since the current GC solution is already simple and fast, what do i know D: |
14:06:41 | FromDiscord | <dom96> Kiloneie: it's definitely fast enough, I can sympathise with it being complex though |
14:08:06 | FromDiscord | <mratsim> The current GC is not thread friendly |
14:08:15 | FromDiscord | <mratsim> nor is it embedded friendly |
14:08:35 | FromDiscord | <mratsim> i.e. when you work with low-level, you need to reimplement everything, including strings |
14:09:41 | FromDiscord | <dom96> I would challenge that. The amount of times Araq has told me that the GC can be even embedded in an OS |
14:09:51 | FromDiscord | <dom96> You can hook the alloc/dealloc calls and it should work just fine |
14:10:42 | FromDiscord | <mratsim> the GC uses thread local heaps, so it's problematic when threading. |
14:12:01 | FromDiscord | <mratsim> that said arc/orc doesn't allow shared objects either, you still need to impelment atomic refcounting, but it makes it easier to share by transfering ownership |
14:12:48 | FromDiscord | <dom96> it's problematic when threading for _some_ usecases. |
14:12:48 | ForumUpdaterBot | New thread by Arnetheduck: Io2 module in stew, see https://forum.nim-lang.org/t/6730 |
14:13:56 | FromDiscord | <dom96> > New thread by Arnetheduck: Io2 module in stew, see https://forum.nim-lang.org/t/6730โตnice, another stdlib module reimplemented |
14:14:26 | FromDiscord | <mratsim> we already said that the stdlib is limited and we were told that due to backward compat we can't change it |
14:15:15 | FromDiscord | <Kiloneie> so a breaking change version incoming at some point in the future ? |
14:16:37 | FromDiscord | <Kiloneie> Is Arc/Orc an original GC by Araq or based on something ? |
14:17:25 | FromDiscord | <mratsim> Original GC based on papers from IBM, Bacon & Dingle to be precise |
14:18:04 | FromDiscord | <Kiloneie> Interesting. Nice to have something truly unique. |
14:18:14 | FromDiscord | <mratsim> The orc part (dealing with cyclic ref in a refcounting scheme) has no implementation besides Nim in particular |
14:18:37 | FromDiscord | <mratsim> Swift which also has ARC, does not have cycle detection, and dev are asked to "deal with it" |
14:21:04 | FromDiscord | <Kiloneie> Hmm. "Deal with it" xD... |
14:22:58 | bung | I got `Malformed communication packet` when I insert float value to mysql 8 on osx, other 3 ci instance works fine, any ideas? |
14:23:07 | FromDiscord | <mratsim> Look for "memory leak Swift" or "weak reference Swift" |
14:24:02 | FromDiscord | <Kiloneie> infamous you say ? |
14:27:47 | leorize[m] | I don't mind someone redoing io.nim |
14:27:58 | leorize[m] | that module desperately need a rework anyway |
14:29:08 | Araq | mratsim: a quite similar cycle collector is actually used in PHP |
14:31:48 | leorize[m] | I'm not a big fan of this shift to Result[T], but then this is status stuff so they're free to use that |
14:34:25 | FromDiscord | <dom96> > we already said that the stdlib is limited and we were told that due to backward compat we can't change itโต@mratsim change what? Not using exceptions for error handling? Is that really so critical for your use cases? |
14:42:51 | FromDiscord | <Varriount> Especially now with the goto exception implementation |
14:45:44 | leorize[m] | arnetheduck is well known for his preference for result types |
14:49:14 | leorize[m] | I would prefer it if status coordinate with upstream more, esp regarding these kinds of big changes like this |
14:50:28 | leorize[m] | stdlib can't change suddenly due to backward compat, that's true, but I'm sure that we would welcome revamp to aged modules like io |
14:50:48 | FromDiscord | <dom96> indeed |
14:51:03 | leorize[m] | an rfc would have helped coordinating efforts |
15:01:43 | FromDiscord | <Clyybber> shashlick: Are you sure you didn't compile one binary with -d:useMalloc and the other one without? |
15:02:50 | * | cjjuice joined #nim |
15:02:59 | * | cjjuice left #nim (#nim) |
15:05:35 | shashlick | @Clyybber just retried the tests and was careful about that |
15:05:46 | FromDiscord | <Clyybber> ok nice |
15:06:19 | shashlick | All this but my plugins package still fails tests with useMalloc so there's yet more issues |
15:13:53 | Zevv | PMunch: I still need to play with this stuff of course. Do you see any benefit of having unsigned types, or is only signed ok as well? It would reduce some of the complexity |
15:16:21 | * | natrys joined #nim |
15:17:51 | * | hnOsmium0001 joined #nim |
15:18:50 | * | theelous3__ quit (Quit: is outty) |
15:18:54 | * | theelous3_ quit (Quit: is outty) |
15:19:12 | * | theelous3 joined #nim |
15:22:02 | * | nikita` is now known as ronja` |
15:22:09 | * | ronja` is now known as nikita` |
15:22:21 | * | rockcavera quit (Remote host closed the connection) |
15:24:23 | * | nuxdie joined #nim |
15:25:07 | FromDiscord | <mratsim> @dom96 not using exceptions is critical yes |
15:25:30 | FromDiscord | <mratsim> They are problematic for both async and later threading |
15:25:58 | FromDiscord | <mratsim> and we need to ensure that all exceptions paths are handled which is better with Result |
15:27:20 | FromDiscord | <mratsim> Also for low-level modules, we really need to only use features that do not allocate |
15:28:16 | FromDiscord | <mratsim> @leorize, we have our deadlines, we are not proposing to replace stdlib io, we are offering an alternative |
15:29:16 | FromDiscord | <dom96> in that case maybe it would make sense for you to put all of these little modules under a "nim-lite" or "nim-low-level" or whatever you want to call it package, and create a distribution ala TinyGo? |
15:29:34 | FromDiscord | <dom96> that way its purpose would be clear |
15:30:28 | leorize[m] | naming a module `<stdlib name>2` doesn't ring "alternative" to me tbh |
15:30:35 | * | kenran quit (Ping timeout: 240 seconds) |
15:32:51 | leorize[m] | I can see that Status found limitations within stdlib io from your security audit, but as far as I can tell these limitations are not reported upstream at all. I'm not saying that you must, but for the sake of open source collaboration some communication should be done. |
15:36:38 | FromDiscord | <mratsim> @dom96 It's called nim-stew, @leorize we opened io2 for discussion while it's still in PR, and just 8 days after it was initially opened. I don't see what more we can do. |
15:37:18 | FromDiscord | <mratsim> we have endians2 and bitops2, that's make it clear for us what to use. |
15:39:19 | FromDiscord | <mratsim> i.e. it's in the description: https://github.com/status-im/nim-stew |
15:39:24 | FromGitter | <bung87> create organization named as "nim-community" or something like for it |
15:41:01 | FromDiscord | <mratsim> For agility, the repo should stay in our organization as it serves as our staging area |
15:41:39 | FromDiscord | <mratsim> some modules have matured, and stable enough and can (and have been proposed) to be merged into nim-fusion |
15:42:23 | * | Vladar joined #nim |
15:44:28 | leorize[m] | given your fast moving pace I guess you're right |
15:44:36 | leorize[m] | I'll see what I can backport over to the stdlib |
15:46:36 | leorize[m] | I don't see any PRs :P |
15:46:52 | FromGitter | <bung87> nim-fusion also a good place to go |
15:47:38 | leorize[m] | endians2 is an excellent replacement for what we have in the stdlib currently |
15:47:43 | FromDiscord | <Lod> Can someone help me? |
15:47:55 | leorize[m] | IMO that one can just go straight as endians replacement if anyone wanted to try |
15:48:22 | FromDiscord | <Lod> Iยดm getting this error on Windows: `.nimble\pkgs\httpbeast-0.2.2\httpbeast.nim(183, 36) Error: undeclared identifier: 'EWOULDBLOCK'` |
15:48:22 | leorize[m] | @Lod sure, what's your question? |
15:48:45 | FromDiscord | <Lod> Tried searching for it, but there's not much information |
15:48:52 | leorize[m] | httpbeast doesn't work on windows |
15:49:12 | leorize[m] | are you using anything that needs it? |
15:50:09 | FromDiscord | <Lod> Yes, I was curious and decided to learn nim, and was checking if rest api's were possible to do |
15:50:55 | leorize[m] | on windows there's asynchttpserver in the stdlib |
15:50:56 | FromDiscord | <Lod> is there any alternative? |
15:51:06 | FromDiscord | <Lod> I will try that ๐ |
15:51:09 | FromDiscord | <Lod> Thanks |
15:51:33 | leorize[m] | you might want to try jester too |
15:51:36 | leorize[m] | !repo jester |
15:51:38 | disbot | https://github.com/dom96/jester -- 9jester: 11A sinatra-like web framework for Nim. 15 1029โญ 101๐ด 7& 29 more... |
15:52:22 | FromDiscord | <Lod> But doesn't jester require httpbeast? |
15:53:04 | FromDiscord | <mratsim> AFAIK we do fixes in PR but for replacement/alternative you can cherry pick in stew. The main issue is figuring out the deprecation/replacement path of Nim modules if there is breaking changes |
15:53:05 | FromDiscord | <dom96> No, jester uses asynchttpserver on Windows |
15:53:21 | FromDiscord | <Lod> Thanks, thats great |
15:53:26 | FromDiscord | <Lod> ๐ |
15:54:13 | * | quetzalb joined #nim |
16:08:25 | * | narimiran quit (Ping timeout: 240 seconds) |
16:16:52 | bung | it's weird I implemented `<` `==` that also need implements `<=` |
16:19:01 | bung | without it wrongly give me result when I compare as `>=`, no any hint or error |
16:20:28 | Zevv | well, put some debug prints in your < and =, see what it gets as input and what you return |
16:20:54 | FromDiscord | <mratsim> I didn't understand your sentence |
16:21:13 | Zevv | whose? |
16:24:31 | bung | mine I guess :) |
16:27:03 | bung | I tried on play it gives compile time error |
16:30:07 | FromDiscord | <mratsim> link |
16:30:50 | bung | https://play.nim-lang.org/#ix=2vjy |
16:31:58 | bung | https://travis-ci.org/github/bung87/amysql/jobs/721394923 see line 456 I got 5.7.30 > 8.0 |
16:33:51 | bung | then I add `<=` proc in https://github.com/bung87/amysql/commit/93a97263d0563e47bb7d7378020cb2337e53c1e3 |
16:34:02 | bung | problem solved |
16:38:35 | * | krux02 joined #nim |
16:43:13 | FromDiscord | <dk> What's the point of `setLen` truncating the seq? |
16:43:37 | FromDiscord | <dk> instead of just changing the `length` field or whatever |
16:48:27 | leorize[m] | it doesn't :) |
16:48:50 | leorize[m] | it's when the seq grows that the new memory got zero-ed out |
16:48:56 | leorize[m] | if you shorten the seq it just reduce the length |
16:53:13 | FromDiscord | <dk> Oh |
16:53:33 | FromDiscord | <dk> Makes sense |
16:53:43 | FromDiscord | <Kiloneie> GC_getStatistics() proc, man it that string hard to read, memory is in bytes D:... |
16:54:22 | FromDiscord | <Kiloneie> What does total and occupied memory mean ? |
16:55:39 | FromDiscord | <mratsim> Total is all the memory managed by Nim, occupied is the memory for user data, and the difference is due to memory allocated, but no data uses it and it has not been returned to the OS |
16:55:50 | FromDiscord | <mratsim> (the last part is an educated guess) |
16:56:09 | FromDiscord | <Kiloneie> like how OS steals an insane amount of RAM xD |
16:56:16 | FromDiscord | <Kiloneie> windows -.- |
16:56:57 | FromDiscord | <Kiloneie> first time reading the source of procs to find more documentation... Someone needs to document a bit more <.< |
16:57:35 | disruptek | where do i read about whatever the current concept discussion is? |
16:57:35 | * | superbia quit (Read error: Connection reset by peer) |
16:57:48 | disruptek | it doesn't work and it's blocking. |
16:58:32 | * | superbia joined #nim |
17:03:53 | FromDiscord | <mratsim> what doesn't work? |
17:04:06 | Zevv | me |
17:04:10 | FromDiscord | <mratsim> https://github.com/nim-lang/RFCs/issues/168 |
17:04:11 | disbot | โฅ Concepts and type-checking generics ; snippet at 12https://play.nim-lang.org/#ix=23U8 |
17:04:13 | Zevv | because im on holidays |
17:04:14 | Zevv | ha ha ha ha |
17:04:56 | disruptek | yeah, well, i commented on that one. |
17:05:00 | disruptek | no response. |
17:06:04 | FromDiscord | <mratsim> Concepts are talked about in hush hush tones on IRC |
17:06:28 | disruptek | here's an example of what i'm frustrated with: |
17:06:31 | disruptek | https://github.com/disruptek/nimph/blob/denimble/nimph/groups.nim |
17:07:44 | disruptek | the "order matters" sucks the big donkey dick as well. |
17:08:48 | FromDiscord | <mratsim> I've created complex recursive concepts but seems like you also should wear a crown |
17:08:58 | FromDiscord | <mratsim> sorry co-recursive* |
17:09:13 | disruptek | nonsense, this is actually the simiplification that i made to try to understand the problem. |
17:10:37 | disruptek | like, you cannot say "T is Suitable" in Collectable. no. but you can iterate and /then/ check if it matches. |
17:11:02 | disruptek | and then /T is Suitable/ at the bottom. |
17:11:23 | FromDiscord | <dom96> My god, stop using single letter identifiers! |
17:11:56 | FromDiscord | <dk> is there a technical reason there's no `mitems` for `NimNode`? |
17:11:58 | disruptek | i don't have a problem with it in a concept definition. |
17:12:10 | disruptek | you would have a hard time finding me using a single letter identifier elsewhere. |
17:12:38 | disruptek | hash() is the only exception i can think of. |
17:12:49 | disruptek | there, it is idiomatic. |
17:14:01 | disruptek | dk: the technical reason is that it's not needed. |
17:14:26 | disruptek | nimnodes are refs. |
17:18:13 | * | awe00_ joined #nim |
17:19:33 | bung | please close this https://github.com/nim-lang/Nim/issues/8231 |
17:19:35 | disbot | โฅ strutils:formatSize() is broken in JS mode ; snippet at 12https://play.nim-lang.org/#ix=2vjM |
17:20:04 | * | awe00 quit (Ping timeout: 258 seconds) |
17:27:19 | FromDiscord | <mratsim> done |
17:27:49 | * | kenran joined #nim |
17:32:15 | kinkinkijkin | quick c to nim question |
17:32:55 | * | kenran quit (Ping timeout: 240 seconds) |
17:33:49 | kinkinkijkin | "m[12] = m[13] = m[14] = 0;", is that "m[12] = m[13] /n m[13] = m[14] /n m[14] = 0", or "m[12..14] = 0" |
17:34:00 | kinkinkijkin | i dont know enough c lol |
17:34:19 | disruptek | yes, it's all 0. |
17:34:22 | disruptek | 0 0 0 |
17:34:26 | kinkinkijkin | alright, thanks |
17:35:25 | FromDiscord | <Kiloneie> Is this all good/valid ? https://media.discordapp.net/attachments/371759389889003532/748234157007568966/unknown.png |
17:36:06 | disruptek | you're either saying too much or too little. |
17:36:17 | disruptek | i don't know what the 2nd bullet point means. |
17:36:29 | disruptek | references have myriad use. |
17:36:34 | leorize[m] | sans the last one |
17:37:03 | leorize[m] | nim automatically optimize parameter passing to pass by reference if the object is big enough (3x float) |
17:37:06 | FromDiscord | <Kiloneie> Second bullet point... say you have 4 objects use the same sprite ? |
17:37:31 | disruptek | you need to understand the material before you attempt to teach it. |
17:37:37 | disruptek | try writing some code and using references. |
17:37:51 | disruptek | teaching it will /refine/ your understanding. |
17:37:59 | disruptek | first, you must start with that understanding. |
17:38:03 | FromDiscord | <Kiloneie> Been on this for a week... not motivated xD... |
17:38:11 | disruptek | well, then. |
17:39:08 | disruptek | do what i do: start yet another lame project. |
17:39:15 | FromDiscord | <Kiloneie> i mean i want to understand it, it's just that it took a lot of time already, i honestly should of done other videos since i got a bit of stuck on this one |
17:39:37 | FromDiscord | <Kiloneie> for some reason i hit this video's wall and stuck behind it xD... |
17:40:02 | disruptek | i don't think you should use this as an excuse to produce poor material that you will want to remake later. |
17:40:15 | disruptek | it's hard enough creating content once. |
17:40:52 | disruptek | just my opinion. |
17:40:54 | FromDiscord | <Kiloneie> well i am mostly happy with most of my videos so far(besides the audio quality which i think i got covered now) |
17:41:10 | FromDiscord | <Kiloneie> this topic is just bit of a stretch |
17:41:48 | FromGitter | <iffy> I'm guessing from testing that asyncfile doesn't work for general-purpose file handles. Is that expected? Here's a demo program: https://play.nim-lang.org/#ix=2vjQ |
17:42:29 | FromDiscord | <mratsim> @kinkinkijkin weren't you writing a partition system in Nim a couple of months ago? |
17:42:42 | * | natrys quit (Ping timeout: 260 seconds) |
17:42:48 | kinkinkijkin | depends what you mean by partition |
17:43:05 | FromDiscord | <mratsim> for music |
17:43:08 | leorize[m] | @iffy you have to setNonBlocking() the fd first |
17:43:10 | FromDiscord | <mratsim> not for filesystem |
17:43:19 | leorize[m] | I don't think that proc is exported so you might have to copy it |
17:43:21 | kinkinkijkin | ah, the renderer |
17:43:25 | kinkinkijkin | kpmmlnim |
17:43:41 | * | nuxdie quit (Quit: Connection closed for inactivity) |
17:43:46 | disruptek | needs more `i`s. |
17:43:55 | FromDiscord | <mratsim> or vowels ๐ |
17:44:23 | kinkinkijkin | (the "nim" at the end denotes it's in nim you see, as opposed to c# like the original version, which sucked and didn't meet the specification it was made for) |
17:44:43 | FromDiscord | <mratsim> ah so it's opensource? |
17:44:44 | disruptek | don't be rude; lots of people are perfectly satisfied with c#. |
17:44:58 | kinkinkijkin | nono, the original kpmml was suck |
17:45:07 | kinkinkijkin | and yes, kpmml is foss |
17:45:18 | disruptek | !repo kpmml |
17:45:19 | disbot | https://github.com/kinkinkijkin/kpmmlnim -- 9kpmmlnim: 11nim version of the discontinued kpmml C# 15 0โญ 0๐ด |
17:45:21 | kinkinkijkin | but it's such a torrid pile of spaghetti i dont recommend looking at it |
17:45:22 | FromDiscord | <mratsim> disruptek is teasing you |
17:45:35 | FromGitter | <iffy> @leorize this one? https://github.com/nim-lang/Nim/blob/ae358a0c7a5f7b14e5dde259cd6ce02b235985a3/lib/pure/nativesockets.nim#L612 |
17:45:46 | kinkinkijkin | oh dear i put up an early version of kpmmlnim didn't i |
17:45:50 | disruptek | this repo tells me absolutely nothing. |
17:46:00 | leorize[m] | @iffy yea |
17:46:06 | kinkinkijkin | i suck at documentation |
17:46:13 | disruptek | echo "You need to specify a file, titscheese." |
17:46:24 | FromDiscord | <mratsim> you might be interested in the Omni talk at the NimConf 2020 https://www.youtube.com/watch?v=ruT7sbs5O-Q |
17:46:25 | kinkinkijkin | the most documentation you'll find on kpmml is the botb thread page |
17:46:27 | disruptek | i see your potential, however. |
17:46:37 | disruptek | ahh, thanks for the link. |
17:46:41 | disruptek | that really helps a lot. |
17:46:44 | kinkinkijkin | ill get the link |
17:46:49 | kinkinkijkin | in a sec |
17:46:58 | kinkinkijkin | im currently finishing off some math helpers for something else |
17:47:08 | disruptek | take your time. i'm already thinking about masturbation. |
17:47:10 | FromDiscord | <mratsim> (it's a DSL for low-level audio programming) |
17:47:16 | FromDiscord | <mratsim> disruptek :/ |
17:47:26 | disruptek | way to ruin the mood. |
17:47:38 | FromDiscord | <mratsim> it's completely inappropriate |
17:47:48 | disruptek | i know, i really had something going there. |
17:48:18 | kinkinkijkin | http://battleofthebits.org/academy/GroupThread/17789/kPMML+-+PseudoMML+Synthesizer+%28WIP%29/ |
17:48:38 | kinkinkijkin | the original kpmml in c# does a lot of things in very, very tacked-on ways |
17:48:42 | FromGitter | <iffy> @leorize It works! Thank you! |
17:48:55 | kinkinkijkin | i recommend not looking at the source for long because it did in 3000 lines what the nim version did in 200 |
17:50:06 | kinkinkijkin | "you can now add blank lines without crashing the compiler!" is my favourite example of how poorly the original version was written |
17:50:44 | kinkinkijkin | it was the first project i programmed since high school and was largely implemented while half-awake |
17:51:14 | FromDiscord | <mratsim> I can give you lots of way to crash Nim compiler ๐ |
17:51:32 | Yardanico | shhhhhhhh |
17:52:06 | leorize[m] | we have an entire section in the issue tracker dedicated to crashing the compiler :P |
17:52:23 | Yardanico | who doesn't :) |
17:52:37 | Yardanico | it's not like you can't get an ICE with gcc or clang |
17:52:49 | disruptek | hard to do with only six characters, though. |
17:52:58 | Yardanico | https://github.com/rust-lang/rust/issues?q=is%3Aopen+is%3Aissue+label%3AI-ICE |
17:53:02 | Yardanico | just for comparison :P |
17:53:45 | kinkinkijkin | my favourite part of writing kpmml's code spec though was that it was the first music programming language with music macros (not like programming macros, more like functions, mml people have different names for things), for loops, and infinite loop nesting |
17:53:51 | leorize[m] | we probably have more but release builds are compiled with -d:danger |
17:53:58 | Yardanico | hehe |
17:54:02 | Yardanico | they're not though |
17:54:03 | Yardanico | are they? |
17:54:05 | Yardanico | I think they're -d:release |
17:54:43 | kinkinkijkin | but i never properly implemented the infinite loop nesting well in the c# version and while i did get it working in the nim version i never got the nim version far enough to compile the demo files |
17:55:07 | disruptek | there's still time. |
17:55:46 | kinkinkijkin | there is, but now i'm working on a renderer and brushing up on graphics testing to help test panfrost |
17:55:54 | Yardanico | panfrost - nice |
17:55:58 | leorize[m] | Yardanico: looks like only nimsuggest remains as -d:danger |
17:56:02 | Yardanico | leorize[m]: yeah |
17:56:09 | Yardanico | I tested panfrost a few months ago on my android tv box (running ALARM) |
17:56:16 | Yardanico | and sway and some other gles2 test apps worked |
17:56:21 | kinkinkijkin | ive done some rudimentary testing (what do i have to do to make this not crash? type testing) |
17:56:38 | * | myphs joined #nim |
17:56:44 | kinkinkijkin | mm, on my board gles2 does not work, only desktop gl |
17:57:08 | kinkinkijkin | gles2 loading hangs the system, and im trying to figure out why |
17:57:17 | kinkinkijkin | no output to dmesg on why |
17:57:20 | FromDiscord | <Kiloneie> Wau i see what i did really retardedly for this Reference objects video... i actually didn't test some of the things i wrote down xD... (i did that for every other video -.-...) Brain dead.โตโตThanks for pointing that out @disruptek |
17:57:57 | disruptek | just trying to motivate you. ๐ |
17:58:08 | FromDiscord | <mratsim> Well @kinkinkijkin, now you're not alone with music macros in Nim with Omni |
17:58:31 | kinkinkijkin | someone's working on a music language in nim? |
17:58:36 | kinkinkijkin | do they use battleofthebits as well? |
17:58:50 | kinkinkijkin | cause i shill nim hard there and a bunch of people were excited for kpmml there |
17:58:59 | Yardanico | not sure, check https://github.com/vitreo12/omni |
17:59:07 | Yardanico | https://vitreo12.github.io/omni/ |
17:59:32 | * | Jesin quit (Quit: Leaving) |
17:59:41 | FromDiscord | <mratsim> I said it a bit before, watch the NimCOnf talk: https://www.youtube.com/watch?v=ruT7sbs5O-Q |
18:00:21 | FromDiscord | <dom96> Here is a wild idea, let's prioritise tooling so that identifying which module each identifier comes from works 99.9% reliably https://forum.nim-lang.org/t/6728 |
18:00:38 | Yardanico | it works reliably for me :) |
18:00:45 | kinkinkijkin | @mratsim looks like it's not someone i know |
18:00:46 | kinkinkijkin | darn |
18:00:51 | kinkinkijkin | what a wacky coincidence |
18:01:17 | kinkinkijkin | though omni seems to be a language-on-language approach, while kpmml is a single-language approach |
18:01:45 | leorize[m] | @dom96 I'm still waiting for a review on #14556 :P |
18:01:46 | disbot | https://github.com/nim-lang/Nim/pull/14556 -- 3net, openssl: support setting the minimum supported SSL/TLS version |
18:02:02 | FromDiscord | <mratsim> @dom96 Weave can deadlock nimsuggest 99.9% of the time to 100% CPU within seconds :/ |
18:02:13 | kinkinkijkin | that is, omni you write omni within your nim code, and kpmml you write kpmml in its own file that you compile on its own |
18:02:24 | Yardanico | em |
18:02:24 | FromDiscord | <mratsim> ah right, yes |
18:02:29 | Yardanico | you write omni in omni though, no? |
18:02:37 | Yardanico | it's technically a nim dsl, yes, but it's separate |
18:02:41 | leorize[m] | nimsuggest breaks when you stare at it angrily |
18:02:51 | kinkinkijkin | yes, but it sits within nim code |
18:03:05 | kinkinkijkin | it's like the original mml before the MCK series of mml compilers jumped up |
18:03:26 | leorize[m] | h\ |
18:03:37 | leorize[m] | oops wrong window |
18:03:46 | Yardanico | 42=HPQ' |
18:06:51 | leorize[m] | I just saw this pop up in my feed: https://github.com/ziglang/gotta-go-fast |
18:06:58 | leorize[m] | do we have something similar? (iirc timothee wrote one) |
18:07:28 | disruptek | only golden. i need to get back to it. |
18:07:42 | * | enthus1ast quit (Ping timeout: 260 seconds) |
18:07:57 | disruptek | look at lolbench for inspiration. |
18:08:37 | leorize[m] | if you got a bench working well I can write some ci scripts to integrate it with the compiler ci |
18:09:41 | FromDiscord | <mratsim> put json in there :p |
18:10:01 | Yardanico | well you can take kostya benchmarks, and some benchmarks from the test suite |
18:10:10 | Yardanico | like we have an altneriatve version of the havlak benchmark |
18:10:13 | disruptek | !repo nimbench |
18:10:14 | disbot | https://github.com/ivankoster/nimbench -- 9nimbench: 11A micro benchmark module for Nim 15 16โญ 3๐ด 7& 1 more... |
18:10:48 | disruptek | i have a few benchmarks include json and base64 that tend to produce cold showers. |
18:11:16 | disruptek | nimbench isn't the one i was thinking of. |
18:13:39 | * | natrys joined #nim |
18:13:58 | * | Jesin joined #nim |
18:14:16 | disruptek | arc is finally the fastest for the json bench. |
18:14:57 | * | bwsq joined #nim |
18:14:58 | disruptek | 1.85s versus 1.35s m&s on the base64. |
18:15:15 | disruptek | that's a big improvement, btw. |
18:18:24 | * | bwsq quit (Client Quit) |
18:18:50 | disruptek | i think araq's work on seqs has made them faster in many cases. |
18:21:15 | * | enthus1ast joined #nim |
18:24:07 | FromDiscord | <Kiloneie> https://play.nim-lang.org/#ix=2vk7 Ehm, how to get child's type ? |
18:24:41 | * | Jesin quit (Quit: Leaving) |
18:24:47 | leorize[m] | convert it |
18:25:06 | leorize[m] | https://play.nim-lang.org/#ix=2vk8 |
18:30:27 | * | Jesin joined #nim |
18:30:42 | FromDiscord | <Kiloneie> How is that useful ... ? Say i had a ton of inheritance and i wanted to only use a specific one, type, typeof doesn't seem to work.โตProbably didn't explain myself right. type, and typeof shows both elements of "people" sequence as Person... |
18:40:05 | FromDiscord | <Rosen> At the risk of sounding stupid, why bother using `.type` when you can just use that `of T` check instead if you only want to use one child type of the parent? |
18:42:46 | Araq | you can use macro voodoo to do more type inspections |
18:42:53 | * | quetzalb quit (Remote host closed the connection) |
18:44:28 | leorize[m] | @Kiloneie well yea, that's how you're supposed to do it |
18:46:56 | * | bwsq joined #nim |
18:47:39 | FromDiscord | <Rosen> @Kiloneie maybe explain a situation where the tools we have wouldn't work? |
19:00:24 | * | Vladar quit (Quit: Leaving) |
19:16:59 | FromDiscord | <Kiloneie> Oh, it flew over my head. if object of myObject: convert and check type if all good if necessary blah blah. |
19:28:40 | * | kenran joined #nim |
19:33:51 | * | kenran quit (Ping timeout: 258 seconds) |
19:38:27 | * | myphs quit (Ping timeout: 256 seconds) |
19:39:02 | FromGitter | <Knaque> Could someone please tell me why `(1..100).toSeq().filterIt(it mod 2 == 0)` isn't valid? |
19:39:33 | Yardanico | because of (1..100) |
19:39:54 | Yardanico | ah wait actually |
19:39:55 | Yardanico | it's valid |
19:39:58 | Yardanico | wdym? |
19:40:04 | Yardanico | it works just fine on 1.2.6 |
19:40:17 | Yardanico | did you perhaps forget to import sequtils? |
19:41:08 | FromGitter | <Knaque> I did, but maybe it's just a `nim secret` thing. I'll try the playground. |
19:41:26 | Yardanico | well, "nim secret" is the VM |
19:41:32 | Yardanico | sometimes it has strange issues :P |
19:42:06 | FromGitter | <Knaque> Yep, its a nim secret thing. Good to know, then. |
19:45:42 | * | natrys quit (Quit: natrys) |
19:46:17 | FromDiscord | <ache of head> eh? it worked on nim secret for me ๐ |
19:46:43 | PMunch | Zevv, sorry I fell asleep. Only signed is fine for now :) |
19:47:30 | FromDiscord | <Elegant Beef> Also pmunch very unclear what your issue with my code is ๐ |
19:51:29 | PMunch | Just a sec |
19:51:31 | * | narimiran joined #nim |
19:54:31 | FromDiscord | <Elegant Beef> Ah forgot to push the named const |
19:54:56 | FromDiscord | <Elegant Beef> But it does work with `proc a(a:Option[int] = namedConst)` |
19:56:03 | PMunch | Ah, it does indeed |
19:56:13 | PMunch | But it does create the code to check it twice |
19:57:33 | PMunch | http://ix.io/2vkG |
19:58:18 | FromDiscord | <Elegant Beef> how do you dump the actual code again? |
19:59:25 | PMunch | I just added a "echo procDef.repr" right before the return |
19:59:56 | FromDiscord | <Elegant Beef> yea i knew it was possible to dump the actual code, but never seen how |
20:00:04 | FromDiscord | <Elegant Beef> always used tree repr ๐ |
20:00:05 | PMunch | But you can also do: --expandMacro:withSome |
20:06:54 | FromDiscord | <Elegant Beef> There beautiful ๐ https://hatebin.com/byoqoqmzzn |
20:10:10 | * | narimiran quit (Remote host closed the connection) |
20:11:15 | PMunch | Perfect! Now just remove the extra space after your `let` keyword and we're golden :) |
20:19:44 | * | awe00 joined #nim |
20:21:56 | * | awe00_ quit (Ping timeout: 256 seconds) |
20:22:53 | FromDiscord | <Elegant Beef> There we're golden |
20:23:01 | FromDiscord | <Elegant Beef> With the most passive agressive comment possible |
20:26:20 | PMunch | Haha :P |
20:26:34 | PMunch | My editor highlights them as red boxes, so they really stick out :P |
20:28:40 | * | bwsq quit (Ping timeout: 256 seconds) |
20:30:02 | FromDiscord | <Elegant Beef> Yea mine just renders them as a dot, so they blend into the background |
20:34:41 | FromDiscord | <Avatarfighter> wait Option[type] is a thing |
20:34:42 | FromDiscord | <Avatarfighter> ๐ฎ |
20:34:55 | FromDiscord | <Elegant Beef> Yes in the options module |
20:34:59 | FromDiscord | <Avatarfighter> thats neat |
20:35:18 | FromDiscord | <Elegant Beef> I do wonder does nimble have a way to auto resolve dependancies and add them to the nimble file? |
20:35:56 | disruptek | no, but generating the .nimble is one of the goals of nimph-2.0. |
20:36:00 | FromDiscord | <Elegant Beef> Say you use X module and it's in your local packages it could add said package to the file instead with `nimble findDeps` ๐ |
20:36:05 | FromDiscord | <Elegant Beef> Ah |
20:39:06 | * | Trustable joined #nim |
20:39:45 | FromDiscord | <dom96> That would be a cool feature, and might actually be doable quite easily |
20:40:02 | FromDiscord | <dom96> AFAIK Nim exposes info about the modules that were imported after compilation |
20:40:27 | PMunch | Yup, I used something similar for my NimScript minimised stdlib thing |
20:44:50 | disruptek | it's not hard to make it work, it's hard to make it work with clashes from a zero-knowledge starting point. |
20:57:04 | kinkinkijkin | hmm, how exactly do i do explicit copy-on-write in nim? ive forgotten, been a while since i needed it |
20:57:36 | kinkinkijkin | er |
20:57:42 | kinkinkijkin | wait i mightve gotten a term backwards |
20:57:44 | kinkinkijkin | just a sec |
20:58:17 | kinkinkijkin | nono, i meant the opposite of copy-on-write lol |
20:59:29 | kinkinkijkin | im using variables to construct items for a seq, and want to be 100% sure the item is written into the seq instead of referenced |
20:59:42 | kinkinkijkin | because i reuse the variables |
21:00:29 | FromDiscord | <martinium> on an http request one of the json keys from the response returns an array of strings. How do I assign that array to a variable? |
21:04:30 | kinkinkijkin | i dont know whether you're actually asking that question and feel like you're answering my question with another question |
21:06:02 | kinkinkijkin | though my question is one i ask because ive had problems with it in the past and the solution i was given was rather dirty; just explicitly converting the variable to the same type on addition to the seq |
21:06:36 | kinkinkijkin | id like to avoid doing that and want to know if there's been a feature added since to make this not necessary |
21:08:42 | FromDiscord | <Elegant Beef> They deleted their message so you looked crazy on discord, had to check the IRC logs to see who/what was the context |
21:09:46 | kinkinkijkin | [17:00:15] <FromDiscord> <martinium> on an http request one of the json keys from the response returns an array of strings. How do I assign that array to a variable? |
21:12:23 | * | thomasross joined #nim |
21:18:29 | FromDiscord | <Elegant Beef> Yea as i said i checked the IRC logs |
21:18:39 | kinkinkijkin | was for others who couldn't |
21:21:58 | * | synshroud joined #nim |
21:25:23 | * | tane quit (Quit: Leaving) |
21:29:32 | * | kenran joined #nim |
21:34:25 | * | kenran quit (Ping timeout: 240 seconds) |
21:48:06 | FromDiscord | <dk> Is `asyncnet.recvLineInto` any faster than `asyncnet.recvLine`? |
22:00:37 | FromDiscord | <lqdev> it doesn't allocate temporaries |
22:01:14 | FromDiscord | <lqdev> so if you're eg. reading commands over and over again, it's faster to use a single buffer |
22:01:17 | * | endragor_ joined #nim |
22:02:20 | * | synshroud_ joined #nim |
22:03:55 | * | solitudesf quit (Ping timeout: 240 seconds) |
22:04:23 | * | synshroud quit (Ping timeout: 258 seconds) |
22:04:23 | * | ForumUpdaterBot quit (Read error: Connection reset by peer) |
22:04:23 | * | def- quit (Quit: -) |
22:04:23 | * | def- joined #nim |
22:04:23 | * | endragor quit (Read error: Connection reset by peer) |
22:05:23 | * | ForumUpdaterBot joined #nim |
22:16:56 | * | kitech1- joined #nim |
22:17:14 | * | PMunch quit (Quit: leaving) |
22:17:56 | * | def- quit (Quit: -) |
22:17:56 | * | def- joined #nim |
22:17:56 | * | kitech1 quit (Quit: ZNC 1.7.5 - https://znc.in) |
22:20:07 | * | krux02 quit (Remote host closed the connection) |
22:29:40 | FromDiscord | <acek7> when installing nim and running finish nim asked me to place mingw into the dist folder after it downloaded and i did that. around the end of the extraction the archive extracter gives a bunch of errors |
22:31:31 | FromDiscord | <Kiloneie> On windows? |
22:31:39 | FromDiscord | <acek7> yes |
22:31:46 | FromDiscord | <acek7> windows 10, 64 bit etc |
22:31:58 | FromDiscord | <Kiloneie> Everytine i did that all of that was automatic... |
22:32:50 | FromDiscord | <Kiloneie> You know what, to be sure, re extract nim, and run finish as admin and y everything |
22:33:20 | FromDiscord | <Kiloneie> It should work, i think it didnt have priviligies |
22:33:48 | FromDiscord | <Kiloneie> Re extract as in clean copy |
22:34:05 | FromDiscord | <Kiloneie> Doesnt work with the path otherwise |
22:34:57 | FromDiscord | <acek7> sounds good i will give it a shot |
22:39:46 | * | bung quit (Ping timeout: 258 seconds) |
22:40:31 | FromDiscord | <dom96> you may also wish to give choosenim a try |
22:41:39 | FromDiscord | <Hearthstone> I wish choosenim worked on Arm ;-; |
22:43:01 | * | NimBot joined #nim |
22:43:16 | FromDiscord | <dom96> Maybe soon if this gets pushed forward https://github.com/dom96/choosenim/pull/213 |
22:43:17 | disbot | โฅ Support linux_arm64 and linux_powerpc64 |
22:43:30 | FromDiscord | <Hearthstone> Oo |
22:43:45 | * | synshroud joined #nim |
22:50:43 | * | vicfred quit (Quit: Leaving) |
22:53:07 | * | vicfred joined #nim |
22:54:14 | * | vicfred quit (Max SendQ exceeded) |
22:54:43 | * | vicfred joined #nim |
22:58:46 | * | synshroud quit (Quit: ZNC 1.7.5 - https://znc.in) |
23:00:04 | * | synshroud joined #nim |
23:09:10 | FromDiscord | <martinium> the following jsonnode key is an array of strings: let recipients = data["recipients"] How do I extract the array of strings from the node? For example, getStr() works for string values, what do we use for a jsonarray? |
23:09:38 | FromDiscord | <Rosen> getElems no? |
23:09:47 | FromDiscord | <martinium> let me try that |
23:10:12 | FromDiscord | <martinium> that was it |
23:10:17 | FromDiscord | <Rosen> perfect |
23:10:20 | FromDiscord | <martinium> wonder why they didn't call it getArray |
23:10:27 | FromDiscord | <martinium> ๐ |
23:13:55 | FromDiscord | <Hearthstone> Or `getSeq` |
23:28:27 | FromDiscord | <martinium> there is no getSeq when I had checked |
23:28:35 | FromDiscord | <kodkuce> lol i acindecly stambles on this https://gist.github.com/jzakiya/6aeebd22b18c01aab56a61b55ef2a649 , araq killing people xD |
23:29:46 | FromDiscord | <kodkuce> i personaly find nim community nice, i feal i can say any *poop* i want and have no consequences, only stuff i dont like is i feel too much a newb :) |
23:29:50 | FromDiscord | <martinium> that guy is def a snowflake |
23:29:59 | FromDiscord | <martinium> he wrote micro aggression |
23:30:03 | FromDiscord | <martinium> ... |
23:30:05 | FromDiscord | <kodkuce> (edit) '*poop*' => '\*poop\*' |
23:30:11 | FromDiscord | <Rosen> I wonder what he got yelled at for |
23:30:19 | FromDiscord | <Rosen> oh wait is it in this second part |
23:30:23 | * | kenran joined #nim |
23:30:44 | FromDiscord | <martinium> Araq was probably trying to code something in the compiler building the language but was getting pestered by that dude for Documentation |
23:30:45 | FromDiscord | <martinium> lol |
23:30:51 | FromDiscord | <martinium> people can be something else |
23:30:56 | FromDiscord | <martinium> anyways |
23:31:09 | FromDiscord | <martinium> sent a code paste, see https://play.nim-lang.org/#ix=2vlS |
23:31:16 | FromDiscord | <martinium> what line does my error start? |
23:31:19 | FromDiscord | <martinium> is it 54 |
23:31:20 | FromDiscord | <martinium> ? |
23:31:46 | FromDiscord | <kodkuce> or 59 |
23:32:10 | FromDiscord | <kodkuce> but i think your error is you wrong node type |
23:32:26 | FromDiscord | <Rosen> yea, post the code segment you're working on |
23:32:44 | FromDiscord | <Rosen> I'm trying to remember what I was doing just today where I got that error |
23:32:51 | FromDiscord | <Rosen> it was something about accessing keys on a jsonnode |
23:33:16 | FromDiscord | <kodkuce> you got an JObject but you tryeing to use it as JArray or soemthing like taht |
23:33:27 | FromDiscord | <martinium> sent a code paste, see https://play.nim-lang.org/#ix=2vlU |
23:33:38 | FromDiscord | <martinium> let recipients is line 54 |
23:34:47 | FromDiscord | <Rosen> is resources and recipients guaranteed to be there? |
23:34:58 | FromDiscord | <martinium> yup |
23:35:29 | * | kenran quit (Ping timeout: 246 seconds) |
23:35:44 | FromDiscord | <Rosen> and recipients *is* an array for sure? |
23:35:52 | FromDiscord | <martinium> I got the error with and without getElems() |
23:36:39 | FromDiscord | <martinium> yeah from API Spec: |
23:36:46 | FromDiscord | <martinium> sent a code paste, see https://play.nim-lang.org/#ix=2vlW |
23:37:03 | FromDiscord | <martinium> thats under the resources array |
23:37:15 | FromDiscord | <martinium> (edit) 'thats' => 'that's' |
23:37:46 | FromDiscord | <Rosen> I'm not certain, but I think you may have to getElems on the resources too |
23:38:05 | FromDiscord | <Rosen> since [] works on JObject but I think you might have JArray |
23:38:57 | FromDiscord | <martinium> let me try that |
23:39:18 | FromDiscord | <martinium> I've accessed before without having to do that in other functions |
23:39:35 | FromDiscord | <martinium> just using the correct .get for whatever type its supposed to be |
23:42:12 | FromDiscord | <martinium> changed it to use curlies instead |
23:42:17 | FromDiscord | <martinium> now I get 400 bad request |
23:42:25 | FromDiscord | <martinium> so seems it may be the body I am trying to send |
23:42:51 | FromDiscord | <martinium> I have this |
23:42:56 | FromDiscord | <kodkuce> just do if node.kind == JObject :โต echo whatyou go |
23:42:59 | FromDiscord | <kodkuce> (edit) 'go' => 'got' |
23:43:23 | FromDiscord | <kodkuce> else: echo what you got |
23:43:36 | FromDiscord | <kodkuce> so you will see where it goes bonkers |
23:44:44 | FromDiscord | <martinium> I may be trying to send json data incorrectly |
23:44:59 | FromDiscord | <martinium> I am trying to make a putContent request |
23:45:38 | FromDiscord | <martinium> json I am trying to send I am doing as client.putContent(url, body=body) |
23:48:50 | * | def-- joined #nim |
23:50:10 | * | Jesin quit (Quit: Leaving) |
23:50:10 | * | def- quit (Quit: -) |
23:50:10 | * | def-- is now known as def- |