NBISweden / LocalEGA

Please go to to https://github.com/EGA-archive/LocalEGA instead
Apache License 2.0
4 stars 1 forks source link

filepath, filename gets correctly set in send_message #370

Closed viklund closed 6 years ago

viklund commented 6 years ago

filepath, filename gets correctly set in send_message

Also updated the names of the parameters so that they don't get overwritten by the function body - this reduces the amount of state one has to keep track of when reading and/or updating the function.

Describe the pull request:

Changes made:

  1. notifications.py - fixed bug according to above

Steps to reproduce the original issue

  1. Checkout 1f9d197 and make sure that all docker images are built against that revision
  2. Set log = console in private/lega/conf.ini
  3. run docker-compose up
  4. run make upload in a different terminal inside the docker/test directory

The (relevant) log output from docker-compose will be:

inbox          | [lega.notifications][ INFO ] (L41) Using chroot isolation
inbox          | [lega.notifications][ INFO ] (L73) User ega-box-999 uploaded /file.txt.c4ga
inbox          | [lega.utils.checksum][ERROR ] (L43) Unable to calculate checksum: IsADirectoryError(21, 'Is a directory')
inbox          | Received disconnect from 192.168.240.1 port 54852:11: disconnected by user
inbox          | Disconnected from user ega-box-999 192.168.240.1 port 54852