RangeError: Maximum call stack size exceeded -- generating C# client
See original GitHub issueI am trying to generate a C# client for a large-ish (7.6MB 234K lines) OpenAPI spec from a vendor. Unfortunately it’s not public so I cannot attach it here.
Here is my command line:
autorest --input-file=verylarge.json --csharp --output-folder=localfolder
Here is the error I’m getting
AutoRest code generation utility [cli version: 3.2.0; node: v12.18.3, max-memory: 2048 MB]
(C) 2018 Microsoft Corporation.
https://aka.ms/autorest
NOTE: AutoRest core version selected from configuration: ~3.1.0.
Loading AutoRest core 'C:\Users\dmcclelland1\.autorest\@autorest_core@3.1.3\node_modules\@autorest\core\dist' (3.1.3)
INFORMATION: > Loading AutoRest extension '@autorest/csharp' (latest->3.0.0-beta.20210428.6)
INFORMATION: > Loading AutoRest extension '@autorest/modelerfour' (4.19.0->4.19.0)
RangeError: Maximum call stack size exceeded
What steps can I take to troubleshoot this?
Issue Analytics
- State:
- Created 2 years ago
- Comments:11 (5 by maintainers)
Top Results From Across the Web
javascript - Maximum call stack size exceeded error
It means that somewhere in your code, you are calling a function which in turn calls another function and so forth, until you...
Read more >RangeError: Maximum call stack size exceeded - Educative.io
The most common source for this error is infinite recursion. You must have a recursive function in your code whose base case is...
Read more >JavaScript Error: Maximum Call Stack Size Exceeded
If you see the “Maximum Call Stack Size Exceeded” error, there's likely a problem with a recursive function within your JavaScript code.
Read more >Uncaught RangeError: Maximum call ... - Net-Informations.Com
This error is almost always means you have a problem with recursion in JavaScript code, as there isn't any other way in JavaScript...
Read more >[Bug] Maximum call stack size exceeded · Issue #1367 - GitHub
Root cause: Circular references were killing the stack, I simply turned them off and it started working again. How did you fix it?...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I will keep looking through it, but since the original error is resolved I’ll close this for now - thanks for your help @timotheeguerin
Yeah that error looks like there is something named with an empty string or blank string. Usually this is an enum with an empty value. I believe this can be resolved by giving the explict name to the enum empty value using
x-ms-enum