modelsbuilder / ModelsBuilder.Original

The Community Models Builder for Umbraco
MIT License
114 stars 49 forks source link

Generate full Xml documentation #164

Open rammi987 opened 6 years ago

rammi987 commented 6 years ago

note: title was "Modelsbuilder does so projekt not can build on special settings" and the idea is to generate the full /// Xml documentation so that building models does not trigger warnings.

Hello,

I work on a project where in the main project where Umbraco living, under the VS project properties inside Build is under output XML documentation file set to true, witch only will give an warning but we tread all warnings as errors "errors and warnings" "warning level: 4"

Trouble is Modelsbuilder not write xml

on the deffined public class, or not set a warning disable #number.

This gives some troubles there cuorse project no to build; i have try to set model builder to go out to an other code lib, where theise settings not is on, but the new problems is it requried Umbraco install and lots of other dll include before it will work, so thats a huge opreations for something simple.

can you help here?

ksuvec commented 6 years ago

Hi rammi987.

We at Umbraco are not sure we quite understand your issue, we would however like to help you sort it out :) If you can write me an e-mail on kec@umbraco.dk explaining your problem in danish, I will make sure we take a good look at it. Regards, Kristian

zpqrtbnk commented 6 years ago

Is it... that MB generates code that is not completely and properly documented with /// xml comments, which causes warnings during compilation, and warnings are treated as errors, which breaks your build?

Any chance you can post a list of those warnings here? We can fix MB by either generating the proper comments or by disabling these warnings in the MB generated code.

rammi987 commented 6 years ago

@ksuvec as @zpqrtbnk is telling, i attach an image where you can see the warnings, and on witch line. And a image of the webappliation propertie page with the settings.

image image

zpqrtbnk commented 6 years ago

got it - thinking now

rammi987 commented 6 years ago

Easy is just disable cs1591

Meaby best solutions is, the Code analysis suppress results from generated code like edmx generate classes can. (edmx does´t have xml comments, but skip the warnings)

Or custom able from web.config what warnings should be disable

michaelchart commented 4 years ago

@zpqrtbnk We also have this issue. Could we add in something for now that disables the warnings?

If we were to contribute a PR to this effect, should we do so in the UmbracoCms repo, or this one?

zpqrtbnk commented 4 years ago

are you using the MB version that adds the "generated" attribute? that attribute supposedly helps suppressing warnings... other than that, a PR is fine - on this repository yes.

michaelchart commented 4 years ago

@zpqrtbnk Yes, the generated attributes are present

image

I'll take a look at creating a PR, either to add some XML comments or disable the warnings.