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

Bytestring type errors #78

Closed
wants to merge 3 commits into from
Closed

Bytestring type errors #78

wants to merge 3 commits into from

Conversation

fizruk
Copy link
Member

@fizruk fizruk commented Sep 4, 2016

Closes #77.

Here are the errors:

>>> toSchema (Proxy :: Proxy Lazy.ByteString)

<interactive>:5:1: error:
    • Impossible to have an instance ToSchema Lazy.ByteString.
      Please, use a newtype wrapper around Lazy.ByteString instead.
      Consider using byteSchema or binarySchema templates.
    • In the expression: toSchema (Proxy :: Proxy Lazy.ByteString)
      In an equation for ‘it’:
          it = toSchema (Proxy :: Proxy Lazy.ByteString)
>>> toParamSchema (Proxy :: Proxy BS.ByteString)

<interactive>:8:1: error:
    • Impossible to have an instance ToParamSchema BS.ByteString.
      Please, use a newtype wrapper around BS.ByteString instead.
      Consider using byteParamSchema or binaryParamSchema templates.
    • In the expression: toParamSchema (Proxy :: Proxy BS.ByteString)
      In an equation for ‘it’:
          it = toParamSchema (Proxy :: Proxy BS.ByteString)

@fizruk
Copy link
Member Author

fizruk commented Sep 26, 2016

@phadej can you review this?

@@ -35,6 +38,13 @@ import Data.Swagger.Internal
import Data.Swagger.Lens
import Data.Swagger.SchemaOptions

#if __GLASGOW_HASKELL__ < 800
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

wouldn't

#if __GLASGOW_HASKELL__ >= 800

be clearer, or is there a good reason to use < ?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well, no good reason. But I'll leave it for now.

Copy link
Collaborator

@phadej phadej left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@phadej
Copy link
Collaborator

phadej commented Sep 30, 2016

I can rebase and make a new release during the weekend. Would it be ok for you, @fizruk ?

@fizruk
Copy link
Member Author

fizruk commented Sep 30, 2016

@phadej yes, that would be great!

@phadej
Copy link
Collaborator

phadej commented Oct 2, 2016

Done in #84

@phadej phadej closed this Oct 2, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants