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

Fallback to gringo binary when clingo pypi package is unavailable #124

Merged
merged 1 commit into from
Feb 7, 2022

Conversation

anubhav-cs
Copy link
Contributor

No description provided.

@miquelramirez miquelramirez merged commit d6ddf3e into aig-upf:devel Feb 7, 2022
"""
command = None
if find_spec("clingo"):
command = [sys.executable, os.path.join(Path(__file__).parent.absolute(), "gringo.py")]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are we spawning a new process here on purpose? Do we need that, or could we simply import our clingo wrapper and invoke clingo_main?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tried it but I couldn't redirect stdout and stderr properly. Technically, we just need to use redirect_stdout but it wouldn't work.

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

Successfully merging this pull request may close these issues.

3 participants