Skip to content
This repository has been archived by the owner on Apr 6, 2023. It is now read-only.

Fix/type key exception #2

Merged
merged 5 commits into from
Jan 21, 2020
Merged

Fix/type key exception #2

merged 5 commits into from
Jan 21, 2020

Conversation

AndyOGo
Copy link
Contributor

@AndyOGo AndyOGo commented Jan 17, 2020

Add failing test file for adobe/jsonschema2md#201

npm run test

> cyclic-schemas-test@1.0.0 test .../dev/cyclic-schemas-test
> jsonschema2md -o docs/ -x docs/ -d schemas/ -e json

loading schemas
cannot resolve http://www.axa.ch/schemas/unknown.json
cannot resolve http://www.axa.ch/schemas/unknown.json
cannot resolve http://www.axa.ch/schemas/unknown.json
cannot resolve http://www.axa.ch/schemas/unknown.json
cannot resolve http://www.axa.ch/schemas/unknown.json
cannot resolve http://www.axa.ch/schemas/unknown.json
writing schemas to .../dev/cyclic-schemas-test/docs
building readme
generating markdown
cannot resolve http://www.axa.ch/schemas/unknown.json
cannot resolve http://www.axa.ch/schemas/unknown.json
cannot resolve http://www.axa.ch/schemas/unknown.json
cannot resolve http://www.axa.ch/schemas/unknown.json
cannot resolve http://www.axa.ch/schemas/unknown.json
cannot resolve http://www.axa.ch/schemas/unknown.json
(node:4460) UnhandledPromiseRejectionWarning: TypeError: Cannot convert object to primitive value
    at String (<anonymous>)
    at longestStreak (.../dev/cyclic-schemas-test/node_modules/longest-streak/index.js:16:11)
    at Of.inlineCode (.../dev/cyclic-schemas-test/node_modules/remark-stringify/lib/visitors/inline-code.js:30:39)
    at Of.one [as visit] (.../dev/cyclic-schemas-test/node_modules/remark-stringify/lib/macro/one.js:19:30)
    at Of.all (.../dev/cyclic-schemas-test/node_modules/remark-stringify/lib/macro/all.js:14:27)
    at Of.tableCell (.../dev/cyclic-schemas-test/node_modules/remark-stringify/lib/visitors/table-cell.js:8:15)
    at Of.one [as visit] (.../dev/cyclic-schemas-test/node_modules/remark-stringify/lib/macro/one.js:19:30)
    at Of.all (.../dev/cyclic-schemas-test/node_modules/remark-stringify/lib/macro/all.js:14:27)
    at Of.table (.../dev/cyclic-schemas-test/node_modules/remark-stringify/lib/visitors/table.js:44:26)
    at Of.one [as visit] (.../dev/cyclic-schemas-test/node_modules/remark-stringify/lib/macro/one.js:19:30)
(node:4460) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:4460) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
.../dev/cyclic-schemas-test/docs/README.md created

@AndyOGo AndyOGo added the enhancement New feature or request label Jan 17, 2020
@AndyOGo AndyOGo self-assigned this Jan 17, 2020
trieloff added a commit to adobe/jsonschema2md that referenced this pull request Jan 20, 2020
trieloff added a commit to adobe/jsonschema2md that referenced this pull request Jan 20, 2020
…cyclic-schemas-test#2

this uses the axa-ch/cyclic-schemas-test#2 branch for the integration tests, which then fail, as
expected

see #201
package.json Outdated
@@ -9,6 +9,6 @@
"author": "",
"license": "ISC",
"devDependencies": {
"@adobe/jsonschema2md": "^4.0.3"
"@adobe/jsonschema2md": "^4.0.9"
Copy link
Contributor Author

@AndyOGo AndyOGo Jan 20, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Error: Cannot find module 'es2015-i18n-tag'

npm run test

> cyclic-schemas-test@1.0.0 test .../dev/cyclic-schemas-test
> jsonschema2md -o docs/ -x docs/ -d schemas/ -e json

internal/modules/cjs/loader.js:583
    throw err;
    ^

Error: Cannot find module 'es2015-i18n-tag'
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:581:15)
    at Function.Module._load (internal/modules/cjs/loader.js:507:25)
    at Module.require (internal/modules/cjs/loader.js:637:17)
    at require (internal/modules/cjs/helpers.js:22:18)
    at Object.<anonymous> (.../dev/cyclic-schemas-test/node_modules/@adobe/jsonschema2md/lib/index.js:23:24)
    at Module._compile (internal/modules/cjs/loader.js:689:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:700:10)
    at Module.load (internal/modules/cjs/loader.js:599:32)
    at tryModuleLoad (internal/modules/cjs/loader.js:538:12)
    at Function.Module._load (internal/modules/cjs/loader.js:530:3)

It doesn't seem to be installed properly 🤔

ls -a ./node_modules/es2015-i18n-tag/
.			.all-contributorsrc	CONTRIBUTING.md		README.md		package.json
..			CHANGELOG.md		LICENSE			benchmark.js		yarn.lock

@AndyOGo AndyOGo merged commit dd3ca02 into master Jan 21, 2020
@AndyOGo AndyOGo deleted the fix/type-key-exception branch January 21, 2020 09:37
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant