{"action":"closed","issue":{"url":"https://api.github.com/repos/Pylons/colander/issues/150","labels_url":"https://api.github.com/repos/Pylons/colander/issues/150/labels{/name}","comments_url":"https://api.github.com/repos/Pylons/colander/issues/150/comments","events_url":"https://api.github.com/repos/Pylons/colander/issues/150/events","html_url":"https://github.com/Pylons/colander/issues/150","id":22355971,"number":150,"title":"SchemaNode subclasses don't properly add children","user":{"login":"mmerickel","id":487237,"avatar_url":"https://avatars.githubusercontent.com/u/487237?v=3","gravatar_id":"","url":"https://api.github.com/users/mmerickel","html_url":"https://github.com/mmerickel","followers_url":"https://api.github.com/users/mmerickel/followers","following_url":"https://api.github.com/users/mmerickel/following{/other_user}","gists_url":"https://api.github.com/users/mmerickel/gists{/gist_id}","starred_url":"https://api.github.com/users/mmerickel/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mmerickel/subscriptions","organizations_url":"https://api.github.com/users/mmerickel/orgs","repos_url":"https://api.github.com/users/mmerickel/repos","events_url":"https://api.github.com/users/mmerickel/events{/privacy}","received_events_url":"https://api.github.com/users/mmerickel/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2013-11-08T18:53:12Z","updated_at":"2016-01-16T21:39:19Z","closed_at":"2016-01-16T21:39:19Z","body":"Prior to 1.0, it was possible to create children of a `MappingSchema` via \r\n\r\n```python\r\ncolander.MappingSchema(colander.SchemaNode(colander.Integer(), name='foo')).\r\n```\r\n\r\nHowever, this is broken, as the `schema_type` property is ignored, so `MappingSchema` still expects the first argument to be a type. The following is the fallback I'm having to use right now.\r\n\r\n```python\r\ncolander.SchemaNode(colander.Mapping(), colander.SchemaNode(colander.Integer(), name='foo'))\r\n```\r\n\r\nThis looks to be due to some decisions made in the `SchemaNode.__init__` which aren't really lining up with what I'd expect.\r\n\r\nhttps://github.com/Pylons/colander/blob/master/colander/__init__.py#L1809\r\n\r\nIn my mind, the `MappingSchema` subclass should override the `__init__` and call super with the appropriate type to keep the hierarchy working as expected."}}