obsidian-git icon indicating copy to clipboard operation
obsidian-git copied to clipboard

[bug] `DisableNotification` setting does not work on obsidian git mobile (iOS).

Open andylizf opened this issue 3 years ago • 4 comments

Maybe because there is no check for the DisableNotification setting before raise a Notice in file isomorphicGit.ts

andylizf avatar Sep 02 '22 10:09 andylizf

Some commands can take a while. So I want the user always to know that the command is still running. I may delay the notice so that they come only up if the task takes like > 5 seconds. Which notices are disturbing you in particular?

Vinzent03 avatar Sep 06 '22 06:09 Vinzent03

It shows all notifications even if you disable notifications (In Android too)

OpenMindAmir avatar Sep 18 '22 16:09 OpenMindAmir

@mwxgaf Notifications like

  • Everything is up-to-date
  • Committed n files
  • Pulled n files
  • Pushed n files

shouldn't be shown. You should see notifications like Getting Status or progress notifications.

Vinzent03 avatar Sep 18 '22 16:09 Vinzent03

yes yes this is right I had not paid attention this is not about all notifications

You should see notifications like Getting Status or progress notifications

By the way do you have any plan to fix this?

thank you for your great plugin :rose:

OpenMindAmir avatar Sep 18 '22 16:09 OpenMindAmir

The spec is that only errors are shown, all other notifications should be silenced.

I depend on Obsidian Git for syncing all my vaults and have all auto backup options on, and it’s quite annoying to be bombarded by status updates every time I startup the iOS app. Hope this is fixed soon.

Great plug-in, can’t live without it, and thanks for your good work :)

green-codes avatar Oct 24 '22 16:10 green-codes

For a temp solution I commented all Notice lines in the JS file

OpenMindAmir avatar Oct 27 '22 16:10 OpenMindAmir

Should be fixed now. If the status command takes longer than 20s I'm still showing a notification to let the user know a task is running long.

Vinzent03 avatar Nov 02 '22 21:11 Vinzent03

I am getting an error with the new pull request

TypeError: undefined is not an object (evaluating progressNotice.noticeEl')

Although this may be unrelated - just updated from 2.8.0 to 2.9.2

bd-g avatar Nov 02 '22 23:11 bd-g

@Vinzent03 just implementation details - for example, in file obsidian-git/src/isomorphicGit.ts, a sample change is below

// This used to ALWAYS be a Notice object - now it can be undefined
const progressNotice = this.showNotice("Initializing pull");
...
...
// progressNotice is used here, but if it is undefined it will fail
(progressNotice as any).noticeEl.innerText = this.getProgressText("Checkout", progress);

I will see if there is a fix in the next day or two. If not, I may try to find time to make a PR with my own fix.

bd-g avatar Nov 02 '22 23:11 bd-g

Am i suppose to see "finish pull" every time?? . i get this notification on ios

echo-saurav avatar Nov 23 '22 10:11 echo-saurav

@echo-saurav Should be fixed now!

Vinzent03 avatar Nov 26 '22 19:11 Vinzent03