Comments (10)
Thanks for the report! I suspected something like this and asked in issue #4 but never got an answer. Could you run the following and report if you get the same error:
subprocess.check_output(["git", b"--version"])
If so, I can extend the wrappers to not only unicode-ify the cwd argument, but also the args list.
from git-filter-repo.
from git-filter-repo.
Yes, you should be able to try that out at a vanilla python prompt, though you'll need to first run import subprocess
within the python prompt to make sure it has the 'subprocess' module loaded.
from git-filter-repo.
Have you had a chance to take a look?
from git-filter-repo.
Please find output below:
>>> import subprocess
>>> subprocess.check_output(["git", b"--version"])
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "E:\python37\lib\subprocess.py", line 395, in check_output
**kwargs).stdout
File "E:\python37\lib\subprocess.py", line 472, in run
with Popen(*popenargs, **kwargs) as process:
File "E:\python37\lib\subprocess.py", line 775, in __init__
restore_signals, start_new_session)
File "E:\python37\lib\subprocess.py", line 1119, in _execute_child
args = list2cmdline(args)
File "E:\python37\lib\subprocess.py", line 530, in list2cmdline
needquote = (" " in arg) or ("\t" in arg) or not arg
TypeError: a bytes-like object is required, not 'str'
from git-filter-repo.
Wow, kinda lame that this isn't an intrinsic windows issue, but Python itself just assumes everything is a (unicode) string. Anyway, I think my workaround in the windows-workarounds branch should fix this. Could you give it a try?
from git-filter-repo.
I'll give it a try tomorrow, will let you know
from git-filter-repo.
It appears to be working now. I successfully issued a mailmap command.
I received an error upon doing a git push
to do with restrictions on only being able to push my own commits but I'm not sure that is something that could be fixed in this program, it appears to be an issue with our git server.
from git-filter-repo.
Also just FYI it looks like PyInstaller can create a Windows executable just fine for git-filter-repo.
Also if you need Windows test coverage maybe Github Actions could help?
from git-filter-repo.
Cool, thanks for testing it out. I've merged the change into the master branch. As far as push restrictions, yeah if you have some kind of aggressive hooks on the server that only let you push your own commits up, then that wouldn't work well with filter-repo since it edits all the commits in the repo creating new ones (and then deletes the old ones). If this is gerrit you are using, https://gerrit-review.googlesource.com/Documentation/access-control.html#category_forge_author (and forge committer right after it) may help, but it's going to be entirely dependent on the git server you're using.
Thanks for the heads up on PyInstaller; I may look into it at some point. Or I may delay until someone else does it for me. :-)
from git-filter-repo.
Related Issues (20)
- How to propagate renames back through history?
- How to keep the file in the file system with filter-repo? HOT 1
- git filter-repo --invert-paths --path <directory/file> creating duplicate branches
- I tried --invert-paths it didn't seem to do anything.
- Remove a commit based on its message content or filename with git filter-repo --commit-callback
- Is there a way to remove duplicate commits?
- Update submodule hashes?
- Renaming paths into pre-existing path causes double-nested paths (sometimes)
- Keep last 3 months of package-lock.json diffs only HOT 1
- Question: prune lfs files
- remark: Pity that this tool can't run scripts/programs and it is not clearly stated HOT 1
- minor: Logic error with `_commits_referenced_but_removed` on a GitHub Gist web url in commit message 😂
- Crash when path contains emoji HOT 1
- Question: Recommended way to log the usage of git filter-repo and related changes? HOT 1
- Callback that gives both filename and blob
- Breaking change in git 2.43 or 2.44 HOT 2
- lint-history: --refs argument not working at all HOT 1
- Test suite succedes with Python 3.11 but has multiple failures with Python 3.12 HOT 7
- Turns out my assumption was wrong: `git lfs migrate export --everything --include="*"` does rewrite the whole history, across all branches, reinjecting all the large files' consecutive versions ([see here](https://github.com/git-lfs/git-lfs/issues/910#issuecomment-551566315)). Awesome! HOT 1
- Support for SHA256
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from git-filter-repo.