‘RSA_SSLV23_PADDING’ undeclared (first use in this function); did you mean...
I am getting this issue while compiling ruby-2.7.1 using asdf or rvm.It is even causing issues in erlang installation as well.Error could begenerating x86_64-linux-fake.rbx86_64-linux-fake.rb...
View ArticleRuby on Rails multiselect adding blank attribute for nested query causing...
In my Rails application, I have a dream model and a location model. A dream can have many locations and a location can have many dreams. I've created a dream_location model to facilitate this. I would...
View ArticleSearching for range overlaps in Ruby hashes
Say you have the following Ruby hash,hash = {:a => [[1, 100..300], [2, 200..300]], :b => [[1, 100..300], [2, 301..400]] }and the following functions,def overlaps?(range, range2)...
View ArticleHow to rename a key in a hash if it exists
I have the following hash:a = { foo: 'bar', answer: '42'}How can I elegantly rename the key :foo to a new key :test? If the hash entry for :foo does not exist, the hash should not be altered.
View ArticleUnable to make correct Reporting Template in Foreman to get a list of modules...
I have searched high and low for a solution to pull my .yaml details out via the Reporting Template function in Foreman. Under Puppet ENC is where my desired information is located.I have tried...
View ArticlePG::UndefinedTable: ERROR: relation "action_text_rich_texts" does not exist |...
I've setup Rails API only project with Postgreqsl database.Rails Version:6.0.0.rc1Rails_Admin Version:2.0.0.betaI am getting following errorActiveRecord::StatementInvalid in...
View Articlepod install fails with "cannot load such file -- xcodeproj"
I recently updated to ruby v 2.6After upgrading I'm facing issue installing pods with the following errorTraceback (most recent call last): 7: from /usr/local/bin/pod:23:in `<main>' 6: from...
View ArticleUsing Sorbet Generics with static methods
I'm creating a factory/builder class that returns a generic type:instance = ClientsFactory[SomeClass].new(:name).buildbut I also want to have a static method to call it directly:instance =...
View ArticleIs there a way to generate a pdf file with editable text (comments or...
I have been using Prawnpdf in Ruby to generate pdf documents. The only issue that I have is that I cannot modify the rendered text in the pdf file afterwards (using Bluebeam or Adobe Acrobot Pro). Is...
View ArticleWhat's the quickest way for a Ruby programmer to pick up Python?
I've been programming Ruby pretty extensively for the past four years or so, and I'm extremely comfortable with the language. For no particular reason, I've decided to learn some Python this week. Is...
View Articleuninitialized constant ActiveSupport::LoggerThreadSafeLevel::Logger (NameError)
rails 6.1.7.10ruby 2.6.6.Just did a bundle update to 6.1.7.10 from 6.1.7.8Now running the application I receive the following...
View ArticleHow do I keep a clean interface when including modules in Ruby
I'm creating a view helper in Rails in which I need to use the existing form_with helper from ActionView::Helpers::FormHelper. I've tried to call it using ActionView::Helpers::FormHelper.for_for which...
View ArticleRe-usable responses in RSWAG
OpenAPI (Swagger) supports responses in the components so you can have re-usable responses: https://swagger.io/docs/specification/v3_0/describing-responses/#reusing-responsesThe Rswag documentation...
View ArticleBundler: list gems in a group
For example, I have the following Gemfile:source "https://rubygems.org"group :example_group do gem 'example_gem' gem 'another_example_gem'endHow can I list all gems inside :example_group in Ruby? Not...
View ArticleHow do I make my model for an association part of the ActiveRecord::Base...
When I log into my ruby rails app, I am getting the following error: "The Reccoh model class for the User#reccohs association is not an ActiveRecord::Base subclass." It seems like none of my models are...
View ArticleInstalling ruby with ruby-install causes build error on Mac M1
When installing ruby 2.6.6 or 2.7.2 using ruby-install on mac M1, the following error occurs. Ruby 3.0.0 works fine however anything older will error out with readline and not allow ruby to...
View ArticleGetting error when creating NEW Rails project: uninitialized constant...
I'm new to Ruby and Rails... I'm following the Ruby on Rails tutorial and when I create a new project from chapter 3, I get this error:$ rails -vRails 7.2.2.1$ rails 7.0.4 new sample_app...
View Articlerake routes command not working - rake version 13.0.3
rake routes on Terminal returns:rake aborted! Don't know how to build task 'routes' (See the list of available tasks with 'rake --tasks'...
View ArticleRuby Class vs Struct
I have seen codebases using Structs to wrap around attributes and behavior inside a class.What is the difference between a Ruby Class and a Struct? And when should one be used over the other.?
View ArticleCould not find option 'storage_mode' in the list of available options:...
when I run this command to build the app:bundle exec fastlane betashows this error:[19:45:54]: ------------------------------[19:45:54]: --- Step: default_platform ---[19:45:54]:...
View Article