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

Make gen_auto_py build withoug needing artscore #481

Merged
merged 3 commits into from
Aug 8, 2022

Conversation

riclarsson
Copy link
Contributor

This moves some stuff around to solve the problem of dependencies above.
It has one key drawback: The default value of workspace variables cannot
be printed anymore. It can still be accessed on an empty variable but
it cannot be printed. I am not sure if this can be fixed or if there is
a way to be self-referential in pyarts documentation somehow (e.g., access
the variable some way while building the string that becomes the
documentation)

@olemke This should help your conda tree. I had to reduce on the documentation somewhat. I think this is fine in pyarts as we can just to ws.wsv.value to see the default though

This moves some stuff around to solve the problem of dependencies above.
It has one key drawback: The default value of workspace variables cannot
be printed anymore.  It can still be accessed on an empty variable but
it cannot be printed.  I am not sure if this can be fixed or if there is
a way to be self-referential in pyarts documentation somehow (e.g., access
the variable some way while building the string that becomes the
documentation)
Despite being documenting that this is added by py::return_value_policy::reference_internal,
it appears this is not the case.  Using just py::keep_alive<0, 1>() makes exiting python
cause a memory corruption segfault, so it seems both are required to keep 1) the workspace
alive as long as required, and 2) not cause memory corruption issues upon deleting an
instance of the Workspace
@riclarsson riclarsson merged commit 7eb750a into atmtools:master Aug 8, 2022
@riclarsson riclarsson deleted the lower_gen_auto_py_level branch August 8, 2022 16:10
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.

1 participant