Skip to content

Use stdlib datetime module to parse D-Bus dates - #1291

Merged
mulkieran merged 1 commit into
stratis-storage:masterfrom
mulkieran:issue_project_895
Sep 3, 2026
Merged

Use stdlib datetime module to parse D-Bus dates#1291
mulkieran merged 1 commit into
stratis-storage:masterfrom
mulkieran:issue_project_895

Conversation

@mulkieran

@mulkieran mulkieran commented Sep 2, 2026

Copy link
Copy Markdown
Member

@mulkieran mulkieran added this to the 3.10.0 milestone Sep 2, 2026
@mulkieran mulkieran self-assigned this Sep 2, 2026
@mulkieran mulkieran moved this to In Progress in 2026September Sep 2, 2026
@mulkieran
mulkieran marked this pull request as ready for review September 2, 2026 20:16
@mulkieran

Copy link
Copy Markdown
Member Author

@coderabbitai review

@coderabbitai

coderabbitai Bot commented Sep 2, 2026

Copy link
Copy Markdown
✅ Action performed

Review finished.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@coderabbitai

coderabbitai Bot commented Sep 2, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Team

Run ID: 0ed5475b-3d72-47d8-aee5-b7376908bea3

📥 Commits

Reviewing files that changed from the base of the PR and between 084df22 and 71dcf9d.

📒 Files selected for processing (3)
  • setup.cfg
  • src/stratis_cli/_actions/_list_filesystem.py
  • src/stratis_cli/_actions/_list_pool.py
💤 Files with no reviewable changes (1)
  • setup.cfg

Included review availability: Your plan provides up to 2 included reviews per hour; 1 remains after this review.


Walkthrough

The CLI removes python-dateutil and uses datetime.fromisoformat() to parse filesystem creation and pool re-encryption timestamps.

Changes

Timestamp Parsing Migration

Layer / File(s) Summary
Dependency and parser import updates
setup.cfg, src/stratis_cli/_actions/_list_filesystem.py, src/stratis_cli/_actions/_list_pool.py
The runtime dependency on python-dateutil is removed. Both actions import datetime from the standard library.
Timestamp formatting updates
src/stratis_cli/_actions/_list_filesystem.py, src/stratis_cli/_actions/_list_pool.py
Filesystem creation and pool re-encryption timestamps use datetime.fromisoformat() before the existing timezone conversion and display formatting.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Merge Risk: ⚪ Minimal · up to 71dcf

The PR replaces an external timestamp parser with Python’s standard library while preserving the existing display behavior. No actionable merge-blocking risk remains after normal checks and review.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 2 functions across 2 files.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely describes the main change: replacing the dateutil parser with the standard-library datetime module for D-Bus dates.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@mulkieran mulkieran moved this from In Progress to In Review in 2026September Sep 3, 2026
@mulkieran
mulkieran requested a review from jbaublitz September 3, 2026 00:33
@mulkieran

Copy link
Copy Markdown
Member Author

/packit build

@packit-as-a-service

Copy link
Copy Markdown

Congratulations! One of the builds has completed. 🍾

You can install the built RPMs by following these steps:

  • sudo dnf install -y 'dnf*-command(copr)'
  • dnf copr enable packit/stratis-storage-stratis-cli-1291-copr_pull
  • And now you can install the packages.

Please note that the RPMs should be used only in a testing environment.

1 similar comment
@packit-as-a-service

Copy link
Copy Markdown

Congratulations! One of the builds has completed. 🍾

You can install the built RPMs by following these steps:

  • sudo dnf install -y 'dnf*-command(copr)'
  • dnf copr enable packit/stratis-storage-stratis-cli-1291-copr_pull
  • And now you can install the packages.

Please note that the RPMs should be used only in a testing environment.

The datetime method fromisoformat() method's contract
declares that it parses a date string given in any valid
ISO 8601 format. stratisd uses the DateTime::to_rfc3339_opts()
method, which guarantees to produce an ISO 8601 formatted
date string.

Assisted-by: Claude:claude-sonnet-4-5
Signed-off-by: the Mulhern <amulhern@amulhern.bos.csb>
@mulkieran
mulkieran merged commit 1cf4b19 into stratis-storage:master Sep 3, 2026
8 checks passed
@mulkieran
mulkieran deleted the issue_project_895 branch September 3, 2026 14:26
@github-project-automation github-project-automation Bot moved this from In Review to Done in 2026September Sep 3, 2026
@mulkieran mulkieran moved this from Done to Done(1) in 2026September Sep 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done(1)

Development

Successfully merging this pull request may close these issues.

dateutil python package is unmaintained and being deprecated in Fedora 45

2 participants