diff options
| author | Frazer Clews <frazer.clews@codethink.co.uk> | 2020-01-16 16:55:18 +0000 |
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2020-01-19 13:31:05 +0000 |
| commit | 0ac5174c7d39a3e49893df0d517d47bec1935555 (patch) | |
| tree | 479496afb1da7814071e39e888e8926cd03bec57 /bitbake/lib/bs4/dammit.py | |
| parent | 444bcb6cb6be8d5205fc88790360d864e633a555 (diff) | |
| download | poky-0ac5174c7d39a3e49893df0d517d47bec1935555.tar.gz | |
bitbake: lib: remove unused imports
removed unused imports which made the code harder to read, and slightly
but less efficient
(Bitbake rev: 4367692a932ac135c5aa4f9f2a4e4f0150f76697)
Signed-off-by: Frazer Clews <frazer.clews@codethink.co.uk>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/bs4/dammit.py')
| -rw-r--r-- | bitbake/lib/bs4/dammit.py | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/bitbake/lib/bs4/dammit.py b/bitbake/lib/bs4/dammit.py index 805aa908a5..7ad9e0dd1e 100644 --- a/bitbake/lib/bs4/dammit.py +++ b/bitbake/lib/bs4/dammit.py | |||
| @@ -8,12 +8,10 @@ XML or HTML to reflect a new encoding; that's the tree builder's job. | |||
| 8 | """ | 8 | """ |
| 9 | __license__ = "MIT" | 9 | __license__ = "MIT" |
| 10 | 10 | ||
| 11 | from pdb import set_trace | ||
| 12 | import codecs | 11 | import codecs |
| 13 | from html.entities import codepoint2name | 12 | from html.entities import codepoint2name |
| 14 | import re | 13 | import re |
| 15 | import logging | 14 | import logging |
| 16 | import string | ||
| 17 | 15 | ||
| 18 | # Import a library to autodetect character encodings. | 16 | # Import a library to autodetect character encodings. |
| 19 | chardet_type = None | 17 | chardet_type = None |
| @@ -38,12 +36,6 @@ except ImportError: | |||
| 38 | def chardet_dammit(s): | 36 | def chardet_dammit(s): |
| 39 | return None | 37 | return None |
| 40 | 38 | ||
| 41 | # Available from http://cjkpython.i18n.org/. | ||
| 42 | try: | ||
| 43 | import iconv_codec | ||
| 44 | except ImportError: | ||
| 45 | pass | ||
| 46 | |||
| 47 | xml_encoding_re = re.compile( | 39 | xml_encoding_re = re.compile( |
| 48 | r'^<\?.*encoding=[\'"](.*?)[\'"].*\?>'.encode(), re.I) | 40 | r'^<\?.*encoding=[\'"](.*?)[\'"].*\?>'.encode(), re.I) |
| 49 | html_meta_re = re.compile( | 41 | html_meta_re = re.compile( |
