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

[dlang] Support extention objects in arrays and the default field #825

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

tom-tan
Copy link
Member

@tom-tan tom-tan commented May 14, 2024

This request contains the following improvements to dlang codegen.

[Implemented] Support extension objects in arrays

The current dlang code-generated parser rejects the extension objects such as cwltool:CUDARequirement in the requirement field. This request is to accept such extension objects in parser level.

Note: Extension fields such as https://schema.org/name as explained in the user guide are already supported in schema-salad-d level without changing dlang codegen.

[Not yet] Support the default field

The current dlang codegen ignores the default field. Therefore schema-salad-d cannot generate the code to set the default value from the declaration. This request is to fix this issue by adding the @defalultValue attribute to the generated field declarations.

Copy link

codecov bot commented May 14, 2024

Codecov Report

Attention: Patch coverage is 91.66667% with 2 lines in your changes are missing coverage. Please review.

Project coverage is 83.38%. Comparing base (74a5ba5) to head (9ba4f9a).
Report is 8 commits behind head on main.

Files Patch % Lines
schema_salad/dlang_codegen.py 91.66% 1 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #825      +/-   ##
==========================================
+ Coverage   83.35%   83.38%   +0.02%     
==========================================
  Files          22       22              
  Lines        4818     4838      +20     
  Branches     1303     1310       +7     
==========================================
+ Hits         4016     4034      +18     
- Misses        527      528       +1     
- Partials      275      276       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

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.

None yet

1 participant