Uncomment the case-insensitive SQLite table spec once rails/rails#59671 is merged
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 2/5
- Tempo stimato
- 1-3 ore
- Idoneità per principianti
- 68/100
Direzione di ricerca
Leggi spec/ransack/active_record/context_spec.rb e verifica se rails/rails#59671 è stato integrato e se il job rails-main è verde su Ransack main. Poi rimuovi i commenti dalla spec «a table whose name differs only in case» e conferma che rails-main rimane verde; queste verifiche definiscono il completamento.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
The spec "a table whose name differs only in case" in spec/ransack/active_record/context_spec.rb (#1770) is commented out, because it fails on Rails main and nothing in Ransack can fix it.
Why it fails
Rails commit rails/rails@2cb3daba96, on main only, made the SQLite adapter read table structures in one batched query. That query selects tables with m.name IN (...), which matches names exactly. The PRAGMA table_info reads it replaced matched them the way SQLite does, ignoring ASCII case. A model whose table_name is widgets can no longer read a table created as Widgets, so the spec fails at Widget.create!, before any Ransack code runs:
ActiveRecord::StatementInvalid:
Could not find table 'widgets'
The spec passes on Rails 8.1. It is commented out so that the rails-main job (#1797) is green and shows only new breaks.
Upstream fix
rails/rails#59671 matches table names with COLLATE NOCASE again, and cites this spec. It is stacked on rails/rails#59668, which merges first.
To close this issue
- rails/rails#59671 is merged
- the
rails-mainjob is green on Ransackmain - uncomment the spec and confirm that
rails-mainstays green
- Lingua principale
- Ruby
- Stelle
- 5.9k
- Fork
- 821
- Merge medio
- 23h 45m
- PR unite (30g)
- 36
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Ha un modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
rubys/roundhouse#1950 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 64/100
I maintainer di solito rispondono entro 1 giorno
-
`Time.at(t, in: nil)` returns UTC instead of the local time (or the time zone of `t`), unlike CRubyAperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100