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

Add Python 2.7 sunset message to Calculator constructor #1923

Merged
merged 1 commit into from
Mar 16, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions taxcalc/calculate.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
# pylint: disable=invalid-name,no-value-for-parameter,too-many-lines

import os
import sys
import json
import re
import copy
Expand Down Expand Up @@ -146,6 +147,11 @@ def __init__(self, policy=None, records=None, verbose=True,
print('Tax-Calculator startup automatically ' +
'extrapolated your data to ' +
str(self.__records.current_year) + '.')
if verbose and sys.version_info.major == 2: # running Python 2.7
print('WARNING: Tax-Calculator packages for Python 2.7 will')
print(' no longer be provided beginning in 2019')
print(' because Pandas is stopping development for 2.7.')
print('SOLUTION: upgrade to Python 3.6 now.')
assert self.__policy.current_year == self.__records.current_year
self.__stored_records = None

Expand Down