<< 12-03-2022 >>

00:00:15FromDiscord<dilawar (Dilawar Singh)> indeed. I just assumed `import logging` would init a default logger that would write to stdout for me.
00:00:47FromDiscord<Elegantbeef> Ah
00:01:07FromDiscord<Elegantbeef> It does not since you dont always want a console logger
00:01:35FromDiscord<Nick.> With C# you've a command called BinaryReader. Which read binary data and can create a key, value out of the binary config. With python you can do it with struct. Is there something within nim to do that? I was looking at strutils. Hopefully I said it correctly.
00:02:06FromDiscord<Elegantbeef> `std/streams`
00:02:36FromDiscord<dilawar (Dilawar Singh)> If tests pass then no stdout is shown. stdout is only shown in case of test failure? If yes, Is there a way to force stdout display even if test passes?
00:02:50FromDiscord<Elegantbeef> https://ajusa.github.io/binarylang-fun/intro.html is also an option
00:03:27FromDiscord<Nick.> I was looking at streams as well but is there a parser like BinaryReader or do I have to parse it all?
00:03:53FromDiscord<Elegantbeef> I dont get why you'd want to force the stdout, but perhaps it's here https://nim-lang.org/docs/testament.html
00:04:15FromDiscord<Elegantbeef> What?
00:04:23FromDiscord<Elegantbeef> Streams is identical to the binaryreader api
00:04:34FromDiscord<Elegantbeef> You make a binary reader than read a specific type out of it
00:04:58FromDiscord<Elegantbeef> You can also use binarylang or look at frosty
00:05:55FromDiscord<Elegantbeef> Like this example https://docs.microsoft.com/en-us/dotnet/api/system.io.binaryreader?view=net-6.0
00:07:20FromDiscord<Elegantbeef> sent a code paste, see https://paste.rs/aH4
00:07:46FromDiscord<Nick.> ok, interesting. and it can also be in a for loop
00:07:58FromDiscord<Elegantbeef> of course
00:08:03FromDiscord<Elegantbeef> `while not myFIle.atEnd`
00:08:13FromDiscord<Nick.> Interesting
00:08:23FromDiscord<Nick.> I'll give it a try! Thank you!
00:08:28FromDiscord<Elegantbeef> Like i said you can also use binarylang
00:08:56FromDiscord<Elegantbeef> You will run into issues if you attempt to serialize ref objects so things like `string` and `seq` might need their own `read` procedures specialized
00:08:56FromDiscord<Nick.> that's a module?
00:09:04FromDiscord<Elegantbeef> It's a package
00:09:10FromDiscord<Elegantbeef> https://github.com/sealmove/binarylang
00:09:15FromDiscord<Nick.> Right, I need to get use to the terms
00:10:47FromDiscord<Elegantbeef> There is also frosty if you want to easily go Nim \<-\> to binary. https://github.com/disruptek/frosty
00:21:49*Figworm joined #nim
00:25:00*jmdaemon joined #nim
00:28:51*jjido quit (Quit: My MacBook Air has gone to sleep. ZZZzzz…)
00:53:26*Gustavo6046_ joined #nim
00:53:37*Gustavo6046_ quit (Client Quit)
00:57:00*Gustavo6046 quit (Ping timeout: 240 seconds)
01:45:53*krux02 quit (Remote host closed the connection)
01:51:29*jmdaemon quit (Quit: ZNC 1.8.2 - https://znc.in)
01:52:47*jmdaemon joined #nim
03:12:14*jmdaemon quit (Ping timeout: 252 seconds)
03:16:21*Gustavo6046 joined #nim
03:21:40*jmdaemon joined #nim
04:24:48*acidsys quit (Excess Flood)
04:25:21*acidsys joined #nim
04:36:23FromDiscord<ripluke> Is there a way I can get Nim intellisese in nvim
04:36:39FromDiscord<ripluke> (edit) "Is there a way I can get Nim intellisese in nvim ... " added "(neovim)"
04:36:49FromDiscord<Rika> nim.nvim?
04:37:08FromDiscord<ripluke> That doesn't have autcomple iirc but I'll check, thx
04:38:03*arkurious quit (Quit: Leaving)
04:38:56FromDiscord<ripluke> In reply to @Rika "nim.nvim?": Thx I just noticed it has autcomplete as well
04:39:29FromDiscord<Rika> 👌
05:14:07*tk quit (Quit: Well, this is unexpected.)
05:15:31*tk joined #nim
05:18:34FromDiscord<Bung> @ElegantBeef any plan fix https://github.com/beef331/nimscripter/issues/11
05:19:11FromDiscord<Elegantbeef> I've looked into it, I need to make a PR for it to the compiler iirc
05:19:20*ormiret quit (Ping timeout: 250 seconds)
05:19:49*euantorano quit (Read error: Connection reset by peer)
05:19:58*euantorano joined #nim
05:20:07*oz quit (Quit: EOF)
05:20:07*notchris quit (Read error: Connection reset by peer)
05:20:13*ormiret joined #nim
05:20:17*notchris joined #nim
05:20:30*ox joined #nim
05:25:26FromDiscord<Bung> ah I thought just need pass new config when initialize nimscripter
05:25:49FromDiscord<Elegantbeef> Eh i fully forgot about the issue so i can try the passing a new config value
05:25:56FromDiscord<Elegantbeef> I think it's more complicated though
05:26:32FromDiscord<Bung> maybe, not sure
05:31:20FromDiscord<Elegantbeef> Oh seems it's simple
05:36:51termer_Does anyone know of any library to run procs on a different thread?
05:37:01termer_I wrote my own implementation but it looks like it's double calling procs
05:37:09termer_pretty lost and would rather use something battle-tested
05:37:33termer_basically I need to complete a future that was passed to a worker thread back on the origin thread of the future
05:37:45*slowButPresent quit (Quit: leaving)
05:38:06FromDiscord<Elegantbeef> Is this async related?
05:38:15termer_Possibly
05:38:23termer_Futures are being completed more than once
05:38:46termer_this isn't a problem until I spawn thousands of futures in a matter of seconds and ask them to be completed
05:39:03FromDiscord<Elegantbeef> @Bung\: seems it was a simple config, so i guess I'm a lazy shithead
05:39:05termer_at a certain point this is also causing a nil reference error in the GC that's crashing the application
05:40:10FromDiscord<Elegantbeef> Is your code thrown some where?
05:40:42FromDiscord<Elegantbeef> thrown up\
05:40:49termer_yes
05:40:52termer_lemme get the link
05:41:12termer_https://github.com/llstreamer/llstreamer-server/blob/main/src/llstreamer_server/private/threadutils.nim
05:41:19termer_here's my local thread executor
05:41:37termer_it's used here https://github.com/llstreamer/llstreamer-server/blob/main/src/llstreamer_server/private/crypto.nim
05:41:44termer_as well as here https://github.com/llstreamer/llstreamer-server/blob/main/src/llstreamer_server/private/db/sqlite.nim
05:42:12FromDiscord<Elegantbeef> What GC are you using?
05:42:13termer_Its purpose is to complete futures passed to a worker thread back on the thread where the future was created
05:42:15termer_orc
05:42:20termer_but this occurs on refc as well
05:42:44FromDiscord<Elegantbeef> Completing futures on other threads just seems like purposefully causing trouble
05:43:10termer_well threadutils.nim facilitates completing futures on their original therad
05:43:12termer_*thread
05:43:24termer_my issue is that at some point, futures are being called more than once
05:43:36FromDiscord<Bung> nimscript not support get env?
05:44:04FromDiscord<Elegantbeef> No clue it's in the nimscript module
05:44:08FromDiscord<Elegantbeef> Consider a PR to VMops
05:44:49FromDiscord<Elegantbeef> I can only imagine something is causing the Future's `finished` to reset, so where do you pass the futures around?
05:45:37termer_threadutils.nim:67 is the proc where futures are added to the queue
05:46:01termer_they are then executed in startLocalThreadExecutor thread
05:46:18termer_err
05:46:21termer_that loop
05:46:24termer_it's not a thread
05:47:48termer_crypto.nim:143 is on location where a future completing job is being passed into the queue
05:48:30FromDiscord<Elegantbeef> So you're still passing futures across the thread barrier?
05:48:47termer_A future is created on thread A
05:49:00termer_it's put in a queue that's accessible to both thread A and B
05:49:10termer_thread B picks up the job and future from the queue
05:49:15FromDiscord<Elegantbeef> Ok see that seems wrong to me, but i could be wrong
05:49:38termer_it performs the task and passes a proc that completes the future into a queue for thread A to execute
05:49:56FromDiscord<Elegantbeef> Thread A should just queue jobs for thread B, thread B then should do those jobs, then add the result to a queue
05:50:11termer_so the future was created on A, a job was passed to B, and then it schedules completion of the future in a job to be run on A
05:50:17termer_so the future is always executed on A
05:50:29FromDiscord<Elegantbeef> I dont get why you're using futures
05:50:49termer_because I'm awaiting a CPU intensive task
05:50:54FromDiscord<Elegantbeef> Just have a thread per operation then dispatch to those operations using async in there
05:51:12termer_thread per operation would end up spawning a ton of threads
05:51:25termer_in crypto.nim, I'm hashing passwords
05:51:27FromDiscord<Elegantbeef> Yea i probably should just shush i'm no expert in threading or async
05:51:57termer_I'm not sure whether you're being sarcastic but if you are I'm not trying to shut you down, just stating my reasoning
05:52:06termer_If I'm doing things wrong I'd be more than happy to be corrected
05:52:48termer_that's why I'm here after all
05:52:52termer_I screwed something up lol
05:53:16FromDiscord<Elegantbeef> I mean per unique operation type
05:53:41termer_there's a thread for password hashing and a thread for I/O currently
05:53:54termer_I/O thread is fully async
05:54:07termer_hashing thread does CPU-intensive work
05:55:23FromDiscord<Elegantbeef> I'm not being sarcastic, i really am not an expert here, and as such dont hold any weight in my view
05:56:13FromDiscord<Elegantbeef> I'd have the thread for password hashing send the result in a channel, and have the IO thread also send the results in a channel, since i'm a simpleton
05:56:18FromDiscord<Elegantbeef> I dont know why a future is involved here
05:56:42termer_how do channels work
05:56:56*termer_ is now known as termer
05:56:59FromDiscord<Elegantbeef> A queue of lock and data
05:57:08FromDiscord<Elegantbeef> https://nim-lang.org/docs/channels_builtin.html#example
05:57:30FromDiscord<Elegantbeef> You add elements to a channel and then can safely access from another thread, it's like a threadsafe sequence kinda
05:58:43termerthat might be just what I'm looking for
05:58:58termerhowever does a thread need to be suspended to get a new channel message
05:59:13FromDiscord<Elegantbeef> There is `tryRecv` which is non blocking
05:59:30termerthis might be EXACTLY what I'm looking for
05:59:38FromDiscord<Elegantbeef> Well there we go
05:59:41termerthank you so much
05:59:44FromDiscord<Elegantbeef> I assumed you knew it existed
05:59:48termernope
05:59:56termerI'm still a relatively new nim user
06:01:04FromDiscord<Elegantbeef> There is also https://github.com/status-im/nim-taskpools
06:02:02termerthis unfortunately isn't geared towards async
06:02:12termerbut channels should do in any case
06:02:30termerThis project needs to block as little as possible, and when it does block it needs to be off the I/O thread
06:05:01FromDiscord<Elegantbeef> Finally to give one more thing to consider https://nim-lang.org/docs/manual_experimental.html#parallel-amp-spawn-spawn-statement does exist
06:05:10FromDiscord<Elegantbeef> But i'm probably just spamming pointless things
06:05:26FromDiscord<Elegantbeef> Though a flowvar is kind alike a thread future
06:13:53FromDiscord<Bung> @ElegantBeef I found the problem is I put nimble pkgs to search pathes , then it try to compile all modules ?
06:15:28FromDiscord<Elegantbeef> Reproduction?
06:17:41FromDiscord<Bung> let me double check this
06:17:45FromDiscord<Elegantbeef> Cause i do test that it doesnt explode with the nimble path added https://github.com/beef331/nimscripter/blob/master/tests/tgeneral.nim#L145-L147
06:21:22FromDiscord<Bung> sent a code paste, see https://paste.rs/Jf1
06:22:24FromDiscord<Elegantbeef> Well i cant do anything but say "ensure your libraries work with nimscript"
06:22:54FromDiscord<Bung> I local modify vmops add getEnv returns empty string then I encounter this error, I dont know where it comes as I dont call docutils directly
06:23:27FromDiscord<Elegantbeef> No clue either, doesnt make any sense
06:25:12FromDiscord<Bung> can the script error trace to my src file , now it just from std to std ..
06:26:49FromDiscord<Elegantbeef> What?
06:27:56FromDiscord<Bung> I mean the script error stack trace does not locate to my local file
06:28:26FromDiscord<Elegantbeef> Invalid symbol errors dont show import order
06:33:49FromDiscord<Bung> okay
06:34:40*jmdaemon quit (Ping timeout: 272 seconds)
08:05:18FromDiscord<retkid> In reply to @Elegantbeef "There is also https://github.com/status-im/nim-task": this looks about as good as stock threading i dont like it
08:06:06FromDiscord<Elegantbeef> Cool
08:11:57FromDiscord<Phil> sent a long message, see http://ix.io/3S0z
08:12:12*krux02 joined #nim
08:13:12FromDiscord<Elegantbeef> That type looks tedious 😀
08:15:31FromDiscord<Phil> And I couldn't just throw the data of all different types into a single table because holy shit that table would've contained a lot of columns
08:16:02FromDiscord<Phil> In terms of db model I went with one table per different article type even if they share some fields, because I didn't want to have the data of a single entry split across 2 tables
08:16:07FromDiscord<Phil> ... discord eating my messages now, I've been trying to send one that just is not getting sent whatsoever
08:17:00FromDiscord<Phil> Anyway, 12 different article model types, each responsible for a different db table, not really much of a choice if I want a "summary" type
08:17:07FromDiscord<Elegantbeef> sent a code paste, see https://play.nim-lang.org/#ix=3S0B
08:17:39FromDiscord<Elegantbeef> I personally dont like the manual upkeep so i'd probably use a pragma instead of a typeclass but you do you i guess
08:17:41FromDiscord<Phil> Inheritance! hiss
08:18:50FromDiscord<Elegantbeef> sent a code paste, see https://play.nim-lang.org/#ix=3S0D
08:18:51FromDiscord<Elegantbeef> Arent you already using inheritance?
08:18:58FromDiscord<Phil> Begrudgingly
08:19:32FromDiscord<Phil> I tend to avoid it wherever possible but it was either accept the inheritance that norm provides me or not using norm
08:20:13FromDiscord<Phil> ... though I'll admit a decent chunk of that is because I detest inheritance complexity that work-code throws at me
08:20:39FromDiscord<Phil> Which is java, so to be expected
08:21:28FromDiscord<Elegantbeef> That was easy
08:21:32FromDiscord<Elegantbeef> sent a code paste, see https://play.nim-lang.org/#ix=3S0F
08:22:11FromDiscord<Elegantbeef> Eh i rarely use inheritance, prefer using concepts where i can
08:23:23FromDiscord<Phil> I'll contemplate that for a future refactor, for now I pretty much already have the types, I'm just trying to refactor them out of a specific module that one thing uses (my search part of the application which searches across all these articles) and put it into its own thing since the "recently updated article" part of the application will also access them
08:23:57FromDiscord<Phil> Thus the quest for a module name, as e.g. there's also an enum with the table names of all these types included that I also want to move out etc.
08:24:08FromDiscord<Elegantbeef> Well then `articles` sounds fine
08:25:34FromDiscord<Phil> Hmmm all this "|" stuff was called type aliasing IIRC
08:26:17FromDiscord<Phil> I'll need to squint heavily at article/s / articleAlias or so as names
08:27:36FromDiscord<Elegantbeef> "articleAlias" isnt a module it's a stupid type name
08:28:00FromDiscord<Elegantbeef> articles implements the types and procedures around said types 😛
08:28:05FromDiscord<Elegantbeef> Smoke bomb with that dumb logic
08:38:26FromDiscord<Bung> @ElegantBeef any reason cause `Error: unhandled exception: 'renderArchive' was not found in the script. [VmProcNotFound]` am pretty sure I have `renderArchive` and my script file has import and export that
08:38:39FromDiscord<Elegantbeef> Do you have overloads
08:39:10FromDiscord<Bung> no , I have only one version renderArchive
08:39:49*krux02 quit (Remote host closed the connection)
08:40:33FromDiscord<Elegantbeef> It's in your top level module?
08:41:32FromDiscord<Elegantbeef> I've not tested exporting a procedure from an inner module, so that is probably the issue
08:41:39FromDiscord<Bung> the proc is in archive.nim https://media.discordapp.net/attachments/371759389889003532/952124201597288498/Screenshot_2022-03-12_at_4.41.18_PM.png
08:42:41FromDiscord<Elegantbeef> The issue is somewhere inside here https://github.com/nim-lang/Nim/blob/f0af4a36b932af3932b611c1f728ebfbfe3a2749/compiler/nimeval.nim#L30-L51
08:43:08FromDiscord<Elegantbeef> What's the procedure definition?
08:44:16FromDiscord<Bung> https://github.com/bung87/crown_ui/tree/nimscripter see
08:45:35FromDiscord<Bung> it called serveral procs from theme.nim successfully until call renderArchive
08:47:34FromDiscord<Elegantbeef> I dont see why this is having issues with this logic
08:50:19FromDiscord<Elegantbeef> What's the nimscript look like?
08:52:49FromDiscord<Bung> https://github.com/bung87/crown_ui/blob/nimscripter/src/crown_ui/themes/default/theme.nim
08:53:55FromDiscord<Bung> https://github.com/bung87/crown_ui/blob/nimscripter/src/crown_ui/themes/default/archive.nim
08:54:45FromDiscord<Elegantbeef> Nothing stands out to me why the compiler says it doesnt exist so i guess it's'a compiler bug
08:57:02FromDiscord<Bung> weird , I commented generateArchive , other generation steps run well
08:59:44*jjido joined #nim
09:34:48NimEventerNew thread by Jasonfi: Launched a web app using Nim on the back-end, see https://forum.nim-lang.org/t/9002
09:38:53FromDiscord<xigoi> sent a code paste, see https://paste.rs/gXX
09:46:25FromDiscord<xigoi> It looks like I'm missing some dynamic library, but I have openssl installed, so no idea what it could be.
09:47:46*brocc joined #nim
09:56:56FromDiscord<soda> sent a code paste, see https://play.nim-lang.org/#ix=3S15
09:57:22FromDiscord<soda> this for loop 'for x in os.walk_dir(src):' is not entered when the recursion occurs
10:07:06FromDiscord<xigoi> I don't see any recursive call in the proc…
10:09:28FromDiscord<xigoi> Maybe you want walkDirRec, so that it would recurse automatically?
10:09:50FromDiscord<Elegantbeef> You also can use a case statement instead of elif statements
10:11:24FromDiscord<rakgew> is there way to use something like `var userInput = stdin.readLine()` inside inim? currently gives me `raise EOF`
10:12:32FromDiscord<Elegantbeef> I dont imagine so
10:12:55FromDiscord<rakgew> bummer..
10:14:12FromDiscord<rakgew> that way I would not have to implement the repl features for my cli apps myself.
10:14:45FromDiscord<rakgew> I tried doing that with nim-prompt
10:14:57FromDiscord<rakgew> but there was no example code
10:15:01FromDiscord<Elegantbeef> You could make your stdin be a file, and then write to the file but that'd be odd
10:15:11FromDiscord<Schelz> Is nim able to import Julia functions ?
10:15:19FromDiscord<Elegantbeef> The best thing would probably use Nimscript to get a repl-ish environment
10:15:20FromDiscord<soda> sent a code paste, see https://play.nim-lang.org/#ix=3S1c
10:15:52FromDiscord<Elegantbeef> Though i dont know what you're doing
10:16:00FromDiscord<rakgew> ah, I see - had not thought about that - thx!!
10:16:08*jjido quit (Quit: My MacBook Air has gone to sleep. ZZZzzz…)
10:16:16FromDiscord<Elegantbeef> Are you trying to make it so your CLI app is modifyable?
10:16:56FromDiscord<rakgew> basically interactive input from user\: one example is asking for input where to put scanned files with which name..
10:16:56FromDiscord<soda> In reply to @xigoi "Maybe you want walkDirRec,": Yes i will give it a try, but i would like to know why this fails.
10:16:56FromDiscord<Rika> In reply to @Schelz "Is nim able to": Not to my knowledge
10:16:58FromDiscord<Elegantbeef> Soda i'd certainly say just use walkdirrec
10:17:17FromDiscord<Elegantbeef> what does `x.path` return?
10:17:25FromDiscord<Bung> @ElegantBeef I rename module to a longer name now it works
10:17:33FromDiscord<soda> It corrects the correct path to the target dir that needs to be recursed into
10:17:38FromDiscord<soda> (edit) "corrects" => "returns"
10:17:42FromDiscord<Bung> archive.nim -> crown_ui_archive.nim
10:17:59FromDiscord<Elegantbeef> That maakes no sense Bung, perhaps a bad cached file
10:18:15FromDiscord<soda> The issue is that this line :↵ for x in os.walk_dir(src):↵is not executed on subsequent recursions. The check fails even though the path is correct and non-empty
10:19:07FromDiscord<Elegantbeef> Does https://nim-lang.org/docs/rdstdin.html#readLineFromStdin%2Cstring not work for you?
10:19:13FromDiscord<Elegantbeef> I'm confused why inim is involved
10:19:22FromDiscord<soda> (edit) "The issue is that this line :↵ for x in os.walk_dir(src):↵is not executed on subsequent recursions. The check fails even though the path is correct and non-empty ... " added "(like it would if the dir was empty, but it's not)"
10:19:33FromDiscord<Bung> In reply to @Elegantbeef "That maakes no sense": maybe I install too much packages it resolve to a nimble package like nimarchive ?
10:19:34FromDiscord<Elegantbeef> Is the "interactive" part a scriptable program?
10:19:45FromDiscord<Elegantbeef> No clue
10:19:55FromDiscord<Elegantbeef> It should default to relative before anywherelese
10:20:07FromDiscord<rakgew> ideally I would like autocomplete and thought I could get that from inim
10:20:19FromDiscord<rakgew> inim does not have to be in the mix though
10:20:42FromDiscord<Rika> Autocomplete for what?
10:20:48FromDiscord<rakgew> any other repl framework would do as well
10:21:01FromDiscord<Elegantbeef> I dont know i'd just implement this using illwill, this isnt a repl needed thing
10:21:11FromDiscord<rakgew> for the user input\: certain predefined topics, today's date, etc..
10:21:19FromDiscord<Elegantbeef> Can you explain the entire program?
10:21:46FromDiscord<soda> sent a code paste, see https://play.nim-lang.org/#ix=3S1e
10:22:04FromDiscord<Elegantbeef> There's the issue you ported python 😛
10:22:15FromDiscord<soda> I also have a working C++ version 😛
10:22:27FromDiscord<Elegantbeef> That's equally as bad
10:23:24FromDiscord<Rika> Let’s not argue
10:23:27FromDiscord<Rika> What’s the issue again
10:23:38FromDiscord<Rika> It’s a bit mixed up above
10:23:59FromDiscord<soda> > The issue is that this line :↵> for x in os.walk_dir(src):↵> is not executed on subsequent recursions. The check fails even though the path is correct and non-empty (like it would if the dir was empty, but it's not)
10:24:18FromDiscord<soda> When going into recursion, the for loop is not entered as it should
10:24:43FromDiscord<rakgew> [Elegantbeef](https://matrix.to/#/@elegantbeef:matrix.org)\: the example is a simple one\: check if the scanner is available, then ask the user for file name infos\: which path to put it to, the topic of scanned documents, the date of the documents (default/autocomplete today), then scan multiple pages, compress them (lzw) and move them to the defined directory.
10:25:05FromDiscord<rakgew> this could be done with simple stdin.readline
10:25:20FromDiscord<Elegantbeef> Ah and you want shell like completion
10:25:22FromDiscord<rakgew> but I would like to make it more generic, so I can reuse it
10:25:31FromDiscord<rakgew> exactly.
10:25:37FromDiscord<Elegantbeef> I feel like the thing to do is make procedures for this then
10:26:09FromDiscord<rakgew> yes - ideally I would have a proc for each command
10:26:46FromDiscord<rakgew> and these then ask for user input accordingly to types/tables to get user data input.
10:26:57FromDiscord<Bung> it will be problem if I wrongly pass it to searchPath https://media.discordapp.net/attachments/371759389889003532/952150702019457085/Screenshot_2022-03-12_at_6.22.41_PM.png
10:27:53FromDiscord<rakgew> I have written a few of these repl like apps in python, and thought they would be a great starting point for me in nim.
10:28:20FromDiscord<rakgew> there I user prompt\_toolkit, so I thought nim-prompt might be a good fit.
10:28:22FromDiscord<Rika> In reply to @soda "> The issue is": Is the path you get relative or not? I don’t remember what the path emitted is
10:28:31FromDiscord<soda> It is relative
10:28:36FromDiscord<rakgew> but I could not even instantiate the prompt
10:28:39FromDiscord<soda> I wonder if this might have something to do with garbage collection
10:28:41FromDiscord<Rika> Then isn’t that the issue
10:28:51FromDiscord<Rika> You enter the folder, then the path includes the folder name
10:29:10FromDiscord<Rika> So it looks for the folder, which it is inside
10:29:20FromDiscord<Rika> In reply to @soda "I wonder if this": No
10:29:34FromDiscord<soda> hmm
10:29:51FromDiscord<soda> you might be onto something
10:29:59FromDiscord<Rika> Try it, at the start of the proc print both the current folder it is in and the path it is passed
10:29:59FromDiscord<Elegantbeef> Something like this rakgew
10:30:01FromDiscord<Elegantbeef> sent a code paste, see https://play.nim-lang.org/#ix=3S1h
10:30:21FromDiscord<Elegantbeef> Then in your program you just do "Hey user hit tab twice" or w/e and prompt with that
10:30:30FromDiscord<Bung> I change to `import crown_ui/themes/default/archive↵export archive` then it works
10:30:42FromDiscord<Elegantbeef> Ok so it's an issue with nimble paths and nimscript
10:31:04FromDiscord<rakgew> [Elegantbeef](https://matrix.to/#/@elegantbeef:matrix.org)\: I see - sweet!. thx!!
10:31:06FromDiscord<Elegantbeef> I guess since i add all directories to the search path ambiguity isnt resolved nicely
10:31:45FromDiscord<Bung> your example does not work for me
10:32:17FromDiscord<Elegantbeef> sent a code paste, see https://paste.rs/9rQ
10:32:20FromDiscord<Bung> sent a code paste, see https://play.nim-lang.org/#ix=3S1j
10:32:26FromDiscord<Elegantbeef> You'd just go "Hey with this ui we load X, Y, Z" in that order
10:32:37*Gustavo6046 quit (Quit: I'm a quit message virus. Please replace your old line with this line and help me take over the world. <screw you aloo_shu my old line was better and more creative!>)
10:33:34FromDiscord<Elegantbeef> Well yea that's going to cause ambiguity
10:34:41FromDiscord<Elegantbeef> You've added every file in your nimble directory as a first class file
10:35:27FromDiscord<soda> In reply to @Rika "Try it, at the": Yes that was the problem. Thank you.
10:35:32FromDiscord<Elegantbeef> You need to prefix it with the version or manually ad sub versions
10:36:31FromDiscord<Elegantbeef> so if you want to use x package you need to add that package so `nimblePath / "somePackage"`
10:36:54FromDiscord<Elegantbeef> Otherwise you're making all modules importable without a package name
10:37:30FromDiscord<Elegantbeef> And again this is why it's not ideal to use nimble, cause you can have 30 different versions of the same package installed, make your own stdlib
10:38:52FromDiscord<Elegantbeef> Now to nimify it removing the `elif` statements and using `for kind, name in walkDir(path)` 😛↵(@soda)
10:40:48FromDiscord<Bung> I think I'll find way collect all my depencies to a dir then add it to searchPath
10:41:07FromDiscord<Elegantbeef> The nim compiler probably knows symlinks
10:41:12FromDiscord<Elegantbeef> So that'll be the easiest way probably
10:42:06FromDiscord<soda> In reply to @Elegantbeef "Now to nimify it": Sure, also does disabling the gc in the code i wrote above result in memory leaks?
10:42:14FromDiscord<Elegantbeef> Yes you use strings
10:42:24FromDiscord<soda> ah okay
10:42:28FromDiscord<soda> makes sense
10:42:29FromDiscord<Elegantbeef> It's better to just do `--gc:arc` than `--gc:none`
10:42:35FromDiscord<Rika> Why do you want to disable it anyway
10:42:43FromDiscord<soda> it results in a smaller binary
10:42:58FromDiscord<Rika> Use as beef says then
10:43:04FromDiscord<soda> hmm ok
10:43:11FromDiscord<Elegantbeef> Then do `-d:lto -d:danger --gc:arc --opt:size`
10:43:12FromDiscord<Rika> Also opt:size
10:43:17FromDiscord<demotomohiro> `--gc:none` can result in a memory leak
10:43:22FromDiscord<Rika> I do not recommend danger
10:43:28FromDiscord<soda> i am used to it
10:43:29FromDiscord<Rika> Use release either way
10:43:33FromDiscord<soda> thanks to c / c++
10:43:42FromDiscord<Elegantbeef> No shit sherlock 😛↵(@demotomohiro)
10:43:54FromDiscord<Rika> In reply to @Elegantbeef "No shit sherlock 😛": Not very obvious to most
10:44:17FromDiscord<Elegantbeef> Danger is smaller, if we're after size it's a good way to do it, shaves a few KB off↵(@Rika)
10:44:27FromDiscord<soda> now i just gotta learn how to manually deallocate strings :3
10:44:30FromDiscord<Elegantbeef> Can also statically build using musl for even smalelr
10:44:34FromDiscord<Elegantbeef> smaller\
10:44:43FromDiscord<Rika> In reply to @soda "now i just gotta": Just use ARC if you’re gonna do this anyway
10:44:51FromDiscord<Rika> In reply to @Elegantbeef "Danger is smaller, if": I still don’t recommend it
10:44:53FromDiscord<Elegantbeef> Nim doesnt really expose the internals of strings so you cant really manually dealloc, just use arc
10:44:56FromDiscord<soda> In reply to @Elegantbeef "Can also statically build": oh true, i do have musl somewhere lying around
10:45:03FromDiscord<soda> In reply to @Elegantbeef "Nim doesnt really expose": sad
10:45:09FromDiscord<soda> In reply to @Rika "I still don’t recommend": Well the idea is to learn.
10:45:09FromDiscord<Elegantbeef> Arc is going to be as performant as manual
10:45:24FromDiscord<Rika> In reply to @soda "Well the idea is": Learn from using danger instead of release?
10:45:29FromDiscord<soda> why not
10:45:34FromDiscord<Elegantbeef> ARC is deterministic GC, so it's not very big, but is very fast
10:45:45FromDiscord<soda> yea the binary is 30kb smaller
10:45:47FromDiscord<Elegantbeef> Danger doesnt give you any information, it's only really useful for speed/size
10:45:58FromDiscord<Rika> It’s not fast, it’s low latency
10:46:12FromDiscord<Rika> Use strip as well if you want
10:46:26FromDiscord<Elegantbeef> All the usual C size optimization tricks apply 😛
10:46:29FromDiscord<soda> haha yes ofc i have done all of these things
10:46:33FromDiscord<soda> save for linking with musl
10:46:45FromDiscord<enthus1ast> can i test if a var is a const? In a macro?
10:46:53FromDiscord<soda> this is the make file i used
10:46:58FromDiscord<soda> sent a long message, see http://ix.io/3S1l
10:47:42FromDiscord<Rika> Why are you pursuing small binary sizes? Just wondering
10:48:07FromDiscord<soda> No real reason. I'm just playing around with nim and compare it to other languages i know
10:48:14FromDiscord<soda> to mentally profile it
10:49:40FromDiscord<soda> In reply to @Elegantbeef "Now to nimify it": This is very similar to go
10:50:26FromDiscord<Elegantbeef> `symKind`
10:50:55FromDiscord<enthus1ast> thanks [Elegantbeef](https://matrix.to/#/@elegantbeef:matrix.org) !
11:27:28*syl_ is now known as syl
11:39:15FromDiscord<retkid> https://github.com/soasme/nim-schedules
11:39:17FromDiscord<retkid> i like this syntac
11:39:18FromDiscord<retkid> (edit) "syntac" => "syntax"
11:39:20FromDiscord<retkid> it make my brain happy
11:46:03*jmdaemon joined #nim
11:48:26FromDiscord<Rika> eh
11:49:49FromDiscord<retkid> https://media.discordapp.net/attachments/371759389889003532/952171552617660416/unknown.png
11:50:26FromDiscord<retkid> it kinda upsets me that it isn't perfect but im going to assume thats the computation time of the difference proc
11:50:38FromDiscord<Rika> perfection is difficult
11:50:52FromDiscord<Rika> if you want perfection then you have a lot of work ahead of you
11:51:03FromDiscord<retkid> https://media.discordapp.net/attachments/371759389889003532/952171862186672128/unknown.png
11:51:13FromDiscord<retkid> its better with -d:danger
11:51:19FromDiscord<retkid> so yea i think its near perfect
12:08:12*jmdaemon quit (Ping timeout: 240 seconds)
12:25:41*jjido joined #nim
12:30:46*jjido quit (Quit: My MacBook Air has gone to sleep. ZZZzzz…)
12:46:38FromDiscord<Sense> In reply to @Amun-Ra "System64 - this is": damn
12:55:52*pro joined #nim
13:04:20*vicecea quit (Remote host closed the connection)
13:04:48*vicecea joined #nim
13:26:50*pro quit (Quit: pro)
14:09:07FromDiscord<Schelz> nim support esp32 ibeacon via ble ?
14:40:16*arkurious joined #nim
14:53:09FromDiscord<auxym> I mean, nim won't support that, but a library might. Have you checked nesper? Also, try asking in the embedded channel
14:58:49*toulene quit (Ping timeout: 272 seconds)
15:01:38*toulene joined #nim
15:10:16FromDiscord<Schelz> its the same thing just that on main peoples might answer faster its not a technical question its just a simple question
15:10:23FromDiscord<Schelz> In reply to @auxym "I mean, nim won't": its the same thing just that on main peoples might answer faster its not a technical question its just a simple question
15:12:03FromDiscord<auxym> i mean, sounds pretty technical tbh, you're asking about a very specific feature of a very specific embedded system. but main is pretty quiet this morning anyways 😄
15:12:26FromDiscord<Schelz> huh lame
15:13:16FromDiscord<Schelz> bth thx for guessing an answer for my question
15:14:21FromDiscord<Schelz> (edit) removed "bth"
15:14:51FromDiscord<Schelz> (edit) "thx for guessing an answer for my question ... " added "😄"
15:25:37FromDiscord<soda> Is there an equivalent of C++'s fmt::format in nim? I know fmt exists, but is there a way i can have something like fmt("{}", 21) ?
15:26:44FromDiscord<Schelz> https://nim-lang.org/docs/strformat.html
15:26:47FromDiscord<Rika> strutils.%
15:27:11FromDiscord<soda> In reply to @Schelz "https://nim-lang.org/docs/strformat.html": i couldn't find what i was looking for there
15:27:18FromDiscord<soda> In reply to @Rika "strutils.%": oh okay i'll check it out
15:27:53FromDiscord<Schelz> oh
15:27:55FromDiscord<Rika> usage is like `"$# aaaa $#" % ["bbbb", "cccc"]`
15:28:04FromDiscord<Rika> i think
15:28:05FromDiscord<Rika> i forget
15:28:09FromDiscord<Rika> its on the docs nonetheless
15:32:43FromDiscord<soda> Cool it works well, but i have one more question. Is there a ternary operator i can use to branch the replacing?
15:33:31FromDiscord<soda> C++ equivalent would be: std::cout << "I am a " << (bool ? "if true" : "if false");
15:33:38FromDiscord<auxym> In reply to @Rika "usage is like `"$#": https://nim-lang.org/docs/strutils.html#%25%2Cstring%2CopenArray%5Bstring%5D
15:33:52FromDiscord<Rika> yeah that
15:34:12FromDiscord<soda> Yeah it's that syntax, but doesn't seem to support ternary operator inside the []
15:34:16FromDiscord<Rika> In reply to @soda "Cool it works well,": `(if aBool: "true" else: "false")`
15:34:24FromDiscord<soda> it wont work
15:34:26FromDiscord<Rika> thats a ternary
15:34:28FromDiscord<Rika> why not
15:34:42FromDiscord<soda> nvm im dum
15:34:52FromDiscord<Rika> !eval echo "$1" % [(if true: "true" else: "false")]
15:34:54NimBotCompile failed: /usercode/in.nim(1, 11) Error: undeclared identifier: '%'
15:35:12FromDiscord<soda> it actually works
15:35:20FromDiscord<soda> i had just missed something else
15:35:21FromDiscord<Rika> ok good
16:00:28*slowButPresent joined #nim
17:00:43*acidsys quit (Excess Flood)
17:01:16*acidsys joined #nim
17:37:28*def- quit (*.net *.split)
17:37:28*rb quit (*.net *.split)
17:37:28*ssiyad quit (*.net *.split)
17:37:28*tinystoat quit (*.net *.split)
17:42:55*def- joined #nim
17:42:55*rb joined #nim
17:42:55*ssiyad joined #nim
17:42:55*tinystoat joined #nim
17:44:37FromDiscord<Require Support> `myObj->myMember` in C is just `myObj.myMember` in nim ? if myObj is already a `ptr` type
18:05:43FromDiscord<huantian> Correct, it’s the same as `myObj[].myMember`
18:11:50FromDiscord<S3cur3Th1sSh1t> sent a long message, see http://ix.io/3S3o
18:35:07FromDiscord<d4rckh> sent a code paste, see https://play.nim-lang.org/#ix=3S3x
18:38:43FromDiscord<qb> I guess echoing isn't threadsafe. Multiple threads could echo to the same line at the same time. Locks would make sure you get every echo on a new line
18:39:48FromDiscord<huantian> Yep you don’t want one echo to happen in the middle of another and “interrupt” it
18:40:46FromDiscord<d4rckh> thanks! I know when I was doing threads in python they wouldn't actually be parallel but concurrent, this happened only on windows tho, is it the same case with nim too?
18:43:23FromDiscord<qb> If you're talking about the interpreter lock python has. No nim doesn't have that
18:44:05*jmdaemon joined #nim
18:44:23FromDiscord<qb> But pythons gil should be on every os
18:46:43FromDiscord<S3cur3Th1sSh1t> In reply to @S3cur3Th1sSh1t "Hey, can someone": Already found a solution, problem solved.
18:49:34FromDiscord<d4rckh> In reply to @qb "If you're talking about": cool
19:12:05FromDiscord<Ayy Lmao> Is there a way to get nimlsp in sublime text to be aware of changes to other files? For some reason when I do something like change a function definition in another file, I have to restart sublime text for other files to be aware of that change.
19:22:52FromDiscord<d4rckh> I am getting this error when compiling that code: `Error: cannot evaluate at compile time: nThreads`. why is that getting evaluated at compile time? https://media.discordapp.net/attachments/371759389889003532/952285564579749918/unknown.png
19:26:09FromDiscord<Phil> Type assignments are done at compile time
19:26:22FromDiscord<Phil> And so it tries to resolve nThreads and replace it with a 5
19:26:47FromDiscord<Phil> But then notices that nThreads isn't known at compile time, only at runtime (because you use var. To have this be at compile time use const)
19:27:26FromDiscord<Phil> Keep in mind though that const values can basically be only magic numbers and magic strings, so essentially strings and numbers you hard code as you did nThreads
19:27:33FromDiscord<d4rckh> I see, but nThreads needs to be a var because it will be replaced with an command line argument later
19:27:36FromDiscord<Phil> (edit) "nThreads" => "nThreads. That or they have to be types/ stem from types"
19:27:44FromDiscord<d4rckh> (edit) "an" => "a"
19:28:12FromDiscord<Phil> in that case you migth want to make a const "threadCount" and then do "nThreads = threadCount" initially
19:28:31FromDiscord<Phil> or "initialThreadCount" if nThreads evolves over time
19:28:43FromDiscord<Phil> or "maxThreadCount" if the array is only ever supposed to contain 5 entries
19:29:24FromDiscord<d4rckh> wait, one second
19:29:29FromDiscord<d4rckh> https://media.discordapp.net/attachments/371759389889003532/952287232646082620/unknown.png
19:29:32FromDiscord<d4rckh> here
19:30:06FromDiscord<d4rckh> this is how it should be
19:30:24FromDiscord<Phil> First question, I assume parsedArgs.threadCount is still 5
19:30:30FromDiscord<Phil> Will you never have more than 5 threads?
19:30:51FromDiscord<Phil> Or do you want your array to be able to handle more than 5 threads?
19:30:53FromDiscord<d4rckh> it a user provided value so it could be anything
19:30:57FromDiscord<d4rckh> (edit) "it" => "its"
19:31:13FromDiscord<d4rckh> 1, 2, 20, 100
19:31:24FromDiscord<Phil> Then you can't use a straight up array here, for an array you must know at compile time how large it is allowed to be. You want to use a seq
19:33:55FromDiscord<d4rckh> oh, it works, thanks
19:34:04FromDiscord<Phil> with seq?
19:34:12FromDiscord<Kiwids> hi guys! I want to use deploy Jester with https. is there a way to achieve that?
19:34:14FromDiscord<Kiwids> thanks! alot
19:34:23FromDiscord<Kiwids> (edit) "use" => ""
19:35:20FromDiscord<Kiwids> like flask in python
19:35:27FromDiscord<Phil> No idea, never used jester, I use prologue. You might have also a chance by asking in the webdev channel
19:35:34FromDiscord<Kiwids> In reply to @Isofruit "No idea, never used": thanks!
19:35:53FromDiscord<d4rckh> In reply to @Isofruit "with seq?": yup
19:36:13FromDiscord<Phil> In reply to @Kiwids "thanks!": Though, either way, shouldn't you have your server behind an ngninx or an apache and they handle the HTTPS side of things?
19:36:23FromDiscord<Phil> (edit) "In reply to @Kiwids "thanks!": Though, either way, shouldn't you have your ... server" added " application"
19:37:18FromDiscord<Kiwids> haha yeah that would be the case. but I am just wondering if this is possible for a small env
19:38:30FromDiscord<Phil> In reply to @d4rckh "yup": Yeh, if you want what amounts to a resizeable array (the data type is typically called a list), then the tool to go is pretty much seq's.↵Arrays are useful when you know your data size ahead of time, e.g. that it must be 5 entries or sth.
19:43:27FromDiscord<d4rckh> sent a code paste, see https://play.nim-lang.org/#ix=3S3M
19:43:40FromDiscord<d4rckh> it throws this error `Error: unhandled exception: index out of bounds, the container is empty [IndexDefect]`
19:44:04FromDiscord<Alea> is there still not better alternative to nimsaem's extension for vscode? it's really not working for me today
19:44:09FromDiscord<Alea> (edit) "not" => "no"
19:44:11FromDiscord<Phil> Well, it starts with 0 threads in it, you're just declaring the variable. Got to do a lot of thr.add calls first that add some threads
19:44:36FromDiscord<exelotl> is there a nim equivalent of `LINE` ?
19:44:49FromDiscord<d4rckh> so just empty elements to the sequence?
19:44:55FromDiscord<exelotl> I'm trying with `instantiationInfo` but it seems to only work in templates
19:45:59FromDiscord<Phil> In reply to @d4rckh "Wait, I don't think": strictly speaking it's just a declared variable with no content. ↵Under the hood nim does some initialization for you, so by just declaring it nim already builds an empty seq with those types for you, but I would never ever rely on that.
19:46:29FromDiscord<d4rckh> In reply to @Isofruit "*strictly speaking* it's just": oh, how can i initialize it myself then?
19:50:21FromDiscord<Phil> sent a code paste, see https://play.nim-lang.org/#ix=3S3N
19:50:35FromDiscord<Phil> (edit) "https://play.nim-lang.org/#ix=3S3N" => "https://play.nim-lang.org/#ix=3S3O"
19:50:50FromDiscord<Schelz> Does nim has bind for DEFINE_GUID ?
19:51:02FromDiscord<Schelz> (edit) "Does nim has bind for DEFINE_GUID ?" => "sent a code paste, see https://play.nim-lang.org/#ix=3S3Q"
19:51:10FromDiscord<Schelz> (edit) "sent a code paste, see https://play.nim-lang.org/#ix=3S3Q" => "Does nim has bind for DEFINE_GUID?"
19:51:13FromDiscord<Schelz> (edit) "DEFINE_GUID?" => "DEFINE_GUID ?"
19:51:24FromDiscord<Phil> In reply to @Alea "is there still no": There's really not a lot. Half the time I debug just on compiler errors alone which do an alright job
19:52:29FromDiscord<d4rckh> In reply to @Isofruit "There's like half a": oh yeah i was doing this too but i wasnt sure about the code to create a thread object haha
19:52:51FromDiscord<Phil> What package did you import to have the Thread type?
19:53:10FromDiscord<Phil> Typically that kind of package contains procs for building the type it provides
19:53:15FromDiscord<d4rckh> It's part of the system module, https://nim-lang.org/docs/threads.html
19:53:38FromDiscord<Phil> I'm spotting 2 "createThread" procs at first glance
19:54:26FromDiscord<Alea> In reply to @Isofruit "There's really not a": my problem is that it wont show func signatures while any errors exist :pain:
19:54:59FromDiscord<Phil> In reply to @Alea "my problem is that": Huh, that puts you further ahead than me, for me the intellisense takes so long I can type out the proc three times over before I get a suggestion
19:55:49FromDiscord<Phil> nimsaem's plugin is still pretty useful for underlining the areas where the compiler is complaining though, so I'll take what I can get
19:56:20FromDiscord<d4rckh> In reply to @Isofruit "I'm spotting 2 "createThread"": both return a proc 😢 https://media.discordapp.net/attachments/371759389889003532/952293989103583302/unknown.png
19:57:17FromDiscord<Phil> You'll find both return nothing 😛↵But they take procs as arguments, as in that proc will be executed by that thread and once the proc is finished that thread will kill itself
19:57:46*jjido joined #nim
19:57:47FromDiscord<Phil> `;` is identical to `,` within proc signatures
19:57:54FromDiscord<Phil> Don't ask me why, some people find that more visible
19:58:37FromDiscord<Phil> Actually there's some fine-grained differences, like you can't do "a; b: int" iirc, but I'm not a fan of that anyway so.... eh
19:59:05FromDiscord<d4rckh> Oh, so how can I get about creating a Thread object to add to that sequence then?
19:59:37FromDiscord<Phil> What task is the thread supposed to do?
19:59:58FromDiscord<d4rckh> It's supposed to do some web requests
20:00:17FromDiscord<d4rckh> actually it just calls another function
20:00:26FromDiscord<d4rckh> (edit) "function" => "function, that is doing some web requests"
20:00:58FromDiscord<Phil> define a proc that does exactly that (does the web request, receives a response and performs some action from that response)
20:01:17FromDiscord<Phil> And then use that proc as argument for creating the thread
20:01:31FromDiscord<Phil> (edit) "And then use that proc as ... argument" added "the "tp""
20:01:41FromDiscord<d4rckh> yeah, i have a `threadFunc` as the example from threads docs
20:08:54NimEventerNew thread by Seves: Handling of persistent connections in asynchttpserver, see https://forum.nim-lang.org/t/9003
20:10:43FromDiscord<Phil> createThread(thr[i], yourProc, <however you instantiate a tuple I forgot>) should do it
20:10:51FromDiscord<Phil> (edit) "yourProc," => "threadFunc,"
20:11:24FromDiscord<Phil> But you start at index 0
20:12:25FromDiscord<Phil> sent a code paste, see https://paste.rs/LtF
20:12:30FromDiscord<d4rckh> In reply to @d4rckh "Wait, I don't think": That's what im doing already
20:22:29FromDiscord<d4rckh> sent a code paste, see https://paste.rs/tPD
20:31:24FromDiscord<Phil> Welp, all examples insist on static numbers of threads, not a dynamic number of threads. I'd start experimenting with createThread procs and see how to get the initial Thread you need for them to work, otherwise I'd recommend contemplating whether dynamic thread amounts are desired or not.
20:31:38FromDiscord<Phil> I myself shall head off to sleep
20:32:21FromDiscord<d4rckh> the thread count must be dynamic
20:32:30FromDiscord<d4rckh> have a great sleep and thanks for helping me
20:32:37*Gustavo6046 joined #nim
20:33:03FromDiscord<d4rckh> maybe someone else can help me with having dynamic thread amounts? 😛
20:33:28FromDiscord<Phil> You could always start experimenting with the procs yourself 😛
21:41:55*wyrd quit (Ping timeout: 240 seconds)
21:48:59*wyrd joined #nim
22:01:41FromDiscord<Schelz> So i found that winim has bind for "DEFINE_GUID" but is there a bind for "DECLSPEC_UUID" ?
22:01:52FromDiscord<Schelz> i couldn't find any
22:39:17*jjido quit (Quit: My MacBook Air has gone to sleep. ZZZzzz…)
23:11:35*acidsys quit (Excess Flood)
23:12:08*acidsys joined #nim
23:23:39FromDiscord<Ayy Lmao> Does anyone know how to get nimsuggest to work on the vscode extension? Whenever I check the `Use Nimsuggest Check` option I stop seeing errors.
23:24:14FromDiscord<Elegantbeef> Which extension are you using?
23:24:34FromDiscord<Ayy Lmao> the one from nimsaem
23:25:02FromDiscord<Elegantbeef> That setting uses `nimsuggest chk` instead of `nim check` for error reporting
23:25:20FromDiscord<Elegantbeef> Or vice versa, it doesnt really matter afaik
23:26:03FromDiscord<Ayy Lmao> I would like to use the `nimsuggest chk` setting because of this specific project that takes 5 seconds to compile.
23:26:58FromDiscord<Elegantbeef> Give me asecond to toy with it, to see if i can get it working
23:27:57FromDiscord<Ayy Lmao> In sublime text with nimlsp, it seems to show errors very quickly, but has this problem where changes in other files don't seem to be immediately visible and I have to restart the language server every time
23:34:22FromDiscord<Elegantbeef> add your file to your project settings 😛
23:34:32FromDiscord<Elegantbeef> image.png https://media.discordapp.net/attachments/371759389889003532/952348902345023570/image.png
23:34:35FromDiscord<Elegantbeef> For instance
23:34:39FromDiscord<Elegantbeef> I think that's right... could be wrong
23:35:22FromDiscord<Elegantbeef> Hmm i cannot get nimsuggest check to play nice
23:35:24nrds<Prestige99> Compiling for wasm, anyone know how to enable linking?
23:35:25FromDiscord<Elegantbeef> II take it back
23:35:30FromDiscord<Elegantbeef> It's impossible to use
23:35:49nrds<Prestige99> "To use dlopen, you need to use Emscripten's linking support"
23:36:13FromDiscord<Ayy Lmao> In reply to @Elegantbeef "It's impossible to use": hehe, have you messed around with sublime text at all?
23:36:29FromDiscord<Elegantbeef> Nope most recently i've been using kate
23:37:40FromDiscord<Ayy Lmao> I'll have to take a look at that one. I like the idea of using sublime text but the issue I'm having with nimsuggest with it is unusable.
23:38:45FromDiscord<Elegantbeef> Yea the issue with kate is the LSP has a bug with Nimlsp so no error reporting
23:40:50FromDiscord<Ayy Lmao> Well maybe when incremental compilation comes it will alleviate my issues.
23:44:16FromDiscord<Elegantbeef> Nimlsp is nimsuggest backed so what's the issue with sublime?
23:45:18FromDiscord<Ayy Lmao> If I change something in one file, it isn't reflected in other files' error messages unless I restart the language server or restart sublime text.
23:45:36FromDiscord<Elegantbeef> That means your project is dispatching mutliple LSPs
23:46:07FromDiscord<Elegantbeef> You need a config that sets up the LSP so it has a single entry into your project so only 1 server is running
23:46:37FromDiscord<Elegantbeef> Is this project public?
23:47:43FromDiscord<Ayy Lmao> I'm not sure how to do that. The project I'm working on isn't public but just imagine a source file on the top level that is using files that are in a folder next to it.
23:48:19FromDiscord<Ayy Lmao> If I change any of the files none of the other files are aware of the changes
23:48:28FromDiscord<Elegantbeef> It might just be a `config.nims` with a `--path:"myEntry.nim"`
23:48:40FromDiscord<Elegantbeef> Yes like i said multiple LSPs are running
23:48:45FromDiscord<Elegantbeef> So each file is getting it's own
23:49:40FromDiscord<Ayy Lmao> I'll try to do a config.nims and see what happens
23:55:46FromDiscord<Ayy Lmao> In reply to @Elegantbeef "It might just be": It doesn't seem to work unfortunately.
23:58:10FromDiscord<Elegantbeef> Yea i dont know how to configure it properly, perhaps pmunch is on, doubtful though
23:58:24FromDiscord<Ayy Lmao> I wonder if there's some setting somewhere to set an entrypoint. I never configured anything like that or found something that was telling me to