Package: whirlwind-web
A wrapper around the tornado web server.Changlog0.12.0 - 14 April 2021Add a newmake_applicationhook to the Server for changing the WSGI appMade it easier to alter what gets logged0.11.0 - 26 March 2021Addedserver_end_futureto the Server objectAddedannounce_startandmake_http_serverhooks to ServerThe http server and routes we make is now put onto the server object inserveThe default error catcher will return a “RequestCancelled” error if the
request raisesasyncio.CancelledError0.10.1 - 8 January 2021Removed the wait_for_futures helper. It’s not a great implementation.The server now usesawait self.wait_for_end()to wait till we should
shut down the server. By default this doesawait self.final_futurelike it
already was doing.0.10.0 - 25 October 2020Removed whirlwind.test_helpersIt was random and didn’t work well in an async contextUsed asynctest which has warnings past python3.7 and isn’t necessary anymore0.9.0 - 10 May 2020The SimpleWebSocketBase and WSHandler handlers now take in afinal_futurewhich is used to stop the websocket stream when it is
cancelled.Websocket streams that take in child messages will now use the request
future on the websocket to know when to stop.0.8.0 - 12 March 2020The status of a response when there is an exception will now look at:If the msg is a dictionary, it’ll get “status” from that dictionary if it has thatIf the exception has a “status” property, the status will be that valueOtherwise the status will be 5000.7.2 - 6 March 2020Fix a small mistake that meant http handlers weren’t logging even iflog_exceptions=Falsewasn’t specified.0.7.1 - 6 March 2020Made it possible to accept files into a commander command. You can do this
by sending amultipart/form-datato the endpoint. The body of the
command will be extracted from a__body__file you provide.HTTP and WebSocket handlers can now be told not to log exceptions by giving
them a class levellog_exceptions = Falseattribute.0.7 - 3 February 2020Made transform_progress responsible for name spacing the progress messagesStore commands can now be interactive. If you define the execute method as
taking inmessages, then you can process extra messages sent to that
command. You then define what messages it accepts by using thestore.commanddecorator with theparentoption as the interactive
command.Reusing a command with a different path is now an error0.6 - 18 September 2019Migrated todelfick_project0.5.3 - Dec 26 2018WSHandler now has a connection_future that is cancelled if we lose the
connection0.5.2 - Oct 25 2018Added a message_done hook to SimpleWebSocketBaseFixed the test helpers so that you aren’t left with no set asyncio loop0.5.1 - Oct 24 2018Made the__server_time__message for SimpleWebSocketBase optional.Made sure to actually use the reprer set on request handlersProgressMessageMaker doesn’t nest dictionaries it receivesAdded a transform_progress hook to SimpleWebSocketBase0.5 - Oct 22 2018Initial ReleaseInstallationThis package is released to pypi under the namewhirlwind-web. When you add
this package to your setup.py it is recommended you either specify[peer]as
well or pininput_algorithms,option_mergeandtornadoto particular
versions.  Seehttps://github.com/delfick/whirlwind/blob/main/setup.py#L24-L28for the recommended versions.For example:fromsetuptoolsimportsetup,find_packagessetup(name="test",version="0.1",include_package_data=True,install_requires=["whirlwind-web[peer]","whirlwind-web==0.5.2"])Running the testsTo run the tests, create and activate a virtualenv somewhere and then:$ pip install -e ".[peer,tests]"
$ pip install -e .followed by./test.shAlternatively:$ pip install tox
$ toxUsageSeehttps://whirlwind.readthedocs.io/en/latest/for usage documentation.