Skip to content

fix yaml archives for conformance#1206

Open
theganyo wants to merge 11 commits into
apigee:mainfrom
theganyo:theganyo/issue1203
Open

fix yaml archives for conformance#1206
theganyo wants to merge 11 commits into
apigee:mainfrom
theganyo:theganyo/issue1203

Conversation

@theganyo
Copy link
Copy Markdown
Member

@theganyo theganyo commented Jun 26, 2023

Fixes #1203

  • Use Artifact id for conformance workers instead of stylesheet id
  • Simplify artifact patching behavior
  • Remove unnecessary structure test

@theganyo theganyo requested a review from timburks June 26, 2023 23:03
@codecov
Copy link
Copy Markdown

codecov Bot commented Jun 26, 2023

Codecov Report

❌ Patch coverage is 68.18182% with 7 lines in your changes missing coverage. Please review.
✅ Project coverage is 71.91%. Comparing base (76ddac3) to head (06653c8).
⚠️ Report is 11 commits behind head on main.

Files with missing lines Patch % Lines
cmd/registry/patch/artifact.go 76.47% 3 Missing and 1 partial ⚠️
...md/registry/cmd/compute/conformance/conformance.go 40.00% 2 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1206      +/-   ##
==========================================
- Coverage   71.96%   71.91%   -0.06%     
==========================================
  Files         146      146              
  Lines       12241    12208      -33     
==========================================
- Hits         8809     8779      -30     
+ Misses       2749     2747       -2     
+ Partials      683      682       -1     

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

}

// populateIdAndKind inserts the "id" and "kind" fields in the supplied json bytes.
func populateIdAndKind(bytes []byte, kind, id string) ([]byte, error) {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this will break API hub, which currently reads proto-serialized artifacts and expects them to contain "kind" and "id" fields. Since these fields are redundant in Registry YAML, I don't think we should be including them in YAML-serialized artifacts and I expect that API hub will adapt to that when it starts reading those YAML-serialized artifacts.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's unfortunate. So I need to add this back for protos?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually, this PR isn't critical until we go all in on yaml...perhaps we should hold it until we correct API Hub.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Inbox

Development

Successfully merging this pull request may close these issues.

Registry tool: ensure yaml archive storage works across all tests

2 participants