Index: branches/HeuristicLab.TimeSeries/HeuristicLab.PluginInfrastructure/3.3/LightweightApplicationManager.cs
===================================================================
--- branches/HeuristicLab.TimeSeries/HeuristicLab.PluginInfrastructure/3.3/LightweightApplicationManager.cs	(revision 7460)
+++ branches/HeuristicLab.TimeSeries/HeuristicLab.PluginInfrastructure/3.3/LightweightApplicationManager.cs	(revision 7615)
@@ -75,6 +75,5 @@
       foreach (Type t in GetTypes(type)) {
         object instance = null;
-        try { instance = Activator.CreateInstance(t); }
-        catch { }
+        try { instance = Activator.CreateInstance(t); } catch { }
         if (instance != null) instances.Add(instance);
       }
@@ -126,8 +125,9 @@
         var assemblyTypes = assembly.GetTypes();
 
-        var buildTypes = from t in assemblyTypes
+        var buildTypes = from t in assembly.GetTypes()
+                         where CheckTypeCompatibility(type, t)
                          where !IsNonDiscoverableType(t)
-                         where CheckTypeCompatibility(type, t)
-                         where onlyInstantiable == false || (!t.IsAbstract && !t.IsInterface && !t.HasElementType)
+                         where onlyInstantiable == false ||
+                               (!t.IsAbstract && !t.IsInterface && !t.HasElementType)
                          select BuildType(t, type);
 
@@ -135,9 +135,7 @@
                where includeGenericTypeDefinitions || !t.IsGenericTypeDefinition
                select t;
-      }
-      catch (TypeLoadException) {
+      } catch (TypeLoadException) {
         return Enumerable.Empty<Type>();
-      }
-      catch (ReflectionTypeLoadException) {
+      } catch (ReflectionTypeLoadException) {
         return Enumerable.Empty<Type>();
       }
@@ -152,9 +150,26 @@
         return true;
       if (type.IsGenericType && other.IsGenericType) {
+        var otherGenericArguments = other.GetGenericArguments();
+        var typeGenericArguments = type.GetGenericArguments();
+
+        //check type arguments count
+        if (otherGenericArguments.Length != typeGenericArguments.Length)
+          return false;
+
+        //check type arguments & constraints
+        int i = 0;
+        foreach (var genericArgument in typeGenericArguments) {
+          if (otherGenericArguments[i].IsGenericParameter) {
+            foreach (var constraint in otherGenericArguments[i].GetGenericParameterConstraints())
+              if (!constraint.IsAssignableFrom(genericArgument)) return false;
+          } else if (genericArgument != otherGenericArguments[i]) return false;
+          i++;
+        }
+        //check types
         try {
-          if (type.IsAssignableFrom(other.GetGenericTypeDefinition().MakeGenericType(type.GetGenericArguments())))
+          var otherGenericTypeDefinition = other.GetGenericTypeDefinition();
+          if (type.IsAssignableFrom(otherGenericTypeDefinition.MakeGenericType(typeGenericArguments)))
             return true;
-        }
-        catch (Exception) { }
+        } catch (Exception) { }
       }
       return false;
Index: branches/HeuristicLab.TimeSeries/HeuristicLab.PluginInfrastructure/3.3/SandboxApplicationManager.cs
===================================================================
--- branches/HeuristicLab.TimeSeries/HeuristicLab.PluginInfrastructure/3.3/SandboxApplicationManager.cs	(revision 7460)
+++ branches/HeuristicLab.TimeSeries/HeuristicLab.PluginInfrastructure/3.3/SandboxApplicationManager.cs	(revision 7615)
@@ -235,5 +235,5 @@
       PluginDescription pluginDesc = (PluginDescription)pluginDescription;
       return from asm in AppDomain.CurrentDomain.GetAssemblies()
-             where !IsDynamicAssembly(asm)
+             where !asm.IsDynamic && !string.IsNullOrEmpty(asm.Location)
              where pluginDesc.AssemblyLocations.Any(location => location.Equals(Path.GetFullPath(asm.Location), StringComparison.CurrentCultureIgnoreCase))
              from t in GetTypes(type, asm, onlyInstantiable, includeGenericTypeDefinitions)
@@ -249,8 +249,4 @@
       }
       return result;
-    }
-
-    private static bool IsDynamicAssembly(Assembly asm) {
-      return (asm is System.Reflection.Emit.AssemblyBuilder) || string.IsNullOrEmpty(asm.Location);
     }
 
@@ -266,6 +262,6 @@
     private static IEnumerable<Type> GetTypes(Type type, Assembly assembly, bool onlyInstantiable, bool includeGenericTypeDefinitions) {
       var buildTypes = from t in assembly.GetTypes()
+                       where CheckTypeCompatibility(type, t)
                        where !IsNonDiscoverableType(t)
-                       where CheckTypeCompatibility(type, t)
                        where onlyInstantiable == false ||
                              (!t.IsAbstract && !t.IsInterface && !t.HasElementType)
@@ -286,6 +282,24 @@
         return true;
       if (type.IsGenericType && other.IsGenericType) {
+        var otherGenericArguments = other.GetGenericArguments();
+        var typeGenericArguments = type.GetGenericArguments();
+
+        //check type arguments count
+        if (otherGenericArguments.Length != typeGenericArguments.Length)
+          return false;
+
+        //check type arguments & constraints
+        int i = 0;
+        foreach (var genericArgument in typeGenericArguments) {
+          if (otherGenericArguments[i].IsGenericParameter) {
+            foreach (var constraint in otherGenericArguments[i].GetGenericParameterConstraints())
+              if (!constraint.IsAssignableFrom(genericArgument)) return false;
+          } else if (genericArgument != otherGenericArguments[i]) return false;
+          i++;
+        }
+        //check types
         try {
-          if (type.IsAssignableFrom(other.GetGenericTypeDefinition().MakeGenericType(type.GetGenericArguments())))
+          var otherGenericTypeDefinition = other.GetGenericTypeDefinition();
+          if (type.IsAssignableFrom(otherGenericTypeDefinition.MakeGenericType(typeGenericArguments)))
             return true;
         }
