Adam Hopkins
b958cdc151
Additonal annotations
2021-01-29 16:19:10 +02:00
Adam Hopkins
8f4e0ad3c8
Raise ValueError when cookie max-age is not an integer ( #2001 )
...
* Raise valueerror when cookie max-age is not an integer
2021-01-19 01:11:39 +02:00
L. Kärkkäinen
0a25868a86
HTTP1 header formatting moved to headers.format_headers and rewritten. ( #1669 )
...
* HTTP1 header formatting moved to headers.format_headers and rewritten.
- New implementation is one line of code and twice faster than the old one.
- Whole header block encoded to UTF-8 in one pass.
- No longer supports custom encode method on header values.
- Cookie objects now have __str__ in addition to encode, to work with this.
* Add an import missed in merge.
2019-12-23 17:30:45 -06:00
Leonardo Teixeira Menezes
08794ae1cf
Enforce Datetime Type for Expires on Set-Cookie ( #1484 )
...
* Enforce Datetime Type for Expires on Set-Cookie
* Fix lint issues
* Format code and improve error type
* Fix import order
2019-02-06 12:29:33 -06:00
Raphael Deem
d418cc9950
formatting
2019-01-12 20:41:35 -08:00
Raphael Deem
7067295e67
enforce integer for max-age cookie
2019-01-12 20:41:35 -08:00
Harsha Narayana
e6fba01682
add documentation for cookies, exception, blueprint and handlers
...
Signed-off-by: Harsha Narayana <harsha2k4@gmail.com>
2018-12-28 10:22:28 +05:30
Adam Hopkins
c708e8425f
Fix documentation build errors
2018-10-26 11:57:28 +03:00
Yun Xu
8ef7bf8e7b
integrate with isort
2018-10-17 21:20:16 -07:00
Yun Xu
aa9bf04dfe
run black against sanic module
2018-10-13 17:55:33 -07:00
7
334649dfd4
Fix response ci header ( #1244 )
...
* add unit tests, which should fail
* fix CIDict
* moving CIDict to avoid circular imports
* fix unit tests
* use multidict for headers
* fix cookie
* add version constraint for multidict
* omit test coverage for __main__.py
* make flake8 happy
* consolidate check in for loop
* travisci retry build
2018-07-11 01:44:21 -07:00
Raphael Deem
5ee35e7eeb
add samesite cookie to cookie keys
2017-12-24 02:33:52 -08:00
Raphael Deem
d876e3ed5c
fix false cookie encoding and output
2017-10-05 22:20:50 -07:00
Jeremy Zimmerman
f39512aa63
double if statement ( #707 )
...
* Migrated `%` string formating
* double if statement
combined double 'if' to a single 'if' with 'and'
* Revert "Fix "Prefer `format()` over string interpolation operator" issue"
2017-05-11 11:49:32 -07:00
sourcepirate
63c24122db
Removed raw string in cookies documentation
2017-03-22 06:39:23 +05:30
Raphael Deem
6726affa7e
isinstance -> try/except
2017-02-15 19:34:45 -08:00
Angus Hollands
51611c3934
Pep8 cleanups ( #429 )
...
* PEP8 cleanups
* PEP8 cleanups (server.py)
* PEP8 cleanups (blueprints.py)
* PEP8 cleanups (config.py)
* PEP8 cleanups (cookies.py)
* PEP8 cleanups (handlers.py)
* PEP8 cleanups (request.py)
* PEP8 cleanups (response.py)
* PEP8 cleanups (router.py)
* PEP8 cleanups (sanic.py) #2
* PEP8 cleanups (server.py) #2
* PEP8 cleanups (static.py)
* PEP8 cleanups (utils.py)
* PEP8 cleanups (views.py)
Updated docstring
2017-02-14 13:10:19 -06:00
Raphael Deem
a162f2ce34
Merge branch 'master' into cookie-usability
2017-01-25 21:24:30 -08:00
Raphael Deem
3c355f19eb
false cookie attributes should not be set
2017-01-25 16:47:14 -08:00
Channel Cat
d0a121ad06
Added del cookie and default path
2017-01-25 01:53:39 -08:00
Eli Uriegas
edb12da154
Fix the flake8 error caused by new flake8 version
2016-11-16 12:55:13 -06:00
Channel Cat
9c16f6dbea
Fix flake8 issues
2016-10-25 01:36:12 -07:00
Channel Cat
c50aa34dd9
Lazy cookie creation
2016-10-25 01:27:54 -07:00