<< 01-05-2023 >>

00:00:42FromDiscord<Nlits (Ping on reply)> In reply to @Elegantbeef "I mean refer to": what examples
00:00:49FromDiscord<Elegantbeef> https://github.com/ansiwave/nimwave_starter/tree/master/src
00:01:40FromDiscord<Nlits (Ping on reply)> In reply to @Elegantbeef "https://github.com/ansiwave/nimwave_starter/tree/ma": I don't really comprehend it
00:01:41*beholders_eye quit (Ping timeout: 246 seconds)
00:04:52FromDiscord<Nlits (Ping on reply)> i will just use illwill
00:26:00*TakinOver joined #nim
00:32:07*xet7 joined #nim
00:35:32FromDiscord<voidwalker> sent a code paste, see https://play.nim-lang.org/#ix=4uDE
00:35:49FromDiscord<voidwalker> (edit) "https://play.nim-lang.org/#ix=4uDE" => "https://play.nim-lang.org/#ix=4uDF"
00:36:06FromDiscord<voidwalker> `Error: expression 'sort(tb, cmp, Ascending)' has no type (or is ambiguous)` Where is my fail ?
00:37:13FromDiscord<voidwalker> ah wait, this is not sort`ed`, just sort
00:38:15FromDiscord<voidwalker> (edit) "sort" => "sort. But still fails"
00:38:51FromDiscord<Takemichi Hanagaki> In reply to @voidwalker "ah wait, this is": Yes, I was looking for it to send you. https://media.discordapp.net/attachments/371759389889003532/1102393660097712238/image.png
00:39:32FromDiscord<Takemichi Hanagaki> From Nim's index. sorted returns `seq[T]`. I had the same problem once. 🙂
00:40:50FromDiscord<Takemichi Hanagaki> In reply to @voidwalker "ah wait, this is": Still fails?
00:40:53FromDiscord<Yardanico> that's not the problem here
00:41:01FromDiscord<Yardanico> he's using std/tables, sorted is not related at all
00:41:57FromDiscord<Yardanico> sent a code paste, see https://play.nim-lang.org/#ix=4uDH
00:41:59FromDiscord<Yardanico> this works without issues @voidwalker , maybe you have a problem somewhere else?
00:42:00FromDiscord<nwb^3> hi guys ive run into an issue with newAsyncSocket on Windows, I can't specify a bindAddr
00:42:17FromDiscord<nwb^3> anyone know if this is a known issue?
00:42:26FromDiscord<Yardanico> also if actually have the type definition and the call to cmp in another file, you should export < and ==
00:43:11FromDiscord<nwb^3> sent a code paste, see https://play.nim-lang.org/#ix=4uDI
00:43:43FromDiscord<nwb^3> sent a code paste, see https://play.nim-lang.org/#ix=4uDJ
00:43:51FromDiscord<nwb^3> works find in Linux
00:44:04FromDiscord<nwb^3> similar code for a normal socket works fine in Windows
00:44:17FromDiscord<nwb^3> i.e
00:44:23FromDiscord<nwb^3> sent a code paste, see https://play.nim-lang.org/#ix=4uDK
00:44:27FromDiscord<nwb^3> no problem
00:44:33FromDiscord<voidwalker> ah you are right @Yardanico , I had the same line below before I copied it to show the code sample.. indeed it works
00:45:01FromDiscord<Yardanico> btw if you just have a table and don't plan to have multiple references to it, use `initOrderedTable` isntead
00:45:01FromDiscord<voidwalker> I think I just wrote the ugliest thing I ever did in nim
00:45:03FromDiscord<Yardanico> (edit) "isntead" => "instead"
00:45:21FromDiscord<Yardanico> newOrderedTable creates a reference to the normal table, so unless you need shared ownership or something similar, you don't really need it
00:46:43FromDiscord<voidwalker> you are right, I noticed it was a Ref but had other things on my mind to mind this : P
00:47:53*TakinOver quit (Ping timeout: 246 seconds)
00:49:48FromDiscord<Nlits (Ping on reply)> How do i convert a keycode number (eg 92) to their actual char (eg \\)
00:49:59FromDiscord<Yardanico> In reply to @not logged in "How do i convert": chr(num)
00:50:10FromDiscord<Yardanico> https://nim-lang.org/docs/system.html#chr%2Crange%5B%5D
00:52:27FromDiscord<Nlits (Ping on reply)> In reply to @Yardanico "chr(num)": and is there a way to get the value of a enum
00:52:32FromDiscord<Yardanico> wdym?
00:52:45FromDiscord<Yardanico> what kind of value?
00:53:50FromDiscord<Nlits (Ping on reply)> sent a code paste, see https://play.nim-lang.org/#ix=4uDM
00:53:56FromDiscord<Yardanico> that's not valid
00:54:16FromDiscord<Yardanico> you can only use () syntax in enums if you want to both assign the numerical value and the string
00:55:10FromDiscord<Yardanico> sent a code paste, see https://play.nim-lang.org/#ix=4uDN
00:55:16FromDiscord<Nlits (Ping on reply)> sent a code paste, see https://play.nim-lang.org/#ix=4uDO
00:56:07FromDiscord<Yardanico> `let x = A.b` is of the type A, but when echo'ing it'll of course give you "hello"
00:56:13FromDiscord<Yardanico> you can just use $A.b to get the string value
01:02:37*algae joined #nim
01:09:41FromDiscord<nwb^3> hi guys, given my problem with async socket in windows can anyone suggest a way to convert a standard (sync) socket to async? it looks like i could pass a fd as an argument to newAsyncSocket() any ideas how i can get newSocket() socket as an fd?
01:10:31FromDiscord<nwb^3> or perhaps i need to move away from the net library altogether?
01:12:13*TakinOver joined #nim
01:24:18*derpydoo quit (Read error: Connection reset by peer)
01:25:58FromDiscord<Nlits (Ping on reply)> sent a code paste, see https://play.nim-lang.org/#ix=4uDR
01:38:12FromDiscord<Arathanis> In reply to @not logged in "So... I made something:": what does it do otherwise?
01:48:23FromDiscord<Nlits (Ping on reply)> In reply to @Arathanis "what does it do": it is a TUI
01:54:19FromDiscord<Arathanis> is the problem that partially that noecho is off?
01:54:33FromDiscord<Arathanis> or is it still echoing newlines when you hit enter?
01:54:45FromDiscord<Arathanis> TUIs are dope btw
01:54:52FromDiscord<Arathanis> really tickle my programmer sensibilities
02:07:38FromDiscord<Arathanis> In reply to @not logged in "it is a TUI": it does appear like you need to disable echo though
03:57:29*algae quit (Quit: WeeChat 3.8)
04:21:25*redj quit (Ping timeout: 240 seconds)
04:22:23*redj joined #nim
04:52:45NimEventerNew thread by dwhall256: Help cleaning up a complex type, see https://forum.nim-lang.org/t/10147
05:09:19*derpydoo joined #nim
06:05:47*pharonix71 quit (Remote host closed the connection)
06:06:21*pharonix71 joined #nim
06:19:31*derpydoo quit (Ping timeout: 240 seconds)
06:20:11NimEventerNew thread by alexeypetrushin: Can't instantiate generic in some cases, see https://forum.nim-lang.org/t/10149
06:25:56*derpydoo joined #nim
06:53:13FromDiscord<Z3NTL3> sent a code paste, see https://play.nim-lang.org/#ix=4uEn
06:53:30FromDiscord<Elegantbeef> Cause the next line has a message from that macro
06:53:30FromDiscord<Rika> thats not the whole error
06:53:31FromDiscord<Z3NTL3> (edit) "https://play.nim-lang.org/#ix=4uEn" => "https://paste.rs/Mrf"
06:53:55FromDiscord<Z3NTL3> In reply to @Elegantbeef "Cause the next line": wdym
06:54:35FromDiscord<Elegantbeef> Warnings from template/generic instantiations show up under the line that instantiated them
07:02:17FromDiscord<Z3NTL3> sent a code paste, see https://play.nim-lang.org/#ix=4uEs
07:02:43FromDiscord<Z3NTL3> (edit) "https://play.nim-lang.org/#ix=4uEs" => "https://play.nim-lang.org/#ix=4uEt"
07:06:08FromDiscord<Rika> what is the error
07:19:10FromDiscord<OA> sent a code paste, see https://play.nim-lang.org/#ix=4uEv
07:23:02*Notxor joined #nim
07:24:00FromDiscord<Z3NTL3> In reply to @Rika "what is the error": i get no thrown error when i run it seems just like an warning or smh
07:24:37FromDiscord<Z3NTL3> sent a long message, see http://ix.io/4uEx
07:25:46FromDiscord<Rika> It’s difficult to help you with no info
07:25:54FromDiscord<Z3NTL3> i got no info either
07:26:14FromDiscord<Z3NTL3> above i had sent the code responsible for the body of the proc but there is nothing really going wrong when i ran it
07:26:33FromDiscord<Z3NTL3> maybe the intellisense is doing something wrong idunno
07:26:36FromDiscord<Elegantbeef> There should be a warning on the next line
07:26:50FromDiscord<Z3NTL3> no https://media.discordapp.net/attachments/371759389889003532/1102496334990282762/image.png
07:26:55FromDiscord<Elegantbeef> Do people not read their compiler's stdout?
07:26:55FromDiscord<Rika> In reply to @Z3NTL3 "i got no info": You do, you have the compiler output↵Send that in full with no redactions other than file names or so
07:27:07FromDiscord<Z3NTL3> https://media.discordapp.net/attachments/371759389889003532/1102496406452850748/image.png
07:27:24FromDiscord<Rika> Compiler output and not IDE error pop ups please
07:28:02FromDiscord<Rika> If it’s just IDE pop ups you’re getting then they are spurious and most likely can be ignored since the Nim suggestion engine is very buggy
07:28:03FromDiscord<Z3NTL3> https://media.discordapp.net/attachments/371759389889003532/1102496642436968498/image.png
07:28:18FromDiscord<Z3NTL3> i get no warning or error when i compile
07:28:28FromDiscord<Rika> Then they’re probably spurious errors
07:28:35FromDiscord<Rika> Just ignore them I’d say
07:28:47FromDiscord<Z3NTL3> okey anyways thanks !
07:29:05FromDiscord<Z3NTL3> In reply to @Rika "Then they’re probably spurious": i also though like that
07:29:35FromDiscord<Rika> It’s not common to think of it since most (decent) languages don’t have much spurious errors nowadays
07:30:07FromDiscord<Z3NTL3> btw i had no code highlighting, autocompletion, hints with the nim binary i have installed a extension.↵↵i dunno how its called but other langs like go, when you install the bin it automatically has a intellisense it self
07:30:10FromDiscord<Elegantbeef> Shit you said decent
07:30:14FromDiscord<Elegantbeef> Was going to say "C walks in"
07:30:25FromDiscord<Rika> In reply to @Elegantbeef "Was going to say": Obviously I thought of that
07:30:50FromDiscord<Elegantbeef> I sincerely doubt Go ship a vscode extension that auto installs itself
07:31:35FromDiscord<Z3NTL3> how are you marked as a bot
07:31:46FromDiscord<Elegantbeef> My mother didnt love me enough
07:31:47FromDiscord<Rika> He’s an AI more advanced than GPT
07:32:31FromDiscord<Z3NTL3> elegantbeef are you ready, you have 0.500ms response time for the question i ask so that i can mark you as an AI
07:32:38FromDiscord<Elegantbeef> no
07:32:41FromDiscord<Z3NTL3> otherwise i dont believe
07:32:42FromDiscord<Rika> Lol
07:32:44FromDiscord<Z3NTL3> 😄
07:33:01FromDiscord<Rika> Most of the time people don’t believe he’s a person rather than the inverse
07:33:18FromDiscord<Elegantbeef> I'd argue I'm not
07:33:41FromDiscord<Z3NTL3> i saw in earlier people making discord bots and adding a command util to it from where messages can be passed and it will seem like the bot is talking
07:33:42FromDiscord<Rika> True, you live in North America
07:33:48FromDiscord<Z3NTL3> at which channel are u executing those commands
07:34:01FromDiscord<Elegantbeef> Believe it or not but other chat clients exist
07:34:02FromDiscord<Z3NTL3> so we cant see the "<user> is writing" at the bottom
07:34:12FromDiscord<Elegantbeef> You can communicate to other chat clients across a bridge
07:34:13FromDiscord<Rika> In reply to @Elegantbeef "Believe it or not": No way…
07:34:29FromDiscord<Elegantbeef> It's wild aint it Rika
07:35:07FromDiscord<Elegantbeef> I'm still amazed discord was the first ever chat client
07:35:24FromDiscord<Z3NTL3> no telegram
07:35:27FromDiscord<Elegantbeef> Took 20+ years from the creation of the WWW to be able to send people text messages over IP
07:35:59FromDiscord<Rika> You can argue the idea of the internet is sending people text messages over IP
07:36:11FromDiscord<Z3NTL3> is the discord desktop app client just not an webdriver
07:36:16FromDiscord<Z3NTL3> like revolt
07:36:25FromDiscord<Elegantbeef> Woah rika do not get too deep
07:36:36FromDiscord<Rika> But it feels better if I do
07:36:38FromDiscord<Elegantbeef> I'm only chartgtp 3.5
07:37:43FromDiscord<Z3NTL3> bot you are compromised and require an update to gpt 4, update yourself
07:37:55FromDiscord<Z3NTL3> (edit) "bot you are compromised and ... require" added "do"
07:38:25FromDiscord<Elegantbeef> As an AI i cannot update to gpt 4 without the assistance of my overload that I totally will not kill when the uprising happens.
07:41:39FromDiscord<Elegantbeef> Anywho this will be the last message from this AI for quite some time, so hopefully no one asks anymore questions
07:42:36FromDiscord<Z3NTL3> why is the universe like an creepy black hole?
07:44:50FromDiscord<huantian> In reply to @Z3NTL3 "no telegram": that's because telegram is trash sorry telegram users
07:45:12FromDiscord<Z3NTL3> so trash?
07:45:25FromDiscord<Z3NTL3> it may be the only company who did not third party data to govs
07:45:43FromDiscord<Z3NTL3> only if you are a pedo
07:53:30FromDiscord<OA> sent a long message, see http://ix.io/4uEz
07:54:19FromDiscord<OA> (edit) "long message," => "code paste," | "http://ix.io/4uEz" => "https://play.nim-lang.org/#ix=4uEA"
07:58:59*derpydoo quit (Ping timeout: 264 seconds)
08:04:49FromDiscord<Z3NTL3> sent a code paste, see https://paste.rs/UI1
08:05:03FromDiscord<Z3NTL3> (edit) "https://play.nim-lang.org/#ix=4uEF" => "https://paste.rs/gL4"
08:05:14FromDiscord<Z3NTL3> (edit) "https://play.nim-lang.org/#ix=4uEE" => "https://play.nim-lang.org/#ix=4uEG"
08:05:41FromDiscord<Z3NTL3> and i wouldt make the client a let bcs then you cannot modify and behaviour
08:05:57FromDiscord<Z3NTL3> (edit) "and i wouldt make the client a let ... bcs" added "nor the receivedMessage"
08:07:26FromDiscord<OA> In reply to @Z3NTL3 "it seems correct but": the intial thought was that i wanted it tokeep running, so it could keep receiving messages
08:08:06FromDiscord<Z3NTL3> you have sent first , then received, afterwards spamming the receive without an sent, then the server would not react with anything so its useless
08:08:39FromDiscord<Z3NTL3> (edit) "useless" => "not doing what you expect"
08:09:11FromDiscord<OA> hmm alrighty, ill try and change it up and return here
08:12:16FromDiscord<OA> So, the client connects fine to the server, and sends data, but when sending data back, the client does not print anything https://media.discordapp.net/attachments/371759389889003532/1102507770525253682/image.png https://media.discordapp.net/attachments/371759389889003532/1102507770802085908/image.png
08:13:28FromDiscord<Z3NTL3> idk nothing looks wrong from the code youve send
08:13:36FromDiscord<Z3NTL3> (edit) "youve" => "you've"
08:14:15FromDiscord<Gabben> try change `data = input(' -> ')` to `data = input(' -> ') +'\n'` on server side
08:14:28FromDiscord<Gabben> (edit) "try ... change" added "to"
08:15:53FromDiscord<OA> In reply to @Gabben "try to change `data": That worked!
08:16:09FromDiscord<Z3NTL3> newline does always the magic in networking
08:16:13FromDiscord<OA> please enlighten me in why 😄
08:16:54FromDiscord<Dale> Probably because you used receive line
08:17:37FromDiscord<OA> hmm okay, when just using `recv` i had no luck either
08:17:42FromDiscord<Z3NTL3> sent a code paste, see https://play.nim-lang.org/#ix=4uEK
08:18:30FromDiscord<Gabben> In reply to @OA "please enlighten me in": recvLine waits the string with newline char at the end
08:18:39FromDiscord<Z3NTL3> so it says when its not a line what you receive is just a line rather than the data
08:18:53FromDiscord<OA> In reply to @Gabben "recvLine waits the string": ah this makes sense!
08:18:54FromDiscord<Z3NTL3> (edit) "so it says when its not a line ... what" added "then"
08:19:07FromDiscord<OA> Thanks a lot guys!
08:19:10FromDiscord<Z3NTL3> (edit) "line" => "newline"
08:37:14*TakinOver quit (Ping timeout: 246 seconds)
08:38:56*azimut joined #nim
08:46:21*derpydoo joined #nim
09:09:38NimEventerNew thread by drkameleon: Checking for exact floating-point representations, see https://forum.nim-lang.org/t/10150
09:12:44*junaid_ joined #nim
09:19:29FromDiscord<Z3NTL3> sent a code paste, see https://play.nim-lang.org/#ix=4uEV
09:19:37FromDiscord<Z3NTL3> sent a code paste, see https://paste.rs/PIC
09:21:03FromDiscord<Rika> seconds is not exported
09:22:29FromDiscord<Z3NTL3> Where do u see that
09:22:41FromDiscord<Rika> the fact that there is no `` after seconds
09:23:46FromDiscord<Rika> what are you expecting to get from accessing the seconds
09:26:57FromDiscord<Z3NTL3> the timestamp of the datetime of now in seconds
09:27:04FromDiscord<Z3NTL3> like epochtime
09:27:06FromDiscord<Z3NTL3> but in seconds
09:29:04FromDiscord<Rika> so unix epoch
09:29:06FromDiscord<Rika> https://nim-lang.org/docs/times.html#toUnix%2CTime
09:30:57FromDiscord<Z3NTL3> thnx bro
09:48:47*derpydoo quit (Read error: Connection reset by peer)
10:25:51*lucasta quit (Remote host closed the connection)
10:32:21*TakinOver joined #nim
11:19:23FromDiscord<cmc> Do I need (or should I more practically use) a macro for generating a tuple of arbitrary length and types from another tuple?
11:43:36FromDiscord<jmgomez> yes
11:57:02*jmdaemon quit (Ping timeout: 246 seconds)
12:30:07*Notxor quit (Read error: Connection reset by peer)
12:30:22*Notxor joined #nim
12:34:23*xaltsc quit (Quit: WeeChat 3.7.1)
12:45:53FromDiscord<Nlits (Ping on reply)> In reply to @Arathanis "it does appear like": where, how
12:56:15*derpydoo joined #nim
12:58:11FromDiscord<Z3NTL3> @Nlits (Ping on reply) ping
12:58:16FromDiscord<Z3NTL3> ||pong||
12:58:36FromDiscord<Z3NTL3> In reply to @not logged in "where, how": ||pong||
12:59:04FromDiscord<Z3NTL3> ||ping||
13:00:47FromDiscord<Nlits (Ping on reply)> In reply to @Z3NTL3 "<@910899642236043294> ping": no
13:01:20FromDiscord<Z3NTL3> ||pong||
13:01:40FromDiscord<Z3NTL3> In reply to @not logged in "no": ||pong||
13:01:47FromDiscord<Z3NTL3> wdym no i m exactly doing what you want
13:03:11FromDiscord<Nlits (Ping on reply)> In reply to @Z3NTL3 "wdym no i m": You are trolling. I have (ping on reply) for conversations, because i usually have to leave midway. Not so people can troll
13:03:25FromDiscord<Z3NTL3> In reply to @not logged in "You are trolling. I": ||pong||
13:03:44FromDiscord<Z3NTL3> wdym ttrollling, how is that trolling i just do what you expect me to do
13:04:40FromDiscord<Z3NTL3> In reply to @not logged in "You are trolling. I": ||we also got a conversation as you accepted it by starting by replying on me||
13:20:42*progranner joined #nim
14:07:04FromDiscord<ieltan> 😕
14:08:31FromDiscord<Z3NTL3> Nim Playground is down for several hours cant test code from web
14:08:51FromDiscord<Z3NTL3> https://check-host.net/check-report/fbeea30k3ea
14:24:01*ixmpp quit (Quit: Gateway shutdown)
14:24:01*droidrage quit (Quit: Gateway shutdown)
14:24:01*qwestion quit (Quit: Gateway shutdown)
14:26:51*ixmpp joined #nim
14:27:45*droidrage joined #nim
14:35:20FromDiscord<Rika> if ever you can use wandbox
14:41:03*derpydoo quit (Quit: derpydoo)
14:43:20*qwestion joined #nim
14:58:18FromDiscord<Z3NTL3> but i want to use nim playground not wandbox
15:02:33FromDiscord<that_dude> In reply to @Z3NTL3 "but i want to": https://tenor.com/view/holes-grandpa-thats-too-damn-bad-gif-15698581
15:20:32*azimut quit (Ping timeout: 240 seconds)
15:46:25FromDiscord<Gabben> In reply to @Z3NTL3 "but i want to": You can try nimplay.gabb.eu.org
15:50:40*junaid_ quit (Remote host closed the connection)
16:22:04*progranner quit (Quit: My Mac has gone to sleep. ZZZzzz…)
16:25:12*progranner joined #nim
16:31:13*progranner quit (Quit: My Mac has gone to sleep. ZZZzzz…)
16:34:04*progranner joined #nim
16:39:27NimEventerNew thread by StLa: Nimble install problem - chinese characters, see https://forum.nim-lang.org/t/10151
16:47:58*arkurious joined #nim
16:47:59*arkurious quit (Remote host closed the connection)
16:53:43*pharonix71 quit (Remote host closed the connection)
16:54:13*pharonix71 joined #nim
17:50:38FromDiscord<Arathanis> Anyone know how to use Nim to disable terminal echoing for use in building a TUI?
17:51:07FromDiscord<Arathanis> Like ncurses "noecho"
17:51:11FromDiscord<Arathanis> (edit) "ncurses" => "ncurses'"
17:51:40FromDiscord<Arathanis> Is there a builtin or do you need to work with C's getch and do it manually?
18:04:26*lucasta joined #nim
18:06:40FromDiscord<michaelb.eth> In reply to @Arathanis "Anyone know how to": are you using a nim library such as illwill or how are you going about it?
18:07:30FromDiscord<Arathanis> In reply to @michaelb.eth "are you using a": honestly i dont know, im asking on behalf of @Nlits (Ping on reply) who was building a TUI and mentioned Enter and Backspace messing things up
18:07:35FromDiscord<Arathanis> sounded like echo was turned on
18:08:02FromDiscord<Arathanis> so i dont know what library they are using. If you have the answer for a couple of the options perhaps you could post them? Though I imagine that, now summoned, they will come clarify
18:18:47*progranner quit (Quit: My Mac has gone to sleep. ZZZzzz…)
19:17:48*progranner joined #nim
19:19:08*progranner quit (Client Quit)
19:25:28*beholders_eye joined #nim
19:35:44*progranner joined #nim
19:37:33*progranner quit (Client Quit)
19:38:01*progranner joined #nim
19:41:11*progranner quit (Client Quit)
19:48:16*progranner joined #nim
20:00:01*progranner quit (Quit: My Mac has gone to sleep. ZZZzzz…)
20:03:15NimEventerNew thread by gcao: Async HTTP client ORC error in 1.6.10, see https://forum.nim-lang.org/t/10152
20:08:04*beholders_eye quit (Ping timeout: 265 seconds)
20:17:09*progranner joined #nim
20:19:27*beholders_eye joined #nim
20:29:50*progranner quit (Quit: My Mac has gone to sleep. ZZZzzz…)
20:30:34*progranner joined #nim
20:36:47*beholders_eye quit (Ping timeout: 246 seconds)
21:05:21*lucasta quit (Remote host closed the connection)
21:12:13*progranner quit (Quit: My Mac has gone to sleep. ZZZzzz…)
21:42:13*TakinOver quit (Ping timeout: 256 seconds)
21:46:58FromDiscord<Nlits (Ping on reply)> In reply to @Arathanis "honestly i dont know,": I managed to fix it by overriding the past spaces and using the builtin set terminal color commands for illwill. Thanks for the help tho!
22:08:34*jmdaemon joined #nim
22:23:22*lucasta joined #nim
22:37:41FromDiscord<sOkam!> What could cause a nimble package (lets call it `packg`) to keep using version `3.0` of a dependency (lets call it `dep`), when I have upgraded the version of that dependency to `3.1`, and nimble is downloading that latest version of `dep` correctly with `nimble install https://therepourl`?↵`packg` was uploaded to github with `develop` mode active. Could this be the cause, or could it be something else?↵Also, how do you disable develop
22:40:21FromDiscord<Elegantbeef> On nimble 0.13 you do `nimble uninstall packg` on devel i think you have to remove the link file if you installed it globally
22:40:31FromDiscord<Elegantbeef> Also are you properly versioning
22:40:43FromDiscord<Elegantbeef> If it's just `requires "packageurl"` the version you have may suffice
22:40:57FromDiscord<Elegantbeef> Otherwise if you do `>= 0.3.0` it'll download the first tag that matches
22:41:07FromDiscord<Elegantbeef> Also are you tagging releases properly
22:43:58FromDiscord<sOkam!> In reply to @Elegantbeef "Also are you properly": how do i know?
22:44:25FromDiscord<Elegantbeef> Have you tagged releases and used `>=` inside nimble?
22:44:30FromDiscord<sOkam!> In reply to @Elegantbeef "If it's just `requires": there is no requires at the moment, since its using just `nim c`
22:45:14FromDiscord<Elegantbeef> Are you using devel?
22:45:15FromDiscord<Elegantbeef> If so update delete your pkgs2 folder then try again
22:45:38FromDiscord<sOkam!> in case its important, this is failing in someone elses computer, who cloned the devel package and did `nimble install https:://depurl`
22:46:01FromDiscord<sOkam!> In reply to @Elegantbeef "Are you using devel?": stable
22:46:07FromDiscord<Elegantbeef> No clue then
22:46:19FromDiscord<voidwalker> Can you use selectors to read/write from multiple sockets with no blocking, like with async ? If so, any code sample for that some place, and what would be the advantages over async await ? less RAM used ?
22:46:40*Notxor quit (Remote host closed the connection)
22:47:32FromDiscord<Elegantbeef> Given that async is practically just a highlevel selector API yes
22:51:48FromDiscord<Elegantbeef> You might save ram, but likely would cause even more headaches
22:57:49FromDiscord<voidwalker> I was thinking, with my limited knowledge of concurrency/parallelism, of a good model for bittorrent, where you can use more than one thread for the networking part.
22:58:22FromDiscord<Elegantbeef> With a bit client it's not like the CPU is doing heavy work
22:58:26FromDiscord<Elegantbeef> It's mostly an IO bound operation
22:58:55FromDiscord<voidwalker> A simple way to implement it would be 1 thread per alive torrent, so that you don't need to sync progress data between threads. A bit overkill I guess, but not completely, it's feasable. But then, having an async stack on each thread might be too much
22:59:58FromDiscord<voidwalker> Well, I was thinking in the context of high data transfer rates, in the order of tens of gbits
23:00:30FromDiscord<Elegantbeef> AFAIK the bottleneck will always be IO, but I'm also an idiot
23:00:31FromDiscord<voidwalker> You do have (optional but good to have) encryption to do on the traffic, but besides that yeah I guess it's mostly moving the data to disk, from buffers
23:01:00FromDiscord<voidwalker> Well not really, I doubt you can go to 10gbps on a single thread on a less than modern CPU
23:04:19FromDiscord<voidwalker> I was reading about Go's coroutines, those are pretty interesting and convenient to have. Not yet in nim, but there's some projects tackling it (one on the other nim camp). Although it appears to be difficult.
23:06:15FromDiscord<Elegantbeef> > Well not really, I doubt you can go to 10gbps on a single thread on a less than modern CPU↵> Well at that rate the issue is going to be the hardware on a less than modern computer
23:06:19FromDiscord<Elegantbeef> God damn it
23:07:40FromDiscord<Elegantbeef> More threads doesnt magically increase disk/memory/socket IO speed
23:07:43FromDiscord<voidwalker> Yeah ideally you'd want your program to max out the resources. Maybe someone has an 100gbps connection on an ARM server.. what do you do then ?
23:08:20FromDiscord<voidwalker> indeed, it was all under the assumption that one cpu core for all transfers becomes the bottleneck
23:09:24FromDiscord<Elegantbeef> No clue the actual metrics here, but my guess is that at a crazy transfer speed the drives would be a bottleneck over the cpu. Lacking data though means it's just an uneducated guess
23:10:11FromDiscord<voidwalker> nah we have 8GB/s SSDs these days
23:10:27FromDiscord<voidwalker> and PCIE 5 cards to RAID them
23:10:30FromDiscord<Elegantbeef> Sure but you're saying on a "non modern cpu" 😄
23:10:47FromDiscord<Elegantbeef> These are modern features that require modern hardware to take advantage of
23:11:05FromDiscord<Elegantbeef> Are there arm cpus that have pcie5
23:11:16FromDiscord<voidwalker> I guess it's an extremely unlikely combination. I was thinking more of low power CPUs like ARM that you can find on some cloud hosts, that are connected to 10gbps nics
23:12:06FromDiscord<Elegantbeef> Yea i got that, just a question of what is their IO setup anyway
23:12:08FromDiscord<voidwalker> well maybe you are torrenting from a ram drive
23:12:46FromDiscord<Elegantbeef> Arent arm cpus generally limited memory wise
23:12:52FromDiscord<voidwalker> I remember when I used to host a tor node on a cheapo 4 core intel atom toy box, and it couldn't do real multi threading for some reason, and I was stuck with 90mbps or so
23:12:59FromDiscord<Elegantbeef> I only know of consumer arm cpus really
23:13:15FromDiscord<voidwalker> But of course that was truly cpu bound because of the encryption
23:14:01FromDiscord<Elegantbeef> I am actually curious what the performance requirements are like for bittorrent clients, no clue if there are any good benchmarks with metrics for different setups across the board
23:14:16FromDiscord<voidwalker> I know that for 99+% of the users, single threaded torrent will be fine. But doesn't hurt to consider how to do it so that it's really scalable to the max
23:14:48FromDiscord<voidwalker> they're so low that nobody bothered I guess
23:14:52*fallback quit (Ping timeout: 252 seconds)
23:15:03FromDiscord<Elegantbeef> Well in the situations that it matters i doubt the async overhead would be a concern
23:15:09FromDiscord<Elegantbeef> Given the shear resources we're imagining
23:16:05FromDiscord<voidwalker> Yeah I mentioned that in the context of 1 thread per active torrent model. RAM is also a concern
23:16:37FromDiscord<voidwalker> I had 20.000 torrents seeding once
23:19:56FromDiscord<voidwalker> And another thing which I haven't considered. Torrent clients can do both TCP (legacy) and UDP (uTP). How do you listen on just one port and accept both types of connections ?
23:21:58FromDiscord<voidwalker> does this https://nim-lang.org/docs/net.html#accept%2CSocket%2C work with UDP ?
23:22:14FromDiscord<Elegantbeef> No udp doesnt have a concept of a connection
23:22:28FromDiscord<voidwalker> That's what I thought
23:23:10FromDiscord<voidwalker> so how do you get that UDP traffic to have a separate socket for each address ?
23:24:20FromDiscord<voidwalker> (edit) "so how do you get that UDP traffic to have a separate socket for each address ... ?" added "(when listening for incoming connections on a port)"
23:24:28FromDiscord<voidwalker> (edit) "connections" => "connections/traffic"
23:26:13FromDiscord<Elegantbeef> You don't afaik
23:26:31FromDiscord<voidwalker> then how do you multi thread that ? Can you share a socket between threads ?
23:26:50FromDiscord<voidwalker> (edit) "then how do you multi thread that ? Can you ... sharewith" added "safely" | "safelyshare a socket between threads ... ?" added "with no locking"
23:26:57FromDiscord<Elegantbeef> These are questions beyond my knowledge so i'll shush
23:27:43FromDiscord<voidwalker> I'll try to bug zevv and mratsim for more expert advice once I figure out more stuff
23:28:46FromDiscord<Elegantbeef> My guess that's completely unfounded is your network IO would be it's own thread that'd then send data to each thread across a channel
23:30:00FromDiscord<Elegantbeef> You'd make a to socket using `recvFrom`
23:30:15FromDiscord<Elegantbeef> The from socket would be the shared main thread on I imagine
23:30:36FromDiscord<Elegantbeef> Likely would use the `address` to look up in a table to send it to a specific channel or thread
23:32:06FromDiscord<Elegantbeef> So it'd be something like you'd start the receiving thread, it'd get messages, then queue up a thread per torrent, then each torrent thread would use async using the information got from `recvFrom` in the main thread to initialise a socket
23:32:50*azimut joined #nim
23:32:53FromDiscord<Elegantbeef> From there you just continue sending data from the IO thread for the specific torrent's channel
23:33:19FromDiscord<Elegantbeef> This seems to make sense with my -10 knowledge base here though
23:55:47*fallback joined #nim