diff --git a/CHANGES.md b/CHANGES.md index b485a039..a56715ca 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -2,6 +2,7 @@ * Update Beautiful Soup 4.12.2 (30c58a1) to 4.12.3 (7fb5175) * Update CacheControl 0.13.1 (783a338) to 0.14.0 (e2be0c2) +* Update feedparser 6.0.10 (9865dec) to 6.0.11 (efcb89b) * Update filelock 3.12.4 (c1163ae) to 3.14.0 (8556141) * Update idna library 3.4 (cab054c) to 3.7 (1d365e1) * Update Requests library 2.31.0 (8812812) to 2.32.3 (0e322af) diff --git a/lib/feedparser/__init__.py b/lib/feedparser/__init__.py index bdf8060c..9fa58e96 100644 --- a/lib/feedparser/__init__.py +++ b/lib/feedparser/__init__.py @@ -38,7 +38,7 @@ from .util import FeedParserDict __author__ = "Kurt McKee " __license__ = "BSD 2-clause" -__version__ = "6.0.10" +__version__ = "6.0.11" # HTTP "User-Agent" header to send to servers when downloading feeds. # If you are embedding feedparser in a larger application, you should diff --git a/lib/feedparser/api.py b/lib/feedparser/api.py index fe49c56d..4de2d271 100644 --- a/lib/feedparser/api.py +++ b/lib/feedparser/api.py @@ -314,7 +314,7 @@ def _parse_file_inplace( except xml.sax.SAXNotSupportedException: pass saxparser.setContentHandler(feed_parser) - saxparser.setErrorHandler(feed_parser) + saxparser.setErrorHandler(feed_parser) # type: ignore[arg-type] source = xml.sax.xmlreader.InputSource() # If an encoding was detected, decode the file on the fly; diff --git a/lib/feedparser/datetimes/rfc822.py b/lib/feedparser/datetimes/rfc822.py index 5f300f1d..902e9894 100644 --- a/lib/feedparser/datetimes/rfc822.py +++ b/lib/feedparser/datetimes/rfc822.py @@ -91,6 +91,10 @@ def _parse_date_rfc822(date): parts.extend(("00:00:00", "0000")) # Remove the day name if parts[0][:3] in day_names: + # Comma without spaces: + # 'Fri,24 Nov 2023 18:28:36 -0000' + if "," in parts[0] and parts[0][-1] != ",": + parts.insert(1, parts[0].rpartition(",")[2]) parts = parts[1:] if len(parts) < 5: # If there are still fewer than five parts, there's not enough diff --git a/lib/feedparser/encodings.py b/lib/feedparser/encodings.py index 01f228d1..7713d7a6 100644 --- a/lib/feedparser/encodings.py +++ b/lib/feedparser/encodings.py @@ -528,7 +528,6 @@ class MissingEncoding(io.UnsupportedOperation): class StreamFactory: - """Decode on the fly a binary stream that *may* have a known encoding. If the underlying stream is seekable, it is possible to call