-
Notifications
You must be signed in to change notification settings - Fork 374
1.2 upgrade
Arash Rouhani edited this page Sep 8, 2013
·
10 revisions
The Detailed change list and the Changelog have an overview of the changes. The release announcement explains some of the changes.
https://plus.google.com/118323070335349339293/posts/JxZ2jpW8CfX
- change the cabal file to
yesod >= 1.2
and bump any persistent dependencies to>= 1.2
- run
cabal update
&& cabal install --force-reinstalls - most changes are visible in the commit that updates the scaffolding code for Yesod 1.2
- change
sqlSettings
tosqlOnlySettings
(details here)
- change persistent imports:
-import qualified Database.Persist.Store
+import qualified Database.Persist
-import Database.Persist.GenericSql
+import Database.Persist.Sql
- change the
persist
quasi-quoter topersistUpperCase
. - add
deriving Typeable
to any entities that trigger a compile-time error referring to generics. See this patch
- Couldn't match expected type
RepJson' with actual type
Value'
-getJsonR :: Handler RepJson
-getJsonR = jsonToRepJson $ object ["message" .= ("Hello, World!" :: Text)]
+getJsonR :: Handler Value
+getJsonR = return $ object ["message" .= ("Hello, World!" :: Text)]
- For multiple representation types, use selectRep/provideRep and Handler TypedContent