Skip to content

fix(bigquery): Avoid method redefinition warnings on require - #36649

Merged
quartzmo merged 1 commit into
googleapis:mainfrom
milkcocoa:fix/bigquery-column-redefinition-warnings
Oct 21, 2026
Merged

quartzmo merged 1 commit into
googleapis:mainfrom
milkcocoa:fix/bigquery-column-redefinition-warnings

Conversation

@milkcocoa

Copy link
Copy Markdown
Contributor

Requiring google-cloud-bigquery with warnings enabled emits 28 diagnostic lines because BigtableSource::Column is defined in both column.rb and column_family.rb.

Remove the duplicate class and documentation from column_family.rb, retaining its existing require of column.rb.

Validation (Ruby 4.0.7, Linux aarch64):

  • The warning-enabled require produces no output after the fix, compared with 28 diagnostic lines before it.
  • bundle exec rake test: 1,433 runs, 10,788 assertions, no failures or errors.
  • RuboCop: 106 files inspected, no offenses. YARD generation passes.
  • Local bundle exec rake ci reaches doctests but does not pass: 459 errors and 11 skips also occur on the unmodified baseline. Comparing test names and error messages (normalizing generated object IDs and UUIDs) found no new error cases. Unit tests were also run separately because the CI task stops at doctests.
  • Live API acceptance tests were not run.

Closes: #36647

Requiring the gem with warnings enabled redefines BigtableSource::Column
because column_family.rb contains a copy of the class already required
from column.rb. Remove the duplicate definition to eliminate the warnings.

closes: googleapis#36647
@quartzmo quartzmo added api: bigquery Issues related to the BigQuery API. kokoro:force-run Add this label to force Kokoro to re-run the tests. labels Oct 21, 2026
@yoshi-kokoro yoshi-kokoro removed the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Oct 21, 2026
@quartzmo
quartzmo merged commit 1373baf into googleapis:main Oct 21, 2026
19 of 20 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

api: bigquery Issues related to the BigQuery API.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

bigquery: Requiring the gem emits method redefinition warnings for BigtableSource::Column

4 participants