[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

[Git][ftp-team/dak][master] 2 commits: daklib/checks.py: Reject binary packages using `unknown` as section



Title: GitLab

Joerg Jaspert pushed to branch master at Debian FTP Team / dak

Commits:

  • b9bbc46d
    by Niels Thykier at 2024-12-15T09:08:24+00:00
    daklib/checks.py: Reject binary packages using `unknown` as section
    
    Previously, these would have gone through (and probably ended up in
    NEW where it would then be manually rejected). With this change, we
    just reject them early.
    
    This is mostly useful if `dpkg` were to automatically populuate
    `Section` when it was omitted. Related:
    
    https://lists.debian.org/debian-devel/2024/12/msg00328.html
    
    Note that previously, this case would have the binary not have a
    `Section`, which rejected a bit further up.
    
  • befbf1a2
    by Joerg Jaspert at 2024-12-15T13:42:54+00:00
    Merge branch 'section-unknown' into 'master'
    
    daklib/checks.py: Reject binary packages using `unknown` as section
    
    See merge request ftp-team/dak!284

1 changed file:

Changes:

  • daklib/checks.py
    ... ... @@ -413,6 +413,10 @@ class BinaryCheck(Check):
    413 413
             if source is not None and not re_field_source.match(source):
    
    414 414
                 raise Reject('{0}: Invalid Source field'.format(fn))
    
    415 415
     
    
    416
    +        section = control.get('Section', '')
    
    417
    +        if section == '' or section == 'unknown' or section.endswith("/unknown"):
    
    418
    +            raise Reject('{0}: The "Section" field must be present and use a real section name.'.format(fn))
    
    419
    +
    
    416 420
             # check filename
    
    417 421
     
    
    418 422
             match = re_file_binary.match(fn)
    


  • Reply to: