(
self,
why: CheckoutNotify,
path: str,
baseline: Optional[DiffFile],
target: Optional[DiffFile],
workdir: Optional[DiffFile],
)
| 560 | # define callbacks that raise an InterruptedError when checkout detects a conflict |
| 561 | class MyStashApplyCallbacks(pygit2.StashApplyCallbacks): |
| 562 | def checkout_notify( |
| 563 | self, |
| 564 | why: CheckoutNotify, |
| 565 | path: str, |
| 566 | baseline: Optional[DiffFile], |
| 567 | target: Optional[DiffFile], |
| 568 | workdir: Optional[DiffFile], |
| 569 | ) -> None: |
| 570 | if why == CheckoutNotify.CONFLICT: |
| 571 | raise InterruptedError('Applying the stash would create a conflict') |
| 572 | |
| 573 | # overwrite hello.txt so that applying the stash would create a conflict |
| 574 | with hello_txt.open('w') as f: |
nothing calls this directly
no outgoing calls
no test coverage detected