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

Accessing the report crashes when the samples values are changed #1966

Closed
diegoliberman opened this issue Jul 7, 2023 · 5 comments · Fixed by #1981
Closed

Accessing the report crashes when the samples values are changed #1966

diegoliberman opened this issue Jul 7, 2023 · 5 comments · Fixed by #1981
Assignees
Labels
Milestone

Comments

@diegoliberman
Copy link
Contributor

Steps to reproduce the error

  1. Create a box, transfer it to another institution, confirm the transfer, upload the results, create a report.
  2. You'll see that you can access the report normally.
  3. Open any sample from the box. Edit any value, for example the Technician name.
  4. Go back to the report and try to open it.
  5. It will crash.

image

@ysbaddaden ysbaddaden self-assigned this Jul 20, 2023
@ysbaddaden
Copy link
Contributor

ysbaddaden commented Jul 21, 2023

I can't reproduce. It may have been fixed by #1974 and/or #1975

@ysbaddaden ysbaddaden added this to the v0.23.0 milestone Jul 24, 2023
@ysbaddaden ysbaddaden removed their assignment Jul 24, 2023
@leandroradusky leandroradusky self-assigned this Jul 25, 2023
@leandroradusky
Copy link
Contributor

This error happens because the measured signal is converted to a string when the sample is edited.

In the last merge with the bugfixes made by @ysbaddaden this:

      - if @sample_form.measured_signal
        = f.form_field :measured_signal do
          = f.text_field :measured_signal, readonly: true

changed to

      - if @sample_form.measured_signal
        = f.form_field :measured_signal do
          .value= @sample_form.measured_signal

This will correct the error automatically?

@ysbaddaden
Copy link
Contributor

Yes, it won't be sent anymore, so it won't be saved anymore.

@ysbaddaden
Copy link
Contributor

QA: we didn't fix the existing invalid samples in staging. You must reproduce the edit steps with new samples.

@sardar-usman
Copy link

@leandroradusky It is working fine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants