Control: severity -1 important
Control: retitle -1 dput-ng: crash on PermissionError

On Sun, Mar 08, 2020 at 06:12:53PM +0530, Pirate Praveen wrote:
> $ dput ssh-upload ../node-clipboard_2.0.4+ds-2~bpo10+1_amd64.changes
…
>    raise IOError(errno.EACCES, text)
> PermissionError: [Errno 13] Permission denied

This means that your likely trying to overwrite a file for which you
have no write permissions.


> During handling of the above exception, another exception occurred:
> 
> Traceback (most recent call last):
>  File "/usr/bin/dput", line 129, in <module>
>    upload_package(changes, args)
>  File "/usr/lib/python3/dist-packages/dput/uploader.py", line 343, in
> invoke_dput
>    obj.upload_file(path)
>  File "/usr/lib/python3/dist-packages/dput/uploaders/sftp.py", line 285, in
> upload_file
>    if e.errno == os.errno.EACCES:
> AttributeError: module 'os' has no attribute 'errno'

This is the crash bit that will be fixed within dput-ng… it's just a
leftover from py2→py3, as errno is now its own library.

Imagine this warning coming out:

          logger.warning("""Upload permissions error

  You either don't have the rights to upload a file, or, if this is on
  ftp-master, you may have tried to overwrite a file already on the server.

  Continuing anyway in case you want to recover from an incomplete upload.
  No file was uploaded, however.""")

-- 
regards,
                        Mattia Rizzolo

GPG Key: 66AE 2B4A FCCF 3F52 DA18  4D18 4B04 3FCD B944 4540      .''`.
More about me:  https://mapreri.org                             : :'  :
Launchpad user: https://launchpad.net/~mapreri                  `. `'`
Debian QA page: https://qa.debian.org/developer.php?login=mattia  `-

Attachment: signature.asc
Description: PGP signature

Reply via email to