theunraveler / taskwarrior-web

A web interface for the Taskwarrior todo application. Because being a neckbeard is only fun sometimes.
http://theunraveler.github.com/taskwarrior-web
MIT License
526 stars 63 forks source link

Launch fails with "undefined method `new' for BigDecimal:Class" #152

Open martinstut opened 3 years ago

martinstut commented 3 years ago

When I try launching task-web after a fresh install, I get this error message:

martin@ubumartin16:~$ task-web
Traceback (most recent call last):
    17: from /usr/local/bin/task-web:23:in `<main>'
    16: from /usr/local/bin/task-web:23:in `load'
    15: from /var/lib/gems/2.7.0/gems/taskwarrior-web-1.1.12/bin/task-web:6:in `<top (required)>'
    14: from /usr/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in `require'
    13: from /usr/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:92:in `require'
    12: from /var/lib/gems/2.7.0/gems/taskwarrior-web-1.1.12/lib/taskwarrior-web.rb:5:in `<top (required)>'
    11: from /usr/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:72:in `require'
    10: from /usr/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:72:in `require'
     9: from /var/lib/gems/2.7.0/gems/activesupport-3.2.22.5/lib/active_support/core_ext.rb:1:in `<top (required)>'
     8: from /var/lib/gems/2.7.0/gems/activesupport-3.2.22.5/lib/active_support/core_ext.rb:1:in `each'
     7: from /var/lib/gems/2.7.0/gems/activesupport-3.2.22.5/lib/active_support/core_ext.rb:2:in `block in <top (required)>'
     6: from /usr/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:72:in `require'
     5: from /usr/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:72:in `require'
     4: from /var/lib/gems/2.7.0/gems/activesupport-3.2.22.5/lib/active_support/core_ext/object.rb:3:in `<top (required)>'
     3: from /usr/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:72:in `require'
     2: from /usr/lib/ruby/2.7.0/rubygems/core_ext/kernel_require.rb:72:in `require'
     1: from /var/lib/gems/2.7.0/gems/activesupport-3.2.22.5/lib/active_support/core_ext/object/duplicable.rb:109:in `<top (required)>'
/var/lib/gems/2.7.0/gems/activesupport-3.2.22.5/lib/active_support/core_ext/object/duplicable.rb:111:in `<class:BigDecimal>': undefined method `new' for BigDecimal:Class (NoMethodError)

OS is Ubuntu Mate 20.04 LTS with current updates. Ruby version 2.7, gem update has updated everything fine.

Output of task _version: 2.5.1

Output of gem list bigdecimal :

*** LOCAL GEMS ***
bigdecimal (3.0.2, default: 2.0.0)

Output of gem list activesupport

*** LOCAL GEMS ***
activesupport (6.1.3.2, 5.2.3, 3.2.22.5)

Searching the web turns out many people have issues with Ruby 2.7 and bigdecimal.

How can I launch task-web without downgrading the my entire Ruby environment?

paultheastronomer commented 2 years ago

I have the same problem. Any solution?

ronstone2000 commented 2 years ago

Same issue here with 2.6. I don't see much activity, perhaps task warrior-web is no longer supported?

klaygomes commented 2 years ago

Including:

gem 'bigdecimal', '1.3.0'

On my Gemfile fixed the problem.

Danieliv commented 2 years ago

Including:

gem 'bigdecimal', '1.3.0'

On my Gemfile fixed the problem.

Thanks. I spent like 4 hours until I found this and it works perfectly. 👍

BlueNalgene commented 1 year ago

Including:

gem 'bigdecimal', '1.3.0'

On my Gemfile fixed the problem.

This did not work for me on Kubuntu 22.04 with ruby 3.0.2p107, but it gave me the hint I needed. I needed to add

s.add_dependency('bigdecimal', '1.3.0')

to taskwarrior-web.gemspec instead.