Uploaded image for project: 'ui-calendar'
  1. ui-calendar
  2. UICAL-40

Invalid JSON in translations breaks web pack build

    XMLWordPrintable

    Details

    • Template:

      Description

      The hourly build for the folio-testing UI failed due to:

      fatal: [10.36.1.65]: FAILED! => {"changed": true, "cmd": "yarn build output --sourcemap", "delta": "0:00:02.246389", "end": "2018-09-14 10:03:09.539849", "failed": true, "rc": 1, "start": "2018-09-14 10:03:07.293460", "stderr": "SyntaxError: Unexpected string in JSON at position 3654\n    at JSON.parse (<anonymous>)\n    at Function.loadFile (/etc/folio/stripes/node_modules/@folio/stripes-core/webpack/stripes-translations-plugin.js:128:17)\n    at StripesTranslationPlugin.loadTranslationsDirectory (/etc/folio/stripes/node_modules/@folio/stripes-core/webpack/stripes-translations-plugin.js:103:55)\n    at StripesTranslationPlugin.gatherAllTranslations (/etc/folio/stripes/node_modules/@folio/stripes-core/webpack/stripes-translations-plugin.js:77:41)\n    at StripesTranslationPlugin.apply (/etc/folio/stripes/node_modules/@folio/stripes-core/webpack/stripes-translations-plugin.js:44:34)\n    at stripesPlugins.forEach.plugin (/etc/folio/stripes/node_modules/@folio/stripes-core/webpack/stripes-webpack-plugin.js:29:45)\n    at Array.forEach (<anonymous>)\n    at StripesWebpackPlugin.apply (/etc/folio/stripes/node_modules/@folio/stripes-core/webpack/stripes-webpack-plugin.js:29:20)\n    at webpack (/etc/folio/stripes/node_modules/webpack/lib/webpack.js:37:12)\n    at Promise (/etc/folio/stripes/node_modules/@folio/stripes-core/webpack/build.js:40:22)\nerror Command failed with exit code 1.", "stderr_lines": ["SyntaxError: Unexpected string in JSON at position 3654", "    at JSON.parse (<anonymous>)", "    at Function.loadFile (/etc/folio/stripes/node_modules/@folio/stripes-core/webpack/stripes-translations-plugin.js:128:17)", "    at StripesTranslationPlugin.loadTranslationsDirectory (/etc/folio/stripes/node_modules/@folio/stripes-core/webpack/stripes-translations-plugin.js:103:55)", "    at StripesTranslationPlugin.gatherAllTranslations (/etc/folio/stripes/node_modules/@folio/stripes-core/webpack/stripes-translations-plugin.js:77:41)", "    at StripesTranslationPlugin.apply (/etc/folio/stripes/node_modules/@folio/stripes-core/webpack/stripes-translations-plugin.js:44:34)", "    at stripesPlugins.forEach.plugin (/etc/folio/stripes/node_modules/@folio/stripes-core/webpack/stripes-webpack-plugin.js:29:45)", "    at Array.forEach (<anonymous>)", "    at StripesWebpackPlugin.apply (/etc/folio/stripes/node_modules/@folio/stripes-core/webpack/stripes-webpack-plugin.js:29:20)", "    at webpack (/etc/folio/stripes/node_modules/webpack/lib/webpack.js:37:12)", "    at Promise (/etc/folio/stripes/node_modules/@folio/stripes-core/webpack/build.js:40:22)", "error Command failed with exit code 1."], "stdout": "yarn run v1.9.4\n$ export NODE_OPTIONS=\"--max-old-space-size=3096 $NODE_OPTIONS\"; stripes build stripes.config.js output --sourcemap\nBuilding...\ninfo Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.", "stdout_lines": ["yarn run v1.9.4", "$ export NODE_OPTIONS=\"--max-old-space-size=3096 $NODE_OPTIONS\"; stripes build stripes.config.js output --sourcemap", "Building...", "info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command."]}
      

      It appears this is caused by invalid JSON in a translation file.

      Having looked at the recent changes, it appears to be that the merge of https://github.com/folio-org/ui-calendar/blob/43d54ec0d7c502df573d656097c93525f4ccd527/translations/ui-calendar/hu.json created invalid JSON, due to a lack of comma at the end of the modifyRegularLibraryValidityPeriod line.

        TestRail: Results

          Attachments

            Activity

              People

              Assignee:
              ibender Istvan Bender
              Reporter:
              marcjohnson Marc Johnson
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  TestRail: Runs

                    TestRail: Cases