matrix-org / matrix-org/mjolnir
TypeError: Utils.isRegExp is not a function
- Dominant language
- TypeScript
- Stars
- 445
- Forks
- 75
- Avg merge
- 2d 44m
- Merged PRs (30d)
- 3
Description
No matter how I try to run mjolnir, it always seems to fail right away with this error message:
```text
/opt/mjolnir/node_modules/config/lib/config.js:1006
} else if (Utils.isRegExp(parent)) {
^
TypeError: Utils.isRegExp is not a function
at _clone (/opt/mjolnir/node_modules/config/lib/config.js:1006:22)
at Config.cloneDeep (/opt/mjolnir/node_modules/config/lib/config.js:1046:10)
at /opt/mjolnir/node_modules/config/lib/config.js:1318:32
at Array.forEach ()
at util.extendDeep (/opt/mjolnir/node_modules/config/lib/config.js:1293:9)
at /opt/mjolnir/node_modules/config/lib/config.js:651:12
at Array.forEach ()
at util.loadFileConfigs (/opt/mjolnir/node_modules/config/lib/config.js:648:16)
at new Config (/opt/mjolnir/node_modules/config/lib/config.js:113:27)
at Object. (/opt/mjolnir/node_modules/config/lib/config.js:1510:31)
Node.js v23.0.0
```
This is on `v1.8.0` as well as `main`
Invocations I've tried:
- `node lib/index.js --mjolnir-config ./config/production.yaml`
- `/usr/bin/node /opt/mjolnir/lib/index.js --mjolnir-config /opt/mjolnir/config/production.yaml`
- `yarn run start:dev --mjolnir-config /opt/mjolnir/config/production.yaml`
\* This is a **Debian 12** system. I installed nodejs from apt, then `corepack enable` for yarn. I followed the [self-build guide](https://github.com/matrix-org/mjolnir/blob/main/docs/setup_selfbuild.md) and there were no errors until trying to run it.
Contributor guide
Research direction
Start with lib/index.js and the self-build guide, reproducing the startup commands with Node.js v23 on Debian 12. Inspect the reported failure in node_modules/config/lib/config.js and the project's dependency setup; done means the documented startup invocation works without the TypeError or the supported Node.js requirements are clearly established.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- node.js, typescript
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100