Skip to content

chore: update googleapis SHA circa 20260514#16102

Open
scotthart wants to merge 6 commits into
googleapis:mainfrom
scotthart:renovate_20260514
Open

chore: update googleapis SHA circa 20260514#16102
scotthart wants to merge 6 commits into
googleapis:mainfrom
scotthart:renovate_20260514

Conversation

@scotthart
Copy link
Copy Markdown
Member

One of the updated protos had an example comment containing the $ character which broke the generator. Added code to sanitize the comments by changing any $ to $$, which escapes it.

@scotthart scotthart requested a review from a team as a code owner May 18, 2026 15:11
Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request updates several Google Cloud C++ client libraries, including the Data Lineage, Dataproc, Memorystore, Redis Cluster, Spanner, and Support APIs. Key changes involve updating the googleapis dependency version, refreshing documentation links, and adding new RPC methods such as SearchLineageStreaming and GetAttachment/GetComment. The reviewer identified that the request_id generation logic in lineage_connection_impl.cc is duplicated and should be refactored into a private helper method to align with the repository's style guide.

Comment on lines +83 to +86
auto request_copy = request;
if (request_copy.request_id().empty()) {
request_copy.set_request_id(invocation_id_generator_->MakeInvocationId());
}
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

This logic for ensuring a request_id is present is duplicated five times in this file (lines 83-86, 103-106, 124-127, 290-293, and 465-468). Following the repository style guide, this should be factored out into a private helper method to improve maintainability and reduce code duplication.

References
  1. The repository prefers to factor out duplicated code if it appears 3 or more times in non-test files. (link)

}
std::string doxygen_formatted_function_comments =
method_source_location.leading_comments;
absl::StrReplaceAll({{"$", "$$"}}, &doxygen_formatted_function_comments);
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.

Why not make this a member of substitutions?

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.

This felt more like a "good practice" to always sanitize the input to escape a known problematic character. substitutions typically contain problematic strings that we couldn't anticipate and have to add post breakage. I also wanted the sanitization to occur before we applied substitutions, which could be enforced by making it the first substitution, but that would require future updates to be mindful of.

@codecov
Copy link
Copy Markdown

codecov Bot commented May 18, 2026

Codecov Report

❌ Patch coverage is 2.94118% with 33 lines in your changes missing coverage. Please review.
✅ Project coverage is 92.69%. Comparing base (cf931ff) to head (2b58cef).

Files with missing lines Patch % Lines
...loud/spanner/internal/spanner_logging_decorator.cc 0.00% 10 Missing ⚠️
...gle/cloud/spanner/internal/spanner_tracing_stub.cc 0.00% 8 Missing ⚠️
...e/cloud/spanner/internal/spanner_auth_decorator.cc 0.00% 5 Missing ⚠️
...oud/spanner/internal/spanner_metadata_decorator.cc 0.00% 5 Missing ⚠️
google/cloud/spanner/internal/spanner_stub.cc 0.00% 4 Missing ⚠️
google/cloud/spanner/testing/mock_spanner_stub.h 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main   #16102      +/-   ##
==========================================
- Coverage   92.70%   92.69%   -0.01%     
==========================================
  Files        2353     2353              
  Lines      218354   218388      +34     
==========================================
+ Hits       202419   202434      +15     
- Misses      15935    15954      +19     

☔ 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.

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.

2 participants