Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Filename / path with space in LocalScheduler not working #18

Closed
dosomder opened this issue Dec 20, 2018 · 2 comments
Closed

Filename / path with space in LocalScheduler not working #18

dosomder opened this issue Dec 20, 2018 · 2 comments

Comments

@dosomder
Copy link

The scheduler splits the command with spaces: https://github.com/LarsHH/sherpa/blob/master/sherpa/schedulers.py#L110

This means any file name / file path with space will not work. This should either be changed or mentioned in the docs.

@dosomder dosomder changed the title Filename / path with space Filename / path with space in LocalScheduler not working Dec 20, 2018
@LarsHH
Copy link
Collaborator

LarsHH commented Jan 11, 2019

Hi @dosomder !

Apologies for the slow reply and thanks for pointing this out.

It looks like this can be changed relatively easily. _Runner creates the command by joining python and filename. Then for LocalScheduler it gets split up again later. So there is some redundancy.

It seems to make sense to just pass a list with command components (i.e. ['python', filename]) to the scheduler. Then let the scheduler join it together or not, depending on what format is needed.

This slightly changes the interface of the Scheduler.submit_job() method, but since it is not really user facing I think that's okay.

Let me know if you have any more comments.

Best,
Lars

LarsHH pushed a commit that referenced this issue Jan 12, 2019
@LarsHH
Copy link
Collaborator

LarsHH commented Jan 12, 2019

Resolved: 99de04f

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants