[Bug]: After update 33.0.2 → 33.0.3, occ upgrade does not populate new MIME types — files download instead of opening in viewer
Nobody has claimed this yet.
- Dominant language
- PHP
- Stars
- 36.9k
- Forks
- 5.2k
- Avg merge
- 2d 3h
- Merged PRs (30d)
- 713
Description
Steps to reproduce
- Update Nextcloud from 33.0.2 to 33.0.3 via
occ upgrade - Open any Office file (.docx, .xlsx, .pptx, .odt, etc.) in the Files app
Expected behavior
File opens in Nextcloud Office (richdocuments/Collabora)
Actual behavior
Browser immediately triggers a download dialog. Files are downloaded instead of opened.
Fix
Manually running the following commands resolves the issue:
php occ maintenance:mimetype:update-db
php occ maintenance:mimetype:update-js
Output: "Added 88 new mimetypes" — all missing after the 33.0.2 → 33.0.3 update.
Environment
Nextcloud: 33.0.2 → 33.0.3
richdocuments (Collabora): 10.1.3
viewer: 6.0.0
PHP OPcache: enabled (Apache)
DB: MySQL
Root cause
occ upgrade does not call maintenance:mimetype:update-db during the
33.0.2 → 33.0.3 patch migration. New MIME types added to mimetypemapping.json
in 33.0.3 are never written to the oc_mimetypes table, so Nextcloud cannot
route file opens to the correct viewer app — it falls back to a browser download.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing the occ upgrade path for the 33.0.2 to 33.0.3 migration, then compare it with maintenance:mimetype:update-db and the entries in mimetypemapping.json. Check the oc_mimetypes table before and after the upgrade. Done means the new MIME types are populated automatically and Office files open in the viewer instead of downloading.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- mysql, php
- Domain
- backend, databases
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 56/100