Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release v1.5.1 #821

Merged
merged 3 commits into from
Nov 18, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
## Changes in 1.5.1

### Fixes

* Stop memoizing schema_columns_hash so dynamic schema changes are picked up. Thanks to @koshigoe via \##812.

## Changes in 1.5.0

### New Features
Expand Down
2 changes: 1 addition & 1 deletion lib/activerecord-import/version.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,6 @@

module ActiveRecord
module Import
VERSION = "1.5.0"
VERSION = "1.5.1"
end
end
2 changes: 1 addition & 1 deletion test/models/book.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

class Book < ActiveRecord::Base
belongs_to :topic, inverse_of: :books
belongs_to :tag, foreign_key: [:tag_id, :parent_id]
belongs_to :tag, foreign_key: [:tag_id, :parent_id] unless ENV["SKIP_COMPOSITE_PK"]

has_many :chapters, inverse_of: :book
has_many :discounts, as: :discountable
Expand Down
10 changes: 6 additions & 4 deletions test/models/customer.rb
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
# frozen_string_literal: true

class Customer < ActiveRecord::Base
has_many :orders,
inverse_of: :customer,
primary_key: %i(account_id id),
foreign_key: %i(account_id customer_id)
unless ENV["SKIP_COMPOSITE_PK"]
has_many :orders,
inverse_of: :customer,
primary_key: %i(account_id id),
foreign_key: %i(account_id customer_id)
end
end
10 changes: 6 additions & 4 deletions test/models/order.rb
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
# frozen_string_literal: true

class Order < ActiveRecord::Base
belongs_to :customer,
inverse_of: :orders,
primary_key: %i(account_id id),
foreign_key: %i(account_id customer_id)
unless ENV["SKIP_COMPOSITE_PK"]
belongs_to :customer,
inverse_of: :orders,
primary_key: %i(account_id id),
foreign_key: %i(account_id customer_id)
end
end
4 changes: 3 additions & 1 deletion test/models/tag_alias.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# frozen_string_literal: true

class TagAlias < ActiveRecord::Base
belongs_to :tag, foreign_key: [:tag_id, :parent_id], required: true
unless ENV["SKIP_COMPOSITE_PK"]
belongs_to :tag, foreign_key: [:tag_id, :parent_id], required: true
end
end