Skip to content

Comments

feat(dnf): add read-only dnf tools and list output limits#264

Open
Albe83 wants to merge 3 commits intorhel-lightspeed:mainfrom
Albe83:feat/dnf-tools
Open

feat(dnf): add read-only dnf tools and list output limits#264
Albe83 wants to merge 3 commits intorhel-lightspeed:mainfrom
Albe83:feat/dnf-tools

Conversation

@Albe83
Copy link

@Albe83 Albe83 commented Feb 7, 2026

Summary

Adds read-only DNF tooling to the Linux MCP Server, enabling system diagnostics for RPM-based (RH-like) systems with DNF v4+. Includes list/detail workflows, repositories, groups and modules, plus safe output limiting for large datasets.

Changes

  • Add DNF tools: list installed/available packages, package info, repo list/info, provides, groups, modules
  • Enforce read-only execution and input validation
  • Add list output controls (limit, offset, no_limit) with safe defaults and truncation note
  • Update usage documentation
  • Add comprehensive tests for all new tool paths and limits

Tests

  • make verify

Notes

  • Read-only by design (readOnlyHint=True)
  • Output is kept raw to avoid early normalization
  • Works on RH-like systems with DNF >= 4

@codecov
Copy link

codecov bot commented Feb 7, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.

Flag Coverage Δ
unittests 97.71% <100.00%> (+0.34%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
src/linux_mcp_server/commands.py 89.09% <ø> (ø)
src/linux_mcp_server/tools/__init__.py 100.00% <100.00%> (ø)
src/linux_mcp_server/tools/dnf.py 100.00% <100.00%> (ø)
src/linux_mcp_server/utils/validation.py 100.00% <100.00%> (ø)
tests/tools/test_dnf.py 100.00% <100.00%> (ø)

... and 1 file with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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.

1 participant