Skip to content

Commit 9a5a639

Browse files
committed
Address PR feedback - thanks @rasmunk .
1 parent 8df332d commit 9a5a639

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

mig/shared/griddaemons/login.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -694,19 +694,20 @@ def refresh_job_creds(configuration, protocol, username):
694694

695695

696696
def refresh_share_creds(configuration, protocol, username,
697-
share_modes=[READ_WRITE_ACCESS]):
697+
share_modes=(READ_WRITE_ACCESS, )):
698698
"""Reload sharelink credentials for username (SHARE_ID) if they changed on
699699
disk. That is, add user entries in configuration.daemon_conf['shares'] for
700700
any corresponding active sharelinks.
701701
Removes all sharelink login entries if the sharelink is no longer active,
702702
too. The protocol argument specifies which auth files to use.
703703
Returns a tuple with the updated daemon_conf and the list of changed share
704704
IDs.
705-
NOTE: we limit share_modes to read-write sharelinks for now since we don't
706-
have guards in place to support read-only or write-only mode in daemons.
705+
NOTE: by default we limit share_modes to read-write sharelinks for now
706+
since we don't have guards in place to support read-only or write-only mode
707+
in all daemons, yet.
707708
NOTE: we further limit to directory sharelinks for chroot'ing.
708709
"""
709-
_valid_modes = [READ_WRITE_ACCESS, READ_ONLY_ACCESS, WRITE_ONLY_ACCESS]
710+
_valid_modes = (READ_WRITE_ACCESS, READ_ONLY_ACCESS, WRITE_ONLY_ACCESS)
710711
# Must end in sep
711712
base_dir = configuration.user_home.rstrip(os.sep) + os.sep
712713
changed_shares = []

0 commit comments

Comments
 (0)