<< 02-11-2019 >>

00:00:11dom96I think that's an important question to answer
00:00:50FromGitter<Willyboar> I personally likes the current system and insist that a tool like virtualenv would be a solution
00:01:01*zyklon quit (Ping timeout: 268 seconds)
00:01:10dom96Willyboar: virtualenv? Why would we need virtualenv?
00:01:22FromGitter<Willyboar> not as a default
00:01:50dom96we don't need virtualenv
00:02:06dom96we can have multiple versions of the same library installed
00:02:16*zyklon joined #nim
00:03:08*jjido joined #nim
00:03:15dom96But I also personally like the current system. The only advantage that these local deps will bring is that it will be slightly easier to modify the dependencies if you want to fix something
00:04:00dom96And if that's the only problem we are solving then I am having doubts that we should solve that problem in this way.
00:07:16shashlickThis is really a question of isolation
00:07:29shashlickNothing from other projects should impact this project
00:09:17FromGitter<Willyboar> What languages use a similar system? Python and ruby they don't. I think node use it.
00:09:46rayman22201node is the only language that uses a subcommand for this
00:09:49rayman22201that I know of
00:10:10FromGitter<Willyboar> is this nodemodules folder?
00:10:17rayman22201yeah
00:10:32dom96shashlick, I know, but there is something to be concerned about and that is complexity of Nimble. This feature will touch a lot of code and I'm sure it won't end here, we'll need to adjust the way the packages are put into this deps folder and we'll get more and more special cases just for this which will make Nimble's code base really complex.
00:10:35rayman22201You have a global `nodemodules` but can pass `--local`
00:11:09rayman22201I don't have a preference, just giving an example for context
00:12:14FromGitter<Willyboar> but i think a freeze command it would be nice
00:12:46shashlickI have some more thoughts on this and I'll update the doc for tomorrow
00:12:52dom96Anyway, 'night
00:13:02shashlickGn
00:13:05FromGitter<Willyboar> goodnight dom
00:13:11rayman22201gn
00:15:25FromGitter<Willyboar> anybody who can help with this issue?
00:15:27FromGitter<Willyboar> https://github.com/thebigbaron/pine/issues/4
00:22:02*oculux quit (Quit: blah)
00:25:30*Vladar quit (Remote host closed the connection)
00:26:09*oculux joined #nim
00:35:11Araqthere is no complexity here, you have a deps/ dir, Nimble uses it. the end.
00:37:09*ftsf joined #nim
00:39:34rayman22201If you are still awake, I have a problem. I want to pass 'out' params for "closureRef" and "closureIterRef" into the async procs. But I have no clue what the type of a "closureRef" is, or a "closureIterRef" for that matter.... :/
00:45:36*krux02_ joined #nim
00:48:39*krux02 quit (Ping timeout: 264 seconds)
00:50:30*jjido quit (Quit: My MacBook has gone to sleep. ZZZzzz…)
01:13:57FromGitter<Varriount> If you don't know what they are, why do you need to pass parameters for them?
01:14:37rayman22201Macros
01:15:40rayman22201Also. Bad question. You often need types that are derived. That's why auto exists
01:17:20*kevin_ joined #nim
01:19:21disruptekshashlick: you up?
01:28:20disruptekoffered my comments here: https://gist.github.com/genotrance/ee2ce321a56c95df2d4bb7ce4bd6b5ab#gistcomment-3072295
01:28:37*kevin_ quit (Quit: leaving)
01:48:26shashlickhey
01:48:41disruptekjust posted another long comment.
01:48:51disruptekbrb
01:50:10shashlickno problem, thanks for taking the time
01:51:46disruptekaside from my comments, i think the two open issues are `develop` and what to do about binaries like toast.
01:52:32shashlicktoast already works cause it is relative to cimport.nim
01:52:39shashlickwhich is part of the same pacakge
01:52:50disruptekah, sneaky.
01:53:01disruptekdid you bump libarchive with bump?
01:53:02shashlickthe problem is if you refer to a binary from another package
01:53:11shashlicki only use bump nowadays
01:53:18disruptekany gotchas?
01:53:21shashlickwho has time
01:53:25shashlicknaah, works great
01:53:54disrupteki just put in a projectVersion*() that you can use to get a version for embedding in cligen's --version.
01:53:55shashlickdid you see the chat earlier on the gist?
01:54:08shashlicki am thinking of localdeps to be an extension of nimble develop
01:57:08FromDiscord<Karl Marx> Hey can someone help me a bit
01:57:08*snooptek quit (Remote host closed the connection)
01:57:25FromDiscord<Karl Marx> I want to collect, terminal arguments and parse them into an string
01:57:57FromDiscord<Karl Marx> But I get this error
01:57:57FromDiscord<Karl Marx> https://cdn.discordapp.com/attachments/371759389889003532/640006650299940895/Screen_Shot_2019-11-01_at_7.57.43_PM.png
01:58:02FromDiscord<Karl Marx> How to convert a Tained String into a normal string?
01:58:27shashlick$
01:58:42FromDiscord<Karl Marx> Where do I put the $?
01:58:57FromDiscord<Karl Marx> Since I read about it in the docs, but I didnt really understand it
01:59:30shashlickcollector is a sequence of tainted strings
01:59:41shashlickyou don't pass it to newString
02:00:08FromDiscord<Karl Marx> Ohhh I get it now
02:00:10shashlickif you want, you can use collector.join(" ") to create a string out of the sequence separated by spaces
02:01:21FromDiscord<Karl Marx> Since its the terminal args, how would I parse lets say, the first argument the user does like: "command [argument]" so how do I grab the [argument] part and parse it to an string? I know how to do this in rust, but I have no idea how to do this on Nim
02:01:56shashlickcollector[0] = command
02:02:09shashlickcollector[1 .. ^1] = arguments in a sequence
02:02:39shashlickso you could `collector[1 .. ^1].join(" ")`
02:03:50*snooptek joined #nim
02:05:01disruptekshashlick: sorry, wedged my ws.
02:05:03FromDiscord<Karl Marx> It works! Thank u
02:05:04FromDiscord<Karl Marx> https://cdn.discordapp.com/attachments/371759389889003532/640008438864281621/Screen_Shot_2019-11-01_at_8.04.25_PM.png
02:05:27disrupteklocal deps work for me as `nimble develop`.
02:05:55shashlickwhat's a good place to store such a spec
02:06:11shashlickgist sucks for editing and highlighting what changed
02:06:40disrupteki woulda said gist. 😀
02:06:52disrupteki just wrote an ix paster.
02:07:09shashlickix is a one line curl command
02:07:16disruptekmostly so i can have a bot send me repro's that link to the playground.
02:07:24disruptekcurl is for pussies.
02:08:55disruptekwhat do i do about my crap code problem?
02:09:52shashlickeach top level project should have its own deps
02:09:59*kevin_ joined #nim
02:10:27shashlickif we pull in the exact deps of deps, you can have incompatible versions together
02:10:38shashlickif you see how lockfiles work, they do the same thing
02:10:56shashlickeach project has its own lockfile that isn't impacted by those of its dependencies' lockfiles
02:11:50disruptekyeah, but i'm talking about dogshit i wanna break out. i guess i just do it manually.
02:12:38shashlickthat's just an answer for the first line
02:12:43shashlicklet me understand the rest
02:19:08shashlickwhy wouldn't you put the not-yet-ready code in a subdir and refer to them with relative paths?
02:19:55lmariscalis ephja here?
02:20:00disruptekonly because i want them to be modules so i can do normal git operations on them.
02:20:29shashlickthen they are independently in git anyway
02:20:47disruptekyeah, i'm not sure how it works. it's an issue i have with the problem of distributions.
02:21:23shashlicki guess you need to put them into nimble then
02:22:50*ng0_ joined #nim
02:24:09shashlickyou could do git submodules if you don't want them in nimble
02:24:18disruptekyep.
02:24:39disrupteki have to see how it feels once i start on nimph.
02:24:40shashlickor we can have a `requires "https://github.com/abc/def"`
02:24:54shashlicknot sure if nimble already supports that
02:24:59disruptekthat's what i use now.
02:25:12disruptekit's only the "distributions" use-case that i'm thinking about.
02:25:32*ng0 quit (Ping timeout: 260 seconds)
02:25:35disruptekif you wanna distribute some closed software with local deps, is there any way to do it?
02:25:49disruptekthis isn't such a strange request.
02:26:54kevin_👑️
02:27:07disruptekoh shoot
02:27:11disruptek👑
02:27:23disrupteki see your crown and raise you a crown.
02:28:12kevin_I still learn how to use 👑️
02:28:33kevin_😋️
02:28:55FromGitter<Willyboar> shashlick that was one thing i hate to golang
02:29:19FromGitter<kaushalmodi> shasklick: nimterop 0.3.3 also works great. Many thanks!
02:29:34shashlickexcellent, thanks for checking
02:31:25FromGitter<Willyboar> you have google from behind build a package hosting
02:31:58shashlick@disruptek - for closed source, you need binary distribution right
02:32:34disrupteki mean internal stuff that you might want to put in your dist.
02:33:36shashlickright you don't want to check it into the project and it's in a separate repo
02:34:02disruptekyeah.
02:34:47disrupteki have a lot of this stuff and putting it in a dist makes a lot of sense for reproducibility.
02:35:37disruptekmy dists will be immutable.
02:35:53shashlicki don't see how nimble can help there
02:36:07shashlickwe cannot rely on git cause nimble supports hg either
02:37:00disrupteki think it's fine for me, just not sure about anyone else.
02:37:19shashlickhow would you solve the thing i said about lock files
02:37:34shashlickhow do you decide to retain the deps vs ignoring them
02:37:40disruptekeverything i do will be local deps.
02:38:27*exelotl quit (Ping timeout: 264 seconds)
02:41:22shashlickso this is only an issue if the project with local deps is actually a library
02:42:51disruptekis it?
02:43:05shashlickwhy else would you install it into ~/.nimble
02:43:20disrupteki mean, i have this problem now.
02:44:08shashlickright but if we do implement local deps as described in the gist
02:44:16shashlickit would solve your problem no
02:44:32disrupteki can't `develop` bump because it produces a binary, so i edit the file. then if i wanna install it alongside my other nimble binaries, i edit the file and `nimble install`. then i edit the file again so i can develop it. and now i've got 17 versions of bump in my ~/.nimble.
02:45:00disruptekif we do local deps, i won't ever use global deps.
02:45:07disruptekso, yeah, all my problems are solved.
02:45:32disruptekexcept for editing my $PATH 😀
02:46:01disrupteki actually just symlink from my ~/bin directly to my devel bump, but don't let Araq hear me say that.
02:46:53shashlickya it would be nice if nimble supported binaries for `nimble develop`
02:47:27disruptekanyway, i'm hopeful we can get the compiler patched and move forward on this. it'll help a lot of people, i think.
02:48:24shashlickwe might not need compiler changes
02:48:53shashlickcause local deps will need some nimble action which can create and maintain a nim.cfg file for you
02:49:01disruptekwe do because it looks in ~/.nimble no matter what.
02:49:14*krux02_ quit (Remote host closed the connection)
02:49:24shashlickwe can add --noNimblePath to the cfg
02:49:38disruptekthat's not enough. 🙁
02:50:00shashlickwhy not
02:50:16disruptek'cause it still looks. try it. i could be wrong, but i don't think so.
02:50:28*GordonBGood joined #nim
02:53:29shashlickthat's what nimble does when you do nimble c
02:54:00shashlickshould work
02:54:12disrupteklemme me try it again.
02:54:20shashlick--noNimblePath
02:56:14disruptekif you specify a path and it doesn't exist, it loads from ~/.nimble.
02:57:27shashlickwhy are you specifying anything
02:57:32shashlickpresume you are running nim and not nimble
02:57:39disrupteki /am/ running nim.
02:58:22disrupteki specified a directory that didn't exist -- it loaded .nimble. i specified a directory that exists and is empty -- it loaded .nimble. i specify --noNimblePath, it doesn't look anywhere. okay, at least that works.
02:58:52disruptekbut the other two don't work unless i'm willing to manually add everything to my nim.cfg/config.nims, which frankly, i'm willing to do to get proper behavior.
03:00:11shashlickSo that's the current behavior - use noNimblePath plus explicit --path for each dep
03:00:23shashlickLocal deps will automate that
03:01:00disruptekyou're just gonna have to accept that some people don't want to have to run `nimble build` in order to build their software.
03:01:03disrupteki'm one of those people.
03:01:07disruptekaraq is one of those people.
03:01:41shashlickI understand - nimble commands will work sure, but maintaining a Nim.cfg will make Nim work too
03:01:59shashlickAnyway you will use nimble to install and maintain deps
03:02:12shashlickSo it can maintain the cfg and nim doesn't have to change
03:02:15disruptekif we could give nim a --nimblePath in nim.cfg or on the command-line and it does the right thing -- ie. not looking anywhere else, that would be an improvement.
03:02:21disruptekbut that's not the current behavior.
03:02:25disruptekso, nim does need to change.
03:03:03disruptekbut don't take my word for it -- try it yourself.
03:05:18*lritter quit (Ping timeout: 245 seconds)
03:10:58shashlick--nimblePath appends, so that's not what we want
03:11:20shashlick--noNimblePath + paths is all we have now
03:11:29shashlicki don't want to mix that into this local deps requirement tho
03:13:30shashlicki think i've kind of addressed all your concerns in your second comment
03:14:00shashlickas far as explicit behavior, it is explicit cause you need to either create a deps folder or set a .nimble flag
03:14:22shashlickand it only applies when it is checked out and the main project
03:14:47disruptekyeah, but `mkdir` isn't all that explicit. it's easy to overlook when wondering why something isn't behavior the way you expect.
03:15:03disruptekyou look in your local config, nothin'. you look in your global config, nothin'. wtf, nim?
03:15:17shashlickpeople are used to node_modules folders littered around
03:15:29shashlickit will take time but it is obvious
03:16:10shashlickdebatable sure, but those who want local deps will know about it
03:16:13disruptekyou don't create node_modules.
03:16:18disrupteknpm is local by default.
03:16:28shashlickperhaps we can add a line to nimble output stating local mode or something
03:16:36disruptekthat would work.
03:16:51shashlickso every time it runs, it makes it clear where deps are being loaded from
03:17:27disruptekor where they are installed to.
03:17:34shashlickadding a flag is not an issue, but then we need to design which commands or sub-commands it applies to and what not
03:17:57shashlickbunch of code to just set nimbleDir
03:18:29disrupteksometimes a bad design is expensive to change.
03:18:45disruptekbut not as expensive as living with it.
03:19:17shashlickdo you agree that local deps are only relevant as the main project but not for libraries?
03:20:55disruptekyou mean are deps recursive?
03:21:00disruptekrecursively local?
03:21:12disrupteknim doesn't support that yet, afaik.
03:22:30shashlickno suppose i make a project with local deps, do all my dev and checkin
03:23:01shashlickif someone nimble installs that project into ~/.nimble, those deps won't come down with it
03:23:44shashlickcause now it lives with the rest of the gang of deps in ~/.nimble
03:23:52disrupteki think if i can dev locally, then you can have global install.
03:24:05disrupteki would get araq's opinion on that.
03:24:25shashlickalso, if they want to create a project with local deps that depends on that project which has local deps
03:25:04shashlicktheir project's dep tree will supersede
03:25:38shashlickif every dep locks its dependencies, you will get multiple versions of the same deps
03:25:47shashlicki read this is how lock files work
03:26:30disruptekif i'm devel'ing project A and it depends upon C1 and B and project B is also local and depends on C2, then i don't mind `nimble build` installing C2 in my A deps folder.
03:28:12disruptekB would have to {.path.} a specific version, i guess. i think the tooling is behind on this use-case.
03:28:36shashlickthat will happen anyway, but note that a C2 checked into B won't be pulled as is, nimble will pull C2 from upstream
03:28:45shashlickhttps://snyk.io/blog/making-sense-of-package-lock-files-in-the-npm-ecosystem/ - see the last para on libraries
03:29:26disruptekyou should watch hickey's talk on package management if you haven't.
03:32:49disruptekhttps://www.youtube.com/watch?v=oyLBGkS5ICk
03:34:39disruptekif i already have B devel-linked in, is nimble going to try to reinstall it?
03:36:44shashlicklinked in how/where
03:36:59disrupteksay B is already `nimble develop`ed.
03:38:11disruptekanother reason to bump versions more often. 😊
03:39:19shashlickhow do you see `nimble develop` linking a project into the local deps dir of another project
03:39:46disruptekfair question.
03:40:19disruptekwhat does `nimble develop` actually do if i'm using local deps?
03:41:05disrupteki've never actually seen hickey speak in real time.
03:41:23disruptekafaik he speaks at 1.75x speed because i can't bear to watch him any slower.
03:46:39shashlickehe
03:46:46shashlicki'm still fleshing out the nimble develop behavior
03:46:56shashlickbut that's for the project in question
03:47:17shashlicki've not gotten far enough for nimble developing a project in a project with local deps
03:47:41shashlickits just a link really but you usually run nimble develop in that project's dir and ~/.nimble is implicit
03:48:02disruptekah, yeah, a lot of my stuff relies on other of my stuff. most of it.
03:48:13shashlicklocal deps are only relevant in that project's dir, how do you run the develop command on some other dir then
03:48:37shashlickunless it is `nimble develop path/to/dir`
03:48:44disruptekcould be a symlink. i dunno. i can do that with nimph if i have to.
03:48:52disrupteki'm just trying to understand what `nimble develop` even means.
03:48:55shashlickbut not sure it is supported yet
03:49:26shashlicknimble develop makes a link file in ~/.nimble/pkgs so nim knows where to really look
03:49:34shashlickrest is the same
03:49:34disruptekright, i know that much.
03:49:47disruptekokay, so we can decide exactly what it does in this use-case.
03:49:52disruptekit's wide open.
03:51:25disruptekso if you're in a local-deps `develop` project and you run `develop`, you pass it a path or it's a user error.
03:51:37disruptekseems pretty easy.
03:52:00disruptekit could be a different name to make it less confusing.
03:53:09shashlickunless it is the other way around - run `nimble develop --nimbleDir:local-dep-dir`
03:53:21shashlickwonder if that works today
03:54:13disruptekthat should work, though does it matter that you have the subcommand before the option?
03:56:37shashlickwhichever way it works
03:57:06shashlickhelp says nimble COMMAND [opts]
03:57:37disruptekhuh. okay.
03:58:01shashlickmade some updates to the gist
04:05:54shashlickwondering what `nimble develop` should even do
04:07:10disruptekit installs `localDependencies = true` in your `project.nimble` and then runs `nimble install`.
04:08:38shashlickwhy would nimble develop force local deps
04:09:28disrupteki guess that's true.
04:10:00shashlickbut if it came with predefined local deps, it should install deps there ya
04:10:32disrupteki think this is more complex than it needs to be but it'll be a hard sell to just put it all under a separate subcommand.
04:12:19shashlickthe code changes aren't very large
04:12:27shashlickbut i want the behavior to be clear
04:13:01disrupteki'm just talking about the user.
04:13:21disruptekdevelop did one thing, i don't think it should suddenly do a very different thing.
04:13:38shashlickdo you think `nimble develop pkgwlocaldeps` should setup the project in ~/.nimble as well as with local deps?
04:13:39disruptekcontext changing with the behavior staying the same... that's fine.
04:14:13disruptekno, if you wanna set it up globally you can use --global.
04:14:30disruptekthere could be a --local too.
04:14:50disruptekit doesn't hurt the user to give them more explicit ways to tell us what they want.
04:14:56shashlicki think --global needs to be reserved for cross-user global, that's a different issue
04:15:02disruptekit gives us more opportunities to verify that we're doing the right thing.
04:15:15disruptekokay, well, w/e.
04:15:20shashlickbut that also complicates the user experience
04:15:42disruptekyou don't need to use --v with bump anymore, but i bet you still do.
04:16:54shashlicknope, not used it
04:17:02shashlickbump's smart
04:17:10disruptekhmmph.
04:17:47disruptekdid it ever fail gracefully for you?
04:19:09disrupteki guess what i'm getting at is that when the user provides more input, you can use it to provide better output.
04:19:24disrupteki know it's a balancing act. just sayin'.
04:22:37shashlickya i'm not too opinionated, i like driving for clarity and good arguments
04:33:35*kevin_ quit (Ping timeout: 276 seconds)
04:33:57shashlickanother update around `nimble develop` but i'm not thrilled about it
04:34:15shashlickfor folks when you wake up - https://gist.github.com/genotrance/ee2ce321a56c95df2d4bb7ce4bd6b5ab
04:47:40*kungtotte quit (Quit: WeeChat 2.6)
04:57:26*chemist69 quit (Ping timeout: 246 seconds)
04:58:47*kungtotte joined #nim
04:59:35*chemist69 joined #nim
05:18:40*leorize quit (Ping timeout: 260 seconds)
05:22:02*leorize joined #nim
05:53:01*kevin joined #nim
05:53:25*kevin is now known as Guest19657
06:14:10*dddddd quit (Remote host closed the connection)
06:35:11*solitudesf joined #nim
06:41:37*narimiran joined #nim
07:00:00*gmpreussner quit (Quit: kthxbye)
07:03:55*zyklon quit (Remote host closed the connection)
07:04:59GordonBGoodAraq: posted an issue against the "closures memory leak" issue, in spite of your PR - https://github.com/nim-lang/Nim/issues/12577
07:05:02*gmpreussner joined #nim
07:05:18GordonBGoodI think it's a valid issue as per my tests
07:11:13*theelous3_ joined #nim
07:11:58*nsf joined #nim
07:12:39*theelous3 quit (Ping timeout: 264 seconds)
07:13:25*uvegbot joined #nim
07:15:37*codeasone joined #nim
07:19:27AraqGordonBGood: I'm aware my patch must be done unconditionally
07:24:27*ndl joined #nim
07:24:39GordonBGoodAraq: ah, good, I filed the issue just as we last agreed, but in testing I also see something wierd in "Alternative 2", a seq field doesn't get destroyed in spite of the destructor being called
07:24:52GordonBGoodthose are version 2 seq's
07:25:03FromDiscord<ndl> hi
07:25:05ndlhi
07:25:33ndl(:
07:25:58AraqGordonBGood: are you at a point where you can fix bugs like these now? :P
07:27:14Araq # tst.`=destroy` # this one on --gc:destructors produces dangling references exist FATAL error!
07:27:16GordonBGoodAraq, I'm not sure - I understand them when I read them and I understand your fixes, but I guess I won't know if I can fix them myself unless I try :)
07:27:48Araqwell d'oh, don't call =destroy yourself, the compiler does it for you
07:27:49GordonBGoodYeah, that one was new and a surprise
07:28:11Araqwe don't 'nil' out refs in the generated destructor
07:28:39Araqjust let the compiler do its job, don't nanny it
07:28:53GordonBGoodThat was left over from what you suggested; in fact wrapping the whole thing in a try:/finally shouldn't be necessary as the compiler effectively does that
07:29:20*solitudesf quit (Ping timeout: 268 seconds)
07:31:55GordonBGoodAnyway, given that your patch will be applied unconditionally and back-ported, I just have to look into why the seq fields (Alternative 2) aren't deallocating their memory
07:32:03GordonBGoodThat seems easy to trace
07:38:39GordonBGoodseq's version 2 have their own custom =destroy's so nothing should be generated by calling them, right?
07:48:07GordonBGoodHave to go - jungle day - back in a few hours
07:48:35Araqbye
07:52:26*GordonBGood quit (Ping timeout: 240 seconds)
07:57:07*ndl quit (Quit: leaving)
08:03:30*gmpreussner_ joined #nim
08:04:18*gmpreussner quit (Ping timeout: 265 seconds)
08:08:03*jjido joined #nim
08:45:46*eterps left #nim (#nim)
08:49:41*Vladar joined #nim
09:00:04*Trustable joined #nim
09:04:20FromGitter<zacharycarter> cool - my little sokol example works with the destructors gc
09:23:11FromDiscord<Lantos> using what I've learned from you guys 🙂
09:23:11FromDiscord<Lantos> https://cdn.discordapp.com/attachments/371759389889003532/640118691475750919/data.png
09:24:44FromDiscord<Lantos> any guesses to what this is?
09:29:14FromGitter<zacharycarter> Bitcoin moving average?
09:31:39FromDiscord<Lantos> yep!
09:37:36FromDiscord<Lantos> I seem to be bottle necked by nimitry. Will try the gnuplot wrapper
09:38:25FromDiscord<Lantos> or nimx to render it
09:39:41FromDiscord<Lantos> or nimx
09:42:50*GordonBGood joined #nim
09:55:06GordonBGoodI'm back - got rained out
09:55:25*NimBot joined #nim
10:06:13*krux02 joined #nim
10:12:34FromDiscord<Chiqqum_Ngbata> Last time I had to plot something I generated CSV and threw it at R
10:13:28*Guest19657 quit (Remote host closed the connection)
10:29:08*ng0_ quit (Quit: Alexa, when is the end of world?)
10:35:49*filcuc joined #nim
10:37:42GordonBGoodAraq: I've found the problem with destroying seq's with "--gc:destructors": you have now defined "nimV2" as part of "--gc:destructors"; and "nimV2" is set to disable seqsv2 "hooks"
10:38:18GordonBGoodI'm confused, as you used to use "nimV2" it meant "--newruntime", so this seems ambiguous
10:45:23*letto quit (Read error: Connection reset by peer)
10:45:45*letto joined #nim
10:56:18*ng0 joined #nim
10:57:09GordonBGoodI take it that "nimV2" no longer means "newruntime" but now mean either "gcDestructors" or "gcHooks" or "newruntime", with "nimOwnedEnabled" now meaning B/D
10:58:25GordonBGoodI still don't see why "--newruntime" also mean "gcHooks", but never mind, that doesn't affect me for now...
10:59:04*filcuc quit (Quit: Konversation terminated!)
11:15:49FromDiscord<krab4t> why Haxe extension for VSCode looks way better than nim? 🙂
11:16:35*Vladar quit (Quit: Leaving)
11:19:39FromDiscord<krab4t> https://i.imgur.com/zSiaoUY.png WTF
11:20:28*skellock joined #nim
11:25:21FromDiscord<Rika> what're you WTFing about
11:31:08dom96Araq, please answer the questions: https://irclogs.nim-lang.org/01-11-2019.html#23:56:43
11:35:35dom96or answer it here: https://gist.github.com/genotrance/ee2ce321a56c95df2d4bb7ce4bd6b5ab#gistcomment-3072452
11:36:01*solitudesf joined #nim
11:39:27*clyybber joined #nim
11:40:05clyybberdisruptek, Araq: Should I provide a pragma for object fields to enforce explicit initalization?
11:52:01*krux02 quit (Remote host closed the connection)
11:55:00lqdev[m]@krab4t because the author of the Nim extension didn't pay attention to details
11:55:06lqdev[m]I bet it works better too
11:55:11lqdev[m](the haxe ext)
12:00:08FromGitter<rishavs> Have a question on Vladar's nimgame2
12:00:39FromGitter<rishavs> Just ran the platformer demo with 0.6.1. I can feel some microfreezes every 15-20 secs. Are these GC pauses?
12:03:30clyybberrishavs: Try with --gc:boehm and maybe some other gc's and if it disappears its probably the GC
12:03:44FromDiscord<Rika> or if it changes pattern
12:03:49clyybberyeah
12:03:54FromDiscord<Rika> try one of the stop the world GCs nim has
12:04:16FromDiscord<Rika> is go's GC stop the world? maybe try that, see if the freezes lengthen
12:05:34FromDiscord<Lantos> @Chiqqum_Ngbata did you do this because you couldn't find a quick grapher?
12:05:43clyybberI think go's GC isn't stop the world
12:05:58clyybberAnd for gc:go you require some dll I think
12:06:09clyybberwhich you get from the go distribution package
12:06:11FromDiscord<Chiqqum_Ngbata> R is just seductively easy to work with
12:06:33FromDiscord<Lantos> lol never heard a language talked about in that way
12:06:46FromDiscord<Rika> seductively easy...
12:06:57FromDiscord<Chiqqum_Ngbata> Think I tried other things and had a moment of clarity "I don't want to program plots!"
12:07:45zedeushttps://github.com/Vindaar/ggplotnim
12:09:09FromDiscord<Rika> OOH
12:09:16FromDiscord<Rika> ***shiny***
12:11:06lqdev[m]@Rike go and boehm are stop the world and afaik you dont need any extra dlls
12:11:26FromDiscord<Rika> i knew it 😛
12:12:04lqdev[m]iirc the details are pointed out in the gc manual
12:13:25FromGitter<rishavs> I tried the perf flags `--multimethods:on -d:release --opt:speed` and dont seem to be getting any microfreezes anymore in the demo
12:13:35lqdev[m]indeed https://nim-lang.org/docs/gc.html#garbage-collector-options
12:13:36*jjido quit (Quit: My MacBook has gone to sleep. ZZZzzz…)
12:14:05lqdev[m]by "Go lang-like" I understand that it's an in-house implementation
12:14:15clyybberrishavs: --multimethods:on is not a flag that enables more performance
12:14:53FromGitter<rishavs> oh. I found them in the nimgame2 github readme
12:15:16FromGitter<rishavs> bt in general for gamedev, which gc would be the best to go with among these? https://nim-lang.org/docs/gc.html#garbage-collector-options
12:15:44FromGitter<rishavs> I am assuming anything with "stop the world" is something i should stay away from?
12:16:01FromDiscord<Rika> yes
12:16:17FromDiscord<Rika> if its a game you avoid stop the world
12:16:54clyybberrishavs: That means nimgame2 needs multimethods, so I'd leave it enabled..
12:21:22FromDiscord<Rika> destructors when 😛
12:22:31FromGitter<zacharycarter> @rishavs - you should go with Nim's default GC, regions GC, no GC or the new destructor based GC
12:23:09FromGitter<zacharycarter> boehm mark and sweep and golang's GC are all considered stop the world GCs
12:27:25lqdev[m]rishavs: the default gc works really well for games, I used it already in memrecall and planet overgamma
12:33:28*ponyrider quit (Quit: WeeChat 2.6)
12:33:49*ponyrider joined #nim
12:36:19*clyybber quit (Quit: WeeChat 2.6)
12:45:59*uu91 joined #nim
13:01:37*GordonBGood quit (Ping timeout: 240 seconds)
13:02:02*uvegbot quit (Quit: Konversation terminated!)
13:07:41FromGitter<kaushalmodi> @Vindaar Does the dependencies section of ggplotnim need to get updated? https://github.com/Vindaar/ggplotnim/blob/master/README.org#dependencies
13:08:48FromGitter<kaushalmodi> I'd like to try it out but am looking for small examples that basically take in XY data series and plot that (like the examples of nimetry package).
13:09:02*Kaivo quit (Quit: WeeChat 2.6)
13:09:46FromGitter<kaushalmodi> My use case is that I would have the XY data and then I'd need to save the plot of those to files (I tried plotly but that pops up a browser window each time, and then that window stays open).
13:10:53FromGitter<kaushalmodi> In my use case, I would literally be generating hundreds of such graphs in a batch. Then based on the simulation status, I would look at the respective plot file to see what went wrong.
13:15:00*natrys joined #nim
13:31:42FromDiscord<Chiqqum_Ngbata> From nim documentation "$projectDir/nim.cfg"
13:31:45FromDiscord<Chiqqum_Ngbata> What is a projectDir? CWD?
13:33:23FromDiscord<mratsim> projectdir is your git directory
13:33:34FromDiscord<mratsim> the base directory of your project
13:33:41disruptekand the directory holding a something.nimble file.
13:34:25FromGitter<kaushalmodi> mratsim: It's not the git directory. I had to cook up something to get that
13:34:32FromDiscord<Chiqqum_Ngbata> Thanks
13:34:54FromDiscord<Chiqqum_Ngbata> Oh, uh.. what is it then?
13:35:55FromDiscord<mratsim> Multithreading runtimes are a pain to design :/. You need to think of data structures where people run N threads for days and they should leave no gorbage even if sometimes you have 1 billion tasks and sometimes only 2 ...
13:38:09FromGitter<kaushalmodi> Chiqqum_Ngbata: https://github.com/nim-lang/Nim/issues/9467 <-- related issue
13:39:20*dddddd joined #nim
13:39:58FromGitter<kaushalmodi> The default behavior of `projectDir` in nims is misleading. So I don't use that any more.
13:40:30FromGitter<kaushalmodi> I define the `getGitRoot()` proc defined in that issue in my global config.nims
13:40:36*lritter joined #nim
13:41:54disrupteki think it might have been fixed recently.
13:43:26FromGitter<kaushalmodi> hmm.. I wouldn't know as I stopped using `projectDir`. But I will try out the dummy example in that issue when I get to my development machine
13:45:41disruptekit'll be helpful if you can find a bug with it; i'm starting to rely on it more and more.
13:51:59FromDiscord<Chiqqum_Ngbata> Yeah. I always hesitate to use things like this when I run into arbitrary terminology. # impatient
13:56:08*exelotl joined #nim
13:58:59*bacterio joined #nim
14:03:30*bacterio quit (Quit: bacterio)
14:07:56*bacterio joined #nim
14:07:56*bacterio quit (Changing host)
14:07:56*bacterio joined #nim
14:29:34disruptekhttps://nim-lang.org/docs/macros.html#getProjectPath -- this is returning a `src` subdirectory in a project, not the project path.
14:31:16FromGitter<kaushalmodi> disruptek: Heh.. coincidentally I recently documented that
14:32:54FromGitter<kaushalmodi> As I updated in issue 9467, we are missing something like `getGitRoot` because procs are those, I believe, would be more useful in config.nims
14:33:14disrupteki think my solution is also to roll my own.
14:34:12FromGitter<kaushalmodi> what's your "roll your own"?
14:34:20FromDiscord<Rika> make your own proc
14:34:27FromGitter<kaushalmodi> yes..
14:34:41FromGitter<kaushalmodi> I meant what's his "roll your own" proc defn?
14:37:13disruptekstart with getProjectPath and climb until i find a .nimble.
14:37:20disrupteki just wish i had globbing at compile-time.
14:37:34shashlickYou do
14:37:38FromGitter<kaushalmodi> I do the same.. but climb up till .git
14:38:10disrupteki do?
14:38:16FromGitter<kaushalmodi> may be we need a `getRootDir` proc in nims that accepts a string
14:38:34FromGitter<kaushalmodi> `getRootDir(".git")` , `getRootDir(".nimble")`
14:39:02disruptekit should be an enum; in theory, ExtSep could be != "." for... reasons.
14:39:05shashlickhttps://github.com/nimterop/nimterop/blob/master/nimterop/cimport.nim#L47
14:39:15shashlickPoor man's walk dir
14:39:42shashlickhttps://github.com/nimterop/nimterop/blob/master/nimterop/build.nim#L677 also works though
14:40:10*nsf quit (Quit: WeeChat 2.6)
14:40:12disruptekyeah, i already walkdir in here. i'm just lazy.
14:41:44shashlickAny more comments on the local deps proposal?
14:41:52shashlick@arnetheduck @mratsim
14:42:51disruptekisn't `nimble build` the same as `nimble install` in localdeps?
14:43:22shashlickYep
14:43:34disruptekinstall without options should probably install somewhere.
14:43:54shashlickGets confusing
14:44:03shashlickEven develop has that issue
14:44:10disruptekthere's no way to install otherwise.
14:44:18shashlickWhich is why I'm documenting to get some consensus
14:44:48shashlickDo you want to try and answer @dom96 question
14:45:42disruptekasked and answered. i mean, we have issues going back years on this thing.
14:50:31shashlickYa but people understand lock files a bit better now
14:51:23disruptekhonestly, the people that don't understand these problems are people that don't write software.
14:54:31shashlickYou're being too generous
14:54:52*uvegbot joined #nim
14:55:03shashlickPlus knowing a lot about everything too much to ask too
14:55:14shashlickI won't claim to know anything about package management
14:55:40disrupteki'm drawing a red circle on my calendar around "November 2nd, 2019". it isn't often i'm called "too generous." 🤣
14:56:18disruptekyou're just proving my point, though.
14:56:31disruptekif you write anything of any complexity, you run into these problems.
14:56:53FromDiscord<Rika> disruptek so you're in favor of lockfiles right>
14:57:03disruptekyep. and/or localdeps.
14:57:46disruptekthe fact is, there's information we find useful about testing our assumptions when developing software. that information should be shared, versioned, stored on disk.
14:58:24FromDiscord<Rika> what are the arguments against lockfiles though?
14:58:34disruptekit could be the deps themselves, it could be lockfiles, it could be package.json or package-lock.json or fubar.nimble or config.nims or nim.cfg or pretty much anything.
14:59:58disruptekthere's really no good reason not to record this stuff, control it, and measure it when attempting to help the user accomplish their goals.
15:00:09shashlickI think local deps is a development requirement
15:00:23shashlickWhereas lock files is a distribution requirement
15:00:29*theelous3_ quit (Ping timeout: 246 seconds)
15:00:30shashlickCannot mix the two
15:00:43disruptekthat's not true at all.
15:00:54shashlickOk please explain
15:01:01FromDiscord<Rika> hmmm?
15:01:24shashlickNote that npm has both as separate features
15:01:28FromDiscord<Rika> local deps is generally used for development (package version isolation between projects)
15:01:54disruptekyou use lockfiles in development all the time; you want to update a library and make sure your code works. you update the lib, you get some test errors, you modify your code, it works. now you version those lockfiles. now you can roll back to the previous version of deps and verify that your code still works -- because you have the old lockfiles.
15:02:10FromDiscord<Rika> lock files are used to ensure anyone who installs a certain version of a repo with a lockfile will have the same versions as the dev who first made and used the lockfile
15:02:18FromDiscord<Rika> no no no
15:02:35FromDiscord<Rika> lockfiles arent necessarily only for distribution, its just that usually they are
15:04:21shashlickLock files are the next logical step after providing per project isolation
15:04:34shashlickBut figuring out both for this requirement will get us nowhere
15:04:59shashlickWe just want to implement --save or whatever npm offers
15:11:53*ftsf quit (Ping timeout: 276 seconds)
15:12:13*clyybber joined #nim
15:12:18*jjido joined #nim
15:17:51skellocksystemctl poweroff
15:18:05disruptek😦
15:18:13skellockwoah... i almost brought down the internet. sorry.
15:18:24disruptekclose one.
15:18:40skellocki'm an untrained professional
15:22:09disruptekclyybber: not sure what you mean wrt pragmas; i would think we'd need a pragma to /not/ set defaults before we need one for defaults; or aren't you defaulting NeedsInit?
15:25:10*jjido quit (Quit: My MacBook has gone to sleep. ZZZzzz…)
15:26:01*sagax quit (Ping timeout: 268 seconds)
15:32:10*NicQ joined #nim
15:39:50clyybberdisruptek: Yeah thats basically what I meant
15:39:55clyybberits equitvalent
15:41:38*skellock quit (Ping timeout: 240 seconds)
15:41:41disruptekyeah, i don't see how defaults matter for non-NeedsInit; that should be safe. but NeedsInit probably needs to let the user choose how/where to alloc.
15:42:16disrupteklet them override it, i mean.
15:44:33clyybberok
15:44:35clyybberHmm
15:44:52clyybberthe way the compiler handles/allows discriminator values rn is really broken
15:45:15clyybberIt is not clear wether I am supposed to be able to use an int as a discriminator
15:45:31clyybberAnd I'm not sure what is intended anymore
15:46:22*nsf joined #nim
15:46:36disruptekseems like a fair question.
15:46:45clyybberBecause Araqs fix for https://github.com/nim-lang/Nim/issues/12379 doesn't acutally fix it for me, and their is some checking for the discriminators size in semobjconstr too
15:47:18disruptekprobably if you want int-like behavior you should use a range[int].
15:47:38disruptekthat would seem to be a suitable subset.
15:48:00disruptekbut maybe there's some reason you can't have the discriminator field be a range?
15:48:03clyybberrange[int16] I think
15:48:23disrupteki mean, as a developer, maybe you are somehow limited with your discriminator type.
15:48:29clyybberdisruptek: Araqs fix tries to disallow using types that have low(T) != 0
15:48:33clyybberas a discriminator
15:48:45disruptekwow, that seems like a mistake.
15:49:19clyybberYeah I don't like it either.
15:49:29clyybberAnd will remove it
15:49:35disrupteklol
15:50:25clyybberdisruptek: Can you check my snippet in the issue? Just to make sure its really not fixed.
15:50:37disruptekdo you have a link?
15:51:04clyybberhttps://github.com/nim-lang/Nim/issues/12379
15:52:03disruptekSEGV
15:54:00disruptekhttps://play.nim-lang.org/#ix=20C3
15:54:15clyybberdisruptek: Are you on devel?
15:54:41disruptekyeah.
15:54:55clyybberOk, thanks
15:55:19disruptekinteresting that it works in playground. what does it say for you?
15:55:29clyybberIt doesn't work in playground for me
15:55:35clyybbererrors in int128
15:55:50disruptekthat's better than a SEGV though.
15:55:50clyybberand with int32 as the discriminator it infinite loops
15:55:59disruptekfun.
15:56:07disruptekthat'll be useful this winter.
15:56:08clyybber#FUN#
15:56:16clyybberdisruptek: Haha
15:57:01disrupteki just did a `build_all.sh` and it's still SEGV for me.
15:57:20disruptekon HEAD.
15:58:24clyybberhmm
15:59:01clyybberweird. sadly the manual/spec isn't very specific on what is supposed to be supported as a discriminator
16:01:22disrupteki just wonder if narrowing the spec is going to get in the way of some use-case.
16:01:39clyybberyeah
16:02:57clyybberand interestingly my snippet works when you remove the field assignment at the end
16:07:31disruptekthat's even worse.
16:08:46disruptekwait, that /should/ work if you remove the assignment.
16:09:46clyybberumm
16:09:48clyybberyeah
16:10:23clyybberbut you can also change it to a valid assignment
16:10:27clyybberand it will still crash
16:12:41clyybberseems like the compiler tries to prove something
16:12:47clyybberand fails miserably
16:13:29clyybberoh
16:13:38clyybberit just tries to compute alignment or size
16:13:40clyybberand fails
16:13:42clyybberha
16:14:55*theelous3 joined #nim
16:15:45clyybberping Araq, krux02
16:15:46disruptekbut that means we support 128bit ints for discriminator.
16:16:23clyybberhaha, I don't think so. The generated runtime checks for field assignments
16:16:45clyybberonly work for int16 or less
16:16:54clyybberI think
16:17:10disruptekworks for int64.
16:17:32disruptekon playground, at least.
16:18:10clyybberhuh, try with one branch having high(int64)
16:18:43clyybberanyways I think that could also just mean that the checks fail to detect invalid assigns
16:19:26disruptekneed to add some tests to the compiler for this stuff.
16:20:41*jjido joined #nim
16:21:08clyybber@mratsim: Huh do booleans not work as discriminators for you?
16:21:15clyybberdisruptek: Yeah definitely
16:21:31FromDiscord<mratsim> in your issue you said to only allow enums
16:21:37clyybberbool is an enum
16:21:47FromDiscord<mratsim> ah so you mean ordinal?
16:21:50clyybberbut yeah I was wrong anyway in that PR
16:22:05clyybbermratsim: We should allow as much as possible :P
16:22:21FromDiscord<yewpad> good evening guys. hope you're having an awesome day so far
16:22:36FromDiscord<mratsim> hello yewpad
16:22:37clyybberBut I'm not sure wether types with a length >= 32 are supposed to be supported
16:22:45clyybberyewpad: Good dat
16:22:49clyybberday
16:23:24FromDiscord<mratsim> you probably mean sizeof(T) > 2 bytes (i.e. bigger than int16)
16:23:29clyybberyeah
16:23:43FromDiscord<mratsim> no they are not supported in case statement anyway
16:23:46FromDiscord<yewpad> I'm planing on writing a huge server orchestration software for Minecraft servers in Nim. Any tips, anything to watch out for?
16:24:08clyybbermratsim: Interesting, so basically the checks were completely bogus till now.
16:25:27clyybberHmm, maybe there is more to it.
16:28:16clyybberHa
16:29:05clyybberIt's not supposed to be supported
16:29:14clyybberI'm pretty sure
16:30:43disruptekyewpad: hard to answer questions that lack specificity.
16:30:47clyybberah
16:30:50clyybberit is supported
16:35:44clyybberbut only for constant discriminators.
16:36:05clyybberor not?
16:36:15clyybberwth, I can't tell anymore
16:36:53disruptekstart with adding some tests of stuff you think should work. see when they start failing.
16:37:03FromDiscord<mratsim> @yewpad iirc def- uses Nim to manage teeworld servers but I may be wrong
16:37:06disruptekwe have no idea what the spec is anymore.
16:37:22disruptekneed to see what people are using in any event.
16:37:48def-well, we do have some scripts in Nim, but also others in Python
16:37:55FromDiscord<mratsim> See: https://hookrace.net/blog/what-is-hookrace/
16:38:07FromDiscord<mratsim> oh, the master is there :p
16:38:08clyybberdisruptek: The thing that tops it that it is not supported for ranges even when when the branch can be determined at compile time
16:38:23def-@mratsim You pinged me :D
16:40:21FromDiscord<mratsim> that doesn't mean you are always on 😉
16:41:42FromDiscord<mratsim> Well I'm not that attached to case objects with bool @Clyybber, I wanted to use them for lazy creation of stuff (cryptographic object for Status and lazy channel creation for Picasso)
16:41:56clyybberThey should definitely work
16:42:00FromDiscord<mratsim> but it's not really an issue to create an enum with 2 state
16:42:13clyybbermratsim: bool IS an enum with 2 states
16:42:22clyybberand it works
16:42:43FromDiscord<mratsim> bool is a type, and enum is another ;). Whoever told you otherwise is a javascript or Php developer
16:42:49clyybbermratsim: My problem with the current compiler is what happens for size(T) > 2
16:43:12FromDiscord<mratsim> I think it's safe to throw a compile-time error on that
16:43:23FromDiscord<mratsim> at the enum definition level
16:43:32FromDiscord<mratsim> because you can't do a case statement on those anyway
16:43:41clyybbermratsim: https://github.com/nim-lang/Nim/blob/devel/lib/system.nim#L43
16:43:56FromDiscord<mratsim> I'm not to sure how the compiler special cases case branches with range of ints though
16:44:07clyybbermratsim: I am, and its bogus
16:44:21FromDiscord<mratsim> oh, you right it's an enum, magic
16:44:38FromDiscord<mratsim> I never knew :p
16:44:55clyybberThese are my concerns rn:
16:44:58clyybber only supported for compile time discriminator values
16:45:01clyybber ? BUT why the fuck not for ranges that are specific enough to specify the branch at compile time
16:45:03clyybber ? Why the fuck does this mess up sizealign?
16:45:05clyybber ? Why the fuck does araqs fix disallow low(T) != 0
16:45:07clyybbersorry for the language
16:45:35FromDiscord<mratsim> I think you should probably take a walk 😉
16:45:38clyybberthey are all conerns for discriminator types with size > 2 bytes
16:46:27FromDiscord<mratsim> anyway, it's good to see more people working on the low-level internal and magic of the Nim compiler
16:47:01clyybberNot good for the people though :p
17:02:03*adeohluwa joined #nim
17:06:51Zevvvoodoo, black magic, witchwork, wizardry and sorcery
17:07:10disrupteknow you're talkin' my language.
17:07:58clyybberblaka smoko
17:08:27Zevvshamans and necromancers
17:13:50lqdev[m]shashlick: any progress on `nim check` performance problems with nimterop?
17:22:53shashlicknot yet @lqdev
17:23:04shashlickdo you still see it with devel?
17:23:56shashlickreplied to some of the comments on https://gist.github.com/genotrance/ee2ce321a56c95df2d4bb7ce4bd6b5ab
17:24:14shashlick@disruptek - i didn't reply to your second comment since we discussed it and I made relevant updates to the gist
17:24:25*adeohluwa quit (Ping timeout: 268 seconds)
17:24:30*clyybber quit (Quit: WeeChat 2.6)
17:24:43shashlickbut please everyone review the gist and provide your insights
17:25:13disruptekthis needs to reach a wider audience than irc.
17:26:28*clyybber joined #nim
17:27:28clyybbercrash playground..
17:28:13clyybberhttps://play.nim-lang.org/#ix=20Cz
17:28:30clyybberdisruptek: its getting fun
17:28:57disruptekoh c'mon
17:29:20FromDiscord<Rika> `--nimbleDir:xxx overrides all the following behaviors` instead of this maybe something simpler like `--no-local` or something, then the current behavior would be used
17:29:54FromDiscord<Rika> (unless nimbleDir isnt currently provided by default, in which case ignore this)
17:30:26clyybberdisruptek: and its gcc that infi-loops
17:30:35disruptekwow, gcc bugs.
17:30:41disruptekyeah.
17:31:23*clyybber quit (Quit: WeeChat 2.6)
17:31:51disruptekc=2 fails the same.
17:32:00*clyybber joined #nim
17:32:06disruptekc=2 fails the same.
17:32:07clyybberHahahaha, it hung up my pc
17:33:31clyybberor at least made it really s l o w
17:34:25disrupteki only have one known wedge on my machine, but it's a bad one.
17:34:49clyybberdamn, I can borrow you some fried eggs if you want?
17:34:56disrupteksometimes if i ctrl-d exit out of a terminal too quickly, it hangs my compositor. the only reasonable fix is to ssh in and reboot.
17:35:22clyybberhaha, wayland?
17:35:25disruptekyeah.
17:35:32clyybberhave you reported it?
17:35:39disruptekto whom?
17:35:46clyybberwlroots?
17:35:54clyybberyou use sway right?
17:36:12disrupteki can't narrow it down. could be sway, could be wayland, could be mesa conceivably.
17:36:39clyybberdisruptek: rely on it, build your scripts around it, make a ruckus when its fixed
17:36:46disrupteklol
17:37:03disruptekthe best way to change behavior of software is to rely upon its consistency.
17:37:04clyybberadapt your workflow kids
17:37:19shashlick@Rika - nimbleDir is existing behavior
17:37:21clyybberdisruptek: that is a sentence worth archiving
17:37:48FromDiscord<Rika> hmm so it's best to just use existing behavior
17:37:49FromDiscord<Rika> okay
17:37:54shashlick@disruptek I've posted on the github issue, I'll make a forum post as well
17:38:44*sagax joined #nim
17:39:50*natrys quit (Ping timeout: 268 seconds)
17:40:58*natrys joined #nim
17:45:54*NicQ quit (Read error: Connection reset by peer)
17:46:27*NicQ joined #nim
17:47:04*clyybber quit (Quit: WeeChat 2.6)
17:50:56*NicQ quit (Ping timeout: 268 seconds)
17:54:50*sedfox quit (Ping timeout: 240 seconds)
17:55:25FromDiscord<arnetheduck> shashlick, local deps issue? (haven't been following chat for a few days)
17:55:45shashlickYes @arnetheduck
17:55:52shashlickPlease see the gist
17:57:18*nif_ quit (Quit: ...)
17:57:28*nif joined #nim
17:57:57FromDiscord<arnetheduck> oh, well, in general I think it's a travesty that nimble ever looks outside of the local project folder (and nim std lib) without explicitly being told to do so. I'd switch it to local and deal with the fallout (either by printing a warning or whatever) - in theory it should be an almost pain-free upgrade, you just run nimble build or whatever and it sets up the deps locally and you're done
17:58:22lqdev[m]shashlick: the performance issue persists, nim check still takes ~4s to complete
17:59:21FromDiscord<arnetheduck> if I have two side-by-side checkouts, there should be absolutely no leakage of information between them
17:59:41disruptekarnetheduck: i share your position, but we seem to be in the minority.
18:03:22FromDiscord<arnetheduck> well, I can't put it any more gently than that either - I mean, the world learned that globals of most kinds are a bad idea - in your code, in your software repo, etc etc - inevitably it fails whenever you create your second checkout or need two things side by side.. guiding users towards this shitty developer experience by defaulting to global is just bad - it's like encouraging users to use globals in code without educating them on th
18:05:16shashlickWe are getting there
18:05:32shashlickSee my last comment about a --user flag to break out
18:05:51shashlickI'm yet to incorporate it into the proposal
18:08:52shashlickAny feedback on behaviors
18:12:02FromDiscord<arnetheduck> yeah, --user to break out is fine, or --global to install to /usr/whatever.. lock files btw are a way to deal with all this, if they're properly implemented.. there are a few other things as well, I want to be able to locally override a dep to a development version I have checked out somewhere (`nimble develop` or whatever it's called) etc.. there's a whole bunch of features that follow, but this is a fundamental issue - you can only so
18:13:02disrupteki have no idea what `isRootDir` does. anyone?
18:15:28disruptekmr. duck, add some newlines. irc folks are only getting half your comments.
18:15:31FromDiscord<arnetheduck> generally, I also have a gut feeling lock files solve most of the issues that your gist and deps thing aims to solve, except mainaining a local copy inside deps (ie vendoring).. generally that's not what I want
18:16:05FromDiscord<arnetheduck> ie generally, I don't want source files from other projects to be checked into my own repo
18:16:23disruptekthat's my shitty-code example.
18:16:33FromDiscord<arnetheduck> there are use cases for that, but that can be an addon to lock files
18:17:19disrupteksometimes you have to deal with orphaned code that way, too.
18:25:46FromDiscord<arnetheduck> yeah, but most of the time I don't - ie imagine a dep on boost in c++ - I don't want a copy of that stuff in my repo
18:28:52disruptekthat's a case where you'll manually point to it with a --path: statement.
18:29:43FromDiscord<arnetheduck> well, no - I'll have a lock file checked in, so that it can be resolved deterministically - if I need vendoring, I'll run a proxy or potentially have special magic commands that work off the lock files to take a local copy
18:30:33disruptekhow fun for you.
18:30:54FromDiscord<Rika> sounds like the "DONT PUSH NODE_MODULES" thing again
18:31:08FromDiscord<Rika> basically: just dont push the deps folder i guess?
18:31:43FromDiscord<arnetheduck> rika, how will you know what's in my deps folder if I hand you some code? the point is to ensure that if I can build the project, so can you
18:31:58FromDiscord<Rika> isnt that the point of the lockfile
18:32:17FromDiscord<Rika> wait, lemme guess: the proposal doesnt indicate a lockfile
18:33:12FromDiscord<arnetheduck> yeah, but once you have a lock file, it doesn't matter where the deps live - they can even be in a (global) cache - semantically, the deps behave as if they were in a deps folder
18:33:49FromDiscord<Rika> hmm good points
18:33:58FromDiscord<Rika> i just want a lock file tbh ;;
18:34:04FromDiscord<Rika> i dont mind either global or local
18:34:39FromDiscord<arnetheduck> there's a few other things as well: I want to have multiple projects per git repo, and be able to specify deps in a relative way (so the commit is atomic across libraries)
18:34:49FromDiscord<arnetheduck> deps folder makes that awkward
18:36:34FromDiscord<arnetheduck> I want to codevelop two things that live in separate repos: I have them checked out side-by-side and want to (locally) say/override: use my checked-out version - also tricky with deps (a symlink in deps perhaps, but...)
18:38:36FromDiscord<arnetheduck> vendoring is more of a distribution thing: the behind-the-firewall use case, or "I want a local copy of the deps in case they get pulled" - doesn't necessarily mean that a local copy in my own git repo is the smoothest option (that's git's responsibility, to copy repos of code, no need for nimble to implement it poorly also)
18:44:37*sedfox joined #nim
18:49:38*natrys quit (Ping timeout: 276 seconds)
18:54:30federico3https://circleci.com/gh/FedericoCeratto/nim-package-directory/128 is anyone running into this error with circleci?
18:55:17*sedfox quit (Ping timeout: 240 seconds)
19:02:32*sedfox joined #nim
19:08:24*sedfox quit (Ping timeout: 265 seconds)
19:20:23*GordonBGood joined #nim
19:20:31*sedfox joined #nim
19:33:06*Skaruts joined #nim
19:35:40Skarutshey guys, I noticed an issue with physics (and seen some other people noticing too), but I don't know if this is a bug or if it's just people doing something wrong
19:36:07Skarutshmm, does IRC support posting images?
19:37:17*thomasross quit (Quit: Leaving)
19:37:28lqdev[m]Skaruts: no, you have to use a hosting service like imgur
19:37:37*thomasross joined #nim
19:37:53Skarutsok then 1 sec... I have a gif of the problem
19:39:56Skarutshttps://i.imgur.com/R9saNLX.mp4
19:40:32Skarutsin the gif I'm walking against a StaticBody, and instead of just stopping, I get this jittering
19:41:11Skarutsthat doesn't happen everywhere, just on some places, but I couldn't perceive a pattern
19:42:01SkarutsI implemeted several FPS controllers from following several tutorials, and this happens with all of them
19:42:32GordonBGoodTo all: I'm new here and Araq has me looking at a couple of newish things like seqsv2 and reference counting that require more knowledge of "compiler magic"...
19:42:49SkarutsOH
19:42:53Skarutswait a minute
19:43:05GordonBGoodI don't know who's who: Other than Araq, who actually works on the compiler magic?
19:43:06SkarutsI'M ON THE WRONG IRC
19:43:14Skarutslol sorry guys
19:43:19Skarutsfacepalm
19:43:27solitudesfhappens to the best of us
19:43:54Skarutsbest way to tell when you seriously need some sleep...
19:44:17Skarutswell, see ya, then, sorry lol
19:44:28*Skaruts left #nim (#nim)
19:45:56GordonBGoodGiven that it's the weekend, it may not be the bast day to find ppl on here?
19:53:08disruptekGordonBGood: clyybber and krux02 get their hands dirty in the compiler.
19:55:49GordonBGooddisruptek: thanks, I have gathered that krux02 is the VM specialist but maybe also the rest of the "magic"?
19:56:19disruptekthe thing about magic is that it is opaque to all but the practitioner, so i really have no idea.
19:56:41GordonBGoodI've chatted with clyybber, but not about "work", will have to extend the relationship, I think
19:57:10GordonBGood(vent), yes, the new "spagetti code" is conditional compilation, I'm afraid
19:59:32GordonBGoodJust re-read the compiler internal's document: "the Nim compiler itself; note that this code has been translated from a bootstrapping version written in Pascal, so the code is not a poster child of good Nim code"
20:00:39*Sembei joined #nim
20:01:16GordonBGoodOne can read it and understand it by some skipping to and fro, but to actually change or debug something is intense
20:03:25*codeasone left #nim (#nim)
20:11:34*Sembei quit (Quit: WeeChat 2.6)
20:13:23GordonBGooddisruptek: do you never sleep? You seem to be here no matter what time of day or night I check in
20:13:42disrupteki'm a loser. it is known.
20:14:21GordonBGoodWelll, I assumed you were "different"; not necessarily a bad thing
20:14:57disruptek"touched", you mean?
20:15:43GordonBGoodNah, don't want to jump to any conclusions: I see you are quite helpful through
20:16:00GordonBGoodCan answer quite a few Nim question
20:16:22GordonBGoodDo you have a specific developement area?
20:16:27disrupteki don't know much, but i like guessing.
20:16:58GordonBGoodYou seem to make quite accurate guesses
20:17:13disruptekhttps://github.com/disruptek -- a pretty good birds-eye view.
20:19:08GordonBGoodThanks, been in Nim for a while, I see
20:19:43disruptekyeah, i think about 6 months or so.
20:19:52GordonBGoodI've jumped languages quite a bit, now trying to settle in Nim dev for the long haul
20:20:07disruptekit's pretty tough to beat. what other paradigms do you code in?
20:20:54disruptekkaushalmodi: pushed a new bump that has a recursive project .nimble finder you can use to get the repo path; works at compile-time.
20:21:15GordonBGoodFor the last several years, mostly FP - F#/Fable, Haskell, Elm, with many other stops, investigations along the way
20:21:34disrupteknice. i wanna learn clojure next.
20:22:36disrupteki see us running nim in lvm and having lisp in the same vm would be amazing.
20:22:43disrupteker, jvm
20:22:59GordonBGoodHave helped with a GraphicsSVG repo for Elm, several web pages/SPA using Elm and Fable, got involved with Eta which is a port of Haskell to run on JVM
20:23:15disruptekneat, i don't know eta.
20:24:14disrupteklooks pretty cool.
20:24:50GordonBGoodReally nice guy (couple actually) run the show, and I would really like them to succeed, but kind of dropped out of their dev team because it is going to be a hard sell to go anywhere; only FP nerds will choose Haskell-like programming
20:25:05GordonBGoodFound the repo?
20:25:29GordonBGoodThe chief there really knows his JVM and Java!
20:25:32disruptekthat's why i'm out on haskell. i think it's just too big a hill to climb for library support.
20:26:27disrupteki think it's a sexy language, just going to be slow going.
20:26:52GordonBGoodI've actually chatted with SPJ of GHC and he invited me to contribute, but "compiler magic" was just a bit beyond me at the time - so now I'm trying to get my head around Nim "compiler magic"
20:27:32GordonBGoodHaskell/Eta is very satisfying to get something working
20:27:50GordonBGoodIt's pretty hard to write really ugly code in Haskell
20:28:02disruptekright, that's what i like about it.
20:28:12disrupteki'm a very aesthetic-oriented programmer.
20:28:59GordonBGoodIt's what I despair a bit about Nim: while the external syntax is a thing of beauty, it seems the internal implementation is not so much
20:29:55disrupteki sometimes think i'd like to /heavily/ comment nim and/or the stdlib, but i don't know if it'd go over very well.
20:29:58GordonBGoodYeah, me too - if the final code doesn't look beautiful to me, I'm never really satisfied, even if it works
20:30:56GordonBGoodAh, Araq seems to be more mellow these days - I think that'w why he invited me here: a fresh look at things
20:31:54disruptekyeah, i think he's pretty relaxed, all things considered.
20:32:03disruptekmust be all the running.
20:32:10GordonBGoodElm language is a beautiful simple language that can be used to teach programming to 12-year-olds (using the mentioned graphics package), but I think perhaps overly restrictive for general use
20:32:46disruptekthis was a good article: https://elm-lang.org/news/the-syntax-cliff
20:33:18GordonBGoodthe owner, Evan, doesn't accapt anyone touching "his" compiler code, which means that new releases take years
20:34:00GordonBGoodYes, he's opinionated, but I agree with most of his opinions
20:34:41disruptekit's nice when those line up. 😆
20:35:29GordonBGoodThere was also a recent article I'm to lazy to look up about the Norwegian transport company that converted their whole website of 83,000 lines of Elm code and are very satisfied; that is even more real world
20:35:52disruptekyikes.
20:36:00disruptekthat seems like a huge amount of elm.
20:36:48GordonBGoodThe only two criticisms by that company were lack of type classes and function overloading, but they ended up kind of justifying even those
20:37:44GordonBGoodIIRC, now up to 15 programmers, something like two or three years; they started gradually with just a small part and as things worked out went with the whole thing
20:37:46disruptek"NoRedInk switched to Elm about two years ago, and 250k+ lines later, they still have not had to scramble to fix a confusing runtime exception in production."
20:38:55GordonBGoodWell, unlike what they say, it IS possible to have runtime exceptions in Elm, but they are likely right that they are likely not "confusing" as in not difficult to find
20:39:13GordonBGoodThe Elm compiler is written in Haskell
20:39:55disrupteki just... don't know how to justify that quantity of such a language.
20:40:31disruptekif i'm gonna write something big, i want something pretty muscular.
20:41:28GordonBGoodWell, JS output can be pretty muscular these days, JS engines can produce code that is about the same speed as any VM
20:42:07GordonBGoodAnd WPA's and SPA's are getting to be the rage when they can be used: trivial installation without a "store"
20:44:10GordonBGoodMy main quibble with Elm and why I would likely choose Fable/F# for such an application is that immutable is strictly enforced even more than Haskell, where one can wrap mutation in monads and drop to primitive ops where necessary
20:44:16disruptektrying to decide if i would write something big in nim right now.
20:45:24disruptekprobably not.
20:45:46GordonBGoodIf one wants mutation for graphics or math power, one has to communicate with JS, and Evan/Elm strictly controls that; to the point that a memoizing lazy list is impossible to use
20:46:35disruptekwhich kinda defeats a lot of the appeal of such a platform.
20:47:25GordonBGoodI wouldn't be afraid to write something fairly big in Nim other than if it needed multi-threading except that, in spite of version 1.0; I don't know how it is going to stay "stable" with all the proposals and fixes that are actaully required
20:48:54GordonBGoodIf you are talking about Elm; yes, I would choose F#/Elm for something big, but I guess the needs of the Norway company didn't extend beyond what Elm supports
20:49:20disrupteki haven't written enough, but i don't think the story on larger apps is all that clear.
20:50:04disruptekthere are some fairly large holes, too.
20:50:18*GordonBGood quit (Read error: Connection reset by peer)
20:51:33*GordonBGood joined #nim
20:51:58GordonBGoodNah, me either, I get bored with one-man large apps and won't join something big at tis stage
20:53:12GordonBGoodJoining a group such as this is likely a good space for my "talents" or lack of them
20:54:21GordonBGoodI sometimes feel a bit out classed by you younger CS types, but I somehow seem to manage to get up to speed - the fun is in the challenge
20:54:45FromGitter<alehander42> age is good
20:54:59disrupteknim has good bones. there's a lot to contribute, even if it's just to test stuff. it sometimes feels like there are so few people using this thing that misbehavior goes undetected for too long.
20:55:35GordonBGoodYes, I can really contribute in more extensive tests if nothing else
20:55:54GordonBGoodalehandler: well, hello, OAP
20:56:10FromGitter<alehander42> i am slightly interested in fuzzing lately
20:56:19disrupteki'm a mechanic; never went to school for cs.
20:56:24FromGitter<alehander42> but i've heard people say nim gets enough actual bugs currently
20:56:38GordonBGoodfuzzing? ah fizzbuzz
20:56:38disruptekthat's the case for almost anything you might want to fuzz.
20:56:50FromGitter<alehander42> hello gordon
20:57:08FromGitter<alehander42> well, no, like randomly generated tests property tests etc
20:57:18FromGitter<alehander42> i am also without finished cs ed
20:57:57disruptekthey asked you not to come back, huh?
20:58:27FromGitter<alehander42> well, i just dropped out
20:58:33FromGitter<alehander42> without realizing i am dropping out
20:58:39FromGitter<alehander42> i found out years later
20:58:46GordonBGoodI grew up in the age of main frames, which when I actually got access to one I found exhilerating, but didn't want to join the big orgs that a CS degree seemed to require at that tiime
20:58:50FromGitter<alehander42> that my "next year" thing is not likely
20:59:06disruptekahh.
20:59:32FromGitter<alehander42> ive watched a video about some kid which got a mainframe
20:59:38FromGitter<alehander42> in his basement
20:59:40FromGitter<alehander42> fun stuff
21:00:02GordonBGoodSo I'm an electrical engineer, but became a "systems engineer" mixing cross disciplines including programming
21:00:13FromGitter<alehander42> i like the simplicity of the "older" computing: the "we can just write a new os in a month and see what happens" thing
21:01:00GordonBGoodMy carreer has spanned the life and death of DEC and the "beginning" of the Intell 4004, if you know what that was
21:01:13FromGitter<alehander42> electrical engineers are cool: you're one of those people that can play with a circuit board
21:01:19GordonBGood^career
21:01:38FromGitter<alehander42> i would be impressed if you had a carrier
21:01:46FromGitter<alehander42> i dont
21:01:54GordonBGoodYeah, we used to design circuit boards and pump out a prototype in a couple of days
21:02:55disruptekwhat did you think of tracey kidder's book?
21:04:42*luis__ joined #nim
21:06:37GordonBGoodThe Soul of a New Machine? That was happening while I was still in uni, mostly. My career has revolved entirely around what we used to call microprocessors, now just all CPU's and SOC's
21:07:57GordonBGoodActually was happening just after I was in uni when mini computer manugacturers through they still had a significant "niche"
21:07:57disruptekyeah, just curious how it struck you since you were a little less removed from that era.
21:08:14GordonBGoodI was allready working along the lines of what we have now
21:08:28disrupteki see.
21:09:23disruptekthat hardware isn't uncommon on ebay but it's pretty hard to get it working if you don't have parts reserves and experience and even, in some cases, licenses.
21:10:54GordonBGoodThat whole minicomputer culture described in the book was real, but I've never workied within the confines of a large organization as described because "nicro" allowed smaller groups to compete
21:11:26disruptekright; makes sense.
21:12:11disruptekit's been such an amazing growth story. hard to really convey to younger folks what a shift it has been.
21:13:00GordonBGoodI once had an employee who bought an old IBM line printer that was being sold for scrap for the novelty that it contained a one farad capacitor
21:13:14GordonBGoodYeah, what a shift
21:13:41GordonBGoodIn uni, the research dept thought they were leading edge using DEC minis
21:14:26GordonBGoodThe line printer could only be moved with a crane, something like a half ton to a ton
21:14:27disruptekdoesn't matter what it is, it's immediately obsolete.
21:15:22GordonBGoodHe asked if he though I could get it working with his original IBM PC - I replied that if the think still worked, of course I could build an interface, but what would be the point?
21:15:55*luis__ quit (Quit: luis__)
21:16:01GordonBGoodThe same would apply to getting ebay DEC's working - what's the point other than for a museum?
21:16:10disrupteki'm sure it had some simple serial interface, but yeah.
21:16:17disruptekeven the museums don't want this stuff.
21:16:29disruptekyou go to bletchley park and it's just rooms full of junk.
21:16:52disrupteki'm not including colossus in that statement, but you know...
21:17:03GordonBGoodAnd who other than OAP's like me would even know what it once was
21:17:09disrupteksame with the computer museum in CA.
21:17:11*luis__ joined #nim
21:17:28*Trustable quit (Remote host closed the connection)
21:17:42disrupteka friend wanted to donate a hardware turing computer. i couldn't give it away.
21:17:49*narimiran quit (Remote host closed the connection)
21:18:17disruptekmechanical, i mean.
21:18:35disrupteki think it's at the ford museum now.
21:18:53GordonBGoodI think the line printer interface was parallel, serial was pretty slow in those days
21:19:35disruptekhttps://www.thehenryford.org/collections-and-research/digital-collections/artifact/449880
21:19:47GordonBGoodSomething one of a kind might appeal to some
21:20:02disrupteki doubt it was parallel.
21:21:48disrupteki mean, look at that thing.
21:21:55GordonBGoodYeah, I looked at the spec's but it was too long ago to remember
21:23:19GordonBGoodYeah, look at it, but at least it doesn't weigh a ton and take a whole room to store
21:24:07disrupteki saw eniac at upenn when i was a kid; ridiculous.
21:24:35GordonBGoodRediculous to us now; not to them at the time
21:24:46disrupteki guess it's open to the public now, but it was a big deal to get to see it then.
21:24:57*jjido quit (Quit: Textual IRC Client: www.textualapp.com)
21:25:15GordonBGoodNot still operable, surely?
21:26:08disruptekno, but i guess it mattered to some political nutjob at penn.
21:26:34GordonBGoodAh...
21:27:13disrupteka friend worked with eckert, so was able to gimme a tour.
21:27:28GordonBGoodNeat...
21:27:44disruptekyeah, this is the guy that invented mercury memory.
21:28:30GordonBGoodI've forgetten about mercury memory if I ever knew it...
21:28:42disruptekyou didn't miss anything.
21:29:01disruptekhttps://en.wikipedia.org/wiki/Delay_line_memory
21:31:52GordonBGoodMy first knowledge of volatile memory was TTL memory boards for DEC at somethhing like $10,000 for four kilobytes and the Intel 4004 "kit" which came with a 32 word memory chip worth probably something like $10
21:33:30disruptekyeah, i remember that stuff. someone'd have a plastic tube of chips and it was like seeing a bag of cocaine.
21:33:35GordonBGoodWow, who would have though they could even make such a thing work reliably enough
21:33:45disrupteki know, it's nuts.
21:34:45disrupteki mean, your memory ran faster or slower depending on ambient temperature ffs.
21:35:09GordonBGoodAnyway, it's nice chatting for a change, but it is delaying getting to looking into the --gc:destructors bug to do with seq memory leaks
21:35:34disrupteki don't want to hold you from that important work. 😄
21:35:55GordonBGoodSo I should really get back to that, but on the other hand, maybe not - it's my bd
21:36:47disruptekah, then you must enjoy yourself. go fix some bugs. 😁
21:36:58GordonBGoodI'm driven to see what a Nim with an alternate MM system to GC will work like
21:38:51GordonBGoodGC, as in Boehm, works ok, but everybody turns to GC, as a potential systems language, I'd like to see Nim have something else, at least as a solid option
21:39:06GordonBGoodThat isn't manual MM
21:39:30disruptekit's definitely a killer app.
21:39:47GordonBGoodYeah, I hope so
21:40:23GordonBGoodAnyway, bye for now, thanks for the tips on who's sho and the chat
21:40:34disrupteksure thing, have a good one.
21:43:18*nsf quit (Quit: WeeChat 2.6)
21:44:50*GordonBGood quit (Ping timeout: 240 seconds)
21:47:57*skellock joined #nim
21:49:39shashlick@arnetheduck sorry was away
21:50:02shashlickWhy are you linking local deps with vendoring? That's not the goal
21:50:09shashlickThe goal is isolation during dev
21:50:32shashlickAnd to get to a good lock file you need to get the deps in a working condition
21:50:42shashlickLocal deps give you isolation
21:51:00shashlickThen you can create your lock file and then your users can install it however
21:51:09shashlickThis is step 1
21:51:54shashlickIf someone wants to check in their deps folder, that's their choice but it has nothing to do with distribution as noted in the gist
21:58:09*skellock quit (Quit: WeeChat 2.6)
22:07:04*luis__ quit (Remote host closed the connection)
22:16:58federico3can i run startProcess without capturing the stdout?
22:17:15disruptekyep.
22:17:37disruptekyou can send it to parent streams or just hope you don't have too much output, i guess.
22:19:16federico3poParentStream
22:19:20disruptekyeah.
22:19:27federico3the doc is the opposite of intuitive :D
22:19:46disruptekit's not brilliant, no. 😆
22:20:12disruptekalso remember to catch the exit signal fd if you're doing that.
22:20:17federico3I feel like we need a flowchart
22:20:48ZevvI feel like the execprocess and friends could do with some major rework. I started some of that some time ago but abanoned because
22:20:54federico3yes
22:21:15Zevveven the compiler itself suffers from its flaws
22:21:48Zevvsorry, "flaws" is too negative, just from "the way it is implemented now"
22:22:28disruptekmaybe i'll fork it for when i impl nim-expect. 😛
22:22:43ZevvI know how to do a lot of this stuff properly on linux/posixy, but the windows parts elude me
22:22:52disruptekyou're nominated.
22:23:00Zevvi need a friend
22:23:05FromGitter<alehander42> i almost started my mini os kernel toy
22:23:14Zevvto help me with the windows implementation
22:23:28Zevvno, you should almost *finish* it instead :)
22:23:30FromGitter<alehander42> i am at the point where i am trying to get var context = Context() to not crash
22:23:35disrupteki'm not friends with anyone who runs windows.
22:23:44Zevvsame here. true story.
22:23:56FromGitter<alehander42> so can i get `-d:useMalloc` only with --newruntime ?
22:24:30FromGitter<alehander42> i love water
22:24:37FromGitter<alehander42> ah thats what thirst does
22:24:43skrylar[m]@eacyy it gets vomited as a bunch of separate chat lines via the irc bot
22:24:55ZevvI'm not sure. i needed something similar a few months ago but i didnt know about :usemalloc, so I added an os to the nim compiler with very basic mallocs
22:25:03Zevvprobably not the way t ogo, but it worked for me
22:26:02Zevvthat did work out quite well in the end with newruntime though
22:31:01AraqZevv, we tried to fix osproc's bugs but they are nasty. I happen to like the API but surely it could be improved.
22:31:32Zevva good api is though here
22:31:45Zevvas everywhere
22:31:50FromGitter<alehander42> hm, so malloc + free should be enough for newruntime -d:useMalloc bare metal
22:31:58FromGitter<alehander42> right
22:33:18Zevvalehander42: my problem was that nim does its own management of memory chuks as a workaround for inefficient malloc implementations, so it always starts with allocing in pretty large chunks. not sure if that logic is above or below :usemalloc
22:33:55Zevvsomething is always allocing 512kb, iirc
22:34:51disruptekstory of my life.
22:35:13FromGitter<alehander42> yeah but it seems newrutime -d:usemalloc just calls malloc in nimNewObj
22:35:21FromGitter<alehander42> otherwise i also saw the thing you describe
22:35:33Zevvso, i missed something obvious there :)
22:36:02Araqthere is now also --gc:destructors -d:useMalloc so that you can use all of Nim, no 'owned' annotation. but it's WIP
22:36:55Zevvso its ready enough to try? sweet will do that!
22:37:34Zevvthe community (or at least 1 member) is pretty confused about availble memory management models and their state these days :)
22:37:48AraqI know, it's being sorted out
22:38:12Zevvwhich is actually pretty cool, as it shows the language is so flexible that all these experiments just fit in the languge implementation
22:38:40Araqthe plan is that in the end 2 options remain: --gc:destructors and --gc:boehm, one for latency and embedded or really big heaps, the other for throughput
22:39:30Araqbut support a custom destructors and a shared heap.
22:39:37Zevvso newruntime was valuable as a learning experiment but will die?
22:40:14AraqI might use the 'owned' annotation for further optimizations
22:41:09ZevvI never managed to ownedize some of my code, ran around in circles but couldnt get the compiler happy. just as with the json lib. I guess its intrinsincially hard with some models
22:41:38Araqand rayman22201's research projecct is whether 'async' can work with --newruntime
22:41:52Zevvyeah, he never asked for that :)
22:42:11Zevvhe just kind of ran into it I believe
22:42:29Araqwell we discussed it
22:42:53Zevvah ok didnt know that, good job rayman22201!
22:43:14FromGitter<alehander42> araq hm i can try it
22:43:21Araqjson.nim should be easy to port to 'owned' once you annotated the collection libraries too
22:43:23FromGitter<alehander42> what does --gc:destructors do
22:43:40FromGitter<alehander42> hm, this worded until now, my next error is for var a = "ls"
22:43:47FromGitter<alehander42> error: dereferencing pointer to incomplete type 'AllocatorObj' {aka 'struct AllocatorObj'} ⏎ (*dest).p->allocator->dealloc((*dest).p->allocator, (*dest).p, (*dest).p->cap + 1 + sizeof(NI) + sizeof(void*)); }
22:43:51FromGitter<alehander42> cool
22:44:37Zevvcmon thats soooo obvious, its there in the error message
22:45:04Araqalehander42: no idea where this bug comes from, but can't be hard to fix
22:45:11Zevvha
22:45:40Araq--gc:destructor throws away the GCs and replaces it with good old refcounting
22:46:05Zevvthat is soo 80's
22:46:12Araqkinda sad I know. we can optimize the overhead to acceptable levels though
22:47:14Zevvif its effective and it works, so what. things were tried, a lot was learned on the way.
22:48:02Araqoh I'm also using about 90% of the implementation
22:48:44Araqso very little effort was "wasted" indeed.
22:49:20FromDiscord<yewpad> Any Linux users here?
22:49:25Zevvsome
22:49:44FromGitter<alehander42> hm, it seems AllocatorObj is defined in stdlib_allocators.nim.c.
22:49:56FromGitter<alehander42> and i am probably not compiling them correctly together with stdlib_system
22:50:13FromDiscord<yewpad> I need some recommendations. Lightweight, should look somewhat modern, focus on efficiency, I don't care about security.
22:50:24Zevvlightweight *what*?
22:50:35FromDiscord<yewpad> lightweight linux distro
22:51:14*solitudesf quit (Ping timeout: 246 seconds)
22:51:37Zevvoh dunno, I don't care too much for distros, too lazy. I always pick debian, its lightweight and looks somewhat modern. it also focusess on efficience, but not sure if that is what you are looking for of course
22:51:59FromDiscord<yewpad> I had some bad experiences with Debian's mirrors
22:52:07Araqhttps://distrowatch.com/ --> "Mx Linux"
22:52:21Zevvthere you go
22:52:26FromDiscord<yewpad> Debian's gnome based, isn't it?
22:52:43Zevvno, it is agnostic
22:54:02FromDiscord<yewpad> Mx Linux ain't gonna do it for me
22:56:18stefantalpalaruY'er a newbie, Harry! Use Mint Linux or Ubuntu.
22:56:35FromDiscord<yewpad> I'll go with Pop Os
22:56:45skrylar[m]SuSE here
22:57:03FromGitter<alehander42> hm, Araq i get system needs nimRawDispose
22:57:08FromGitter<alehander42> with --gc:destructors
22:59:45Araqyou need nim devel
23:00:12FromGitter<alehander42> i use it
23:00:31FromGitter<alehander42> with ⏎ --os:standalone ⏎ --noMain ⏎ --deadCodeElim:off ⏎ --cpu:i386 ... [https://gitter.im/nim-lang/Nim?at=5dbe0a8fa85791488f895bba]
23:02:00Araqwtf?
23:02:05Araq--deadCodeElim:off?
23:02:13Araq--os:standalone?
23:03:03Araq'standalone' is not yet supported I guess
23:03:17Zevvback to the newruntime for you
23:05:25FromDiscord<mratsim> @yewpad, the big question with Linux is how much time do you want to spend or how much you wantto learn the internals of system administration
23:05:59FromDiscord<yewpad> I don't really care about the internals. I'm a software developer, I just want it to work and do its job
23:06:25FromGitter<alehander42> hm, probably dont need the deadCode one
23:06:32FromDiscord<mratsim> I use Debian to manage my home server (run a virtualization host + containers) and arch for my work machine and all the containers on that server
23:06:36FromGitter<alehander42> well --os:standalone because i was trying it on bare metal
23:06:39Zevvjust pick a debian flavour, ubuntu, xubuntu, whatever
23:06:40FromGitter<alehander42> kinda
23:06:44Calinoumaybe Fedora?
23:06:52FromDiscord<yewpad> PopOs is Ubuntu flavoured
23:06:57FromDiscord<mratsim> yeah agree, pick an Ubuntu or Fedora then
23:06:59Calinouit offers recent packages, but is still quite stable, I'd say it's a good choice for developers
23:07:00FromGitter<alehander42> it kinda runs now with standalone and newruntime
23:07:12FromGitter<alehander42> with some patches to the c files
23:07:16FromDiscord<mratsim> though Fedora I seem to always get into SELinux issues for some reasons
23:07:18FromGitter<alehander42> very simple patches
23:08:00FromDiscord<mratsim> @Araq: for your threading API, don't forget a barrier API, there is no barriers right now in Nim so I had to implement my own.
23:08:28FromDiscord<mratsim> If you know your way around windows barrier that would be helpful as well
23:09:21FromDiscord<mratsim> nothing fany, I only need init, wait and destroy: https://github.com/mratsim/weave/blob/master/picasso/primitives/barriers.nim#L32-L50
23:09:21FromGitter<Willyboar> I use elementary OS to my second computer and i like it a lot.
23:09:51*exelotl quit (Ping timeout: 250 seconds)
23:26:20Araqmratsim: barrier == threadpool's sync?
23:33:38FromDiscord<mratsim> I'm think that won't work for me, there is no shared memory besides channels so you can't access a worker.ready variable
23:33:45FromDiscord<mratsim> I think*
23:36:48FromDiscord<mratsim> I'm guessing I just need that: https://docs.microsoft.com/en-us/windows/win32/api/synchapi/nf-synchapi-entersynchronizationbarrier
23:39:32*exelotl joined #nim
23:47:20Araqa barrier is just a condition variable on the condition counter == N
23:47:49Araqif not, it's because I'm tired and working on something else :P