Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

validateEveryToJSON ignores new response handlers #68

Open
mossprescott opened this issue Jul 12, 2017 · 3 comments
Open

validateEveryToJSON ignores new response handlers #68

mossprescott opened this issue Jul 12, 2017 · 3 comments

Comments

@mossprescott
Copy link

We’ve implemented a new handler (for streaming responses) by providing instances of HasServer, HasClient, Accept, and HasSwagger. This works reasonably well, but now we've run into an issue where the type-level machinery used by validateEveryToJSON (i.e. BodyTypes) can’t be extended in a similar way, and in fact it silently ignores endpoints that use the new type. I don’t know if this approach can be made to handle this, but it would be an improvement if it at least gave an error saying that it can’t discover all the types.

The problem is the “default” case on this line:

@phadej
Copy link
Contributor

phadej commented Jul 12, 2017

@fizruk should we make it extendable similarly as IsElem for safeLink is?

@fizruk
Copy link
Member

fizruk commented Oct 17, 2017

@phadej definitely!

@akhesaCaro
Copy link
Contributor

Hi,
Servant-swagger will be moved into the main Servant repo (see : haskell-servant/servant#1475)
If this issue is still relevant, would it be possible for you to summit it there? : https://github.com/haskell-servant/servant/issues

Thanks in advance!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants