b-k/py1040

Calculated taxable income incorrect

Closed this issue · 4 comments

The calculated taxable income does not match the 2019 tax table. Is this perhaps using a tax table from a previous year?

b-k commented

The calculation is at the top of forms/f1040.js. There's a link there to the IRS's 2019 rate schedules on page seven of the F1040-ES instructions. The constants look like the right ones. Does anything look amiss in the calculation there?

Thanks for the response. I made a typo in my question, I was referring to line 11a tax rather than taxable income. So what I meant to say was given the taxable income (line 10 in form 1040) the calculation for line 11a: tax was not matching the 2019 tax table https://www.irs.gov/pub/irs-pdf/i1040tt.pdf

Also want to confirm you mean 1040.js/forms/f1040.m4 correct? I see it says "2018 tax rate schedules" in the comment at the top of the page. If the calculation is using the 2018 tax table rather than 2019 maybe that's the reason?

On looking into this further, this was an issue on my end. When I set my capital gains tax to 0 then I end up with the correct tax using this tool (assuming we round up to nearest integer since tool gives fractions whereas the table gives whole numbers). Then I figured out my error of not adding qualified dividends into all dividends in inform.py
Since my all dividends field was smaller than my qualified dividends it was subtracting out qualified dividends and outputting a lower than expected tax value. Thanks for the help! The graph tool on the js repo was very helpful in debugging this