[MonoDevelop] MD 2.8 Loading Solution error: Error loading policy file 'Default.mdpolicy.xml'
Michael Hutchinson
m.j.hutchinson at gmail.com
Wed Oct 19 19:18:29 EDT 2011
On Thu, Oct 6, 2011 at 8:16 AM, Miljenko Cvjetko
<mcvjetko at holisticware.net> wrote:
> Hi
>
> During loading solution there are few confusing errors 1st one:
>
> Error - 08:47:43 - Error loading policy file 'Default.mdpolicy.xml' file
> '%USERPROFILE%\AppData\Roaming\MonoDevelop-2.8\Policies\Default.mdpolicy.xml':
> System.InvalidOperationException: Could not set property 'Text' in type
> 'StandardHeader' ---> System.InvalidCastException: Unable to cast object
> of type 'MonoDevelop.Core.Serialization.DataItem' to type
> 'MonoDevelop.Core.Serialization.DataValue'.
>
> at
> MonoDevelop.Core.Serialization.PrimitiveDataType.OnDeserialize(SerializationContext
> serCtx, Object mapData, DataNode data)
> at MonoDevelop.Core.Serialization.DataSerializer.OnDeserialize(DataType
> dataType, SerializationContext serCtx, Object mapData, DataNode data)
> at
> MonoDevelop.Core.Serialization.DataType.Deserialize(SerializationContext
> serCtx, Object mapData, DataNode data)
> at
> MonoDevelop.Core.Serialization.ItemProperty.OnDeserialize(SerializationContext
> serCtx, DataNode data)
> at
> MonoDevelop.Core.Serialization.DataSerializer.OnDeserializeProperty(ItemProperty
> prop, SerializationContext serCtx, Object instance, DataNode data)
> at
> MonoDevelop.Core.Serialization.ItemProperty.Deserialize(SerializationContext
> serCtx, Object instance, DataNode data)
> at
> MonoDevelop.Core.Serialization.ClassDataType.Deserialize(SerializationContext
> serCtx, Object obj, DataCollection itemData, DataItem ukwnDataRoot,
> String baseName)
> --- End of inner exception stack trace ---
> at
> MonoDevelop.Core.Serialization.ClassDataType.Deserialize(SerializationContext
> serCtx, Object obj, DataCollection itemData, DataItem ukwnDataRoot,
> String baseName)
> at
> MonoDevelop.Core.Serialization.ClassDataType.DeserializeNoCustom(SerializationContext
> serCtx, Object obj, DataCollection itemData)
> at
> MonoDevelop.Core.Serialization.ClassDataType.OnDeserialize(SerializationContext
> serCtx, Object mapData, DataNode data, Object obj)
> at MonoDevelop.Core.Serialization.DataSerializer.OnDeserialize(DataType
> dataType, SerializationContext serCtx, Object mapData, DataNode data,
> Object valueInstance)
> at
> MonoDevelop.Core.Serialization.DataType.Deserialize(SerializationContext
> serCtx, Object mapData, DataNode data, Object valueInstance)
> at
> MonoDevelop.Core.Serialization.ClassDataType.OnDeserialize(SerializationContext
> serCtx, Object mapData, DataNode data)
> at MonoDevelop.Core.Serialization.DataSerializer.OnDeserialize(DataType
> dataType, SerializationContext serCtx, Object mapData, DataNode data)
> at
> MonoDevelop.Core.Serialization.DataType.Deserialize(SerializationContext
> serCtx, Object mapData, DataNode data)
> at
> MonoDevelop.Core.Serialization.DataContext.LoadConfigurationData(SerializationContext
> serCtx, Type type, DataNode data)
> at MonoDevelop.Core.Serialization.DataSerializer.Deserialize(Type type,
> DataNode data)
> at MonoDevelop.Projects.Policies.PolicyService.RawDeserialize(DataNode data)
> at MonoDevelop.Projects.Policies.PolicyService.DiffDeserialize(DataItem
> item)
> at
> MonoDevelop.Projects.Policies.PolicyService.<DiffDeserializeXml>d__a.MoveNext()
> at MonoDevelop.Projects.Policies.PolicySet.LoadFromXml(XmlReader reader)
> at
> MonoDevelop.Projects.Policies.PolicyService.<LoadPolicy>b__37(StreamReader
> reader)
> at MonoDevelop.Projects.Policies.PolicyService.ParanoidLoad(String
> fileName, String friendlyName, Action`1 read)
>
>
> my
> %USERPROFILE%\AppData\Roaming\MonoDevelop-2.8\Policies\Default.mdpolicy.xml:
>
> <?xml version="1.0" encoding="utf-8"?>
> <Policies>
> <PolicySet name="Default" id="Default">
> <DotNetNamingPolicy>
> <DirectoryNamespaceAssociation>None</DirectoryNamespaceAssociation>
> <ResourceNamePolicy>FileFormatDefault</ResourceNamePolicy>
> </DotNetNamingPolicy>
> <TextStylePolicy inheritsSet="null" scope="application/xml" />
> <XmlFormattingPolicy inheritsSet="Mono" inheritsScope="application/xml"
> scope="application/xml" />
> <TextStylePolicy inheritsSet="Mono" inheritsScope="text/plain"
> scope="text/plain">
> <FileWidth>90</FileWidth>
> <TabWidth>4</TabWidth>
> </TextStylePolicy>
> <TextStylePolicy inheritsSet="null" scope="text/x-csharp" />
> <CSharpFormattingPolicy inheritsSet="Mono" inheritsScope="text/x-csharp"
> scope="text/x-csharp" />
> <VersionControlPolicy inheritsSet="Mono" />
> <StandardHeader>
> <Text />
> <IncludeInNewFiles>True</IncludeInNewFiles>
> </StandardHeader>
> </PolicySet>
> </Policies>
>
>
> mea culpa or what?
It's a bug, I filed it at
http://bugzilla.xamarin.com/show_bug.cgi?id=1588. Thanks for the
report!
--
Michael Hutchinson
http://mjhutchinson.com
More information about the Monodevelop-list
mailing list