Skip to content

Modernize packaging, fix parsing issues, and add CI#38

Open
jonasjancarik wants to merge 5 commits intopoliteauthority:masterfrom
jonasjancarik:master
Open

Modernize packaging, fix parsing issues, and add CI#38
jonasjancarik wants to merge 5 commits intopoliteauthority:masterfrom
jonasjancarik:master

Conversation

@jonasjancarik
Copy link

@jonasjancarik jonasjancarik commented Dec 29, 2025

Summary

This PR modernizes the packaging and fixes multiple issues with the parsing logic.

Changes

Parsing Improvements

  • Use JSON output format for docker ps (--format '{{json .}}') to eliminate brittle column splitting. Fixes issues where container names were misidentified when commands contained newlines or multiple spaces.
  • Fix health status parsing in _parse_ps_date to correctly handle (health: starting) and other health status variants.

Packaging Modernization

  • Switch to console_scripts entry point instead of scripts= to ensure proper wrapper generation on all platforms.
  • Add dockerprettyps/__main__.py to support python -m dockerprettyps.
  • Update shebang to #!/usr/bin/env python3.
  • Escape ASCII art backslashes to fix SyntaxWarning in Python 3.12+.

CI/CD

  • Add GitHub Actions workflow to test installation via pip and uv on Ubuntu, macOS, and Windows.

Documentation

  • Update README to recommend modern install methods (uv tool install, pip install .).

Fixes

@jonasjancarik jonasjancarik reopened this Dec 29, 2025
@jonasjancarik jonasjancarik changed the title Fix cross-platform installs: use console_scripts entry point (pip/uv), remove hardcoded shebang launcher Modernize packaging, fix parsing issues, and add CI Dec 30, 2025
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.

Executable points to python3.7

1 participant