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

Investigate why the Model Editor is not applying the test on Apply #1633

Open
smk78 opened this issue Jul 20, 2020 · 4 comments
Open

Investigate why the Model Editor is not applying the test on Apply #1633

smk78 opened this issue Jul 20, 2020 · 4 comments
Assignees
Milestone

Comments

@smk78
Copy link
Contributor

smk78 commented Jul 20, 2020

Created at request of @rozyczko :
The Model Editor window does not seem to have the test run implemented on Apply. Was this just missed, or was there a reason?

@smk78 smk78 added the Critical High priority label Jul 20, 2020
@smk78 smk78 added this to the SasView 5.0.3 milestone Jul 20, 2020
@butlerpd butlerpd modified the milestones: SasView 5.0.3, SasView 5.0.4 Aug 18, 2020
@butlerpd butlerpd changed the title ESS_GUI: Investigate why the Model Editor is not applying the test on Apply Investigate why the Model Editor is not applying the test on Apply May 2, 2021
@butlerpd butlerpd modified the milestones: SasView 5.0.4, SasView 5.0.5 May 2, 2021
@butlerpd
Copy link
Member

butlerpd commented Feb 1, 2022

@smk78 and/or @rozyczko, is this referring to the create model editor? or the full model editor? My impression is the the error checking is pretty robust now on the "add custom model" editor. I note that the "edit custom model" editor does not have an apply button, just a save button. However it still seems to catch simple syntax errors. There is another issue #1595 which describes what happens with those that still don't get caught.
Question: can we close this or is there something more specific to look for?

@butlerpd butlerpd modified the milestones: SasView 5.0.5, SasView 5.1.0 Feb 1, 2022
@smk78
Copy link
Contributor Author

smk78 commented Feb 1, 2022

Add Custom Model.

So if you create one:
image
And click Apply all is good as you'd expect.
image

Now deliberately introduce an error (so here I'll change the function to have a parameter b but not update the parameter list):
image
This time when you click apply (and note I've had to check the overwrite box at the top) the syntax checker spots the error.
image

But if I switch to the Model Editor tab and make the same code change:
image
And then click Apply the syntax checking is not applied and the faulty model is saved:
image

@butlerpd
Copy link
Member

butlerpd commented Feb 1, 2022

Interesting .. I had not noticed the different buttons when the edit custom model editor is automatically loaded after a first save vs when it is called directly from the menu bar. It clearly is the same editor code (if not it should be).

That behavior is similar to what I found when the custom model editor is called directly. A deliberate mistake in the parameter table for example (in my case removal of a comma) caused the problem described here (no error flagged and file saved but ..), but changing the math function to have an unclosed parenthesis [ x(x+y(r)] for example DID cause the red box "error" to pop up. As I say, the add custom model panel seems to be much more robust at finding errors, but I suspect making the general python editor that robust may be more problematic? It would be nice to have some ideas of what is possible or not to help the users here I think.

@lucas-wilkins
Copy link
Contributor

@rozyczko Was this investigated? Was it fixed? Do we need an issue that actions a fix? Can we close?

@lucas-wilkins lucas-wilkins added the Stale Mark for potential close: issue no longer seems relevant / probably complete / probably not doable. label Oct 30, 2022
@butlerpd butlerpd removed the Stale Mark for potential close: issue no longer seems relevant / probably complete / probably not doable. label Oct 31, 2022
@tsole0 tsole0 mentioned this issue Jun 21, 2024
7 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants