Quantcast
Channel: Active questions tagged ruby - Stack Overflow
Browsing all 4609 articles
Browse latest View live

I have been attempting an interesting problem in a parent child object...

Both the parent and child have different validators via validate… or validates…I want to store the result of each validator across all of themthe valid? command is run on the parent (edited)when I run...

View Article


I18n.t Translation Missing Default Value Nil

So I know how return a default value if I get "translation missing:" when reading a yaml file.some = I18n.t("something.something_else", default: "value")But how do I do that in the Ruby way if I want...

View Article


I accidentally installed gems using the preinstalled system ruby before...

I started trying to install some Ruby gems to preview a site using Jekyll: gem install jekyll bundler. This didn't work because of an access error, so I used the command sudo gem install jekyll...

View Article

How can I remove Google tracking parameters (UTM) from an URL?

I have a bunch of URLs which I would like to clean. They all contain UTM parameters, which are not necessary, or rather harmful in this case....

View Article

Rails server quits with EADDRINUSE right when it starts

I have had this problem for a while but have found no solution. I am building a forums application in rails. I had just finished adding bootstrap and the bootstrap gem to my project. I go to run the...

View Article


Stuck at building native extension in gem install jekyll

While installing Gems for jekyll, it's been 30 mins now that cmd is at building native extentions. This could take a while.I started this installation using cmd with admin...

View Article

Custom method as ID

I have two models:class Product belongs_to :storage_boxendclass StorageBox validates :key presence: true, uniqueness: { scope: %i[kind] } validates :kind presence: true def...

View Article

External Dependency Manager in Unity installing Cocoapods succeeded but the...

I try to make build on iOs with Unity. But has problem with Branch.io and (Header.h in xCode) file.To resolve dependencies, it is suggested to use External Dependency Manager. It runs the cocoapods...

View Article


How can I reload a script in IRB?

I am writing a Ruby script for use in the Rails environment, but I chose to run it from irb because reloading the Rails console can be a pain. Now the wait time is much shorter from irb, but I'm...

View Article


Issues with knife command in chef-workstation "knife status, knife block list...

I installed chef-workstation in my mac via brew install --cask chef-workstation, it says installation was successful but I got this message after the installation process in my ui:A JavaScript error...

View Article

How to change which version of Ruby I am using

I need to run 2.5.3. I use brew to manage my ruby installation (as I couldn't get rvm to work on my machine). When I run$ruby -vI getruby 2.3.7p456 (2018-03-28 revision 63024)...

View Article

Puppet get value from Deferred function run

I'm using a customized version of such Puppet function vault_lookup for Vault integration. Changed some logic, to login with AppRole, not with the certs as it was in the original version. And trying to...

View Article

Autoforme with Sequel (Ruby) using ManyThroughMany

We have a Ruby application using Roda, Sequel and Autoforme.If I use the many_through_many plugin for Sequel and define an association as many_through_many in the Sequel model and I add the association...

View Article


I am having trouble fixing a broken website that is giving me a code to...

Kind of a weird thing to post here, but I am trying to access Yugioh Top Deck and it is sending me to a page that says to put a few line of code into Windows Powershell as an Administrator.app.rb:class...

View Article

Image may be NSFW.
Clik here to view.

ISSUE WITH COOKIES - RUBY ON RAILS AND REACT JS

I am currently facing an issue using cookies for login. I have ruby on rails in backend and vite in front end.I am able to send cookies to front end can see in the response headers in developer toolsI...

View Article


Learning Ruby, where do I start? [closed]

I'm a C++/C#/PHP/Javascript programmer who's been interested in learning Ruby for a while now. I just graduated and considering this means I no longer have homework to do, I figured now might be a good...

View Article

devise and language by multiple domain

I'm trying to use multi language by domain, for example I have domain.fi.local for language Finnish and domain.es.local for language Spanish and on every of them you can switch to English and I have to...

View Article


Sending WhatsApp messages through WhatsApp API How To & Lessons Learned [closed]

I recently had to figure out how to send WhatsApp messages via the WhatsApp API and figuring out the syntax and all the parts took a long time, so I'm posting what worked here.I was sending a marketing...

View Article

Change default size of text input in Simple Form [closed]

How can I change default size of SimpleForm inputs using initializer? I would like to treat as string all text fields too by default. So I want an input to have text size only when explicitly setting...

View Article

Ruby rspec converting mock hash with strings into hash with symbol

I am in a plain ruby project and I have this mock: let(:mock_binance_client) { instance_double(Binance::Client::REST, time: {"serverTime": 1594138489530}) }which says that when time is called it should...

View Article
Browsing all 4609 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>