[Bug 12412] New: Allow plugins to convert arbitrary files to MARC from record staging tool
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12412 Bug ID: 12412 Summary: Allow plugins to convert arbitrary files to MARC from record staging tool Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 - low Component: Cataloging Assignee: gmcharlt@gmail.com Reporter: kyle@bywatersolutions.com QA Contact: testopia@bugs.koha-community.org CC: m.de.rooy@rijksmuseum.nl Many libraries would like to be able to import various types of files as MARC records ( citations, csv files, etc ). We can add a new function to the plugins system to allow that kind of behavior at a very custom level. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12412 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Assignee|gmcharlt@gmail.com |kyle@bywatersolutions.com -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12412 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Change sponsored?|--- |Sponsored -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12412 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|Allow plugins to convert |Add ability for plugins to |arbitrary files to MARC |convert arbitrary files to |from record staging tool |MARC from record staging | |tool -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12412 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff Patch complexity|--- |Medium patch -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12412 --- Comment #1 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 28825 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=28825&action=edit Bug 12412 - Add ability for plugins to convert arbitrary files to MARC from record staging tool Many libraries would like to be able to import various types of files as MARC records ( citations, csv files, etc ). We can add a new function to the plugins system to allow that kind of behavior at a very custom level. Test Plan: 1) Ensure you have plugins enabled and configured correctly 2) Installed the attached version 2.00 of the Kitchen Sink plugin 3) Download the attached text file 4) Browse to "Stage MARC records for import" 5) Select the downloaded text file for staging 6) After uploading, you should see a new area "Transform file to MARC:", select "Example Kitchen-Sink Plugin" from the pulldown menu 7) Click 'Stage for import" 8) Click 'Manage staged records" 9) You should now see two new MARC records! -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12412 --- Comment #2 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 28826 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=28826&action=edit Test text file that will be transformed into MARC -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12412 --- Comment #3 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 28827 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=28827&action=edit Kitchen-Sink Plugin v2.00 -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12412 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #28825|0 |1 is obsolete| | --- Comment #4 from Kyle M Hall <kyle@bywatersolutions.com> --- Created attachment 31676 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=31676&action=edit Bug 12412 - Add ability for plugins to convert arbitrary files to MARC from record staging tool Many libraries would like to be able to import various types of files as MARC records ( citations, csv files, etc ). We can add a new function to the plugins system to allow that kind of behavior at a very custom level. Test Plan: 1) Ensure you have plugins enabled and configured correctly 2) Installed the attached version 2.00 of the Kitchen Sink plugin 3) Download the attached text file 4) Browse to "Stage MARC records for import" 5) Select the downloaded text file for staging 6) After uploading, you should see a new area "Transform file to MARC:", select "Example Kitchen-Sink Plugin" from the pulldown menu 7) Click 'Stage for import" 8) Click 'Manage staged records" 9) You should now see two new MARC records! -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12412 verolencinas <verolencinas@yahoo.com.ar> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Patch doesn't apply CC| |verolencinas@yahoo.com.ar --- Comment #5 from verolencinas <verolencinas@yahoo.com.ar> --- I have tried to test this, but in point 6) of the test plan 6) After uploading, you should see a new area "Transform file to MARC:", select "Example Kitchen-Sink Plugin" from the pulldown menu there is no new area "Transform file to MARC:". tested with Koha 3.16.03.000. (Test-Koha is bilingual english-spanish, and test was made with both, english and spanish, interfaces). -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12412 Kyle M Hall <kyle@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Patch doesn't apply |Needs Signoff --- Comment #6 from Kyle M Hall <kyle@bywatersolutions.com> --- (In reply to verolencinas from comment #5)
I have tried to test this, but in point 6) of the test plan
6) After uploading, you should see a new area "Transform file to MARC:", select "Example Kitchen-Sink Plugin" from the pulldown menu
there is no new area "Transform file to MARC:".
tested with Koha 3.16.03.000. (Test-Koha is bilingual english-spanish, and test was made with both, english and spanish, interfaces).
You should be testing this patch on master. Here is a demo video as well: http://screencast.com/t/Q4xtMiQpggN -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12412 Aleisha Amohia <aleishaamohia@hotmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12412 Aleisha Amohia <aleishaamohia@hotmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #31676|0 |1 is obsolete| | --- Comment #7 from Aleisha Amohia <aleishaamohia@hotmail.com> --- Created attachment 35483 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=35483&action=edit Bug 12412 - Add ability for plugins to convert arbitrary files to MARC from record staging tool Many libraries would like to be able to import various types of files as MARC records ( citations, csv files, etc ). We can add a new function to the plugins system to allow that kind of behavior at a very custom level. Test Plan: 1) Ensure you have plugins enabled and configured correctly 2) Installed the attached version 2.00 of the Kitchen Sink plugin 3) Download the attached text file 4) Browse to "Stage MARC records for import" 5) Select the downloaded text file for staging 6) After uploading, you should see a new area "Transform file to MARC:", select "Example Kitchen-Sink Plugin" from the pulldown menu 7) Click 'Stage for import" 8) Click 'Manage staged records" 9) You should now see two new MARC records! Signed-off-by: Aleisha <aleishaamohia@hotmail.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12412 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12412 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #35483|0 |1 is obsolete| | --- Comment #8 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Created attachment 36478 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=36478&action=edit [PASSED QA] Bug 12412 - Add ability for plugins to convert arbitrary files to MARC from record staging tool Many libraries would like to be able to import various types of files as MARC records ( citations, csv files, etc ). We can add a new function to the plugins system to allow that kind of behavior at a very custom level. Test Plan: 1) Ensure you have plugins enabled and configured correctly 2) Installed the attached version 2.00 of the Kitchen Sink plugin 3) Download the attached text file 4) Browse to "Stage MARC records for import" 5) Select the downloaded text file for staging 6) After uploading, you should see a new area "Transform file to MARC:", select "Example Kitchen-Sink Plugin" from the pulldown menu 7) Click 'Stage for import" 8) Click 'Manage staged records" 9) You should now see two new MARC records! Signed-off-by: Aleisha <aleishaamohia@hotmail.com> Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de> Works as described - interesting new feature. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12412 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |katrin.fischer@bsz-bw.de --- Comment #9 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Wondering if we should update this to be a 'new feature'? -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12412 --- Comment #10 from Kyle M Hall <kyle@bywatersolutions.com> --- (In reply to Katrin Fischer from comment #9)
Wondering if we should update this to be a 'new feature'?
I would certainly consider this to be a new feature! -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12412 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |tomascohen@gmail.com Severity|enhancement |new feature -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12412 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Pushed to Master --- Comment #11 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Feature pushed to master. Thanks Kyle! -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12412 David Cook <dcook@prosentient.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |dcook@prosentient.com.au -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12412 Dobrica Pavlinusic <dpavlin@rot13.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |dpavlin@rot13.org --- Comment #12 from Dobrica Pavlinusic <dpavlin@rot13.org> --- This bug will break Koha installation if there is no enable_plugins in koha-conf.xml with following error: Can't call method "GetPlugins" on an undefined value at /srv/koha_ffzg/tools/stage-marc-import.pl line 206, <DATA> line 603. This is not ideal, since it will break old installations. Problem is line: Koha::Plugins->new()->GetPlugins('to_marc'); where Koha::Plugins->new() will return undef is plugins are not enabled. It seems we also have same syntax in plugins/plugins-home.pl so it should probably be fixed also. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12412 --- Comment #13 from Dobrica Pavlinusic <dpavlin@rot13.org> --- It's a little bit worse: plugins had to be enabled. Even adding <enable_plugins>0</enable_plugins> to koha-conf.xml won't help. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12412 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |14148 -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12412 Pete Edwards <koha@jsense.co.uk> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |koha@jsense.co.uk --- Comment #14 from Pete Edwards <koha@jsense.co.uk> --- This is a really useful facility and I am using it import directly from Excel spreadsheets (XLS binary format). There is a problem if I try and re-import the same file. I get the impression that the import tries to reload the staged file but in this case it doesn't include the transformation step so I get an error: stage-marc-import.pl: binmode() on closed filehandle STDOUT at /usr/share/koha/lib/C4/Templates.pm line 120., referer: http://library-intra.edwards4.co.uk/cgi-bin/koha/tools/stage-marc-import.pl stage-marc-import.pl: Filehandle STDOUT reopened as FH only for input at /usr/lib/perl5/Template/Provider.pm line 964., referer: http://library-intra.edwards4.co.uk/cgi-bin/koha/tools/stage-marc-import.pl Have I understood the issue correctly and does the staging facility need to remember the transformation too? -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12412 --- Comment #15 from Pete Edwards <koha@jsense.co.uk> --- (In reply to Pete Edwards from comment #14)
This is a really useful facility and I am using it import directly from Excel spreadsheets (XLS binary format). There is a problem if I try and re-import the same file. I get the impression that the import tries to reload the staged file but in this case it doesn't include the transformation step so I get an error:
stage-marc-import.pl: binmode() on closed filehandle STDOUT at /usr/share/koha/lib/C4/Templates.pm line 120., referer: http://library-intra.edwards4.co.uk/cgi-bin/koha/tools/stage-marc-import.pl stage-marc-import.pl: Filehandle STDOUT reopened as FH only for input at /usr/lib/perl5/Template/Provider.pm line 964., referer: http://library-intra.edwards4.co.uk/cgi-bin/koha/tools/stage-marc-import.pl
Have I understood the issue correctly and does the staging facility need to remember the transformation too?
Sorry - this was a red herring. I had another error in my plugin meaning I couldn't load the file. However, I still get the following error from somewhere when I import a file: stage-marc-import.pl: binmode() on closed filehandle STDOUT at /usr/share/koha/lib/C4/Templates.pm line 120 I don't know what causes this. Has anyone seen similar? -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=12412 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Pushed to Master |RESOLVED Resolution|--- |FIXED --- Comment #16 from Tomás Cohen Arazi <tomascohen@gmail.com> --- (In reply to Pete Edwards from comment #15)
(In reply to Pete Edwards from comment #14)
This is a really useful facility and I am using it import directly from Excel spreadsheets (XLS binary format). There is a problem if I try and re-import the same file. I get the impression that the import tries to reload the staged file but in this case it doesn't include the transformation step so I get an error:
stage-marc-import.pl: binmode() on closed filehandle STDOUT at /usr/share/koha/lib/C4/Templates.pm line 120., referer: http://library-intra.edwards4.co.uk/cgi-bin/koha/tools/stage-marc-import.pl stage-marc-import.pl: Filehandle STDOUT reopened as FH only for input at /usr/lib/perl5/Template/Provider.pm line 964., referer: http://library-intra.edwards4.co.uk/cgi-bin/koha/tools/stage-marc-import.pl
Have I understood the issue correctly and does the staging facility need to remember the transformation too?
Sorry - this was a red herring. I had another error in my plugin meaning I couldn't load the file. However, I still get the following error from somewhere when I import a file: stage-marc-import.pl: binmode() on closed filehandle STDOUT at /usr/share/koha/lib/C4/Templates.pm line 120 I don't know what causes this. Has anyone seen similar?
I think you should either: 1) send an email to the devel list 2) fill a bug for what you are seeing, and check with the devs taking care of it. You should probably do (1) and then (depending on the results) do (2). -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org