views:

208

answers:

2

I'm currently trying to find out why my InjectableAttributes never get to the filter part.
Therefor I linked in the source project directly so I could easily put breakpoints etc.
When I build however I get the following message:

The following module was built either with optimizations enabled or without debug information: 
C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\root\[a bunch of randomly named directories]\assembly\[more random names]\MvcTurbine.Web.DLL]

To debug this module, change its project build configuration to Debug mode. To suppress this message, disable the 'Warn if no user code on launch' debugger option.

I checked the project's properties. It's configuration is set to "Active(Debug)" and the "Optimize code" check box is unchecked.

UPDATE
I checked again if I didn't by accident include the file rather then the project, but the references seem correct.
Just to be sure I also removed all existing bins so that all libraries are definitely rebuild somewhere, but to no avail.

UPDATE
In the advanced Build window the Debug output is set to Full and all options are identical to projects that are building debug info.
The config manager shows that the project is being built and has the exact same settings as all the other options.

UPDATE
In the Debug->Windows-Modules window the symbol status for the turbine library is PDB file does not match image I removed all corresponding pdb files on my entire system to make sure it gets re-generated, but to no avail.
To make sure I also searched for the dll on my entire system and removed them. Nothing.

What can be preventing VS from creating debug information?

+1  A: 

It sounds like you've referenced the MvcTurbine.Web.DLL file rather than the MvcTurbine project. Try removing the reference and re-adding it as a project reference.

Update Are you sure the DLL isn't coming from the GAC? Do Debug->Windows->Modules when the app is running and check the Path column.

Craig Stuntz
Because I started doubting myself I checked again, but no I did reference the project, not the file. I'll update the OP to clarify.
borisCallens
OK, I have added a new guess. :)
Craig Stuntz
I didn't know about this window :) +1!The libraries are not in the gack (for the path see the error message I updated in OP.They are optimized = no, but the Symbol status is PDB does not match image. Any idea where to go from here? I'll start with deleting pdb files for this module wherever I can find it :P
borisCallens
*gac. I keep doing this...
borisCallens
Does it matter that the User Code = No for this library?
borisCallens
It does if you have debugging non-user code disabled, which is the default.
Craig Stuntz
The symbols are probably coming from your symbol cache. The filename won't match the assembly, but you can see it in the Modules window.
Craig Stuntz
I checked the module window for the pdb file path and removed it (complete with the entire directory it was in).I also checked the debug symbol info for all the paths that were checked if I could find any more of the pdb files. Still the same.What makes the UserCode flag be none? Should I change the value of the flag somehow or enable debug non-user code somewhere (I imagine the latter option will become bothersome for all other libraries)
borisCallens
Just something I noted now: The mvcTurbine libs are signed. Does that change anything at all?
borisCallens
It's not the signing. another project that's using the same signing file does generate correct debugging info. Sadly it's not that project I'm interested in.
borisCallens
Start with enable debug non-user code because it's easy to try. It's in debugging options.
Craig Stuntz
Yes, thought so too, but it doesn't seem to change anything.
borisCallens
+1  A: 

Check that debug info is being generated for the project. You can do this by opening the Build tab on the Project Properties page and clicking the "Advanced..." button. Check the "Debug Info" setting. See this MSDN article for an explanation of what each option means.

If that doesn't solve it, check that the MvcTurbine project is actually being built (Build -> Configuration Manager).

adrianbanks
The debug info output is "full". I cross checked it with other libraries that are writing debug info and it matches.In the Config mngr tie mvcTurbine projects are on Debug Any CPU and checked, just like all the others.
borisCallens