coreutils icon indicating copy to clipboard operation
coreutils copied to clipboard

Use `Duration` based uptime across uucore

Open irbeam256 opened this issue 7 months ago • 5 comments

Closes #7851

Changes the i64 based uptime returned by uucore's get_uptime into an std::time::Duration and updates callsites.

  • [x] get_uptime modified to accept fractional seconds from /proc/uptime and return Duration
  • [x] Callsites in uucore/.../features/uptime.rs and uu/.../uptime.rs use Duration

irbeam256 avatar May 12 '25 16:05 irbeam256

you probably noticed that a few jobs are failing

sylvestre avatar May 12 '25 17:05 sylvestre

you probably noticed that a few jobs are failing

Oh yes, just getting a draft PR on the issue now while I work on it, this commit won't build yet. I'll mark ready for review when it's good enough to look at.

irbeam256 avatar May 12 '25 19:05 irbeam256

This PR depends on the changes in #7910 so once that is merged I can rebase this branch on main.

irbeam256 avatar May 13 '25 01:05 irbeam256

GNU testsuite comparison:

Skipping an intermittent issue tests/misc/tee (passes in this run but fails in the 'main' branch)

github-actions[bot] avatar May 13 '25 05:05 github-actions[bot]

I think 177fae1208c77814c57b2fb045f7b470241c0b8f looks good, would it be possible to rebase just that commit on main? (arguably this is more important than --pretty parameter that's technically an extension)

drinkcat avatar May 29 '25 09:05 drinkcat

it has been draft for a long time, please reopen when ready

sylvestre avatar Oct 06 '25 20:10 sylvestre