Quote SQLite table identifiers in DBI column_info PRAGMA
Mantenedores costumam responder em até 1 dia
Ninguém assumiu esta issue ainda.
Avaliação
- Dificuldade
- 2/5
- Tempo estimado
- 1-3 horas
- Facilidade para iniciantes
- 84/100
Direção de pesquisa
Comece em src/main/java/org/perlonjava/runtime/perlmodule/DBI.java, em columnInfoViaPragma, e depois reproduza a falha com os testes do SQLite t/13-init.t, t/14-smart-accessors.t e t/15-sql-row.t. O trabalho está concluído quando column_info retornar metadados para uma tabela chamada order sem um erro de sintaxe do SQLite; o defeito separado relacionado a active-flag é acompanhado em #1604.
Escrita pelo modelo de indexação a partir do texto da issue.
Descrição
Summary
PerlOnJava's SQLite-specific DBI.column_info constructs PRAGMA table_info($table) without quoting the table identifier. A table named order therefore produces PRAGMA table_info(order), which SQLite rejects because order is a reserved word.
ActiveRecord::Simple 1.11 creates and introspects an order table in its SQLite tests. The metadata call fails, and its caller then attempts fetchall_arrayref on the undefined result, aborting t/13-init.t, t/14-smart-accessors.t, and t/15-sql-row.t before those tests emit TAP.
Evidence
- CPAN random tester run:
20261002-084902-54310 - Distribution/version:
ActiveRecord::Simple1.11 - System Perl 5.42.2 on macOS 26.6.2 arm64: all 16 test files passed (206 tests).
- PerlOnJava 5.44.1, build
f25d551c1, Java 24.0.2 on macOS 26.6.2 arm64: the SQLite metadata error reproduces on both JVM and interpreter backends. - Diagnostic:
DBI column_info failed: near "order": syntax error, followed by an attempt to callfetchall_arrayrefon an undefined value.
Suspected cause
columnInfoViaPragma in src/main/java/org/perlonjava/runtime/perlmodule/DBI.java concatenates the table name directly into PRAGMA table_info(...). It should use SQLite-safe identifier quoting (or another metadata approach that safely handles reserved names).
Expected result
column_info should return metadata for valid SQLite table names, including reserved words such as order, without SQL syntax errors.
A separate missing-active-flag defect in the synthetic column_info statement handle breaks accessor discovery and is tracked in #1604.
- Linguagem predominante
- Perl
- Estrelas
- 64
- Forks
- 8
- Merge médio
- 5h 42min
- PRs com merge (30d)
- 205
Preparar o ambiente
- Inclui um Dockerfile ou arquivo Docker Compose
- Sem modelo de pull request
- Ler o guia de contribuição
Primeiros passos
- Leia a issue inteira e depois o guia de contribuição do projeto.
- Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
- Faça um fork do repositório e trabalhe em uma branch.
- Abra um pull request que referencie o número da issue.
Mais de fglock/PerlOnJava
-
bug
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 72/100
fglock/PerlOnJava#1579 ·
Mantenedores costumam responder em até 1 dia
-
perf: achieve measured 1:1 standard Perl throughput after #1850Talvez já em andamento Um pull request vinculado a esta issue está aberto ou já foi mesclado. Aberta
Dificuldade 5/5 Mais de uma semana Facilidade para iniciantes 20/100
fglock/PerlOnJava#1863 · 1 comentário ·
Mantenedores costumam responder em até 1 dia
-
area:memory area:performance area:runtime bug
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 52/100
fglock/PerlOnJava#1860 ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 5/5 Mais de uma semana Facilidade para iniciantes 38/100
fglock/PerlOnJava#1854 ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 3/5 1-2 dias Facilidade para iniciantes 56/100
fglock/PerlOnJava#1851 ·
Mantenedores costumam responder em até 1 dia
Todas as issues de fglock/PerlOnJava
Issues semelhantes
-
observablt-ci
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 86/100
elastic/golang-crossbuild#840 ·
Mantenedores costumam responder em até 1 dia
-
Sync playback crashes repeatedly in a sync group (v9.1.1)Talvez já em andamento Um pull request vinculado a esta issue está aberto ou já foi mesclado. Aberta
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 68/100
LMS-Community/slimserver#1701 · 6 comentários ·
Mantenedores costumam responder em até 1 dia
-
bug
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 72/100
RotherOSS/otobo#6286 · 1 comentário ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 76/100
-
fix(api): API v3 Product Read ignores request language (lc) for sample products and image URLsTalvez já em andamento @muntasir-396 assumiu há 4 dias. Aberta
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 88/100
openfoodfacts/openfoodfacts-server#15042 · 1 comentário ·
Mantenedores costumam responder em até 1 dia