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 Django 2 support and update other dependencies. #44

Open
wants to merge 33 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
33 commits
Select commit Hold shift + click to select a range
304e84f
Add PyCharm .idea/ folder to .gitignore.
kblicharski Jan 10, 2018
f09cc98
Modify models and migrations to work with Django 2.
kblicharski Jan 10, 2018
c841825
Change user.is_authenticated() to user.is_authenticated.
kblicharski Jan 10, 2018
c451a65
Change to . All tests passing.
kblicharski Jan 10, 2018
26549c0
Update dependencies.
kblicharski Jan 10, 2018
5ae36cc
Delete unneeded django_fitapp file.
kblicharski Jan 10, 2018
b587899
Update changelog and setup.py.
kblicharski Jan 10, 2018
bf2516f
Merge pull request #1 from thesignalcenter/add-django-2-support
kblicharski Jan 10, 2018
d6a90c6
Reformat project code to conform to PEP8.
kblicharski Jan 10, 2018
038f3d7
add Pipfile, update to Django 2.1
kblicharski Jun 18, 2018
6485428
revert to Django 2.0.6
kblicharski Jun 18, 2018
f451d56
Add doc for recording intraday changes and add intraday-related setting.
madsilva Jul 5, 2018
90ebad4
Make and document intraday changes to fitapp/models.py.
madsilva Jul 5, 2018
e7f98a3
Small changes and additional notes.
madsilva Jul 11, 2018
0b9ecb1
Make changes to migrations files to correctly add new intraday relate…
madsilva Jul 11, 2018
320e9bd
More notes on intraday support.
madsilva Jul 11, 2018
def759f
Change task scheduling portion of subscription view to use get_intrad…
madsilva Jul 12, 2018
efcfb82
Update intraday-support-docs.md
madsilva Jul 12, 2018
8222410
Add field to track last intraday step data.
madsilva Jul 12, 2018
e72a88f
Beign to make changes to data-pulling chain of events to allow for in…
madsilva Jul 13, 2018
51b75b6
Merge branch 'intraday-support-redo' of https://github.com/thesignalc…
madsilva Jul 13, 2018
5107a67
Quick fix for upgrading celery from 4.1 to 4.2.
madsilva Jul 23, 2018
72d1ac5
Update celery version in requirements.
madsilva Jul 23, 2018
3e79f7a
Add swappable user model.
madsilva Jul 27, 2018
32fa264
Update views.complete to account for swappable user model.
madsilva Aug 18, 2018
bb8b4ca
Modify views.complete.
madsilva Aug 18, 2018
b2e0152
Modify views.complete.
madsilva Aug 18, 2018
f150038
Experimentally remove login_required decorator from complete view.
madsilva Aug 18, 2018
dc83415
Changes needed to make data pulling work correctly.
madsilva Aug 22, 2018
268fc15
Remove login_required decorator from views.
madsilva Oct 1, 2018
0d4cc4d
Add swappable user model to migration
justin-f-perez Oct 2, 2018
cd93cbe
Fix migrations to use correct user model
justin-f-perez Oct 2, 2018
aa17ee5
Just update existing UserFitbit, dont throw error
justin-f-perez Oct 4, 2018
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
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,6 @@ docs/_build/
.coverage
htmlcov/
*~
.idea

django_fitapp
6 changes: 6 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
0.4.0 (2018-01-10)
------------------

- Adds Django 2.0.1 support
- Updates dependencies

0.3.0 (2017-01-25)
------------------

Expand Down
28 changes: 28 additions & 0 deletions Pipfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
[[source]]
url = "https://pypi.org/simple"
verify_ssl = true
name = "pypi"

[packages]
fitbit = ">=0.3.0"
celery = "*"
simplejson = "<4,>=3.13"
mock = "<3,>=2"
freezegun = "<0.4,>=0.3.9"
requests-mock = "<1.5,>=1.4.0"
Django = "<2.1,>=2.0"

[dev-packages]
six = "*"
coverage = "*"
django-debug-toolbar = "*"
tox = "*"
Sphinx = "*"
pip-review = "*"
pipdeptree = "*"

[requires]
python_version = "3.6"

[pipenv]
allow_prereleases = true
444 changes: 444 additions & 0 deletions Pipfile.lock

Large diffs are not rendered by default.

3 changes: 3 additions & 0 deletions fitapp/decorators.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,12 +42,15 @@ def my_view(request):
"""
if not msg:
msg = utils.get_setting('FITAPP_DECORATOR_MESSAGE')

def inner_decorator(view_func):
def wrapped(request, *args, **kwargs):
user = request.user
if not utils.is_integrated(user):
text = msg(request) if callable(msg) else msg
messages.error(request, text)
return view_func(request, *args, **kwargs)

return wraps(view_func)(wrapped)

return inner_decorator
5 changes: 5 additions & 0 deletions fitapp/defaults.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,3 +41,8 @@
# called with the request as the only parameter to get the final value for the
# message.
FITAPP_DECORATOR_MESSAGE = 'This page requires Fitbit integration.'

# By default, don't try to get intraday time series data. See
# https://dev.fitbit.com/docs/activity/#get-activity-intraday-time-series for
# more info.
FITAPP_GET_INTRADAY = False
Loading