@adonis-agora/filter 1.0.0-rc.1 → 1.0.0-rc.3
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.
- package/CHANGELOG.md +12 -0
- package/dist/commands/agora_doctor.d.ts +23 -0
- package/dist/commands/agora_doctor.d.ts.map +1 -0
- package/dist/commands/agora_doctor.js +110 -0
- package/dist/commands/agora_doctor.js.map +1 -0
- package/dist/commands/filter_doctor.d.ts +8 -0
- package/dist/commands/filter_doctor.d.ts.map +1 -0
- package/dist/commands/filter_doctor.js +8 -0
- package/dist/commands/filter_doctor.js.map +1 -0
- package/dist/commands/main.d.ts +6 -4
- package/dist/commands/main.d.ts.map +1 -1
- package/dist/commands/main.js +6 -3
- package/dist/commands/main.js.map +1 -1
- package/dist/providers/filter_provider.d.ts +1 -1
- package/dist/providers/filter_provider.d.ts.map +1 -1
- package/dist/providers/filter_provider.js +4 -1
- package/dist/providers/filter_provider.js.map +1 -1
- package/dist/src/doctor/agora_doctor.d.ts +116 -0
- package/dist/src/doctor/agora_doctor.d.ts.map +1 -0
- package/dist/src/doctor/agora_doctor.js +685 -0
- package/dist/src/doctor/agora_doctor.js.map +1 -0
- package/dist/src/doctor/checks.d.ts +21 -0
- package/dist/src/doctor/checks.d.ts.map +1 -0
- package/dist/src/doctor/checks.js +207 -0
- package/dist/src/doctor/checks.js.map +1 -0
- package/dist/src/doctor/index.d.ts +5 -0
- package/dist/src/doctor/index.d.ts.map +1 -0
- package/dist/src/doctor/index.js +5 -0
- package/dist/src/doctor/index.js.map +1 -0
- package/dist/src/generate_client.d.ts +10 -0
- package/dist/src/generate_client.d.ts.map +1 -1
- package/dist/src/generate_client.js +33 -4
- package/dist/src/generate_client.js.map +1 -1
- package/dist/src/index.d.ts +1 -1
- package/dist/src/index.js +1 -1
- package/package.json +8 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
# @adonis-agora/filter
|
|
2
2
|
|
|
3
|
+
## 1.0.0-rc.3
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#148](https://github.com/DavideCarvalho/adonis-agora-filter/pull/148) [`7ac919c`](https://github.com/DavideCarvalho/adonis-agora-filter/commit/7ac919ceabf41976ae30e42a50c5a6f179502593) Thanks [@DavideCarvalho](https://github.com/DavideCarvalho)! - `agora:doctor`'s `filter.manifest` check no longer reports prettier-formatted clients as out of date. Generated clients now carry a `// Content hash: sha256:…` banner line (the hash of what the generator emitted), and the check compares that hash with a fresh generation, so any formatter is fine. Clients generated before this get a more tolerant shape comparison (quoted vs unquoted keys, quote escapes and a union's leading `|` are ignored). Run `node ace make:filter-client` once to add the hash.
|
|
8
|
+
|
|
9
|
+
## 1.0.0-rc.2
|
|
10
|
+
|
|
11
|
+
### Minor Changes
|
|
12
|
+
|
|
13
|
+
- [#146](https://github.com/DavideCarvalho/adonis-agora-filter/pull/146) [`efaae21`](https://github.com/DavideCarvalho/adonis-agora-filter/commit/efaae2137a53a8c85a66a9640d5606256ac82852) Thanks [@DavideCarvalho](https://github.com/DavideCarvalho)! - `node ace agora:doctor` (the shared Agora health check) and `node ace filter:doctor`, with the `filter.manifest` check: `config/filter.ts` loads, and the clients in `app/generated/filters` match it (out of date, missing or orphaned → run `make:filter-client`). New `@adonis-agora/filter/doctor` entry for `--no-boot`.
|
|
14
|
+
|
|
3
15
|
## 1.0.0-rc.1
|
|
4
16
|
|
|
5
17
|
### Minor Changes
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { BaseCommand } from '@adonisjs/core/ace';
|
|
2
|
+
import type { CommandOptions } from '@adonisjs/core/types/ace';
|
|
3
|
+
/**
|
|
4
|
+
* `node ace agora:doctor`: one health check for every installed `@adonis-agora` lib. Exit code `0`
|
|
5
|
+
* when nothing is an error (`--strict`: nor a warning), `1` otherwise, `2` when the doctor itself
|
|
6
|
+
* cannot run.
|
|
7
|
+
*/
|
|
8
|
+
export default class AgoraDoctor extends BaseCommand {
|
|
9
|
+
static commandName: string;
|
|
10
|
+
static description: string;
|
|
11
|
+
static options: CommandOptions;
|
|
12
|
+
/** A `<lib>:doctor` alias sets this to pre-filter its lib. */
|
|
13
|
+
protected presetLib: string | undefined;
|
|
14
|
+
json: boolean;
|
|
15
|
+
lib?: string;
|
|
16
|
+
deep: boolean;
|
|
17
|
+
only?: string;
|
|
18
|
+
strict: boolean;
|
|
19
|
+
verbose: boolean;
|
|
20
|
+
boot: boolean;
|
|
21
|
+
run(): Promise<void>;
|
|
22
|
+
}
|
|
23
|
+
//# sourceMappingURL=agora_doctor.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"agora_doctor.d.ts","sourceRoot":"","sources":["../../commands/agora_doctor.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,WAAW,EAAS,MAAM,oBAAoB,CAAC;AACxD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAS/D;;;;GAIG;AACH,MAAM,CAAC,OAAO,OAAO,WAAY,SAAQ,WAAW;IAClD,OAAgB,WAAW,SAAkB;IAC7C,OAAgB,WAAW,SAAkE;IAE7F,OAAgB,OAAO,EAAE,cAAc,CAAuB;IAE9D,8DAA8D;IAC9D,SAAS,CAAC,SAAS,EAAE,MAAM,GAAG,SAAS,CAAa;IAG5C,IAAI,EAAE,OAAO,CAAC;IAGd,GAAG,CAAC,EAAE,MAAM,CAAC;IAGb,IAAI,EAAE,OAAO,CAAC;IAGd,IAAI,CAAC,EAAE,MAAM,CAAC;IAGd,MAAM,EAAE,OAAO,CAAC;IAGhB,OAAO,EAAE,OAAO,CAAC;IAOjB,IAAI,EAAE,OAAO,CAAC;IAEP,GAAG,IAAI,OAAO,CAAC,IAAI,CAAC,CAwDlC;CACF"}
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
// agora-doctor command v1 — keep identical across libs
|
|
2
|
+
// Revision 1.1 (see the canonical README for the changelog).
|
|
3
|
+
// Every @adonis-agora lib ships this command (commands/agora_doctor.ts); whichever copy Ace loads
|
|
4
|
+
// last wins, and they all behave the same. Each repo's CI checks its sha256 against the pinned
|
|
5
|
+
// canonical one. Never edit a lib's copy: change the canonical copy, then re-copy it into every lib.
|
|
6
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
7
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
8
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
9
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
10
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
11
|
+
};
|
|
12
|
+
import { BaseCommand, flags } from '@adonisjs/core/ace';
|
|
13
|
+
import { AgoraDoctorUsageError, discoverDoctorChecks, readDoctorChecks, renderAgoraDoctor, runAgoraDoctor, } from '../src/doctor/agora_doctor.js';
|
|
14
|
+
/**
|
|
15
|
+
* `node ace agora:doctor`: one health check for every installed `@adonis-agora` lib. Exit code `0`
|
|
16
|
+
* when nothing is an error (`--strict`: nor a warning), `1` otherwise, `2` when the doctor itself
|
|
17
|
+
* cannot run.
|
|
18
|
+
*/
|
|
19
|
+
export default class AgoraDoctor extends BaseCommand {
|
|
20
|
+
static commandName = 'agora:doctor';
|
|
21
|
+
static description = 'Check the configuration of every installed @adonis-agora lib';
|
|
22
|
+
// The app is booted by `run()` itself, so `--no-boot` can skip it.
|
|
23
|
+
static options = { startApp: false };
|
|
24
|
+
/** A `<lib>:doctor` alias sets this to pre-filter its lib. */
|
|
25
|
+
presetLib = undefined;
|
|
26
|
+
async run() {
|
|
27
|
+
const err = (line) => process.stderr.write(`${line}\n`);
|
|
28
|
+
try {
|
|
29
|
+
let checks;
|
|
30
|
+
if (this.boot === false) {
|
|
31
|
+
checks = await discoverDoctorChecks(this.app);
|
|
32
|
+
}
|
|
33
|
+
else {
|
|
34
|
+
if (!this.app.isReady) {
|
|
35
|
+
try {
|
|
36
|
+
await this.app.boot();
|
|
37
|
+
await this.app.start(() => { });
|
|
38
|
+
}
|
|
39
|
+
catch (error) {
|
|
40
|
+
const reason = error instanceof Error ? error.message : String(error);
|
|
41
|
+
throw new AgoraDoctorUsageError(`the app did not boot (${reason}). Fix the boot error, or run with --no-boot.`);
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
checks = await readDoctorChecks(this.app.container);
|
|
45
|
+
}
|
|
46
|
+
const libs = (this.lib ?? this.presetLib)
|
|
47
|
+
?.split(',')
|
|
48
|
+
.map((name) => name.trim())
|
|
49
|
+
.filter(Boolean);
|
|
50
|
+
const { report, exitCode } = await runAgoraDoctor(this.app, checks, {
|
|
51
|
+
...(libs ? { libs } : {}),
|
|
52
|
+
...(this.only ? { only: this.only } : {}),
|
|
53
|
+
deep: this.deep === true,
|
|
54
|
+
noBoot: this.boot === false,
|
|
55
|
+
strict: this.strict === true,
|
|
56
|
+
});
|
|
57
|
+
if (this.json) {
|
|
58
|
+
process.stdout.write(`${JSON.stringify(report)}\n`);
|
|
59
|
+
}
|
|
60
|
+
else {
|
|
61
|
+
const fancy = process.stdout.isTTY === true && !process.env.NO_COLOR;
|
|
62
|
+
const c = this.colors;
|
|
63
|
+
process.stdout.write(renderAgoraDoctor(report, {
|
|
64
|
+
verbose: this.verbose === true,
|
|
65
|
+
fancy,
|
|
66
|
+
paint: {
|
|
67
|
+
green: (t) => c.green(t),
|
|
68
|
+
yellow: (t) => c.yellow(t),
|
|
69
|
+
red: (t) => c.red(t),
|
|
70
|
+
dim: (t) => c.dim(t),
|
|
71
|
+
bold: (t) => c.bold(t),
|
|
72
|
+
},
|
|
73
|
+
}));
|
|
74
|
+
}
|
|
75
|
+
this.exitCode = exitCode;
|
|
76
|
+
}
|
|
77
|
+
catch (error) {
|
|
78
|
+
if (!(error instanceof AgoraDoctorUsageError))
|
|
79
|
+
throw error;
|
|
80
|
+
err(`agora:doctor: ${error.message}`);
|
|
81
|
+
this.exitCode = 2;
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
__decorate([
|
|
86
|
+
flags.boolean({ description: 'Print one JSON object to stdout' })
|
|
87
|
+
], AgoraDoctor.prototype, "json", void 0);
|
|
88
|
+
__decorate([
|
|
89
|
+
flags.string({ description: 'Only these libs, comma separated (durable,payments)' })
|
|
90
|
+
], AgoraDoctor.prototype, "lib", void 0);
|
|
91
|
+
__decorate([
|
|
92
|
+
flags.boolean({ description: 'Also run checks that touch the database, Redis or the network' })
|
|
93
|
+
], AgoraDoctor.prototype, "deep", void 0);
|
|
94
|
+
__decorate([
|
|
95
|
+
flags.string({ description: 'Run one check by id' })
|
|
96
|
+
], AgoraDoctor.prototype, "only", void 0);
|
|
97
|
+
__decorate([
|
|
98
|
+
flags.boolean({ description: 'Fail (exit 1) on warnings too' })
|
|
99
|
+
], AgoraDoctor.prototype, "strict", void 0);
|
|
100
|
+
__decorate([
|
|
101
|
+
flags.boolean({ description: 'Show skipped checks and every message' })
|
|
102
|
+
], AgoraDoctor.prototype, "verbose", void 0);
|
|
103
|
+
__decorate([
|
|
104
|
+
flags.boolean({
|
|
105
|
+
description: 'Boot the app first; --no-boot checks the config only (when boot itself fails)',
|
|
106
|
+
default: true,
|
|
107
|
+
showNegatedVariantInHelp: true,
|
|
108
|
+
})
|
|
109
|
+
], AgoraDoctor.prototype, "boot", void 0);
|
|
110
|
+
//# sourceMappingURL=agora_doctor.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"agora_doctor.js","sourceRoot":"","sources":["../../commands/agora_doctor.ts"],"names":[],"mappings":"AAAA,uDAAuD;AACvD,6DAA6D;AAC7D,kGAAkG;AAClG,+FAA+F;AAC/F,qGAAqG;;;;;;;AAErG,OAAO,EAAE,WAAW,EAAE,KAAK,EAAE,MAAM,oBAAo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AGhB;IADP,KAAK,CAAC,OAAO,CAAC,EAAE,WAAW,EAAE,uCAAuC,EAAE,CAAC;4CAC/C;AAOjB;IALP,KAAK,CAAC,OAAO,CAAC;QACb,WAAW,EAAE,+EAA+E;QAC5F,OAAO,EAAE,IAAI;QACb,wBAAwB,EAAE,IAAI;KAC/B,CAAC;yCACoB"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import AgoraDoctor from './agora_doctor.js';
|
|
2
|
+
/** `node ace filter:doctor`: `agora:doctor` for `@adonis-agora/filter` only. */
|
|
3
|
+
export default class FilterDoctor extends AgoraDoctor {
|
|
4
|
+
static commandName: string;
|
|
5
|
+
static description: string;
|
|
6
|
+
protected presetLib: string | undefined;
|
|
7
|
+
}
|
|
8
|
+
//# sourceMappingURL=filter_doctor.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"filter_doctor.d.ts","sourceRoot":"","sources":["../../commands/filter_doctor.ts"],"names":[],"mappings":"AAAA,OAAO,WAAW,MAAM,mBAAmB,CAAC;AAE5C,gFAAgF;AAChF,MAAM,CAAC,OAAO,OAAO,YAAa,SAAQ,WAAW;IACnD,OAAgB,WAAW,SAAmB;IAC9C,OAAgB,WAAW,SAAkD;IAC7E,UAAmB,SAAS,EAAE,MAAM,GAAG,SAAS,CAAY;CAC7D"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import AgoraDoctor from './agora_doctor.js';
|
|
2
|
+
/** `node ace filter:doctor`: `agora:doctor` for `@adonis-agora/filter` only. */
|
|
3
|
+
export default class FilterDoctor extends AgoraDoctor {
|
|
4
|
+
static commandName = 'filter:doctor';
|
|
5
|
+
static description = 'Check the @adonis-agora/filter configuration';
|
|
6
|
+
presetLib = 'filter';
|
|
7
|
+
}
|
|
8
|
+
//# sourceMappingURL=filter_doctor.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"filter_doctor.js","sourceRoot":"","sources":["../../commands/filter_doctor.ts"],"names":[],"mappings":"AAAA,OAAO,WAAW,MAAM,mBAAmB,CAAC;AAE5C,gFAAgF;AAChF,MAAM,CAAC,OAAO,OAAO,YAAa,SAAQ,WAAW;IACnD,MAAM,CAAU,WAAW,GAAG,eAAe,CAAC;IAC9C,MAAM,CAAU,WAAW,GAAG,8CAA8C,CAAC;IAC1D,SAAS,GAAuB,QAAQ,CAAC;CAC7D"}
|
package/dist/commands/main.d.ts
CHANGED
|
@@ -1,19 +1,21 @@
|
|
|
1
1
|
import { ListLoader } from '@adonisjs/core/ace';
|
|
2
|
+
import AgoraDoctor from './agora_doctor.js';
|
|
2
3
|
import MakeFilter from './make_filter.js';
|
|
3
4
|
import MakeFilterClient from './make_filter_client.js';
|
|
4
5
|
/**
|
|
5
6
|
* The commands barrel for `@adonis-agora/filter`. An app registers it in its
|
|
6
7
|
* `adonisrc` via `rcFile.addCommand('@adonis-agora/filter/commands')`. A
|
|
7
8
|
* {@link ListLoader} exposes the `make:filter-client` command's metadata and
|
|
8
|
-
* constructors to the ace kernel: `make:filter` (scaffold a filter class)
|
|
9
|
-
* `make:filter-client` (emit the typed front-end builders)
|
|
9
|
+
* constructors to the ace kernel: `make:filter` (scaffold a filter class),
|
|
10
|
+
* `make:filter-client` (emit the typed front-end builders) and the `agora:doctor` /
|
|
11
|
+
* `filter:doctor` health check.
|
|
10
12
|
*
|
|
11
13
|
* `@adonisjs/core` is an *optional* peer of this otherwise framework-free core —
|
|
12
14
|
* only this `./commands` subpath imports it, so the main entrypoint stays
|
|
13
15
|
* dependency-free.
|
|
14
16
|
*/
|
|
15
|
-
declare const loader: ListLoader<typeof MakeFilter | typeof MakeFilterClient>;
|
|
17
|
+
declare const loader: ListLoader<typeof AgoraDoctor | typeof MakeFilter | typeof MakeFilterClient>;
|
|
16
18
|
export declare const getMetaData: () => Promise<import("@adonisjs/core/types/ace").CommandMetaData[]>;
|
|
17
|
-
export declare const getCommand: (metaData: import("@adonisjs/core/types/ace").CommandMetaData) => Promise<typeof MakeFilter | typeof MakeFilterClient | null>;
|
|
19
|
+
export declare const getCommand: (metaData: import("@adonisjs/core/types/ace").CommandMetaData) => Promise<typeof AgoraDoctor | typeof MakeFilter | typeof MakeFilterClient | null>;
|
|
18
20
|
export default loader;
|
|
19
21
|
//# sourceMappingURL=main.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"main.d.ts","sourceRoot":"","sources":["../../commands/main.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAChD,OAAO,UAAU,MAAM,kBAAkB,CAAC;AAC1C,OAAO,gBAAgB,MAAM,yBAAyB,CAAC;AAEvD
|
|
1
|
+
{"version":3,"file":"main.d.ts","sourceRoot":"","sources":["../../commands/main.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAChD,OAAO,WAAW,MAAM,mBAAmB,CAAC;AAE5C,OAAO,UAAU,MAAM,kBAAkB,CAAC;AAC1C,OAAO,gBAAgB,MAAM,yBAAyB,CAAC;AAEvD;;;;;;;;;;;GAWG;AACH,QAAA,MAAM,MAAM,8EAA4E,CAAC;AAEzF,eAAO,MAAM,WAAW,qEAAkC,CAAC;AAC3D,eAAO,MAAM,UAAU,oJAAiC,CAAC;eAE1C,MAAM"}
|
package/dist/commands/main.js
CHANGED
|
@@ -1,18 +1,21 @@
|
|
|
1
1
|
import { ListLoader } from '@adonisjs/core/ace';
|
|
2
|
+
import AgoraDoctor from './agora_doctor.js';
|
|
3
|
+
import FilterDoctor from './filter_doctor.js';
|
|
2
4
|
import MakeFilter from './make_filter.js';
|
|
3
5
|
import MakeFilterClient from './make_filter_client.js';
|
|
4
6
|
/**
|
|
5
7
|
* The commands barrel for `@adonis-agora/filter`. An app registers it in its
|
|
6
8
|
* `adonisrc` via `rcFile.addCommand('@adonis-agora/filter/commands')`. A
|
|
7
9
|
* {@link ListLoader} exposes the `make:filter-client` command's metadata and
|
|
8
|
-
* constructors to the ace kernel: `make:filter` (scaffold a filter class)
|
|
9
|
-
* `make:filter-client` (emit the typed front-end builders)
|
|
10
|
+
* constructors to the ace kernel: `make:filter` (scaffold a filter class),
|
|
11
|
+
* `make:filter-client` (emit the typed front-end builders) and the `agora:doctor` /
|
|
12
|
+
* `filter:doctor` health check.
|
|
10
13
|
*
|
|
11
14
|
* `@adonisjs/core` is an *optional* peer of this otherwise framework-free core —
|
|
12
15
|
* only this `./commands` subpath imports it, so the main entrypoint stays
|
|
13
16
|
* dependency-free.
|
|
14
17
|
*/
|
|
15
|
-
const loader = new ListLoader([MakeFilter, MakeFilterClient]);
|
|
18
|
+
const loader = new ListLoader([MakeFilter, MakeFilterClient, FilterDoctor, AgoraDoctor]);
|
|
16
19
|
export const getMetaData = loader.getMetaData.bind(loader);
|
|
17
20
|
export const getCommand = loader.getCommand.bind(loader);
|
|
18
21
|
export default loader;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"main.js","sourceRoot":"","sources":["../../commands/main.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAChD,OAAO,UAAU,MAAM,kBAAkB,CAAC;AAC1C,OAAO,gBAAgB,MAAM,yBAAyB,CAAC;AAEvD
|
|
1
|
+
{"version":3,"file":"main.js","sourceRoot":"","sources":["../../commands/main.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAChD,OAAO,WAAW,MAAM,mBAAmB,CAAC;AAC5C,OAAO,YAAY,MAAM,oBAAoB,CAAC;AAC9C,OAAO,UAAU,MAAM,kBAAkB,CAAC;AAC1C,OAAO,gBAAgB,MAAM,yBAAyB,CAAC;AAEvD;;;;;;;;;;;GAWG;AACH,MAAM,MAAM,GAAG,IAAI,UAAU,CAAC,CAAC,UAAU,EAAE,gBAAgB,EAAE,YAAY,EAAE,WAAW,CAAC,CAAC,CAAC;AAEzF,MAAM,CAAC,MAAM,WAAW,GAAG,MAAM,CAAC,WAAW,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;AAC3D,MAAM,CAAC,MAAM,UAAU,GAAG,MAAM,CAAC,UAAU,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;AAEzD,eAAe,MAAM,CAAC"}
|
|
@@ -15,7 +15,7 @@ import type { ApplicationService } from '@adonisjs/core/types';
|
|
|
15
15
|
* const page = await User.query().filterPaginate(userFilter, ctx)
|
|
16
16
|
* ```
|
|
17
17
|
*
|
|
18
|
-
* It also registers the filter developer tools on `@adonis-agora/agent`'s dev MCP endpoint when
|
|
18
|
+
* It also registers the `agora:doctor` checks, and the filter developer tools on `@adonis-agora/agent`'s dev MCP endpoint when
|
|
19
19
|
* that is installed.
|
|
20
20
|
*
|
|
21
21
|
* Register it in `adonisrc.ts` (`providers`). The free functions
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"filter_provider.d.ts","sourceRoot":"","sources":["../../providers/filter_provider.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;
|
|
1
|
+
{"version":3,"file":"filter_provider.d.ts","sourceRoot":"","sources":["../../providers/filter_provider.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAO/D;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,MAAM,CAAC,OAAO,OAAO,cAAc;;IACrB,SAAS,CAAC,GAAG,EAAE,kBAAkB;IAA7C,YAAsB,GAAG,EAAE,kBAAkB,EAAI;IAE3C,IAAI,kBAKT;CA2BF"}
|
|
@@ -1,4 +1,6 @@
|
|
|
1
1
|
import { registerFilterDevTools } from '../src/dev_tools/tools.js';
|
|
2
|
+
import { registerDoctorChecks } from '../src/doctor/agora_doctor.js';
|
|
3
|
+
import { filterDoctorChecks } from '../src/doctor/checks.js';
|
|
2
4
|
import { registerFilterMacros } from '../src/lucid_macros.js';
|
|
3
5
|
import { loadFilterManifest } from '../src/manifest.js';
|
|
4
6
|
/**
|
|
@@ -17,7 +19,7 @@ import { loadFilterManifest } from '../src/manifest.js';
|
|
|
17
19
|
* const page = await User.query().filterPaginate(userFilter, ctx)
|
|
18
20
|
* ```
|
|
19
21
|
*
|
|
20
|
-
* It also registers the filter developer tools on `@adonis-agora/agent`'s dev MCP endpoint when
|
|
22
|
+
* It also registers the `agora:doctor` checks, and the filter developer tools on `@adonis-agora/agent`'s dev MCP endpoint when
|
|
21
23
|
* that is installed.
|
|
22
24
|
*
|
|
23
25
|
* Register it in `adonisrc.ts` (`providers`). The free functions
|
|
@@ -31,6 +33,7 @@ export default class FilterProvider {
|
|
|
31
33
|
this.app = app;
|
|
32
34
|
}
|
|
33
35
|
async boot() {
|
|
36
|
+
await registerDoctorChecks(this.app.container, filterDoctorChecks());
|
|
34
37
|
const { ModelQueryBuilder } = await import('@adonisjs/lucid/orm');
|
|
35
38
|
registerFilterMacros(ModelQueryBuilder);
|
|
36
39
|
await this.#registerDevTools();
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"filter_provider.js","sourceRoot":"","sources":["../../providers/filter_provider.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,sBAAsB,EAAE,MAAM,2BAA2B,CAAC;AACnE,OAAO,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAC;AAC9D,OAAO,EAAE,kBAAkB,EAAE,MAAM,oBAAoB,CAAC;AAExD;;;;;;;;;;;;;;;;;;;;;;;GAuBG;AACH,MAAM,CAAC,OAAO,OAAO,cAAc;IACX,GAAG;IAAzB,YAAsB,GAAuB;mBAAvB,GAAG;IAAuB,CAAC;IAEjD,KAAK,CAAC,IAAI;QACR,MAAM,EAAE,iBAAiB,EAAE,GAAG,MAAM,MAAM,CAAC,qBAAqB,CAAC,CAAC;QAClE,oBAAoB,CAAC,iBAAiB,CAAC,CAAC;QACxC,MAAM,IAAI,CAAC,iBAAiB,EAAE,CA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AC;QACJ,CAAC;IACH,CAAC;CACF"}
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
import type { ApplicationService } from '@adonisjs/core/types';
|
|
2
|
+
/** The container binding the registry lives at. */
|
|
3
|
+
export declare const AGORA_DOCTOR_BINDING = "agora.doctor";
|
|
4
|
+
/** Bound as a VALUE under `'agora.doctor'`. Data only. */
|
|
5
|
+
export interface AgoraDoctorRegistry {
|
|
6
|
+
readonly version: 1;
|
|
7
|
+
readonly checks: AgoraDoctorCheck[];
|
|
8
|
+
}
|
|
9
|
+
export type AgoraDoctorStatus = 'ok' | 'warn' | 'error' | 'skip';
|
|
10
|
+
export interface AgoraDoctorCheck {
|
|
11
|
+
/** `'<lib>.<kebab>'`, unique and frozen for 1.x: `'durable.verify-tenant'`. */
|
|
12
|
+
id: string;
|
|
13
|
+
/** `'durable'`. The package is `@adonis-agora/<lib>` unless {@link package} says otherwise. */
|
|
14
|
+
lib: string;
|
|
15
|
+
/** The npm package, when it is not `@adonis-agora/<lib>`. */
|
|
16
|
+
package?: string;
|
|
17
|
+
title: string;
|
|
18
|
+
/** `'cheap'` (default) reads config, env and files only; `'deep'` touches a DB, Redis or the network. */
|
|
19
|
+
cost?: 'cheap' | 'deep';
|
|
20
|
+
run(app: ApplicationService): AgoraDoctorResult | AgoraDoctorResult[] | Promise<AgoraDoctorResult | AgoraDoctorResult[]>;
|
|
21
|
+
}
|
|
22
|
+
export interface AgoraDoctorResult {
|
|
23
|
+
status: AgoraDoctorStatus;
|
|
24
|
+
/** One line, no secrets, no stack. */
|
|
25
|
+
message: string;
|
|
26
|
+
/** One line: the exact change to make. */
|
|
27
|
+
fix?: string;
|
|
28
|
+
/** Absolute URL of the lib docs page. */
|
|
29
|
+
docs?: string;
|
|
30
|
+
}
|
|
31
|
+
/** One reported result. */
|
|
32
|
+
export interface AgoraDoctorReportEntry extends AgoraDoctorResult {
|
|
33
|
+
id: string;
|
|
34
|
+
lib: string;
|
|
35
|
+
title: string;
|
|
36
|
+
ms: number;
|
|
37
|
+
}
|
|
38
|
+
/** What `agora:doctor --json` prints. */
|
|
39
|
+
export interface AgoraDoctorReport {
|
|
40
|
+
version: 1;
|
|
41
|
+
env: string;
|
|
42
|
+
summary: Record<AgoraDoctorStatus, number>;
|
|
43
|
+
libs: Array<{
|
|
44
|
+
lib: string;
|
|
45
|
+
package: string;
|
|
46
|
+
version: string | null;
|
|
47
|
+
}>;
|
|
48
|
+
results: AgoraDoctorReportEntry[];
|
|
49
|
+
}
|
|
50
|
+
export interface AgoraDoctorOptions {
|
|
51
|
+
libs?: string[];
|
|
52
|
+
only?: string;
|
|
53
|
+
deep?: boolean;
|
|
54
|
+
/** The app was not booted (`--no-boot`): deep checks are reported as skipped, never run. */
|
|
55
|
+
noBoot?: boolean;
|
|
56
|
+
strict?: boolean;
|
|
57
|
+
/** Per-check budget in ms (default 5000, deep checks 15000). */
|
|
58
|
+
timeoutMs?: number;
|
|
59
|
+
deepTimeoutMs?: number;
|
|
60
|
+
}
|
|
61
|
+
/** A doctor problem that stops the run itself (exit 2). */
|
|
62
|
+
export declare class AgoraDoctorUsageError extends Error {
|
|
63
|
+
}
|
|
64
|
+
interface ContainerLike {
|
|
65
|
+
hasBinding(binding: string): boolean;
|
|
66
|
+
bindValue(binding: string, value: unknown): void;
|
|
67
|
+
make(binding: string): Promise<unknown>;
|
|
68
|
+
}
|
|
69
|
+
/**
|
|
70
|
+
* Add a lib's checks to the app's doctor registry, creating it when absent. Call it from a provider's
|
|
71
|
+
* `boot()` (Adonis does not await `register()`, so an async registration there can be lost). A
|
|
72
|
+
* registry of another version is left alone; a duplicate id is skipped.
|
|
73
|
+
*/
|
|
74
|
+
export declare function registerDoctorChecks(container: ContainerLike, checks: readonly AgoraDoctorCheck[]): Promise<void>;
|
|
75
|
+
/** The registered checks; throws {@link AgoraDoctorUsageError} on a registry of another version. */
|
|
76
|
+
export declare function readDoctorChecks(container: ContainerLike): Promise<AgoraDoctorCheck[]>;
|
|
77
|
+
/**
|
|
78
|
+
* The checks of every installed `@adonis-agora/*` package that publishes a `./doctor` entry
|
|
79
|
+
* (`export const agoraDoctorChecks`), imported from the app root without booting providers. A
|
|
80
|
+
* package whose entry fails to load is reported as an error (`<lib>.doctor-entry`), never skipped.
|
|
81
|
+
*/
|
|
82
|
+
export declare function discoverDoctorChecks(app: ApplicationService): Promise<AgoraDoctorCheck[]>;
|
|
83
|
+
/** The directory of `name` as Node would find it from `from` (walking up `node_modules`), real path. */
|
|
84
|
+
export declare function packageDir(name: string, from: string): Promise<string | null>;
|
|
85
|
+
/** The installed version of `name` resolved from `from`, or `null` when it is not installed. */
|
|
86
|
+
export declare function installedVersion(name: string, from: string): Promise<string | null>;
|
|
87
|
+
/**
|
|
88
|
+
* Whether `version` satisfies `range`, with node-semver's grammar and prereleases included (like
|
|
89
|
+
* `semver.satisfies(version, range, { includePrerelease: true })`). An unparsable range is `false`.
|
|
90
|
+
*/
|
|
91
|
+
export declare function satisfies(version: string, range: string): boolean;
|
|
92
|
+
/**
|
|
93
|
+
* The environment shown in the report, from the app itself: `production` when `app.inProduction`,
|
|
94
|
+
* `test` when `app.inTest`, else the app's node environment, and `development` when that is unset.
|
|
95
|
+
*/
|
|
96
|
+
export declare function environmentOf(app: Pick<ApplicationService, 'inProduction' | 'inTest' | 'nodeEnvironment'>): string;
|
|
97
|
+
/** Run the checks and build the report. Throws {@link AgoraDoctorUsageError} for an unknown `--only`. */
|
|
98
|
+
export declare function runAgoraDoctor(app: ApplicationService, registered: readonly AgoraDoctorCheck[], options?: AgoraDoctorOptions): Promise<{
|
|
99
|
+
report: AgoraDoctorReport;
|
|
100
|
+
exitCode: 0 | 1;
|
|
101
|
+
}>;
|
|
102
|
+
export interface Paint {
|
|
103
|
+
green(text: string): string;
|
|
104
|
+
yellow(text: string): string;
|
|
105
|
+
red(text: string): string;
|
|
106
|
+
dim(text: string): string;
|
|
107
|
+
bold(text: string): string;
|
|
108
|
+
}
|
|
109
|
+
/** The human report. `fancy` = colors and symbols (a TTY without `NO_COLOR`). */
|
|
110
|
+
export declare function renderAgoraDoctor(report: AgoraDoctorReport, options?: {
|
|
111
|
+
verbose?: boolean;
|
|
112
|
+
fancy?: boolean;
|
|
113
|
+
paint?: Paint;
|
|
114
|
+
}): string;
|
|
115
|
+
export {};
|
|
116
|
+
//# sourceMappingURL=agora_doctor.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"agora_doctor.d.ts","sourceRoot":"","sources":["../../../src/doctor/agora_doctor.ts"],"names":[],"mappings":"AASA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAE/D,mDAAmD;AACnD,eAAO,MAAM,oBAAoB,iBAAiB,CAAC;AAEnD,0DAA0D;AAC1D,MAAM,WAAW,mBAAmB;IAClC,QAAQ,CAAC,OAAO,EAAE,CAAC,CAAC;IACpB,QAAQ,CAAC,MAAM,EAAE,gBAAgB,EAAE,CAAC;CACrC;AAED,MAAM,MAAM,iBAAiB,GAAG,IAAI,GAAG,MAAM,GAAG,OAAO,GAAG,MAAM,CAAC;AAEjE,MAAM,WAAW,gBAAgB;IAC/B,+EAA+E;IAC/E,EAAE,EAAE,MAAM,CAAC;IACX,+FAA+F;IAC/F,GAAG,EAAE,MAAM,CAAC;IACZ,6DAA6D;IAC7D,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,KAAK,EAAE,MAAM,CAAC;IACd,yGAAyG;IACzG,IAAI,CAAC,EAAE,OAAO,GAAG,MAAM,CAAC;IACxB,GAAG,CACD,GAAG,EAAE,kBAAkB,GACtB,iBAAiB,GAAG,iBAAiB,EAAE,GAAG,OAAO,CAAC,iBAAiB,GAAG,iBAAiB,EAAE,CAAC,CAAC;CAC/F;AAED,MAAM,WAAW,iBAAiB;IAChC,MAAM,EAAE,iBAAiB,CAAC;IAC1B,sCAAsC;IACtC,OAAO,EAAE,MAAM,CAAC;IAChB,0CAA0C;IAC1C,GAAG,CAAC,EAAE,MAAM,CAAC;IACb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