I attempted to make a new app using rails new command and the bundle is completed. However, it said that rails aborted! and appeared another error:
Bundle complete! 15 Gemfile dependencies, 70 gems now installed.
Use `bundle info [gemname]` to see where a bundled gem is installed.
run bundle binstubs bundler
rails importmap:install
rails aborted!
TZInfo::DataSourceNotFound: tzinfo-data is not present. Please add gem 'tzinfo-data' to your Gemfile and run bundle install
C:/Sites/test_001/config/environment.rb:5:in `<main>'
Caused by:
TZInfo::DataSources::ZoneinfoDirectoryNotFound: None of the paths included in TZInfo::DataSources::ZoneinfoDataSource.search_path are valid zoneinfo directories.
C:/Sites/test_001/config/environment.rb:5:in `<main>'
Tasks: TOP => app:template => environment
(See full trace by running task with --trace)
rails turbo:install stimulus:install
You must either be running with node (package.json) or importmap-rails (config/importmap.rb) to use this gem.
You must either be running with node (package.json) or importmap-rails (config/importmap.rb) to use this gem.
Any help on resolving this will be greatly appreciated. Thank you very much.
It says that you need to install tzinfo-data gem for your application.
Please add
gem 'tzinfo-data', '~> 1.2021', '>= 1.2021.5'
in your application's gemfile.
Thanks
Actually, I've mixed two of the answers here and it fixed the problem for me on Windows 11.
I've added:
gem 'tzinfo-data', '~> 1.2021', '>= 1.2021.5'
And removed the other part of the gem 'tzinfo-data' added by default.
In the gem fille where you see gem "tzinfo-data", platforms: %i[ mingw mswin x64_mingw jruby ], remove platforms and then run gem install tzinfo-data. After you do that run bundle install. Then go back to the original directory where you ran rails new, and run it again with the same name, I managed to get rid of the tzinfo error and the node(package.json) error.
Related
Similar to other queries I found that upon running rails s exits the program immediately and says:
in 'rescue in create_defaut_data_source': tzinfo-data is not present. Please add gem 'tzinfo-data' to your Gemfile and run bundle install (TZInfo:: DataSourceNotFound)
1
I ran both gem install tzinfo and gem install tzinfo-data. When I checked the Gemfile file, the tzinfo-data gem was also present.
Has anyone else had a similar issue?
I have created a new application using Ruby on Rails v4.1.0. When attempting to start a server or console on Windows, I am encountering the following error:
$ rails server
Booting WEBrick
Rails 4.1.0 application starting in development on ....
Exiting
c:/RailsInstaller/Ruby2.0.0/lib/ruby/gems/2.0.0/gems/tzinfo-1.1.0/lib/tzinfo/data_source.rb:199:
in `rescue in create_default_data_source':
No timezone data source could be found. To resolve this, either install
TZInfo::Data (e.g. by running `gem install tzinfo-data`) or specify a zoneinfo
directory using `TZInfo::DataSource.set(:zoneinfo, zoneinfo_path)`.
(TZInfo::DataSourceNotFound)
from c:/RailsInstaller/Ruby2.0.0/lib/ruby/gems/2.0.0/gems/tzinfo-1.1.0/lib/tzinfo/data_source.rb:196:
in `create_default_data_source'
How can I resolve this error?
Resolving the Error
To resolve this error, you'll need to make sure that the tzinfo-data gem is being included in your Gemfile.
First of all, check your Gemfile to see if there is an existing reference to tzinfo-data. If there isn't already a reference, then add the following line:
gem 'tzinfo-data'
You may find that there is already a line like the following:
gem 'tzinfo-data', platforms: [:mingw, :mswin]
If you are using a 64-bit version of Ruby on Windows, then add :x64_mingw to the list of platforms as follows:
gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw]
Alternatively, you can remove the platforms option altogether.
Note that there is a bug in Bundler that means there's currently no platform option that will match 64-bit Ruby 3.1 on Windows. The solution here to remove the platforms option.
After doing this, run bundle update at the command line to install the tzinfo-data gem and you'll then be able to start your Rails server or console.
Background
The TZInfo::DataSourceNotFound error is being raised by TZInfo, a dependency of the Active Support component of Rails. TZInfo is looking for a source of time zone data on your system, but failing to find one.
On many Unix-based systems (e.g. Linux), TZInfo is able to use the system zoneinfo directory as a source of data. However, Windows doesn't include such a directory, so the tzinfo-data gem needs to be installed instead. The tzinfo-data gem contains the same zoneinfo data, packaged as a set of Ruby modules.
Rails generates a default Gemfile when the application is first created. If the application is created on Windows, then a dependency for tzinfo-data will be included. However Rails (up to version 4.1.x) omitted :x64_mingw from the list of platforms and therefore didn't work correctly on 64-bit Windows versions of Ruby.
I had to add two gems to get the server to start..
gem 'tzinfo-data'
gem 'tzinfo'
Then bundle install.
I had that error when trying to install Redmine in a Docker container:
RAILS_ENV=production bundle exec rake db:migrate
gave me the error because package tzdata was not installed in my Ubuntu image.
apt-get update && apt-get install tzdata -y
did the trick.
Just put this in your app terminal :
gem install tzinfo-data
then change the gemfile line to :
gem 'tzinfo-data', platforms: [:x64_mingw, :mingw, :mswin]
then again in your terminal :
bundle update
That will solve the problem directly.
Add the following line to your Gem File
gem 'tzinfo-data', platforms: [:x64_mingw,:mingw, :mswin]
In Gemfile, I added this following line
#tzinfo-data
gem 'tzinfo-data', '~> 1.2021', '>= 1.2021.5'
and then, I commented out the following line
gem "tzinfo-data", platforms: %i[ mingw mswin x64_mingw jruby ]
and then I simply ran
rails server
and it worked for me successfully.
Here is my full Gemfile
source "https://rubygems.org"
git_source(:github) { |repo| "https://github.com/#{repo}.git" }
ruby "3.1.1"
#tzinfo-data
gem 'tzinfo-data', '~> 1.2021', '>= 1.2021.5'
# Bundle edge Rails instead: gem "rails", github: "rails/rails", branch: "main"
gem "rails", "~> 7.0.2", ">= 7.0.2.3"
# The original asset pipeline for Rails [https://github.com/rails/sprockets-rails]
gem "sprockets-rails"
# Use sqlite3 as the database for Active Record
gem "sqlite3", "~> 1.4"
# Use the Puma web server [https://github.com/puma/puma]
gem "puma", "~> 5.0"
# Use JavaScript with ESM import maps [https://github.com/rails/importmap-rails]
gem "importmap-rails"
# Hotwire's SPA-like page accelerator [https://turbo.hotwired.dev]
gem "turbo-rails"
# Hotwire's modest JavaScript framework [https://stimulus.hotwired.dev]
gem "stimulus-rails"
# Build JSON APIs with ease [https://github.com/rails/jbuilder]
gem "jbuilder"
# Use Redis adapter to run Action Cable in production
# gem "redis", "~> 4.0"
# Use Kredis to get higher-level data types in Redis [https://github.com/rails/kredis]
# gem "kredis"
# Use Active Model has_secure_password [https://guides.rubyonrails.org/active_model_basics.html#securepassword]
# gem "bcrypt", "~> 3.1.7"
# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
# gem "tzinfo-data", platforms: %i[ mingw mswin x64_mingw jruby ]
# Reduces boot times through caching; required in config/boot.rb
gem "bootsnap", require: false
# Use Sass to process CSS
# gem "sassc-rails"
# Use Active Storage variants [https://guides.rubyonrails.org/active_storage_overview.html#transforming-images]
# gem "image_processing", "~> 1.2"
group :development, :test do
# See https://guides.rubyonrails.org/debugging_rails_applications.html#debugging-with-the-debug-gem
gem "debug", platforms: %i[ mri mingw x64_mingw ]
end
group :development do
# Use console on exceptions pages [https://github.com/rails/web-console]
gem "web-console"
# Add speed badges [https://github.com/MiniProfiler/rack-mini-profiler]
# gem "rack-mini-profiler"
# Speed up commands on slow machines / big apps [https://github.com/rails/spring]
# gem "spring"
end
group :test do
# Use system testing [https://guides.rubyonrails.org/testing.html#system-testing]
gem "capybara"
gem "selenium-webdriver"
gem "webdrivers"
end
Maybe tzinfo is not installed on your system, try to install it:
gem install tzinfo
gem install tzinfo-data
I had this problem too and fixed it by adding BOTH the :x64_mingw to the list of platforms for tzinfo-data, AND the gem 'tzinfo' to the gemfile. Then bundle install.
I ran into this issue on macOs Mojave 10.14.5 and I found out that it was something with how my symlink in macOs wasn't reading the correct provided zone info files.
I was able to track this down with where the files should be using the command
TZInfo::ZoneinfoDataSource.search_path and that provided the output of ["/usr/share/zoneinfo", "/usr/share/lib/zoneinfo", "/etc/zoneinfo"].
I began looking into /usr/share/zoneinfo and there were files available to read. However rails still wasn't finding them, reading them, executing them..? So I then created a symlink from the other file in /usr/share/zoneinfo.default/ to /etc/zoneinfo (the last path TZInfo looks up)
So finally the command that worked for me to fix this issue was ln -s /usr/share/zoneinfo.default /etc/zoneinfo
Hopefully this information is helpful to someone in the future.
I am using windows and for several days I was not able to solve this problem.
So the solution for our 64 bit platform is to type the following in the terminal:
gem install tzinfo
gem install tzinfo-data
Then afterwards go navigate back to your gem file. In case if you haven't created one create it with rails new xyznameofyours on the terminal.
Then replace the line of code which states something like:
gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw] or
gem "tzinfo-data", platforms: %i[ mingw mswin x64_mingw jruby ]
to this:
gem 'tzinfo-data'
gem 'tzinfo'
Only then after your code will work!
It is possible that installing the gem directly via cmd might not solve the issue on Windows OS.
Here is how it did work for me step-by-step;
Inside the Gemfile folder "ctrl-F" and type "platforms"
Find the line gem "tzinfo-data", platforms: %i[ mingw mswin
x64_mingw jruby ]
Remove everything after "tzinfo-data" (comma included)
Final view should be just gem "tzinfo-data" add also gem "tzinfo"
On the terminal, type "bundler update" or "bundle update"
Once it is completed, type "rails s"
Notice: Even after this, if your server starts but can not resolve the default page (additionally ctrl-c / ctrl-pause/break doesn't work), then add webrick instead of puma by adding the gem gem 'webrick', '~> 1.3', '>= 1.3.1'. After that, to run the webrick server you need to type
rails s -u webrick
1-go to gemfile
add the following line without any arrays only that line
gem "tzinfo-data"
then save the file
2- then on cmd type
bundle install
then press Enter
3-then also on cmd type
rails server
then press Enter
so, the gems didn't quite seem to install properly, i had to do the following
gem 'tzinfo-data'
gem 'tzinfo'
then
bundle show
to see all gems
bundle gem tzinfo
will get you the gem's directory
then, go to that directory. you will need to splice tzinfo-data into tzinfo.
in the tzinfo-data file, go to..
local_pathname/tzinfo-data-1.2014.5/lib/tzinfo
copy all the contents of this directory into...
local_pathname/tzinfo-1.2.1/lib/tzinfo
(for me this meant copying 'data' the file and 'data' the directory)
then
go to
local_pathname/tzinfo-1.2.1/lib
and open the file, tzinfo, (not the directory)
and add this line
require 'tzinfo/data'
this was such a pain to figure out
I've replaced:
gem "tzinfo-data", platforms: %i[ mingw mswin x64_mingw jruby ]
with:
gem 'tzinfo-data', '~> 1.2021', '>= 1.2021.5'
and it worked fine.
> Blockquote
I need sqlite3 v1.3.9 gem installed for my app, so I add this line to the Gemfile:
gem 'sqlite3', '= 1.3.9'
However, when I run 'bundle install', it installs v1.4.2 of that gem.
I modified the above line to
gem 'sqlite3', '= 1.3.9', '< 1.4'
No joy -- sqlite v1.4.2 is installed (even if I remove any reference to 'sqlite3' from the Gemfile completely).
My Gemfile was created when I used rails new appname, so it is not fancy at all... I only added gem devise to it.
Gemfile.lock doesn't contain any reference to sqlite3. I removed it anyway and it didn't help.
As another option, I installed v1.3.9 via gem install sqlite3 -v 1.3.9 and I removed v1.4.2 with
# bundle exec gem uninstal sqlite3
Select gem to uninstall:
1. sqlite3-1.3.9
2. sqlite3-1.4.2
3. All versions
> 2
Successfully uninstalled sqlite3-1.4.2
...but as soon as I tried to add v1.3.9, I got:
# bundle add sqlite3 -v 1.3.9
[!] There was an error parsing `injected gems`: You cannot specify the same gem twice with different version requirements.
You specified: sqlite3 (~> 1.4) and sqlite3 (= 1.3.9). Bundler cannot continue.
# from injected gems:1
# -------------------------------------------
> gem "sqlite3", "= 1.3.9"
# -------------------------------------------
I'd grateful for any hints on why v1.4.2 keeps being installed and, most importantly, how do get the bundler forget about v1.4.2 and accept v1.3.9?
Thanks a lot!
There might be some gem in your app that requires sqlite3-1.4.2 and that is causing an issue with installing sqlite3-1.3.9. You should check your Gemfile.lock and look for any gem that is adding sqlite3-1.4.2 as a dependency.
There should be a gem in your app that requires sqlite3-1.4.2 and that is causing an issue with installing sqlite3-1.3.9. You should check your Gemfile.lock and look for any gem that is adding sqlite3-1.4.2 as a dependency.
What I tried to do I tried to run
rails g petergate:install
I expected it to add a migration and insert petergate into my User model.
What actually happened is I got an error in terminal saying:
Could not find i18n-0.8.6 in any of the sources
Run `bundle install` to install missing gems.
I ran bundle install and retried rails g petergate:install, but the same error keeps occurring.
When I view my gems, I do have i18n-0.8.6.
$ rails g petergate:install
Could not find i18n-0.8.6 in any of the sources
Run `bundle install` to install missing gems.
$ bundle install
Using rake 12.0.0
Using concurrent-ruby 1.0.5
Using i18n 0.8.6
I am not sure how to debug this.
The petergate gem is in my Gemfile:
# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw, :jruby]
gem 'friendly_id', '~> 5.2', '>= 5.2.1'
gem 'devise', '~> 4.3'
gem 'bootstrap', '~> 4.0.0.beta'
gem 'microurb_view_tool', '~> 0.1.0'
gem 'petergate', '~> 1.7', '>= 1.7.5'
The following commands have been run for debugging purposes:
$ cat Gemfile.lock | grep i18n
i18n (~> 0.7)
i18n (0.8.6)
$ bundle exec rails g petergate:install
Could not find i18n-0.8.6 in any of the sources
Run `bundle install` to install missing gems.
$ bundle exec rake rails:update:bin
rake aborted!
Don't know how to build task 'rails:update:bin' (see --tasks)
/Users/danale/.rvm/gems/ruby-2.4.0#global/gems/rake-12.0.0/exe/rake:27:in `<top (required)>'
/Users/danale/.rvm/gems/ruby-2.4.0/bin/ruby_executable_hooks:15:in `eval'
/Users/danale/.rvm/gems/ruby-2.4.0/bin/ruby_executable_hooks:15:in `<main>'
(See full trace by running task with --trace)
Be sure to confirm that ruby -v, rails -v and bundle -v outputs the expected versions, since Rails could be using a different gemset.
I have created a new application using Ruby on Rails v4.1.0. When attempting to start a server or console on Windows, I am encountering the following error:
$ rails server
Booting WEBrick
Rails 4.1.0 application starting in development on ....
Exiting
c:/RailsInstaller/Ruby2.0.0/lib/ruby/gems/2.0.0/gems/tzinfo-1.1.0/lib/tzinfo/data_source.rb:199:
in `rescue in create_default_data_source':
No timezone data source could be found. To resolve this, either install
TZInfo::Data (e.g. by running `gem install tzinfo-data`) or specify a zoneinfo
directory using `TZInfo::DataSource.set(:zoneinfo, zoneinfo_path)`.
(TZInfo::DataSourceNotFound)
from c:/RailsInstaller/Ruby2.0.0/lib/ruby/gems/2.0.0/gems/tzinfo-1.1.0/lib/tzinfo/data_source.rb:196:
in `create_default_data_source'
How can I resolve this error?
Resolving the Error
To resolve this error, you'll need to make sure that the tzinfo-data gem is being included in your Gemfile.
First of all, check your Gemfile to see if there is an existing reference to tzinfo-data. If there isn't already a reference, then add the following line:
gem 'tzinfo-data'
You may find that there is already a line like the following:
gem 'tzinfo-data', platforms: [:mingw, :mswin]
If you are using a 64-bit version of Ruby on Windows, then add :x64_mingw to the list of platforms as follows:
gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw]
Alternatively, you can remove the platforms option altogether.
Note that there is a bug in Bundler that means there's currently no platform option that will match 64-bit Ruby 3.1 on Windows. The solution here to remove the platforms option.
After doing this, run bundle update at the command line to install the tzinfo-data gem and you'll then be able to start your Rails server or console.
Background
The TZInfo::DataSourceNotFound error is being raised by TZInfo, a dependency of the Active Support component of Rails. TZInfo is looking for a source of time zone data on your system, but failing to find one.
On many Unix-based systems (e.g. Linux), TZInfo is able to use the system zoneinfo directory as a source of data. However, Windows doesn't include such a directory, so the tzinfo-data gem needs to be installed instead. The tzinfo-data gem contains the same zoneinfo data, packaged as a set of Ruby modules.
Rails generates a default Gemfile when the application is first created. If the application is created on Windows, then a dependency for tzinfo-data will be included. However Rails (up to version 4.1.x) omitted :x64_mingw from the list of platforms and therefore didn't work correctly on 64-bit Windows versions of Ruby.
I had to add two gems to get the server to start..
gem 'tzinfo-data'
gem 'tzinfo'
Then bundle install.
I had that error when trying to install Redmine in a Docker container:
RAILS_ENV=production bundle exec rake db:migrate
gave me the error because package tzdata was not installed in my Ubuntu image.
apt-get update && apt-get install tzdata -y
did the trick.
Just put this in your app terminal :
gem install tzinfo-data
then change the gemfile line to :
gem 'tzinfo-data', platforms: [:x64_mingw, :mingw, :mswin]
then again in your terminal :
bundle update
That will solve the problem directly.
Add the following line to your Gem File
gem 'tzinfo-data', platforms: [:x64_mingw,:mingw, :mswin]
In Gemfile, I added this following line
#tzinfo-data
gem 'tzinfo-data', '~> 1.2021', '>= 1.2021.5'
and then, I commented out the following line
gem "tzinfo-data", platforms: %i[ mingw mswin x64_mingw jruby ]
and then I simply ran
rails server
and it worked for me successfully.
Here is my full Gemfile
source "https://rubygems.org"
git_source(:github) { |repo| "https://github.com/#{repo}.git" }
ruby "3.1.1"
#tzinfo-data
gem 'tzinfo-data', '~> 1.2021', '>= 1.2021.5'
# Bundle edge Rails instead: gem "rails", github: "rails/rails", branch: "main"
gem "rails", "~> 7.0.2", ">= 7.0.2.3"
# The original asset pipeline for Rails [https://github.com/rails/sprockets-rails]
gem "sprockets-rails"
# Use sqlite3 as the database for Active Record
gem "sqlite3", "~> 1.4"
# Use the Puma web server [https://github.com/puma/puma]
gem "puma", "~> 5.0"
# Use JavaScript with ESM import maps [https://github.com/rails/importmap-rails]
gem "importmap-rails"
# Hotwire's SPA-like page accelerator [https://turbo.hotwired.dev]
gem "turbo-rails"
# Hotwire's modest JavaScript framework [https://stimulus.hotwired.dev]
gem "stimulus-rails"
# Build JSON APIs with ease [https://github.com/rails/jbuilder]
gem "jbuilder"
# Use Redis adapter to run Action Cable in production
# gem "redis", "~> 4.0"
# Use Kredis to get higher-level data types in Redis [https://github.com/rails/kredis]
# gem "kredis"
# Use Active Model has_secure_password [https://guides.rubyonrails.org/active_model_basics.html#securepassword]
# gem "bcrypt", "~> 3.1.7"
# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
# gem "tzinfo-data", platforms: %i[ mingw mswin x64_mingw jruby ]
# Reduces boot times through caching; required in config/boot.rb
gem "bootsnap", require: false
# Use Sass to process CSS
# gem "sassc-rails"
# Use Active Storage variants [https://guides.rubyonrails.org/active_storage_overview.html#transforming-images]
# gem "image_processing", "~> 1.2"
group :development, :test do
# See https://guides.rubyonrails.org/debugging_rails_applications.html#debugging-with-the-debug-gem
gem "debug", platforms: %i[ mri mingw x64_mingw ]
end
group :development do
# Use console on exceptions pages [https://github.com/rails/web-console]
gem "web-console"
# Add speed badges [https://github.com/MiniProfiler/rack-mini-profiler]
# gem "rack-mini-profiler"
# Speed up commands on slow machines / big apps [https://github.com/rails/spring]
# gem "spring"
end
group :test do
# Use system testing [https://guides.rubyonrails.org/testing.html#system-testing]
gem "capybara"
gem "selenium-webdriver"
gem "webdrivers"
end
Maybe tzinfo is not installed on your system, try to install it:
gem install tzinfo
gem install tzinfo-data
I had this problem too and fixed it by adding BOTH the :x64_mingw to the list of platforms for tzinfo-data, AND the gem 'tzinfo' to the gemfile. Then bundle install.
I ran into this issue on macOs Mojave 10.14.5 and I found out that it was something with how my symlink in macOs wasn't reading the correct provided zone info files.
I was able to track this down with where the files should be using the command
TZInfo::ZoneinfoDataSource.search_path and that provided the output of ["/usr/share/zoneinfo", "/usr/share/lib/zoneinfo", "/etc/zoneinfo"].
I began looking into /usr/share/zoneinfo and there were files available to read. However rails still wasn't finding them, reading them, executing them..? So I then created a symlink from the other file in /usr/share/zoneinfo.default/ to /etc/zoneinfo (the last path TZInfo looks up)
So finally the command that worked for me to fix this issue was ln -s /usr/share/zoneinfo.default /etc/zoneinfo
Hopefully this information is helpful to someone in the future.
I am using windows and for several days I was not able to solve this problem.
So the solution for our 64 bit platform is to type the following in the terminal:
gem install tzinfo
gem install tzinfo-data
Then afterwards go navigate back to your gem file. In case if you haven't created one create it with rails new xyznameofyours on the terminal.
Then replace the line of code which states something like:
gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw] or
gem "tzinfo-data", platforms: %i[ mingw mswin x64_mingw jruby ]
to this:
gem 'tzinfo-data'
gem 'tzinfo'
Only then after your code will work!
It is possible that installing the gem directly via cmd might not solve the issue on Windows OS.
Here is how it did work for me step-by-step;
Inside the Gemfile folder "ctrl-F" and type "platforms"
Find the line gem "tzinfo-data", platforms: %i[ mingw mswin
x64_mingw jruby ]
Remove everything after "tzinfo-data" (comma included)
Final view should be just gem "tzinfo-data" add also gem "tzinfo"
On the terminal, type "bundler update" or "bundle update"
Once it is completed, type "rails s"
Notice: Even after this, if your server starts but can not resolve the default page (additionally ctrl-c / ctrl-pause/break doesn't work), then add webrick instead of puma by adding the gem gem 'webrick', '~> 1.3', '>= 1.3.1'. After that, to run the webrick server you need to type
rails s -u webrick
1-go to gemfile
add the following line without any arrays only that line
gem "tzinfo-data"
then save the file
2- then on cmd type
bundle install
then press Enter
3-then also on cmd type
rails server
then press Enter
so, the gems didn't quite seem to install properly, i had to do the following
gem 'tzinfo-data'
gem 'tzinfo'
then
bundle show
to see all gems
bundle gem tzinfo
will get you the gem's directory
then, go to that directory. you will need to splice tzinfo-data into tzinfo.
in the tzinfo-data file, go to..
local_pathname/tzinfo-data-1.2014.5/lib/tzinfo
copy all the contents of this directory into...
local_pathname/tzinfo-1.2.1/lib/tzinfo
(for me this meant copying 'data' the file and 'data' the directory)
then
go to
local_pathname/tzinfo-1.2.1/lib
and open the file, tzinfo, (not the directory)
and add this line
require 'tzinfo/data'
this was such a pain to figure out
I've replaced:
gem "tzinfo-data", platforms: %i[ mingw mswin x64_mingw jruby ]
with:
gem 'tzinfo-data', '~> 1.2021', '>= 1.2021.5'
and it worked fine.
> Blockquote