I started looking at it.
https://kallithea-scm.org/repos/kallithea/pull-request/273/_/refactorings_and_stable_fixes_from_mailing_list
propose some tests (after refactoring to add basic test coverage of git
PRs).
/Mads
On 9/25/20 6:38 PM, Thomas De Schampheleire wrote:
Hi,
Thanks for your patch.
I did not yet have time to verify and test it.
Do you think it would be possible for you to add a test for the
failing behaviour?
Thanks,
Thomas
On Mon, Sep 21, 2020, 15:22 tonich sh <[email protected]
<mailto:[email protected]>> wrote:
second try:
Fixes dulwich exception on pull-request deletion
diff -r a2ec23356e6b kallithea/model/pull_request.py
--- a/kallithea/model/pull_request.py Tue Sep 15 21:30:26 2020 +0200
+++ b/kallithea/model/pull_request.py Mon Sep 21 16:14:46 2020 +0300
@@ -139,7 +139,7 @@
if pull_request.org_repo.scm_instance.alias == 'git':
# remove a ref under refs/pull/ so that commits can be
garbage-collected
try:
- del
pull_request.org_repo.scm_instance._repo["refs/pull/%d/head" %
pull_request.pull_request_id]
+ del
pull_request.org_repo.scm_instance._repo[b"refs/pull/%d/head" %
pull_request.pull_request_id]
except KeyError:
pass
пн, 21 сент. 2020 г. в 16:17, tonich sh <[email protected]
<mailto:[email protected]>>:
>
> diff -r a2ec23356e6b kallithea/model/pull_request.py
> --- a/kallithea/model/pull_request.py Tue Sep 15 21:30:26 2020
+0200
> +++ b/kallithea/model/pull_request.py Mon Sep 21 16:14:46 2020
+0300
> @@ -139,7 +139,7 @@
> if pull_request.org_repo.scm_instance.alias == 'git':
> # remove a ref under refs/pull/ so that commits can be
> garbage-collected
> try:
> - del
> pull_request.org_repo.scm_instance._repo["refs/pull/%d/head" %
> pull_request.pull_request_id]
> + del
> pull_request.org_repo.scm_instance._repo[b"refs/pull/%d/head" %
> pull_request.pull_request_id]
> except KeyError:
> pass
--
С уважением, Антон Щур.
_______________________________________________
kallithea-general mailing list
[email protected]
<mailto:[email protected]>
https://lists.sfconservancy.org/mailman/listinfo/kallithea-general
_______________________________________________
kallithea-general mailing list
[email protected]
https://lists.sfconservancy.org/mailman/listinfo/kallithea-general
_______________________________________________
kallithea-general mailing list
[email protected]
https://lists.sfconservancy.org/mailman/listinfo/kallithea-general