#2610 cli: raise NotImplementedError with btype name
Merged a year ago by tkopecek. Opened a year ago by ktdreyer.
ktdreyer/koji raise-download-build  into  master

file modified
+1 -2
@@ -655,8 +655,7 @@ 

          path = archive['filename']

      else:

          # TODO: cover module/operator-manifests/remote-sources

-         # can't happen

-         assert False  # pragma: no cover

+         raise NotImplementedError(archive['btype'])

  

      download_file(url, path, quiet=quiet, noprogress=noprogress, filesize=archive['size'])

  

Print the exact unhandled btype name to the user, so it's clearer why we're exiting early here.

Use raise instead of assert? This one will do nothing - assert will evaluate is as true/pass.

rebased onto 2028c2e

a year ago

rebased onto 2028c2e

a year ago

Oh, that was my bad. I've amended this to raise instead of assert. Thanks for catching that.

Metadata Update from @tkopecek:
- Pull-request tagged with: testing-ready

a year ago

Metadata Update from @mfilip:
- Pull-request tagged with: testing-done

a year ago

Commit 8e94e8c fixes this pull-request

Pull-Request has been merged by tkopecek

a year ago