diff --git a/Simulation/Aivika/Distributed/Optimistic/DIO.hs b/Simulation/Aivika/Distributed/Optimistic/DIO.hs
--- a/Simulation/Aivika/Distributed/Optimistic/DIO.hs
+++ b/Simulation/Aivika/Distributed/Optimistic/DIO.hs
@@ -1,5 +1,5 @@
 
-{-# LANGUAGE MultiParamTypeClasses, FlexibleInstances #-}
+{-# LANGUAGE MultiParamTypeClasses, FlexibleInstances, OverlappingInstances #-}
 
 -- |
 -- Module     : Simulation.Aivika.Distributed.Optimistic.DIO
diff --git a/Simulation/Aivika/Distributed/Optimistic/Internal/DIO.hs b/Simulation/Aivika/Distributed/Optimistic/Internal/DIO.hs
--- a/Simulation/Aivika/Distributed/Optimistic/Internal/DIO.hs
+++ b/Simulation/Aivika/Distributed/Optimistic/Internal/DIO.hs
@@ -1,5 +1,5 @@
 
-{-# LANGUAGE DeriveGeneric #-}
+{-# LANGUAGE DeriveGeneric, DeriveDataTypeable #-}
 
 -- |
 -- Module     : Simulation.Aivika.Distributed.Optimistic.Internal.DIO
diff --git a/Simulation/Aivika/Distributed/Optimistic/Internal/Event.hs b/Simulation/Aivika/Distributed/Optimistic/Internal/Event.hs
--- a/Simulation/Aivika/Distributed/Optimistic/Internal/Event.hs
+++ b/Simulation/Aivika/Distributed/Optimistic/Internal/Event.hs
@@ -1,5 +1,5 @@
 
-{-# LANGUAGE TypeFamilies, FlexibleInstances #-}
+{-# LANGUAGE TypeFamilies, FlexibleInstances, OverlappingInstances #-}
 
 -- |
 -- Module     : Simulation.Aivika.Distributed.Optimistic.Internal.Event
@@ -18,7 +18,6 @@
 
 import Data.Maybe
 import Data.IORef
-import Data.Typeable
 import Data.Time.Clock
 
 import System.Timeout
diff --git a/Simulation/Aivika/Distributed/Optimistic/Internal/Message.hs b/Simulation/Aivika/Distributed/Optimistic/Internal/Message.hs
--- a/Simulation/Aivika/Distributed/Optimistic/Internal/Message.hs
+++ b/Simulation/Aivika/Distributed/Optimistic/Internal/Message.hs
@@ -1,5 +1,5 @@
 
-{-# LANGUAGE RankNTypes, DeriveGeneric #-}
+{-# LANGUAGE RankNTypes, DeriveGeneric, DeriveDataTypeable #-}
 
 -- |
 -- Module     : Simulation.Aivika.Distributed.Optimistic.Internal.Message
diff --git a/Simulation/Aivika/Distributed/Optimistic/Internal/Priority.hs b/Simulation/Aivika/Distributed/Optimistic/Internal/Priority.hs
--- a/Simulation/Aivika/Distributed/Optimistic/Internal/Priority.hs
+++ b/Simulation/Aivika/Distributed/Optimistic/Internal/Priority.hs
@@ -1,5 +1,5 @@
 
-{-# LANGUAGE DeriveGeneric #-}
+{-# LANGUAGE DeriveGeneric, DeriveDataTypeable #-}
 
 -- |
 -- Module     : Simulation.Aivika.Distributed.Optimistic.Internal.Priority
diff --git a/Simulation/Aivika/Distributed/Optimistic/Internal/TimeServer.hs b/Simulation/Aivika/Distributed/Optimistic/Internal/TimeServer.hs
--- a/Simulation/Aivika/Distributed/Optimistic/Internal/TimeServer.hs
+++ b/Simulation/Aivika/Distributed/Optimistic/Internal/TimeServer.hs
@@ -1,5 +1,5 @@
 
-{-# LANGUAGE DeriveGeneric #-}
+{-# LANGUAGE DeriveGeneric, DeriveDataTypeable #-}
 
 -- |
 -- Module     : Simulation.Aivika.Distributed.Optimistic.Internal.TimeServer
diff --git a/aivika-distributed.cabal b/aivika-distributed.cabal
--- a/aivika-distributed.cabal
+++ b/aivika-distributed.cabal
@@ -1,5 +1,5 @@
 name:            aivika-distributed
-version:         0.3
+version:         0.3.1
 synopsis:        Parallel distributed discrete event simulation module for the Aivika library
 description:
     This package extends the aivika-transformers [1] package with facilities for running parallel distributed simulations.
@@ -71,7 +71,9 @@
                      FlexibleContexts,
                      TypeFamilies,
                      RankNTypes,
-                     DeriveGeneric
+                     DeriveGeneric,
+                     DeriveDataTypeable,
+                     OverlappingInstances
 
     ghc-options:     -O2
 
diff --git a/tests/MachRep1.hs b/tests/MachRep1.hs
--- a/tests/MachRep1.hs
+++ b/tests/MachRep1.hs
@@ -1,6 +1,7 @@
 
 {--# LANGUAGE TemplateHaskell #--}
 {-# LANGUAGE DeriveGeneric #-}
+{-# LANGUAGE DeriveDataTypeable #-}
 
 -- It corresponds to model MachRep1 described in document 
 -- Introduction to Discrete-Event Simulation and the SimPy Language
diff --git a/tests/MachRep2.hs b/tests/MachRep2.hs
--- a/tests/MachRep2.hs
+++ b/tests/MachRep2.hs
@@ -1,6 +1,7 @@
 
 {--# LANGUAGE TemplateHaskell #--}
 {-# LANGUAGE DeriveGeneric #-}
+{-# LANGUAGE DeriveDataTypeable #-}
 
 -- It corresponds to model MachRep2 described in document 
 -- Introduction to Discrete-Event Simulation and the SimPy Language
diff --git a/tests/MachRep2Distributed.hs b/tests/MachRep2Distributed.hs
--- a/tests/MachRep2Distributed.hs
+++ b/tests/MachRep2Distributed.hs
@@ -1,6 +1,7 @@
 
 {-# LANGUAGE TemplateHaskell #-}
 {-# LANGUAGE DeriveGeneric #-}
+{-# LANGUAGE DeriveDataTypeable #-}
 
 -- It corresponds to model MachRep2 described in document 
 -- Introduction to Discrete-Event Simulation and the SimPy Language
diff --git a/tests/MachRep2Reproducible.hs b/tests/MachRep2Reproducible.hs
--- a/tests/MachRep2Reproducible.hs
+++ b/tests/MachRep2Reproducible.hs
@@ -1,6 +1,7 @@
 
 {--# LANGUAGE TemplateHaskell #--}
 {-# LANGUAGE DeriveGeneric #-}
+{-# LANGUAGE DeriveDataTypeable #-}
 
 -- It corresponds to model MachRep2 described in document 
 -- Introduction to Discrete-Event Simulation and the SimPy Language
diff --git a/tests/MachRep2Sync.hs b/tests/MachRep2Sync.hs
--- a/tests/MachRep2Sync.hs
+++ b/tests/MachRep2Sync.hs
@@ -1,6 +1,7 @@
 
 {--# LANGUAGE TemplateHaskell #--}
 {-# LANGUAGE DeriveGeneric #-}
+{-# LANGUAGE DeriveDataTypeable #-}
 
 -- It corresponds to model MachRep2 described in document 
 -- Introduction to Discrete-Event Simulation and the SimPy Language
diff --git a/tests/MachRep2SyncIO.hs b/tests/MachRep2SyncIO.hs
--- a/tests/MachRep2SyncIO.hs
+++ b/tests/MachRep2SyncIO.hs
@@ -1,6 +1,7 @@
 
 {--# LANGUAGE TemplateHaskell #--}
 {-# LANGUAGE DeriveGeneric #-}
+{-# LANGUAGE DeriveDataTypeable #-}
 
 -- It corresponds to model MachRep2 described in document 
 -- Introduction to Discrete-Event Simulation and the SimPy Language
