on master help sign in
add some quick comments to out_of_the_tarpit test
ca3680cAgentM
examples/out_of_the_tarpit.hs+3
@@ -8,6 +8,7 @@ import GHC.Generics
8import Data.Binary
8import Data.Binary
9import Control.DeepSeq
9import Control.DeepSeq
10
10
11+--create various database value (atom) types
11addressAtomType :: AtomType
12addressAtomType :: AtomType
12addressAtomType = TextAtomType
13addressAtomType = TextAtomType
13
14
@@ -46,6 +47,7 @@ speedBandAtomType = ConstructedAtomType "SpeedBand" M.empty
46
47
47main :: IO ()
48main :: IO ()
48main = do
49main = do
50+ --connect to the database
49 let connInfo = InProcessConnectionInfo NoPersistence emptyNotificationCallback []
51 let connInfo = InProcessConnectionInfo NoPersistence emptyNotificationCallback []
50 check x = case x of
52 check x = case x of
51 Left err -> error (show err)
53 Left err -> error (show err)
@@ -53,6 +55,7 @@ main = do
53 eConn <- connectProjectM36 connInfo
55 eConn <- connectProjectM36 connInfo
54 let conn = check eConn
56 let conn = check eConn
55
57
58+ --create a database session at the default branch of the fresh database
56 eSessionId <- createSessionAtHead "master" conn
59 eSessionId <- createSessionAtHead "master" conn
57 let sessionId = check eSessionId
60 let sessionId = check eSessionId
58
61