@forge/lint 5.12.0-next.22 → 5.12.0-next.24
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 +16 -0
- package/out/lint/linters/llm-module-linter/llm-linter-interface.d.ts +1 -1
- package/out/lint/linters/llm-module-linter/llm-linter-interface.d.ts.map +1 -1
- package/out/lint/linters/llm-module-linter/llm-linter-interface.js +1 -1
- package/out/lint/linters/llm-module-linter/llm-node-visitor.d.ts +1 -1
- package/out/lint/linters/llm-module-linter/llm-node-visitor.d.ts.map +1 -1
- package/out/lint/linters/llm-module-linter/llm-node-visitor.js +9 -12
- package/package.json +4 -4
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,21 @@
|
|
|
1
1
|
# @forge/lint
|
|
2
2
|
|
|
3
|
+
## 5.12.0-next.24
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies [428a2be]
|
|
8
|
+
- Updated dependencies [0c433a0]
|
|
9
|
+
- @forge/csp@5.3.0-next.3
|
|
10
|
+
- @forge/manifest@11.0.0-next.10
|
|
11
|
+
- @forge/cli-shared@8.9.0-next.19
|
|
12
|
+
|
|
13
|
+
## 5.12.0-next.23
|
|
14
|
+
|
|
15
|
+
### Minor Changes
|
|
16
|
+
|
|
17
|
+
- 003d118: Update LLM SDK name. Update to show single error
|
|
18
|
+
|
|
3
19
|
## 5.12.0-next.22
|
|
4
20
|
|
|
5
21
|
### Patch Changes
|
|
@@ -5,5 +5,5 @@ export interface LLMModuleLintCriteriaMatch extends LintCriteriaMatch {
|
|
|
5
5
|
export interface LLMModuleMatches {
|
|
6
6
|
[key: string]: LLMModuleLintCriteriaMatch[];
|
|
7
7
|
}
|
|
8
|
-
export declare const LLM_SDK_PACKAGE = "@
|
|
8
|
+
export declare const LLM_SDK_PACKAGE = "@forge/llm";
|
|
9
9
|
//# sourceMappingURL=llm-linter-interface.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"llm-linter-interface.d.ts","sourceRoot":"","sources":["../../../../src/lint/linters/llm-module-linter/llm-linter-interface.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAE3D,MAAM,WAAW,0BAA2B,SAAQ,iBAAiB;IACnE,IAAI,EAAE,KAAK,CAAC;CACb;AAED,MAAM,WAAW,gBAAgB;IAC/B,CAAC,GAAG,EAAE,MAAM,GAAG,0BAA0B,EAAE,CAAC;CAC7C;AAED,eAAO,MAAM,eAAe,
|
|
1
|
+
{"version":3,"file":"llm-linter-interface.d.ts","sourceRoot":"","sources":["../../../../src/lint/linters/llm-module-linter/llm-linter-interface.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAE3D,MAAM,WAAW,0BAA2B,SAAQ,iBAAiB;IACnE,IAAI,EAAE,KAAK,CAAC;CACb;AAED,MAAM,WAAW,gBAAgB;IAC/B,CAAC,GAAG,EAAE,MAAM,GAAG,0BAA0B,EAAE,CAAC;CAC7C;AAED,eAAO,MAAM,eAAe,eAAe,CAAC"}
|
|
@@ -3,7 +3,7 @@ import { LLMModuleLintCriteriaMatch } from './llm-linter-interface';
|
|
|
3
3
|
import { TSESTree } from '@typescript-eslint/typescript-estree';
|
|
4
4
|
export declare class LlmNodeVisitor implements NodeVisitor<LLMModuleLintCriteriaMatch> {
|
|
5
5
|
visit(node: TSESTree.Node, _parent: TSESTree.Node | undefined, onMatchCallback: (llmModuleCall: LLMModuleLintCriteriaMatch) => void): void;
|
|
6
|
-
private
|
|
6
|
+
private isLLMSDKPackageImport;
|
|
7
7
|
private isImportSpecifier;
|
|
8
8
|
}
|
|
9
9
|
//# sourceMappingURL=llm-node-visitor.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"llm-node-visitor.d.ts","sourceRoot":"","sources":["../../../../src/lint/linters/llm-module-linter/llm-node-visitor.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,2BAA2B,CAAC;AACxD,OAAO,EAAmB,0BAA0B,EAAE,MAAM,wBAAwB,CAAC;AACrF,OAAO,EAAkB,QAAQ,EAAE,MAAM,sCAAsC,CAAC;AAEhF,qBAAa,cAAe,YAAW,WAAW,CAAC,0BAA0B,CAAC;IACrE,KAAK,CACV,IAAI,EAAE,QAAQ,CAAC,IAAI,EACnB,OAAO,EAAE,QAAQ,CAAC,IAAI,GAAG,SAAS,EAClC,eAAe,EAAE,CAAC,aAAa,EAAE,0BAA0B,KAAK,IAAI;
|
|
1
|
+
{"version":3,"file":"llm-node-visitor.d.ts","sourceRoot":"","sources":["../../../../src/lint/linters/llm-module-linter/llm-node-visitor.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,2BAA2B,CAAC;AACxD,OAAO,EAAmB,0BAA0B,EAAE,MAAM,wBAAwB,CAAC;AACrF,OAAO,EAAkB,QAAQ,EAAE,MAAM,sCAAsC,CAAC;AAEhF,qBAAa,cAAe,YAAW,WAAW,CAAC,0BAA0B,CAAC;IACrE,KAAK,CACV,IAAI,EAAE,QAAQ,CAAC,IAAI,EACnB,OAAO,EAAE,QAAQ,CAAC,IAAI,GAAG,SAAS,EAClC,eAAe,EAAE,CAAC,aAAa,EAAE,0BAA0B,KAAK,IAAI;IActE,OAAO,CAAC,qBAAqB;IAI7B,OAAO,CAAC,iBAAiB;CAM1B"}
|
|
@@ -5,20 +5,17 @@ const llm_linter_interface_1 = require("./llm-linter-interface");
|
|
|
5
5
|
const typescript_estree_1 = require("@typescript-eslint/typescript-estree");
|
|
6
6
|
class LlmNodeVisitor {
|
|
7
7
|
visit(node, _parent, onMatchCallback) {
|
|
8
|
-
if (this.
|
|
9
|
-
node.specifiers.
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
}
|
|
17
|
-
}
|
|
18
|
-
});
|
|
8
|
+
if (this.isLLMSDKPackageImport(node) && 'specifiers' in node) {
|
|
9
|
+
const specifier = node.specifiers.find((spec) => this.isImportSpecifier(spec));
|
|
10
|
+
if (specifier?.loc) {
|
|
11
|
+
onMatchCallback({
|
|
12
|
+
type: 'llm',
|
|
13
|
+
...specifier.loc.start
|
|
14
|
+
});
|
|
15
|
+
}
|
|
19
16
|
}
|
|
20
17
|
}
|
|
21
|
-
|
|
18
|
+
isLLMSDKPackageImport(node) {
|
|
22
19
|
return node.type === typescript_estree_1.AST_NODE_TYPES.ImportDeclaration && node.source.value === llm_linter_interface_1.LLM_SDK_PACKAGE;
|
|
23
20
|
}
|
|
24
21
|
isImportSpecifier(specifier) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@forge/lint",
|
|
3
|
-
"version": "5.12.0-next.
|
|
3
|
+
"version": "5.12.0-next.24",
|
|
4
4
|
"description": "Linting for forge apps",
|
|
5
5
|
"main": "out/index.js",
|
|
6
6
|
"license": "SEE LICENSE IN LICENSE.txt",
|
|
@@ -19,10 +19,10 @@
|
|
|
19
19
|
"eslint-plugin-import": "^2.29.1"
|
|
20
20
|
},
|
|
21
21
|
"dependencies": {
|
|
22
|
-
"@forge/cli-shared": "8.9.0-next.
|
|
23
|
-
"@forge/csp": "5.3.0-next.
|
|
22
|
+
"@forge/cli-shared": "8.9.0-next.19",
|
|
23
|
+
"@forge/csp": "5.3.0-next.3",
|
|
24
24
|
"@forge/egress": "2.1.1",
|
|
25
|
-
"@forge/manifest": "11.0.0-next.
|
|
25
|
+
"@forge/manifest": "11.0.0-next.10",
|
|
26
26
|
"@typescript-eslint/typescript-estree": "^5.62.0",
|
|
27
27
|
"array.prototype.flatmap": "^1.3.3",
|
|
28
28
|
"@atlassian/atlassian-openapi": "^1.0.6",
|