Only one line will load. Need all lines in directory to load.

2023-03-19 Thread jyapayne
Try out your idea and see what happens :)

My Nim Development Weekly Report (3/19)

2023-03-19 Thread ringabout
## Progress ### Checks the potential errors with closure calls [fixes #19857; Exception raised in closure may be "skipped" in ORC](https://github.com/nim-lang/Nim/pull/21530). ### Adds a prepass for codeReordering [add a prepass for codeReordering](https://github.com/nim-lang/Nim/pull/21513).

Only one line will load. Need all lines in directory to load.

2023-03-19 Thread Naterlarsen
I think a for loop when requesting from server can be sent back to the client for the number of need loops and then run a for loop on the with the incoming data for that number of times. Example code: import os echo "Please enter a directory path > " let input_dir_path

Only one line will load. Need all lines in directory to load.

2023-03-19 Thread Naterlarsen
Thanks, I will give it a try. Hopefully I can come up with something effective. Appreciate your help.

Only one line will load. Need all lines in directory to load.

2023-03-19 Thread jyapayne
@Naterlarsen `recvLine()` is a blocking call. That means that while message != "": echo message message = client.recvLine() Run will keep going as long as the client is sending it messages. As soon as those run out, you're stuck in `message = client.recvLin

Only one line will load. Need all lines in directory to load.

2023-03-19 Thread Naterlarsen
I have fix the problem of just getting one line but its cause a different problem. I used a while loop to get all the lines, however, now I am knocked out of the original loop and loose the ability to continue making other requests. UPDATED CODE that gets multiple lines but looses ability to ma

Do you miss these compact syntaxes?

2023-03-19 Thread xigoi
Meh, that seems less readable than `if increment: count.incr`.

Do you miss these compact syntaxes?

2023-03-19 Thread ElegantBeef
It's not builtin, but I'll shill it to get more usage and to better it.

Do you miss these compact syntaxes?

2023-03-19 Thread ElegantBeef
See if we're talking only conditionally incrementing an integer we already have this wonderful `count += ord(increment)`.

Only one line will load. Need all lines in directory to load.

2023-03-19 Thread sls1005
I think @jyapayne's right. It prints only one line because that's all it received from `recvLine()`, before printing it out and start another iteration. Don't take my previous suggestion.

/usr/lib/nim/lib/system.nim

2023-03-19 Thread tmsa04
I use install.sh and it was working for me last time I tried, don't know how it will be after the directory changes though. When you get a prebuilt package from here: then you can extract it somewhere and run "sudo sh install.sh /opt" then "cd /usr/loca

Only one line will load. Need all lines in directory to load.

2023-03-19 Thread jyapayne
@Naterlarsen it's because the client is only receiving one message from the server and then waiting for input from the user. Can you figure out what to do based on that information?

Do you miss these compact syntaxes?

2023-03-19 Thread Hlaaftana
Postfix if, unless keyword etc are all borrowed from Perl where code was supposed to look like English, like `say "this" if true` This doesn't really work otherwise imo and `if increment: count += 1` is one of the cleanest ways to write what it does in any language I've seen

Only one line will load. Need all lines in directory to load.

2023-03-19 Thread sls1005
Try socket = newSocket(buffered=false) Run

Background tasks in jester

2023-03-19 Thread sdmcallister
Thanks for pointing out `after`. I honestly haven't seen this before and missed it when looking throught the tests.

Do you miss these compact syntaxes?

2023-03-19 Thread alexeypetrushin
> I used it for some years in Ruby Yes, all the syntaxes in the post, are not imagined but borrowed from Ruby and CoffeeScript. > I would also like to have some kind of built-in pattern matching syntax. Yes, I would like to have it too.

Do you miss these compact syntaxes?

2023-03-19 Thread Stefan_Salewski
# Postfix if count += 1 if increment` Run I was not aware of that term, but I used it for some years in Ruby. And actually it is very nice in rare situations. In German language, we say "ruf mich mal an, wenn du etwas Zeit hast", or "besuch mich mal wieder, wenn du in d

Do you miss these compact syntaxes?

2023-03-19 Thread didlybom
I am personally very happy with Nim's syntax in general. If I could add something it would probably be a better way to define sum types. I find the current Object Variant syntax too verbose and complicated. I would also like to have some kind of built-in pattern matching syntax.

/usr/lib/nim/lib/system.nim

2023-03-19 Thread shirleyquirk
No apologies necessary, I’m very happy with this change. koch tools doesn’t make dochack for me A quick search through koch.nim and I can’t find dochack anywhere. Instead, ‘getDocHackJs’ in compiler/nimpaths.nim seems to compile it if it doesn’t exist

design question: generic methods are deprecated

2023-03-19 Thread noah
i ended up just moving the type alias into the object type ParseType* = Config | JsonNode type base* = ref object of RootObj parsed*: ParseType Run

Background tasks in jester

2023-03-19 Thread ThomasTJdev
What is in your `sendText()` proc? Do you call it with `asyncCheck sendText()`? What @gs suggest, or go further and create a microservice where you can pass the info to through e.g. redis. If it's okay that the blocking persist after the user received the response, then you can use jesters `aft