Skip to content
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

Exception when connecting/changing connection not from an SQL file created from the sidebar #236

Closed
ransagy opened this issue May 20, 2019 · 2 comments

Comments

2 participants
@ransagy
Copy link

commented May 20, 2019

Post the v0.19 changes for file sessions, There seems to be an issue using the SQLTools: Connect command. If you are not using the sidebar to create the SQL file/tab, Trying to connect throws the following exception:

ERROR: Error:  [TypeError [ERR_INVALID_ARG_TYPE]: The "path" argument must be of type string. Received type undefined
	at assertPath (path.js:39:11)
	at Object.join (path.js:434:7)
	at ConnectionManagerPlugin.<anonymous> (C:\Users\ran\.vscode\extensions\mtxr.sqltools-0.19.0\extension.js:29412:75)
	at Generator.next (<anonymous>)
	at module.exports.__awaiter (C:\Users\ran\.vscode\extensions\mtxr.sqltools-0.19.0\extension.js:29135:71)
	at new Promise (<anonymous>)
	at module.exports.__awaiter (C:\Users\ran\.vscode\extensions\mtxr.sqltools-0.19.0\extension.js:29131:12)
	at ConnectionManagerPlugin.openConnectionFile (C:\Users\ran\.vscode\extensions\mtxr.sqltools-0.19.0\extension.js:29407:16)
	at ConnectionManagerPlugin.<anonymous> (C:\Users\ran\.vscode\extensions\mtxr.sqltools-0.19.0\extension.js:29219:32)
	at Generator.next (<anonymous>)
	at fulfilled (C:\Users\ran\.vscode\extensions\mtxr.sqltools-0.19.0\extension.js:29132:58)]

To Reproduce
Steps to reproduce the behavior:

  1. Open VSCode.
  2. Create a new file or change the existing Untitled tab to be an SQL file via the language choice command/UI.
  3. Invoke the SQLTools: Connect command.
  4. See error in notification/log.

Expected behavior
Connection will be succesfull and should be attached to the current file.

Desktop (please complete the following information):

  • SQLTools Version v0.19.0
  • VSCode Version: v1.34
  • Dialect Used: MSSQL
  • OS: Windows 10 Pro x64 Build 1903

@ransagy ransagy added the bug label May 20, 2019

@project-bot project-bot bot added this to To do in Kanban May 20, 2019

@mtxr

This comment has been minimized.

Copy link
Owner

commented May 20, 2019

Confirmed. Happens when no folder is open..

@mtxr mtxr closed this in a2bcbb0 May 20, 2019

Kanban automation moved this from To do to To be released May 20, 2019

@ransagy

This comment has been minimized.

Copy link
Author

commented May 20, 2019

Confirmed, working well now. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.