Commit graph

1410 commits

Author SHA1 Message Date
Julian K. Arni
e0ba34372e Remove link to 0.4 version of tutorial.
Stackage has 0.5 already, and the 0.4 version has numerous mistakes.
2016-05-10 13:39:01 +02:00
Julian K. Arni
d4c5edea25 Change throwErr to throwError. 2016-05-10 13:30:57 +02:00
Julian K. Arni
efbe6fd498 Use NoContent and fix content-type lists in docs. 2016-05-10 13:21:34 +02:00
Julian Arni
6702d7ed6d Merge pull request #497 from jekor/master
support safeLink for RemoteHost
2016-05-10 12:55:59 +02:00
Julian K. Arni
f2c925f39a Link to vault package. 2016-05-10 12:48:28 +02:00
Julian Arni
3ae3e43ff7 Merge pull request #502 from haskell-servant/jkarni/bound-mock
Make servant-mock bounds match the other packages.
2016-05-10 12:37:29 +02:00
Julian K. Arni
753ad402e1 Make servant-mock bounds match the other packages.
This is causing build failures for some.
2016-05-09 19:28:44 +02:00
Chris Forno
70d2ccaae3 support safeLink for RemoteHost 2016-05-04 21:03:31 +08:00
Arian van Putten
fd26721feb Merge pull request #479 from rubenmoor/patch-1
Update examples.md: diener-monad
2016-04-29 11:24:01 +02:00
Amar
845a06ccbd Correct the description of arbitrary monad server spec 2016-04-28 22:27:50 +08:00
Amar
61a99c9567 Replace Servant.Server.Internal.Enter with Servant.Utils.Enter in a comment 2016-04-28 22:26:27 +08:00
Amar
3f4bcf7752 Remove mmorph dependency from servant-server 2016-04-28 22:13:09 +08:00
Amar
4045d20c8d Fix unused warning 2016-04-28 22:13:09 +08:00
Amar
a948639673 Move enter to servant package 2016-04-28 22:13:04 +08:00
Arian van Putten
4f4ca69672 Merge pull request #476 from trofi/master
Fix doctests failure when testpack or checkers are installed
2016-04-22 17:18:20 +02:00
Sönke Hahn
e0216781b0 set the homepage to readthedocs 2016-04-22 14:12:21 +08:00
Sönke Hahn
29be5761ce servant-client: add Eq instance for ServantError 2016-04-21 15:27:08 +08:00
Julian Arni
438912f6c5 Merge pull request #397 from jsermeno/master
Allow duplicate headers
2016-04-21 09:07:53 +02:00
Sönke Hahn
b26bbfccda travis: enable -Wall -Werror 2016-04-21 13:06:10 +08:00
Justin Sermeno
e1463cd02d remove response header contains check 2016-04-20 18:37:49 -05:00
Ruben Moor
07f10aaf5e typos 2016-04-20 16:07:02 +02:00
Ruben Moor
292d49408a fixed formatting 2016-04-20 16:04:51 +02:00
Ruben Moor
69239393ad Update examples.md 2016-04-20 15:53:55 +02:00
Julian Arni
555038cbf4 Merge pull request #471 from haskell-servant/doc-examples
doc: add a section about example projects
2016-04-20 15:46:59 +02:00
Sergei Trofimovich
c064f94fd6 Fix doctests failure when testpack or checkers are installed
Test fails as:
  Test suite doctests: RUNNING...

  test/Servant/API/ContentTypesSpec.hs:31:18:
    Ambiguous module name `Test.QuickCheck.Instances':
      it was found in multiple packages:
      checkers-0.4.4@check_A5bAKHstANbBRqwFoOaIKx testpack-2.1.3.0@testp_BjTqfpWNTOG5Lwlc3iqqG9 quickcheck-instances-0.3.12@quick_3Tkh09kYN8p78zxMKFPcZI
  Test suite doctests: FAIL

Fixed by importing 'Test.QuickCheck.Instances' from "quickcheck-instances".

Signed-off-by: Sergei Trofimovich <siarheit@google.com>
2016-04-16 16:13:58 +01:00
Andres Löh
abce1190ce Merge pull request #475 from wiz/changelogs
Add missing changelogs and readme
2016-04-16 16:43:14 +02:00
Alexander Bondarenko
b13ecd6098
Add missing changelogs and readme to cabal in servant, servant-client. 2016-04-16 16:51:38 +03:00
Sönke Hahn
65bdaa6d10 tweaked release script 2016-04-15 19:23:23 +08:00
Sönke Hahn
718ca10589 update changelogs for release 2016-04-15 18:35:17 +08:00
Sönke Hahn
ab6131d733 version bump 2016-04-15 18:35:17 +08:00
Andres Löh
d876031e7b Merge pull request #461 from kosmikus/accept-check
Do the accept check before the body check.
2016-04-15 11:20:13 +02:00
Sönke Hahn
ef1561167d doc: add a section about example projects 2016-04-15 17:18:12 +08:00
Andres Loeh
a551eb62e2 Do the accept check before the body check.
This is a reasonably simple attempt at fixing #460.
By moving the accept check to a place before the body check,
we can make it recoverable (the body check is irreversible,
so everything done after the body check has to fail fatally).

The advantage is that we can now specify routes offering
different content types modularly. Failure to match one
is not fatal, and will result in subsequent routes being
tried.

The disadvantage is that we hereby bump the error priority
of the 406 status code. If a request contains a bad accept
header and a bad body, we now get 406 rather than 400. This
deviates from the HTTP decision diagram we try to follow,
but seems like an acceptable compromise for now.
2016-04-15 10:54:22 +02:00
Sönke Hahn
caf02096a0 Merge pull request #466 from rvion/fix-some-warnings
Fix some warnings
2016-04-14 18:36:41 +08:00
Rémi Vion
c3bb14fb26 remove redundant import to remove warnings 2016-04-13 15:41:51 +02:00
Rémi Vion
96abac7ef2 remove duplicated HeaderArg export
it is also 2 lines below
2016-04-13 15:41:28 +02:00
Andres Löh
1807c72c8a Merge pull request #388 from bgamari/master
Compatibility with GHC 8.0
2016-04-13 15:09:16 +02:00
Andres Löh
15143cc900 Merge pull request #457 from kosmikus/fix-router-sharing
Fix router sharing
2016-04-12 10:04:05 +02:00
Andres Loeh
b1a6d88845 Revise the Router type to allow proper sharing.
We've previously used functions in the Router type to provide
information for subrouters. But this accesses the Requests too
early, and breaks sharing of the router structure in general,
causing the Router or large parts of the Router to be recomputed
on every request.

We now do not use functions anymore, and properly compute all
static parts of the router first, and gain access to the request
only in Delayed.

This also turns the code used within Delayed into a proper monad
now called DelayedIO, making some of the code using it a bit
nicer.
2016-04-12 09:38:49 +02:00
Sönke Hahn
d4c6f67cf0 servant-server: update changelog 2016-04-12 13:58:00 +08:00
Luke Cycon
21546991af Introduce a Handler alias for ExceptT ServantErr IO
Fixes #434
2016-04-11 22:27:29 -07:00
Sönke Hahn
b8422e80b2 Merge #456 2016-04-12 13:00:39 +08:00
Luke Cycon
b84016e191 Sort out this changelog situation 2016-04-11 21:54:04 -07:00
Luke Cycon
353c1798e1 Update some docs and the changelogs 2016-04-11 11:19:18 -07:00
Sönke Hahn
fffa72b62b Merge pull request #459 from joncfoo/patch-1
Fix code example in haddock  of servant-mock
2016-04-11 23:01:06 +08:00
Jonathan
aa71099ffd Update Mock.hs 2016-04-11 08:54:38 -05:00
Andres Löh
6ec4bdcc73 Merge pull request #451 from kosmikus/show-router
Improvements of router merging, visualization and testing
2016-04-11 08:43:10 +02:00
Andres Loeh
8c778825c7 Improvements and visualization of router structure.
* Improves how Routers are built, in particular via
the `choice` smart constructors. Static lookups are
now used more often.

* We now have test cases making sure that certain
routers have the same structure.

* The router structure can now be visualized for debugging
purposes as a tree. The new functions `layout` and
`layoutWithContext` do this.
2016-04-11 08:08:37 +02:00
Andrew Gibiansky
ba57d20008 Add ReflectMethod instances for OPTIONS, TRACE, and CONNECT 2016-04-11 11:50:15 +08:00
Jonathan
23fb5e1f56 Fix code example in haddock of servant-mock
The example in the haddock does not coincide with the example code in servant-mock/example/main.hs
2016-04-10 11:03:48 -05:00