nextcloud / nextcloud/user_usage_report
Inconsistent results for user quota when using `default_quota`
Nobody has claimed this yet.
- Dominant language
- PHP
- Stars
- 45
- Forks
- 12
- Avg merge
- 13h 25m
- Merged PRs (30d)
- 19
Description
Steps to reproduce
- Give a value to
default_quotain the server, ex "1 GB" - Have user
user1assigned the value ofdefault_quota. Verify it too by checkinguser1settings page. - Run:
Case 1:
# occ usage-report:generate --output=json user1 | jq .quota`
0
Case 2:
# occ usage-report:generate --output=json | grep user1 | jq .quota`
"1 GB"
Expected behaviour
The field quota should be always an integer number and consistent.
Actual behaviour
The field quota is wrong (case 1) and a string (case 2). Manually assigning the user the same value as default_quota fixes the issue.
Server configuration
Nextcloud version: 27.1.5
user_usage_report: 1.11.1
Where did you install Nextcloud from: normal installer
List of activated apps:
Nextcloud configuration:
Client configuration
Logs
Nextcloud log (data/nextcloud.log)
Browser log
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 with the occ usage-report:generate --output=json entry point and trace how quota is calculated for a named user versus the bulk report, especially when default_quota is inherited. Reproduce both commands with a user assigned the server default, then verify that quota is consistently emitted as an integer in both outputs.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- php
- Domain
- backend, cli
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100