Repository navigation
uninitialized constant DeepL::VERSION in v3.6.1 #17
Description
Activity
I cannot reproduce this,
rails sgives me=> Booting Puma => Rails 8.1.1 application starting in development => Run `bin/rails server --help` for more startup options Puma starting in single mode... * Puma version: 7.1.0 ("Neon Witch") * Ruby version: ruby 3.4.8 (2025-12-17 revision 995b59f666) +PRISM [arm64-darwin25] * Min threads: 3 * Max threads: 3 * Environment: development * PID: 80054 * Listening on http://127.0.0.1:3000 * Listening on http://[::1]:3000 Use Ctrl-C to stopIn your gem installation, do you have the
lib/version.rbfile which definesDeepL::VERSION? linkI use this GEM in several applications, and the problem occurs in all applications in versions from v3.4 onwards. I will check this again in more detail and then get back to you.
lib/version.rbis present in all local gem installations.@341bms if you are using 3.4 version, try to make sure if the version installed is 3.4.0, because upgrading from version 3.3 all the minor versions 3.4.0, 3.5.0 and 3.6.0 are broken. I tested all of them to be sure.
To fix that, try to upgrade the last patch versions, so if you are using 3.4.0, them upgrade to 3.4.1. The same for all the next minor updates 3.5 and 3.6. I have just already tested each one as well to make sure those patches upgrades fixed that issue.
Here is the commit with those fixes: v3.6.0...v3.6.1
Maybe would be important to clarify this issue in the documentation, to avoid wasting time testing each version to find out which one is broken or not.
PS: simply running
bundle installdoesnt guarantee its going to install the latest version, unless you removed the gem fromGemfilerunbundle install, add to theGemfileagain and runningbundle install. The correct way to make sure that updates to the latest version is by runningbundle update deepl-rb, or by freezing the specific version in Gemfile asgem "deepl-rb", "3.6.1"then you can runbundle installnormally.We are still seeing this issue with 3.6.1. The
require 'version'is not loading the version correctly because it's resolving to another gem'sversion.rb.I was able to resolve by updating
require 'version'torequire_relative 'version'.It's also worth updating the
require 'http_client_options'line as well torequire_relative.I added a PR to fix #18
Reacted by Richard Young- added a commit that references this issue
on Apr 10, 2026 - added a commit that references this issue
on Apr 13, 2026 Keeping this open until we release 3.6.2
Bug Report:
uninitialized constant DeepL::VERSIONin v3.6.1Description
When configuring the DeepL gem in a Rails initializer, an
uninitialized constant DeepL::VERSION (NameError)is raised during theDeepL.configurecall. The error originates fromlib/deepl/configuration.rb:49in theconstruct_user_agentmethod.Steps to Reproduce
gem 'deepl-rb', require: 'deepl'to Gemfilebundle installconfig/initializers/deepl.rbwith:rails sExpected Behavior
The DeepL gem should configure successfully without errors.
Actual Behavior
The application fails to start with the following error:
Full Stack Trace