{"action":"created","issue":{"url":"https://api.github.com/repos/silkapp/rest/issues/113","labels_url":"https://api.github.com/repos/silkapp/rest/issues/113/labels{/name}","comments_url":"https://api.github.com/repos/silkapp/rest/issues/113/comments","events_url":"https://api.github.com/repos/silkapp/rest/issues/113/events","html_url":"https://github.com/silkapp/rest/issues/113","id":60818505,"number":113,"title":"Remove `Step` after top level singleton","user":{"login":"hesselink","id":75477,"avatar_url":"https://avatars.githubusercontent.com/u/75477?v=3","gravatar_id":"","url":"https://api.github.com/users/hesselink","html_url":"https://github.com/hesselink","followers_url":"https://api.github.com/users/hesselink/followers","following_url":"https://api.github.com/users/hesselink/following{/other_user}","gists_url":"https://api.github.com/users/hesselink/gists{/gist_id}","starred_url":"https://api.github.com/users/hesselink/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hesselink/subscriptions","organizations_url":"https://api.github.com/users/hesselink/orgs","repos_url":"https://api.github.com/users/hesselink/repos","events_url":"https://api.github.com/users/hesselink/events{/privacy}","received_events_url":"https://api.github.com/users/hesselink/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-03-12T13:30:05Z","updated_at":"2015-03-12T14:00:33Z","closed_at":null,"body":"Right now, the `Schema` constructor takes a top level construct (`Maybe (Cardinality sid mid)`), and a `Step`. However, when the top level thing is `Single`, it doesn't make sense to have the subsequent `Step`: nesting listings and getters on top of a singleton getter is weird, and for statics you can get the same effect with actions. The statics also don't work.\r\n\r\nRather than trying to make the statics work, I propose to remove the `Step` if the top level thing is a `Single`. This is a breaking change to `Schema` (which people probably don't use) and `singleton`. It would also probably be a bit of work in the router and perhaps rest-gen. @bergmark What do you think?"},"comment":{"url":"https://api.github.com/repos/silkapp/rest/issues/comments/78484310","html_url":"https://github.com/silkapp/rest/issues/113#issuecomment-78484310","issue_url":"https://api.github.com/repos/silkapp/rest/issues/113","id":78484310,"user":{"login":"bergmark","id":100681,"avatar_url":"https://avatars.githubusercontent.com/u/100681?v=3","gravatar_id":"","url":"https://api.github.com/users/bergmark","html_url":"https://github.com/bergmark","followers_url":"https://api.github.com/users/bergmark/followers","following_url":"https://api.github.com/users/bergmark/following{/other_user}","gists_url":"https://api.github.com/users/bergmark/gists{/gist_id}","starred_url":"https://api.github.com/users/bergmark/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bergmark/subscriptions","organizations_url":"https://api.github.com/users/bergmark/orgs","repos_url":"https://api.github.com/users/bergmark/repos","events_url":"https://api.github.com/users/bergmark/events{/privacy}","received_events_url":"https://api.github.com/users/bergmark/received_events","type":"User","site_admin":false},"created_at":"2015-03-12T14:00:33Z","updated_at":"2015-03-12T14:00:33Z","body":"I don't really know how `Schema` \"works\" so I can't really comment on that but the rationale is good.\r\n\r\nFrom an API perspective:\r\n\r\n* What is the current behavior, will end points silently be ignored?\r\n* What will the behavior be after this change? Type error?\r\n* Should we add a smart constructor for singletons?\r\n"}}