-
Notifications
You must be signed in to change notification settings - Fork 73
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
Fix "Reload Libraries macro issues" #95
Conversation
Thank you for your pull request and welcome to our community. We require contributors to sign our Contributor License Agreement (CLA), and it seems that the following contributors have not yet signed it: @PietroCampana. In order for us to review and merge your code, please sign the CLA at meetiqm.com. Once you have signed the CLA, write a comment here and we'll verify. Please note that it may take some time for us to verify it. |
I have now signed the CLA. |
Thank you for your pull request and welcome to our community. We require contributors to sign our Contributor License Agreement (CLA), and it seems that the following contributors have not yet signed it: @PietroCampana. In order for us to review and merge your code, please sign the CLA at meetiqm.com. Once you have signed the CLA, write a comment here and we'll verify. Please note that it may take some time for us to verify it. |
I have added the |
Thanks for the pull request. Unfortunately there is a hidden bug in this approach, that can be replicated easily:
I believe what is happening is that after While it's probably good that |
@cla-bot check |
The cla-bot has been summoned, and re-checked this pull request! |
Another thing I recommend to test is to induce a syntax error to test that the
the Another quirk is that the newline after |
I have written a partial solution addressing both points. To solve the problem of duplicated instances, they are now collected at the same time of the view data in the Making the PCell modifiable again after fixing the libraries in case of any error seems to be fairly more complex, but I found a possible simple solution by moving the call to Regarding the last point, I couldn't manage to reproduce the quirk due to the newline after |
Thank you for your follow-up. Right now this seems to work fantastic! If I place an element, induce some code errors, reload libraries, it gives me errors and then lets me modify parameters for the element based on the previous version of the code. I only tested on Windows so far, does it perform differently on Ubuntu/Arch? Because as it works now on Windows I don't think we need to concern ourselves with temporary files at all. The odd thing with newline after wrong indentation seems to be Windows specific. I'd say we leave this out as out-of-scope for this issue. I'll test this on other platforms after the weekend, but I'd say in this current version this could be merged already. But I would recommend to try out the two points I brought up earlier:
|
Thank you for the nice comments. I have written a more informative error message and made some minor modifications. I found out that it was necessary to delete the cells before reloading the libraries, otherwise they would lose the references to their children's instances, which didn't get deleted and appeared out of the top cell afterwards. The current behavior on Linux is:
Current limitations:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is now in a state where I can happily merge this to our main branch! Thank you for your collaboration!
This pull request addresses issue #89.
To start, I implemented a basic solution by making
extract_pcell_data_from_views
work only with instances ofElement
and by restoring the view in case of an exception when reloading the libraries.