Commit Graph

270 Commits

Author SHA1 Message Date
Anthony Dresser
9bd7e30d18 revert vscode cahnges (#4879) 2019-04-05 09:15:38 -07:00
David Shiflet
1f22326e78 Reuse existing saved connection that matches args (#4839)
* Reuse existing saved connection that matches args

* search subgroups for matches
2019-04-04 11:11:18 -07:00
Yurong He
504d5c91bc Fixed #4800 need to use ConnectionProfile in order to get the correct… (#4812)
* Fixed #4800 need to use ConnectionProfile in order to get the correct connection

* Go back to create connect in run cell to avoid to fail to run cell or close the connection used by other.
2019-04-03 19:00:56 -07:00
Anthony Dresser
80a8e1a4da More builder removal (#4810)
* remove more builder references

* formatting
2019-04-03 16:18:03 -07:00
Anthony Dresser
fcb8fe50fe Advanced Description On Bottom (#4836)
* move description to the bottom

* formatting
2019-04-03 15:49:53 -07:00
Anthony Dresser
fb697729c0 Data Explorer Icons (#4806)
* inital icon support

* add necessary classes for icons

* initialize icon to blank string
2019-04-03 11:10:48 -07:00
Chris LaFreniere
07166fb3cd Run All Cells Notebook Implementation (#4713)
* runAllCells API

* add comment

* more run cells fixes

* Add integration test

* Add multiple cell SQL notebook test

* Comment out python tests as they fail in the lab

* remove unused imports

* PR comments

* Remove localize

* Return true instead of promise.resolve(true)
2019-04-02 16:47:00 -07:00
Alan Ren
e83a6f9c2e profile page and summary page (#4769)
* add cluster name to page

* implement profile page -1

* fix compilation error due to new method

* profile page 0328

* summary page

* make divcontainer accessible

* handle disposable

* add support for "coming soon" cards
2019-04-02 13:52:39 -07:00
Anthony Dresser
63485c8c78 Remove builder references from options dialog (#4774)
* remove more builder references; remove $ from declarations

* fix jquery references

* formatting

* fixing backup

* fix backup box
2019-04-02 13:49:50 -07:00
Charles Gagnon
e0ec3c5035 Fix workspaceRoot macro for insights (#4686)
* Fix workspaceRoot macro for insights

The workspaceRoot macro wasn't working correctly for finding the queryFile. There were a couple of issues :

1. The path separators were hardcoded as / which wasn't xplat-compatible
2. They required the first section of the path was one of the folders in the workspace - e.g. if the workspace contained a folder named foo you'd have to specify ${workspaceRoot}\foo\myfile.sql. This is inconsistent with the folder logich was just appends the path after ${workspaceRoot} to the folder that's currently open

I changed the logic to just append the relative part of the path to every folder currently open in the workspace and choose the first one that it found that contained the file we were told to look for - which follows the convention the folder logic uses. If the file doesn't exist it'll just fall back to using the path without the macro (which is likely to not resolve and thus will display an error, but there's nothing we can do at that point anyways)

* Switch to using VS Code resolver (support for more than just workspaceRoot) and move resolution code into helper method so it can be used by the multiple places it's called. Added tests for the methods.

* Add test for invalid param

* Change resolveQueryFilePath to be a standalone exported function. Change it to throw if the file can't be resolved/found so callers can display error correctly. Added more tests to covery new scenarios. Switch to using pfs instead of fs for file existance checks.

* Add extra param to InsightsDialogController construction in test

* Fix formatting and test errors.

* Change to suiteSetup and suiteTeardown so the setup/teardown is only ran once instead of once per test - we don't need unique files and this stops a race condition error with deleting the test folder.

* spaces -> tabs
2019-03-29 14:53:49 -07:00
Raj
1415aa1c03 #4586: Clear Results feature in Notebooks (#4705)
* #4586: Clear all outputs feature

* text change

* Adding extensible method with integration tests

* Misc change

* Misc change

* Adding more logging

* Change to test

* Adding outputs confition in integration tests
2019-03-28 15:20:28 -07:00
Karl Burtram
7eb17f6abc Add Query Editor null checks (#4753) 2019-03-28 15:18:44 -07:00
Karl Burtram
cc2951265e Add query execution plan extensibility APIs (#4072)
* WIP 1

* WIP 2

* Fix typos

* Iterate on API a bit

* Query Tab WIP

* More dynamic query tab impl

* Fix merge breaks

* Update interfaces

* Update to single event handler for query events

* Remove query plan extension

* Add generated JS file
2019-03-28 10:59:02 -07:00
David Shiflet
a360bebd9d Add status messages during command line processing (#4725)
* add status bar messages

* missed semicolon
2019-03-27 15:44:57 -04:00
Chris LaFreniere
5ac6cf3b74 Ensure SQL is the first kernel in the kernels dropdown (#4692)
* Ensure SQL is the first kernel shown in the dropdown

* cleanup to prevent sql from registering twice
2019-03-26 19:39:28 -07:00
Anthony Dresser
bceeda1cfd Remove dev flags (#4707)
* remove more dev flags

* formatting
2019-03-26 11:44:59 -07:00
Raj
83c8baf8e3 #4418: Notebook file icon doesn't show for new notebook (#4676)
* #4418: Notebook icon doesn't load for untitled

* Indentation

* Indentation
2019-03-25 16:05:04 -07:00
Chris LaFreniere
1bac929ab3 Fix for SQL Kernel only showing up (#4691)
* Ensure that notebook providers that are registered "early" are shown in kernels dropdown

* cleanup
2019-03-25 15:24:57 -07:00
udeeshagautam
ddce7731b9 Feature/viewlet cmsapis (#4312)
* first set of changes to experiment the registration of cms related apis

* Adding cms service entry to workbench

* Adding basic functionality for add remove reg servers and group

* Returning relative path as part of RegServerResult as string

* Removing the cms apis from core. Having mssql extension expose them for cms extension

* Propogating the backend name changes to apis

* Fixing some missing sqlops references

* Adding a sqltools service version with CMS apis available
2019-03-22 17:24:45 -07:00
Anthony Dresser
24b5f41065 add data explorer default (#4653) 2019-03-21 16:10:54 -07:00
Chris LaFreniere
b00352570b Fix the "Failed to show notebook document" errors (#4649) 2019-03-21 16:06:17 -07:00
Chris LaFreniere
82da64d66d Handle future done in SQL for multiple batches (#4654) 2019-03-21 13:47:01 -07:00
Anthony Dresser
c814b92557 VSCode merge (#4610)
* Merge from vscode e388c734f30757875976c7e326d6cfeee77710de

* fix yarn lcoks

* remove small issue
2019-03-20 10:39:09 -07:00
Anthony Dresser
87765e8673 Vscode merge (#4582)
* Merge from vscode 37cb23d3dd4f9433d56d4ba5ea3203580719a0bd

* fix issues with merges

* bump node version in azpipe

* replace license headers

* remove duplicate launch task

* fix build errors

* fix build errors

* fix tslint issues

* working through package and linux build issues

* more work

* wip

* fix packaged builds

* working through linux build errors

* wip

* wip

* wip

* fix mac and linux file limits

* iterate linux pipeline

* disable editor typing

* revert series to parallel

* remove optimize vscode from linux

* fix linting issues

* revert testing change

* add work round for new node

* readd packaging for extensions

* fix issue with angular not resolving decorator dependencies
2019-03-19 17:44:35 -07:00
Raj
25b1d4b673 #4565: Open notebook from Dashboard - can't close dirty notebook (#4568)
* #4565:"Don't save" doesn't close editor -Dashboard

* Misc change
2019-03-17 08:03:43 -07:00
Chris LaFreniere
b9d0602f55 Only show filename for notebook titlebar when opening from Open Notebook (#4556) 2019-03-15 17:45:06 -07:00
Alan Ren
5caf0b02f0 make connectiondialog react to provider event (#4544)
* make connectiondialog react to provider event

* fix unit test error

* code review comments
2019-03-15 14:47:23 -07:00
Matt Irvine
86bac90001 Merge VS Code 1.31.1 (#4283) 2019-03-15 13:09:45 -07:00
Anthony Dresser
4014c1d0ab Small strict null checking pass on a few files (#4293)
* fix some null checking

* fix various null strict checks

* move location fo sql files in json

* fix compile and more unused properties

* formatting

* small formatting changes

* readd types

* add comments for angular components

* formatting

* remove any decl
2019-03-14 18:18:32 -07:00
Anthony Dresser
0bf0e795ca More data explorer actions (#4307)
* adding context

* apply extension changes

* shimming disconnect

* add data explorer context menu and add disconnect to it

* clean up shim code; better handle errors

* remove tpromise

* simplify code

* add node context on data explorer

* formatting

* add new Query action

* fix various errors with how the context menus work

* add manage and new query

* add refresh command

* formatting
2019-03-14 17:19:37 -07:00
Kevin Cunnane
6f1a03587a Fix #4029 Ensure changeKernels always resolves, even in error states (#4488)
* Fix #4029 Ensure changeKernels always resolves, even in error states
This is necessary to unblock reverting the kernel on canceling  Python install
- startSession now correctly sets up kernel information, since a kernel is loaded there.
- Remove call to change kernel on session initialize. This isn't needed due to refactor
- Handle kernel change failure by attempting to fall back to old kernel
- ExtensionHost $startNewSession now ensures errors are sent across the wire.
- Update AttachTo and Kernel dropdowns so they handle kernel being available. This is needed since other changes mean the session is likely ready before these get going

* Fix to handle python cancel and load existing scenarios
- Made changes to handle failure flow when Python dialog is canceled
- Made changes to handle initial load fail. Kernel and Attach To dropdowns show No Kernel / None and you can choose a kernel
- Added error wrapping in ext host so that string errors make it across and aren't lost.
2019-03-14 13:07:08 -07:00
Kevin Cunnane
0131746919 Fix #4452 Notebook is reloaded with wrong kernel (#4480)
* Fix #4452 Notebook is reloaded with wrong kernel
- Await all extension registration before getting providers and providerId
To do this, we need to await way up in the NotebookInput, and promise the model that we'll have values eventually
2019-03-13 20:03:01 -07:00
Anthony Dresser
b6584c9ddf Change shutdown listeners (#4282)
* change shutdown to use proper notification

* change to use storage service

* remove unused imports

* fix test

* change shutdown methods to private

* remove unusde imports

* fix tests

* formatting
2019-03-13 15:15:51 -07:00
Karl Burtram
e9390dcd48 Update "Preview features" notification text (#4444) 2019-03-13 13:50:42 -07:00
Raj
ebd187ec06 #4363: Reopen notebook editors when ADS launched (#4424)
* #4363: Reopen notebook editors when ADS launched

* Code review changes
2019-03-12 23:02:37 -07:00
David Shiflet
58e5125cde Add scripted object name to query editor tab display (#4403)
* Add scripted object name to query editor tab display

* Update src/sql/parts/query/common/queryInput.ts

Co-Authored-By: shueybubbles <shueybubbles@hotmail.com>
2019-03-12 22:07:11 -04:00
Anthony Dresser
dadfbd2ddb add check to remove errors (#4412) 2019-03-12 15:32:41 -07:00
Raj
6a7df2f1ae Adding back save api (#4407)
* #4339: Kernel change event occurs after model load

* #4347: Code cleanup - Notebooks Save

* Remove save method from sqlops

* Adding save method to api's

* Adding save method to ext host

* Misc change
2019-03-12 13:07:10 -07:00
Kevin Cunnane
7226f25c67 Fix #4356 New Notebook from connection doesn't connect (#4364)
* Fix #4356 New Notebook from connection doesn't connect
Fix new notebook error by passing profile instead of ID.
- I could've just sent the ID over, but this fix sets the stage for disconnected connections to work (since we have enough info to properly connect).
- There's a bug in NotebookModel blocking the disconnected connection part working, but Yurong's in progress fixes will unblock this. Hence checking in as-is and working to properly unblock once that's in.

* Support connection profile in commandline service
- Added new context API for things that want to work on commandline and object explorer
- Refactored commandlineservice slightly to be async & have a simpler execution flow (far fewer if/else statements)

* Fix unit tests
- Fixed 2 issues raised by tests (sholdn't do new query if no profile passed, shouldn't error on new query failing)
- Updated unit tests to pass as expected given changes to the APIs.
2019-03-12 12:14:08 -07:00
Yurong He
118d2c7273 Fix #4047 Redesign notebook model to handle single client session (#4371)
* Start single client session based on the default kernel or saved kernel in NB.

* Added kernel displayName to standardKernel.
Modified name to allign wtih Juptyer Kernel.name.
So we can show the displayName during startup and use the name to start the session.

* Change session.OnSessionReady event in KernelDropDown

* Added model.KernelChnaged for switching kernel in the same provider

* Fixed session.Ready sequence

* Fixed merge issues

* Solve merged issue

* Fixed wrong kernel name in saved NB

* Added new event in Model to notify kernel change.
Toolbar depends on ModelReady to load

* Change attachTo to wait for ModelReady like KenelDropDown

* sanitizeSavedKernelInfo to fix invalid kernel and display_name. For example: PySpark1111 and PySpark 1111


* Added _contextsChangingEmitter to change loadContext msg when changing kernel

* Resolve PR comments
2019-03-11 17:59:13 -07:00
David Shiflet
b44d2b1bb3 Re-enabled command line service tests (#4387) 2019-03-11 19:31:11 -04:00
Chris LaFreniere
037c49e2c6 Warning for table max rows displayed (#4357)
* Warning for top rows

* change single to double quotes when calling localize method
2019-03-08 19:01:21 -08:00
Karl Burtram
26274e6c5d Fix connection dialog Saved Connections refresh timing (#4346) 2019-03-08 11:45:11 -08:00
Raj
036ffe595a #3920: Notebooks file save/save all/cache - for existing files (#4286)
* #3920: Notebooks file save

* Missed in merge

* #4290: Untitled save and native dirty implementation

* Misc changes

* Content Manager, notebooks extension and commented failed unit tests

* Removing modelLoaded event
2019-03-07 18:07:20 -08:00
Gene Lee
36e5bbb752 added 'fireOnTextChange' field to azdata.proposed.d.ts (#4341) 2019-03-07 16:03:50 -08:00
Alan Ren
addba0d007 remove the modelviewdialog namespace from azdata (#4301) 2019-03-06 21:32:05 -08:00
Anup N. Kamath
0a268f35bc Fix backup (#4274)
* check to see whether options is available

* removing options state and using _modelOptions

* removed additional space

* making options getter private as not intended to expose
2019-03-05 19:17:42 -08:00
Chris LaFreniere
e3709533b4 Add New Notebook to File Menu (#4287) 2019-03-05 17:42:35 -08:00
Anthony Dresser
da06a96630 Add Data Explorer Context and apply to disconnect (#4265)
* adding context

* apply extension changes

* shimming disconnect

* add data explorer context menu and add disconnect to it

* clean up shim code; better handle errors

* remove tpromise

* simplify code

* add node context on data explorer

* formatting

* fix various errors with how the context menus work
2019-03-05 17:09:00 -08:00
Karl Burtram
b4984d7f2d Update 'sqlops' to 'azdata' in Notebook Manager (#4275) 2019-03-04 12:45:34 -08:00