Skip to content

Commit f0c1563

Browse files
chore: Fix release matching directories (#1728)
* chore: Fix release matching directories HTTP / HTTPX SQL / Sql Obfuscation + Sql Processors All these gems match on the substring and cause toys to initiate releases when changes have not been made to accidentally matching gems. Adding a / should fix the match problem. * Apply suggestions from code review Co-authored-by: Sander Jans <[email protected]> --------- Co-authored-by: Sander Jans <[email protected]>
1 parent 3ae8c88 commit f0c1563

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

.toys/.data/releases.yml

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,11 @@ gems:
3939
version_constant: [OpenTelemetry, Instrumentation, ActiveStorage, VERSION]
4040

4141
- name: opentelemetry-helpers-sql
42-
directory: helpers/sql
42+
# we append a slash here to avoid the naive substring start_with? directory-matching condition in underlying toys gem
43+
# which causes helpers/sql to incorrectly match when changes occur in helpers/sql-processor or helpers/sql-obfuscation
44+
# https://github.com/dazuma/toys/blob/17ed449da8299f272b834470ff6b279a59e8070b/.toys/release/.lib/release_utils.rb#L436
45+
# https://github.com/open-telemetry/opentelemetry-ruby-contrib/pull/1727
46+
directory: helpers/sql/
4347
version_constant: [OpenTelemetry, Helpers, Sql, VERSION]
4448

4549
- name: opentelemetry-instrumentation-gruf
@@ -138,7 +142,11 @@ gems:
138142
version_constant: [OpenTelemetry, Instrumentation, LMDB, VERSION]
139143

140144
- name: opentelemetry-instrumentation-http
141-
directory: instrumentation/http
145+
# we append a slash here to avoid the naive substring start_with? directory-matching condition in underlying toys gem
146+
# which causes instrumentation/http to incorrectly match when changes occur in instrumentation/httpx
147+
# https://github.com/dazuma/toys/blob/17ed449da8299f272b834470ff6b279a59e8070b/.toys/release/.lib/release_utils.rb#L436
148+
# https://github.com/open-telemetry/opentelemetry-ruby-contrib/issues/1512
149+
directory: instrumentation/http/
142150
version_constant: [OpenTelemetry, Instrumentation, HTTP, VERSION]
143151

144152
- name: opentelemetry-instrumentation-graphql

0 commit comments

Comments
 (0)