{"action":"opened","issue":{"url":"https://api.github.com/repos/weaveworks/kubediff/issues/13","repository_url":"https://api.github.com/repos/weaveworks/kubediff","labels_url":"https://api.github.com/repos/weaveworks/kubediff/issues/13/labels{/name}","comments_url":"https://api.github.com/repos/weaveworks/kubediff/issues/13/comments","events_url":"https://api.github.com/repos/weaveworks/kubediff/issues/13/events","html_url":"https://github.com/weaveworks/kubediff/issues/13","id":183559680,"number":13,"title":"Fails with multiple documents","user":{"login":"sstarcher","id":3778974,"avatar_url":"https://avatars.githubusercontent.com/u/3778974?v=3","gravatar_id":"","url":"https://api.github.com/users/sstarcher","html_url":"https://github.com/sstarcher","followers_url":"https://api.github.com/users/sstarcher/followers","following_url":"https://api.github.com/users/sstarcher/following{/other_user}","gists_url":"https://api.github.com/users/sstarcher/gists{/gist_id}","starred_url":"https://api.github.com/users/sstarcher/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sstarcher/subscriptions","organizations_url":"https://api.github.com/users/sstarcher/orgs","repos_url":"https://api.github.com/users/sstarcher/repos","events_url":"https://api.github.com/users/sstarcher/events{/privacy}","received_events_url":"https://api.github.com/users/sstarcher/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2016-10-18T00:11:50Z","updated_at":"2016-10-18T00:11:50Z","closed_at":null,"body":"If a yaml file contains multiple definitions the code errors.\r\n\r\nExample:\r\n```\r\nkind: ClusterRoleBinding\r\napiVersion: rbac.authorization.k8s.io/v1alpha1\r\nmetadata:\r\n  name: readonly-binding\r\nsubjects:\r\n  - kind: Group\r\n    name: readonly\r\nroleRef:\r\n  kind: ClusterRole\r\n  name: readonly-role\r\n  apiVersion: rbac.authorization.k8s.io/v1alpha1\r\n---\r\nkind: ClusterRoleBinding\r\napiVersion: rbac.authorization.k8s.io/v1alpha1\r\nmetadata:\r\n  name: system-admin-binding\r\nsubjects:\r\n  - kind: ServiceAccount\r\n    name: default\r\n    namespace: system\r\nroleRef:\r\n  kind: ClusterRole\r\n  name: admin-role\r\n  apiVersion: rbac.authorization.k8s.io/v1alpha1\r\n```\r\n\r\n\r\n```\r\nTraceback (most recent call last):\r\n  File \"kubediff/kubediff\", line 40, in <module>\r\n    main()\r\n  File \"kubediff/kubediff\", line 34, in main\r\n    failed = check_files(args, printer, options.kubeconfig)\r\n  File \"kubediff/kubedifflib/_diff.py\", line 137, in check_files\r\n    differences += check_file(printer, path, kubeconfig=kubeconfig)\r\n  File \"kubediff/kubedifflib/_diff.py\", line 80, in check_file\r\n    expected = yaml.load(stream)\r\n  File \"/usr/local/lib/python2.7/site-packages/yaml/__init__.py\", line 71, in load\r\n    return loader.get_single_data()\r\n  File \"/usr/local/lib/python2.7/site-packages/yaml/constructor.py\", line 37, in get_single_data\r\n    node = self.get_single_node()\r\n  File \"/usr/local/lib/python2.7/site-packages/yaml/composer.py\", line 43, in get_single_node\r\n    event.start_mark)\r\nyaml.composer.ComposerError: expected a single document in the stream\r\n  in \"workspace/charts/x/manifests/x.yaml\", line 1, column 1\r\nbut found another document\r\n  in \"workspace/charts/x/manifests/x.yaml\", line 10, column 1\r\n```"}}
{"actor":{"display_login":"sstarcher"}}