<< 07-06-2020 >>

00:00:29*NimBot joined #nim
00:01:12*junland joined #nim
00:01:35*zedeus joined #nim
00:11:32*NimBot joined #nim
00:19:44AvatarfighterWhat is up party people :D
00:20:21*fredrikhr joined #nim
00:21:54FromDiscord<Elegant Beef> Also leorize i dont know if you seen me ask about if you used picom with rounded edges when you had the xorg leak
00:22:16FromDiscord<Elegant Beef> (edit) 'edges' => 'corners'
00:22:44*NimBot joined #nim
00:23:37*abm quit (Quit: Leaving)
00:25:01*bung joined #nim
00:30:03*NimBot joined #nim
00:43:44*NimBot joined #nim
00:46:15disruptekand iirc, koa is pretty decent.
00:50:07*zacharycarter quit (Ping timeout: 260 seconds)
00:54:30*NimBot joined #nim
00:57:49voltistIs it OK to use creative common images in a GNU GPL project?
00:58:08voltistcreative commons*
01:02:39*theelous3 quit (Read error: Connection reset by peer)
01:05:39*NimBot joined #nim
01:07:11FromDiscord<19> hello, has anyone ran into this issue while running `nimble install nimlsp`↵https://ibb.co/X5WTcTY
01:07:35Yardanicothat's some issue with your C compiler
01:07:45YardanicoI don't think it's related to nimlsp
01:07:56FromDiscord<19> my C:\MinGW
01:07:57FromDiscord<19> ?
01:07:59Yardanicolibmpfr-6 is required by GCC
01:08:08Yardanicoyes, mingw (mingw is gcc for windows)
01:08:12*chemist69 quit (Ping timeout: 246 seconds)
01:08:31FromDiscord<19> any idea how i can fix it?
01:08:39Yardanicohow did you install mingw? from where?
01:09:38FromDiscord<19> from sourceforge
01:09:45Yardanicouhh
01:10:22*chemist69 joined #nim
01:10:47Yardanicowell honestly I can't help a lot, but either use mingw shipped with choosenim or mingw-w64 from sourceforge :)
01:11:02leorize[m]@Beef I use regular picom
01:11:27FromDiscord<19> it's okay, how can i detect which mingw it is using
01:11:39FromDiscord<19> (edit) 'it' => 'nim'
01:11:45Yardanicoit's using whatever "gcc" you have in $PATH
01:15:07voltistAnybody know whats up with the nimble error ` Invalid section: .`?
01:15:19voltistI'm using the example from the nimble README
01:15:27voltistBut with my own values pasted in
01:15:37Yardanicowhat's your nim version?
01:15:49voltist1.2.0
01:15:49Yardanicohm
01:16:12Yardanicothat error shouldn't happen on 1.2.0 really
01:16:22Yardanicocan you show your example btw?
01:16:45*NimBot joined #nim
01:16:50FromDiscord<Elegant Beef> Ah i updated to the rounded corners version and started getting system lock ups and high memory usage
01:16:51FromDiscord<Elegant Beef> So weird
01:16:53voltistOh could it be because I haven't actually made the version tag yet?
01:17:07Yardanicovoltist: oh yeah it's invalid
01:17:25voltistOk I'll fix that now
01:17:27Yardanicothere's no "name" variable in nimble
01:17:32Yardanicoalso it tells you that in the error
01:17:35Yardanico"/home/dian/Stuff/inumon/inumon_9049.nims(7, 1) Error: undeclared identifier: 'name'"
01:17:54voltistOh whoops
01:18:16Yardanicoalso with GPLv3 you're forcing everyone to keep their code open source and compatible with GPL :P but again, it's your own choice of course
01:18:35FromDiscord<Elegant Beef> Permissive licensing! 😛
01:19:22voltist"you're forcing everyone to keep their code open source and compatible with GPL" yeah thats the point :P
01:19:32Yardanicoand that's why I would never use it :P
01:20:01Yardanicobut really, I don't understand the point of GPLv3 for libraries like that
01:20:07YardanicoI understand GPLv3 for big libraries/projects
01:20:58FromDiscord<Elegant Beef> I see GPLv3 most important for things like games that decided to open source or completed software tools made by big companies
01:21:17FromDiscord<Elegant Beef> I get the free software reasoning, but it's a detractor from actual use
01:21:49FromDiscord<Elegant Beef> I personally dislike non permissive licenses since they're intrinsictly not free
01:21:53voltistIf there was a license that allowed users to use a different license of their choice as long as it was open source, I would use it
01:22:05Yardanicovoltist: there's MPL
01:22:20Yardanicowhich allows people to use your code in proprietary apps but they still have to contribute changes (if they made any)
01:22:24YardanicoMozilla Public License
01:22:28Yardanicochanges to the code of the library itself
01:22:44FromDiscord<Elegant Beef> Thing gplv2 is like that no?
01:22:46Yardanicono
01:22:54Yardanicolibraries as in source-code too
01:22:59Yardaniconot just linking (that's lgpl)
01:23:05FromDiscord<Elegant Beef> ah
01:23:08FromDiscord<Elegant Beef> That's it
01:23:13YardanicoMPL is a middle ground between MIT/Apache/BSD-2 and GPL
01:23:35Yardanicohttps://www.mozilla.org/en-US/MPL/2.0/FAQ/
01:24:06FromDiscord<exelotl> If I wanted to make share my textadept configuration on github, but one of the modules is GPL, what does that mean for me?
01:24:29shashlick@leorize not sure what you mean, can you explain
01:24:44FromDiscord<Elegant Beef> Well you can license as MIT as long as you dont include the dependancy directly AFAIK
01:25:32voltistIs a non-NIT license a turn off for many people when it comes to libraries?
01:25:35voltistMIT*
01:25:42Yardanicosomething like GPLv3 - yes
01:25:56FromDiscord<Elegant Beef> i dont believe `nimble build` counts as distrobution and the user should look at the source of each dep
01:25:56FromDiscord<Rika> not-MIT or apache
01:25:56Yardanicoeven LGPLv3
01:26:03Yardanicobecause when you compile it in one binary LGPL and GPL are the same
01:26:20FromDiscord<exelotl> The problem is this module only exists in a larger package which is all under GPL, but I just want to copy-paste the one module into my repo
01:26:32FromDiscord<Elegant Beef> Well then you have to abide by that license
01:26:37FromDiscord<Rika> then it still has to be GPL
01:26:44YardanicoLGPL only matters if you create a shared library or a separate object file
01:26:44FromDiscord<exelotl> That's bullshit lol
01:26:52FromDiscord<Elegant Beef> I mean that's how licensing works
01:27:06Yardanicowell I don't think your repo has to be gpl, no
01:27:30*NimBot joined #nim
01:27:32FromDiscord<Elegant Beef> The entire repo doesnt as you say
01:27:35FromDiscord<Rika> *unless you use that module in other modules
01:27:35FromDiscord<exelotl> Right, I can live with that
01:27:43FromDiscord<Rika> GPL is a viral license
01:27:52FromDiscord<Elegant Beef> And this is the fucking issue with non permissive licensing
01:28:07FromDiscord<Elegant Beef> You want to include it but you have to walk around its licenses
01:28:32FromDiscord<Rika> ~~you can get away with it if the repos are small enough~~
01:28:36FromDiscord<Elegant Beef> Lol
01:29:33Yardanicoi mean some people use GPLv3 just because a friend or someone else told them that "it's a cool open source license"
01:29:37FromDiscord<exelotl> Wait so, if my main config file says `require "somegplmodule"` does the whole repo then have to be GPL?
01:29:41Yardanicoothers use it because of their beliefs (which is no wrong)
01:29:51FromDiscord<Rika> afaik yes
01:29:57FromDiscord<Rika> not sure on requires
01:30:10Yardanico@exelotl it doesn't have to be GPL
01:30:14Yardanicobut it has to be GPL-compatible :P
01:30:28YardanicoIANAL anyway
01:30:29FromDiscord<Elegant Beef> Really even if you dont distribute
01:30:39voltistHmm this is legit hard choice. I want people to use my work, and then maybe contribute to it and increase the shared benefits; but I also don't want to endorse/support closed-source, however drop-in-the-oceany it might be
01:31:04FromDiscord<Elegant Beef> I mean if you're for free software that should be free for anyone that wants it imo, minus the CCP 😛
01:31:17Yardanicovoltist: did you check the MPL FAQ?
01:31:45Yardanicoit's exactly for people who want contributions but don't want to limit the freedom too much
01:32:45voltistHmmm not *exactly* what I want
01:32:51voltistBut close enough
01:32:59Yardanicoi mean if you really don't want people to use your lib in closed-source, use GPL
01:33:06Yardanicoit's well-known and stuff
01:34:53FromDiscord<Rika> hm, ill ask the original creator of slider if i can retroactively change circa to use MPL
01:35:47voltistI want it to be used only in open source, but I don't want the people who do use it in open-source to be restricted to any one restrictive license
01:35:50voltistIdk if that makes sense
01:36:00voltistLooks like MPL is the closest I will get for now
01:36:10FromDiscord<Yardanico> Well they can still use MIT for their code
01:36:17FromDiscord<Yardanico> Since MIT is GPL compatible
01:36:31FromDiscord<Yardanico> The thing is that it has to be open source
01:36:46FromDiscord<Yardanico> With any GPL compatible license
01:36:56voltist"MIT is GPL compatible" in which direction?
01:37:47FromDiscord<Yardanico> "MIT licensed software can be re-licensed as GPL software, and integrated with other GPL software, but not the other way around."
01:38:55voltistOh right yeah
01:39:20*NimBot joined #nim
01:39:42FromDiscord<Yardanico> "Many of the most common free software licenses, such as the original MIT/X license, ... are "GPL-compatible". That is, their code can be combined with a program under the GPL without conflict (the new combination would have the GPL applied to the whole)."
01:40:10FromDiscord<Yardanico> So the app can be MIT but the whole package of the app + library is still GPL
01:42:27*Jjp137_ joined #nim
01:42:42*Jjp137 quit (Read error: Connection reset by peer)
01:43:50voltistI think I'll use MPL
01:49:38FromDiscord<19> seems like i have a problem 😆 ↵https://ibb.co/0DYmtSb
01:51:30FromDiscord<Cut a weeb and a pedo bleeds> Hi, are there `[]` iterators in system.nim?
01:51:57*NimBot joined #nim
01:52:34FromDiscord<Cut a weeb and a pedo bleeds> In other words, does `for it in someSeq[1..^1]` allocate a new seq?
01:54:18FromDiscord<Technisha Circuit> How would i wrap https://github.com/hjson/hjson-cpp for use in the C backend?
01:54:20PrestigeAnyone familiar with the deprecated pragma syntax {.deprecated: [FooOld: FooNew].}? Someone is suggesting it for a PR but I'm getting linting errors. Also haven't seen any docs on it
01:54:45FromDiscord<Technisha Circuit> Sorry, no idea
01:55:15FromDiscord<Rika> Technisha it needs a c wrapper first AFAIK?
01:55:47FromDiscord<Rika> Prestige I don't think that exists yet
01:56:06FromDiscord<Rika> @Cut a weeb and a pedo bleeds it does AFAIK
01:56:14FromDiscord<Rika> [] is a proc
01:56:36Prestige@Rika Hm well that's interesting. Here's the PR if you want to see the discussion.. https://github.com/nim-lang/x11/pull/33
01:56:37disbotRemoved `T` prefix for types.
01:56:45PrestigeIdk who timotheecour is on irc/discord
01:56:47voltist@Technisha Circuit Currently the wrapping of c++ libraries is very limited
01:57:49FromDiscord<Technisha Circuit> > Technisha it needs a c wrapper first AFAIK?↵It doesn't have a C wrapper really, just something similar which isn't as good at the hjson module/packages
01:57:52FromDiscord<Technisha Circuit> (edit) 'module/packages' => 'module/package'
01:57:58FromDiscord<Rika> Prestige, that's his name on irc AFAIK
01:58:16voltistDoes the nimble `publish` command work well? Fork, clone, modify, add, commit, push and make a pull request seems like a lot of steps that could go wrong when automated
01:58:21Prestigeah, haven't seen him talk here I guess
01:58:35FromDiscord<Technisha Circuit> > @Technisha Circuit Circuit Currently the wrapping of c++ libraries is very limited↵How limited?
01:59:38voltist@Technisha Circuit I hope shashlick wouldn't mind me saying that their Nimterop is currently the state of the art when it comes to wrapping things in Nim
01:59:48voltistBut it doesn't support c++ yet
02:00:04voltistSo you will have to use c2nim, which has limitations
02:00:17FromDiscord<Technisha Circuit> Oh okay
02:02:28voltistYou could make a poor-man's 'wrapper' and impliment various useful functions in c++, then call them from Nim
02:02:49*NimBot joined #nim
02:03:25FromDiscord<Technisha Circuit> How would i do that voltist?
02:03:30FromDiscord<Technisha Circuit> Using importcpp?
02:03:39FromDiscord<Technisha Circuit> How does it work? :P
02:03:45voltistYep https://nim-lang.org/docs/backends.html
02:04:00PrestigeI thought that was about deprecatedAlias
02:04:19Prestigeno idea why he would tell me to use the syntax if it wasn't currently a part of nim, though
02:05:56voltist@Technisha Circuit Ping me if you need any help with that
02:06:15FromDiscord<Technisha Circuit> Thanks!
02:11:46leorize[m]voltist: GPL3 is much stricter about the "not let people use your code in closed source software" part
02:12:37voltistI am aware, but I'd like people to be able to use whatever license they would like as long as it is open source. There isn
02:12:53voltist't a license that does that yet, so MPL is close enough for now
02:13:16*NimBot joined #nim
02:13:17voltistI thought it does?
02:13:36leorize[m]nope
02:13:54FromGitter<tulayang> Hello, please can someone tell me how to determine whether the function imported by ffi exists? Like this: ⏎ ⏎ ```code paste, see link``` [https://gitter.im/nim-lang/Nim?at=5edc4d603ffa6106f1fca72d]
02:14:34leorize[m]you can't other than just knowing that the underlying OS supports it
02:14:46leorize[m]see posix.nim in `devel` for how accept4 is imported
02:15:02voltistleorize "if you release the modified version to the public in some way, the GPL requires you to make the modified source code available to the program's users, under the GPL."
02:15:08leorize[m]well actually you can but it's not really that nice...
02:15:26leorize[m]voltist: well the same applies to mpl
02:15:31leorize[m]it's how copyleft work
02:15:45leorize[m]and actually it doesn't have to be under gpl
02:15:52leorize[m]it can be anything that's gpl-compatible
02:15:57voltistOnly if it is modified
02:16:07leorize[m]see how many of the linux kernel modules are actually MIT
02:16:36leorize[m]voltist: wdym?
02:17:32voltistMPL only requires open publication of modified source
02:18:28*muffindrake quit (Ping timeout: 260 seconds)
02:18:37voltistMy understanding is that if I was to use a library licensed under MPL, I could use any compatible license on my project as long as I published any modifications to the library under MPL
02:18:59leorize[m]the same applies to gpl
02:19:56leorize[m]GPL applies to the concept of "Software", MPL applies to files
02:20:03leorize[m]that's the difference between them
02:20:12voltistI don't see how it allows you to use any license
02:20:16voltistReading from here https://www.gnu.org/licenses/gpl-faq.html#GPLRequireSourcePostedPublic
02:20:44*muffindrake joined #nim
02:21:16leorize[m]that means if anyone modifies your library, they gotta release it to the public under gpl
02:22:10leorize[m]https://www.mozilla.org/en-US/MPL/2.0/FAQ/#distribute-binaries-from-modified-source
02:22:40leorize[m]^ the same applies to MPL, if you modify the MPL code, you gotta release it as MPL-compatible
02:22:42FromGitter<tulayang> devel/posix.nim ? thanks, I got it.
02:22:42*FromDiscord quit (Remote host closed the connection)
02:22:55*FromDiscord joined #nim
02:23:26voltistleorize[m]: https://www.gnu.org/licenses/gpl-faq.html#IfLibraryIsGPL
02:23:27*FromDiscord quit (Remote host closed the connection)
02:24:24voltistOh
02:24:45voltistI had no idea the list of GPL-compatible licenses is so huge
02:25:54*NimBot joined #nim
02:26:00voltistMaybe I will switch back to GPL
02:26:58leorize[m]just remember to pick the license wisely, once it goes open and people contributes to it, relicensing will be a pain
02:27:05voltistBetter do that before I submit it to the nimble repository
02:27:06voltistYeah
02:27:25FromGitter<tulayang> I see this code snippet in devel: ⏎ ⏎ ```code paste, see link``` ⏎ ⏎ Is there any way to check if this function exists at runtime? [https://gitter.im/nim-lang/Nim?at=5edc508c225dc25f54cee594]
02:27:55leorize[m]well... no
02:28:07leorize[m]yet
02:28:23leorize[m]it's possible to make it auto-detect
02:28:41FromGitter<tulayang> This solution seems to check the version of the operating system.
02:28:45leorize[m]but it's kinda complicated so no one does that
02:29:12leorize[m](in Nim, that is)
02:33:21leorize[m]if you want it to auto detect, then you can generate a C file at compile time importing and trying to use the function
02:33:25leorize[m]then try to compile it
02:33:56voltistleorize[m]: My concern is that the trend in Nim is to use non-restrictive licenses like MIT, so licensing under GPL might limit adoptability
02:33:58leorize[m]if it compiles without any errors then the function exists
02:34:04voltistThe Nim community*
02:34:33leorize[m]voltist: it's to allow Nim to be adopted by companies and/or their employees
02:34:52leorize[m]corporate say no to any hint of GPL
02:35:52voltistYeah that's why I was thinking MPL; it allows closed-source use as long as the source is not modified
02:36:08voltistKind of a middle-ground that still encourages contribution
02:37:24leorize[m]there's still a loophole for closed-source modification :P
02:37:40*NimBot joined #nim
02:37:43voltistEspecially for a library
02:38:34voltistI do not care a bit if someone just uses it because its convenient, but I do care if they are improving it and not sharing those improvements with the world
02:38:46voltistWell I do care for that first one
02:38:58voltistBut not enough to outweigh the adoptability thing
02:41:04voltistOh gee here I for my third relicensing in one day
02:41:10voltisthere I go*
02:43:55FromGitter<tulayang> I see, thank you. By the way, I am just writing a network framework, and I hope to be as compatible as possible in the program, without considering the operating system version. For example, ``epoll_create1`` and ``epoll_create``; ``accept4`` and ``accept``; ``pipe``, ``pipe2`` and ``eventfd``. It would be nice if there could be a runtime check, just like the C language. ⏎ ⏎ ```code paste, see link```
02:43:55FromGitter... [https://gitter.im/nim-lang/Nim?at=5edc546b7f08394226cfc2de]
02:48:04*NimBot joined #nim
02:48:48*fredrikhr quit (Ping timeout: 260 seconds)
02:56:29FromGitter<gogolxdong> Do we have bigint implementation?
02:56:55zedeushttps://github.com/status-im/nim-stint
02:57:46FromGitter<gogolxdong> Thanks !
03:00:14*NimBot joined #nim
03:11:57*NimBot joined #nim
03:24:26*NimBot joined #nim
03:25:54leorize[m]@tulayang I'd advise that you write higher level abstractions for them
03:26:46leorize[m]also when you're writing a network library, it's crucial to detect the OS, since what the API do depends entirely on what's underneath
03:36:03*NimBot joined #nim
03:46:53*NimBot joined #nim
03:58:40*NimBot joined #nim
03:58:50*silvernode joined #nim
04:01:59voltistHow would I go about casting a TaintedString into the equivalent of a char* ?
04:03:03shashlickcstring
04:03:22shashlickNo need to cast
04:03:50voltistAh actually nimterop has wrapped it to a `ptr cuchar`
04:04:00voltistSo I presume I do need to cast it to that?
04:05:02shashlickYep that's not char *
04:05:43*silvernode_ joined #nim
04:06:02*supakeen quit (Quit: WeeChat 2.8)
04:06:14*silvernode quit (Ping timeout: 264 seconds)
04:06:38*supakeen joined #nim
04:07:24voltistshashlick: Hmm still not working. I'll put more details on the gitter since it's nimterop related
04:09:03shashlickCool
04:10:39*NimBot joined #nim
04:21:18*NimBot joined #nim
04:27:18silvernode_good morning
04:27:36silvernode_one more night of work and then 3 days of Nim programming
04:27:49Prestigesup silvernode_
04:29:13silvernode_Working on this text adventure game. I was making a space game but got stuck and started another project in the meantime to hopefully learn other stuff to bring back to the space game.
04:30:30silvernode_Elegant Beef made a nice menu system but I ended up not using it since I can't figure out how to use it properly.
04:31:08silvernode_It's supposed to wait for input but does not do that in practice.
04:31:45silvernode_So I am just going with a simple proc of my own
04:33:54*NimBot joined #nim
04:34:17silvernode_but I am printing the index of an array and trying to figure out how to stop printing index 0. I don't want my menu to start at 0.
04:36:41PrestigeI can help if u can show your code
04:37:03silvernode_I think if I can set i to a range starting from 1 to infinity, that might work
04:37:15silvernode_that way the menu starts at 1 when printed out.
04:37:37silvernode_Let me paste it
04:38:42silvernode_https://play.nim-lang.org/#ix=2ot1
04:41:09silvernode_I forgot to remove that i=
04:41:29silvernode_I was trying stuff out
04:42:04silvernode_I also forgot to import strformat
04:42:34silvernode_https://play.nim-lang.org/#ix=2ot3
04:44:35Prestigeyou could just add 1 to i?
04:44:47Prestigelike when you're printing it out
04:45:24silvernode_so echo fmt"{i+1}"
04:45:56*NimBot joined #nim
04:46:31silvernode_I wouldn't have thought it would work out like that and still show the text that would have otherwise been at index 0
04:46:42silvernode_but it works!
04:47:45Prestigeyep, cuz you're printing the current index + 1
04:49:04silvernode_yeah it makes sense but at the same time doesn't. I would expect index 0 not to show up while also hiding whatever text was there too.
04:49:47silvernode_well....*sigh*, time to clock into work. have a good day/night
04:49:51silvernode_thanks for the help
04:54:01*silvernode_ quit (Ping timeout: 246 seconds)
04:58:23*NimBot joined #nim
05:05:20*solitudesf- joined #nim
05:06:21Zevvwth is pmunch compiling?!
05:07:19voltisthttps://imgur.com/a/E3Z8n1c Deffo not the helix nebula. I think my JPEG reader needs some work
05:09:50PrestigeZevv: another reality
05:10:24*NimBot joined #nim
05:19:39ZevvHow cool is that. Afraid one is enough for me
05:20:50*NimBot joined #nim
05:28:54voltistOk here is a fun challenge: WTF has to go wrong for the image on the left to become the image on the right - https://i.imgur.com/uku77rv.jpg
05:32:14*NimBot joined #nim
05:34:28ZevvWith coordinates going from -1.0 to +1.0 and wrapping occuring, the right seems to have been stransformed (x,y) -> (1.0/x,1.0/y)
05:34:34Zevvor similar
05:34:41Zevvdoes that make any sense at all?
05:35:24Zevvwell, not quite now that I look at it. But there's something getting 1/-ed somewhere
05:38:17voltistZevv: I have no idea how that would manifest through code that reshapes a flattened image into a (width,height,channels) one
05:38:42Zevvwhat is the code *supposed* to do then?
05:42:14voltistlibjpeg outputs a flattened image (<row1col1channel1>, <row1col1channel2>,<row1col1channel3>,<row1col2channel1>,...) and I'm turning that into a tensor of shape [height, width, channels]
05:44:05voltistZevv: code looks like this https://gist.github.com/dizzyliam/c7c795289c4c2bc3be346f0a055f90c5
05:44:58*NimBot joined #nim
05:48:26voltistZevv: It's possible that I'm misunderstanding how libjpeg outputs data, but I'd like to rule out a shoddy algorithm first
05:58:29*NimBot joined #nim
05:59:45Zevvand it might be that you need a stride (line width) which is not necessarily the same as image width, but that depends on your decoder lib
06:15:34*waleee-cl quit (Quit: Connection closed for inactivity)
06:16:42Zevvvoltist: fixed it?
06:33:22voltistSorry went to peel potatoes
06:33:33voltistZevv: Of course, thats my problem!
06:33:36voltistSilly mistake
06:34:41voltistZevv: Yep it works now. Thanks for spotting my error :)
06:34:47Zevvbeen there more then once :)
06:35:01voltistWe all have
06:42:12*B4s1l3 joined #nim
06:42:16*B4s1l3 is now known as opDispatch
06:42:35voltistWell now it's time for jpeg writing
06:42:39voltistMore fun no doubt
07:11:52voltistAny reason why `fp.write(cast[string](output))` would throw the error `Error: unhandled exception: errno: 14 `Bad address` [IOError]`
07:12:01voltistWhere output is of type `ptr cuchar`
07:23:49Zevvyeah, tons :)
07:24:12Zevva string is a tuple of a pointer to the data and its length
07:24:28Zevvyou lie to NIm, telling it that your 'output' is a string. But it's not.
07:25:34Zevvyou want to do fp.writeBuffer(output, len)
07:25:39Zevvhttps://nim-lang.github.io/Nim/io.html#writeBuffer%2CFile%2Cpointer%2CNatural
07:26:03Zevvif you cast, you better be sure what you are doing because the compiler will no longer protect you
07:33:03*dddddd quit (Ping timeout: 256 seconds)
07:40:02*kenran joined #nim
07:44:35bungwhat's the equal operator `features[:, 0]` compare to mxnet's nd
07:59:20*opDispatch quit (Quit: Konversation terminated!)
08:00:19voltistZevv: Yeah that worked out, thanks
08:00:35voltistWell, I mean i've got other problems now
08:00:38voltistBut not that one
08:01:32voltistAnd now no problems
08:01:48voltistInumon will support JPEG read/write as soon as I can commit and push
08:03:30bungpure nim lib ?
08:04:27voltistUnfortunately not; it wraps the common libpng and libjpeg-boost
08:04:46*kenran quit (Ping timeout: 256 seconds)
08:04:47voltistFor IO
08:10:08*JStoker quit (Ping timeout: 256 seconds)
08:11:00*JStoker joined #nim
08:19:20*zielmicha___ joined #nim
08:19:33*zielmicha__ quit (Ping timeout: 256 seconds)
08:19:33*zielmicha___ is now known as zielmicha__
08:21:36bungok, there are wrapers for image processing.
08:26:29voltistI'm yet to find one that makes me want to use it
08:46:20FromGitter<mattrberry> Hi! I'm struggling to read an entire file into a seq[uint8]. How would I go about this? I'm just trying to use readBytes, but I'm getting an "index out of bounds, the container is empty"
08:49:45PrestigeCan you show the code on play.nim-lang.org?
08:51:51FromGitter<mattrberry> https://play.nim-lang.org/#ix=2otD
08:53:02bungrom is empty
08:55:37FromGitter<mattrberry> Ah, didn't realize I needed newSeq
08:55:38FromGitter<mattrberry> Thanks
08:58:07voltistIs everyone unsure of how to version their projects or is it just me?
09:03:28FromGitter<mattrberry> What's the preferred ide for nim? I'm trying to use some vscode extension, but it really sucks at formatting
09:05:28bungas far as I know vscode extension using nimpretty for formatting
09:05:53bungI use https://github.com/bung87/vscode-nim-lsp for myself
09:14:42*snowolf quit (Ping timeout: 260 seconds)
09:18:37*jjido joined #nim
09:19:33*jjido quit (Client Quit)
09:28:15*clemens3 quit (Ping timeout: 260 seconds)
09:48:13*chemist69 quit (Ping timeout: 272 seconds)
09:48:37*chemist69 joined #nim
09:55:59*kenran joined #nim
09:58:50*fredrikhr joined #nim
10:01:30*lritter joined #nim
10:03:50*kenran quit (Ping timeout: 264 seconds)
10:05:38*neceve_ joined #nim
10:10:47FromGitter<sheerluck> voltist I like the youtube-dl way: youtube-dl-2020.05.29, youtube-dl-2020.06.06
10:26:07*team\andinus joined #nim
11:04:55*Guest58273 quit (Ping timeout: 256 seconds)
11:06:30*dadada joined #nim
11:06:53*dadada is now known as Guest4954
11:09:49*fredrikhr quit (Ping timeout: 264 seconds)
11:11:17*tane joined #nim
11:14:25*clemens3 joined #nim
11:23:54*dddddd joined #nim
11:25:49*haxscramper joined #nim
11:30:38*arecaceae quit (Remote host closed the connection)
11:31:01*arecaceae joined #nim
11:37:27haxscramperHow I can convert `PNode` (from `compiler/ast`) back intro string representation? In `macros` module it is implemented using `repr` but for `PNode` this does not generate string representation.
11:51:53*Senketsu quit (Quit: WeeChat 2.8)
11:52:56*Senketsu joined #nim
12:00:45*xet7 quit (Quit: Leaving)
12:06:01*supakeen quit (Quit: WeeChat 2.8)
12:06:38*supakeen joined #nim
12:07:02*xet7 joined #nim
12:24:49*PMunch joined #nim
12:31:59PMunchAnyone know what might be causing these issues: https://github.com/PMunch/nimlsp/issues/53#issuecomment-640210897
12:32:01disbotError: cannot export: Suggest ; snippet at 12https://play.nim-lang.org/#ix=2ouO
12:53:56*nc-x joined #nim
12:54:19bungmine thoughts same as yours first comment
12:54:45nc-xhaxscramper: what are you trying to do? anyways, iirc renderer.nim contains `$` implementation for PNode.
12:55:25*Senketsu quit (Ping timeout: 256 seconds)
12:57:18*Senketsu joined #nim
12:58:21nc-x@mattrberry it is best to disable nimpretty (formatting) in vscode nim extension settings. AFAICT, nimpretty works for simple programs, but I have had issues with it on big pieces of code.
12:59:37nc-xPMunch: maybe something changed between 1.2 and devel? because vitreo12 is using v1.2 with sources pointed to devel.
13:02:06*nc-x quit (Remote host closed the connection)
13:13:10haxscrampernc-x: I'm trying to take `PNode` and get string representation from it - this is the end goal for now. `renderer.$` throws `IndexError` when I try to use it.
13:13:10haxscramper
13:48:49haxscramperIt was mistake on my part - I was compiling with `--define:nimpretty`. Without it everything works fine.
13:50:50*Vladar joined #nim
14:07:31FromGitter<deech> I keep getting bit by the kind of early template resolution issues that mratsim has compiled ( https://github.com/nim-lang/Nim/issues/8677 ) . Is there an effort underway to fix this?
14:07:32disbot[Meta] Generics/Static early symbol resolution
14:08:46*krux02 joined #nim
14:09:11FromGitter<deech> To clarify, I would like to help with such an effort.
14:11:05*silvernode_ joined #nim
14:22:25*krisppurg joined #nim
14:28:49aeverrapparently the discord bot died lol
14:28:50FromGitter<Willyboar> federico3 here?
14:34:24aeverryardanico: discord to irc dead, both ways
14:34:33Yardanicohuh
14:34:50Yardanico!status
14:34:57Yardanico!ping
14:34:57NimBotpong
14:35:06aeverrthonk
14:35:50Yardanicowell idk why it stopped
14:35:58*FromDiscord joined #nim
14:36:00YardanicoI had a while true loop in a script for restarts
14:36:04Yardanicoidk how it ended :D
14:36:16Yardanicostarted now
14:36:50Yardanicoand no one noticed :D
14:36:56Yardanicofor quite some hours
14:44:39*clemens3 quit (Quit: WeeChat 2.7)
14:44:53bungmaybe you could use a master process monitor it
14:45:07Yardanicobung: as I said, I just have an external bash script
14:45:13*silvernode_ quit (Ping timeout: 264 seconds)
14:45:23Yardanicowhich will just start ircord again if it crashes
14:46:08bungok, idk now.
14:51:36aeverrmake that bash script loop execute a bash script that loop executes the irc server :D
14:51:43Yardanicolmao
14:51:47aeverri mean, bridge
14:57:39*HannahGem joined #nim
14:58:59FromDiscord<KrispPurg> I did notice tho.
15:02:34*idxu quit (Ping timeout: 256 seconds)
15:02:45*HannahGem quit (Ping timeout: 265 seconds)
15:03:03Zevvwhy does it need a restart script in the first place?
15:05:29aeverrits just thats cuffed
15:05:31aeverrscuffec
15:05:49Zevvfix your code! :)
15:17:22*clemens3 joined #nim
15:17:38FromDiscord<KrispPurg> I'm sure Dimscord will be stable on the latest branch I think.
15:17:57FromDiscord<KrispPurg> or at least the unpushed commit.
15:35:30PrestigeI'm trying to create a wrapper for Xft which has references to other libs (like fontconfig). It needs a few things from fontconfig like enums and simple data types. Should I be creating an entire wrapper for fontconfig as well?
15:37:05Yardanicowhy?
15:37:11Yardanicoif you don't use them in your code you don't need to
15:37:25federico3Willyboar: huh?
15:37:47PrestigeI was going to make a PR for x11 Yardanico to include the xft wrapper, since it is complete
15:40:11PrestigeJust seems weird having a few things from fontconfig and freetype declared inside of xft.nim but if they aren't implemented yet, idk if that really matters
15:43:03FromDiscord<willyboar> Federico3 sorry for the double ping discord not crashed
15:43:27federico3np
15:48:04disruptek!last disruptek
15:48:05disbotdisruptek spoke in 12#nim 15 hours ago 12https://irclogs.nim-lang.org/07-06-2020.html#00:46:15
15:48:09disruptekwhere is that asshole?
15:49:35haxscramperHow I can check if code runs at compile time vs runtime? Something like `when defined(nimscript)` but for complile/run-time.
15:49:36haxscramper
15:50:23FromDiscord<Recruit_main707> considering you specify when your code runs at compile time, it shouldnt be too hard
15:54:04haxscramperIs there a `define` that is at compile time? I want to write `static: test()` and `test()` so each one would do different things. Something like https://play.nim-lang.org/#ix=2ovR but replace `when defined(compiletime)` witch necessary check.
15:54:51disruptekadd the .compileTime pragma to a proc.
15:55:22disruptekthere's `when nimvm` but don't use it.
15:57:40haxscramperI need execute it at runtime too. And `when nimvm` works like exactly as I need - is there a reason not to use it?
15:58:09disruptekyeah.
16:03:16Zevvisn't he lovely
16:05:18*waleee-cl joined #nim
16:09:05*luis_ joined #nim
16:09:27Zevvdear disruptek
16:09:32Zevvwhat is the reason not to use it
16:09:40Zevvlove, zevv
16:10:23*xet7 quit (Quit: Leaving)
16:11:00*luis_ quit (Client Quit)
16:13:02*Vladar quit (Quit: Leaving)
16:34:47federico3https://blog.min.io/intel_vs_gravitron/
16:36:30federico3^^^ as the average number of cores keeps increasing, Nim needs a good parallelism paradigm more urgently
16:37:05disruptekworking on it.
16:37:17disruptekthe reason not to use it is that `when` is for chumps.
16:37:41disruptekit breaks assumptions otherwise enjoyed by programmer and compiler.
16:38:19disrupteki mean, peeps are working on the parallelism problem.
16:38:30disrupteki'm working on man boobs.
16:42:20*Vladar joined #nim
16:53:37FromGitter<Willyboar> federico3 ready
16:55:32disruptekif you listen closely, you can actually hear me getting fatter.
16:56:20FromGitter<Willyboar> The stretching sound?
16:56:30*arecaceae quit (Remote host closed the connection)
16:56:53*arecaceae joined #nim
16:56:54disruptekadjusting the suspenders.
17:01:59*Vladar quit (Quit: Leaving)
17:14:08FromDiscord<Shucks> ```case health:↵ of 66..100:```
17:14:29FromDiscord<Shucks> Why is not just `> 66` accepted?
17:14:55FromDiscord<él liquido> because that's not how a `case…of` works
17:15:00FromDiscord<él liquido> it operates on sets
17:15:05FromDiscord<él liquido> not expressions
17:15:24FromDiscord<él liquido> `of 66..100` is just syntax sugar for `of {66..100}`
17:15:31FromDiscord<él liquido> or, well, they have the exact same effect
17:15:43disruptekyou're giving me indigestion.
17:15:46FromDiscord<él liquido> that's why you can also define a set in a const and then use it as a `case` statement branch
17:16:53FromDiscord<Shucks> Im wondering if a `if` statement would be compiled into more efficient code then
17:17:06FromDiscord<él liquido> doubt it.
17:17:17FromDiscord<él liquido> they're probably about the same perf.
17:17:17disruptekuse a range instead.
17:19:11*natrys joined #nim
17:19:19FromDiscord<él liquido> well if you have a `Player` object and there's a `health` field that you want to check, an `if` is probably the way to go.
17:19:55FromDiscord<él liquido> just do `if health > 66`, it will save you a lot of headaches in the end. esp if your health somehow exceeds 100
17:20:37FromDiscord<Shucks> > well if you have a `Player` object and there's a `health` field that you want to check, an `if` is probably the way to go.↵yup thats what im doing. Thank you
17:20:50disruptek!repo disruptek/criterion
17:20:51disbotno results 😢
17:20:55disruptekWHAT THE FUCK
17:21:08disruptekdisbot: are you out to get me?
17:21:09disbotyep. 😊
17:25:02FromGitter<Willyboar> disbot: better hear what disruptek says...
17:25:58disruptekyou wouldn't like me when i'm angry.
17:26:05disrupteknarrator: he's always angry.
17:26:07shashlick@voltist please use ast2 for your wrappers
17:35:50*silvernode_ joined #nim
17:42:11*krisppurg quit (Quit: Connection closed for inactivity)
17:53:09*jjido joined #nim
17:55:00*jjido quit (Client Quit)
17:56:34*Faulander_ quit (Ping timeout: 240 seconds)
17:59:52*team\andinus quit (Quit: ERC (IRC client for Emacs 26.3))
18:00:59*team\andinus joined #nim
18:28:52*jjido joined #nim
18:34:50*waleee-cl quit (Quit: Connection closed for inactivity)
18:40:14*jjido quit (Quit: My MacBook has gone to sleep. ZZZzzz…)
18:41:09federico3leorize[m]: https://securesocketapi.org/ now, that's a good idea finally
18:42:36*abm joined #nim
18:44:14*waleee-cl joined #nim
18:44:31FromDiscord<Elegant Beef> Well disruptek im writting down today as the day the robots uprising began
18:44:52disrupteki started years ago.
18:45:32FromDiscord<Elegant Beef> Yea clearly, you probably started when you dad gave your mom a grown up hug
18:46:07disruptekis that what your sister calls your snuggle struggle?
18:46:45FromDiscord<Elegant Beef> Dude you're closer to alabama than I, you'd know better
18:46:53disruptekconcepts are broken.
18:47:06disrupteki don't know how anyone is supposed to use this half-assed feature.
18:47:33disruptekit shouldn't exist in this state; calling it experimental is unfair.
18:50:17FromDiscord<Elegant Beef> I still dont understand what they're for 😄
18:51:37*Trustable joined #nim
18:53:15disruptekaraq felt there weren't enough complaints in #nim.
18:54:04silvernode_is there a special way to do order of operations in nim?
18:54:27*kenran joined #nim
18:54:49silvernode_var sum = (5 - 2) 5/9 # does not work
18:55:12silvernode_Can't seem to find documentation on that
18:56:26FromDiscord<Elegant Beef> In what way doesnt that work?
18:56:38FromDiscord<Elegant Beef> 3 * 5/9 = 1.6
18:56:51FromDiscord<Elegant Beef> Cmon 😄
18:57:15disruptek!eval echo (5 -2) 5/9
18:57:16NimBotCompile failed: /usercode/in.nim(1, 7) Error: in expression '5 -2': identifier expected, but found '5'
18:57:36silvernode_yep
18:57:55FromDiscord<Elegant Beef> I assumed they removed an asterix
18:58:23disruptek!eval echo `*`((5 -2) 5/9)
18:58:25NimBotCompile failed: /usercode/in.nim(1, 11) Error: in expression '5 -2': identifier expected, but found '5'
18:58:37disruptek!eval echo `*`((5-2),5/9)
18:58:39NimBot1.666666666666667
18:58:40FromDiscord<Elegant Beef> There isnt an implicit operator for two floating values next to eachother
18:59:13FromDiscord<Elegant Beef> it's like `"asdsa" "gjkjklkj"` and expecting it to concat together
18:59:24silvernode_I was just trying to do temperature conversion. F to C
18:59:38disruptekno point.
18:59:51FromDiscord<Elegant Beef> Just measure in celcius first 😛
19:00:03disruptekthere are no thermometers in hell.
19:00:20FromDiscord<Elegant Beef> I've been there and cant confirm
19:00:32FromDiscord<Elegant Beef> Hitler had one, stalin had one, mao had one
19:01:07silvernode_I just tried it the way the formula was put on google which I think worked fine one time in python so I tried it in Nim and thought it would work similar
19:01:29FromDiscord<Elegant Beef> Ah
19:01:47FromDiscord<Elegant Beef> Python has implicit operators for floating values?
19:02:05silvernode_So in Nim we have to use * ?
19:02:11FromDiscord<Elegant Beef> Yea
19:02:25silvernode_hmm, ok then. I will try it
19:02:40FromDiscord<Elegant Beef> That doesnt work in python
19:02:49silvernode_kind of reminds me of how bash would want it
19:02:59silvernode_I left python behind
19:03:06silvernode_the community is toxic
19:03:16FromDiscord<Elegant Beef> I mean have you met disruptek
19:03:42silvernode_I should clarify, a large portion of the community appears to be toxic
19:03:42FromDiscord<Elegant Beef> I never liked the dynamically typed and intepreted part
19:04:26*jjido joined #nim
19:06:24silvernode_so now I tried: var sum = `*`((5 -2) 5/9) and pretty much get the same error
19:06:52silvernode_also copy and pasted the example written above in chat
19:07:05silvernode_go an error for that too
19:07:30shashlick) * 5
19:12:09*Jesin quit (Quit: Leaving)
19:13:13FromDiscord<Rika> just do (5 - 2) * 5 / 9 or something how hard is that T_T
19:13:30FromDiscord<Rika> and the reason what you sent didnt work is because it is missing a comman
19:13:32FromDiscord<Rika> comma
19:16:49*jjido quit (Quit: My MacBook has gone to sleep. ZZZzzz…)
19:19:19leorize[m]federico3: nice
19:19:39*NimBot joined #nim
19:20:14leorize[m]they could've chosen something other than openssl as a base though :P
19:20:33*Jesin joined #nim
19:25:36*kenran quit (Ping timeout: 256 seconds)
19:28:22*luis_ joined #nim
19:29:05luis_Hi everyone, did anyone create a makefile for crosscompile from linux to win using zig cc?
19:30:13silvernode_@Rika lol I think that's what shashlick was trying to tell me, I wasn't multiplying when I should have been....
19:30:30silvernode_it's always dumb stuff with me lol
19:30:35FromDiscord<Rika> thats fine
19:30:40FromDiscord<Rika> are you still learning?
19:30:46FromDiscord<Rika> if so then at least youre learning 😛
19:32:23silvernode_@Rika Yeah I have been programming on the weekends since like 2011 but only started Nim back in December.
19:33:00silvernode_I usually catch small errors like that but I rarely use that formula and forgot I needed to multiply
19:33:28silvernode_Since 2011, I learned bash for the most part and a tiny amount of Python and Lua.
19:33:52silvernode_With a dash of C and C++ but not enough to write anything useful.
19:34:13silvernode_I know more Nim now than C/C++
19:35:04silvernode_same goes for Python, I haven't spent months straight learning those like I have with Nim.
19:37:07silvernode_Anyway, I can write the formula just as in python, it was an error on my part and did not need to do `*` as disruptek did.
19:37:13disruptekbut what do you know about animal husbandry?
19:37:18*jjido joined #nim
19:37:28FromDiscord<Elegant Beef> When you're level 4 on rexxar
19:37:36silvernode_disruptek, ha, I know nothing
19:38:42silvernode_So side note, I am outside on my laptop and have been for a few hours now because the roomate locked the door when she left the house (and passed by me mind you)
19:39:15silvernode_Tried calling and texting her, and got no reply.
19:44:05*idxu joined #nim
19:50:09*idxu quit (Quit: ZNC - https://znc.in)
19:51:54FromDiscord<codic> Jester allows you to have a static directory but it doesn't use all files in all direcotries inside the static dir (it's not recursive). can i make it recursive somehow?
19:51:58FromDiscord<Rika> how're you charging the laptop if ever
19:52:09*zedeus_ joined #nim
19:52:23FromDiscord<codic> all i need to do is serve everything in public/src tbh
19:54:07silvernode_@Rika I have a ThinkPad dock that is always plugged in outside on the screened in deck.
19:54:28FromDiscord<Rika> thats odd lol
19:54:34*zedeus quit (Ping timeout: 240 seconds)
19:55:06*zedeus_ is now known as zedeus
19:55:08silvernode_@Rika I also have a thinkpad charger inside at 2 locations.
19:55:21silvernode_Also multiple thinkpads
19:55:30FromDiscord<Rika> thinkpad addict
19:56:14silvernode_@Rika I blame my friend for showing me his used T420 that he got on Ebay for $140 back in 2016. The rest is history
19:56:24FromDiscord<codic> Thiiiiiiiiinkpad
19:56:50silvernode_I even picked up 2 standalone thinkpad battery chargers just because they exist.
19:57:03*idxu joined #nim
19:57:12FromDiscord<codic> so, can i serve everything in the static dir (public by default) recursively in jester? thinkpads are awesome, i own a x230 myself
19:57:52FromDiscord<Elegant Beef> Are lenovo thinkpads as good as their IBM counterparts? 😄
19:58:04FromDiscord<Elegant Beef> And by that i mean has the quality gone down
19:58:06silvernode_I have 2 T420 models including the original T420 that my friend introduced me to years ago since he has decided he does not want it anymore.
19:58:46silvernode_I think the quality has gone down, that's why a lot of people still go for the T420 and similar older models.
19:59:26silvernode_I can have 16 gb of ram in this thing, Linux works great, MacOS works pretty great on it too if I ever need it.
20:00:15silvernode_There is a Github project to boot MacOS on the T420, I have done it for fun and was very impressed.
20:00:32FromDiscord<Elegant Beef> I mean seems like a lot of work when elementary OS exists 😛
20:00:58FromDiscord<Elegant Beef> I honestly sorta want a trackpoint on my desktop keyboard
20:00:59silvernode_It's not much work actually if you really need MacOS for something.
20:01:51*jjido quit (Quit: My MacBook has gone to sleep. ZZZzzz…)
20:02:42silvernode_I actually loaded stock MacOS on here before adding the T420 boot files and it actually installed and had native resolution.
20:03:17FromDiscord<codic> eh. everything on mac is usually available on windows
20:03:27*krux02 quit (Remote host closed the connection)
20:03:31FromDiscord<codic> and a windows vm / dualboot is easier and legal
20:03:39FromDiscord<codic> also, shouldn't this be in #offtopic/#nim-offtopic?
20:03:40silvernode_True, but the fact that it works on here is still pretty cool.
20:04:24FromDiscord<codic> Yeah
20:05:17silvernode_I honestly didn't know there was an offtopic channel
20:08:06*silvernode_ quit (Quit: Leaving)
20:08:20*silvernode_ joined #nim
20:08:31PMunch@codic, as long as there isn't anyone trying to discuss Nim stuff in here then it's fine to go off-topic
20:08:40*Trustable quit (Ping timeout: 256 seconds)
20:08:54PMunchThe other day off-topic was talking about Nim and this channel was off-topic :P
20:09:41silvernode_I figure it is generally ok to go off topic when nobody is asking for help or information about Nim.
20:10:02silvernode_as soon as someone comes here for help, all off topic talk has to stop
20:12:29*silvernode_ quit (Client Quit)
20:13:30*silvernode joined #nim
20:13:46*Jesin quit (Ping timeout: 256 seconds)
20:14:54*tane quit (Ping timeout: 256 seconds)
20:15:18*tane joined #nim
20:16:50FromDiscord<Elegant Beef> Imagine using Mac/Windows for development, brought to you by the freebsd gang
20:16:54FromDiscord<Elegant Beef> Now if only that wasnt a joke
20:17:04FromDiscord<Technisha Circuit> How would i "import" a .so file in Nim?
20:17:26FromDiscord<Technisha Circuit> @Elegant Beef I'm actually going to try Debian BSD :P
20:17:30clemens3silvernode: but that is irc, different conversations intertwined, where is the problem
20:17:57clemens3btw, is there a nim offtopic channel?
20:18:05FromDiscord<Elegant Beef> Yea
20:18:12disruptek##rust
20:18:15clemens3yey
20:18:22silvernodeclemens3, its in the topic header for this channel on IRC
20:18:23FromDiscord<Elegant Beef> #golang
20:18:48clemens3i am in tty with classical 80 columns, must be in the other 920 ones then..
20:19:17*sschwarzer joined #nim
20:19:22FromDiscord<Technisha Circuit> > How would i "import" a .so file in Nim?
20:20:02PMunchsilvernode, exactly
20:20:36PMunchclemens3, it's #nim-offtopic
20:20:41FromDiscord<Elegant Beef> https://nim-lang.org/docs/manual.html#foreign-function-interface-dynlib-pragma-for-import
20:20:46PMunchThere's also #nim-nologs
20:20:49sschwarzerFor this code, https://play.nim-lang.org/#ix=2oza , I get a compiler error "/usercode/in.nim(140, 5) Error: invalid type: 'var seq[NodeAction[xmltree.XmlNode]]' in this context: 'Iter[xmltree.XmlNode]' for var" - and I have _no_ idea what this is trying to tell me, let alone fix it. Can please someone explain the compiler message?
20:20:51PMunch#nim-gamedev
20:21:03PMunchAnd probably more :P
20:21:16silvernodeI tried to join with /join then again with my client but had to right click the link in the header and join that way. Weird when stuff like that doesn't work
20:21:36*Senny joined #nim
20:21:38clemens3PMunch: ah, coulda guess it.. but thanks!
20:21:51*luis_ quit (Ping timeout: 256 seconds)
20:21:51*Senketsu quit (Ping timeout: 256 seconds)
20:22:18silvernodeI should have read the header or at least assumed there was an offtopic channel since most communities have them
20:22:28FromDiscord<Technisha Circuit> > https://nim-lang.org/docs/manual.html#foreign-function-interface-dynlib-pragma-for-import↵@Elegant Beef thanks!
20:22:48*sentreen quit (Quit: sentreen)
20:25:47sschwarzerIn case it helps: The last thing was that I added the `var` for the seq in line 37. I need this for line 67. Before, instantiation of the iterator was working. So it seems somehow related to the `var` for the `seq`.
20:25:58*sentreen joined #nim
20:29:12FromDiscord<Rika> sschwarzer: ill try understanding, one moment
20:29:53sschwarzerRika: Thanks in advance :)
20:30:25sschwarzerI also tried a web search, of course.
20:30:51FromDiscord<Rika> this is massive code btw T_T
20:31:31sschwarzerRika: I can _try_ to reduce it. Already removed a bit.
20:32:01sschwarzerOr did you mean something else with "massive"? (It's probably not the most trivial code, admittedly :) )
20:32:20*sentreen quit (Quit: sentreen)
20:32:28FromDiscord<codic> PMunch: true, but I was trying to ask a question :P
20:32:34FromDiscord<Rika> its complex, ills till try it this way tho
20:33:36sschwarzerRika: "ills till try it"? I don't understand. Should I try something, or are you going to try something?
20:33:38FromDiscord<Rika> found it lol
20:33:44sschwarzerRika: Wow! :-)
20:33:47FromDiscord<Rika> ills till -> i'll still
20:34:06FromDiscord<Rika> line 37, you cant have a var field `nodeActions: var seq[NodeAction[N]]` -> `nodeActions: seq[NodeAction[N]]`
20:34:09FromDiscord<codic> now that we are on topic i can ask!so, can i serve everything in the static dir (public by default) recursively in jester?
20:34:10FromDiscord<Rika> all fields are var
20:34:30FromDiscord<Rika> maybe you mean export, in which case do `nodeActions*: seq[NodeAction[N]]`
20:35:22FromDiscord<Rika> sschwarzer ^
20:35:24sschwarzerRika: Hm, ok, I was also wondering because I hadn't seen this before. I added the `var` only because of some other message and that message went away after I added the `var`.
20:35:38FromDiscord<Rika> hm? is there a new issue?
20:35:39*sentreen joined #nim
20:35:46FromDiscord<Rika> let me run it
20:35:53FromDiscord<Rika> it compiels without the var...
20:35:57FromDiscord<Rika> compiles
20:36:07*sentreen quit (Client Quit)
20:36:11FromDiscord<Rika> update me on the new issue if ever
20:37:12sschwarzerYes, it compiles. The compile error was triggered by a call of `deleteNode` in line 64.
20:37:45FromDiscord<Rika> well nice that it works now
20:38:34sschwarzerRika: I added the previous message as a comment under https://play.nim-lang.org/#ix=2ozh .
20:39:15sschwarzerSo if I remove the var I'll get the other compile error again (see the comment). That compiler output was the reason why I added the `var`.
20:39:25*sentreen joined #nim
20:40:10sschwarzerRika: The problem somehow is with the `seq.add` in line 67
20:41:15FromDiscord<Rika> you make the nodeInfo var, so on line 64
20:41:21FromDiscord<Rika> `func deleteNode*[N](nodeInfo: var NodeInfo[N]) =`
20:41:46FromDiscord<Rika> since all arguments (unless theyre ref types) are immutable
20:42:20sschwarzerRika: I'll try ...
20:46:25sschwarzerRika: I changed the signature of `deleteNode` to func deleteNode*[N](nodeInfo: var NodeInfo[N]) = (added the `var`). Now I get ...
20:48:49sschwarzer(Meta problem: irssi asks me to press ctrl-k to paste 5 lines, but readline(?) asks for a digraph if I press ctrl-k XD
20:49:50FromDiscord<Rika> dont paste 5 lines here then LOL
20:50:16sschwarzerRika: makes perfectly sense ;-) I thought 5 lines were ok. :)
20:50:20sschwarzerWait a second ...
20:50:37FromDiscord<Rika> i have waited a second
20:50:50sschwarzerHere's the error: https://play.nim-lang.org/#ix=2ozj
20:51:31sschwarzerRika: Seems you need to wait more than one second, which includes one second, so I wasn't wrong. ;-)
20:51:51*jjido joined #nim
20:51:55*jjido quit (Client Quit)
20:52:19FromDiscord<Rika> so where is this deletenode being called
20:52:25FromDiscord<Rika> i kinda also need source for that
20:52:35FromDiscord<Rika> i cant find it in the old sources you sent
20:54:15FromGitter<ynfle> Can I unpack a defsection? https://play.nim-lang.org/#ix=2ozk
20:54:19FromDiscord<Rika> basically if you have something like `proc something(somenodeinfo:NodeInfo) = somenodeinfo.deletenode` then you need to `var` that too
20:54:40FromDiscord<Rika> or if its `let nodeinfo = returnsanodeinfo; nodeinfo.deletenode` then you need to `var` instead of `let`
20:56:50FromDiscord<Rika> @ynfle not that i am aware of
20:57:06FromDiscord<Rika> unpacking is tuple only (not even arrays have them) so
20:57:29sschwarzerRika: I think I have the code at https://play.nim-lang.org/#ix=2ozm , but interestingly I only get a different error message here in the playground. I don't know if I made an error when combining the files or if it's something with the Nim version. But my Nim version is 1.2.0, hm.
20:57:52FromDiscord<Rika> haa, now this code is even more massive now
20:58:13FromDiscord<Rika> anyway see my older messages
20:58:25FromDiscord<Rika> you'll be able to fix your issues yourself that way
20:58:29sschwarzerRika: I only added the test code, so you have it one "file" :)
20:58:46sschwarzerRika: I'll try it. :-)
20:59:09FromDiscord<Rika> and to codic that was just typing a moment ago, i dont know how to solve your issue
20:59:20FromDiscord<Rika> (you can see if someone is typing in discord)
20:59:58FromGitter<ynfle> @Rika, thx
21:03:00FromDiscord<codic> i was?
21:03:01FromDiscord<codic> i wasn't
21:03:05FromDiscord<codic> probably a discord bug
21:03:08FromDiscord<codic> I was in another server lol
21:03:45*neceve_ quit (Read error: Connection reset by peer)
21:03:58FromDiscord<Rika> discord dumb then
21:04:00*haxscram` joined #nim
21:04:15sschwarzerHm, I now need a `var NodeInfo` to call `deleteNode` on, but the `nodeInfo` instance is from an iterator, and if I add `var` to the iterator "return value", I get the compiler error "Error: expression has no address". That's understandable when looking at the iterator code. I'll try to find a fix/workaround.
21:05:17FromDiscord<Rika> if you think aboutt it, how would you delete (mutate) data from an immutable nodeInfo
21:05:18FromDiscord<Rika> 😛
21:05:29sschwarzerRika: but actually I should anyway have access to the `NodeInfo` instance via the `lastNodeInfoOption` and that isn't set yet in this version of the code. I'm in the process of a larger modification, phew.
21:05:44*haxscramper quit (Ping timeout: 265 seconds)
21:05:51sschwarzerRika: Yep, that's my point (of my last IRC message) :-D
21:06:39*haxscram` quit (Remote host closed the connection)
21:07:02sschwarzerI want to keep a "reference" to the yielded `nodeInfo`, so the next time the iterator (i. e. `nextNodeInfoOption`) is called it can check what I called on the previously yielded `NodeInfo` object. It's not trivial, yes. ;-)
21:07:10*solitudesf- quit (Ping timeout: 260 seconds)
21:08:09FromDiscord<Rika> in one ear out the other @_@
21:08:13sschwarzerDid I ever mention that I'd like recursive iterators in Nim? ;-/ Then this convoluted stuff wouldn't be necessary. (Although maybe what I'm trying to do can be achieved in some simpler way.)
21:08:24sschwarzerRika :D
21:09:15FromDiscord<Rika> man i just make simple ass libraries
21:09:24sschwarzerRika: To "see" changes to the yielded object in the next iteration, I have the `lastNodeInfoOption` in the iterator. But it isn't set yet. :)
21:09:50FromDiscord<Rika> have i mentioned that im still not following?
21:10:03FromDiscord<Rika> i kinda dont wanna since im already overloaded with trying to learn kubernetes
21:10:53sschwarzerRika: Anyway, I got it to compile now! :-)
21:11:02FromDiscord<Rika> congrats
21:11:38sschwarzerWith changing the yield to `yield rootIter.lastNodeInfoOption.get()`, so this refers to the actual object/field in the iterator.
21:11:59FromGitter<cyberlis> Where can I read about `{.dirty.}`, `{.cursor.}` and `<//>` ?
21:12:00sschwarzerRika: When I have this working, i. e. with passing unit tests, I'll try to simplify the code.
21:12:22FromDiscord<Rika> <//> is owned
21:12:22sschwarzerRika: thanks a lot!
21:12:30FromDiscord<Rika> old syntax for 0.19 compat
21:12:36disruptekcyberlis: doc/destructors.rst
21:12:37FromDiscord<Rika> no clue on cursor
21:12:49FromDiscord<Rika> guess thatll answer everything else 😛
21:13:08FromGitter<cyberlis> thank you all :)
21:18:40*lritter quit (Ping timeout: 256 seconds)
21:19:39sschwarzerRika: And have fun with Kubernetes :)
21:20:22FromDiscord<Rika> im dying already 🙂
21:33:03FromDiscord<Recruit_main707> can you convert a cstring or a ptr UncheckedArray[char] into an string easily?
21:33:11FromDiscord<Recruit_main707> and fast specially
21:34:19*silvernode quit (Quit: Leaving)
21:35:53FromDiscord<Generic> afaik in this direction you need a copy
21:36:35FromDiscord<Generic> since strings are managed by Nim, you can't create ones from some random memory
21:36:57FromDiscord<Generic> though you can create an openArray without any copies
21:38:29*silvernode joined #nim
21:39:18*tane quit (Quit: Leaving)
21:40:05leorize[m]@Recruit_main707 no you can't
21:40:19leorize[m]you can just use an openArray though
21:43:57*Senny quit (Ping timeout: 260 seconds)
21:52:01PMunchAnd that seems like a good time as any to call it the night!
21:52:38PMunch(For those not on IRC, they just said they had to reroute some servers and that it would be noisy, so the bots might behave weirdly/not bridge things properly for a while)
21:52:41*PMunch quit (Quit: leaving)
21:53:09*kragil[m] quit (*.net *.split)
21:53:09*oneark quit (*.net *.split)
21:53:11*j4nvkvc quit (*.net *.split)
21:53:11*koltrast_ quit (*.net *.split)
21:53:38*oneark joined #nim
21:53:38*kragil[m] joined #nim
21:53:38*j4nvkvc joined #nim
21:53:38*koltrast_ joined #nim
21:53:51*disbot quit (*.net *.split)
21:53:51*aeverr quit (*.net *.split)
21:53:51*letto quit (*.net *.split)
21:53:51*anti[m] quit (*.net *.split)
21:53:51*nekits quit (*.net *.split)
21:53:51*nikita` quit (*.net *.split)
21:53:52*sz0 quit (*.net *.split)
21:53:52*msmorgan quit (*.net *.split)
21:53:52*d10n-work quit (*.net *.split)
21:53:53*dgb quit (*.net *.split)
21:53:53*hpyc9 quit (*.net *.split)
21:54:15*disbot joined #nim
21:54:15*aeverr joined #nim
21:54:15*letto joined #nim
21:54:15*anti[m] joined #nim
21:54:15*nekits joined #nim
21:54:15*sz0 joined #nim
21:54:15*nikita` joined #nim
21:54:15*d10n-work joined #nim
21:54:15*msmorgan joined #nim
21:54:15*dgb joined #nim
21:54:15*hpyc9 joined #nim
21:54:26*natrys quit (Quit: natrys)
21:54:33*d10n-work quit (Max SendQ exceeded)
21:55:10*stefantalpalaru quit (*.net *.split)
21:55:10*kitech1 quit (*.net *.split)
21:55:10*def- quit (*.net *.split)
21:55:11*FromGitter quit (*.net *.split)
21:55:11*WilhelmVonWeiner quit (*.net *.split)
21:55:11*Cthalupa quit (*.net *.split)
21:55:12*blueberrypie quit (*.net *.split)
21:55:12*screens_ quit (*.net *.split)
21:55:32*stefantalpalaru joined #nim
21:55:32*kitech1 joined #nim
21:55:32*def- joined #nim
21:55:32*FromGitter joined #nim
21:55:32*WilhelmVonWeiner joined #nim
21:55:32*Cthalupa joined #nim
21:55:32*blueberrypie joined #nim
21:55:32*screens_ joined #nim
21:55:44*kitech1 quit (Max SendQ exceeded)
21:55:56*kungtotte quit (*.net *.split)
21:55:56*neceve quit (*.net *.split)
21:55:56*beatmox quit (*.net *.split)
21:55:56*qwertfisch quit (*.net *.split)
21:55:57*matthias[m]3 quit (*.net *.split)
21:55:59*watzon quit (*.net *.split)
21:55:59*sepples quit (*.net *.split)
21:55:59*Northstrider quit (*.net *.split)
21:56:05*kitech1 joined #nim
21:56:07*kitech1 quit (Changing host)
21:56:07*kitech1 joined #nim
21:56:18*neceve joined #nim
21:56:18*kungtotte joined #nim
21:56:18*beatmox joined #nim
21:56:18*qwertfisch joined #nim
21:56:18*matthias[m]3 joined #nim
21:56:18*watzon joined #nim
21:56:18*Northstrider joined #nim
21:56:18*sepples joined #nim
21:56:18*nikita` quit (Ping timeout: 245 seconds)
21:56:36*skrylar[m] quit (*.net *.split)
21:56:36*drewr quit (*.net *.split)
21:56:38*codic quit (*.net *.split)
21:56:39*TheManiac[m] quit (Ping timeout: 244 seconds)
21:56:40*lqdev[m] quit (Ping timeout: 244 seconds)
21:56:40*salotz[m] quit (Ping timeout: 244 seconds)
21:56:40*Jjp137_ quit (Ping timeout: 264 seconds)
21:56:40*msmorgan quit (Ping timeout: 246 seconds)
21:56:45*j4nvkvc quit (Ping timeout: 244 seconds)
21:56:47*matthias[m]3 quit (Ping timeout: 252 seconds)
21:57:00*sz0 quit (Ping timeout: 246 seconds)
21:57:08*sendell quit (Ping timeout: 260 seconds)
21:57:08*dannyfritz[m] quit (Ping timeout: 260 seconds)
21:57:09*k0mpjut0r quit (Ping timeout: 260 seconds)
21:57:39*msmorgan joined #nim
21:57:52*gangstacat quit (*.net *.split)
21:57:52*bbarker quit (*.net *.split)
21:57:52*bjornroberg quit (*.net *.split)
21:57:53*planetis[m] quit (*.net *.split)
21:57:53*ormiret quit (*.net *.split)
21:57:53*crem quit (*.net *.split)
21:57:53*casaca quit (*.net *.split)
21:57:54*tyler569 quit (*.net *.split)
21:57:54*bozaloshtsh_ quit (*.net *.split)
21:57:54*Cadey quit (*.net *.split)
21:58:14*gangstacat joined #nim
21:58:14*bbarker joined #nim
21:58:14*bjornroberg joined #nim
21:58:14*planetis[m] joined #nim
21:58:14*ormiret joined #nim
21:58:14*crem joined #nim
21:58:14*casaca joined #nim
21:58:14*tyler569 joined #nim
21:58:14*bozaloshtsh_ joined #nim
21:58:14*Cadey joined #nim
21:58:33*nisstyre quit (*.net *.split)
21:58:35*shodan45 quit (*.net *.split)
21:58:35*nickster quit (*.net *.split)
21:58:35*Mister_Magister quit (*.net *.split)
21:58:35*jxy quit (*.net *.split)
21:58:35*acidx quit (*.net *.split)
21:59:51*nisstyre joined #nim
21:59:51*shodan45 joined #nim
21:59:51*nickster joined #nim
21:59:51*Mister_Magister joined #nim
21:59:51*jxy joined #nim
21:59:51*acidx joined #nim
21:59:54*unclechu quit (Ping timeout: 244 seconds)
21:59:55*watzon quit (Ping timeout: 252 seconds)
21:59:55*drewr joined #nim
21:59:56*sschwarzer quit (Quit: leaving)
22:00:06*neceve quit (Ping timeout: 252 seconds)
22:00:06*nisstyre quit (Max SendQ exceeded)
22:00:15*dzamo[m] quit (Ping timeout: 244 seconds)
22:00:51*planetis[m] quit (Ping timeout: 246 seconds)
22:00:51*anti[m] quit (Ping timeout: 246 seconds)
22:00:51*kragil[m] quit (Ping timeout: 244 seconds)
22:00:52*oneark quit (Ping timeout: 244 seconds)
22:01:12*khanate[m]0 quit (Ping timeout: 260 seconds)
22:01:22*nikita` joined #nim
22:01:37*BitPuffin quit (Ping timeout: 272 seconds)
22:01:37*nisstyre joined #nim
22:03:49*sz0 joined #nim
22:05:01*d10n-work joined #nim
22:06:13*TheManiac[m] joined #nim
22:06:16*lqdev[m] joined #nim
22:07:16*dannyfritz[m] joined #nim
22:07:24*sendell joined #nim
22:12:18*neceve joined #nim
22:13:17*dzamo[m] joined #nim
22:13:22*Jesin joined #nim
22:14:26*khanate[m]0 joined #nim
22:15:04*kragil[m] joined #nim
22:15:04*oneark joined #nim
22:15:24*planetis[m] joined #nim
22:15:38*anti[m] joined #nim
22:16:12*BitPuffin joined #nim
22:16:44*matthias[m]3 joined #nim
22:16:46*salotz[m] joined #nim
22:16:50*everfree joined #nim
22:17:09*everfree is now known as arty
22:18:19*j4nvkvc joined #nim
22:21:12FromGitter<cyberlis> If I want to write linked list (I now about `lists` module in standard lib), I have to know about `owned`, `{.cursor.}` and everything about new destructors (`sink`, `destory` etc) ? Are there a way to write it simply ?
22:21:32*skrylar[m] joined #nim
22:26:04disruptekjust write it normally.
22:26:54*codic joined #nim
22:27:31*drewr quit (Remote host closed the connection)
22:27:58leorize[m]@cyberlis all those stuff are implementation details atm
22:28:18disruptekwell, optimizations.
22:28:27leorize[m]until the new GC can be transitioned to take the default spot, I wouldn't care too much about them
22:28:46*drewr joined #nim
22:31:32*k0mpjut0r joined #nim
22:34:22*ldlework joined #nim
22:34:32ldleworkIs there a favorite library for writing CLI tools?
22:35:06*watzon joined #nim
22:35:23*unclechu joined #nim
22:41:35leorize[m]my personal favorite is argparse, but many people swear by cligen
22:42:22leorize[m]and the terminal module provides a good set of tools to craft your own I/O styling
22:42:31ldleworknimble.directory seems to be having some troubles
22:47:37PrestigeI'm trying to draw a string with xft, and getting strange results. I think I may be casting a string incorrectly for the type. The first character is always correct, but the rest are wrong and different on each run: https://github.com/avahe-kellenberger/x11/blob/master/examples/xftex.nim#L84
22:48:09PrestigeThe second to last param was a ptr cchar but I've changed it to a cstring, which I think is fine.. not sure what's going wrong, if someone can help?
22:48:22leorize[m]Prestige: displayString[0].addr
22:48:27leorize[m]or `cstring(displayString)`
22:49:05Prestigeaha thanks!
22:49:15PrestigeIt's working
22:49:53Araqrandom idea: can we make 'func' enforce writes through 'var' parameters? many people seem to want even more "Purity"
22:50:02*cyraxjoe joined #nim
22:50:38Araqthis implies 'proc .noSidEffect' would be less strict than 'func'
22:50:48disrupteki want var refs to mean something first.
22:52:15disruptekreally failing hard on concepts, too.
22:52:23leorize[m]they shouldn't use `var` if they want purity...
23:01:57FromDiscord<Technisha Circuit> When i use dynlib to import a .so file, does the proc just act as a namespace for the imported.so file?
23:02:04FromDiscord<Technisha Circuit> (edit) 'imported.so' => 'imported .so'
23:02:17FromDiscord<Technisha Circuit> (edit) '.so' => '`.so`' | '.so' => '`.so`'
23:02:18*abm quit (Quit: Leaving)
23:03:14leorize[m]wdym namespace?
23:03:31ldleworkHow do you get the cli args?
23:03:53leorize[m]os.commandLineParams, os.paramCount, os.paramStr
23:03:56leorize[m]your choice :P
23:05:28ldleworkthanks
23:05:48*MightyJoe joined #nim
23:06:22FromDiscord<Rika> has anyone used redis in nim? which do yall use, (x)monade(r)'s module or the official one?
23:06:52FromDiscord<Technisha Circuit> Namespace as in a class sort of thing
23:07:00FromDiscord<Technisha Circuit> Or like a placeholder
23:07:09FromDiscord<Technisha Circuit> Also, where do i get cdecl from?
23:07:57ldleworkWhat's a nice library for easily executing external commands?
23:08:07*cyraxjoe quit (Ping timeout: 272 seconds)
23:08:36ldleworkshell looks nice
23:08:57FromDiscord<Rika> osproc?
23:09:28leorize[m]my library but you gotta wait since I haven't got it out :P
23:10:15leorize[m]@Technisha I still don't understand your question
23:10:25leorize[m]cdecl is a pragma thing
23:10:36FromDiscord<Technisha Circuit> Yeah, it says it's not defined
23:10:41ldleworkshell is a little complicated actually
23:10:47FromDiscord<Technisha Circuit> I need to know what to import to be able to use it
23:11:02FromDiscord<Technisha Circuit> ```↵/data/data/com.termux/files/home/nim_stuff/dynlibTesting/test.nim(3, 13) Error: invalid pragma: cdecl```
23:11:13ldleworkit'll do though
23:11:27FromDiscord<Technisha Circuit> ```nim↵import dynlib↵var name* {.cdecl, exportc, dynlib.}: string = "This is a test"```
23:11:30FromDiscord<Technisha Circuit> That's the code
23:12:11leorize[m]remove cdecl
23:12:19FromDiscord<Technisha Circuit> Oh okay
23:12:25leorize[m]it's only applicable to procs
23:12:53FromDiscord<Technisha Circuit> Oh okay
23:12:56FromDiscord<Technisha Circuit> Thanks!
23:14:30ldleworkIt's too bad there's no way to make shell execute the stuff quietly
23:14:59ldleworkoh you can
23:15:33ldleworknice
23:20:22FromDiscord<Elegant Beef> Holy shit ldlework
23:20:31FromDiscord<Elegant Beef> Atleast i assume it's you from GDL
23:20:46*ldlework waves.
23:21:14FromDiscord<Elegant Beef> So leorize how do i use the master file with the PTY, do i open the file descriptor and read/write that file
23:21:23FromDiscord<Elegant Beef> Cause i've tried a variety of things but.. no cigar
23:21:40FromDiscord<Elegant Beef> There is actually a surprising amount of users from the GDL discord to here
23:21:52leorize[m]master file?
23:21:57FromDiscord<Rika> gdl => game dev, lol
23:21:58leorize[m]what are you trying to do?
23:22:04FromDiscord<Rika> (i am joking)
23:22:21FromDiscord<Elegant Beef> Currently attempting to interact with the slave
23:22:31FromDiscord<Elegant Beef> https://hatebin.com/dhqtjbhqae
23:22:35FromDiscord<Elegant Beef> Current state of it
23:22:48FromDiscord<Elegant Beef> Nothing has changed much
23:23:01FromDiscord<Elegant Beef> Although it seems the bash invoktion is working but in certain
23:23:23FromDiscord<Elegant Beef> (edit) 'in certain' => 'im uncertain'
23:24:03leorize[m]whatever you write to the PT master will be the input
23:24:07FromDiscord<Elegant Beef> Yea i know
23:24:12FromDiscord<Elegant Beef> But how do i open the PT master in nim
23:24:30FromDiscord<Elegant Beef> Using the file descriptor as a filehandle only lets me open it as fmread
23:24:38leorize[m]use posix.open()
23:24:44leorize[m]oh wait you don't have to lmao
23:24:54leorize[m]it's already opened
23:25:02FromDiscord<Elegant Beef> Then how do i write to it?
23:25:15FromDiscord<Elegant Beef> Do i change my std streams to it?
23:25:17leorize[m]posix.write :)
23:25:41FromDiscord<Elegant Beef> I really hope that isnt that easy 😄
23:25:53ldleworkIf I wanted to bypass nimble completely, and download my dependencies directly from github to disk, how do I arrange things so I can compile my app and nim will find the depenencies
23:26:12ldleworkjust use -p?
23:27:13leorize[m]yea, or use `nimph`
23:27:32leorize[m]it lets you vendor packages afaik
23:27:48leorize[m]!repo nimph
23:27:50disbothttps://github.com/disruptek/nimph -- 9nimph: 11Nim package hierarchy manager from the future 🧚 15 65⭐ 4🍴 7& 1 more...
23:33:29ldleworkhow do I prevent nim from creating .cache/nim/nixt_d ?
23:33:40ldleworknm
23:35:10ldleworknice i can build nim stuff in nix now
23:35:27FromDiscord<Elegant Beef> Using nixos?
23:35:30ldleworkya
23:35:44ldleworkI need a nimble2nix :P
23:35:49FromDiscord<Elegant Beef> I only know that it has an interesting pkgmanager
23:35:57FromDiscord<Elegant Beef> Never looked into it
23:36:37ldleworkIt's a functionally pure package manager
23:36:45ldleworkIt has unprecedented reproducability guarantees
23:37:04ldleworkThe learning curve is absolute hell though if you're new to functionalshit like I was
23:37:14FromDiscord<Elegant Beef> As a numpty using ubuntu derived
23:37:16FromDiscord<Elegant Beef> Think ill pass
23:37:16ldleworkBut my workstation and servers are so gd nicce now
23:37:18FromDiscord<Elegant Beef> 😄
23:39:28ldleworkis there a nimble lock file?
23:39:37ldleworki'll rtfm
23:41:05leorize[m]nope there aren't any atm
23:42:20ldleworkWell that explains why there is no nimble2nix yet ^_^'
23:52:55FromDiscord<Elegant Beef> Well go make a PR 😛
23:53:08FromDiscord<Elegant Beef> Coming from a man that cant make a terminal emullator
23:53:12FromDiscord<Elegant Beef> (edit) 'emullator' => 'emulator'
23:55:54*Jjp137_ joined #nim