kiota CSharp generation for yaml fails with error generating the client: Invalid URI: The URI is empty. #5760
AndrewZenith
started this conversation in
General
Replies: 1 comment
-
Thanks for raising this @AndrewZenith Taking a look at your input description, it looks like you have a number of XML objects. These objects look to have empty strings for the
xml:
name: DocNumHEA5
namespace: ""
attribute: false
wrapped: false Any chance you can try removing the properties/entries of |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Outcome.txt
Having trouble generating some CSharp Code from the attached YAML file:
Tue 12 11 2024 10:22:26: Executing:
Tue 12 11 2024 10:22:26: kiota --version
Tue 12 11 2024 10:22:26: 1.20.0+81bdb1bf13383a749f794d47926d09733d2d7be1
Tue 12 11 2024 10:22:26: Executing:
Tue 12 11 2024 10:22:26: kiota generate -l CSharp -d "D:\projects\MyCustoms\webapi\REST\HMRC\SAS\Declaration\Declaration.yaml" -o "C:\Users\andre\AppData\Local\Temp\f8f80e7e-3b13-4280-be2c-15a774ad674e" -n webapi.REST.HMRC.SAS.Declaration --type-access-modifier Public
Tue 12 11 2024 10:22:26:
Tue 12 11 2024 10:22:26: crit: Kiota.Builder.KiotaBuilder[0]
Tue 12 11 2024 10:22:26: error generating the client: Invalid URI: The URI is empty.
Tue 12 11 2024 10:22:26:
Tue 12 11 2024 10:22:26: Rapicgen.Core.Generators.ProcessLaunchException: kiota failed!
Output:
crit: Kiota.Builder.KiotaBuilder[0]
error generating the client: Invalid URI: The URI is empty.
Error:
at Rapicgen.Core.Generators.ProcessLauncher.StartInternal(String command, String arguments, Action
1 onOutputData, Action
1 onErrorData, String workingDirectory) in D:\a\apiclientcodegen\apiclientcodegen\src\Core\ApiClientCodeGen.Core\Generators\ProcessLauncher.cs:line 107at Rapicgen.Core.Generators.ProcessLauncher.Start(String command, String arguments, Action
1 onOutputData, Action
1 onErrorData, String workingDirectory) in D:\a\apiclientcodegen\apiclientcodegen\src\Core\ApiClientCodeGen.Core\Generators\ProcessLauncher.cs:line 74at Rapicgen.Core.Generators.ProcessLauncher.Start(String command, String arguments, String workingDirectory) in D:\a\apiclientcodegen\apiclientcodegen\src\Core\ApiClientCodeGen.Core\Generators\ProcessLauncher.cs:line 33
at Rapicgen.Core.Generators.Kiota.KiotaCodeGenerator.RunKiotaGenerate(String outputFolder) in D:\a\apiclientcodegen\apiclientcodegen\src\Core\ApiClientCodeGen.Core\Generators\Kiota\KiotaCodeGenerator.cs:line 104
at Rapicgen.Core.Generators.Kiota.KiotaCodeGenerator.GenerateCode(IProgressReporter pGenerateProgress) in D:\a\apiclientcodegen\apiclientcodegen\src\Core\ApiClientCodeGen.Core\Generators\Kiota\KiotaCodeGenerator.cs:line 48
at Rapicgen.CustomTool.SingleFileCodeGenerator.Generate(String wszInputFilePath, String bstrInputFileContents, String wszDefaultNamespace, IntPtr[] rgbOutputFileContents, UInt32& pcbOutput, IVsGeneratorProgress pGenerateProgress)
Tue 12 11 2024 10:22:26: Rapicgen.Core.Generators.ProcessLaunchException: kiota failed!
Output:
crit: Kiota.Builder.KiotaBuilder[0]
error generating the client: Invalid URI: The URI is empty.
Error:
at Rapicgen.Core.Generators.ProcessLauncher.StartInternal(String command, String arguments, Action
1 onOutputData, Action
1 onErrorData, String workingDirectory) in D:\a\apiclientcodegen\apiclientcodegen\src\Core\ApiClientCodeGen.Core\Generators\ProcessLauncher.cs:line 107at Rapicgen.Core.Generators.ProcessLauncher.Start(String command, String arguments, Action
1 onOutputData, Action
1 onErrorData, String workingDirectory) in D:\a\apiclientcodegen\apiclientcodegen\src\Core\ApiClientCodeGen.Core\Generators\ProcessLauncher.cs:line 74at Rapicgen.Core.Generators.ProcessLauncher.Start(String command, String arguments, String workingDirectory) in D:\a\apiclientcodegen\apiclientcodegen\src\Core\ApiClientCodeGen.Core\Generators\ProcessLauncher.cs:line 33
at Rapicgen.Core.Generators.Kiota.KiotaCodeGenerator.RunKiotaGenerate(String outputFolder) in D:\a\apiclientcodegen\apiclientcodegen\src\Core\ApiClientCodeGen.Core\Generators\Kiota\KiotaCodeGenerator.cs:line 104
at Rapicgen.Core.Generators.Kiota.KiotaCodeGenerator.GenerateCode(IProgressReporter pGenerateProgress) in D:\a\apiclientcodegen\apiclientcodegen\src\Core\ApiClientCodeGen.Core\Generators\Kiota\KiotaCodeGenerator.cs:line 48
at Rapicgen.CustomTool.SingleFileCodeGenerator.Generate(String wszInputFilePath, String bstrInputFileContents, String wszDefaultNamespace, IntPtr[] rgbOutputFileContents, UInt32& pcbOutput, IVsGeneratorProgress pGenerateProgress)
Tue 12 11 2024 10:22:26: Unable to generate code
Beta Was this translation helpful? Give feedback.
All reactions