Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade gem to ruby 2.6 #4

Open
ck2000 opened this issue Feb 7, 2021 · 1 comment
Open

Upgrade gem to ruby 2.6 #4

ck2000 opened this issue Feb 7, 2021 · 1 comment

Comments

@ck2000
Copy link

ck2000 commented Feb 7, 2021

I am receiving some deprecating warnings with ruby 2.6.3 e.g.:

warning: BigDecimal.new is deprecated; use BigDecimal() method instead.

If I am running via rails console the following:

tax = Taxger::Lohnsteuer.calculate(2015, stkl: 1, lzz: 1, re4: 70_000 * 100)

Traceback (most recent call last):
        1: from (irb):5
NoMethodError (undefined method `divide' for 0.0:BigDecimal)
Did you mean?  divmod

Could someone please help me out with these two messages?
Cheers

@ck2000
Copy link
Author

ck2000 commented Feb 7, 2021

I am been trying the solve the deprecated warnings by replacing BigDecimal.new is deprecated; use BigDecimal(). Now I am receiving another error message:

2.6.3 :001 > tax = Taxger::Lohnsteuer.calculate(2015, stkl: 1, lzz: 1, re4: 70_000 * 100)
"year {:stkl=>1, :lzz=>1, :re4=>7000000}"
Traceback (most recent call last):
        5: from (irb):1
        4: from lib/taxger/lohnsteuer.rb:24:in `calculate'
        3: from lib/taxger/lohnsteuer.rb:24:in `map'
        2: from lib/taxger/lohnsteuer.rb:24:in `each'
        1: from lib/taxger/lohnsteuer.rb:25:in `block in calculate'
NoMethodError (private method `BigDecimal' called for Taxger::Lohnsteuer:Module)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant