-
Notifications
You must be signed in to change notification settings - Fork 124
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
[BUG] Fields with $ result in error #449
Labels
Comments
hi @queen3 ! Please share part of swagger file, generated this. Thanks! |
Hello. Yes, sorry, not sure if I can share the whole file, so here's that part:
|
@queen3 thanks! Will fix it asap! |
I have the same issue with dots in property names (Company.Id, Company.Name)...
|
Merged
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
If the field contain $ in the name, the JsonKey name is treated as a symbol and this results in an error.
So the generated code is
@jsonkey(name: '$Solution')
final String? $Solution;
and the compilation error is
Arguments of a constant creation must be constant expressions.
Undefined name 'Solution'.
I suppose $ has to be escaped somehow in the generated code.
The text was updated successfully, but these errors were encountered: