Hi.
We’re working on a custom module with skills, actions, hooks etc.
We do this in a separate project/repo “botpress-module”, which is located next to a local botpress installation. We put a symlink into botpress/modules under a specific name to make our custom module available in botpress.
- botpress-module <- our “foo” module, watched and recompiled via module-builder
- botpress
- modules
- foo <- symlink to …/…/botpress-module
- modules
To build our module, we depend on "module-builder": "file:../botpress/build/module-builder"
This does not work with the latest versions because of this commit: https://github.com/botpress/botpress/commit/35f23a1980f186c7b8bd92b3076e739c63afb8f9
The commit introduces some hardcoded overrides on loaded tsconfig settings, assuming only the default use case and effectively ignoring our own use-case and configuration. During compilation, the typescript compiler fails due to incorrect relative paths.
One solution I found was to somehow provide our own module-builder and use that - be it a fork, or as in our case, a local package in a yarn workspace - where we commented out the overrides introduced by said commit.
- botpress
- packages
- module-builder
- botpress-module
However, for now we simply stick with botpress 12.5.0 anyways, which is before the commit and change. We might fall back to the modified module-builder, but it’s really a suboptimal situation. Also, we don’t have more capacity to investigate and debug that particular issue, so I hope for some help in the forum here.
What is the recommended way of developing your custom module, where would you place the module in the filesystem? How would you make it available to botpress?
The approach we currently use - keep module outside of botpress, link it into botpress/(internal-?)modules
- is it a silly approach, or basically the right direction?
Thanks in advance, I appreciate any tips and feedback!