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

add an ability to find the import string for constants and typedefs #694

Closed
chrisdonlan opened this issue Nov 5, 2024 · 1 comment
Closed

Comments

@chrisdonlan
Copy link

Currently, if I set up a constant or typedef:

constant = 'foo'

Label = str

Then when I query for the import string with the constant or typedef's value, the getimport function will not work (of course):

dill.source.getimport(constant) 

This is a meaningless request, because dill.source.getimport(constant) will look at the value of constant to determine the import, which is a string, 'foo'.

In order to support the look-up of typedefs and constants' import paths, something different would need to be attempted, likely involving reflection.

@chrisdonlan
Copy link
Author

I was able to get around this with some logic. Might be worth looking into though. Closing.

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