[GH-ISSUE #30] git-sim reset can't seem to work #22

Closed
opened 2026-03-02 16:47:12 +03:00 by kerem · 2 comments
Owner

Originally created by @zadigus on GitHub (Jan 27, 2023).
Original GitHub issue: https://github.com/initialcommit-com/git-sim/issues/30

I wanted to give git-sim a go, because it seems interesting. I therefore installed it on my windows machine, like this:

choco install manimce
pip install git-sim

I have python 3.10. Now, I wanted to quickly check if it works and in one of my repositories, I ran

git-sim reset -h

which tells me that the reset works like this:

git-sim reset [-h] [--mode MODE] [--soft] [--mixed] [--hard] [commit]

So essentially all options are optional, i.e. I should be able to run git-sim reset, which I did, with the following result:

$ git-sim reset
Simulating: git reset HEAD
Traceback (most recent call last):
  File "C:\Users\lmichel\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 196, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "C:\Users\lmichel\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 86, in _run_code
    exec(code, run_globals)
  File "C:\Users\lmichel\AppData\Local\Programs\Python\Python310\Scripts\git-sim.exe\__main__.py", line 7, in <module>
  File "C:\Users\lmichel\AppData\Local\Programs\Python\Python310\lib\site-packages\git_sim\__main__.py", line 89, in main
    scene.render()
  File "C:\tools\Manim\Lib\site-packages\manim\scene\scene.py", line 223, in render
    self.construct()
  File "C:\Users\lmichel\AppData\Local\Programs\Python\Python310\lib\site-packages\git_sim\git_sim.py", line 56, in construct
    self.command.execute()
  File "C:\Users\lmichel\AppData\Local\Programs\Python\Python310\lib\site-packages\git_sim\git_sim_reset.py", line 41, in execute
    self.parse_commits(self.commits[self.i])
  File "C:\Users\lmichel\AppData\Local\Programs\Python\Python310\lib\site-packages\git_sim\git_sim_base_command.py", line 77, in parse_commits
    commitId, circle, arrow, hide_refs = self.draw_commit(commit, prevCircle, shift, dots)
  File "C:\Users\lmichel\AppData\Local\Programs\Python\Python310\lib\site-packages\git_sim\git_sim_base_command.py", line 173, in draw_commit
    commitId, commitMessage, commit, hide_refs = self.build_commit_id_and_message(commit, dots)
TypeError: GitSimReset.build_commit_id_and_message() takes 2 positional arguments but 3 were given

Sounds crazy, not sure I will continue to git-sim if I get such an issue after the first command. I also tried git-sim tag. That one seems fine.

Originally created by @zadigus on GitHub (Jan 27, 2023). Original GitHub issue: https://github.com/initialcommit-com/git-sim/issues/30 I wanted to give `git-sim` a go, because it seems interesting. I therefore installed it on my windows machine, like this: ``` choco install manimce pip install git-sim ``` I have python 3.10. Now, I wanted to quickly check if it works and in one of my repositories, I ran ``` git-sim reset -h ``` which tells me that the reset works like this: ``` git-sim reset [-h] [--mode MODE] [--soft] [--mixed] [--hard] [commit] ``` So essentially all options are optional, i.e. I should be able to run `git-sim reset`, which I did, with the following result: ``` $ git-sim reset Simulating: git reset HEAD Traceback (most recent call last): File "C:\Users\lmichel\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 196, in _run_module_as_main return _run_code(code, main_globals, None, File "C:\Users\lmichel\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 86, in _run_code exec(code, run_globals) File "C:\Users\lmichel\AppData\Local\Programs\Python\Python310\Scripts\git-sim.exe\__main__.py", line 7, in <module> File "C:\Users\lmichel\AppData\Local\Programs\Python\Python310\lib\site-packages\git_sim\__main__.py", line 89, in main scene.render() File "C:\tools\Manim\Lib\site-packages\manim\scene\scene.py", line 223, in render self.construct() File "C:\Users\lmichel\AppData\Local\Programs\Python\Python310\lib\site-packages\git_sim\git_sim.py", line 56, in construct self.command.execute() File "C:\Users\lmichel\AppData\Local\Programs\Python\Python310\lib\site-packages\git_sim\git_sim_reset.py", line 41, in execute self.parse_commits(self.commits[self.i]) File "C:\Users\lmichel\AppData\Local\Programs\Python\Python310\lib\site-packages\git_sim\git_sim_base_command.py", line 77, in parse_commits commitId, circle, arrow, hide_refs = self.draw_commit(commit, prevCircle, shift, dots) File "C:\Users\lmichel\AppData\Local\Programs\Python\Python310\lib\site-packages\git_sim\git_sim_base_command.py", line 173, in draw_commit commitId, commitMessage, commit, hide_refs = self.build_commit_id_and_message(commit, dots) TypeError: GitSimReset.build_commit_id_and_message() takes 2 positional arguments but 3 were given ``` Sounds crazy, not sure I will continue to `git-sim` if I get such an issue after the first command. I also tried `git-sim tag`. That one seems fine.
kerem closed this issue 2026-03-02 16:47:13 +03:00
Author
Owner

@initialcommit-io commented on GitHub (Jan 27, 2023):

Hi @zadigus,

Thanks for reporting this! It's actually a bug that I accidentally introduced yesterday when fixing something else, but I fixed it now and released git-sim version 0.1.6.

Please update your git-sim version to the latest by running pip install git-sim --upgrade, which should get you the new version 0.1.6.

Sorry about the bug and let me know if it works now! Also, keep in mind this is a new project so I know there are other issues that will come up in general. I'm working with some new contributors to try and address these while also adding new features to the tool.

Please be patient with us we'd love to keep you as a git-sim user :D. If you notice any other issues please let me know. and we'll get it fixed as soon as possible.

<!-- gh-comment-id:1406217906 --> @initialcommit-io commented on GitHub (Jan 27, 2023): Hi @zadigus, Thanks for reporting this! It's actually a bug that I accidentally introduced yesterday when fixing something else, but I fixed it now and released git-sim version 0.1.6. Please update your git-sim version to the latest by running `pip install git-sim --upgrade`, which should get you the new version 0.1.6. Sorry about the bug and let me know if it works now! Also, keep in mind this is a new project so I know there are other issues that will come up in general. I'm working with some new contributors to try and address these while also adding new features to the tool. Please be patient with us we'd love to keep you as a git-sim user :D. If you notice any other issues please let me know. and we'll get it fixed as soon as possible.
Author
Owner

@zadigus commented on GitHub (Jan 27, 2023):

Thanks for the quick-fix. I will continue to play with it then!

The big issue I see with your repository is that it completely lacks tests. I am not sure, but I can imagine that you could be able to integration test you application with some kind of snapshot testing. Indeed, you generate some output in some format that you should be able to easily snapshot test. That would be a simple way to prevent regressions in your code.

<!-- gh-comment-id:1406311627 --> @zadigus commented on GitHub (Jan 27, 2023): Thanks for the quick-fix. I will continue to play with it then! The big issue I see with your repository is that it completely lacks tests. I am not sure, but I can imagine that you could be able to integration test you application with some kind of snapshot testing. Indeed, you generate some output in some format that you should be able to easily snapshot test. That would be a simple way to prevent regressions in your code.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/git-sim#22
No description provided.