./www/py-multipart, Parser for multipart/form-data

[ CVSweb ] [ Homepage ] [ RSS ] [ Required by ] [ Add to tracker ]


Branch: CURRENT, Version: 1.2.1, Package name: py312-multipart-1.2.1, Maintainer: pkgsrc-users

This module provides a parser for the multipart/form-data format.
It can read from a file, a socket or a WSGI environment. The parser
can be used to replace cgi.FieldStorage to work around its limitations.


Master sites:

Filesize: 35.651 KB

Version history: (Expand)


CVS history: (Expand)


   2024-11-30 09:56:15 by Adam Ciarcinski | Files touched by this commit (2) | Package updated
Log message:
py-multipart: updated to 1.2.1

Release 1.2

This release improves error handling, documentation and performance, fixes
several parser edge-cases and adds new functionality. API changes are backwards
compatible.

* feat: Split up `MultipartError`` into more specific exceptions and add HTTP
  status code hints. All exceptions are subclasses of `MultipartError`.
* feat: New `parse_form_data(ignore_errors)` parameter to throw exceptions in
  non-strict mode, or suppress exceptions in strict mode. Default behavior does
  not change (throw in strict-mode, ignore in non-strict mode).
* feat: New `is_form_request(environ)` helper.
* feat: New specialized `content_disposition_[un]quote` functions.
* feat: `parse_options_header()` can now use different unquote functions. The
  default does not change.
* fix: `parse_form_data()` no longer checks the request method and the new
  `is_form_request` function also ignores it. All methods can carry parse-able
  form data, including unknown methods. The only reliable way is to check the
  `Content-Type` header, which both functions do.
* fix: First boundary not detected if separated by chunk border.
* fix: Allow CRLF in front of first boundary, even in strict mode.
* fix: Fail fast if first boundary is broken or part of the preamble.
* fix: Fail if stream ends without finding any boundary at all.
* fix: Use modern WHATWG quoting rules for field names and filenames.
  Legacy quoting is still supported as a fallback.
* fix: `MultiDict.get(index=999)` should return default value, not throw IndexError.
* docs: Lots of work on docs and docstrings.
* perf: Multiple small performance improvements
* build: Require Python 3.8
   2024-10-25 15:03:43 by Adam Ciarcinski | Files touched by this commit (3) | Package updated
Log message:
py-multipart: updated to 1.1.0

Release 1.1

This release could have been a patch release, but some of the fixes include \ 
change in behavior to match documentation or specification. None of them should \ 
be a surprise or have an impact on real-world clients, though. Existing apps \ 
should be able to upgrade without issues.

fix: Fail faster on input with invalid line breaks
fix: Allow empty segment names
fix: Avoid ResourceWarning when using parse_form_data
fix: MultipartPart now always has a sensible content type.
fix: Actually check parser state on context manager exit.
fix: Honor Content-Length header, if present.
perf: Reduce overhead for small segments (-21%)
perf: Reduce write overhead for large uploads (-2%)

Release 1.0

This release introduces a completely new, fast, non-blocking  \ 
PushMultipartParser parser, which now serves as the basis for all other parsers.

feat: new PushMultipartParser parser.
change: Parser is stricter by default and now rejects clearly broken input. This \ 
should not affect data sent by actual browsers or HTTP clients, but may break \ 
some artificial unit tests. * Fail on invalid line-breaks in headers or around \ 
boundaries. * Fail on invalid header names.
change: Default charset for segment headers and text fields changed to utf8, as \ 
recommended by W3C HTTP.
change: Default disk and memory limits for MultipartParser increased, but \ 
multiple other limits were introduced to allow finer control. Check if the new \ 
defaults still fit your needs.
change: Several undocumented APIs were deprecated or removed, some of which were \ 
not strictly private but should only be used by the parser itself, not by \ 
applications.
   2024-06-19 07:03:05 by Adam Ciarcinski | Files touched by this commit (3) | Package updated
Log message:
py-multipart: updated to 0.2.5

0.2.5 (18.06.2024)
* Don't test semicolon separators in urlencoded data
* Add python-requires directive, indicating Python 3.5 or later is required and \ 
preventing older Pythons from attempting to download this version
* Add official support for Python 3.10-3.12
* Default value of copy_file should be 2 ** 16, not 2 * 16
* Update URL for Bottle
   2022-01-04 21:55:40 by Thomas Klausner | Files touched by this commit (1595)
Log message:
*: bump PKGREVISION for egg.mk users

They now have a tool dependency on py-setuptools instead of a DEPENDS
   2021-12-19 15:16:04 by Thomas Klausner | Files touched by this commit (1)
Log message:
py-multipart: not for python 2.7
   2021-11-25 13:11:44 by Thomas Klausner | Files touched by this commit (1)
Log message:
py-multipart: pkglint cleanup
   2021-11-25 13:10:40 by Thomas Klausner | Files touched by this commit (4)
Log message:
www/py-multipart: import py-multipart-0.2.4

This module provides a parser for the multipart/form-data format.
It can read from a file, a socket or a WSGI environment. The parser
can be used to replace cgi.FieldStorage to work around its limitations.