inventree-report-lsp-plugin
A report editor plugin that is powered by django-template-lsp.
⚙️ Installation
- Install the
inventree-report-lsp-pluginfrom the Admin Center > Plugins > Install plugin. (Make sure the user interface plugin integration is enabled.) - Now the LSP server needs to be started separately via the
inventree-report-lspcmd and the requests to/plugins/report-lsp/wsneed to be proxied to it. If you're using the official docker stack, follow the guide below:
[!IMPORTANT] At least InvenTree v0.18.0 is required to use this plugin.
🐳 Docker
Add this extra container to the docker-compose.yml file:
inventree-report-lsp:
image: inventree/inventree:${INVENTREE_TAG:-stable}
container_name: inventree-report-lsp
command: /bin/bash -c "invoke plugins && inventree-report-lsp"
env_file:
- .env
volumes:
- ${INVENTREE_EXT_VOLUME}:/home/inventree/data:z
restart: unless-stopped
Add this proxy_route to the Caddyfile:
forward_auth {$INVENTREE_SERVER:"http://inventree-server:8000"} {
uri /auth/
}
}
+ reverse_proxy /plugin/report-lsp/ws "http://inventree-report-lsp:8765"
# All other requests are proxied to the InvenTree server
reverse_proxy {$INVENTREE_SERVER:"http://inventree-server:8000"} {
🏃 Usage
Goto the Admin Center > Label Templates or Report Templates. Click on any in the table and select the "Report Editor". For the first load, this can take some time (up to ~30s) until the data is collected. The status bar at the bottom should show LSP Running (Connected) when its ready.
🧑💻 Development
For this plugin to work in development, the inventree source has to be patched temporary:
-
Add this to the InvenTree
vite.config.ts:proxy: { '/media': { target: 'http://localhost:8000', changeOrigin: true, secure: true }, + '/static/plugins/report-lsp/dist/': { + target: 'http://localhost:5212', + changeOrigin: true, + secure: true, + ws: true + }, + "/plugin/report-lsp/ws": { + target: "http://localhost:8765", + changeOrigin: true, + secure: true, + ws: true, + } },
-
Remove Strict Mode temporary from
src/frontend/src/main.tsx:ReactDOM.createRoot(document.getElementById('root') as HTMLElement).render( - <React.StrictMode> <MainView /> - </React.StrictMode> );
-
Set the
INVENTREE_REPORT_LSP_DEVtoTruebefore starting the dev server -
Install this package as editable pip package into your venv via
pip install -e path/to/the/inventree-report-lsp-plugin
-
Install frontend dependencies via
cd frontend && npm ci -
Run the LSP in the background by invoking the
inventree-report-lspcommand in a terminal where the venv is activated. (If you want to use a custom djlsp instance because you want to do changes there, you need to specify theINVENTREE_DJANGO_LSP_SERVER_CMDenv variable. E.g./path/to/django-template-lsp/env/bin/djlsp) -
Run the Frontend dev server via
cd frontend && npm run dev
Metadata
Release files for inventree-report-lsp-plugin 0.1.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| inventree_report_lsp_plugin-0.1.2.tar.gz | 10.3 MB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| inventree_report_lsp_plugin-0.1.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 20.7 MB
Release files / inventree_report_lsp_plugin-0.1.2.tar.gz
| Download URL | inventree_report_lsp_plugin-0.1.2.tar.gz |
|---|---|
| Size | 10.3 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
071bf1768b22dea9bf80fb441810a587794fe688ffb438749c0d3b2aaa024850
|
|
BLAKE2b-256 checksum How to use checksums |
d431cd80d111f6072fc529a7f2228028200023bc482b81c805ba06174744041a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.12.9
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jan 15, 2026.
Transparency logRelease files / inventree_report_lsp_plugin-0.1.2-py3-none-any.whl
| Download URL | inventree_report_lsp_plugin-0.1.2-py3-none-any.whl |
|---|---|
| Size | 10.4 MB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
f8150337ef8ae82cff19ceafbf3bf76abdf811c7151eb882925de148a3337909
|
|
BLAKE2b-256 checksum How to use checksums |
c3f4cd4a44d272ce4c355e3ce87e6f3b3d0e9133d86fc50767ab76d33b26d310
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.12.9
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jan 15, 2026.
Transparency log