Changes the strategy so that after a message has been put on the wait queue, it is then checked to see if it became the next message during this time and if so, immediately flushed. Will hopefully fix#451.
* Move project tests to its own directory.
* Install mock test dependency for Python2 only.
* Do not install tox inside tox environment.
* Exclude tests from sdist.
* Use recent pip on Travis-CI.
* Add custom TestUUIDModel for auto tests
* Update Binding to support models with UUIDField as primary key
Add and fix test_trigger_outbound_create_non_auto_pk.
Before updating pre_save_receiver, this new test failed with this error:
======================================================================
FAIL: test_trigger_outbound_create_non_auto_pk
(channels.tests.test_binding.TestsBinding)
----------------------------------------------------------------------
Traceback (most recent call last):
File "C:\Users\User\git\contribs\python\channels\channels\tests\test_binding.py", line 85, in test_trigger_outbound_create_non_auto_pk
self.assertEqual(received['payload']['action'], 'create')
AssertionError: u'update' != u'create'
* Fix for session shenanigans with WebsocketDemultiplexer
Session data was getting lost in the demux due to the session getting
saved after only the first connect/disconnect consumer was run.
* fix for flake8
* flake8 again
flake8 again
* User friendly way to close websocket with status
* More generic way to close(whatever) connection by exception
* Fix import ordering for exceptions (isort)
* Added accept at default behavior for websocket generic cbv and pass message instead of dict
* Fix flake8
* Use HttpClient Instead of Client
* Fix lsort
* Fixed import to resolve RemovedInDjango20Warning
That resolves: "RemovedInDjango20Warning: Importing from django.core.urlresolvers is deprecated in favor of django.urls."
* Fixed syntax error
Fixed indent
* Updated import order
* pass save's kwargs to serialize
So it can access update_fields
* added short explanation
* added missing kwargs
* use update_fields to filter fields to serialize
* save kwargs on self
* get signal_kwargs from self
* whitespace
* just save signal_kwargs on self+removed left over kwargs
* Add Delay Protocol Server
Add a process that listens to a specific channel
and delays incoming messages by a given time.
* Add custom django command rundelay
* Add test suite
* Implements #115
* Add channels.delay app
* Add AppConfig
* Move rundelay command to channels.delay app
* Refactor DelayedMessage into model
Move login into a database backed model.
* Update Worker
* Add migration
* Add delay docs page
* Add to TOC
* Fix import sorting
* Add ASGI spec document for Delay Protocol
* Update channels.delay doc with new channel name
* remove interval docs
* Refactor Delay to use milliseconds instead of seconds
Use milliseconds as the default unit. Gives more control to developers.
* Remove interval logic from DelayedMessage
* Remove interval tests
* Tweak test logic to use milliseconds
* Pass FORCE_SCRIPT_NAME to Daphne server when set
FORCE_SCRIPT_NAME seems not to be honored any more with build-in runserver after activating channels app.
The normal behavior of Django is the FORCE_SCRIPT_NAME is used as prefix when set while generating URLs so its possible to
create a path prefix and determine different Django installations based on the path rather than hostname without having to prefix all paths in urls.py.
* Only strip script_name from path if it starts with it
* make tests happy again after setting kwarg root_path
* added http_timeout as a comand line option for runserver
* possible improvement for input param management
* explicitly set the default http_timeout in add_argument