Closed luxlogica closed 5 years ago
Hey @luxlogica,
Thanks for detailed investigation and explanation of this bug. Yeah, it's clearly a bug. The funny thing is that it all used to work as it should prior version 1.2, hence, version 1.1.3 was the last one working correctly in this regard. Too bad nobody has caught this before and I'll certainly fix it in the first upcoming minor update.
If you're interested to read how it got broken… Version 1.2 changed a lot in regard what are responsibilities of GitFinder application and its accompanying GitFinderSync Finder Sync extension. I realised it's much better if the application does everything git related and just sends file statuses to the extension, so the extension does minimal work and just shows file statuses in Finder and offers certain menu actions (like Apple advises).
While it was the other way around (prior version 1.2), the extension was doing all git related things, including checking git file status for ALL files in the repository, even if they are unmodified (thus "up-to-date"). With new architecture, I have to send statuses of all files in the repository from the application to the extension. And for large repositories (many files), it can be quite long message, with many objects that need to be encoded on one side and decoded on the other side, etc… And in most cases, out of thousands files, only a few or a dozen are really changed/modified/ deleted, while the vast majority is "up-to-date". Hence, I decided to exclude those unmodified files in the status messages and assume if a file doesn't have status specifically mentioned, then it's ""up-to-date".
Unfortunately, this gets broken for all subfiles and subfolders of a newly added (still untracked) folder. Subfolders and subfiles really don't have any git status (yet), but due to the decision I explained in the previous paragraph, they're treated as "up-to-date", as you've discovered. Everything else that happens (not being able to stage and commit files, etc…) is a consequence of incorrectly calculated/assumed file status.
The fix is coming in a few days.
Thank you, @milke - happy to hear it was something easy to pinpoint! :) Looking forward to the update!
@luxlogica, I've just updated new beta version 1.3.1b1 (build 58). It fixes (hopefully) these issues with children of folders newly added into the repository. It works as it used to before version 1.2 and as it does in other git clients. I tested it myself, but it's always good to have someone other to confirm it's fixed.
So please, give this beta version a try for a few days and let me know if you still have those problems. You can update your current copy to this beta automatically, just choose Beta channel in update preferences. Or, if you prefer direct download, here it is. Once we're sure it's fixed, I'll make an official release.
Thank you for looking at this so quickly, @milke!
I have just tested it, and here is what happens now:
I guess that one is probably not intended behaviour, as to me this looks like all these items are being tracked — ie., I expected them to show the 'ignored' symbol, as these have never been tracked...
Sub-sub-folders (grandchildren of the parent folder) and their items, however, do not show any icons. I guess this might be intended behaviour?
Yes, it's intended, because those files (children of newly added folder(s)) don't really have any git status. However, from your question I realised that may be confusing to many people, so I decided to show badges for those files too. Not only that, they will also provide Stage action in the contextual and toolbar item menu, since those files can be staged - that is, added into repository index.
If I now 'Ignore' select these 2 folders, and tell GitFinder to 'Ignore' them, even after committing this, their sub-folders will show all their items as 'up-to-date'...:
You're right, of course.
Both of these are fixed in the latest beta version 1.3.1b3 (build 60). You can update to it like you did before. I'd appreciate if you give this beta a try and confirm the issues are fixed. Thanks! 👍
Indeed, seems to be fixed now - and the extra indicator icons in the grandchildren files/folders is a definite bonus, which makes it more intuitive - thank you!
Brief Issue Description
GitFinder seems to be unable to correctly see the status of certain files and folders in some directories. In certain cases, this makes GitFinder operation unreliable, as it becomes impossible for GitFinder to stage and commit certain files/folder. Overall, it impossible to use GitFinder in these cases.
Steps to Reproduce Issue
We should see '?' tag icons next to the 'plainkit-master' folder, as well as next to every sub-folder and file inside it, indicating that nothing is being staged yet. Unfortunately, this is not what we get, though... If we look inside the sub-folders, we see that GitFinder has marked all files and folder there as 'up-to-date/no change' - even though we still have no commits in our brand-new repository:
Let's try to do an initial commit, to see what happens:
Please note, that this means that in this instance, GitFinder seems to be wrongly reporting on the status of certain files and folders. It also seems that it is impossible to stage and commit certain files and folders with GitFinder.
Lastly, this is an issue that happens only with GitFinder. Performing these operations using other git GUI clients, or using git directly on the terminal, proceeds as expected.