Build errors (Debug only) for Changeset a54c8b7cd6eb

Sep 18, 2010 at 5:53 PM

Line 147 of ActionMessage.cs is throwing several errors on a Debug build for Silverlight and WPF. I did a complete Synchronize and Update with discard local beforehand. Release builds fine. Housekeeping, I guess. Line 147 is marked below:

Snippet
#if NET
            var binding = new Binding {
                Path = new PropertyPath(Message.HandlerProperty), 
                Source = currentElement
            };
#else
            const string bindingText = "<Binding xmlns='http://schemas.microsoft.com/winfx/2006/xaml/presentation\' xmlns:cal='clr-namespace:Caliburn.Micro;assembly=Caliburn.Micro' Path='(cal:Message.Handler)' />";
// below is line 147
            var binding = (Binding)XamlReader.Load(bindingText);
            binding.Source = currentElement;
#endif

Error    16    The type 'System.Xml.XmlReader' is defined in an assembly that is not referenced. You must add a reference to assembly 'System.Xml, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'.    D:\DotNetProjects\NetFx4\caliburn.micro\src\Caliburn.Micro.Silverlight\ActionMessage.cs    147    13    Caliburn.Micro.WPF
Error    17    The best overloaded method match for 'System.Windows.Markup.XamlReader.Load(System.IO.Stream)' has some invalid arguments    D:\DotNetProjects\NetFx4\caliburn.micro\src\Caliburn.Micro.Silverlight\ActionMessage.cs    147    36    Caliburn.Micro.WPF
Error    18    Argument 1: cannot convert from 'string' to 'System.IO.Stream'    D:\DotNetProjects\NetFx4\caliburn.micro\src\Caliburn.Micro.Silverlight\ActionMessage.cs    147    52    Caliburn.Micro.WPF
Coordinator
Sep 18, 2010 at 6:46 PM

Oops! Thanks for catching that. It's now fixed in 10d0451fdedc 

Sep 19, 2010 at 12:14 PM

I have the latest check in, when i try to build the sln in vs2010, it fails to build the templates and there are 14 warnings, is this expected?  Can't see anything in the docs about it.

 

Warning    1    Load of property 'RootNamespace' failed.  The string for the root namespace must be a valid identifier.    SilverlightTemplate
Warning    2    Load of property 'RootNamespace' failed.  The string for the root namespace must be a valid identifier.    WPFTemplate
Error    3    The type or namespace name 'Framework' could not be found (are you missing a using directive or an assembly reference?)    C:\Dev\caliburnmicro\templates\SilverlightTemplate\AppBootstrapper.cs    9    8    SilverlightTemplate
Error    4    The type or namespace name 'Bootstrapper' could not be found (are you missing a using directive or an assembly reference?)    C:\Dev\caliburnmicro\templates\SilverlightTemplate\AppBootstrapper.cs    11    33    SilverlightTemplate
Warning    5    Missing XML comment for publicly visible type or member 'Caliburn.Micro.Screen.Log'    C:\Dev\caliburnmicro\src\Caliburn.Micro.Silverlight\Screen.cs    13    40    Caliburn.Micro.WPF
Warning    6    XML comment is not placed on a valid language element    C:\Dev\caliburnmicro\src\Caliburn.Micro.Silverlight\PropertyChangedBase.cs    32    5    Caliburn.Micro.WPF
Warning    7    Missing XML comment for publicly visible type or member 'Caliburn.Micro.PropertyChangedBase'    C:\Dev\caliburnmicro\src\Caliburn.Micro.Silverlight\PropertyChangedBase.cs    35    18    Caliburn.Micro.WPF
Warning    8    XML comment is not placed on a valid language element    C:\Dev\caliburnmicro\src\Caliburn.Micro.Silverlight\PropertyChangedBase.cs    47    9    Caliburn.Micro.WPF
Warning    9    Missing XML comment for publicly visible type or member 'Caliburn.Micro.PropertyChangedBase.PropertyChanged'    C:\Dev\caliburnmicro\src\Caliburn.Micro.Silverlight\PropertyChangedBase.cs    50    50    Caliburn.Micro.WPF
Warning    10    Missing XML comment for publicly visible type or member 'Caliburn.Micro.ActionMessage.OnAttached()'    C:\Dev\caliburnmicro\src\Caliburn.Micro.Silverlight\ActionMessage.cs    90    33    Caliburn.Micro.WPF
Warning    11    Missing XML comment for publicly visible type or member 'Caliburn.Micro.ActionMessage.OnDetaching()'    C:\Dev\caliburnmicro\src\Caliburn.Micro.Silverlight\ActionMessage.cs    110    33    Caliburn.Micro.WPF
Warning    12    Missing XML comment for publicly visible type or member 'Caliburn.Micro.ActionMessage.Invoke(object)'    C:\Dev\caliburnmicro\src\Caliburn.Micro.Silverlight\ActionMessage.cs    166    33    Caliburn.Micro.WPF
Warning    13    Missing XML comment for publicly visible type or member 'Caliburn.Micro.Screen.Log'    C:\Dev\caliburnmicro\src\Caliburn.Micro.Silverlight\Screen.cs    13    40    Caliburn.Micro.Silverlight
Warning    14    Missing XML comment for publicly visible type or member 'Caliburn.Micro.ActionMessage.OnAttached()'    C:\Dev\caliburnmicro\src\Caliburn.Micro.Silverlight\ActionMessage.cs    90    33    Caliburn.Micro.Silverlight
Warning    15    Missing XML comment for publicly visible type or member 'Caliburn.Micro.ActionMessage.OnDetaching()'    C:\Dev\caliburnmicro\src\Caliburn.Micro.Silverlight\ActionMessage.cs    110    33    Caliburn.Micro.Silverlight
Warning    16    Missing XML comment for publicly visible type or member 'Caliburn.Micro.ActionMessage.Invoke(object)'    C:\Dev\caliburnmicro\src\Caliburn.Micro.Silverlight\ActionMessage.cs    166    33    Caliburn.Micro.Silverlight
Error    17    '$safeprojectname$' name is not valid in the default namespace '$safeprojectname$'. Correct the RootNamespace tag value in the project file.    WPFTemplate

Coordinator
Sep 19, 2010 at 3:29 PM

The warnings related to code docs I apparently need to add :) The templates do not build on their own. You must run the power shell script to do that. Perhaps I should put the templates in their own solution?

Sep 19, 2010 at 5:17 PM

Perhaps you should, for distinction purpose.

Just tow little typing errors I want to point out: The script's name is "generate-tempaltes.ps1", and in line 84 of the script it creates folders named "Caliburn_Mirco_".

(Did not find that important enough to open a new discussion.)

Sep 19, 2010 at 5:43 PM

I have just been unticking them in the Properties, Configuration, Build column lol.

Speaking of templates, Rob, I had sent you an email from your site last week, but had not heard back. Do you want me to delete the Caliburn.Micro WP7
template I built and posted to the Visual Studio Gallery? Since you've now embedded the templates, and just about have it nailed for continuous update
of the source, it seems like a distraction to have another template on the Gallery. My template includes the Caliburn.Micro.dll from a month or so ago,
which, of course, makes no sense as you evolve it. Rudi Grobler did the WPF one, and also has a Silverlight one on his blog (Rudi in the Cloud).

Thanks for the quick turnaround. I did not see any change to ActionMessage.cs when I pulled down the update (especially around line 147). What was it?
Project level define missing?

Bob Baker

Coordinator
Sep 19, 2010 at 7:18 PM

@bbakermai

It was a Debug mode build symbol that was missing. I thought I had tidied all that up, but I obviously missed one. That's all that changed.

Also, I emailed you back, but I guess my response got lost in the ethos somewhere. For the time being, I think you can probably leave your template in the gallery. I'll try to get with you and Rudi to sync on getting the official templates up there when the time is right. I want to let things sit a bit more to make sure we don't have too many more issues before I put it up. Thanks for building the templates too. That really motivated us to make it an official part of the project.

 

@RAuer

Thanks for pointing out those typos :) We'll try to get those fixed shortly.

Sep 19, 2010 at 10:04 PM

It was my pleasure, and a perfect storm where Rudi had not done one for WP7, and I needed an excuse to teach myself how to build one.

Sep 20, 2010 at 8:06 AM

This all makes sense now :-)

Thankee Kindly!