krisfremen
01/20/2022, 3:22 AMkevins8
01/20/2022, 3:41 AMkrisfremen
01/20/2022, 3:43 AMkrisfremen
01/20/2022, 3:47 AMkevins8
01/20/2022, 4:19 AMkrisfremen
01/20/2022, 5:26 AMkrisfremen
01/20/2022, 5:27 AMkevins8
01/20/2022, 4:57 PMkrisfremen
01/20/2022, 5:06 PMNidoling
01/20/2022, 10:56 PMvscode.window.showQuickPick
in dnode.ts
, I get the following error
rejected promise not handled within 1 second: DendronError: disconnect
/private/var/folders/zp/c_kspb_11jg7pd997_yr1__40000gn/T/AppTranslocation/976BFBA6-4FE5-40A6-A0C5-085D195F0568/d/Visual Studio Code - Insiders.app/Contents/Resources/app/out/bootstrap-fork.js:5
stack trace: DendronError: disconnect
at ChildProcess.<anonymous> (/Users/tulingma/workspace/dendron/packages/api-server/lib/utils.js:141:24)
at ChildProcess.emit (events.js:315:20)
at ChildProcess.emit (domain.js:467:12)
at finish (internal/child_process.js:888:14)
at processTicksAndRejections (internal/process/task_queues.js:75:11)
As a test example, I added a new method (that isn't being used anywhere) in dnode.ts
static async testFun() {
await vscode.window.showQuickPick([], {
title: "Select Vault",
});
}
Then if you run Extension Integ Tests
, it leads to first error
Edit: Happens to other window
methods like await vscode.window.showErrorMessage("test");
kevins8
01/20/2022, 10:59 PMNidoling
01/20/2022, 11:01 PMkevins8
01/20/2022, 11:20 PMplugin-core
kevins8
01/20/2022, 11:20 PMkevins8
01/20/2022, 11:21 PMplugin-core
and follow the convention in [[Test|dendron://dendron.docs/pkg.plugin-core.qa.test]]kevins8
01/20/2022, 11:26 PMNidoling
01/20/2022, 11:27 PMvscode
in dnode.ts
, how do i do the vault prompting?Nidoling
01/20/2022, 11:27 PMdnode.spec.ts
SeriousBug
01/20/2022, 11:44 PMcompat.ts
for examples. You basically have to write your own objects that replicate VSCode, then convert them to VSCode objects in the plugin. The windowDecorations.ts
is a good example where we do this.kevins8
01/20/2022, 11:52 PMdnode
but in lookup
(same place where we currently do the schema match)Nidoling
01/21/2022, 12:03 AMgetNoteByPath
in enginev2.ts
. how will vault prompting work then?kevins8
01/21/2022, 12:08 AMcreateWithSchema
shouldn't prompt in that case but return a
ts
DendronError({message: "multiple schemas", data: [...]})
then it will be the responsibility of the caller to prompt the user and ask for a vault, and then call that function again.kevins8
01/21/2022, 12:10 AMdockthepod
01/21/2022, 1:54 AMSeriousBug
01/21/2022, 1:55 AMSeriousBug
01/21/2022, 1:56 AMjyeung
01/21/2022, 2:59 AMyarn bootstrap:bootstrap
in your repo's root directory): https://github.com/dendronhq/dendron/pull/2188
This change adds a husky hook on pre-push to do a circular dependency check. We've been working on getting rid of circular dependencies in the code base, and we're using a tool called madge to report on them.
To help with this effort, we're adding an extra step in the PR process to check to make sure we're not adding more circular dependencies. Details here: https://docs.dendron.so/notes/773e0b5a-510f-4c21-acf4-2d1ab3ed741e/#avoiding-circular-dependencies
Thanks!jyeung
01/21/2022, 3:06 AMPreviewProxy
class instead. Doc Notes updated here: https://docs.dendron.so/notes/a80f36d9-01d0-4c5a-a228-867b093a4913/#preview-panelSeriousBug
01/21/2022, 10:07 AMasWebviewUri
which creates URLs that allow the preview to access files, but we can only use this in the plugin. https://code.visualstudio.com/api/references/vscode-api#Webview
Right now we use the engine to render the note for the preview. This is good because it avoids running the heavy rendering code in the plugin and blocking it.
This creates a mismatch though, I can't use asWebviewUri
in the engine and I can't render the note in the preview. Any thoughts on how to get around this?
A few options come to mind:
- Preview parses the markdown and replaces the URIs first, then sends the markdown the engine, and finally passes the rendered HTML to the preview
- Plugin starts a worker thread to render the preview (not sure if we can share the webview object with the thread, needed for asWebviewUri
)
- Have some sort of reverse-API where the engine requests `asWebviewUri`d image URLs from the pluginsashasasha
01/21/2022, 4:44 PM