Bug 28769 - tabloop not used in cataloguing plugins
Summary: tabloop not used in cataloguing plugins
Status: RESOLVED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Architecture, internals, and plumbing (show other bugs)
Version: master
Hardware: All All
: P5 - low enhancement (vote)
Assignee: Jonathan Druart
QA Contact: Marcel de Rooy
URL:
Keywords:
Depends on: 27526
Blocks: 28445
  Show dependency treegraph
 
Reported: 2021-07-27 14:33 UTC by Jonathan Druart
Modified: 2021-11-05 00:31 UTC (History)
4 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Small patch
Text to go in the release notes:
This technical change removes the "tabloop" variable that is passed from the add item form logic to the cataloguing plugins, as it is never used.
Version(s) released in:
21.11.00


Attachments
Bug 28769: Remove tabloop from cataloguing plugins (42.77 KB, patch)
2021-07-27 14:35 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 28769: Remove tabloop from cataloguing plugins (42.74 KB, patch)
2021-10-05 17:03 UTC, Tomás Cohen Arazi
Details | Diff | Splinter Review
Bug 28769: Remove tabloop from cataloguing plugins (41.05 KB, patch)
2021-10-12 10:18 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 28769: Remove tabloop from cataloguing plugins (41.03 KB, patch)
2021-10-15 06:55 UTC, Marcel de Rooy
Details | Diff | Splinter Review
Bug 28769: (QA follow-up) Fix another occurrence (1.09 KB, patch)
2021-10-15 06:55 UTC, Marcel de Rooy
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Jonathan Druart 2021-07-27 14:33:11 UTC
There is a "tabloop" variable that is passed from the add item form logic to the cataloguing plugins.
But there is confusion, sometimes it's an iterator ($i) and sometimes (batchMod.pl) an array.

Actually this tabloop variable is never used from cataloguing plugins, we should remove it.
Comment 1 Jonathan Druart 2021-07-27 14:35:57 UTC
Created attachment 123212 [details] [review]
Bug 28769: Remove tabloop from cataloguing plugins

There is a "tabloop" variable that is passed from the add item form logic to the cataloguing plugins.
But there is confusion, sometimes it's an iterator ($i) and sometimes (batchMod.pl) an array.

Actually this tabloop variable is never used from cataloguing plugins, we should remove it.

Test plan:
Read the code and confirm the above.
You can also test a couple of plugins and confirm that they are still
working.
Comment 2 Tomás Cohen Arazi 2021-10-05 17:01:59 UTC
This is a trivial change, *but* it needs to be advertised because it might break custom cataloguing plugins.
Comment 3 Tomás Cohen Arazi 2021-10-05 17:03:14 UTC
Created attachment 125748 [details] [review]
Bug 28769: Remove tabloop from cataloguing plugins

There is a "tabloop" variable that is passed from the add item form logic to the cataloguing plugins.
But there is confusion, sometimes it's an iterator ($i) and sometimes (batchMod.pl) an array.

Actually this tabloop variable is never used from cataloguing plugins, we should remove it.

Test plan:
Read the code and confirm the above.
You can also test a couple of plugins and confirm that they are still
working.

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Comment 4 Jonathan Druart 2021-10-12 10:18:18 UTC
Created attachment 126085 [details] [review]
Bug 28769: Remove tabloop from cataloguing plugins

There is a "tabloop" variable that is passed from the add item form logic to the cataloguing plugins.
But there is confusion, sometimes it's an iterator ($i) and sometimes (batchMod.pl) an array.

Actually this tabloop variable is never used from cataloguing plugins, we should remove it.

Test plan:
Read the code and confirm the above.
You can also test a couple of plugins and confirm that they are still
working.

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Comment 5 Marcel de Rooy 2021-10-12 15:10:27 UTC
(In reply to Tomás Cohen Arazi from comment #2)
> This is a trivial change, *but* it needs to be advertised because it might
> break custom cataloguing plugins.

Hmm. So trivial for skipping QA ?
Comment 6 Jonathan Druart 2021-10-12 17:00:33 UTC
Do you think it needs an additional pair of eyes on this patch, Marcel?
Comment 7 Marcel de Rooy 2021-10-13 11:09:09 UTC
(In reply to Jonathan Druart from comment #6)
> Do you think it needs an additional pair of eyes on this patch, Marcel?

Well, at least might need. I will do it this week.
Note that comment2 is no recommendation for using the fast lane :)
Comment 8 Marcel de Rooy 2021-10-15 06:25:38 UTC
QAing
Comment 9 Marcel de Rooy 2021-10-15 06:54:34 UTC
I wonder who wrote this in 2014: Note that some of these parameters are not used in most (if not all) plugins and may be obsoleted in the future (kept for now to provide backward compatibility).

Somehow I mixed up tabloop and tagslib. Tabloop is probably the most useless one to pass. But tagslib might be a good candidate too now, especially since we cache these structures now.
Comment 10 Marcel de Rooy 2021-10-15 06:55:24 UTC
Created attachment 126304 [details] [review]
Bug 28769: Remove tabloop from cataloguing plugins

There is a "tabloop" variable that is passed from the add item form logic to the cataloguing plugins.
But there is confusion, sometimes it's an iterator ($i) and sometimes (batchMod.pl) an array.

Actually this tabloop variable is never used from cataloguing plugins, we should remove it.

Test plan:
Read the code and confirm the above.
You can also test a couple of plugins and confirm that they are still
working.

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Comment 11 Marcel de Rooy 2021-10-15 06:55:28 UTC
Created attachment 126305 [details] [review]
Bug 28769: (QA follow-up) Fix another occurrence

Framework plugin unimarc_leader_authorities.pl.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Comment 12 Jonathan Druart 2021-10-18 09:34:05 UTC
Pushed to master for 21.11, thanks to everybody involved!