cover image uploader generic error even with success

Bug #1988321 reported by Jason Etheridge
34
This bug affects 6 people
Affects Status Importance Assigned to Milestone
Evergreen
Fix Released
Medium
Unassigned
3.10
Fix Released
Medium
Unassigned

Bug Description

So even when the backend successfully changed the jacket image for a bib, the UI was reporting a generic failure and not clearing the upload form. In the code, it looks like we got loose vs strict equality operators mixed up. Branch forthcoming.

Revision history for this message
Jason Etheridge (phasefx) wrote :
tags: added: pullrequest
Revision history for this message
Garry Collum (gcollum) wrote :
Changed in evergreen:
status: New → Confirmed
tags: added: signedoff
Revision history for this message
Jane Sandberg (sandbergja) wrote :

Thanks, Jason and Garry. Unfortunately, this branch doesn't pass ng lint, which is looking for that strict comparison. Could we have '1' cast to the expected type and use the strict comparison? If that's not practical, could we disable the linter for that line?

Changed in evergreen:
milestone: none → 3.9.1
Changed in evergreen:
milestone: 3.9.1 → 3.9.2
Galen Charlton (gmc)
tags: added: needswork
removed: signedoff
Revision history for this message
Chris Sharp (chrissharp123) wrote :

I have a branch that casts x.body to a string, which resolves the problem locally for PINES.

https://git.evergreen-ils.org/?p=working/Evergreen.git;a=shortlog;h=refs/heads/user/csharp/lp1988321_fix_broken_jacket_uploader

tags: removed: needswork
tags: added: cat-holdingseditor
Revision history for this message
Beth Willis (willis-a) wrote :

I tested both of these branches on our EG 3.9.1 test server. In both cases, I was able to upload cover images and did not get the erroneous failure message. Both look good to me.

Revision history for this message
Michele Morgan (mmorgan) wrote :

I ran ng lint (master circa 3.10) on both proposed fixes and both passed for me.

Changed in evergreen:
status: Confirmed → Fix Committed
importance: Undecided → Medium
Revision history for this message
Jane Sandberg (sandbergja) wrote :

Thank you, Jason, Garry, Chris, Beth, and Michele. I pushed Chris' version to rel_3_9 and above.

Michele, I agree with your findings -- when I cherry-pick Jason's commit, then `npm i && ng lint`, I get no linting errors. When I check out Jason's original branch and do the same steps, I get: "ERROR: 101:32 triple-equals != should be !==". A mystery for another day...

Changed in evergreen:
status: Fix Committed → Fix Released
Changed in evergreen:
status: Fix Released → Fix Committed
Changed in evergreen:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.