Bug 22451 - Asset plugin is using the version from the DB
Summary: Asset plugin is using the version from the DB
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Architecture, internals, and plumbing (show other bugs)
Version: Main
Hardware: All All
: P5 - low normal (vote)
Assignee: Josef Moravec
QA Contact: Testopia
URL:
Keywords:
Depends on: 20658
Blocks: 18308
  Show dependency treegraph
 
Reported: 2019-03-04 18:51 UTC by Jonathan Druart
Modified: 2020-06-04 20:33 UTC (History)
5 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Small patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
19.05.00, 18.11.05


Attachments
Bug 22451: Make Asset plugin use Koha::version instead of version from db (1.06 KB, patch)
2019-03-04 20:36 UTC, Josef Moravec
Details | Diff | Splinter Review
Bug 22451: Update test (1014 bytes, patch)
2019-03-04 20:36 UTC, Josef Moravec
Details | Diff | Splinter Review
Bug 22451: Use Asset everywhere (4.60 KB, patch)
2019-03-04 20:36 UTC, Josef Moravec
Details | Diff | Splinter Review
Bug 22451: Make Asset plugin use Koha::version instead of version from db (1.07 KB, patch)
2019-03-05 19:30 UTC, Josef Moravec
Details | Diff | Splinter Review
Bug 22451: Update test (1014 bytes, patch)
2019-03-05 19:30 UTC, Josef Moravec
Details | Diff | Splinter Review
Bug 22451: Use Asset everywhere (4.60 KB, patch)
2019-03-05 19:30 UTC, Josef Moravec
Details | Diff | Splinter Review
Bug 22451: Make Asset plugin use Koha::version instead of version from db (1.13 KB, patch)
2019-04-11 22:54 UTC, Hayley Pelham
Details | Diff | Splinter Review
Bug 22451: Update test (1.06 KB, patch)
2019-04-11 22:55 UTC, Hayley Pelham
Details | Diff | Splinter Review
Bug 22451: Use Asset everywhere (4.68 KB, patch)
2019-04-11 22:55 UTC, Hayley Pelham
Details | Diff | Splinter Review
Bug 22451: Make Asset plugin use Koha::version instead of version from db (1.19 KB, patch)
2019-04-12 12:35 UTC, Katrin Fischer
Details | Diff | Splinter Review
Bug 22451: Update test (1.11 KB, patch)
2019-04-12 12:35 UTC, Katrin Fischer
Details | Diff | Splinter Review
Bug 22451: Use Asset everywhere (4.74 KB, patch)
2019-04-12 12:35 UTC, Katrin Fischer
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Jonathan Druart 2019-03-04 18:51:29 UTC
Should not be retrieved with Koha::Version?

See bug 20658 comment 13.
Comment 1 Josef Moravec 2019-03-04 20:36:14 UTC
Created attachment 86034 [details] [review]
Bug 22451: Make Asset plugin use Koha::version instead of version from db

Test plan:
Apply the patch a try to use Koha, css and js files should be used
normally
Comment 2 Josef Moravec 2019-03-04 20:36:18 UTC
Created attachment 86035 [details] [review]
Bug 22451: Update test

Test plan:
prove t/db_dependent/Koha/Template/Plugin/Asset.t
Comment 3 Josef Moravec 2019-03-04 20:36:22 UTC
Created attachment 86036 [details] [review]
Bug 22451: Use Asset everywhere

Test plan:
Use installer and onboaarding tool, make sure the js and css files are
loaded
Comment 4 Jonathan Druart 2019-03-05 18:28:11 UTC
error: sha1 information is lacking or useless (koha-tmpl/intranet-tmpl/prog/en/includes/installer-doc-head-close.inc).
Comment 5 Jonathan Druart 2019-03-05 18:44:44 UTC
1. I'd say there is a dot missing:
$1$2$3 should be $1.$2$3 to match the value in the DB

2. I do not understand the changes in the tests.
Comment 6 Josef Moravec 2019-03-05 19:30:11 UTC
Created attachment 86115 [details] [review]
Bug 22451: Make Asset plugin use Koha::version instead of version from db

Test plan:
Apply the patch a try to use Koha, css and js files should be used
normally
Comment 7 Josef Moravec 2019-03-05 19:30:15 UTC
Created attachment 86116 [details] [review]
Bug 22451: Update test

Test plan:
prove t/db_dependent/Koha/Template/Plugin/Asset.t
Comment 8 Josef Moravec 2019-03-05 19:30:19 UTC
Created attachment 86117 [details] [review]
Bug 22451: Use Asset everywhere

Test plan:
Use installer and onboaarding tool, make sure the js and css files are
loaded
Comment 9 Josef Moravec 2019-03-05 19:31:33 UTC
(In reply to Jonathan Druart from comment #5)
> 1. I'd say there is a dot missing:
> $1$2$3 should be $1.$2$3 to match the value in the DB
$1 is for first two version parts with dot... so dot is here, but I agree it is not obvious... maybe better to format regex with 4 parts to make it better readable - i updated the first patch
> 
> 2. I do not understand the changes in the tests.

When database is not fully updated, then the test could fail if using version preference... maybe a bit
Comment 10 Hayley Pelham 2019-04-11 22:54:55 UTC
Created attachment 87821 [details] [review]
Bug 22451: Make Asset plugin use Koha::version instead of version from db

Test plan:
Apply the patch a try to use Koha, css and js files should be used
normally

Signed-off-by: Hayley Mapley <hayleymapley@catalyst.net.nz>
Comment 11 Hayley Pelham 2019-04-11 22:55:24 UTC
Created attachment 87822 [details] [review]
Bug 22451: Update test

Test plan:
prove t/db_dependent/Koha/Template/Plugin/Asset.t

Signed-off-by: Hayley Mapley <hayleymapley@catalyst.net.nz>
Comment 12 Hayley Pelham 2019-04-11 22:55:57 UTC
Created attachment 87823 [details] [review]
Bug 22451: Use Asset everywhere

Test plan:
Use installer and onboaarding tool, make sure the js and css files are
loaded

Signed-off-by: Hayley Mapley <hayleymapley@catalyst.net.nz>
Comment 13 Katrin Fischer 2019-04-12 12:35:32 UTC
Created attachment 87897 [details] [review]
Bug 22451: Make Asset plugin use Koha::version instead of version from db

Test plan:
Apply the patch a try to use Koha, css and js files should be used
normally

Signed-off-by: Hayley Mapley <hayleymapley@catalyst.net.nz>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 14 Katrin Fischer 2019-04-12 12:35:37 UTC
Created attachment 87899 [details] [review]
Bug 22451: Update test

Test plan:
prove t/db_dependent/Koha/Template/Plugin/Asset.t

Signed-off-by: Hayley Mapley <hayleymapley@catalyst.net.nz>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 15 Katrin Fischer 2019-04-12 12:35:40 UTC
Created attachment 87900 [details] [review]
Bug 22451: Use Asset everywhere

Test plan:
Use installer and onboaarding tool, make sure the js and css files are
loaded

Signed-off-by: Hayley Mapley <hayleymapley@catalyst.net.nz>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 16 Nick Clemens 2019-04-16 13:26:21 UTC
Awesome work all!

Pushed to master for 19.05
Comment 17 Martin Renvoize 2019-04-25 13:29:06 UTC
Pushed to 18.11.x for 18.11.05
Comment 18 Lucas Gass 2019-04-26 15:59:36 UTC
missing dependency for 18.05.x, not backporting