Page 1 of 2
XS1569: Error writing to XML documentation file
Posted: Mon Aug 10, 2020 7:19 pm
by steveferrandino
Hi,
I'm getting this when trying to generate XML comment in 2.5.2.0 with VS 2019 enterprise
The full error message is "XS1569: Error writing to XML documentation file: The given key was not present in the dictionary"
Even with Output set to Diagnostic it doesn't tell me what key is not present
Any help, appreciated before I start commenting out all my comments to see which one it's having a problem with
Thanks,
SteveF
XS1569: Error writing to XML documentation file
Posted: Mon Aug 10, 2020 8:37 pm
by Chris
Hi Steve,
Maybe there's some more info in the Output window? Specifically a callstack together with the exception that apparently happens in the compiler that is noted in the error message.
XS1569: Error writing to XML documentation file
Posted: Mon Aug 10, 2020 8:38 pm
by steveferrandino
Hi Chris,
I'll look at it again tomorrow and send you a dump of what I see
Thanks,
SteveF
XS1569: Error writing to XML documentation file
Posted: Tue Aug 11, 2020 2:59 pm
by steveferrandino
Hi Chris,
I've shared a onedrive line with the file to your eMail. The error shows up on line 9311
Thanks,
SteveF
XS1569: Error writing to XML documentation file
Posted: Tue Aug 11, 2020 4:31 pm
by Chris
Hi Steve,
Thanks, but unfortunately indeed there's no more additional info about it which could help. I am afraid the only way is as you said to locate the problem with trial an error, unless you can send the full (compileable) project to Robert, so he can debug the compiler while compiling it..
XS1569: Error writing to XML documentation file
Posted: Tue Aug 11, 2020 4:32 pm
by steveferrandino
Ok. thanks
SteveF
XS1569: Error writing to XML documentation file
Posted: Tue Aug 11, 2020 7:32 pm
by steveferrandino
I found it. YAY
/// <seealso cref="xxx"/>
Thanks,
SteveF
XS1569: Error writing to XML documentation file
Posted: Wed Aug 12, 2020 8:28 am
by Chris
Hi Steve,
Nice! Can you please post the full doc comments you had included for this specific method(s) (before fixing the problem), so I can log this to be fixed?
XS1569: Error writing to XML documentation file
Posted: Wed Aug 12, 2020 1:50 pm
by steveferrandino
Hi Chris,
Here is the code (with the seealso commented out) these are both in the same project named sph_core_library. this worked at some time in the past (possibly the vulcan compiler?)
/// <summary>
/// Convert an XML boolean to a logic
/// </summary>
///// <seealso cref="Sph_Core_Library.Functions.LogicToXmlLogic"/>
/// <param name='sXmlString'>The XML String</param>
/// <returns>true if the XML string == "1"</returns>
function XmlLogicToLogic( sXmlString as string ) as logic
return (alltrim(sXmlString) == "1")
/// <summary>
/// Convert a logic to an XML boolean
/// </summary>
///// <seealso cref="Sph_Core_Library.Functions.XmlLogicToLogic"/>
/// <param name='lLogic'>The Logic</param>
/// <returns>"1" if the Logic is true, "0" if false</returns>
function LogicToXmlLogic( lLogic as logic ) as string
return iif(lLogic,"1","0")
Thanks,
SteveF
XS1569: Error writing to XML documentation file
Posted: Wed Aug 12, 2020 2:05 pm
by robert
Steve,
Thanks, I can reproduce this. The exception disappears if you prefix the cref strings with "M:" (method reference). But this should not be needed. Also the classname prefix should not be needed (C# does not require this).
In fact I remember seeing this before when documenting the runtime. I use fully qualified references there to resolve the problem. But that really should not be needed.
It should be enough to write <seealso cref="XmlLogicToLogic"/> and that should resolve to method or property with that name in the same (compiler generated Functions) class.
I'll see what I can do.
Robert