You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Running git-filter-repo using that file as --replace-message parameter causes an exception on a (probably the first) commit that I actually want to fix, saying Missing space before < in ident string. Here's the full output on an execution with --debug on. btw: Using --dryrun does not cause the problem.
$ ../git-filter-repo/git-filter-repo --replace-message fixmissingspace.txt --debug
[DEBUG] Passed arguments:
Namespace(analyze=False, report_dir=None, inclusive=False, path_changes=[], use_base_name=False, subdirectory_filter=None, to_subdirectory_filter=None, replace_text=None, max_blob_size=0, strip_blobs_with_ids=set(), tag_rename=None, replace_message={'literals': [], 'regexes': [(re.compile(b'^.+\\w\\<.+$'), b'missingSpaceBeforeEmail <[email protected]>')]}, preserve_commit_hashes=False, preserve_commit_encoding=False, mailmap=None, replace_refs=None, prune_empty='auto', prune_degenerate='auto', no_ff=False, filename_callback=None, message_callback=None, name_callback=None, email_callback=None, refname_callback=None, blob_callback=None, commit_callback=None, tag_callback=None, reset_callback=None, source=None, target=None, help=False, version=False, force=True, partial=False, refs=['--all'], dry_run=False, debug=True, state_branch=None, stdin=False, quiet=False, repack=True)
[DEBUG] Running: git fast-export --show-original-ids --signed-tags=strip --tag-of-filtered-object=rewrite --fake-missing-tagger --reference-excluded-parents --no-data --use-done-feature --mark-tags --reencode=yes --all
(saving a copy of the output at .git/filter-repo/fast-export.original)
[DEBUG] Running: git -c core.ignorecase=false fast-import --force --quiet --date-format=raw-permissive
(using the following file as input: .git/filter-repo/fast-export.filtered)
Parsed 30189 commitsfatal: Missing space before < in ident string: Gregor Hartmann<gh <Gregor Hartmann<[email protected]>> 1282910542 +0200
fast-import: dumping crash report to .git/fast_import_crash_17358
Traceback (most recent call last):
File "/home/thorsten/git/rare/core/../git-filter-repo/git-filter-repo", line 4005, in <module>
main()
File "/home/thorsten/git/rare/core/../git-filter-repo/git-filter-repo", line 4002, in main
filter.run()
File "/home/thorsten/git/rare/core/../git-filter-repo/git-filter-repo", line 3937, in run
self._parser.run(self._input, self._output)
File "/home/thorsten/git/rare/core/../git-filter-repo/git-filter-repo", line 1409, in run
self._parse_commit()
File "/home/thorsten/git/rare/core/../git-filter-repo/git-filter-repo", line 1260, in _parse_commit
self._commit_callback(commit, aux_info)
File "/home/thorsten/git/rare/core/../git-filter-repo/git-filter-repo", line 3486, in _tweak_commit
self._record_remapping(commit, orig_parents)
File "/home/thorsten/git/rare/core/../git-filter-repo/git-filter-repo", line 3261, in _record_remapping
self._output.flush()
File "/home/thorsten/git/rare/core/../git-filter-repo/git-filter-repo", line 2721, in flush
self.file1.flush()
BrokenPipeError: [Errno 32] Broken pipe
I need help in understanding which of the three options applies in this case (or if there's another option I don't even think about):
I did something wrong using git-filter-repo for the described scenario.
git-filter-repo cannot fix this git fsck issue so it works as designed.
There is a bug in git-filter-repo as it should be able to handle my use case.
Of course I appreciate any other help in how to fix a repo with missingSpaceBeforeEmail (and also missingSpaceBeforeDate) in an efficient manner (so git filter-branch is not the preferred option and deprecated anyway;).
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hello fellow git-filter-repo community,
in order to fix a repo with a lot of
missingSpaceBeforeEmail
errors when runnniggit fsck
I have created a mapping file with the following content:Running
git-filter-repo
using that file as--replace-message
parameter causes an exception on a (probably the first) commit that I actually want to fix, sayingMissing space before < in ident string
. Here's the full output on an execution with--debug
on. btw: Using--dryrun
does not cause the problem.I need help in understanding which of the three options applies in this case (or if there's another option I don't even think about):
git-filter-repo
for the described scenario.git-filter-repo
cannot fix thisgit fsck
issue so it works as designed.git-filter-repo
as it should be able to handle my use case.Of course I appreciate any other help in how to fix a repo with
missingSpaceBeforeEmail
(and alsomissingSpaceBeforeDate
) in an efficient manner (sogit filter-branch
is not the preferred option and deprecated anyway;).Thank you and cheers
Thorsten
Beta Was this translation helpful? Give feedback.
All reactions