Introduce concept of env to make gpg signing easier to test
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 1k
- Forks
- 84
- PR merge metrics
- No merged PRs in 30d
Description
https://github.com/ezyang/ghstack/pull/78 is a reasonable implementation given the current code structure but it is not great for testing because it (1) makes use of the ambient Git configuration (which is implemented as a one off function that probes git config), (2) requires us to be able to interpose on Git configuration in testing. The style of testing in ghstack today is that environmental settings are all turned into concrete arguments to the function at main() and that means that calls from testing can override the behavior there; refactor ghstack so that this occurs here as well.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at main() and trace how ambient Git configuration is obtained, including the one-off Git config probing function. Compare this with the existing pattern for passing environmental settings as concrete arguments. Done means signing behavior can be overridden by tests without interposing on Git configuration, with the relevant tests passing.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- cli, testing
- Issue type
- Refactor
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100