{"action":"created","issue":{"url":"https://api.github.com/repos/biocore/biom-format/issues/609","repository_url":"https://api.github.com/repos/biocore/biom-format","labels_url":"https://api.github.com/repos/biocore/biom-format/issues/609/labels{/name}","comments_url":"https://api.github.com/repos/biocore/biom-format/issues/609/comments","events_url":"https://api.github.com/repos/biocore/biom-format/issues/609/events","html_url":"https://github.com/biocore/biom-format/issues/609","id":60218560,"number":609,"title":"to_hdf5 cannot handle None's in metadata","user":{"login":"wasade","id":474290,"avatar_url":"https://avatars.githubusercontent.com/u/474290?v=3","gravatar_id":"","url":"https://api.github.com/users/wasade","html_url":"https://github.com/wasade","followers_url":"https://api.github.com/users/wasade/followers","following_url":"https://api.github.com/users/wasade/following{/other_user}","gists_url":"https://api.github.com/users/wasade/gists{/gist_id}","starred_url":"https://api.github.com/users/wasade/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wasade/subscriptions","organizations_url":"https://api.github.com/users/wasade/orgs","repos_url":"https://api.github.com/users/wasade/repos","events_url":"https://api.github.com/users/wasade/events{/privacy}","received_events_url":"https://api.github.com/users/wasade/received_events","type":"User","site_admin":false},"labels":[{"id":3027790,"url":"https://api.github.com/repos/biocore/biom-format/labels/bug","name":"bug","color":"fc2929","default":true}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":5,"created_at":"2015-03-07T18:37:03Z","updated_at":"2016-11-05T20:56:05Z","closed_at":null,"body":"This table:\n\n``` python\n> t.metadata()\nOut[5]:\n(defaultdict(<function <lambda> at 0x10d595848>, {u'pH': 7.0}),\n defaultdict(<function <lambda> at 0x10d5958c0>, {u'pH': 8.0}),\n defaultdict(<function <lambda> at 0x10d595938>, {u'pH': 7.0}),\n defaultdict(<function <lambda> at 0x10d5959b0>, {}))\n```\n\nWill cause `to_hdf5` to except. It is valid for `to_json`. \n"},"comment":{"url":"https://api.github.com/repos/biocore/biom-format/issues/comments/258640091","html_url":"https://github.com/biocore/biom-format/issues/609#issuecomment-258640091","issue_url":"https://api.github.com/repos/biocore/biom-format/issues/609","id":258640091,"user":{"login":"wasade","id":474290,"avatar_url":"https://avatars.githubusercontent.com/u/474290?v=3","gravatar_id":"","url":"https://api.github.com/users/wasade","html_url":"https://github.com/wasade","followers_url":"https://api.github.com/users/wasade/followers","following_url":"https://api.github.com/users/wasade/following{/other_user}","gists_url":"https://api.github.com/users/wasade/gists{/gist_id}","starred_url":"https://api.github.com/users/wasade/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wasade/subscriptions","organizations_url":"https://api.github.com/users/wasade/orgs","repos_url":"https://api.github.com/users/wasade/repos","events_url":"https://api.github.com/users/wasade/events{/privacy}","received_events_url":"https://api.github.com/users/wasade/received_events","type":"User","site_admin":false},"created_at":"2016-11-05T20:56:05Z","updated_at":"2016-11-05T20:56:05Z","body":"We need better enforcement surrounding metadata... a reserved word for indicating a null entry for HDF5, but it would need to be defined in the spec itself, which would trigger a change to format version 2.1.1, which is not ideal. The masked arrays would really need to trigger a 2.2.0 format as that would be defining a separate dataset. \r\n\r\nAll paths are not fun -- I think the best direction is to, at write, detect nulls like this such that in the original example, the data are implicitly transformed to:\r\n\r\n```python\r\n> t.metadata()\r\nOut[5]:\r\n(defaultdict(<function <lambda> at 0x10d595848>, {u'pH': 7.0}),\r\n defaultdict(<function <lambda> at 0x10d5958c0>, {u'pH': 8.0}),\r\n defaultdict(<function <lambda> at 0x10d595938>, {u'pH': 7.0}),\r\n defaultdict(<function <lambda> at 0x10d5959b0>, {u'pH': None}))\r\n```\r\n\r\n...which I believe would fly for the format and spec. "}}
{"actor":{"display_login":"wasade"}}