<FunkyBob>
heh... snuck a link to the Pony tutorial into a twitter convo about how "Go solved the interaces problem" ...
jemc has quit [Ping timeout: 260 seconds]
nyarum has joined #ponylang
amclain has quit [Quit: Leaving]
nyarum has quit [Remote host closed the connection]
plietar has quit [Remote host closed the connection]
plietar_ has joined #ponylang
jemc has joined #ponylang
dougmacdoug has joined #ponylang
<dougmacdoug>
@jemc i was able to get zmq to compile using 0.12 .. is zmq compatible with other languages// trying to talk to a nodejs app..
aav has quit [Read error: Connection reset by peer]
aav has joined #ponylang
gmcabrita has quit [Quit: Connection closed for inactivity]
jemc has quit [Ping timeout: 260 seconds]
jemc has joined #ponylang
<jemc>
dougmacdoug: it's supposed to be compatible, yes - and I have tested it against the reference in libzmq in the past
<dougmacdoug>
cannot figure out how to use it yet
<dougmacdoug>
i only found one code use online and it is evidently old because there is no more bind method on socket, so just trying to cobble together a server
<jemc>
which socket type are you trying to set up? REQ/REP?
<jemc>
which language is the REQ and which is the REP?
<dougmacdoug>
rep.. using bind
<dougmacdoug>
rep in pony req in nodejs
<dougmacdoug>
connect seems to wait to connect, but I was having other errors with it, switched to bind and now it just exits.. assuming I am missing something
<jemc>
can you paste somewhere what you have so far?
<jemc>
I'll use it as the starting place for adding an example to the codebase
<dougmacdoug>
hrmm.. about 50 lines of _env.out.print("nope..")
<dougmacdoug>
also, fyi, last night i tried to compile with 0.11, 0.10. 0.13, 0.14 in that order.. all failed with different errors (actually 13 and 14 had same error)..
<dougmacdoug>
then I tried 0.12 and it compiled..
<jemc>
yeah, the compiler/language/stdlib has been changing pretty rapidly - I'll push up a patch to make it work with latest master right now
<dougmacdoug>
so I actually just got a message . but only one.. is there something i need to do at the end of receive() to get another message? (ack or something)
<jemc>
with the REQ/REP pattern in ZeroMQ, it's required that you send a response before you can get a new request
<jemc>
I just finished writing up a simple echo server and client REQ/REP example, and am pushing it now
<jemc>
if you have questions, or pain points, please let me know - I plan to eventually circle back and refine the API a bit in some places, though in others I'm quite proud of the ease of use
<dougmacdoug>
ah, peer.send, was doing socket.send..
<dougmacdoug>
also, for whatever reason, with my node client, the first string in the message is empty
<dougmacdoug>
but, the really cool news is that I am able to run an electron app (its what runs VS.code and atom) that spawns my pony server and sends UI inputs back.. nice
<dougmacdoug>
thanks for the help and the cool zmq ..
smoon has joined #ponylang
dougmacdoug has quit [Quit: Page closed]
endformationage has quit [Quit: WeeChat 1.7]
wintermoo has joined #ponylang
smoon has quit [Quit: smoon]
jemc has quit [Ping timeout: 246 seconds]
plietar_ has quit [Remote host closed the connection]
plietar has joined #ponylang
plietar has quit [Ping timeout: 246 seconds]
nyarum has joined #ponylang
wintermoo has quit [Remote host closed the connection]
wintermoo has joined #ponylang
wintermoo has quit [Ping timeout: 268 seconds]
nyarum has quit [Remote host closed the connection]
nyarum_ has joined #ponylang
nyarum_ has quit [Remote host closed the connection]
wintermoo has joined #ponylang
nyarum has joined #ponylang
fluttershy_ has joined #ponylang
<fluttershy_>
Hello, I can't understand errors in this code, can someone take a look please ? https://is.gd/Qywn2M
wintermoo has quit [Remote host closed the connection]
wintermoo has joined #ponylang
wintermoo has quit [Ping timeout: 246 seconds]
nyarum has quit [Remote host closed the connection]
wintermoo has joined #ponylang
gmcabrita has joined #ponylang
plietar has joined #ponylang
<wintermoo>
fluttershy_: not sure if it helps, but you cant assign to an element in a tuple, like you do in the try block in findMinMax
nyarum has joined #ponylang
<wintermoo>
theres also a typo in normalize (line 20): findminMax should be findMinMax
<wintermoo>
that stops the backtrace for me at least
<wintermoo>
finally, lines 23 and 24 dont make sense. you cant divide by max._1 == max._2 etc
<wintermoo>
max._1 == min._1
abbiya has joined #ponylang
aedigix has quit [Remote host closed the connection]
aedigix has joined #ponylang
<wintermoo>
fluttershy_: this works: https://is.gd/WrhpeN . you'll have to change lines 20 and 21 so that the else expression is correct (i.e. not plus)
<wintermoo>
the backtrace occured when the compiler tried looking up the case insensitive id of findMinMax, which it didnt manage to do properly (seems like it found a case insensitive match, but didnt get the correct token id). probably a bug!
wintermoo has quit [Remote host closed the connection]
wintermoo has joined #ponylang
wintermoo has quit [Ping timeout: 246 seconds]
plietar has quit [Remote host closed the connection]
plietar has joined #ponylang
plietar has quit [Ping timeout: 240 seconds]
wintermoo has joined #ponylang
_andre has joined #ponylang
<fluttershy_>
wintermoo: thank you, that was so helpful, I could't see the typo because the error given by the compiler wasn't easy for me to understand.
<wintermoo>
yeah, compiler crashes can be hard to debug! you should maybe post it as an issue on github, so someone can take a look at fixing it!
abbiya has quit [Remote host closed the connection]
papey_lap has quit [Quit: WeeChat 1.7.1]
papey_lap has joined #ponylang
<fluttershy_>
wintermoo: ok I'll.
plietar has joined #ponylang
papey_lap has quit [Quit: WeeChat 1.8]
papey_lap has joined #ponylang
nyarum has quit [Remote host closed the connection]
dougmacdoug has joined #ponylang
wintermoo has quit [Remote host closed the connection]
wintermoo has joined #ponylang
jemc has joined #ponylang
wintermoo has quit [Ping timeout: 246 seconds]
nyarum has joined #ponylang
nyarum has quit [Ping timeout: 246 seconds]
nyarum has joined #ponylang
nyarum has quit [Remote host closed the connection]
nyarum has joined #ponylang
graaff has joined #ponylang
amclain has joined #ponylang
fluttershy_ has quit [Quit: Page closed]
nyarum has quit [Remote host closed the connection]
graaff has quit [Quit: Leaving]
HoloIRCUser1 has joined #ponylang
darach has quit [Ping timeout: 258 seconds]
darach has joined #ponylang
plietar has quit [Remote host closed the connection]
plietar has joined #ponylang
plietar has quit [Ping timeout: 240 seconds]
TheLemonMan has joined #ponylang
Matthias247 has joined #ponylang
nyarum has joined #ponylang
vaninwagen_ has joined #ponylang
<vaninwagen_>
hi, good evening! :) i am puzzled by this behaviour: https://is.gd/qVk1wc
<vaninwagen_>
i have a class with a ref method. i have a ref field to an instance of this class in my Main. calling this ref method from within the constructor of Main is fine, but i get errors when calling it from a method of Main
Matthias247 has quit [Read error: Connection reset by peer]
<vaninwagen_>
if i refer to my ref field in the constructor of Main, everything is fine
nyarum has quit [Remote host closed the connection]
<SeanTAllen>
sorry, what is the problem vaninwagen_ ?
nyarum has joined #ponylang
<vaninwagen_>
SeanTAllen can you access this playground snippet https://is.gd/qVk1wc ?
<SeanTAllen>
o i see your problem
<vaninwagen_>
i am not able to call a "ref" method on a "ref" field of actor Main
<SeanTAllen>
blubb is a "box" not a "ref"
<SeanTAllen>
so that isnt going to compile
<SeanTAllen>
this.. " fun blubb(): String =>"
<SeanTAllen>
means that it can be called with a ref or a val
<SeanTAllen>
so its not allowed to mutate thing
<SeanTAllen>
if you want to call a ref method from inside that it needs to be a ref like