jcoffey-dev is traveling from Thursday 1 October through Sunday 4 October. Issues and pull requests are welcome, and will get an answer after that. Thanks for your patience.
The Logs page read "Showing 1-2 of 5000" for a two-line log.
The cause:log_query built its response with the query cap (query_max_results, 5000) as the total, so calculateTotal always answered 5000.
The fix: the total is only known without extra work when the first page reaches the end of the logs. Then it's exact. Past the first page, or when there are more entries than the limit, the total is left out; counting would mean reading every log file on every page. An empty log now answers 0.
Checked: against a local server with a log tracer:
5 entries with limit 50 gives ids 5, total 5;
limit 3 gives ids 3, no total;
an empty log gives total 0.
The console change that pages without a total is the admin PR that follows.
The Logs page read "Showing 1-2 of 5000" for a two-line log.
**The cause:** `log_query` built its response with the query cap (`query_max_results`, 5000) as the total, so `calculateTotal` always answered 5000.
**The fix:** the total is only known without extra work when the first page reaches the end of the logs. Then it's exact. Past the first page, or when there are more entries than the limit, the total is left out; counting would mean reading every log file on every page. An empty log now answers 0.
**Checked:** against a local server with a log tracer:
- 5 entries with limit 50 gives ids 5, total 5;
- limit 3 gives ids 3, no total;
- an empty log gives total 0.
The console change that pages without a total is the admin PR that follows.
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
The Logs page read "Showing 1-2 of 5000" for a two-line log.
The cause:
log_querybuilt its response with the query cap (query_max_results, 5000) as the total, socalculateTotalalways answered 5000.The fix: the total is only known without extra work when the first page reaches the end of the logs. Then it's exact. Past the first page, or when there are more entries than the limit, the total is left out; counting would mean reading every log file on every page. An empty log now answers 0.
Checked: against a local server with a log tracer:
The console change that pages without a total is the admin PR that follows.