fabricius: joined #tikiwiki jonnyb: joined #tikiwiki josephzitt: joined #tikiwiki luciash: jonnyb: hi, good morning! jonnyb: polom luciash luciash: jonnyb: was trying to debug H5P yesterday and found out some differences in the old .h5p and current .h5p files
jonnyb: for example in the simple accordion, currently there is "language":"und" and "license":"U" crap when I download the file from their examples on the site -- is it rendered? by my browser wrongly? old h5p accordion file I had stored somewhere still works nicely when I upload it to Tiki 17/18/19 but these freshly downloaded ones yell just errors on me :( jonnyb: sry, later luciash: so far I noticed in the old one there was "language":"en" and no "license" entry in the h5p.json file included in the h5p zip
but it still doesn't work if I edit and repackage and reupload the file -- it is not giving the errors but is not recognized as h5p lib file anyway jonnyb: joined #tikiwiki
repolom
sorry luciash, yes, it looks like H5P have broken backwards compatibility - i'll try and upgrade our version in 19.x but as that was slightly broken before i'm not too hopeful it'll fix everything... luciash: jonnyb: thank you! what version do we use? and is there any way to get the old format h5p content files still omehow?
s/omehow jonnyb: we're on 1.17 and the latest is 1.19 (and 1.18 for the editor)
No idea about older files, sorry
ok, i just committed updates for the h5p libraries in 19.x luciash, can you see if that helps with the newer files? Seems to work for me luciash: jonnyb: yay, going to update and test right away! jonnyb: thanks luciash luciash: re-uploaded the agamotto, it appears in the create h5p dropdown now, yay, but...
it seems to be stuck on "Loading, please wait..." when I choose it
will try another h5p content type -: luciash trying chart luciash: this look promising: "Success: Added 2 new H5P libraries."
darn, again "Loading, please wait..." :(
console gives uncaught syntax error
browser conole
jonnyb: "Uncaught SyntaxError: Invalid regular expression flags at eval (<anonymous>) at Object.ns.libraryRequested (h5peditor.js?ver=19.1svn:78)"
at Object.success (h5peditor.js?ver=19.1svn:137)
at c (jquery.js?ver=19.1svn:2)
at Object.fireWith [as resolveWith] (jquery.js?ver=19.1svn:2)
at k (jquery.js?ver=19.1svn:4)
at XMLHttpRequest.r (jquery.js?ver=19.1svn:4) jonnyb: i've never managed to work out how to debug their code, it just works or it doesn't... let me try some more files... luciash: the old format accordion still works though (just for your information) without the JS error
jonnyb: thanks, try some which you did not uploaded yet to your file gal jonnyb: agamoto seems ok for me
looks like it hasn't changed - file name still agamotto-80158.h5p
chart's ok too (doesn't do much though) ricks99: joined #tikiwiki luciash: jonnyb: display works, yes, but create new content? jonnyb: coo, even the speech recognition french lesson one works 8)
Ah no, editing is totally broken
has been since tiki 16 i think :( luciash: old format create or edit works still
but these new ones give the JS error I pasted when trying to create jonnyb: yes, they changed a load of stuff but couldn't tell me what, i spent hours trying to revese engineer it but failed luciash: let me reindex/clear cache/etc. again jonnyb: I was focussing on getting uploading and viewing working for Rick mainly luciash: is it theirs? the error. or something wrong in our code?
fyi: this was in Chrome console
I will test in firefox now jonnyb: the errors are in their code, but probably caused by our code that initialises the editor which was based on what worked a few (minor) versions ago, think it was 1.15 or 1.16 we started on
i even read all of their commits to see if i could spot what they had changed but couldn't luciash: ah, in Firefox it is a bit different... the "Loading" is not tuck and gets away but in the FF console there is slightly different error message
s/tuck/stuck
TypeError: metadataSemantics is undefined[Learn More] h5peditor-metadata.js:339:21
findField
https://demo.luciash.eu/tiki19x/vendor_bundled/vendor/h5p/h5p-editor/scripts/h5peditor-metadata.js:339:21
MetadataForm
https://demo.luciash.eu/tiki19x/vendor_bundled/vendor/h5p/h5p-editor/scripts/h5peditor-metadata.js:27:7
ns.Form.prototype.processSemantics
https://demo.luciash.eu/tiki19x/vendor_bundled/vendor/h5p/h5p-editor/scripts/h5peditor-form.js:91:25
ns.LibrarySelector.prototype.loadSemantics/<
https://demo.luciash.eu/tiki19x/vendor_bundled/vendor/h5p/h5p-editor/scripts/h5peditor-library-selector.js:330:7
success/<
https://demo.luciash.eu/tiki19x/vendor_bundled/vendor/h5p/h5p-editor/scripts/h5peditor.js:181:13
ns.libraryRequested/</script.onload
https://demo.luciash.eu/tiki19x/vendor_bundled/vendor/h5p/h5p-editor/scripts/h5peditor.js:106:15
...
does it ring a bell?
ah, sorry, you probably already know this...
sorry to hear that even JS guru like you is struggling with H5P code
aparently something with metadata semantics according to Firefox :-p jonnyb: yes, was looking at the same code, seems metadataSemantics should be stuck on the H5PEditor object, but isn't - probably a clue! luciash: jonnyb: interesting that Firefox console is a bit more helpful than Chrome console for debugging jonnyb: interesting - i stopped using firefox ages ago as it was so slow (and then they got rid of firebug) - should take another look i guess luciash: jonnyb: do you have "show TPL in source" enabled? I am just wondering if that cannot cause some interferrence here for me jonnyb: don't think so luciash: in this case
ok, thanks jonnyb: basically they're changed their API but without saying what
but i have the old WP plugin and the new version so am doing a diff on the main files... (altohugh have to go out, so more later) luciash: superb, thanks a lot and see you laterz! jonnyb: woo! i think i got it working!
need to review and will commit when i get back :) luciash: w00ty w00t!
:) trebmuh: joined #tikiwiki ricks99: @jonnyb still around? luciash: hey ricks99 ! :)
not anymore, but he will be back ;) ricks99: good morning (afternoon?) luciash
thx. i'll ping him later. that h5p stuff is for me luciash: ricks99: not jut for you ;)
s/jut/just/ ricks99: true. :)
all your h5p belong to *me* luciash: :D ricks99: joined #tikiwiki jonnyb: joined #tikiwiki
moloq
repolom luciash - try h5p in 19.x with r68753? Seems better here... luciash: coolio, will try! need to go out downtown now, will be back later fabricius: joined #tikiwiki luciash: re jonnyb: joined #tikiwiki luciash: jonnyb: wb! jonnyb: :) luciash: no luck :( i still get the same error it seems "TypeError: metadataSemantics is undefined"
when trying to created/edit jonnyb: Have more to coem for h5p, not sure what it will fix but there were lots of new fields in the database tables
Oh? svn up, caches, composer all updated? luciash: you said you got it working, how?
yep, did all the updates necessary i believe
except index rebuild
which i suppose is not necessary
did you have to re-upload the h5p content type?
I did svn up; sh setup.sh -pphp71 composer; php71 console.php d:u jonnyb: yes, index not involved
hmm, that metadataSemantics was the bug i thought i fixed
in your browser debugger, do you see lib/core/H5P/editor.js ?
line 10 should be H5PEditor.metadataSemantics = H5PIntegration.editor.metadataSemantics (which is what fixed it for me) luciash: yes, I see that editor.js file referenced
let me check the line
oh, I do not see that file referenced there actually
I see h5peditor-metadata.js:339:21
and then 6 others when I expand the collapsed error:
findField
https://demo.luciash.eu/tiki19x/vendor_bundled/vendor/h5p/h5p-editor/scripts/h5peditor-metadata.js:339:21
MetadataForm
https://demo.luciash.eu/tiki19x/vendor_bundled/vendor/h5p/h5p-editor/scripts/h5peditor-metadata.js:27:7
ns.Form.prototype.processSemantics
https://demo.luciash.eu/tiki19x/vendor_bundled/vendor/h5p/h5p-editor/scripts/h5peditor-form.js:91:25
ns.LibrarySelector.prototype.loadSemantics/<
https://demo.luciash.eu/tiki19x/vendor_bundled/vendor/h5p/h5p-editor/scripts/h5peditor-library-selector.js:330:7
success/<
https://demo.luciash.eu/tiki19x/vendor_bundled/vendor/h5p/h5p-editor/scripts/h5peditor.js:181:13
ns.libraryRequested/</script.onload
https://demo.luciash.eu/tiki19x/vendor_bundled/vendor/h5p/h5p-editor/scripts/h5peditor.js:106:15
when I open that file you said I can see this:
H5PEditor.metadataSemantics = H5PIntegration.editor.metadataSemantics;
on line 10
that is a stubborn bug :(
let me try upload another type
nope, sorry, that damn issue is stuck here :-/
bbl jonnyb: joined #tikiwiki Jyhem_laptop: joined #tikiwiki ricks99: joined #tikiwiki