8000 store in sync.js called twice · Issue #61 · eXist-db/atom-existdb · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

store in sync.js called twice #61

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
mgraauw opened this issue Jan 22, 2019 · 2 comments
Open

store in sync.js called twice #61

mgraauw opened this issue Jan 22, 2019 · 2 comments
Labels

Comments

@mgraauw
Copy link
mgraauw commented Jan 22, 2019

Having Sync on in Atom.

Whenever I save a local file, I get a message from busy-signal:
"Status .... is already set..."
caused by line 70 in syn.js:
this.emit("status", Uploading ${file} to ${relPath} as ${contentType}...);
Not an busy-signal issue (see similar problems in busy-signal git).
Files are actually synced to eXist, no problems there.

Replacing the lines in sync.js with:
console.log('hi')
var d = new Date()
this.emit("status", Uploading ${d.getTime()}: ${file} to ${relPath} as ${contentType}...);
resolves the busy-signal error, however the console does say 'hi' twice for every save.

Seems the underlying problem is store being called twice.

Atom 1.34.0 x64 on Win10, eXist 4.3.1, atom existdb package 0.12.0

@ghost ghost added the triage label Jan 22, 2019
@mgraauw
Copy link
Author
mgraauw commented Feb 1, 2019

Did some research into the issue. Disabling atom packages did not solve the issue.

store() in sync.js is indeed called twice. Turns out onDidChangeFiles in sync,js lines 18.19:

    const disposable = atom.project.onDidChangeFiles(events => {
        for (const event of events) {

is called twice, first time with 1, second time with 2 "modified" events.

If this is an issue only I encounter, I suggest closing it, since it's probably some peculiarity of my machine (or Windows). Not closing it myself yet in case the above leads to a hint on how to solve it.

@bwbohl
Copy link
bwbohl commented Mar 16, 2022

I also encounter this issue, running:

  • MacOS Monterey on Apple Silicon
  • Atom 1.60.0
  • Atom existdb package 1.2.0
  • existdb v5.4.1 via docker

The sync works but the warning is a bit annoying ;-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants
0