summaryrefslogtreecommitdiff
path: root/cherrypy/lib/static.py
Commit message (Collapse)AuthorAgeFilesLines
* Remove reliance on sixJason R. Coombs2018-09-021-2/+1
|
* Use bytes literals where appropriatev14.0.0Jason R. Coombs2018-02-041-3/+3
|
* Wrap MIME-type init into a function definitionSviatoslav Sydorenko2017-12-121-6/+11
|
* Adjust indentation in cherrypy.lib.staticSviatoslav Sydorenko2017-12-121-1/+1
|
* Correcting the initialization of the mimetypes libraryJohan De Taeye2017-12-111-1/+2
|
* Use platform.system for platform detection. Update docstring to include an ↵Jason R. Coombs2017-10-281-5/+7
| | | | authoritative reference.
* File in sub-dir of staticdir in long-path notation would not loadSafihre2017-10-151-0/+7
|
* Fix email.generator._make_boundary compat importSviatoslav Sydorenko2017-08-111-6/+1
| | | | Reported by lgtm.com
* Fix io.UnsupportedOperation reported by lgtm.comSviatoslav Sydorenko2017-08-111-4/+1
|
* Make cherrypy.lib.static PEP 257 compliantSviatoslav Sydorenko2017-08-111-2/+2
|
* Rely on six for urllib moves.Jason R. Coombs2017-07-091-2/+4
|
* Convert all strings to conform single-quoted styleSviatoslav Sydorenko2016-09-081-28/+28
| | | | pre-commit run double-quote-string-fixer --all-files
* Also include ValueError. Fixes failing test on Python 3.5.Jason R. Coombs2015-12-191-1/+4
|
* Returning HTTP 404 for static serving when the requested path has null bytesDiogo Baeder2015-12-171-1/+1
|
* Reorganize imports to conform to conventionJason R. Coombs2014-09-131-9/+11
|
* Remove unused importsJason R. Coombs2014-09-131-2/+0
|
* More PEP8 work.Gustavo Picon2014-01-121-10/+17
|
* Running: autopep8 -vvvvv -i `find . -name '*.py'`Gustavo Picon2014-01-121-10/+18
| | | | | --HG-- branch : autopep8
* Removed trailing whitespace from the codebase.Gustavo Picon2012-04-031-38/+38
| | | | sed -i '' -e 's/ *$//' `find cherrypy -name '*.py'`
* Bye bye, py2/3.Robert Brewer2011-07-021-0/+363
|
* Bringing python3 back into trunk with its own py3 folder; what was in trunk ↵trunkRobert Brewer2011-02-251-352/+0
| | | | goes in the py2 folder, and we can use a single setup.py to install either, depending on the version of Python that runs setup.py install.
* Freeow. The magic cherrypy/_cpcompat.py module to take all our py3k fears away.Robert Brewer2011-02-241-11/+11
|
* Sphinx docs (rsts) for rest of cherrypy.lib.*chbrown2010-02-241-18/+24
|
* Final fix for #915 (Add "debug=False" arg to builtin Tools).Robert Brewer2009-08-061-14/+65
|
* All internals now use cherrypy.serving.request/response instead of ↵Robert Brewer2009-06-221-13/+15
| | | | request/response for a speed boost.
* Added a cautionary note to the docstring for serve_fileobj(), regarding the ↵visteya2009-06-101-0/+7
| | | | seek() performed on the file object when the request has a 'Range' header, and how this may result in incorrect behavior.
* More syncs with python3.Robert Brewer2009-06-091-2/+2
|
* static.serve_fileobj: Allow file-like objects that have no 'fileno' attribute.Robert Brewer2009-06-071-9/+12
|
* New static.serve_fileobj function.Robert Brewer2009-06-071-16/+57
|
* trunk: A bunch more alignments between trunk and python3 syntax.Robert Brewer2009-06-021-1/+1
|
* trunk - Porting the cherrypy.lib.httputil name change. It'll be easier to ↵Lakin Wecker2009-05-311-3/+3
| | | | maintain two released branches if the modules are named the same. However, in the 2.6 branch we'll leave cherrypy.lib.http working and deprecate it for 3.3.
* Fix for #879 (static.serve_file() should use "application/octet-stream" if ↵Robert Brewer2009-03-181-2/+3
| | | | it can't determine Content-Type).
* Added the mimetypes mentioned in #879.Robert Brewer2009-03-181-0/+2
|
* Now that error_log defaults to INFO, we can emit a DEBUG message once in a ↵Robert Brewer2009-02-251-0/+4
| | | | great while (but not too many; they're still slow even if they never emit).
* Long-standing misfeature: staticdir/file should only answer to GET/HEAD.Robert Brewer2009-02-251-0/+6
|
* New test for streaming static files.Robert Brewer2009-02-101-8/+7
|
* Change lib.static.serve_file() to use a file generator for requests with ↵visteya2008-09-281-3/+6
| | | | Ranges, rather than read entire range into memory. Closes #859.
* Docstring updates.Robert Brewer2008-06-041-2/+25
|
* Doc tweak.Robert Brewer2008-05-151-1/+2
|
* Moved mimetools to only import if needed.Robert Brewer2008-03-141-1/+1
|
* Static tool: allow the use of ~ as a placeholder for a the user's home ↵Lakin Wecker2007-10-161-0/+3
| | | | directory in the path names.
* Fix for #689 (add equivalent of trailing_slash tool for static content). The ↵Robert Brewer2007-06-161-1/+3
| | | | staticdir tool now sets request.is_index if needed. The trailing_slash tool priority was increased to allow most before_handler tools a chance to set is_index.
* Trunk fix for #577 (GzipFilter doesn't force an update of the Content-Length ↵Robert Brewer2006-10-201-2/+4
| | | | header). All code which could change the length of response.body should delete the Content-Length header (if already set).
* Inline isdir to save a call to os.stat.Robert Brewer2006-10-191-4/+6
|
* Fix to 2.1, 2.2, 3.0 for bugs in Range slicing and final boundary. Also made ↵Robert Brewer2006-09-021-5/+11
| | | | the output match Apache output (CRLFs).
* API and docstring cleanups:Robert Brewer2006-08-261-2/+2
| | | | | | | | 1. Removed WrongConfigValue, decorate, decorate_all, and ExposeItems. 2. Moved cherrypy.logtime to cherrypy.log.time. 3. Reduced cherrypy.config.globalconf back to just cherrypy.config. 4. Moved _cpconfig.default_conf to config.defaults. .
* Overhaul of config system:Robert Brewer2006-08-241-2/+0
| | | | | | | | | | | | | | | | | 1. New docstring for config module! 2. Put all entries into a config namespace. New deadlock, log, request and response namespaces. 3. Request and response entries now directly modify attributes of cherrypy.request and .response, and consumer code looks up those attributes, not config. This also allows interactive inspection of defaults. 4. Removed 'log_config' config entry. Use engine.on_start_engine_list.append(config.log_config) instead. 5. Old 'dispatch' entry is now 'request.dispatch'. 6. New log entries: log.error.file, log.error.function, log.access.file, log.access.function, log.screen. 7. 'server.max_request_body_size' is now 'request.max_body_size'. 8. environments now only apply to globalconf. 9. The 'development' environment has been removed, since its settings were all the default anyway. 10. The 'embedded' environment has been removed, since it duplicates the 'production' environment now. 11. There's a new 'test_suite' environment. 12. Removed log_file_not_found (from static.py). Something still needs to be done to config.wrap, so it can take dotted names as kwarg keys.
* Lots of mixedCase to lower_with_underscores.Robert Brewer2006-08-121-3/+3
|
* Fix for #547 (serve_file still uses contentType instead of content_type). ↵Robert Brewer2006-08-121-7/+7
| | | | Thanks, michele!
* WSGI-related changes:Robert Brewer2006-08-071-1/+1
| | | | | | | 1. Changed Request.run from request_line arg to deconstructed args: method, path, query_string, and protocol. 2. Moved HTTP protocol checking from _cprequest to _cpwsgiserver. What was cherrypy.response.version is now cherrypy.request.protocol (tuple form of SERVER_PROTOCOL). request.version and response.version attributes removed. _cpwsgiserver now writes out server.protocol, not SERVER_PROTOCOL (which is a misnomer, it really should have been REQUEST_PROTOCOL). 3. path unquoting was also moved from _cprequest to _cpwsgiserver (like most other WSGI servers). 4. New test for absoluteURI in the Request-Line.