bmad-plus 0.18.0 → 0.20.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,6 @@
1
+ - **Privilege.** Containers running as root without need; `privileged: true`, added capabilities, host network or PID namespace; the Docker socket mounted into a container (root on the host).
2
+ - **Images.** Base images on `latest` or an unpinned tag; packages installed without cleanup or version pins where reproducibility matters; secrets passed as build arguments or copied into a layer.
3
+ - **Exposure.** Ports published on `0.0.0.0` for services that should stay internal (databases, caches, admin APIs); missing network separation between stacks.
4
+ - **Health and restart.** No health check for a service others depend on; `depends_on` without a health condition; restart policies that loop a crashing container.
5
+ - **Data.** Volumes for stateful services missing or anonymous; host paths mounted read-write where read-only suffices.
6
+ - **Resources.** No memory or CPU limits on a shared host; Kubernetes pods without requests/limits, probes or a `securityContext` (`runAsNonRoot`, `readOnlyRootFilesystem`).
@@ -0,0 +1,10 @@
1
+ Look for what the diff changes in behaviour, not how it reads.
2
+
3
+ - **Callers.** Search every caller of a changed function, export, route, command or schema. A signature, return shape or error type that changed is a defect at the caller that was not updated.
4
+ - **Removed behaviour.** Read what the diff deletes: a check, a branch, a cleanup, a log that an operator relies on. Deleted protection is the most often missed defect.
5
+ - **Boundaries.** Empty input, one element, the last element, the maximum size, a missing optional field, a concurrent second call, a retry after a partial failure.
6
+ - **Errors.** An error swallowed, logged and ignored, or turned into a success value. A failure path that leaves state half-written.
7
+ - **Trust.** Data that crosses a boundary (request, file, environment, another service, a model's output) and reaches a query, a command, a path, HTML or a permission decision without validation.
8
+ - **Tests.** A changed behaviour whose test still passes because it mocks the changed path, asserts nothing about the new case, or is skipped.
9
+
10
+ Do not report formatting, naming or style a linter enforces, and do not propose rewrites the change did not need.
@@ -0,0 +1,36 @@
1
+ # Built-in review checklists, applied by path. Every matching rule applies to a file.
2
+ # A project adds, replaces (same id) or disables rules in _bmad/review-rules.yaml.
3
+ schema: bmad-plus/review-rules/1
4
+ rules:
5
+ - id: general
6
+ title: Every change
7
+ globs: ['**']
8
+ doc: general.md
9
+ - id: javascript-typescript
10
+ title: JavaScript and TypeScript
11
+ globs: ['**/*.{js,cjs,mjs,jsx,ts,cts,mts,tsx}', '**/*.{vue,svelte}']
12
+ doc: javascript-typescript.md
13
+ - id: python
14
+ title: Python
15
+ globs: ['**/*.{py,pyi}']
16
+ doc: python.md
17
+ - id: sql-and-migrations
18
+ title: SQL, queries and migrations
19
+ globs: ['**/*.sql', '**/{migrations,migrate,db/migrate}/**', '**/*.prisma', '**/schema.rb']
20
+ doc: sql-and-migrations.md
21
+ - id: shell
22
+ title: Shell and PowerShell scripts
23
+ globs: ['**/*.{sh,bash,zsh,ps1,psm1}', '**/{Makefile,makefile}']
24
+ doc: shell.md
25
+ - id: ci-workflows
26
+ title: CI workflows
27
+ globs: ['.github/workflows/**/*.{yml,yaml}', '**/.gitlab-ci.yml', '**/{bitbucket-pipelines.yml,azure-pipelines.yml}']
28
+ doc: ci-workflows.md
29
+ - id: containers
30
+ title: Containers and deployment manifests
31
+ globs: ['**/{Dockerfile,Containerfile}', '**/*.dockerfile', '**/{docker-,}compose*.{yml,yaml}', '**/{k8s,kubernetes,helm,charts}/**/*.{yml,yaml}']
32
+ doc: containers.md
33
+ - id: configuration
34
+ title: Configuration and dependency manifests
35
+ globs: ['**/*.{json,yml,yaml,toml,ini,properties}', '**/.env.example', '**/{package.json,pyproject.toml,requirements*.txt,go.mod,Cargo.toml,composer.json}']
36
+ doc: configuration.md
@@ -0,0 +1,7 @@
1
+ - **Async.** A promise that is created but not awaited or returned; `forEach` with an async callback; an `await` inside a loop that should run in parallel, or `Promise.all` where one failure must not cancel the others (`allSettled`). Unhandled rejections in event handlers and timers.
2
+ - **Nullish values.** Property access on a value that can be `undefined` after an `await`, a `find`, a map lookup or an optional API field; `||` used where `0`, `''` or `false` are valid values and `??` was meant.
3
+ - **Equality and numbers.** Loose equality across types; floating-point money; `parseInt` without a radix or on user input without a `NaN` check; array index arithmetic off by one.
4
+ - **Mutation.** A function that mutates its argument or a shared default object; sorting or splicing an array the caller still uses; state mutated in a React render or a reducer.
5
+ - **Injection.** `innerHTML`, `dangerouslySetInnerHTML`, `v-html`, template literals building SQL, shell commands through `exec` or `shell: true`, `eval`/`new Function`, a user-controlled path reaching `fs` without confinement, a user-controlled URL fetched by the server (SSRF), `Object.assign`/spread of untrusted keys (`__proto__`).
6
+ - **Types that lie.** `as` casts, non-null assertions (`!`) and `any` that hide a real `undefined` or a wrong shape at runtime.
7
+ - **Resources.** Listeners, intervals, streams, file handles or database connections opened without a matching close on every path, including errors.
@@ -0,0 +1,6 @@
1
+ - **Defaults and scope.** Mutable default arguments; a loop variable captured late by a closure; a module-level object mutated per request.
2
+ - **Exceptions.** Bare `except:` or `except Exception` that swallows and continues; `raise` without `from` that loses the cause; cleanup that is not in `finally` or a context manager.
3
+ - **Resources.** Files, sockets, database cursors and locks not managed by `with`; a subprocess whose output is never drained.
4
+ - **Injection.** SQL built with f-strings or `%`; `subprocess` with `shell=True` or a string command built from input; `pickle`, `yaml.load` without a safe loader, `eval`/`exec` on untrusted data; `os.path.join` with an absolute user path; `tarfile`/`zipfile` extraction without member path checks.
5
+ - **Types and values.** `None` returned on one path and used unconditionally; integer division where a float was meant; naive and aware datetimes compared; timezones assumed.
6
+ - **Concurrency.** Shared state touched from threads or async tasks without a lock; a blocking call inside an `async def`.
@@ -0,0 +1,6 @@
1
+ - **Failure handling.** Bash without `set -euo pipefail` (or an explicit reason); a failing command in a pipeline hidden by the last stage; PowerShell without `$ErrorActionPreference = 'Stop'` where errors must stop the script; native exit codes (`$LASTEXITCODE`) not checked.
2
+ - **Quoting.** Unquoted variables and command substitutions that split on spaces or expand globs; `eval` or `Invoke-Expression` on data.
3
+ - **Destructive commands.** `rm -rf`, `Remove-Item -Recurse`, `git reset --hard`, `DROP` or deploy commands on a path or target built from a variable that can be empty or wrong.
4
+ - **Secrets.** Tokens passed on the command line (visible in process lists and logs), echoed, or written to world-readable files; `set -x` in a script that handles credentials.
5
+ - **Portability.** Bash-only syntax under `#!/bin/sh`; GNU-only flags on macOS; PowerShell 7 syntax (`&&`, `??`, ternary) in scripts run by Windows PowerShell 5.1; CRLF line endings in a script run by Linux.
6
+ - **Temporary files.** Predictable names in shared directories instead of `mktemp`/`New-TemporaryFile`, and no cleanup trap.
@@ -0,0 +1,6 @@
1
+ - **Parameters.** Any value reaching a query must be bound, never concatenated; identifiers (table, column, sort order) chosen from an allow-list.
2
+ - **Scope of writes.** An `UPDATE` or `DELETE` whose `WHERE` can match more rows than intended, or none at all silently; a missing tenant or owner filter.
3
+ - **Migrations.** A migration that locks a large table, drops or renames a column still read by the running version, adds a `NOT NULL` column without a default or backfill, or cannot be rolled back. Data migrations must be idempotent and safe to rerun.
4
+ - **Transactions.** Several writes that must succeed together outside a transaction; a transaction held open across a network call.
5
+ - **Performance.** A new filter or join on a column without an index; a query inside a loop (N+1); an unbounded result set returned to a caller.
6
+ - **Nulls.** Comparisons with `NULL` using `=`; aggregates or `NOT IN` over nullable columns.