Disable supports_expression_index unconditionally#250
Disable supports_expression_index unconditionally#250ecwall merged 2 commits intocockroachdb:masterfrom ecwall:disable_supports_expression_index
Conversation
|
|
||
| def supports_expression_index? | ||
| @crdb_version >= 2122 | ||
| # Expression indexes are partially supported by CockroachDB v21.2, |
There was a problem hiding this comment.
if we do support it partially, then i would argue we should skip the test instead, or add a new condition for ON CONFLICT support and use that to skip the test / anything relevant in the ORM
otherwise, is this is a "regression" in ORM behaviour?
There was a problem hiding this comment.
Moved this to disable supports_insert_conflict_target? instead.
There was a problem hiding this comment.
we didn't need the public_send stuff right?
There was a problem hiding this comment.
It looks like it is already there for the ones I overrode.
%w[
supports_savepoints?
supports_partial_index?
supports_partitioned_indexes?
supports_expression_index?
supports_insert_returning?
supports_insert_on_duplicate_skip?
supports_insert_on_duplicate_update?
supports_insert_conflict_target?
supports_optimizer_hints?
supports_datetime_with_precision?
].each do |method_name|
define_method method_name do
ActiveRecord::Base.connection.public_send(method_name)
end
end
There was a problem hiding this comment.
does this mean it will also disable ON CONFLICT column_name?
There was a problem hiding this comment.
Yeah it looks like there is no way to say we support expression indexes and ON CONFLICT column_name, but not ON CONFLICT expression without modifying activerecord itself.
hmm, this failure seems suspicious |
Yeah it looks like I also had to disable However |
fixes cockroachdb/cockroach#67893 fixes cockroachdb/cockroach#80777 These can be enabled when CockroachDB supports "ON CONFLICT expression". refs cockroachdb/cockroach#67893
fixes cockroachdb/cockroach#67893
fixes cockroachdb/cockroach#80777
These can be enabled when CockroachDB supports "ON CONFLICT expression"
refs cockroachdb/cockroach#67893