[PATCH] Allow underscore '_' in field identifiers within Packages files

Gerhard Poul gerhard.poul at gmail.com
Sun Oct 15 18:23:02 UTC 2017


---
 lib/debian/debian_support.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/debian/debian_support.py b/lib/debian/debian_support.py
index 143f8a9..5812716 100644
--- a/lib/debian/debian_support.py
+++ b/lib/debian/debian_support.py
@@ -326,7 +326,7 @@ class PackageFile:
     Objects of this class can be used to read Debian's Source and
     Packages files."""
 
-    re_field = re.compile(r'^([A-Za-z][A-Za-z0-9-]+):(?:\s*(.*?))?\s*$')
+    re_field = re.compile(r'^([A-Za-z][A-Za-z0-9-_]+):(?:\s*(.*?))?\s*$')
     re_continuation = re.compile(r'^\s+(?:\.|(\S.*?)\s*)$')
 
     def __init__(self, name, file_obj=None):
-- 
2.13.5 (Apple Git-94)




More information about the pkg-python-debian-maint mailing list