There are some issues with timezone for the `DatabaseScheduler`, so we
fallback to the default one (celery.beat.PersistentScheduler) which is
simpler --doesn't allow us to change the scheduled task from the
admin, but we don't need that.
In case we need this again, we can come back when those issues are
already fixed and revert this commit.
* Upgrade docker-py to its latest version (1.10.6)
* Hardcode 1.19 as Docker version
* Upgrade to latest possible docker/requests version
* Lint
* Fix import mistake from previous merge
* Fix merge conflict on creating container host config
* Remove unused import
* create_host_config fixed by calling it from the Docker client
* Upgrade docker and requests to their latest versions
* Upgrade all packages using `pur` tool
These ones were not upgraded since they are incompatible:
* docker-py
* celery
* elasticsearch
* pyelasticsearch
* Upgrade all packages with `pur`
pur --skip django,docker-py,elasticsearch,pyelasticsearch
and some packages pinned manually to avoid conflicts with our tests.
* Downgrade commonmark to 0.5.5
In 6.x changelog
> DocParser has been renamed to Parser.
https://github.com/rtfd/CommonMark-py/releases/tag/0.6.0
and that it's not compatible with the latest version of
recommonmark (0.4.0)
* `assert_not_called` replaced by `call_count`
It doesn't receive arguments and can't be used at that point because
it was called previously by the other POST on the API:
https://docs.python.org/3/library/unittest.mock.html#unittest.mock.Mock.assert_not_called
* Upgrade packages with `pur`
$ pur --skip django-tastypie,django,docker-py,elasticsearch,pyelasticsearch,commonmark,stripe,djangorestframework
* Upgrade more packages
* Pin django-allauth to 0.32.0
django-allauth 0.33.0 doesn't support Django 1.9.x which is the
version we are using at the moment.
* Pin mkdocs to 0.15.0 for compatibility reasons
This version is the one installed by default on the venv to build the
user's documentation.
* Fix typo in method name
* Proper call to the superproject symlink on Project.save
`Project.superprojects.all()` returns `ProjectRelationship` instances
where we need to use the `parent` or `child` attribute to access to
the project itself.
(we were sending the `ProjectRelationship.pk`)
* Test for changing subproject privacy level
* Proper test for privacy level on subprojects
* Trigger re-symlink for superproject when project changes
Re-symlink when:
* a subproject is deleted
* a subproject privacy level is changed
* a subproject version privacy level is changed
* Update test case for current implementation
* Revert "Trigger re-symlink for superproject when project changes"
This reverts commit 3fe6cb3f3dfddc87d8c1e658cb7f3ebad4f6f476.
* Move logic from Form to Model
Instead of trigger the re-symlink task on each of the Form actions, we
trigger it once on ``Project.save()`` or ``Project.delete()`` method.
* Test for calls to broadcast utility on Project.save()
* Use new Celery, use new application pattern
* Use modern celery
* Drop djcelery
* New pattern for starting celery
* Bump redis to 2.10.6 to avoid startup bug, change autodiscover call
* Update docs mentioning Celery
* Goof on package name
* Missed djcelery import
* Fix rebased task that was missed
* Handle change to Celery group calls in 4.x
* Fix tests
* Fix up some linting issues and problems starting the application
* Fix celery task registration
* We don't need shared_task anymore, swap for readthedocs.worker.app.task
* Fix call to chord
* Resolve first round of linting errors in restapi.
This is a first step and only adds docstrings, etc. It doesn't refactor any
code.
Conflicts:
prospector-more.yml
readthedocs/restapi/views/model_views.py
* Reduce unused params.
In several cases, we can use the provided `request` rather than access `self`
(which could make these functions easier to test in isolation). In others, the
unused args could be folded into an unnamed kwarg param.
* Don't replace section variable.
This worked as intended, but only because the overridden section variable
would later evaluate to True. Using a different variable name makes this a bit
less error-prone.
* Minor docstring update
* Fix indent on docstring
* Punt on refactoring
* Fix call args
* Try unpinning testing reqs
* Bump up prospector higher level strictness
* Linting issues: arguments-differ, len-as-condition, redefined variables
* Remove unnecessary elses
This addresses no-else-return, which removes a `return` in an `else` after an
`if` that already has a `return`. This makes the default return more obvious in
most cases.
* Fix new linting issues with import order
Also, update travis and tox config for multiple versions of python
* Another fix on travis envs