datalad / datalad-catalog

Create a user-friendly data catalog from structured metadata
https://datalad-catalog.netlify.app
MIT License
15 stars 12 forks source link

BUG: display_schema page has bugs after schema change #251

Closed jsheunis closed 3 months ago

jsheunis commented 1 year ago

Page: https://datalad.github.io/datalad-catalog/display_schema.html

Click on metadata_sources schema => no display.

Console output:

Failed to load resource: the server responded with a status of 404 ()
display_schema.js:519 WARNING: schema file could not be loaded:./assets/jsonschema__metadata_sources.json
/favicon.ico:1          Failed to load resource: the server responded with a status of 404 ()
vue.js:634 [Vue warn]: Error in render: "TypeError: Cannot read properties of undefined (reading 'title')"

(found in <Root>)
warn @ vue.js:634
vue.js:1906 TypeError: Cannot read properties of undefined (reading 'title')
    at Proxy.eval (eval at createFunction (vue.js:11698:14), <anonymous>:3:2545)
    at Vue._render (vue.js:3572:24)
    at Vue.updateComponent (vue.js:4082:23)
    at Watcher.get (vue.js:4494:27)
    at Watcher.run (vue.js:4569:24)
    at flushSchedulerQueue (vue.js:4327:15)
    at Array.<anonymous> (vue.js:1998:14)
    at flushCallbacks (vue.js:1924:16)
logError @ vue.js:1906
vue.js:634 [Vue warn]: Error in render: "TypeError: Cannot read properties of undefined (reading 'title')"

(found in <Root>)
warn @ vue.js:634
vue.js:1906 TypeError: Cannot read properties of undefined (reading 'title')
    at Proxy.eval (eval at createFunction (vue.js:11698:14), <anonymous>:3:2545)
    at Vue._render (vue.js:3572:24)
    at Vue.updateComponent (vue.js:4082:23)
    at Watcher.get (vue.js:4494:27)
    at Watcher.run (vue.js:4569:24)
    at flushSchedulerQueue (vue.js:4327:15)
    at Array.<anonymous> (vue.js:1998:14)
    at flushCallbacks (vue.js:1924:16)
jsheunis commented 3 months ago

This was fixed in subsequent changes to the display-schema content, but the fix was not explicitly documented.

NOTE: The display schema functionality could perhaps be useful to refactor and extract into its own package at some undefined point in the future. But this is not a priority for future datalad-catalog developments.