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

Allow question scripts to import files in the same directory #14

Open
pauek opened this issue Jan 15, 2025 · 0 comments
Open

Allow question scripts to import files in the same directory #14

pauek opened this issue Jan 15, 2025 · 0 comments

Comments

@pauek
Copy link
Member

pauek commented Jan 15, 2025

When writing questions about the same subject, it is useful to be able to import a file with common functions, which can be reused for different questions. Right now this does not work by default but can be made to work with:

import sys
sys.path.append('.')

import local_package
...

It would be useful to append the path inside the jutge-make-quiz so that it is not necessary to add the current path of the question file and it works by default.

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

1 participant