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

Fixes AWS AwsStandardTypesTransformer bug #1129

Merged
merged 1 commit into from
Jul 28, 2023

Conversation

Baccata
Copy link
Contributor

@Baccata Baccata commented Jul 28, 2023

Only structure members can carry the @default trait.

Only structure members can carry the `@default` trait.
@daddykotex
Copy link
Contributor

So the spec was not invalid, we were just transforming the model incorrectly, interesting.

@daddykotex daddykotex merged commit 727dd80 into series/0.17 Jul 28, 2023
@daddykotex
Copy link
Contributor

daddykotex commented Jul 28, 2023

Do you think it could be good user experience to:

  1. load the model before any transformation (keep the result aside, do not throw if it fail)
  2. load the model after transformation

Then if an error occur during the second step, we can print a better error message like:

val msg: 
if (failedAt1) "The model was not loading before transformation and still does not load after transformations."
else "The model was loading before transformation but does not load after transformations."
val errors = ??? // errors from 1 if failed, else errors from 2, and JUST errors, we can print warnings when the thing is successful
s"""
Code generation failed because we were not able to load the model.
$msg
Here are the errors:
$errors
"""

@Baccata
Copy link
Contributor Author

Baccata commented Jul 28, 2023

Possibly. Honestly I'm not too sure, because we're not attempting transformations of models that do not pass validation.

However, one thing that'd improve user experience would be to remove warnings from the reported validation events when there's an error or danger.

@Baccata Baccata deleted the fix-aws-transformation-again branch July 28, 2023 13:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants