<gray-_-wolf>
Hello, quick question: does bundler support other transport protocols beside http(s)? For example, I would like to use it with S3 (pull gems from S3). Is that possible?
jenrzzz has quit [Ping timeout: 240 seconds]
jenrzzz has joined #ruby
crankharder has quit [Ping timeout: 240 seconds]
jenrzzz has quit [Ping timeout: 240 seconds]
akem has joined #ruby
znz_jp has quit [Remote host closed the connection]
duderonomy has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
MalkbabY_ has joined #ruby
znz_jp has joined #ruby
MalkbabY has quit [Ping timeout: 240 seconds]
bonhoeffer has quit [Ping timeout: 258 seconds]
<weaksauce>
gray-_-wolf not natively i don't think
ur5us has quit [Remote host closed the connection]
ur5us has joined #ruby
Arahael has joined #ruby
jenrzzz has joined #ruby
jenrzzz has quit [Ping timeout: 265 seconds]
crankharder has quit [Ping timeout: 240 seconds]
jenrzzz has joined #ruby
jenrzzz has quit [Ping timeout: 240 seconds]
jenrzzz has joined #ruby
crankharder has joined #ruby
jenrzzz has quit [Ping timeout: 260 seconds]
crankharder has quit [Ping timeout: 260 seconds]
jenrzzz has joined #ruby
duderonomy has joined #ruby
akem has quit [Ping timeout: 240 seconds]
akem has joined #ruby
jenrzzz has quit [Ping timeout: 265 seconds]
gix has quit [Ping timeout: 240 seconds]
howdoi has quit [Quit: Connection closed for inactivity]
jenrzzz has joined #ruby
jenrzzz has quit [Ping timeout: 268 seconds]
jenrzzz has joined #ruby
ChmEarl has quit [Quit: Leaving]
jenrzzz has quit [Ping timeout: 252 seconds]
andremedeiros has quit [Quit: ZNC 1.8.2 - https://znc.in]
andremedeiros has joined #ruby
jenrzzz has joined #ruby
alexherbo2 has quit [Ping timeout: 240 seconds]
jenrzzz has quit [Ping timeout: 260 seconds]
cd has quit [Quit: cd]
ur5us has quit [Ping timeout: 258 seconds]
m27frogy has quit [Ping timeout: 240 seconds]
shtirlic_ has joined #ruby
jetchisel has joined #ruby
shtirlic has quit [Ping timeout: 265 seconds]
jenrzzz has joined #ruby
ur5us has joined #ruby
jenrzzz has quit [Ping timeout: 252 seconds]
jenrzzz has joined #ruby
Furai has quit [Quit: WeeChat 3.1]
neshpion has quit [Quit: neshpion]
<nakilon>
how to write "class << self ; attr_accessor :x ; end" in a single line? the self.attr_accessor throws an error
jenrzzz has quit [Ping timeout: 268 seconds]
Furai has joined #ruby
robotbee has quit [Ping timeout: 252 seconds]
MalkbabY has joined #ruby
MalkbabY_ has quit [Ping timeout: 240 seconds]
purple_lotus has joined #ruby
<purple_lotus>
Hi! I've got an instance method whose last three lines look like this: `val = { foo: :bar, boo: 42 } \n @values << val \n val` Is there a way to condense that down to one line? I'd ideally like to do something along the lines of: `@values.append { foo: :bar, boo: 42 }` (but Array#append doesn't return the appended value of course)
jenrzzz has joined #ruby
jenrzzz has quit [Ping timeout: 252 seconds]
<nakilon>
purple_lotus val.tap{ @values << val }
<purple_lotus>
nice
patr0clus has joined #ruby
<purple_lotus>
yep, that worked perfectly. thanks!
<drusepth>
I understand this is a terrible thing to do but is there any (hacky) way to pass params to a method without comma-delimiting them? for example, foo(x y) instead of foo(x, y)
robotbee has joined #ruby
<drusepth>
context: just exploring oddities of the language while hacking together a dsl for inline tests, right now I'm doing `tested def method(blah); stuff(); end, tests do; tests(); end; ... but I'd really love to not need that comma after end
<nakilon>
I feel like you copypasted something wrong here
<drusepth>
ah yeah, was just trying to hand-wave vague code, here's the actual syntax i'm working with currently: https://dpaste.org/AKPJ
<drusepth>
basically just trying to make it a little less weird by potentially scrapping the , after the method definition's end (though tbh i don't know if that'd actually be less weird, mostly just curious at how it could possible even be done)
<drusepth>
possibly*
blackmesa has joined #ruby
MalkbabY has quit [Remote host closed the connection]
nofxx has quit [Read error: Connection reset by peer]
nofxx has joined #ruby
DaRock has joined #ruby
KeyJoo has joined #ruby
gearnode has joined #ruby
blackmesa has joined #ruby
jla has quit [Ping timeout: 240 seconds]
al2o3-cr has quit [Read error: Connection reset by peer]
al2o3-cr has joined #ruby
KeyJoo has quit [Ping timeout: 260 seconds]
Jonopoly has joined #ruby
Theora[m] has quit [Quit: Idle for 30+ days]
StarOnD has joined #ruby
<NL3limin4t0r_afk>
nakilon: I'm not sure if `attr_accessor` is a private method, but if it isn't you can use `singleton_class.attr_accessor :x`
NL3limin4t0r_afk is now known as NL3limin4t0r
ur5us has joined #ruby
<NL3limin4t0r>
It seems to work using Ruby 2.6.5 on my machine.
jla has joined #ruby
StarOnD has quit [Quit: Connection closed]
drusepth has quit [Ping timeout: 240 seconds]
Jonopoly has quit [Quit: WeeChat 3.0.1]
vondruch has quit [Ping timeout: 240 seconds]
TCZ has joined #ruby
ur5us has quit [Ping timeout: 258 seconds]
MalkbabY has joined #ruby
shtirlic has joined #ruby
MalkbabY has quit [Ping timeout: 252 seconds]
shtirlic_ has quit [Ping timeout: 240 seconds]
m27frogy has joined #ruby
shtirlic has quit [Ping timeout: 265 seconds]
greengriminal has joined #ruby
shtirlic has joined #ruby
baojg has quit [Remote host closed the connection]
baojg has joined #ruby
shtirlic has quit [Ping timeout: 246 seconds]
shtirlic_ has joined #ruby
alexherbo2 has joined #ruby
dviola has quit [Ping timeout: 265 seconds]
stryek has joined #ruby
StarOnD has joined #ruby
shtirlic_ has quit [Ping timeout: 260 seconds]
shtirlic has joined #ruby
gawlinski has quit [Ping timeout: 240 seconds]
gawlinski has joined #ruby
shtirlic has quit [Ping timeout: 240 seconds]
shtirlic has joined #ruby
crankharder has joined #ruby
crankharder has quit [Ping timeout: 252 seconds]
TCZ has quit [Quit: Do nothing unless you must, and when you must act -- hesitate.]
AndreYuhai has joined #ruby
<AndreYuhai>
Hey there, in my RSpec how can I expect the response to have some css or xpath?
<AndreYuhai>
When I do expect(response.body).to have_css I get an error saying:
<AndreYuhai>
expected #<ActionDispatch::TestResponse:0x00000001370a9618 @mon_data=#<Monitor:0x00000001370a95a0>, @mon_data_..._revalidate=>true}, @request=#<ActionDispatch::Request GET "http://www.example.com/" for 127.0.0.1>> to respond to `has_selector?`
cd has joined #ruby
<AndreYuhai>
have_css instead of 'has_selector?' *
<AndreYuhai>
Or I think another way of asking would be, how can I find an xpath on a response body in RSpec?
<AndreYuhai>
Because response.body basically returns a String with HTML
<AndreYuhai>
Normally I would parse with Nokogiri but not sure whether there's an easy way in RSpec
StarOnD has quit [Ping timeout: 240 seconds]
jla has quit [Ping timeout: 240 seconds]
MalkbabY has joined #ruby
ChmEarl has joined #ruby
MalkbabY has quit [Ping timeout: 240 seconds]
elcuervo has quit [Read error: Connection reset by peer]
elcuervo has joined #ruby
crankharder has joined #ruby
crankharder has quit [Client Quit]
lockweel has joined #ruby
Rudd0 has quit [Ping timeout: 240 seconds]
lockweel has quit [Read error: Connection reset by peer]
TeDChange has quit [Ping timeout: 248 seconds]
TeDChange has joined #ruby
lockweel has joined #ruby
AndreYuhai has quit [Quit: Lost terminal]
AndreYuhai has joined #ruby
<AndreYuhai>
I am using RVM, and have changed my Ruby version from 2.7.2 to 2.7.3 in Gemfile. Why didn't RVM pick up the changes from the Gemfile?
<AndreYuhai>
I've got a few branches
<AndreYuhai>
when I do rvm use it still uses 2.7.2
<AndreYuhai>
At first it had picked up the changes and had changed to 2.7.3 but then it kept using 2.7.2 somehow, I don't know why.
lockweel has quit [Quit: Leaving]
lockweel has joined #ruby
ejjfunky has joined #ruby
camilasan_ has quit [Remote host closed the connection]
vondruch has joined #ruby
<AndreYuhai>
when doing bundle install I am getting this error:
<AndreYuhai>
An error occurred while installing nokogiri (1.11.2), and Bundler cannot continue.
camilasan_ has joined #ruby
<AndreYuhai>
Make sure that `gem install nokogiri -v '1.11.2' --source 'https://rubygems.org/'` succeeds before bundling.
<AndreYuhai>
How and where (in which folder) am I supposed to write that?
nofxx has quit [Ping timeout: 240 seconds]
cthulchu_ has joined #ruby
ejjfunky has quit [Ping timeout: 240 seconds]
MalkbabY has joined #ruby
jla has joined #ruby
gigetoo has quit [Ping timeout: 265 seconds]
MalkbabY has quit [Ping timeout: 240 seconds]
Rounin has quit [Ping timeout: 240 seconds]
blackmesa has quit [Ping timeout: 240 seconds]
alexherbo20 has joined #ruby
alexherbo20 is now known as alexherbo2
alexherbo2 has quit [Ping timeout: 240 seconds]
AndreYuhai has quit [Quit: Lost terminal]
alexherbo20 has joined #ruby
alexherbo20 is now known as alexherbo2
gearnode has quit [Ping timeout: 252 seconds]
gearnode has joined #ruby
dhollinger has joined #ruby
KeyJoo has joined #ruby
dviola has joined #ruby
dviola has quit [Changing host]
dviola has joined #ruby
jla has quit [Ping timeout: 252 seconds]
vondruch has quit [Quit: vondruch]
Rudd0 has joined #ruby
vondruch has joined #ruby
bukkitgerman8608 has quit [Read error: Connection reset by peer]
bukkitgerman8608 has joined #ruby
supercoven has joined #ruby
supercoven has quit [Max SendQ exceeded]
supercoven has joined #ruby
robotbee has joined #ruby
DaRock has quit [Ping timeout: 268 seconds]
jla has joined #ruby
TCZ has joined #ruby
MalkbabY has joined #ruby
MalkbabY has quit [Ping timeout: 252 seconds]
blackmesa has joined #ruby
jla has quit [Ping timeout: 268 seconds]
blackmesa has quit [Ping timeout: 258 seconds]
blackmesa has joined #ruby
blackmesa has quit [Ping timeout: 258 seconds]
blackmesa has joined #ruby
Rudd0 has quit [Ping timeout: 240 seconds]
andremedeiros has quit [Read error: Connection reset by peer]
andremedeiros has joined #ruby
goepsilongo has joined #ruby
jla has joined #ruby
TCZ has quit [Quit: oh eh ah]
reyfi9e has joined #ruby
blackmesa has quit [Quit: WeeChat 3.1]
roshanavand_ has joined #ruby
TomyLobo has joined #ruby
roshanavand__ has joined #ruby
TomyWork has quit [Quit: Leaving]
roshanavand_ has quit [Ping timeout: 240 seconds]
ua has quit [Read error: Connection reset by peer]
NL3limin4t0r is now known as NL3limin4t0r_afk
jla has quit [Ping timeout: 265 seconds]
patr0clus has joined #ruby
gix has joined #ruby
ua has joined #ruby
al2o3-cr has quit [Ping timeout: 240 seconds]
TCZ has joined #ruby
MalkbabY has joined #ruby
MalkbabY has quit [Ping timeout: 240 seconds]
baojg has quit [Remote host closed the connection]
baojg has joined #ruby
TorpedoSkyline has quit [Ping timeout: 260 seconds]
splud has quit [Quit: Leaving]
splud has joined #ruby
Rounin has joined #ruby
splud has quit [Client Quit]
splud has joined #ruby
MalkbabY has joined #ruby
dviola has quit [Quit: WeeChat 3.1]
dviola has joined #ruby
Iarfen has joined #ruby
Jello_Raptor has quit [Remote host closed the connection]
drusepth has joined #ruby
MalkbabY has quit [Remote host closed the connection]
MalkbabY has joined #ruby
KeyJoo has quit [Ping timeout: 268 seconds]
MalkbabY has quit [Ping timeout: 252 seconds]
neshpion has joined #ruby
neshpion has quit [Remote host closed the connection]
robotbee has quit [Changing host]
robotbee has joined #ruby
neshpion has joined #ruby
mic_e has joined #ruby
mic_e has quit [Ping timeout: 240 seconds]
akem has quit [Quit: leaving]
vondruch has quit [Read error: Connection reset by peer]
vondruch has joined #ruby
<regent>
Anybody know why the last line at `url = "https://www.blabla/25849" ; json = URI.open(url) ; data = JSON.parse(json)` is giving me `TypeError: no implicit conversion of StringIO into String`?
mcspud has quit [Ping timeout: 260 seconds]
<regent>
If I download it manually into a file instead, then `file = File.read('/path/to/some_file.json') ; data = JSON.parse(file)` works just fine.
<drusepth>
does `data = JSON.parse(json.string)` throw the same error?
<regent>
drusepth: bless you! no it didn't <3
<drusepth>
URI.open returns a StringIO object, which has #string to return the actual string :) TypeError: no implicit
<AndreYuhai>
But now I want to figure out what was wrong
<AndreYuhai>
So I deleted that dependency from Gemfile and only installed nokogiri 1.11.2 gem
<AndreYuhai>
But now bundle install or bundle update still tries to install 1.11.3
<weaksauce>
put the 1.11.2 in the gemfile for a bit to diagnose it
<weaksauce>
and it will likely use that over .3
<weaksauce>
when it satisfies the dependency
<AndreYuhai>
weaksauce, Alright I will try that, thanks!
robotbee has joined #ruby
<AndreYuhai>
Hmm, now everything worked fine on my machine.
robotbee has quit [Changing host]
robotbee has joined #ruby
BTRE has quit [Remote host closed the connection]
bucareli has joined #ruby
Xiti has joined #ruby
<AndreYuhai>
I wonder what the difference is between "building with native extensions" and just doing gem install
<AndreYuhai>
Because when I did bundle update it still installed nokogiri 1.11.2 with native extensions even though I had nokogiri 1.11.2
BTRE has joined #ruby
<AndreYuhai>
Alright, gotta sleep now. Night everyone!
AndreYuhai has quit [Quit: Leaving]
shtirlic has quit [Ping timeout: 240 seconds]
markong has quit [Remote host closed the connection]
<scriptonaut>
I'm having a weird issue with bundler or ruby gems or possibly rbenv. When I type: which bundle, it shows an exe in /usr/local/bin. But gem env, shows me the proper rbenv executable directory
<scriptonaut>
I've done rbenv rehash, I've confirmed I'm using the right version of ruby, etc
shtirlic has joined #ruby
<scriptonaut>
when I type: whereis bundle, it shows both the /usr/local/bin path, and the proper rbenv path, but the /usr/local/bin path is first
jetchisel has joined #ruby
dpl_ has joined #ruby
markong has joined #ruby
roshanavand has joined #ruby
roshanavand__ has quit [Ping timeout: 252 seconds]
dpl has quit [Ping timeout: 268 seconds]
rotcev has joined #ruby
roshanavand has quit [Ping timeout: 246 seconds]
stryek has quit [Quit: Connection closed for inactivity]