ChanServ changed the topic of #picolisp to: PicoLisp language | Channel Log: https://irclog.whitequark.org/picolisp/ | Check also http://www.picolisp.com for more information
orivej has quit [Ping timeout: 246 seconds]
orivej has joined #picolisp
orivej has quit [Ping timeout: 256 seconds]
orivej has joined #picolisp
orivej has quit [Ping timeout: 260 seconds]
<tankf33der> Morning all
<tankf33der> Regenaxer: would you like add llvm 7* menation in INSTALL file?
<tankf33der> llvm7+
<Regenaxer> Hi tankf33der!
<Regenaxer> yes, but add exactly what?
<Regenaxer> llvm7+ ?
<Regenaxer> You mean mentioning that LLVM must be 7 or greater?
<tankf33der> Yeap
<Regenaxer> Is it still below 7 on Ubuntu 18?
<tankf33der> i think so.
<Regenaxer> hmm, but anyway the problem will go away soon ;)
<Regenaxer> 7 is very old
<Regenaxer> What if we check in Makefile?
<tankf33der> Sometines llvm-config is not part of llvm packege, but llvm-tools or utils
<Regenaxer> ok, I see
<tankf33der> Then you should run clang -v and check first lines
<Regenaxer> 'sysdefs' generates it
<Regenaxer> it goes to the first line of @lib/sysdefs
<tankf33der> Make sense.
<Regenaxer> Let's just wait a little
<Regenaxer> 7 will disappear soon ;)
<tankf33der> You will get something new someday, i can imagine they break api in llvm14
<Regenaxer> You think so? Why should they break it?
<tankf33der> Because they did it llvm7
<Regenaxer> Did they break anything? I thought they just extended
<Regenaxer> upwards compatible
<Regenaxer> memcpy()
<tankf33der> They removed param in builtin functions.
<Regenaxer> not good
<tankf33der> Yea, in general noone cares because they dont sit on raw llvm-ir
<Regenaxer> The compiler writers *do* care
<Regenaxer> lots of languages
<Regenaxer> If this happens in the future, @src/lib/llvm.l can check the version
<tankf33der> Llvm do all job
<Regenaxer> Not sure
<Regenaxer> There is tHe C++ API
<Regenaxer> for language developers
<Regenaxer> Nobody does like Pil though, generate IR directly, I think
<tankf33der> Fight above to support llvm7+ versions
<Regenaxer> So future changes *might* be handled in @src/lib/llvm.l
<Regenaxer> Let's see what happens
<Regenaxer> but I think we should just ignore 7 for now
<tankf33der> when this will happen you have to find langref for llvm14 and compare
<Regenaxer> What do you mean?
<Regenaxer> if eg memcpy changes, I need to handle both calls
<tankf33der> This link for master latest llvm, but you dont sit on latest
<tankf33der> every branch they own link to langref and llvm 14 will have too
<Regenaxer> I have not looked a while, yes. What changed?
<tankf33der> For example when llvm14 will break something link above could be different from llvm14’s langref documentation
<Regenaxer> hmm, can we discuss later? I'm very busy atm
<Regenaxer> deadline
<tankf33der> sure.
<Regenaxer> thanks
<tankf33der> Push for text tabkf33der dont work sny
<tankf33der> Ping me by text tankf33der dont work anymore.
<Regenaxer> We cant ping you here in IRC by nickname?
<tankf33der> Not anymore
<Regenaxer> different irc client?
<tankf33der> yea, completely different infrastucture
<tankf33der> ping by deltachat is fastest
<Regenaxer> ok, good
rob_w has joined #picolisp
<tankf33der> Now i am using https://thelounge.chat/
<tankf33der> Via envs.net infrastructure. Main feature - always connected. And i dont need always keep browser open on irccloud to keep session active.
<Regenaxer> Nice
orivej has joined #picolisp
_whitelogger has joined #picolisp
casaca has quit [*.net *.split]
Nistur has quit [*.net *.split]
casaca has joined #picolisp
Nistur has joined #picolisp
rob_w has quit [Ping timeout: 246 seconds]
<tankf33der> calling curl as https client and reading from pipe
<tankf33der> sometimes exits with error
<tankf33der> (23) Failed writing body
<beneroth> curl has an argument to enable a log into a file
<beneroth> maybe turn this on, and on success you delete the log file afterwards, on fail you keep it to inspect
<beneroth> e.g. use --stderr option
rob_w has joined #picolisp
<beneroth> or if you can replicate, use --verbose to get more details
<beneroth> <tankf33der> (23) Failed writing body
<tankf33der> cant repeat on latest, installing debian
<beneroth> first find out if that refers to the body when sending (when you do HTTP POST) or reading the response
<beneroth> I have an API client which uses curl wrapped in pil, I always let the HTTP body/response go into a file with the "-o" output option
<tankf33der> *sometimes* it faails
<beneroth> and then I read & validate the output file in a next step
<beneroth> (maybe a bit slower, but more resilient and easier to debug)
<beneroth> (performance didn't matter so much in my use case, as the other end was faulty and slow anyway)
<beneroth> hmm
<beneroth> I'd guess it's not handling of expected error response but pipe timing issue
<beneroth> I mean something like 'curl writes into the pipe buffer faster than pil reads"... should only block then and continue when there is space, but well..
<beneroth> if performance is not critical, I would let curl output into a file and then read the file
<beneroth> man curl says at the end
<beneroth> " 23 Write error. Curl couldn't write data to a local filesystem or similar."
<beneroth> sounds like that fits with my guess
<beneroth> you probably could optimize the performance while using an -o output-file if you create this file previously as a unix/linux fifo-file
<tankf33der> while true; do pil21 nestping.l -https && sleep 1 && echo "next"; done
<tankf33der> this loop works for hours without errors
<beneroth> ok
<beneroth> then I know
<beneroth> I guess then it fails if you leave the sleep 1 away, right?
<beneroth> you create/close too many pipes in short time
<tankf33der> but fails once under crontab, running hourly.
<tankf33der> i just receiving error mail from cron once a day
<beneroth> hmm
<tankf33der> others 23 runs are ok
<beneroth> must be some weird thing with the pipes
<tankf33der> anyway pil21 works under latest debian.
<beneroth> great!
<beneroth> I've gotta go :\
<beneroth> bbl
beneroth has quit [Quit: Leaving]
mmmattyx has joined #picolisp
<Regenaxer> Perhaps "Failed writing body" means a pipe error?
<Regenaxer> Exiting the while loop while curl still writes to the pipe
<Regenaxer> If so, curl should ignore SIGPIPE, not sure if there is an option
rob_w has quit [Remote host closed the connection]
emacsoma1 has quit [Quit: WeeChat 3.0]
emacsomancer has joined #picolisp
<tankf33der> It fails only sometimes, not always
<Regenaxer> yes, race condition
<Regenaxer> two processes in the pipe
<Regenaxer> the reader finishes before the writer
<Regenaxer> perhaps exits because it finds a result early in th data
<Regenaxer> Or curl hangs for a moment for some reason
<Regenaxer> kernel buffers are also involved
<Regenaxer> afp
beneroth has joined #picolisp
<tankf33der> $ 1
<tankf33der> also i could do this.
<Regenaxer> ret
<Regenaxer> yes, search for deadbeef
<Regenaxer> To find out if the above is really a pipe error, either strace curl, or let the loop finish all input and just remember the result
<tankf33der> Good this is not pil21 problem
<Regenaxer> On the other hand I never had a pipe problem with curl
<Regenaxer> Probably not pil, right
<Regenaxer> it cannot do anything to the curl process
<tankf33der> Thanks.
<beneroth> Regenaxer, I managed to overuse (in 'lst)
<Regenaxer> oh, overuse? :)
<beneroth> called (in 'lst) in a function which was very often called, repeatedly in short time, resulted in use of too many pipes
<beneroth> kinda-fixed by adding a (wait 1) or something like that, to give time (to the kernel I assume) to clean up the pipes
<beneroth> ugly
<beneroth> :)
<Regenaxer> hehe, pil64
<beneroth> T
<Regenaxer> pil21 has no such limit
<Regenaxer> but still, 'in' waits for the child upon close
<Regenaxer> you started all in parallel?
<beneroth> no, sequential
<Regenaxer> strange
<Regenaxer> hmm, yeah
<Regenaxer> the sigchild signal appears later
<Regenaxer> async from the kernel
<Regenaxer> So I recommend pil21 ;)
<beneroth> how is this different in pil21?
<Regenaxer> it uses poll() instead of select()
beneroth_ has joined #picolisp
beneroth has quit [Ping timeout: 256 seconds]
beneroth_ has quit [Quit: Leaving]
beneroth has joined #picolisp
mmmattyx has quit [Quit: Connection closed for inactivity]
<Regenaxer> German government says we must do more home office? I wonder how I can do that.
<tankf33der> Latvia prolonged till 7.feb
<Regenaxer> here at least 15th
<Regenaxer> (I was kidding. In home office all my life)
Seteeri has joined #picolisp
<beneroth> same here, homeoffice is now a must as much as possible
<beneroth> before it was a recommendation, and sometimes employees were not allowed to work in homeoffice even when they requested their company
* beneroth still strongly believes that priority 1 focus should be on scaling up testing & tracing
mmmattyx has joined #picolisp