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

Check system path #6

Closed
lindonroberts opened this issue Jul 19, 2019 · 1 comment
Closed

Check system path #6

lindonroberts opened this issue Jul 19, 2019 · 1 comment
Assignees

Comments

@lindonroberts
Copy link
Collaborator

In build_interface.import_problem(), check that cache is in the Python path. Easiest way would be to add an ImportError catch to lines 341-342:
return CUTEstProblem(__import__('%s.%s' % (CACHE_SUBFOLDER, problemDir), globals(), locals(), [str(problemDir)]), drop_fixed_variables=drop_fixed_variables)

If this throws an ImportError, just try to import CACHE_SUBFOLDER - an ImportError here indicates the Python path can't see it. This will hopefully avoid issues when using IDEs, etc.

@lindonroberts lindonroberts self-assigned this Jul 19, 2019
@jfowkes
Copy link
Owner

jfowkes commented Jul 19, 2019

This sounds like a sensible way of handling it to me.

@jfowkes jfowkes closed this as completed in 3fddfbd Sep 5, 2019
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