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

Freeze on unusual input in nuclide selection dialog #19

Open
manevich opened this issue Dec 3, 2022 · 3 comments
Open

Freeze on unusual input in nuclide selection dialog #19

manevich opened this issue Dec 3, 2022 · 3 comments

Comments

@manevich
Copy link

manevich commented Dec 3, 2022

InterSpec freezes on unusual input in nuclide selection dialog.

Steps to repeat:

  1. Enter menu "Tools > Nuclide Decay Info"
  2. Press "Add Nuclide"
  3. Type "Co6+"

Not limited to "Co6+" string. Any part of valid nuclide name with at least one digit and "+" or "*" char afterwards makes InterSpec freeze.

I'm using InterSpec v1.0.10 buid date 20220808 on Debian Linux.

@wcjohns
Copy link
Collaborator

wcjohns commented Dec 4, 2022

Thank you very much for reporting this!

I wont have access to my Linux computer for about a week, and I cant reproduce on Windows/macOS, so it will be a little bit until it is fixed.

There is a regular expression used for highlighting the suggested nuclides list, based on your input, so perhaps special regex character are somehow confusing things and causing this issue. There are a number of workarounds in the IsotopeNameFilterModel::nuclideNameMatcherJs() function, which defines this javascript regex, so I will look there first.

@LaurentCronimus
Copy link

Hi,
I have the same problem with InterSpec v1.0.11 buid date 20221017 on W10 64.

@wcjohns
Copy link
Collaborator

wcjohns commented Jan 13, 2023

Thank you for the additional input @LaurentCronimus.
I took a look at this, and had a really hard time consistently reproducing it; the error didn't seem to often happen.
So I think I'll just re-write the relevant code to do the validation in C++ instead of javascript.

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

3 participants