{"action":"created","issue":{"url":"https://api.github.com/repos/raml-org/ramldt2jsonschema/issues/9","repository_url":"https://api.github.com/repos/raml-org/ramldt2jsonschema","labels_url":"https://api.github.com/repos/raml-org/ramldt2jsonschema/issues/9/labels{/name}","comments_url":"https://api.github.com/repos/raml-org/ramldt2jsonschema/issues/9/comments","events_url":"https://api.github.com/repos/raml-org/ramldt2jsonschema/issues/9/events","html_url":"https://github.com/raml-org/ramldt2jsonschema/issues/9","id":187167745,"number":9,"title":"Cannot handle !include","user":{"login":"dwarburt","id":52614,"avatar_url":"https://avatars.githubusercontent.com/u/52614?v=3","gravatar_id":"","url":"https://api.github.com/users/dwarburt","html_url":"https://github.com/dwarburt","followers_url":"https://api.github.com/users/dwarburt/followers","following_url":"https://api.github.com/users/dwarburt/following{/other_user}","gists_url":"https://api.github.com/users/dwarburt/gists{/gist_id}","starred_url":"https://api.github.com/users/dwarburt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dwarburt/subscriptions","organizations_url":"https://api.github.com/users/dwarburt/orgs","repos_url":"https://api.github.com/users/dwarburt/repos","events_url":"https://api.github.com/users/dwarburt/events{/privacy}","received_events_url":"https://api.github.com/users/dwarburt/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2016-11-03T19:30:27Z","updated_at":"2016-11-11T19:56:33Z","closed_at":null,"body":"A simple Hello World RAML project, that is modified only to !include a file, will generate this exception:\r\n\r\n`[~/git/tmp/raml-test]$ dt2js ./api.raml TestType\r\n{ Error\r\n    at generateError (/usr/local/lib/node_modules/ramldt2jsonschema/node_modules/js-yaml/lib/js-yaml/loader.js:162:10)\r\n    at throwError (/usr/local/lib/node_modules/ramldt2jsonschema/node_modules/js-yaml/lib/js-yaml/loader.js:168:9)\r\n    at composeNode (/usr/local/lib/node_modules/ramldt2jsonschema/node_modules/js-yaml/lib/js-yaml/loader.js:1397:7)\r\n    at readBlockMapping (/usr/local/lib/node_modules/ramldt2jsonschema/node_modules/js-yaml/lib/js-yaml/loader.js:1056:11)\r\n    at composeNode (/usr/local/lib/node_modules/ramldt2jsonschema/node_modules/js-yaml/lib/js-yaml/loader.js:1326:12)\r\n    at readBlockMapping (/usr/local/lib/node_modules/ramldt2jsonschema/node_modules/js-yaml/lib/js-yaml/loader.js:1056:11)\r\n    at composeNode (/usr/local/lib/node_modules/ramldt2jsonschema/node_modules/js-yaml/lib/js-yaml/loader.js:1326:12)\r\n    at readDocument (/usr/local/lib/node_modules/ramldt2jsonschema/node_modules/js-yaml/lib/js-yaml/loader.js:1488:3)\r\n    at loadDocuments (/usr/local/lib/node_modules/ramldt2jsonschema/node_modules/js-yaml/lib/js-yaml/loader.js:1544:5)\r\n    at load (/usr/local/lib/node_modules/ramldt2jsonschema/node_modules/js-yaml/lib/js-yaml/loader.js:1561:19)\r\n  name: 'YAMLException',\r\n  reason: 'unknown tag !<!include>',\r\n  mark:\r\n   Mark {\r\n     name: null,\r\n     buffer: '#%RAML 1.0\\ntitle: Test Raml DT to JS schema\\nversion: v1\\nbaseUri: http://api.samplehost.com\\ntypes:\\n  TestType: !include type1.yml\\n/helloWorld:\\n  get:\\n    responses:\\n      200:\\n        body:\\n          application/json:\\n            example: |\\n              {\\n                \"message\" : \"Hello World\"\\n              }\\n\\u0000',\r\n     position: 128,\r\n     line: 5,\r\n     column: 30 },\r\n  message: 'unknown tag !<!include> at line 6, column 31:\\n      TestType: !include type1.yml\\n                                  ^' }`"},"comment":{"url":"https://api.github.com/repos/raml-org/ramldt2jsonschema/issues/comments/260041916","html_url":"https://github.com/raml-org/ramldt2jsonschema/issues/9#issuecomment-260041916","issue_url":"https://api.github.com/repos/raml-org/ramldt2jsonschema/issues/9","id":260041916,"user":{"login":"jstoiko","id":9660342,"avatar_url":"https://avatars.githubusercontent.com/u/9660342?v=3","gravatar_id":"","url":"https://api.github.com/users/jstoiko","html_url":"https://github.com/jstoiko","followers_url":"https://api.github.com/users/jstoiko/followers","following_url":"https://api.github.com/users/jstoiko/following{/other_user}","gists_url":"https://api.github.com/users/jstoiko/gists{/gist_id}","starred_url":"https://api.github.com/users/jstoiko/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jstoiko/subscriptions","organizations_url":"https://api.github.com/users/jstoiko/orgs","repos_url":"https://api.github.com/users/jstoiko/repos","events_url":"https://api.github.com/users/jstoiko/events{/privacy}","received_events_url":"https://api.github.com/users/jstoiko/received_events","type":"User","site_admin":false},"created_at":"2016-11-11T19:56:33Z","updated_at":"2016-11-11T19:56:33Z","body":"@dwarburt: you're right. That's a limitation of `dt2js`. Includes are not supported (yet?). you should be able to run it against the file that contains that type though."}}
{"actor":{"display_login":"jstoiko"}}