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

platform.bible extension poc #1003

Draft
wants to merge 47 commits into
base: develop
Choose a base branch
from
Draft

Conversation

hahn-kev
Copy link
Collaborator

@hahn-kev hahn-kev commented Aug 6, 2024

this adds FW Lite as a tab in platform.bible. It is hardcoded to open sena-3, and requies the local web server is running, at the moment platform.bible does not support extensions launching processes.

todo before merging in:

  • try to make the extension launch the backend
  • automate or document how to build an extension and how to develop the extension

Copy link

github-actions bot commented Aug 6, 2024

UI unit Tests

12 tests  ±0   12 ✅ ±0   0s ⏱️ ±0s
 4 suites ±0    0 💤 ±0 
 1 files   ±0    0 ❌ ±0 

Results for commit fa51551. ± Comparison against base commit 2f9974f.

♻️ This comment has been updated with latest results.

@hahn-kev hahn-kev linked an issue Aug 14, 2024 that may be closed by this pull request
…custom formatting for json patch change names.
…sion

# Conflicts:
#	frontend/viewer/src/FwDataProjectView.svelte
#	frontend/viewer/src/lib/search-bar/SearchBar.svelte
# Conflicts:
#	backend/FwLite/LocalWebApp/LocalWebAppServer.cs
#	frontend/viewer/src/FwDataProjectView.svelte
#	frontend/viewer/src/lib/search-bar/SearchBar.svelte
# Conflicts:
#	frontend/viewer/src/FwDataProjectView.svelte
# Conflicts:
#	frontend/viewer/src/lib/utils/search-params.ts
@myieye
Copy link
Contributor

myieye commented Sep 20, 2024

I was under the hopeful impression that we could maybe include the .NET backend as part of the extension as well. But...I can't find any documentation in that direction 🙁

@megahirt
Copy link
Contributor

We need @tjcouch-sil to help us figure out what is possible and possibly influence what changes we may need in order to include Lexbox Local backend into a PT extension installation.

@hahn-kev
Copy link
Collaborator Author

hahn-kev commented Sep 22, 2024

TJ recently told me that they support extensions launching their own processes, so we're supported just fine.

@hahn-kev hahn-kev marked this pull request as draft September 23, 2024 08:17
@tjcouch-sil
Copy link

Unfortunately I don't believe we have a guide wiki page written about elevated privileges like launching processes yet, but here is a brief explanation:

You can add to your manifest's elevatedPrivileges array different strings from ElevatedPrivilegeNames to receive access to the corresponding members of the ElevatedPrivileges property elevatedPrivileges on your activation function's context, the first parameter of your extension main file activate function. So you would want to add "createProcess" to your manifest's elevatedPrivileges array, which would then give you access to context.elevatedPrivileges.createProcess (if you don't have access, it will be undefined). It has fork and spawn straight from node's child_process library. It also has osData, which informs you of some important things related to launching processes like which operating system you're on.

You can click around in these links to see the TSDocs for these different types in that website. They're also available in VS Code via Intellisense (it's the same information).

Do note we don't currently close processes extensions spawn in development because of some technical limitations with how we're handling some things, but we do close processes extensions spawn in production. You can decide for now how you want to manage this in development haha sorry :p

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Build platform.bible extension
4 participants