229,232 questions
-1
votes
0
answers
39
views
Selenium attach to existing browser using ruby - script froze
I'm trying to attach Selenium to existing browser. Based on this tutorial, now I've got:
test.bat
cd /d "%~dp0"
ruby test.rb %1 %2 %3 %input%
pause
test.rb
require 'selenium-webdriver'
...
0
votes
1
answer
37
views
msgpack gem failing to install on MacOS when running `bundle install`
I'm on MacOS Tahoe (26.3.1 (a)). I have a Ruby project which requires msgpack (1.4.2).
Unfortunately, when I run bundle install, I see:
Fetching msgpack 1.4.2
Installing msgpack 1.4.2 with native ...
-1
votes
1
answer
66
views
How to solve problems with wxruby?
I have successfully installed wxruby3 using the gem install wxruby3 command.
I also downloaded wxWidgets from the official website.
I downloaded additional packages using the wxruby setup command.
I ...
0
votes
1
answer
46
views
How to use existing chromium profile for ferrum?
I have setup chromium profile and wish to use that with ruby ferrum library. I copied complete configurations directory into /tmp and passed browser switched, but profile extensions seems to not work....
Tooling
0
votes
4
replies
102
views
Automating repetitive tasks with Ruby and Selenium WebDriver
I followed the advice from this question and I started to experimenting with Selenium, but I feel like it has to many limitations. Could you recommend something more suitable?
A simple program that ...
0
votes
1
answer
165
views
Convert a string to only have regular alphabet characters, from any language
I had an issue this morning where someone was blowing up our school search function (which uses a MySQL MATCH function) by typing '𝓵𝓲𝓵𝓵𝔂𝓬𝓻𝓸𝓯𝓽' into the school search. This is within the ...
-1
votes
1
answer
127
views
Regex Named Capture Group also Include Complete String
Is it possible to have a Regex include the whole string as a named capture group as well as individual named capture groups?
I am trying to parse IIS logs and can successfully extract the details I ...
Advice
0
votes
2
replies
138
views
New DataTypes For Ruby
I'm Alex. I program science I was in school and I have concepts of Datatypes which I would like to have in programming language.
Ruby is My Favorite languge (10+ years of experience), Are there any ...
3
votes
1
answer
92
views
Rails 8.0.4 app build from scratch test ("bin/rails test") gives wrong number of arguments in line_filtering.rb
I started a new rails project and generated a model with
rails new nonono --css=bootstrap -j esbuild
bin/rails g scaffold State name
After that I run the test suite
bin/rails test
And got the ...
Advice
0
votes
5
replies
135
views
Remove un-numbered lines from vscode
In VSCode i am tying to increase amount of useful information displayed. A lot of screen space is taken up by UN-numbered blank lines between the lines of code. These are not actual lines as they ...
0
votes
0
answers
76
views
Ruby Nokogiri Sax parser does not unescape & attribute
With the following code:
require 'nokogiri'
class MyDocument < Nokogiri::XML::SAX::Document
def start_element_namespace(name, attrs = [], prefix = nil, uri = nil, ns = [])
a = attrs.map ...
2
votes
0
answers
102
views
Heroku ruby buildpack breaks on second deployment push
I've upgraded Ruby from Ruby 3.1.7 to Ruby 3.2.8; after that, I've encountered a situation where my ruby bundle works for the first deployment on Heroku-deployed servers, but all subsequent ...
1
vote
1
answer
130
views
Negative Unix timestamp in Ruby
I have the following Unix timestamp:
time = Time.at(-8_640_000_000_000) # => -271821-04-19 19:00:00 -0500
time.strftime('%B %-d, %Y at %-I:%M %p') # => "April 19, -271821 at 7:00 PM"
...
Advice
0
votes
6
replies
74
views
Why are things magically available in the current scope in a ruby script in Jekyll?
My question could apply to many other ruby frameworks I guess. But here I have the case while programming a Jekyll project.
Let's see this Jekyll plugin as an example:
require 'dotenv'
module Jekyll
...
-3
votes
0
answers
53
views
How to convert a unicode value to a utf-8 character in Ruby 1.8.7 [duplicate]
I'm looking at the characters in this pdf:
https://www.unicode.org/charts/PDF/U1D100.pdf
For example, the treble clef symbol which has a unicode value of '1D120'
In ruby 1.8.7, how would i convert ...