You need to sign in or sign up before continuing.
Follow-up from "Fix bug where create MR toggle wasn't inspected correctly"
The following discussion from !139047 (merged) should be addressed:
-
@schin1 started a discussion:
Looking at !139047 (comment 1703639433), I think perhaps we could follow-up in a separate issue regarding
ActiveModel::Type::Boolean.new.cast
vsGitlab::Utils.to_boolean
.➜ gitlab git:(sc1-buffered-counter-migrate) ✗ rg ActiveModel::Type::Boolean ee/spec/support/llm.rb 5: real_ai_request_bool = ActiveModel::Type::Boolean.new.cast(ENV['REAL_AI_REQUEST']) ee/app/models/concerns/identity_verifiable.rb 93: ActiveModel::Type::Boolean.new.cast(phone_number_exemption_attribute.value) app/models/concerns/cascading_namespace_setting_attribute.rb 259: ActiveModel::Type::Boolean.new.cast(value)
I see only 4 instances (inclusive of this) where
ActiveModel::Type::Boolean.new
so perhaps the issue could target the entire project as to whether we should favourGitlab::Utils.to_boolean
overActiveModel::Type::Boolean
.This is not blocking so as they are both functionally correct and battle-tested (one in Rails and one in GitLab) I'm setting auto-merge.