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

feat: make json-ld expansion fails if titanium returns empty result #3192

Merged

Conversation

ndr-brt
Copy link
Member

@ndr-brt ndr-brt commented Jun 16, 2023

What this PR changes/adds

Make TitaniumJsonLd expansion fails if the result is empty (that usually happens when there are no expanded properties, e.g. when there are no namespaced properties withouth the @context property set).

It also fix a nit that avoided the validator to work correctly on the update method

Why it does that

improve error messages

Further notes

Linked Issue(s)

Closes #3172

Please be sure to take a look at the contributing guidelines and our etiquette for pull requests.

@ndr-brt ndr-brt added enhancement New feature or request api Feature related to the (REST) api labels Jun 16, 2023
@ndr-brt ndr-brt requested a review from jimmarino June 16, 2023 13:19
@ndr-brt ndr-brt force-pushed the 3172-validate-jsonld-context branch from 1674941 to 5e803bc Compare June 19, 2023 05:50
@codecov-commenter
Copy link

codecov-commenter commented Jun 19, 2023

Codecov Report

Patch coverage: 100.00% and project coverage change: +0.07 🎉

Comparison is base (abf2443) 65.35% compared to head (7afecbe) 65.43%.

❗ Your organization is not using the GitHub App Integration. As a result you may experience degraded service beginning May 15th. Please install the Github App Integration for your organization. Read more.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3192      +/-   ##
==========================================
+ Coverage   65.35%   65.43%   +0.07%     
==========================================
  Files         835      835              
  Lines       16794    16800       +6     
  Branches      925      925              
==========================================
+ Hits        10976    10993      +17     
+ Misses       5449     5439      -10     
+ Partials      369      368       -1     
Impacted Files Coverage Δ
...in/java/org/eclipse/edc/jsonld/TitaniumJsonLd.java 93.10% <100.00%> (ø)
...nector/api/management/asset/AssetApiExtension.java 90.90% <100.00%> (+90.90%) ⬆️
...ement/asset/validation/AssetEntryDtoValidator.java 86.95% <100.00%> (+3.62%) ⬆️

... and 3 files with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@ndr-brt ndr-brt force-pushed the 3172-validate-jsonld-context branch from 5e803bc to 7afecbe Compare June 19, 2023 06:15
@ndr-brt ndr-brt merged commit ee3f8de into eclipse-edc:main Jun 19, 2023
22 checks passed
@ndr-brt ndr-brt deleted the 3172-validate-jsonld-context branch June 19, 2023 06:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api Feature related to the (REST) api enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

management API : Cannot retrieve asset after updating its properties
4 participants