jeinarsson / josync

josync.readthedocs.org
MIT License
0 stars 0 forks source link

Capital drive letters with mapped network folders cause error #37

Closed rasmuse closed 10 years ago

rasmuse commented 10 years ago

I am syncing to a network location like \\domain.com\myfolder\sync. For convenience I have mapped my home folder on the network, \\domain.com\myfolder, to a drive letter H:. If i set up the sync job with "target" : "h:/sync", everything works as intended. However, if I change to a capital drive letter, "target" : "H:/sync", josync crashes with the following output:

__main__ [INFO] ************************************************************
__main__ [INFO] Session started. Josync version 0.0.
utils [INFO] net use reported 2 mapped drives
utils [WARNING] Config file user.josync-config not found (ignoring).
utils [INFO] Creating FailureNotifier from test.josync-job.
utils [INFO] No notification settings were found. Disabling notifications.
jobs [INFO] Creating Job from test.josync-job.
josync_run [ERROR] Josync job test.josync-job failed with an exception: u'H:'
__main__ [ERROR] u'H:'
Traceback (most recent call last):
  File "josync.py", line 55, in main
    job = jobs.create_job_from_file(jobfile)
  File "c:\temp\josync\jobs.py", line 189, in create_job_from_file
    return job_types[params['type']](params)
  File "c:\temp\josync\jobs.py", line 145, in __init__
    super(SyncJob, self).__init__(params)
  File "c:\temp\josync\jobs.py", line 117, in __init__
    super(BaseSyncJob, self).__init__(params)
  File "c:\temp\josync\jobs.py", line 35, in __init__
    unc = utils.net_drives[target_drive]
KeyError: u'H:'
__main__ [INFO] Session ended.

I am running josync 1.0 on Windows 7 x64.