Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't create C# classes using XSD.exe #10195

Closed
davidcorbin-atmosera opened this issue Jul 26, 2023 · 6 comments
Closed

Can't create C# classes using XSD.exe #10195

davidcorbin-atmosera opened this issue Jul 26, 2023 · 6 comments
Labels
enhancement a request to enhance doxygen, not a bug XML XML Output

Comments

@davidcorbin-atmosera
Copy link

Describe the bug
Attempting to use Microsoft Visual Studio Tool to generate classes from CSD files here in the repository.

Expected behavior
Tool runs without errors.

Screenshots
Microsoft (R) Xml Schemas/DataTypes support utility
[Microsoft (R) .NET Framework, Version 4.8.3928.0]
Copyright (C) Microsoft Corporation. All rights reserved.
Error: Error generating classes for schema 'C:\Usedoxygen --rs\david_corbin\source\repos\doxygen\templates\xml\compound'.

  • Group 'docTitleCmdGroup' from targetNamespace='' has invalid definition: Circular group reference.

To Reproduce
xsd /c compound.xsd

Version
Current clone of Repository

Stack trace
N/A

Additional context
Add any other context about the problem here.

@albert-github
Copy link
Collaborator

  • Current clone of Repository

This is a moving target so please specify the version used (though I can reproduce the problem with the current master, 1.9.8 (2777acd) and an empty project).

The message:

Group 'docTitleCmdGroup' from targetNamespace='' has invalid definition: Circular group reference.

It looks like the

  <xsd:group name="docCmdGroup">
    <xsd:choice>
      <xsd:group ref="docTitleCmdGroup"/>

so the group in the group or choice in choice gives some problems.

  • what is the purpose of the the generation of the classes? Is it something similar to what is done for doxmlparser?

@albert-github albert-github added needinfo reported bug is incomplete, please add additional info XML XML Output labels Jul 26, 2023
@davidcorbin-atmosera
Copy link
Author

@albert-github - Thanks for the prompt response. First the easy part, I can confirm I am using 2777acd

As for "why", that is more complicated. I am looking to perform some analytics. Rather than attempting to parse source code, using the DoxyGen XML files seemed good (still does!), but then there was the choices in a .Net world of how to load them, and I was investingating XSD for strongly typed classes...

Not familiar with doxmlparse... will have to look that up.
I would love to discuss: david(dot)corbin(at)atmosera(dot)com.

albert-github added a commit to albert-github/doxygen that referenced this issue Jul 26, 2023
Original code looks like to be valid xsd code, working around on quirk of `xsd.exe`
@albert-github albert-github added enhancement a request to enhance doxygen, not a bug and removed needinfo reported bug is incomplete, please add additional info labels Jul 26, 2023
@albert-github
Copy link
Collaborator

I've just pushed a proposed patch, pull request #10196
(even though it is not really nice to copy the data)

@davidcorbin-atmosera
Copy link
Author

davidcorbin-atmosera commented Jul 28, 2023

Thanks. That gave me an idea (though I really wish MFST would update XSD to properly support Circular - and svcutil is not a great option either).

[Please feel free to Close this]

doxygen added a commit that referenced this issue Jul 31, 2023
issue #10195 Cant create C# classes using XSD.exe
@albert-github albert-github added the fixed but not released Bug is fixed in github, but still needs to make its way to an official release label Jul 31, 2023
@albert-github
Copy link
Collaborator

Code has been integrated in master on GitHub (please don't close the issue as this will be done at the moment of an official release).

@doxygen
Copy link
Owner

doxygen commented Aug 25, 2023

This issue was previously marked 'fixed but not released',
which means it should be fixed in doxygen version 1.9.8.
Please verify if this is indeed the case. Reopen the
issue if you think it is not fixed and please include any additional information
that you think can be relevant (preferably in the form of a self-contained example).

@doxygen doxygen removed the fixed but not released Bug is fixed in github, but still needs to make its way to an official release label Aug 25, 2023
@doxygen doxygen closed this as completed Aug 25, 2023
@albert-github albert-github changed the title Cant create C# classes using XSD.exe Can't create C# classes using XSD.exe Nov 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement a request to enhance doxygen, not a bug XML XML Output
Projects
None yet
Development

No branches or pull requests

4 participants
@doxygen @albert-github @davidcorbin-atmosera and others