havenwood changed the topic of #ruby to: Rules: https://ruby-community.com | Ruby 3.2.1, 3.1.3, 3.0.5, 2.7.7: https://www.ruby-lang.org | Paste 4+ lines to: https://gist.github.com | Books: https://t.ly/9ua4 | Logs: https://libera.irclog.whitequark.org/ruby/
ur5us has quit [Ping timeout: 260 seconds]
Linux_Kerio has quit [Ping timeout: 255 seconds]
Grapto42 has joined #ruby
unintr39 has quit [Ping timeout: 268 seconds]
wand has quit [Remote host closed the connection]
Grapto42 has quit [Ping timeout: 248 seconds]
wand has joined #ruby
ur5us has joined #ruby
wand has quit [Remote host closed the connection]
wand has joined #ruby
siery has quit [Ping timeout: 252 seconds]
ur5us has quit [Remote host closed the connection]
ur5us has joined #ruby
ur5us has quit [Ping timeout: 255 seconds]
siery has joined #ruby
ur5us has joined #ruby
CrazyEddy is now known as Myrtales
ur5us has quit [Ping timeout: 255 seconds]
<yosileyid> Im connecting a bot via ruby, it is connecting but when I use the bot.join(roomName) it says the server disconnects me, how do I look into what is causing that?
<yosileyid> im connecting it in irb currently to test what is causing the issue
Tempesta has quit [Quit: See ya!]
___nick___ has quit [Quit: https://quassel-irc.org - Chat comfortably. Anywhere.]
<leftylink> hm. I guess if I were presented with this situation I'd look at the IRC protocol and see what messages the bot is sending to the server and receiving back
ur5us has joined #ruby
___nick___ has joined #ruby
___nick___ has quit [Client Quit]
___nick___ has joined #ruby
ur5us has quit [Ping timeout: 260 seconds]
Tempesta has joined #ruby
wmoxam has quit [Ping timeout: 255 seconds]
wmoxam has joined #ruby
moldorcoder7 has quit [Ping timeout: 248 seconds]
razetime has joined #ruby
MalusVulgaris has joined #ruby
wand has quit [Ping timeout: 255 seconds]
wand has joined #ruby
razetime has quit [Ping timeout: 268 seconds]
siery has quit [Ping timeout: 255 seconds]
hololeap has quit [Ping timeout: 255 seconds]
hololeap has joined #ruby
razetime has joined #ruby
razetime1 has joined #ruby
razetime has quit [Ping timeout: 248 seconds]
razetime1 is now known as razetime
razetime1 has joined #ruby
razetime has quit [Ping timeout: 255 seconds]
razetime1 is now known as razetime
<yosileyid> leftylink: it wasnt connecting due to no ssl for some reason
<yosileyid> probably because I specified port 6697, but I got it fixed and it loaded up
razetime has quit [Ping timeout: 255 seconds]
razetime has joined #ruby
jhass has quit [Ping timeout: 268 seconds]
jhass has joined #ruby
razetime has quit [Quit: See You Space Cowboy]
AlexBrownSobinec has joined #ruby
Sankalp has quit [Ping timeout: 255 seconds]
shokohsc61 has joined #ruby
shokohsc6 has quit [Ping timeout: 248 seconds]
shokohsc61 is now known as shokohsc6
AlexBrownSobinec has quit [Quit: Client closed]
AlexBrownSobinec has joined #ruby
Sankalp has joined #ruby
razetime has joined #ruby
AlexBrownSobinec has quit [Quit: Client closed]
Starfoxxes has quit [Ping timeout: 246 seconds]
MalusVulgaris has quit [Quit: MalusVulgaris]
panella32 has joined #ruby
panella32 has quit [Client Quit]
panella32 has joined #ruby
<gridbugsmasher42> Ruby is fun
ur5us has joined #ruby
tomtmym has joined #ruby
tomtmym has quit [Changing host]
tomtmym has joined #ruby
ur5us has quit [Ping timeout: 260 seconds]
ur5us has joined #ruby
razetime has quit [Ping timeout: 268 seconds]
dionysus69 has joined #ruby
dionysus69 has quit [Quit: dionysus69]
panella32 has quit [Ping timeout: 268 seconds]
razetime has joined #ruby
ur5us has quit [Ping timeout: 260 seconds]
ur5us has joined #ruby
<yosileyid> fr
teclator has joined #ruby
infinityfye has joined #ruby
tomtmym has quit [Quit: Gone.]
Linux_Kerio has joined #ruby
CoolerX has joined #ruby
<CoolerX> Hi
<CoolerX> I am having an issue while trying to build a bottle for a homebrew formula
<CoolerX> Error: undefined method `path' for nil:NilClass
<CoolerX> Some issues online suggest updating xcode https://github.com/rbenv/ruby-build/issues/1434
<CoolerX> xcode-select version 2395.
<CoolerX> I think it's already up to date
<CoolerX> brew doctor only reports 1 warning
<CoolerX> Warning: Putting non-prefixed coreutils in your path can cause GMP builds to fail.
<CoolerX> The error from brew bottle seems to be in this file /usr/local/Homebrew/Library/Homebrew/formula_versions.rb:25:in `initialize'
pvalenta has quit [Quit: ZNC - https://znc.in]
pvalenta has joined #ruby
_ht has joined #ruby
_ht has quit [Client Quit]
_ht has joined #ruby
_ht has quit [Client Quit]
_ht has joined #ruby
_ht has quit [Remote host closed the connection]
_ht has joined #ruby
<CoolerX> is anyone here?
jvalleroy has quit [Quit: https://quassel-irc.org - Chat comfortably. Anywhere.]
jvalleroy has joined #ruby
ur5us has quit [Ping timeout: 255 seconds]
<sam113101> I am
<CoolerX> on this line https://github.com/Homebrew/brew/blob/8051e8818a4fdcbad0a71ea27a1eb5bc17ade88b/Library/Homebrew/formula_versions.rb#L25 I am getting an error saying Error: undefined method `path' for nil:NilClass
<leftylink> well, it's probably it's rude to answer when you don't know the answer, so people don't want to be rude
<leftylink> I would start from the fact that https://github.com/Homebrew/brew/blob/8051e8818a4fdcbad0a71ea27a1eb5bc17ade88b/Library/Homebrew/formula.rb#L99-L102 says "If it's `nil`, then this formula is loaded from a path or URL." and go from there.
teclator has quit [Ping timeout: 248 seconds]
<Shell> CoolerX: the tap for that formula is nil. why? who knows. :)
<CoolerX> Shell: uh, which formula?
<sam113101> what's tap?
<CoolerX> it's not a formula, it's just a ruby script
<Shell> CoolerX: the Homebrew formula object.
<Shell> CoolerX: look, if you print out what formula.tap is at that point, it's nil. that's what the error says.
<CoolerX> Shell: ok that makes sense but why is it nil? that code is part of the homebrew tool
<Shell> CoolerX: I think there's a Homebrew IRC channel that is more likely to be able to answer that question.
<CoolerX> if there was a huge bug like that my brew would probably stop working
<CoolerX> nah, there's noone there really
<CoolerX> I did ask there
<Shell> email Mike McQuaid? :)
<CoolerX> Shell: have you ever built a custom formula?
<CoolerX> I have a custom formula that I am trying to build locally
<CoolerX> it's been working so far for all my previous versions, I was using homebrew 3.6.16
<CoolerX> but now Homebrew updated to v4
<CoolerX> brew bottle --force-core-tap --json --root-url='..........' ./path/to/my/formula@1.2.3.rb
<CoolerX> That's how I am building the bottle
<sam113101> what's a bottle? like a package?
<CoolerX> yes
<Shell> sam113101: a bottle is a binary package, as opposed to a formula which is a source package.
<Shell> iirc
<Shell> it's been years since I cared about this. :)
<CoolerX> Shell: how do I find the code that is responsible for setting .tap ?
<leftylink> well, https://github.com/Homebrew/brew/blob/8051e8818a4fdcbad0a71ea27a1eb5bc17ade88b/Library/Homebrew/formula.rb says it's an attr_reader, so you look for any code that looks like `@tap = ...` .
<sam113101> there's no difference between latest version and 3.6.16
<CoolerX> This condition is triggered
<CoolerX> and I am using the --force-core-tap flag to keep going since it's a local formula that I am building
<CoolerX> so yes .tap is nil
<CoolerX> tap = CoreTap.instance
<Shell> CoolerX: I don't know.
<CoolerX> maybe they need one more line f. tap = CoreTap.instance
<CoolerX> f.tap = CoreTap.instance
<CoolerX> "Formula not from core or any installed taps" I do have my custom tap installed
<Shell> email Mike McQuaid, if there's no other place you can get help with Homebrew's core code, he's probably got an idea.
<CoolerX> so I am not sure why it says that
<sam113101> because tap is nil, obviously
<sam113101> what's a tap?
<Shell> if you have your custom tap installed, you should be able to reference your formula by name, not by path to a Ruby file. that will probably fix the problem.
<CoolerX> a tap is a repo
<leftylink> huh. I guess everyone has their own unique ways of dealing with vampires. interesting
<CoolerX> sam113101: it's a personal repo
<CoolerX> of formulae
<CoolerX> Shell: well the tap is installed but the formula is a new one I just created
<CoolerX> maybe I should ptu the tap name in the formula
<Shell> then the formula is not in the tap.
<CoolerX> yeah because I just created it
<CoolerX> Shell: I am going to add it to the tap
<CoolerX> it says that "If it's `nil`, then this formula is loaded from a path or URL."
<CoolerX> and also it's a private field so Idk if I can specify it in my child class
ollysmith has quit [Quit: ZNC 1.8.2+deb3+b4 - https://znc.in]
<CoolerX> Shell: so it's supposed to be nil
* Shell puts channel on quiet
ollysmith has joined #ruby
teclator has joined #ruby
<CoolerX> "The format #<...> tells you that this object is not a simple thing like a number, string, or array. Instead, it just tells you the name of the class, Calculator, and the internal id that Ruby has assigned to this object.
<CoolerX> "
<CoolerX> inspect is supposed to print as close as possible to the original code that created the object right?
<CoolerX> but when I puts myfilepath.inspect I get something like #<Pathname:/aaaa/bbbbbbb/cccccc>
<leftylink> pandabot ri Object#inspect
<leftylink> as that says.
nmollerup has joined #ruby
razetime has quit [Remote host closed the connection]
teclator has quit [Ping timeout: 248 seconds]
<CoolerX> Hi
<CoolerX> seems to be from a custom CLI argument parser
<CoolerX> but I don't see where to_resolved_formulae is defined
<CoolerX> I think args.named refers to the arguments that come after the flags https://github.com/Homebrew/brew/blob/8051e8818a4fdcbad0a71ea27a1eb5bc17ade88b/Library/Homebrew/dev-cmd/bottle.rb#L93
<CoolerX> positional arguments
<leftylink> `git grep` can do wonders.
<CoolerX> Thanks
<CoolerX> Error: undefined method `path' for nil:NilClass
<CoolerX> They are getting the same error
infinity_fye has joined #ruby
infinityfye has quit [Ping timeout: 248 seconds]
Starfoxxes has joined #ruby
CoolerX has quit [Ping timeout: 248 seconds]
infinityfye_ has joined #ruby
infinityfye_ is now known as infinityfye
infinity_fye has quit [Ping timeout: 255 seconds]
amvara has joined #ruby
<amvara> Hi there ... I receive a LoadError when installing redmine plugin ... details: https://paste.debian.net/1273005/ ... any help with this is appreciated, as I am a total newby to Ruby
siery has joined #ruby
c10l7 has quit [Quit: See ya! o/]
wand has quit [Remote host closed the connection]
c10l7 has joined #ruby
wand has joined #ruby
Guest12 has joined #ruby
Guest12 has left #ruby [#ruby]
shiru has joined #ruby
TomyLobo has joined #ruby
CoolerX has joined #ruby
AlexBrownSobinec has joined #ruby
<CoolerX> Hi
shiru has quit [Quit: leaving]
<leftylink> Kernel#caller for finding out where something is called
MalusVulgaris has joined #ruby
joast has quit [Quit: Leaving.]
<AlexBrownSobinec> Guys, is there any lib to make ruby interact with python? I just need to make a little part of my ruby program in python but I need to transfer dome vars. Does anybody have a solution?
<siery> IPC c:? Other then that, idk
shokohsc66 has joined #ruby
shokohsc6 has quit [Ping timeout: 248 seconds]
shokohsc66 is now known as shokohsc6
MalusVulgaris has quit [Quit: MalusVulgaris]
<leftylink> right, it sounds like something that wouldn't have a dedicated library because the general purpose library such as open3 or Kernel#` would do the job equally well
tomtmym has joined #ruby
tomtmym has quit [Changing host]
tomtmym has joined #ruby
<amvara> Question about gems ... gem list | grep matrix shows 0.4.2 is installed. bundle show matrix returns: "Could not find gem 'matrix'." ... what am I missing on?
shokohsc6 has quit [Ping timeout: 264 seconds]
<amvara> Found the answer: added matrix to local Gemfile and did bundle install ...
horsec97 has joined #ruby
CoolerX has quit [Ping timeout: 248 seconds]
shokohsc6 has joined #ruby
Vonter has quit [Quit: WeeChat 3.8]
gridbugsmasher42 has left #ruby [#ruby]
teclator has joined #ruby
Vonter has joined #ruby
CoolerX has joined #ruby
gr33n7007h has quit [Ping timeout: 248 seconds]
gr33n7007h has joined #ruby
<adam12> ox1eef_: I just set up a ChatGPT account because I was curious.
CoolerX has quit [Ping timeout: 255 seconds]
<adam12> leah2: I tried your question, and it worked, but who knows if ChatGPT is hallucinating it to me or not :P https://gist.github.com/adam12/9d73965898da7f2fb9ea9425f7667aea
AlexBrownSobinec has quit [Ping timeout: 260 seconds]
CoolerX has joined #ruby
<leah2> well
<leah2> not exactly what i meant :)
horsec97 has quit [Ping timeout: 252 seconds]
<nickjj> besides setting a custom error message when would you prefer to use ENV.fetch with a 2nd arg to define a default vs using a block to define a default?
<nickjj> example: ENV.fetch("COOL", true) vs ENV.fetch("COOL") { true }
nonpas80 has joined #ruby
<leftylink> oh I have an idea. since the block is only run if the key doesn't exist, you use a block if it's expensive to compute. for example, ENV.fetch('USER', sleep 5) will always sleep 5, but ENV.fetch('USER') { sleep 5 } won't.
<nickjj> leftylink, ah that makes a lot of sense, i didn't think the first one would evaluate if USER existed but it sounds like it does?
<leftylink> of course. function arguments are always evaluated before the function is called.
<nickjj> thanks, when you you think about it like that, it makes sense -- for some reason i thought it may have short circuited somehow
<nickjj> this is where premature optimization is also the root of all evil because it begs to ask if defining a block that's not executed is faster or slower than evaluating something "simple" like a default string or boolean
<nickjj> because it almost sounds like it always makes sense to use a block
AlexBrownSobinec has joined #ruby
<nickjj> i ran it through Benchmark and when setting a string as a default value the block version is consistently twice as fast but we're also talking 0.000005 vs 0.000012
teclator has quit [Ping timeout: 248 seconds]
hightower2 has quit [Remote host closed the connection]
<Momentum> any suggestion for a title slugification gem?
Linux_Kerio has quit [Read error: Connection reset by peer]
factor has joined #ruby
Linux_Kerio has joined #ruby
<leah2> for ENV, ENV[key] || slowfn works the same
wand has quit [Ping timeout: 255 seconds]
wand has joined #ruby
factor has quit [Remote host closed the connection]
factor has joined #ruby
factor has quit [Remote host closed the connection]
<AlexBrownSobinec> I made a ChatGPT IRC bot lmao
moldorcoder7 has joined #ruby
<Momentum> does the API allow that?
<Momentum> isn't it limited?
<AlexBrownSobinec> I gonna add the cooldown for 1 minute
<AlexBrownSobinec> Also
<AlexBrownSobinec> If i gonna make random choice from multiple tokens
<AlexBrownSobinec> THis can help me
AlexBrownSobinec has quit [Ping timeout: 260 seconds]
niv has quit [Ping timeout: 260 seconds]
niv has joined #ruby
c10l7 has quit [*.net *.split]
siery has quit [*.net *.split]
Sankalp has quit [*.net *.split]
wmoxam has quit [*.net *.split]
CharleyBates has quit [*.net *.split]
jmcgnh has quit [*.net *.split]
micro has quit [*.net *.split]
bougyman has quit [*.net *.split]
miah has quit [*.net *.split]
rapha has quit [*.net *.split]
depesz has quit [*.net *.split]
cornett has quit [*.net *.split]
ralu1 has quit [*.net *.split]
leftylink has quit [*.net *.split]
sol has quit [*.net *.split]
PedroG1 has quit [*.net *.split]
scottg489 has quit [*.net *.split]
siery has joined #ruby
c10l7 has joined #ruby
wmoxam has joined #ruby
Sankalp has joined #ruby
CharleyBates has joined #ruby
rapha has joined #ruby
micro has joined #ruby
depesz has joined #ruby
bougyman has joined #ruby
cornett has joined #ruby
scottg489 has joined #ruby
sol has joined #ruby
ralu1 has joined #ruby
leftylink has joined #ruby
miah has joined #ruby
PedroG1 has joined #ruby
ralu1 has quit [Max SendQ exceeded]
scottg489 has quit [Max SendQ exceeded]
c10l7 has quit [Max SendQ exceeded]
bougyman has quit [Max SendQ exceeded]
micro has quit [Max SendQ exceeded]
micro has joined #ruby
scottg489 has joined #ruby
bougyman has joined #ruby
ralu1 has joined #ruby
c10l7 has joined #ruby
ur5us has joined #ruby
AlexBrownSobinec has joined #ruby
CoolerX has quit [Ping timeout: 256 seconds]
joast has joined #ruby
jmcgnh has joined #ruby
tomtmym has quit [Quit: Gone.]
AlexBrownSobinec has quit [Quit: Client closed]
CoolerX has joined #ruby
CoolerX has quit [Client Quit]
___nick___ has quit [Ping timeout: 255 seconds]
szkl has joined #ruby
_ht has quit [Remote host closed the connection]
infinityfye has quit [Read error: Connection reset by peer]
teclator has joined #ruby
gr33n7007h has quit [Ping timeout: 256 seconds]
gr33n7007h has joined #ruby
ruby[bot] has quit [Remote host closed the connection]
ruby[bot] has joined #ruby
quazimodo has joined #ruby
nonpas80 has quit [Ping timeout: 248 seconds]