Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
  • 06:41
    pepe commented #683
  • 02:34
    sogaiu commented #683
  • 02:28
    sogaiu commented #683
  • 01:57
    crocket commented #683
  • 01:33
    crocket commented #683
  • 00:18
    uvtc commented #683
  • Apr 15 23:18
    andrewchambers commented #683
  • Apr 15 23:13
    sogaiu commented #683
  • Apr 15 19:58
    bakpakin closed #682
  • Apr 15 19:58

    bakpakin on master

    Fix #682 - Don't hardcode size … (compare)

  • Apr 15 16:03
    uvtc commented #683
  • Apr 15 04:20
    sogaiu commented #683
  • Apr 15 04:10
    pyrmont commented #683
  • Apr 15 03:54
    crocket edited #683
  • Apr 15 03:53
    crocket opened #683
  • Apr 15 00:18
    bakpakin closed #678
  • Apr 12 19:11
    littleli commented #533
  • Apr 12 12:56
    sogaiu opened #116
  • Apr 12 01:28
    bakpakin labeled #682
  • Apr 11 00:13
    DEADB17 edited #682
pp
@damnpepe:matrix.org
[m]
yep, I am doing it in my webserver to refresh the templates
but again I can be totally not understanding at all :-)
Saikyun
@Saikyun
@pp I'd have to try it :) I don't know how modules/cache works. one main issue is that when using import normally, all names are thrown away, and iiuc even when using import :fresh, you have to also re-evaluate the defn-calls using the functions you depend on
if I had to wager a guess, the modules/cache-part will solve a similar problem as import :fresh true, but I wonder if it will solve the "thrown away names" problem
I'll try it later and get back to you :)
thanks for the info
pp
@damnpepe:matrix.org
[m]
oh I am going to speculate (import :fresh true) is doing that module/cache thing :-)
so no help probably
Saikyun
@Saikyun
still, good to know about modules/cache, I had no idea :)
so thanks again
pp
@damnpepe:matrix.org
[m]
you are welcome! yumaikas- brought it to my attention not that long ago (just in time I needed them)
Saikyun
@Saikyun
@pyrmont as you say, those are two different problems :) for me, it's all about being able to reload "namespaces". in my case, I have a render loop in main.janet, and it depends on various files. in those files I want to make changes and have them come through to the render loop. wrt: evaluating in different environments -- an environment and/or fiber per netrepl connection might make sense? :) not sure what problem you want to solve
Michael Camilleri
@pyrmont
@damnpepe: Perhaps you might know the answer to this question. If you have a stream created by net/connect, is there a way to check whether there's anything to read in the stream?
pp
@damnpepe:matrix.org
[m]
to read it is only way I know of
Michael Camilleri
@pyrmont
And that consumes it, right?
pp
@damnpepe:matrix.org
[m]
it does yes
Michael Camilleri
@pyrmont
Hmmm.
pp
@damnpepe:matrix.org
[m]
but I do not see scenario, where it could be problem
can you please share yours (as you seem disapointed 😀
Michael Camilleri
@pyrmont
I'm trying to test various things with a stream to a netrepl connection from an ordinary REPL. I have two functions, recv and send which read from and write to the stream respectively. The problem is that if I read from the stream when there's nothing there, it will block.
pp
@damnpepe:matrix.org
[m]
yes, but with the ev it is not that big problem?
in my mental model I tied ev and net as tight as my old mind allowes
Michael Camilleri
@pyrmont
Well, I'm in the REPL and I don't see anyway to cancel the blocking. I guess I could tweak the recv function to have a timeout.
pp
@damnpepe:matrix.org
[m]
that is other way around indeed
Michael Camilleri
@pyrmont
The problem is that I'm using spork/msg to create the receiver (and the sender) and the make-recv and make-send functions don't have the capacity to do timeouts.
I guess those functions aren't exceptionally complicated so I could just tweak them.
pp
@damnpepe:matrix.org
[m]
yep
Saikyun
@Saikyun
@pyrmont do you have a specific example for repling / blocking problem?
don't know if it will help you, but this is how I manage to get netrepl + loop to work together: https://github.com/Saikyun/text-experiment/blob/main/src/main.janet#L217-L235
the ev/sleep call makes it so that the netrepl gets a chance to do its thing :)
when thinking about it, a generator might have been cleaner, haha. anyway :)
Michael Camilleri
@pyrmont
I've got it working now :)
I'm running the netrepl server in a separate process so it's OK for recv to block, just not indefinitely :)
Saikyun
@Saikyun
ah right, in my case I couldn't run netrepl in a separate process / thread, due to having to run raylib calls on main thread
Michael Camilleri
@pyrmont
Ah. Yeah, I'm just trying to play around with some of the stuff that I helped add to run-context and spork/netrepl.
I was trying to get Conjure to work with it but I am not having much luck and am trying to see if something's broken in the implementation (I don't think it is but wanted to double check).
pp
@damnpepe:matrix.org
[m]
lol
dogfooding
Michael Camilleri
@pyrmont
Well, sort of :)
More like bearpoking :P
pp
@damnpepe:matrix.org
[m]
😀
no danger I would say
not from Janet codes, they are helpful only
Michael Camilleri
@pyrmont
Or like that scene in 80s action movies where they have to cut the right wire to defuse the bomb while the wrong wire will explode.
pp
@damnpepe:matrix.org
[m]
oh the adventures of SW development
why it was funny for me: I finished Chidi, very proud father. Then I put it to work in the good-place website and found a lot of the rough edges
some parts got total overhaul
Michael Camilleri
@pyrmont
Yeah, this is not acting the way that I expected.
Which is a bit weird because it runs OK when testing.
pp
@damnpepe:matrix.org
[m]
one of the famous last sentences 🙂