mtxr / vscode-sqltools

Database management for VSCode
https://vscode-sqltools.mteixeira.dev?utm_source=github&utm_medium=homepage-link
MIT License
1.5k stars 302 forks source link

Upgrade typescript and cut some weight from the packed extension #970

Closed mtxr closed 2 years ago

mtxr commented 2 years ago

Describe here what is this PR about and what we are achieving merging this.

Like I mentioned before, there is code in the extension no longer being executed. Before releasing 0.25, I believe we should remove it.


Thank you for your contribution! Before submitting this PR, please make sure:

gjsjohnmurray commented 2 years ago

@mtxr I've pushed a few changes I needed to make so that the pack:all script would run on my Windows dev workstation. But I'm finding that the driver VSIXes are broken. For example if I install the 0.25.0 VSIX of the main extension and only the 0.4.0 VSIX of the SQLite driver (leaving the other bundled ones at the latest Marketplace versions, 0.3.0) then the 0.3.0 drivers register OK but the 0.4.0 one fails, Messages in the log:

[1663178193535] INFO  (ls): REQUEST RECEIVED => ls/RegisterPlugin
[1663178193535] INFO  (ls): request to register plugin: "c:\Users\JohnM\.vscode\extensions\mtxr.sqltools-driver-sqlite-0.4.0\out\ls\plugin.js"
[1663178193680] ERROR (ls): Error registering plugin: {}
    error: {}
[1663178193680] ERROR (ext): ERROR: Error loading plugin SQLite Plugin Request ls/RegisterPlugin failed with message: ls is not defined, {"code":-32603}
    ns: "error-handler"
[1663178194540] INFO  (ext): EXECUTING COMMAND => sqltools.refreshTree
[1663178194540] INFO  (ext): Connection explorer changed. Will be updated.
    ns: "conn-man:explorer"
[1663178204609] INFO  (ext): EXECUTING COMMAND => sqltools.showOutputChannel

The output from my yarn run start has this warning that looks significant:

ext:
  1 asset
  364 modules
  ext (webpack 5.74.0) compiled successfully in 11388 ms

ls:
  1 asset
  172 modules

  WARNING in ../packages/language-server/src/server.ts 64:53-60
  Critical dependency: require function is used in a way in which dependencies cannot be statically extracted

  ls (webpack 5.74.0) compiled with 1 warning in 11763 ms

ui:
...

Are you able to run the VSIXes you build?

mtxr commented 2 years ago

I know how to fix it. Let me take care