From 78522f6604cc007a70a1708e3d227f71d286ae6f Mon Sep 17 00:00:00 2001 From: Will Kahn-Greene Date: Mon, 27 Nov 2017 11:54:44 -0500 Subject: [PATCH 1/2] Document exceptions in constants module --- html5lib/constants.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/html5lib/constants.py b/html5lib/constants.py index 4f967cb6..082219eb 100644 --- a/html5lib/constants.py +++ b/html5lib/constants.py @@ -2939,8 +2939,14 @@ class DataLossWarning(UserWarning): + """Raised whenever html5lib changes something in such a way that some input data is lost""" pass class ReparseException(Exception): + """Raised when the parser should restart parsing + + This is used when the parsing discovers a new encoding that should be used. + + """ pass From ef7c7634c1195926173ea783923922d14ec8cede Mon Sep 17 00:00:00 2001 From: Will Kahn-Greene Date: Tue, 28 Nov 2017 15:30:16 -0500 Subject: [PATCH 2/2] Adjust docstrings based on comments --- html5lib/constants.py | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/html5lib/constants.py b/html5lib/constants.py index 082219eb..c0db14f1 100644 --- a/html5lib/constants.py +++ b/html5lib/constants.py @@ -2939,14 +2939,9 @@ class DataLossWarning(UserWarning): - """Raised whenever html5lib changes something in such a way that some input data is lost""" + """Raised when the current tree is unable to represent the input data""" pass class ReparseException(Exception): - """Raised when the parser should restart parsing - - This is used when the parsing discovers a new encoding that should be used. - - """ pass pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy