obsidian-git
obsidian-git copied to clipboard
[Bug]: buffer error on iOS
Describe the bug
Since i added a pdf/blob in my git repository i am getting "buffer error". The directory with the pdf doesn't pull (but some others do) Pushes totally fail
Interestingly i have another directory with a much bigger PDF that just works
Relevant errors (if available) from notifications or console (CTRL+SHIFT+I)
No response
Steps to reproduce
- Add a pdf in a directory
- Fetch/commit
- Get buffer error
Expected Behavior
Not getting buffer error 🙂
Addition context
No response
Operating system
iOS
Installation Method
None
Plugin version
2.22
I’ve been running into this as well when adding a ~5MB jpg file.
I have the exact same problem, pushing just throws a "buffer error". However, there are no big files in the commit or in the vault itself.
I did a bit of experiments, in the following the finding:
- Deleting/adding to gitignore the largest fine (~9MB) everything works perfectly
- Adding the big file on the mobile, committing works. Push doesn't (and Pull doesn't either that triggered me filing this bug)
- Once the large file is committed, there is no way back (I guess it is because the file stays in the local log and needs to be pushed)
(2) makes me think that the issue is with network rather than with the local client. (3) makes me thing that what @RDust4 is experiencing may be due to a huge log (for some reason)
Happy to do more experiments and/or grabbing logs (I have to figure out how though :)
I had a plugin installed named obsidian-likzjax, which does not work on mobile (it threw a "plugin failed to load" on startup). As soon as thr main.js of that plugin was in the commit, it failed to push. After then uninstalling the plugin, everything works as normal.
I have the same bug on iOS. At first it was working fine but after some time using the feature the error begun to appear.
I don't have any large files, only small text files. I have tried to disable all extension except obsdian-git, reinstall the app, but nothing worked.
I don't have any large files, only small text files. I have tried to disable all extension except
obsdian-git, reinstall the app, but nothing worked.
Disabling extensions doesn't do anything because the plugins themselves are backed up either way. You would have to uninstall extensions for that to work.
Personally, I have fixed my problem by adding a .gitignore for plugins. This backs up everything except plugins and their settings, thus resolving the problem.
The exact steps I took:
On desktop:
- add the ".gitignore" file to the vault root
- add "/.obsidian/plugins" to the gitignore file (I used notepad -> save under -> go to your vault root)
- backup (commit all changes and push) the vault
- check on git if the .obsidian/plugins folder is gone in the latest commit
Then on mobile: 5. delete old vault & create new empty vault 6. install obsidian-git, enable, and add git credentials 7. clone your vault 8. install all your plugins manually 9. change something and test if commit&push works
Hope that helps!
I had a plugin installed named obsidian-likzjax, which does not work on mobile (it threw a "plugin failed to load" on startup). As soon as thr main.js of that plugin was in the commit, it failed to push. After then uninstalling the plugin, everything works as normal.
I don't have any large files, only small text files. I have tried to disable all extension except
obsdian-git, reinstall the app, but nothing worked.Disabling extensions doesn't do anything because the plugins themselves are backed up either way. You would have to uninstall extensions for that to work.
Personally, I have fixed my problem by adding a .gitignore for plugins. This backs up everything except plugins and their settings, thus resolving the problem.
The exact steps I took:
On desktop:
1. add the ".gitignore" file to the vault root 2. add "/.obsidian/plugins" to the gitignore file (I used notepad -> save under -> go to your vault root) 3. backup (commit all changes and push) the vault 4. check on git if the .obsidian/plugins folder is gone in the latest commitThen on mobile: 5. delete old vault & create new empty vault 6. install obsidian-git, enable, and add git credentials 7. clone your vault 8. install all your plugins manually 9. change something and test if commit&push works
Hope that helps!
Unfortunately it didn't work. I did everything you mentioned (including reinstalling obsidian and only using obsidian-git plugin) but the buffer error is still happening
Could you try the same thing again, but add the whole .obsidian folder to .gitignore? I think the problem lies somewhere in there.
I have faced the same issue. Here is how I solve it:
- Delete the directory of the old vault in iphone: My Iphone->Obsidian->XXX(my vault name)
- Use a new git client to clone the repository of my vault. I use PolyGit(I think it doesn't matter, I just want to clone the repository to my iphone).
- Find the repository directory in "My Iphone->PolyGit->XXX", and move it to "My Iphone->Obsidian"
- open Obsidian on iphone
The old (WRONG) way to create the vault on my iphone was like this:
- git clone the reposity XXX (on windows)
- zip XXX to XXX.zip (on windows)
- send XXX.zip to my iphone, and place it under "My Iphone->Obsidian".
- Open Obsidian in iphone Then it popped "buffer error" when "git push". Then I used a git client app on my iphone to open the XXX, and it also popped errors. So I assume something went wrong when I copy files from windows to my iphone. Then I used a git client clone the repository directly on my iphone, then move it to Obsidian dir. It works well。
Could you try the same thing again, but add the whole .obsidian folder to .gitignore? I think the problem lies somewhere in there.
I’ve just encountered the same issue. I don’t have large files in my vault. And I also have had, since the beginning, the entire .obsidian folder in my .gitignore. The problem must be lying somewhere else.