Array error appears in search box while placing hold after advanced search

Bug #1732591 reported by Kathy Lussier on 2017-11-16
16
This bug affects 3 people
Affects Status Importance Assigned to Milestone
Evergreen
Medium
Unassigned
2.12
Medium
Unassigned
3.0
Medium
Unassigned

Bug Description

Evergreen version: 2.12 and 3.0

In bug 1671635, we added some hidden fields for qtype, query, and locg to the place hold page so that a user could edit their search from the searchbar on the holds confirmation page. While this works well when the user starts off in a basic search, those parameters aren't applied correctly if the search began on the advanced search page.

After clicking 'place hold', we end up with a URL that looks like this:

https://mlnc1.noblenet.org/eg/opac/place_hold?bool=and;bool=and;bool=and;qtype=keyword;qtype=title;qtype=author;contains=contains;contains=contains;contains=contains;query=concerto;query=;query=;_adv=1;detail_record_view=0;locg=1;pubdate=is;hold_source_page=%2Feg%2Fopac%2Fresults%3Fbool%3Dand%3Bbool%3Dand%3Bbool%3Dand%3Bqtype%3Dkeyword%3Bqtype%3Dtitle%3Bqtype%3Dauthor%3Bcontains%3Dcontains%3Bcontains%3Dcontains%3Bcontains%3Dcontains%3Bquery%3Dconcerto%3Bquery%3D%3Bquery%3D%3B_adv%3D1%3Bdetail_record_view%3D0%3Blocg%3D1%3Bpubdate%3Dis;hold_type=T;hold_target=2

The user will see an ugly array error in the search bar.

Changed in evergreen:
status: New → Confirmed
Jeanette Lundgren (jlundgren) wrote :

I can confirm this @ C/W MARS on Evergreen 2.12.8 and 3.0.2 for hold placed on titles retrieved via advanced search query.

I am attaching a snip of error.

Dan Pearl (dpearl) wrote :

I have put up a repair for this.
http://git.evergreen-ils.org/?p=working/Evergreen.git;a=shortlog;h=refs/heads/user/dpearl/LP1732591_ARRAY_error_in_hold

To test:
Advanced Search: search for anything
In search results, click on Place Hold in one of the items.
In Place Hold screen, note that searchbar query is in the one-liner form.
Place the hold, and note that the searchbar query is in the one-liner form.

For completeness:
Do the same with a Basic Search, and the Searchbar will contain the correct results.

tags: added: pullrequest
Cesar V (cesardv) wrote :

The above branch works for me, thanks Dan.
I saw the error in the Hold placement confirmation screen, and this patch fixes it.

Here's a signed-off branch below:

http://git.evergreen-ils.org/?p=working/Evergreen.git;a=shortlog;h=refs/heads/user/cesardv/user/dpearl_LP1732591_ARRAY_error_in_hold

tags: added: opac signedoff
Dan Wells (dbw2) on 2018-03-22
Changed in evergreen:
milestone: none → 3.1-rc
assignee: nobody → Dan Wells (dbw2)
Dan Wells (dbw2) wrote :

Tested this out, and ran into a few issues.

First, it looks like this patch does fix the results list link. However, it seems we need to do the same (or similar) for the Place Hold link in the record detail view after doing an advanced search.

Second, I didn't try, but we should be able to use the pre-computed 'is_advanced' bool rather than pulling in the CGI object and doing the test again ourselves.

Changed in evergreen:
assignee: Dan Wells (dbw2) → nobody
milestone: 3.1-rc → none
tags: added: needsrepatch
removed: pullrequest
tags: removed: signedoff
Changed in evergreen:
milestone: none → 3.1-rc
Dan Wells (dbw2) wrote :

Leaving this targeted for now, as I don't want to lose track of it. Also, thank you to those working on the fix.

Dan Pearl (dpearl) on 2018-03-23
Changed in evergreen:
assignee: nobody → Dan Pearl (dpearl)
Dan Pearl (dpearl) wrote :

Addressed Dan Wells' issues in
user/dpearl/LP1732591_ARRAY_error_in_hold

Thanks, Dan!

Changed in evergreen:
assignee: Dan Pearl (dpearl) → nobody
tags: added: pullrequest
removed: needsrepatch
Dan Pearl (dpearl) wrote :

Pullrequest removed. Needs a wee bit more work.

tags: removed: pullrequest
Dan Pearl (dpearl) wrote :

user/dpearl/LP1732591_ARRAY_error_in_hold_respin note new branch.

tags: added: pullrequest
Jason Stephenson (jstephenson) wrote :

I'm going to test this with 3.0.5. We may need to move the 3.1 target back, but so be it.

Changed in evergreen:
milestone: 3.1-rc → 3.1.1
Jason Stephenson (jstephenson) wrote :

I tested this and in the most basic case, I'm still seeing ARRAY(...) in the search box when placing a hold after advanced search. I'm removing the pullrequest tag and assigning it back to Dan Pearl.

tags: removed: pullrequest
Changed in evergreen:
assignee: nobody → Dan Pearl (dpearl)

This is very curious, as basic cases are working for me. Can you please
submit a series of steps to repro the error?

On Fri, Mar 30, 2018 at 9:44 AM, Jason Stephenson <
<email address hidden>> wrote:

> I tested this and in the most basic case, I'm still seeing ARRAY(...) in
> the search box when placing a hold after advanced search. I'm removing
> the pullrequest tag and assigning it back to Dan Pearl.
>
> ** Changed in: evergreen/3.0
> Assignee: Jason Stephenson (jstephenson) => (unassigned)
>
> ** Tags removed: pullrequest
>
> ** Changed in: evergreen
> Assignee: (unassigned) => Dan Pearl (dpearl)
>
> --
> You received this bug notification because you are subscribed to
> Evergreen.
> Matching subscriptions: LP_Mail
> https://bugs.launchpad.net/bugs/1732591
>
> Title:
> Array error appears in search box while placing hold after advanced
> search
>
> Status in Evergreen:
> Confirmed
> Status in Evergreen 2.12 series:
> Won't Fix
> Status in Evergreen 3.0 series:
> Confirmed
>
> Bug description:
> Evergreen version: 2.12 and 3.0
>
> In bug 1671635, we added some hidden fields for qtype, query, and locg
> to the place hold page so that a user could edit their search from the
> searchbar on the holds confirmation page. While this works well when
> the user starts off in a basic search, those parameters aren't applied
> correctly if the search began on the advanced search page.
>
> After clicking 'place hold', we end up with a URL that looks like
> this:
>
> https://mlnc1.noblenet.org/eg/opac/place_hold?bool=and;bool=
> and;bool=and;qtype=keyword;qtype=title;qtype=author;
> contains=contains;contains=contains;contains=contains;
> query=concerto;query=;query=;_adv=1;detail_record_view=0;
> locg=1;pubdate=is;hold_source_page=%2Feg%2Fopac%2Fresults%
> 3Fbool%3Dand%3Bbool%3Dand%3Bbool%3Dand%3Bqtype%3Dkeyword%3Bqtype%3Dtitle%
> 3Bqtype%3Dauthor%3Bcontains%3Dcontains%3Bcontains%3Dcontains%3Bcontains%
> 3Dcontains%3Bquery%3Dconcerto%3Bquery%3D%3Bquery%3D%3B_adv%
> 3D1%3Bdetail_record_view%3D0%3Blocg%3D1%3Bpubdate%3Dis;
> hold_type=T;hold_target=2
>
> The user will see an ugly array error in the search bar.
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/evergreen/+bug/1732591/+subscriptions
>

Jason Stephenson (jstephenson) wrote :

Dan,

I will test it again next week with a fresh branch on a clean virtual
machine.

Jason

Dan Pearl (dpearl) wrote :

Deal

On Thu, Apr 5, 2018 at 3:47 PM, Jason Stephenson <<email address hidden>
> wrote:

> Dan,
>
> I will test it again next week with a fresh branch on a clean virtual
> machine.
>
> Jason
>
> --
> You received this bug notification because you are a bug assignee.
> Matching subscriptions: LP_Mail
> https://bugs.launchpad.net/bugs/1732591
>
> Title:
> Array error appears in search box while placing hold after advanced
> search
>
> Status in Evergreen:
> Confirmed
> Status in Evergreen 2.12 series:
> Won't Fix
> Status in Evergreen 3.0 series:
> Confirmed
>
> Bug description:
> Evergreen version: 2.12 and 3.0
>
> In bug 1671635, we added some hidden fields for qtype, query, and locg
> to the place hold page so that a user could edit their search from the
> searchbar on the holds confirmation page. While this works well when
> the user starts off in a basic search, those parameters aren't applied
> correctly if the search began on the advanced search page.
>
> After clicking 'place hold', we end up with a URL that looks like
> this:
>
> https://mlnc1.noblenet.org/eg/opac/place_hold?bool=and;bool=
> and;bool=and;qtype=keyword;qtype=title;qtype=author;
> contains=contains;contains=contains;contains=contains;
> query=concerto;query=;query=;_adv=1;detail_record_view=0;
> locg=1;pubdate=is;hold_source_page=%2Feg%2Fopac%2Fresults%
> 3Fbool%3Dand%3Bbool%3Dand%3Bbool%3Dand%3Bqtype%3Dkeyword%3Bqtype%3Dtitle%
> 3Bqtype%3Dauthor%3Bcontains%3Dcontains%3Bcontains%3Dcontains%3Bcontains%
> 3Dcontains%3Bquery%3Dconcerto%3Bquery%3D%3Bquery%3D%3B_adv%
> 3D1%3Bdetail_record_view%3D0%3Blocg%3D1%3Bpubdate%3Dis;
> hold_type=T;hold_target=2
>
> The user will see an ugly array error in the search bar.
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/evergreen/+bug/1732591/+subscriptions
>

Changed in evergreen:
assignee: Dan Pearl (dpearl) → nobody
Jason Stephenson (jstephenson) wrote :

I am not able to reproduce what I mentioned in comment #10 today. I must have not loaded the branch properly or something.

I'm pushed a sign off, and added the pullrequest tag, but I think more eyes would still be useful.

working/user/dyrcona/LP1732591_ARRAY_error_in_hold_signoff

http://git.evergreen-ils.org/?p=working/Evergreen.git;a=shortlog;h=refs/heads/user/dyrcona/LP1732591_ARRAY_error_in_hold_signoff

Thanks, Dan!

tags: added: pullrequest signedoff
Dan Wells (dbw2) on 2018-04-18
Changed in evergreen:
assignee: nobody → Dan Wells (dbw2)
Dan Wells (dbw2) wrote :

I think this looks good, but I am going to hold off on pushing it in until right after today's release, just to give a little more time for any possible loose bits to shake out. Thanks!

Changed in evergreen:
milestone: 3.1.1 → 3.1.2
Dan Wells (dbw2) wrote :

As promised, pushed to master through rel_3_0. Thanks, Dan and Jason!

Changed in evergreen:
assignee: Dan Wells (dbw2) → nobody
status: Confirmed → Fix Committed
Changed in evergreen:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Bug attachments