Skip to content

New/queries export - #3871

Open
fbuenohernandez wants to merge 6 commits into
pi-hole:developmentfrom
fbuenohernandez:new/queries-export
Open

fbuenohernandez wants to merge 6 commits into
pi-hole:developmentfrom
fbuenohernandez:new/queries-export

Conversation

@fbuenohernandez

Copy link
Copy Markdown

What does this PR aim to accomplish?:

Adds a CSV export option to the Tail Log page (dnsmasq log view), allowing users to download query data within a selected date range without needing shell/SSH access to the Pi.

How does this PR accomplish the above?:

  • Adds an "Export queries" button to the Tail Log header, visible only when viewing the dnsmasq log tab.
  • Adds a modal where the user picks a date range (From/Until) and which columns to include (timestamp, domain, type, status, client IP, client name, reply, reply time, DNSSEC, upstream).
  • Optionally removes duplicate queries (same domain + type, keeping the most recent).
  • Fetches matching queries from the existing /queries API endpoint, paginating with the cursor parameter to handle large result sets.
  • Builds a CSV client-side and triggers a browser download; no server-side changes required.
  • Cancelling the modal (Cancel button, X button, or clicking outside) aborts an export that is still in progress instead of letting it keep running in the background.

Link documentation PRs if any are needed to support this PR:

None — this only adds a UI feature to an existing page, no behavior change requiring doc updates.


  • I have read the above and my PR is ready for review. Check this box to confirm
taillog taillog2 taillog3

Signed-off-by: fbuenohernandez <fbuenohernandez@users.noreply.github.com>
Signed-off-by: fbuenohernandez <132588231+fbuenohernandez@users.noreply.github.com>
@fbuenohernandez
fbuenohernandez requested a review from a team as a code owner September 19, 2026 16:59
Signed-off-by: fbuenohernandez <132588231+fbuenohernandez@users.noreply.github.com>
Signed-off-by: fbuenohernandez <132588231+fbuenohernandez@users.noreply.github.com>
Signed-off-by: fbuenohernandez <132588231+fbuenohernandez@users.noreply.github.com>
Signed-off-by: fbuenohernandez <132588231+fbuenohernandez@users.noreply.github.com>
@rdwebdesign

Copy link
Copy Markdown
Member

DCO test is still failing. The test details says you used the wrong e-mail on the first commit:

image

And the commit really shows a different e-mail address:

image

If DCO is missing/failing in one commit, the test will fail for the whole PR. You could try to edit that commit message and force push.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants