Open alexbeletsky opened 13 years ago
You will need to change your CodeContract options in the Visual Studio project properties page. Unfortunately I can't say what to as I am afk but from memory it's the only drop down on the properties sheet.
I have removed "Perform Static Contract Checking" and it went fine!
Thanks a lot :)
Finished up with errors. Seems like Code Contacts issues (could not diagnose deeply since lack CC expertise)
NcqrsFramework.sln
------ Build started: Project: Ncqrs, Configuration: Debug Any CPU ------ EXEC : error CC1019: Type 'Ncqrs.Eventing.IEvent' specifies the class 'Ncqrs.Eventing.IEventContracts' as its contract class, but that class does not point back to this type. EXEC : error CC1019: Type 'Ncqrs.Eventing.Sourcing.ISourcedEventHandler' specifies the class 'Ncqrs.Eventing.Sourcing.IEventSourcedHandlerContracts' as its contract class, but that class does not point back to this type. d:\Development\Projects\ncqrs\Framework\src\Ncqrs\Eventing\Sourcing\TypeThresholdedActionBasedSourcedEventHandler.cs(71,13): warning CC1033: Method 'Ncqrs.Eventing.Sourcing.TypeThresholdedActionBasedDomainEventHandler.HandleEvent(Ncqrs.Eventing.Sourcing.ISourcedEvent)' implements interface method 'Ncqrs.Eventing.Sourcing.ISourcedEventHandler.HandleEvent(Ncqrs.Eventing.Sourcing.ISourcedEvent)', thus cannot add Requires. EXEC : error CC1019: Type 'Ncqrs.Eventing.Storage.IEventStore' specifies the class 'Ncqrs.Eventing.Storage.IEventStoreContracts' as its contract class, but that class does not point back to this type. EXEC : error CC1019: Type 'Ncqrs.Eventing.Storage.ISnapshotStore' specifies the class 'Ncqrs.Eventing.Storage.ISnapshotStoreContracts' as its contract class, but that class does not point back to this type. EXEC : error CC1019: Type 'Ncqrs.Commanding.CommandExecution.ICommandExecutor.Execute(type parameter.TCommand)', thus cannot add Requires.
d:\Development\Projects\ncqrs\Framework\src\Ncqrs\Commanding\CommandExecution\ICommandExecutor.cs(26,13): warning CC1033: Method 'Ncqrs.Commanding.CommandExecution.ICommandExecutorContracts.Execute(type parameter.TCommand)', thus cannot add Requires.
EXEC : error CC1019: Type 'Ncqrs.IClock' specifies the class 'Ncqrs.IClockContracts' as its contract class, but that class does not point back to this type.
d:\Development\Projects\ncqrs\Framework\src\Ncqrs\Eventing\Sourcing\EventSource.cs(112,13): warning CC1033: Method 'Ncqrs.Eventing.Sourcing.EventSource.InitializeFromHistory(System.Collections.Generic.IEnumerable)', thus cannot add Requires.
d:\Development\Projects\ncqrs\Framework\src\Ncqrs\Eventing\Sourcing\Mapping\ExpressionBasedEventHandlerMappingStrategy.cs(43,13): warning CC1033: Method 'Ncqrs.Eventing.Sourcing.Mapping.ExpressionBasedEventHandlerMappingStrategy.GetEventHandlers(System.Object)' implements interface method 'Ncqrs.Eventing.Sourcing.Mapping.IEventHandlerMappingStrategy.GetEventHandlers(System.Object)', thus cannot add Requires.
d:\Development\Projects\ncqrs\Framework\src\Ncqrs\Eventing\Sourcing\ISourcedEventHandler.cs(27,13): warning CC1033: Method 'Ncqrs.Eventing.Sourcing.IEventSourcedHandlerContracts.HandleEvent(Ncqrs.Eventing.Sourcing.ISourcedEvent)' implements interface method 'Ncqrs.Eventing.Sourcing.ISourcedEventHandler.HandleEvent(Ncqrs.Eventing.Sourcing.ISourcedEvent)', thus cannot add Requires.
EXEC : error CC1019: Type 'Ncqrs.Eventing.Sourcing.Snapshotting.ISnapshotable)', thus cannot add Requires.
EXEC : error CC1019: Type 'Ncqrs.Eventing.Storage.Serialization.IEventFormatter)' implements interface method 'Ncqrs.Eventing.Storage.Serialization.IEventTranslator)', thus cannot add Requires.
d:\Development\Projects\ncqrs\Framework\src\Ncqrs\Eventing\Storage\Serialization\IEventTranslator.cs(44,13): warning CC1033: Method 'Ncqrs.Eventing.Storage.Serialization.IEventTranslatorContracts)' implements interface method 'Ncqrs.Eventing.Storage.Serialization.IEventTranslator)', thus cannot add Requires.
d:\Development\Projects\ncqrs\Framework\src\Ncqrs\Eventing\Storage\Serialization\IEventFormatter.cs(46,13): warning CC1033: Method 'Ncqrs.Eventing.Storage.Serialization.IEventFormatterContracts.Serialize(Ncqrs.Eventing.Sourcing.ISourcedEvent)',thus cannot add Requires.
d:\Development\Projects\ncqrs\Framework\src\Ncqrs\Eventing\Storage\Serialization\IEventFormatter.cs(53,13): warning CC1033: Method 'Ncqrs.Eventing.Storage.Serialization.IEventFormatterContracts)' implements interface method 'Ncqrs.Eventing.Storage.Serialization.IEventFormatter)', thus cannot add Requires.
EXEC : error CC1019: Type 'Ncqrs.Config.IEnvironmentConfiguration' specifies the class 'Ncqrs.Config.IEnvironmentConfigurationContracts' as its contract class, but that class does not point back to this type.
d:\Development\Projects\ncqrs\Framework\src\Ncqrs\Eventing\Sourcing\Mapping\AttributeBasedEventHandlerMappingStrategy.cs(40,13): warning CC1033: Method 'Ncqrs.Eventing.Sourcing.Mapping.AttributeBasedEventHandlerMappingStrategy.GetEventHandlers(System.Object)' implements interface method 'Ncqrs.Eventing.Sourcing.Mapping.IEventHandlerMappingStrategy.GetEventHandlers(System.Object)', thus cannot add Requires.
d:\Development\Projects\ncqrs\Framework\src\Ncqrs\Eventing\Sourcing\Mapping\ConventionBasedEventHandlerMappingStrategy.cs(40,13): warning CC1033: Method 'Ncqrs.Eventing.Sourcing.Mapping.ConventionBasedEventHandlerMappingStrategy.GetEventHandlers(System.Object)' implements interface method 'Ncqrs.Eventing.Sourcing.Mapping.IEventHandlerMappingStrategy.GetEventHandlers(System.Object)', thus cannot add Requires.
EXEC : error CC1019: Type 'Ncqrs.Domain.Storage.IDomainRepository' specifies the class 'Ncqrs.Domain.Storage.IDomainRepositoryContracts' as its contract class, but that class does not point back to this type.
d:\Development\Projects\ncqrs\Framework\src\Ncqrs\Domain\Storage\IDomainRepository.cs(40,13): warning CC1033: Method 'Ncqrs.Domain.Storage.IDomainRepositoryContracts.GetById(System.Type,System.Guid)' implements interface method 'Ncqrs.Domain.Storage.IDomainRepository.GetById(System.Type,System.Guid)', thus cannot add Requires.
d:\Development\Projects\ncqrs\Framework\src\Ncqrs\Domain\Storage\IDomainRepository.cs(52,13): warning CC1033: Method 'Ncqrs.Domain.Storage.IDomainRepositoryContracts.Save(Ncqrs.Domain.AggregateRoot)' implements interface method 'Ncqrs.Domain.Storage.IDomainRepository.Save(Ncqrs.Domain.AggregateRoot)', thus cannot add Requires.
d:\Development\Projects\ncqrs\Framework\src\Ncqrs\Domain\UnitOfWork.cs(194,13): warning CC1033: Method 'Ncqrs.Domain.UnitOfWork.Accept' implements interface method 'Ncqrs.Domain.IUnitOfWorkContext.Accept', thus cannot add Requires.
d:\Development\Projects\ncqrs\Framework\src\Ncqrs\Eventing\Storage\IEventStore.cs(54,13): warning CC1033: Method 'Ncqrs.Eventing.Storage.IEventStoreContracts.Save(Ncqrs.Eventing.Sourcing.IEventSource)' implements interface method 'Ncqrs.Eventing.Storage.IEventStore.Save(Ncqrs.Eventing.Sourcing.IEventSource)', thus cannot add Requires.
elapsed time: 711,0407ms
C:\Program Files\Microsoft\Contracts\MsBuild\v4.0\Microsoft.CodeContracts.targets(231,5): error MSB3073: The command ""C:\Program Files\Microsoft\Contracts\Bin\ccrewrite" "@Ncqrsccrewrite.rsp"" exited with code 14.
------ Build started: Project: Ncqrs.Tests, Configuration: Debug Any CPU ------
EnsureContractReferenceAssemblies: D:\Development\Projects\ncqrs\Framework\src\Ncqrs\bin\Debug\Ncqrs.dll
Ncqrs.Tests -> D:\Development\Projects\ncqrs\Framework\src\Ncqrs.Tests\bin\Debug\Ncqrs.Tests.dll
------ Build started: Project: Ncqrs.Spec, Configuration: Debug Any CPU ------
Ncqrs.Spec -> D:\Development\Projects\ncqrs\Framework\src\Ncqrs.Spec\bin\Debug\Ncqrs.Spec.dll
========== Build: 2 succeeded or up-to-date, 1 failed, 0 skipped ==========
1' specifies the class 'Ncqrs.Commanding.CommandExecution.ICommandExecutorContracts
1' as its contract class, but that class does not point back to this type. EXEC : error CC1019: Type 'Ncqrs.Commanding.CommandExecution.Mapping.Attributes.CommandMappingAttribute' specifies the class 'Ncqrs.Commanding.CommandExecution.Mapping.Attributes.CommandMappingAttributeContracts' as its contract class, but that class does not point back to this type. d:\Development\Projects\ncqrs\Framework\src\Ncqrs\Commanding\CommandExecution\Mapping\Fluent\MappedCommandToAggregateRoot.cs(42,13): warning CC1032: Method 'Ncqrs.Commanding.CommandExecution.Mapping.Fluent.MappedCommandToAggregateRoot2.Execute(type parameter.TCommand)' overrides 'Ncqrs.Commanding.CommandExecution.Mapping.Fluent.MappedCommandToAggregateRoot
11.Execute(type parameter.TCommand)' implements interface method 'Ncqrs.Commanding.CommandExecution.ICommandExecutor
11<Ncqrs.Eventing.Sourcing.ISourcedEvent>)' implements interface method 'Ncqrs.Eventing.Sourcing.IEventSource.InitializeFromHistory(System.Collections.Generic.IEnumerable
11' specifies the class 'Ncqrs.Eventing.Sourcing.Snapshotting.SnapshotableContracts
1' as its contract class, but that class does not point back to this type. EXEC : error CC1019: Type 'Ncqrs.Eventing.Storage.IEventTypeResolver' specifies the class 'Ncqrs.Eventing.Storage.IEventTypeResolverContracts' as its contract class, but that class does not point back to this type. d:\Development\Projects\ncqrs\Framework\src\Ncqrs\Eventing\Storage\ISnapshotStore.cs(26,13): warning CC1033: Method 'Ncqrs.Eventing.Storage.ISnapshotStoreContracts.SaveShapshot(Ncqrs.Eventing.Sourcing.Snapshotting.ISnapshot)' implements interface method 'Ncqrs.Eventing.Storage.ISnapshotStore.SaveShapshot(Ncqrs.Eventing.Sourcing.Snapshotting.ISnapshot)', thus cannot add Requires. EXEC : error CC1019: Type 'Ncqrs.Eventing.Storage.Serialization.IEventConverter' specifies the class 'Ncqrs.Eventing.Storage.Serialization.IEventConverterContracts' as its contract class, but that class does not point back to this type. d:\Development\Projects\ncqrs\Framework\src\Ncqrs\Eventing\Storage\Serialization\IEventConverter.cs(44,13): warning CC1033: Method 'Ncqrs.Eventing.Storage.Serialization.IEventConverterContracts.Upgrade(Ncqrs.Eventing.Storage.StoredEvent1<Newtonsoft.Json.Linq.JObject>)' implements interface method 'Ncqrs.Eventing.Storage.Serialization.IEventConverter.Upgrade(Ncqrs.Eventing.Storage.StoredEvent
11' specifies the class 'Ncqrs.Eventing.Storage.Serialization.IEventFormatterContracts
1' as its contract class, but that class does not point back to this type. EXEC : error CC1019: Type 'Ncqrs.Eventing.Storage.Serialization.IEventTranslator1' specifies the class 'Ncqrs.Eventing.Storage.Serialization.IEventTranslatorContracts
1' as its contract class, but that class does not point back to this type. d:\Development\Projects\ncqrs\Framework\src\Ncqrs\Eventing\Storage\Serialization\IEventTranslator.cs(37,13): warning CC1033: Method 'Ncqrs.Eventing.Storage.Serialization.IEventTranslatorContracts1.TranslateToCommon(Ncqrs.Eventing.Storage.StoredEvent
11<type parameter.T>.TranslateToCommon(Ncqrs.Eventing.Storage.StoredEvent
11.TranslateToRaw(Ncqrs.Eventing.Storage.StoredEvent
11<type parameter.T>.TranslateToRaw(Ncqrs.Eventing.Storage.StoredEvent
11.Serialize(Ncqrs.Eventing.Sourcing.ISourcedEvent)' implements interface method 'Ncqrs.Eventing.Storage.Serialization.IEventFormatter
11.Deserialize(Ncqrs.Eventing.Storage.StoredEvent
11<type parameter.T>.Deserialize(Ncqrs.Eventing.Storage.StoredEvent
1