Code Monkey home page Code Monkey logo

existdb-langserver's People

Contributors

duncdrum avatar joewiz avatar line-o avatar wolfgangmm avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

existdb-langserver's Issues

Random attempts to create a collection

Since the last few days the plugin is randomly trying to create collections. I am syncing with an eXist-db collection named „wuehr-soeinefreiheit“ and after starting the synchronization the plugin tries to create collections inside eXist, which are already there. For example the following is logged to the terminal:

> Executing task: node /Users/bastian/.vscode/extensions/exist-db.existdb-vscode-1.5.0/sync/dist/sync.js -s http://localhost:8080/exist -u admin -p   -c /db/apps/wuehr-soeinefreiheit "/Users/bastian/Documents/GitHub/wuehr-soeinefreiheit" -i ".existdb.json" ".git/**" ".gitignore" "node_modules/**" "bower_components/**" "*/.DS_Store" <

Watching /Users/bastian/Documents/GitHub/wuehr-soeinefreiheit
Using fs events.
Creating collection  in /db/apps/wuehr-soeinefreiheit
Creating collection  in /db/apps/wuehr-soeinefreiheit
Creating collection  in /db/apps/wuehr-soeinefreiheit
Creating collection  in /db/apps/wuehr-soeinefreiheit
Creating collection  in /db/apps/wuehr-soeinefreiheit
Creating collection  in /db/apps/wuehr-soeinefreiheit
Creating collection  in /db/apps/wuehr-soeinefreiheit
Creating collection  in /db/apps/wuehr-soeinefreiheit
Creating collection  in /db/apps/wuehr-soeinefreiheit
Creating collection  in /db/apps/wuehr-soeinefreiheit

Everything is still working fine, but I'm curious, if there is going to be any problem in the future.

I am using the following setup:
MacBook Air (M1)
MacOS BigSur
VS-Code 1.5.2
eXist-db 5.2.0

VSCode objects to "request:" namespace prefix

Following up on my posting of 2020-10-06 to exist-open:

When using eXist 5.3.0-SNAPSHOT 587dde5f72791201512956125d4d8d0f6cc0a319 20201002114117 inside VSCode, if I create an XQuery file that reads, in its entirety:

xquery version "3.1";
declare namespace output = "http://www.w3.org/2010/xslt-xquery-serialization";
declare option output:method "xhtml";
declare option output:media-type "application/xhtml+xml";
declare option output:omit-xml-declaration "no";
declare option output:doctype-system "about:legacy-compat";
declare option exist:serialize "method=xhtml enforce-xhtml=yes";
declare variable $input as xs:string := request:get-parameter('in', 'xyz');
<html><head><title>Title</title></head><body>Here is my default input: {$input}</body></html>

a "problem" is reported on the request: prefix:

[XPST0081] "request": can not expand prefix of lexical QName to namespace URI

I have installed the Atom server-side library for eXist-db (version 1.0.1). Otherwise VSCode is communicating with eXist-db, real-time synchronization from the file system is working correctly, and I can run the query on my eXist-db instance without error.

only syncing / uploading files in app root directory

If I make a change to a file in the app root collection, the changes are synced
If I make a change to say /modules/app.xql, the changes do not sync

  • eXist-db 4.7.1
  • Microsoft Windows 10
  • Visual Studio Code - running in WSL environment
  • existdb-vscode tasks seem to run no problem
  • .existdb.json file in root of workspace
{
    "servers": {
        "localhost": {
            "server": "http://localhost:8080/exist",
            "user": "admin",
            "password": "",
            "root": "/db/apps/my-app"    
        }
    },
    "sync": {
        "server": "localhost",
        "ignore": [
            ".existdb.json",
            ".git/**"
        ]
    }
}

couldn't connect to exist-db from VsCode

hi,

Unable to connect to db from Visual studio code. I can't the db icons in status bar. My workspace configuration file .existdb.json contains

{
"servers": {
"localhost": {
"server": "http://localhost:8080/exist",
"user": "admin",
"password": "rama",
"root": "/apps/SrikoshNew"
}
}
}

please let me know what I am doing wrong.

Onboarding quirk

When installing doing a fresh install of extension in VS-Code it only triggers the connection to exist-db after opening an xquery file. If doesn't matter if everything is configured properly many times over. It makes it look like the extension isn't working properly. So either we should put something on the readme, or make sure that the connection can be triggered even when its not an xquery file on wishes to work upon.

No existdb-sync tasks found

Hi,

I'm trying to set this extension up but can't seem to link to my existdb instance: when I try to run task I see existdb-sync in the task list but then when I click through, the command palette says No existdb-sync tasks found. Pressing the little sync status icon takes me to an empty command palette prompt with no suggestions. My .existdb.json config is as follows:

{
    "servers": {
        "localhost": {
            "server": "http://localhost:8080/exist",
            "user": "admin",
            "password": "",
            "root": "/db/apps/my-app"
        }
    },
    "sync": {
      "server": "localhost",
      "dir": ".",
      "polling": false,
      "interval": 100,
      "ignore": [
          ".existdb.json",
          ".git/**",
          "node_modules/**",
          "bower_components/**"
      ]
  }
}

It seems like I'm not connecting to my the instance correctly. I might be missing something very obvious here, and would appreciate your input.

Thanks,
Joshua

existdb-sync task breaks if workspace path contains a space

When testing the vscode extension, I noticed that the existdb-sync task would fail if the path to the workspace contains a space.

The error:

Executing task in folder air table: node /Users/joe/.vscode/extensions/exist-db.existdb-vscode-1.0.2/sync/dist/sync.js -s http://localhost:8080/exist -u admin -p -c /db/apps/airtable /Users/joe/Downloads/air table -i ".existdb.json" ".git/" "node_modules/" "bower_components/**" <

directory /Users/joe/Downloads/air not found
The terminal process terminated with exit code: 1

Terminal will be reused by tasks, press any key to close it.

The path in question is /Users/joe/Downloads/air table.

If I wrap the path in quotes or escape the space (e.g., "/Users/joe/Downloads/air table" or /Users/joe/Downloads/air\ table) and run the command again, it succeeds. However, I can't figure out how to get vscode to add quotes or escape the space.

Could anyone suggest a method that might work? I think the relevant code is here:

const argv = yargs.options({
s: { alias: 'server', type: 'string', default: 'http://localhost:8080/exist' },
u: { alias: 'user', type: 'string', default: 'admin' },
p: { alias: 'password', type: 'string', default: '' },
c: { alias: 'collection', type: 'string', demandOption: true },
i: { alias: 'ignore', type: 'string', array: true, default: [] }
}).argv;
if (argv._.length == 0) {
console.log('please specify a directory to watch');
process.exit(1);
}
const dir = path.resolve(argv._[0]);
if (!fs.existsSync(dir)) {
console.log(`directory ${argv._[0]} not found`);
process.exit(1);
}

sync only seems to work if exist context is se to `/exist`

When trying to get the sync to work with a dockerized eXist-db with context set to / installation of the support XAR failed and so did synchronzation. After rebooting the container with context set to /exist it started working.

Would another solution be to modify the server in .existdb.json, i.e. not "server": "http://localhost:8088/exist" but `"server": "http://localhost:8088/"?

Cannot read properties of undefined (reading 'sendRequest')

Can't for the life of me connect to the server. The error reported in the VSCode extension host log is:

2023-04-27 13:16:17.656 [error] TypeError: Cannot read properties of undefined (reading 'sendRequest') at /Users/anthony/.vscode/extensions/exist-db.existdb-vscode-1.7.2/client/dist/extension.js:1:266419 at m.h (/Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/api/node/extensionHostProcess.js:98:125797) at m.$executeContributedCommand (/Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/api/node/extensionHostProcess.js:98:126701) at c.N (/Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/api/node/extensionHostProcess.js:108:11655) at c.M (/Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/api/node/extensionHostProcess.js:108:11373) at c.H (/Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/api/node/extensionHostProcess.js:108:10454) at c.G (/Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/api/node/extensionHostProcess.js:108:9432) at /Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/api/node/extensionHostProcess.js:108:8220 at E.invoke (/Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/api/node/extensionHostProcess.js:63:145) at h.deliver (/Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/api/node/extensionHostProcess.js:63:2121) at n.fire (/Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/api/node/extensionHostProcess.js:63:1729) at p.fire (/Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/api/node/extensionHostProcess.js:72:14916) at /Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/api/node/extensionHostProcess.js:124:16654 at E.invoke (/Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/api/node/extensionHostProcess.js:63:145) at h.deliver (/Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/api/node/extensionHostProcess.js:63:2121) at n.fire (/Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/api/node/extensionHostProcess.js:63:1729) at p.fire (/Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/api/node/extensionHostProcess.js:72:14916) at MessagePortMain.<anonymous> (/Applications/Visual Studio Code.app/Contents/Resources/app/out/vs/workbench/api/node/extensionHostProcess.js:124:14780) at MessagePortMain.emit (node:events:526:28) at MessagePortMain._internalPort.emit (node:electron/js2c/utility_init:5:364) existdb.reconnect {"value":"eXist-db.existdb-vscode","c":"exist-db.existdb-vscode"}

Extension version is 1.7.2 and my server connection settings are standard out of the box settings:

{
"servers": {
"localhost": {
"server": "http://localhost:8080/exist",
"user": "admin",
"password": "exist",
"root": "/db/apps"
}
}
}

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.