Open PerryCodes opened 1 week ago
Can an admin please remove the v3 label? I didn't realize that --legacy was bumping the version of autorest.csharp down to v2 until after posting this. Thanks.
Here's the spec I'm attempting to build a client for (Autotask PSA) v1.json
I'm able to build clients fine without --legacy, however it doesn't seem to bother with models anymore. So then I tried the --generation1-convenience-client
option. That built models, but also decided it wanted to scope internal
all over the clients.
increase-memory-limit didn't help.
Could you try the customization to make clients internal? https://github.com/Azure/autorest.csharp/blob/feature/v3/readme.md#make-a-client-internal
Hi @PerryCodes --legacy
should be using our v2
generator which has been retired for a long time.
node
has some configuration which allows you to enlarge the heap, such as --max-old-space-size=4096
. The OOM
error might happen when your swagger is big.
But in general, our recommendation is to switch to the v3
generator, and if possible, switch to typespec
.
Here's the spec I'm attempting to build a client for (Autotask PSA) v1.json
I'm able to build clients fine without --legacy, however it doesn't seem to bother with models anymore. So then I tried the
--generation1-convenience-client
option. That built models, but also decided it wanted to scopeinternal
all over the clients.increase-memory-limit didn't help.
So if you remove --legacy
, only typespec
input will generate models.
If you remove --legacy
and add --generation1-convenience-client
option, and you want the clients to be public, you could add another configuration --public-client
with the --generation1-convenience-client
. The public-client
configuration should make your clients to be public by default.
I'm trying to use the --legacy option and it generates the following error: