Repository navigation
fix(import): import preview rows use source_row, row_number is reserved on MariaDB - #5879
Merged
Merged
Conversation
…ed on MariaDB Enabling the app on MariaDB 11.4 failed with error 1064: Doctrine leaves row_number unquoted there. Version1Date20260915050000 now creates source_row. Version1Date20261106080000 renames the column on installs that already hold it, with one quoted RENAME COLUMN, so their rows and the unique index stay. The version moves with it, or occ upgrade would not read the new step. The API is unchanged: rows are still answered under the key row. Assisted-by: ClaudeCode:claude-opus-5-5
…view-row-column # Conflicts: # appinfo/info.xml
Assisted-by: ClaudeCode:claude-opus-5-5
This was referenced Nov 6, 2026
Contributor
Quality Report — ConductionNL/openregister @
|
| Check | PHP | Vue | Security | License | Tests |
|---|---|---|---|---|---|
| lint | ✅ | ||||
| phpcs | ✅ | ||||
| phpmd | ❌ | ||||
| psalm | ❌ | ||||
| phpstan | ❌ | ||||
| phpmetrics | ✅ | ||||
| eslint | ❌ | ||||
| stylelint | ✅ | ||||
| build | ✅ | ||||
| check-specs | ✅ | ||||
| test-l10n | ❌ | ||||
| test-l10n-parity | ✅ | ||||
| check-schema-l10n | ✅ | ||||
| composer | ✅ | ✅ 165/165 | |||
| npm | ✅ | ✅ 640/640 | |||
| app:check-code | ⏭️ | ||||
| info.xml | ✅ | ||||
| REUSE | ✅ | ||||
| lockfile sync | ✅ | ||||
| PHPUnit | ❌ 34600/34602 · 18 skipped | ||||
| Newman | ❌ 1628/1630 | ||||
| Playwright | ⏭️ deferred: E2E runs locally and on the promotion path only. This pull request targets development, so the suite is asked once per promotion into beta and main rather than once per push per open pull request. Run it locally with npx playwright test, or from the Actions tab on a branch with no open pull request into development. |
||||
| Hydra gates | ❌ |
Quality workflow — 2026-11-06 08:55 UTC
Download the full PDF report from the workflow artifacts.
WilcoLouwerse
added a commit
that referenced
this pull request
Nov 6, 2026
…5879) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This was referenced Nov 6, 2026
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
A fresh
occ app:enable openregisterfails on MariaDB 11.4 with error 1064 atrow_number INT UNSIGNED. Doctrine only quotes words on its keyword list, and that list does not holdROW_NUMBERfor MariaDB. The failed enable leaves 106 tables and no rows inoc_migrations.The change
Version1Date20260915050000createssource_row. A fresh install runs Nextcloud's schema-only path, which skips pre and post steps, so this edit is what fixes it.Version1Date20261106120000is new. On an install that still holdsrow_numberit runs one quotedALTER TABLE ... RENAME COLUMN. Rows andidx_or_improw_uniquestay. It does nothing when the column is already gone.ImportPreviewRow::$rowNumberbecomes$sourceRow, and the mapper sorts onsource_row.<version>moves to2.1.35-unstable.20261106120000. Without that,occ upgradedoes not read the new step.The API does not change: a row is still answered under the key
row.Who is affected
mainnever held the migration, so stable installs are not touched.row_number, the local :8080 instance among them. The follow-up renames it on upgrade.Verified on real databases
Nextcloud 34, throwaway containers, MariaDB 11.4.13 and PostgreSQL 16. Each case checked the column, the unique index, the
oc_migrationsrow, and a real write and read through the mapper.occ upgradesource_rowrow_number, thenocc upgradeThat last MariaDB install was made by restoring the old column by hand, because the old code cannot install there. It stands for an install that ran the migration on an older MariaDB and moved to 11.4.
Not tested: MySQL, because no image is on this machine. Nextcloud 32, 33 and 35 were not run either.
Unit tests: the new migration test,
tests/Unit/Db,tests/Unit/Service/Importand the preview controller test under pcov, 3352 tests, 0 failures. Capped mutants on the migration: 5 of 5 killed. phpcs, phpmd, phpstan and psalm clean on touched files.check-migration-version-bump: OK. Gate 119: 0.Full suite
Full PHPUnit under pcov with
--fail-on-riskythrough heavy.sh, on combinedb193646ed(#5879, #5882, #5883 and #5887 on development47f5021b9): 34640 tests, 1 failure, 34 risky. The failure is inherited:CalculationEvaluatorGoldenTestrecords a literal tomorrow fordateAdd bad date, so it goes red on any later day, and this tree touches no calculation file. The 34 risky are the 18 inherited plus 16 inObjectsControllerGeoRoutesGoldenTest, also on development.Rerun on this head
cbc50fe24, MariaDB 11.4.13: development still fails with 1064; retry on that failed install, a fresh enable, andocc upgradefromrow_numberwith 3 rows all pass. PostgreSQL 16 ran on the same migration before that: upgrade from the old code with 3 rows, and a fresh enable.🤖 Generated with Claude Code