Page MenuHomePhabricator

rhg: Add support for the blackbox extension
ClosedPublic

Authored by SimonSapin on Wed, Feb 17, 7:58 AM.

Details

Summary

Only command and commandfinish events are logged.
The dirty, logsource, track and ignore configuration items
are not supported yet.

To indicate commands executed without Python, a (rust) prefix is added
in corresponding log messages.

Diff Detail

Repository
rHG Mercurial
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

SimonSapin created this revision.Wed, Feb 17, 7:58 AM
Alphare added inline comments.
rust/rhg/src/blackbox.rs
61

You've got a NBSP here ;)

116

Problem with this is that it conflicts with .t output. Or was it intentional?

SimonSapin marked an inline comment as done.Fri, Feb 19, 3:29 AM
SimonSapin added inline comments.
rust/rhg/src/blackbox.rs
61

Right. This comment was obsolete anyway so I’ve removed it. (date-format is part of this commit and there’s not quoting in config syntax outside of list-values, see previous commit.)

116

Oh do you mean that (glob) expected output in .t files makes it hard to expect a literal ? character? https://docs.rs/users/0.11.0/users/fn.get_current_username.html says “This function to return None if the current user does not exist, which could happen if they were deleted after the program started running.” so I don’t expect this ??? fallback to show up a lot in practice and I think it’s not worth testing it.

SimonSapin marked an inline comment as done.Fri, Feb 19, 3:31 AM
SimonSapin updated this revision to Diff 25661.
Alphare accepted this revision.Fri, Feb 19, 4:05 AM
Alphare added inline comments.
rust/rhg/src/blackbox.rs
116

I don't think it's worth testing either, I just meant I would have chosen a different set of characters just to avoid confusion. It's not a dealbreaker.

baymax updated this revision to Diff 25680.Fri, Feb 19, 6:29 AM

✅ refresh by Heptapod after a successful CI run (🐙 💚)

This revision was not accepted when it landed; it landed in state Needs Review.
This revision was automatically updated to reflect the committed changes.