-
Notifications
You must be signed in to change notification settings - Fork 12
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
Anistropy messages block execution from script #207
Comments
Seems to be a known issue. For now we can 1.Get rid of messages that are not absolutely necessary 2. Add instructions for how to hack the macros. Option 2 for Anisotropy would look like
If you want to go with option 2, we'll need to mark all message parameters with |
option 3: can we just put the message in the dialog box, so that only interactive GUI users see it? |
This is how you add messages to a dialog box. By having
Like I mentioned above, there just so happens to be bug that makes them pop up when a macros run. |
Option 2. seems to work OK at the moment. There is one other dialog that pops up: Could we make it so that if code is being called from a script, warnings and messages get output to the console or log window only and not to a GUI OK button window? This particular one doesn't block execution, but you do get a big pile of them accumulating on the screen. It's possible to work around this for now by not asking for |
Allows running macros with "myMessageParameter=\"\"", which prevents them from opening a dialog (an open issue in scijava-common). Without `persist=false` a macro like this would change the message permanently.
@alessandrofelder Have you encountered these issues when running Python scripts? |
Yea, I think so. I can't remember exactly, but I will try to replicate tomorrow and report here. It was ITA-related, I think. |
* Enable mocking final classes * Add a utility method Adds a utility method that allows cancelling plugins without showing message dialogs, when a macro is running. * Cancels plugins in a macro safe way Cancels plugins so that they won't show a message dialog if a macro is being run. * Workaround for issue #207 Allows running macros with "myMessageParameter=\"\"", which prevents them from opening a dialog (an open issue in scijava-common). Without `persist=false` a macro like this would change the message permanently. * Mark test resources for gc Co-authored-by: Michael Doube <[email protected]>
Fixed by #210 , closing. |
Describe the bug
When running from macro, Anisotropy shows messages in the GUI which interrupts execution until the user clicks OK.
To Reproduce
Run the macro
Expected behavior
The script completes without user interaction. Errors and other messages could be logged to the console of Log window.
Screenshots

Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered: