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

[MONITOR-SPEC-PR] Failed to successfully run fluentnamer plugin #9570

Open
jianingwang123 opened this issue Dec 24, 2024 · 2 comments
Open
Assignees

Comments

@jianingwang123
Copy link

jianingwang123 commented Dec 24, 2024

Description:

06:02:26.277 cmdout 	[Java-Sdk-Automation] info    | FluentGen | Read YAML
06:02:26.852 cmdout 	[Java-Sdk-Automation] info    | FluentNamer | Created temp directory for code model: /tmp/code-modelf8fdfef0-207f-4773-8538-bfeefa3449ab18337953335811302983
06:02:29.219 cmdout 	[Java-Sdk-Automation] error   | FluentNamer | Failed to successfully run fluentnamer plugin.
06:02:29.219 cmdout 	[Java-Sdk-Automation] Cannot create property=schemas for JavaBean=com.microsoft.typespec.http.client.generator.core.extension.model.codemodel.CodeModel@3ac1d089
06:02:29.219 cmdout 	[Java-Sdk-Automation]  in 'string', line 1, column 1:
06:02:29.219 cmdout 	[Java-Sdk-Automation]     info:
06:02:29.219 cmdout 	[Java-Sdk-Automation]     ^
06:02:29.219 cmdout 	[Java-Sdk-Automation] Cannot create property=armIds for JavaBean=com.microsoft.typespec.http.client.generator.core.extension.model.codemodel.Schemas@69c223e3
06:02:29.219 cmdout 	[Java-Sdk-Automation]  in 'string', line 5, column 3:
06:02:29.219 cmdout 	[Java-Sdk-Automation]       booleans:
06:02:29.219 cmdout 	[Java-Sdk-Automation]       ^
06:02:29.220 cmdout 	[Java-Sdk-Automation] Cannot create property=extensions for JavaBean=com.microsoft.typespec.http.client.generator.core.extension.model.codemodel.ArmIdSchema@30427649
06:02:29.220 cmdout 	[Java-Sdk-Automation]  in 'string', line 19587, column 7:
06:02:29.220 cmdout 	[Java-Sdk-Automation]         - &ref_1500
06:02:29.220 cmdout 	[Java-Sdk-Automation]           ^
06:02:29.220 cmdout 	[Java-Sdk-Automation] Cannot create property=xmsArmIdDetails for JavaBean=com.microsoft.typespec.http.client.generator.core.extension.model.extensionmodel.XmsExtensions@4288540f
06:02:29.220 cmdout 	[Java-Sdk-Automation]  in 'string', line 19592, column 9:
06:02:29.220 cmdout 	[Java-Sdk-Automation]             x-ms-arm-id-details:
06:02:29.220 cmdout 	[Java-Sdk-Automation]             ^
06:02:29.220 cmdout 	[Java-Sdk-Automation] No suitable constructor with 1 arguments found for class com.microsoft.typespec.http.client.generator.core.extension.model.extensionmodel.XmsArmIdDetails
06:02:29.220 cmdout 	[Java-Sdk-Automation]  in 'string', line 19593, column 11:
06:02:29.220 cmdout 	[Java-Sdk-Automation]               - type: Microsoft.KeyVault/vaults
06:02:29.220 cmdout 	[Java-Sdk-Automation]               ^
06:02:29.220 cmdout 	[Java-Sdk-Automation]  in 'string', line 19592, column 9:
06:02:29.220 cmdout 	[Java-Sdk-Automation]             x-ms-arm-id-details:
06:02:29.221 cmdout 	[Java-Sdk-Automation]             ^
06:02:29.221 cmdout 	[Java-Sdk-Automation]  in 'string', line 19587, column 5:
06:02:29.221 cmdout 	[Java-Sdk-Automation]         - &ref_1500
06:02:29.221 cmdout 	[Java-Sdk-Automation]         ^
06:02:29.221 cmdout 	[Java-Sdk-Automation]  in 'string', line 5, column 3:
06:02:29.221 cmdout 	[Java-Sdk-Automation]       booleans:
06:02:29.221 cmdout 	[Java-Sdk-Automation]       ^

06:02:29.253 cmdout 	[Java-Sdk-Automation] Caused by: org.yaml.snakeyaml.error.YAMLException: No suitable constructor with 1 arguments found for class com.microsoft.typespec.http.client.generator.core.extension.model.extensionmodel.XmsArmIdDetails
06:02:29.253 cmdout 	[Java-Sdk-Automation] 	at org.yaml.snakeyaml.constructor.Constructor$ConstructSequence.construct(Constructor.java:589)
06:02:29.253 cmdout 	[Java-Sdk-Automation] 	at org.yaml.snakeyaml.constructor.BaseConstructor.constructObjectNoCheck(BaseConstructor.java:264)
06:02:29.253 cmdout 	[Java-Sdk-Automation] 	at org.yaml.snakeyaml.constructor.BaseConstructor.constructObject(BaseConstructor.java:247)
06:02:29.253 cmdout 	[Java-Sdk-Automation] 	at org.yaml.snakeyaml.constructor.Constructor$ConstructMapping.constructJavaBean2ndStep(Constructor.java:261)
06:02:29.254 cmdout 	[Java-Sdk-Automation] 	... 46 more
06:02:29.254 cmdout 	[Java-Sdk-Automation] fatal   | Process() cancelled due to failure 
06:02:29.254 cmdout 	[Java-Sdk-Automation] error   |   Error: Plugin fluentgen reported failure.
06:02:29.254 cmdout 	[Java-Sdk-Automation] error   | Autorest completed with an error. If you think the error message is unclear, or is a bug, please declare an issues at https://github.com/Azure/autorest/issues with the error message you are seeing.
06:02:29.285 cmdout 	[Java-Sdk-Automation] 2024-12-17 18:02:29 [ERROR] [GENERATE] Code generation failed.
06:02:29.285 cmdout 	[Java-Sdk-Automation] 2024-12-17 18:02:29 [ERROR] Please first check if the failure happens only to Java automation, or for all SDK automations. If it happens for all SDK automations, please double check your Swagger, and check whether there is errors in ModelValidation and LintDiff. If it happens to Java alone, you can open an issue to https://github.com/Azure/autorest.java/issues. Please include the link of this Pull Request in the issue.
06:02:29.285 cmderr W 	[Java-Sdk-Automation] Traceback (most recent call last):
06:02:29.285 cmderr W 	[Java-Sdk-Automation]   File "/mnt/vss/_work/1/s/azure-sdk-for-java/./eng/automation/generate.py", line 439, in <module>
06:02:29.285 cmderr W 	[Java-Sdk-Automation]     main()
06:02:29.286 cmderr W 	[Java-Sdk-Automation]   File "/mnt/vss/_work/1/s/azure-sdk-for-java/./eng/automation/generate.py", line 350, in main
06:02:29.286 cmderr W 	[Java-Sdk-Automation]     return sdk_automation(args["config"][0], args["config"][1])
06:02:29.287 cmderr W 	[Java-Sdk-Automation]   File "/mnt/vss/_work/1/s/azure-sdk-for-java/./eng/automation/generate.py", line 118, in sdk_automation
06:02:29.287 cmderr W 	[Java-Sdk-Automation]     packages = sdk_automation_autorest(config)
06:02:29.287 cmderr W 	[Java-Sdk-Automation]   File "/mnt/vss/_work/1/s/azure-sdk-for-java/./eng/automation/generate.py", line 207, in sdk_automation_autorest
06:02:29.287 cmderr W 	[Java-Sdk-Automation]     "content": changelog,
06:02:29.287 cmderr W 	[Java-Sdk-Automation] UnboundLocalError: local variable 'changelog' referenced before assignment
06:02:29.303 error C 	Script return with result [failed] code [1] signal [null] cwd [azure-sdk-for-java]: ./eng/automation/generate.py
06:02:29.303 endsection 	Call generateScript
06:02:29.303 warn 	Warning: File azure-sdk-for-java_tmp/generateOutput.json not found to read. Please re-run the pipeline if the error is transitient error or report this issue through https://aka.ms/azsdk/support/specreview-channel.
06:02:29.303 warn 	Warning: Package processing is skipped as the SDK generation fails. Please look into the above generation errors or report this issue through https://aka.ms/azsdk/support/specreview-channel.
06:02:29.305 section 	Report status

Additional context:
link1: https://dev.azure.com/azure-sdk/internal/_build/results?buildId=4417490&view=logs&j=a8a7a537-82b0-583c-7971-bac70b9822ca&t=37e3947b-3cfb-5d36-86ba-0e22bb7dbc33&l=1031
link2: https://dev.azure.com/azure-sdk/internal/_build/results?buildId=4442410&view=logs&j=a8a7a537-82b0-583c-7971-bac70b9822ca&t=37e3947b-3cfb-5d36-86ba-0e22bb7dbc33&l=1034
link3: https://dev.azure.com/azure-sdk/internal/_build/results?buildId=4457362&view=logs&j=a8a7a537-82b0-583c-7971-bac70b9822ca&t=37e3947b-3cfb-5d36-86ba-0e22bb7dbc33&l=1056
link4: https://dev.azure.com/azure-sdk/internal/_build/results?buildId=4469034&view=logs&j=a8a7a537-82b0-583c-7971-bac70b9822ca&t=37e3947b-3cfb-5d36-86ba-0e22bb7dbc33&l=1032
link5: https://dev.azure.com/azure-sdk/internal/_build/results?buildId=4486952&view=logs&j=a8a7a537-82b0-583c-7971-bac70b9822ca&t=37e3947b-3cfb-5d36-86ba-0e22bb7dbc33&l=1030

@wanlwanl
Copy link
Member

@v-hongli1 could you help troubleshoot this issue?

@v-hongli1
Copy link
Member

v-hongli1 commented Jan 21, 2025

@wanlwanl
There are two x-ms-arm-id-details records in CommonDefinitions.json. but the formats of these two records are inconsistent.
L811
Image
L773
Image
According to the error message, I think the format of L811 is wrong.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Backlog
Development

No branches or pull requests

3 participants