Skip to content

Conversation

@michael-smith-nz
Copy link
Contributor

👋
This PR fixes the ArgumentError: wrong number of arguments (given 3, expected 2) issue when calling rename_table with the migration version 7.0 and below.

It looks like ActiveRecord is expecting rename_table to include options as a parameter when calling super here

@yahonda
Copy link
Collaborator

yahonda commented Jun 13, 2025

Related to rails/rails#45136

@yahonda yahonda merged commit c21146a into rsim:master Jun 13, 2025
13 checks passed
yahonda added a commit to yahonda/oracle-enhanced that referenced this pull request Jun 13, 2025
…ompat

Fix rename_table for compatibility migrations
yahonda added a commit that referenced this pull request Jun 13, 2025
Merge pull request #2418 from michael-smith-nz/fix_rename_table_compat
yahonda added a commit to yahonda/oracle-enhanced that referenced this pull request Jun 23, 2025
This commit suppresses the following migration standard output.

```ruby
$ bundle exec rspec spec/active_record/connection_adapters/oracle_enhanced/compatibility_spec.rb:21
==> Loading config from ENV or use default
==> Running specs with ruby version 3.4.4
==> Effective ActiveRecord version 8.0.2
Run options: include {locations: {"./spec/active_record/connection_adapters/oracle_enhanced/compatibility_spec.rb" => [21]}}
==  : migrating ===============================================================
-- rename_table(:test_employees, :new_test_employees)
   -> 0.2045s
==  : migrated (0.2045s) ======================================================

==  : reverting ===============================================================
-- rename_table(:new_test_employees, :test_employees)
   -> 0.2033s
==  : reverted (0.2046s) ======================================================

.

Finished in 0.68775 seconds (files took 0.34644 seconds to load)
1 example, 0 failures

$
```

Follow up rsim#2418
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