jhass[m] changed the topic of #ruby to: Rules: https://ruby-community.com | Ruby 3.1.2, 3.0.4, 2.7.6: https://www.ruby-lang.org | Paste 4+ lines to: https://gist.github.com | Books: https://goo.gl/wpGhoQ
jpn has joined #ruby
jpn has quit [Ping timeout: 252 seconds]
skape has quit [Quit: Connection closed for inactivity]
perrierjouet has quit [Quit: WeeChat 3.6]
Al2O3_ has quit [Quit: I'm quitting, thanks for all the sharks.]
mikecmpbll has quit [Read error: Connection reset by peer]
mikecmpbll has joined #ruby
ur5us has joined #ruby
finsternis has joined #ruby
jpn has joined #ruby
jpn has quit [Ping timeout: 268 seconds]
mdemo has quit [Ping timeout: 260 seconds]
jhass has quit [Ping timeout: 260 seconds]
John_Ivan has quit [Ping timeout: 252 seconds]
jhass has joined #ruby
donofrio has joined #ruby
kaivai has quit [Quit: ZNC - https://znc.in]
kaivai has joined #ruby
nirvdrum has joined #ruby
jpn has joined #ruby
jpn has quit [Ping timeout: 268 seconds]
kaivai has quit [Ping timeout: 252 seconds]
kaivai_ has joined #ruby
nirvdrum has quit [Quit: nirvdrum]
_ht has joined #ruby
teclator has joined #ruby
jpn has joined #ruby
jpn has quit [Ping timeout: 268 seconds]
r3m has quit [Quit: WeeChat 3.7-dev]
r3m has joined #ruby
Linux_Kerio has joined #ruby
c10l8 has joined #ruby
c10l has quit [Ping timeout: 252 seconds]
c10l8 is now known as c10l
<madprops> so to get the wait_thr i need popen3 instead of capture3 (it seems). but seems the only way to feed it stdin is wtih the callback, stdin.write(s) but now the information is not shown instantly upon starting the command
jpn has joined #ruby
jpn has quit [Ping timeout: 252 seconds]
_ht has quit [Remote host closed the connection]
Manouchehri has joined #ruby
jpn has joined #ruby
jpn has quit [Ping timeout: 252 seconds]
tonytonyjan has joined #ruby
tonytonyjan has quit [Client Quit]
tonytonyjan has joined #ruby
tonytonyjan has quit [Client Quit]
dionysus69 has joined #ruby
tonytonyjan has joined #ruby
ur5us has quit [Ping timeout: 255 seconds]
jpn has joined #ruby
Sankalp has quit [Ping timeout: 268 seconds]
Sankalp has joined #ruby
ur5us has joined #ruby
gr33n7007h has quit [Quit: WeeChat 3.6]
gr33n7007h has joined #ruby
walez has joined #ruby
jpn has quit [Ping timeout: 268 seconds]
protektwar has joined #ruby
protektwar has quit [Changing host]
protektwar has joined #ruby
protektwar has quit [Remote host closed the connection]
protektwar has joined #ruby
protektwar has quit [Changing host]
protektwar has joined #ruby
Aminda has quit [Remote host closed the connection]
Aminda has joined #ruby
protektwar has quit [Remote host closed the connection]
protektwar has joined #ruby
protektwar has quit [Changing host]
protektwar has joined #ruby
protektwar has quit [Remote host closed the connection]
Manouchehri has quit [Quit: Connection closed for inactivity]
protektwar has joined #ruby
protektwar has quit [Changing host]
protektwar has joined #ruby
jpn has joined #ruby
protektwar has quit [Remote host closed the connection]
protektwar has joined #ruby
protektwar has quit [Changing host]
protektwar has joined #ruby
protektwar has quit [Remote host closed the connection]
ur5us has quit [Ping timeout: 255 seconds]
protektwar has joined #ruby
protektwar has quit [Changing host]
protektwar has joined #ruby
yxhuvud has quit [Read error: Connection reset by peer]
yxhuvud has joined #ruby
ur5us has joined #ruby
oxfuxxx has joined #ruby
artemis has joined #ruby
oxfuxxx has quit [Ping timeout: 244 seconds]
artemis has quit [Ping timeout: 255 seconds]
protektwar has quit [Remote host closed the connection]
mikecmpbll has quit [Ping timeout: 255 seconds]
ur5us has quit [Ping timeout: 244 seconds]
walez has quit [Ping timeout: 252 seconds]
desnudopenguino has quit [Read error: Connection reset by peer]
mikecmpbll has joined #ruby
desnudopenguino has joined #ruby
ur5us has joined #ruby
ur5us has quit [Ping timeout: 244 seconds]
mdemo has joined #ruby
protektwar has joined #ruby
protektwar has quit [Changing host]
protektwar has joined #ruby
protektwar has quit [Remote host closed the connection]
protektwar has joined #ruby
protektwar has quit [Changing host]
protektwar has joined #ruby
protektwar has quit [Remote host closed the connection]
protektwar has joined #ruby
protektwar has quit [Changing host]
protektwar has joined #ruby
oxfuxxx has joined #ruby
<madprops> what's the deal with top 2 ruby extensions on vscode
<madprops> they point to the same repo
<madprops> but are made by 2 different people
<madprops> one by Peng Lv and the other by Stafford Brunk
dionysus69 has quit [Ping timeout: 252 seconds]
artemis has joined #ruby
yxhuvud has quit [Read error: Connection reset by peer]
oxfuxxx has quit [Ping timeout: 255 seconds]
yxhuvud has joined #ruby
c10l has quit [Quit: See ya! o/]
<adam12> madprops: Hard to say about your popen3 without seeing the source code.
c10l has joined #ruby
<madprops> you'd need rofi installed to check it
<adam12> madprops: What do you want to do with the output of rofi?
c10l has quit [Client Quit]
<madprops> in some cases I make it return the index, to know what item the user picked. also would need the return code. Like so (in python) https://gist.github.com/madprops/44e27f25a2b22562c0a05faf76fccc33
<madprops> adam12,
c10l has joined #ruby
artemis has quit [Ping timeout: 260 seconds]
<madprops> basically the only issue is that there's a slight delay when showing rofi in the ruby version
<madprops> as if it first loads rofi, then takes the stdin
<adam12> madprops: Do you close it after they've picked their data?
pgib has quit [Ping timeout: 252 seconds]
<madprops> yes
<madprops> the user hits enter, rofi stops and responds
<madprops> or responds and stops*
<madprops> puts stdout.read
<madprops> puts wait_thr.value.exitstatus
<madprops> i can use that to get the info
<madprops> just don't know how to fill rofi instantly like i do with my other python scripts
<madprops> there's like a 150ms delay
<adam12> I can't get rofi installed on this machine to play with it, but the strange (imho) part is having two mechanisms of stdin.
<adam12> I wonder how the Python call is handling that.
<madprops> in python my full proc line looks like:
<madprops> proc = Popen(f'{prompt} -format i {rofi_style} -selected-row {selected}', stdout=PIPE, stdin=PIPE, shell=True, text=True)
<madprops> oh it's in the gist
<adam12> Do you know if Python is making an IO pipe and then creating threads to buffer between them?
<adam12> Maybe that's unnecessary work. And it's early here, my brain might not be functioning right.
<madprops> im gonna ask in python
<adam12> Seems they are using threads.
<madprops> hmm
<adam12> I guess you could create a pipe for stdin. Pass the reader side of the pipe to popen3. Write your pre-load data into the writable side of the pipe, then spawn a thread that reads from $stdin and writes to the writable side of the buffer.
<adam12> s/buffer/pipe
<adam12> then just wait for thread exit?
<madprops> adam12, turns out it was a rofi thing. If I add the option -selected-row 0 to it, it loads instantly. Not sure why
<adam12> madprops: Weird. And everything else works as expeted?
mdemo has quit [Quit: The Lounge - https://thelounge.github.io]
<madprops> sorry my computer crashed
<madprops> after attempting to run that
<madprops> i know exitcode should be exitstatus there
<madprops> but not sure that would cause the crash
Tempesta has quit [Read error: Connection reset by peer]
Tempesta has joined #ruby
Tempesta has quit [Changing host]
Tempesta has joined #ruby
mikecmpbll has quit [Ping timeout: 255 seconds]
<adam12> madprops: I'm not sure why it would crash.
<adam12> It looks OK
dionysus69 has joined #ruby
protektwar has quit [Remote host closed the connection]
protektwar has joined #ruby
protektwar has quit [Changing host]
protektwar has joined #ruby
<madprops> tried again and it hanged as well
<madprops> but changing to another tty worked this time
<madprops> and i killed rofi
<madprops> seems this line is doing it: puts wait_thr.value.exitstatus
John_Ivan has joined #ruby
<madprops> if i remove the -selected-row option, it works ok
<madprops> probably a rofi bug
mikecmpbll has joined #ruby
jpn has quit [Ping timeout: 268 seconds]
jetchisel has quit [Ping timeout: 244 seconds]
jpn has joined #ruby
avemestr has joined #ruby
jpn has quit [Ping timeout: 268 seconds]
protektwar has quit [Ping timeout: 260 seconds]
jpn has joined #ruby
cocalero has joined #ruby
jpn has quit [Ping timeout: 255 seconds]
jpn has joined #ruby
jpn has quit [Ping timeout: 268 seconds]
jpn has joined #ruby
John_Ivan_ has joined #ruby
John_Ivan has quit [Read error: Connection reset by peer]
dionysus69 has quit [Read error: Connection reset by peer]
dionysus69 has joined #ruby
Manouchehri has joined #ruby
dionysus69 has quit [Ping timeout: 260 seconds]
bit4bit has joined #ruby
oxfuxxx has joined #ruby
artemis has joined #ruby
oxfuxxx has quit [Ping timeout: 255 seconds]
artemis has quit [Ping timeout: 252 seconds]
eddof13 has joined #ruby
keb has joined #ruby
protektwar has joined #ruby
protektwar has quit [Changing host]
protektwar has joined #ruby
<madprops> adam12, got some closure on the rofi thing. https://github.com/davatorium/rofi/discussions/1692
moldorcoder7 has joined #ruby
<adam12> madprops: ah. interesting...
cocalero has quit [Quit: Going offline, see ya! (www.adiirc.com)]
eddof13 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
eddof13 has joined #ruby
gschanuel has joined #ruby
mikecmpbll has quit [Ping timeout: 255 seconds]
jpn has quit [Ping timeout: 252 seconds]
thomas25 has joined #ruby
Rounin has joined #ruby
jpn has joined #ruby
havenwood has quit [Quit: The Lounge - https://thelounge.chat]
havenwood has joined #ruby
havenwood4 has joined #ruby
havenwood has quit [Ping timeout: 252 seconds]
havenwood4 is now known as havenwood
jpn has quit [Ping timeout: 255 seconds]
aeris has quit [Ping timeout: 258 seconds]
jpn has joined #ruby
Aminda has quit [Ping timeout: 258 seconds]
aeris has joined #ruby
Aminda has joined #ruby
nirvdrum has joined #ruby
donofrio has quit [Ping timeout: 255 seconds]
donofrio has joined #ruby
keb has quit [Quit: Leaving]
desnudopenguino has quit [Read error: Connection reset by peer]
desnudopenguino has joined #ruby
eddof13 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
eddof13 has joined #ruby
protektwar has quit [Ping timeout: 260 seconds]
nirvdrum has quit [Quit: nirvdrum]
nirvdrum has joined #ruby
Linux_Kerio has quit [Ping timeout: 252 seconds]
Al2O3 has quit [Ping timeout: 255 seconds]
jpn has quit [Ping timeout: 268 seconds]
nirvdrum has quit [Quit: nirvdrum]
Al2O3 has joined #ruby
jpn has joined #ruby
jetchisel has joined #ruby
nirvdrum has joined #ruby
nirvdrum has quit [Client Quit]
walez has joined #ruby
nirvdrum has joined #ruby
donofrio_ has joined #ruby
donofrio has quit [Ping timeout: 244 seconds]
jpn has quit [Ping timeout: 252 seconds]
_ht has joined #ruby
nirvdrum has quit [Quit: nirvdrum]
teclator has quit [Quit: http://quassel-irc.org - Chat comfortably. Anywhere.]
_ht has quit [Remote host closed the connection]
donofrio__ has joined #ruby
mikecmpbll has joined #ruby
donofrio_ has quit [Ping timeout: 244 seconds]
mikecmpbll has quit [Ping timeout: 252 seconds]
hrberg has quit [Ping timeout: 260 seconds]
jpn has joined #ruby
donofrio__ has quit [Quit: Leaving]
donofrio__ has joined #ruby
walez has quit [Ping timeout: 255 seconds]
Guest76 has joined #ruby
Guest76 is now known as ironmagma
ur5us has joined #ruby
nirvdrum has joined #ruby
ironmagma has quit [Client Quit]
jpn has quit [Ping timeout: 252 seconds]
walez has joined #ruby
oxfuxxx has joined #ruby
jimmakris has joined #ruby
jimmakris has quit [Client Quit]
artemis has joined #ruby
oxfuxxx has quit [Ping timeout: 268 seconds]
artemis has quit [Ping timeout: 268 seconds]
walez has quit [Quit: Leaving]
nirvdrum has quit [Quit: nirvdrum]
bit4bit has quit [Quit: Leaving]
perrierjouet has joined #ruby
teclator has joined #ruby
oxfuxxx has joined #ruby
eddof13 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
artemis has joined #ruby
oxfuxxx has quit [Ping timeout: 252 seconds]
artemis has quit [Ping timeout: 268 seconds]
nirvdrum has joined #ruby
teclator has quit [Quit: http://quassel-irc.org - Chat comfortably. Anywhere.]
eddof13 has joined #ruby
Rounin has quit [Ping timeout: 255 seconds]
eddof13 has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
jollyrogue[m] has joined #ruby
ur5us has quit [Ping timeout: 244 seconds]