Skip to content

Conversation

newfish-cmyk
Copy link
Collaborator

No description provided.

@newfish-cmyk newfish-cmyk changed the title Node generate add ai generate node Aug 20, 2025
Copy link

github-actions bot commented Aug 20, 2025

Preview sandbox Image:

registry.cn-hangzhou.aliyuncs.com/fastgpt/fastgpt-pr:fatsgpt_sandbox_52bd5e9e8fe81a522111288077689104c6b06670

Copy link

github-actions bot commented Aug 20, 2025

Preview mcp_server Image:

registry.cn-hangzhou.aliyuncs.com/fastgpt/fastgpt-pr:fatsgpt_mcp_server_52bd5e9e8fe81a522111288077689104c6b06670

Copy link

github-actions bot commented Aug 20, 2025

Preview fastgpt Image:

registry.cn-hangzhou.aliyuncs.com/fastgpt/fastgpt-pr:fatsgpt_52bd5e9e8fe81a522111288077689104c6b06670

@newfish-cmyk newfish-cmyk marked this pull request as ready for review August 21, 2025 08:07
Copy link
Contributor

gru-agent bot commented Aug 21, 2025

TestGru Assignment

Summary

Link CommitId Status Reason
Detail c1bb3b7 ✅ Finished

History Assignment

Files

File Pull Request
projects/app/src/web/common/api/fetch.ts ❌ Failed (The test job failed because the test file could not import the source file due to a module resolution or environmental issue. The error message indicates that Vitest could not resolve the path '../../../../projects/app/src/web/common/api/fetch' from the test file. This is not a bug in the source code or the test code itself, but rather a problem with the test environment configuration, such as incorrect path resolution, missing files, or misconfigured project structure.)
projects/app/src/web/core/workflow/utils.ts ❌ Failed (The test job failed due to an import resolution error: vitest could not resolve the import '../../../../projects/app/src/web/core/workflow/utils' from the test file. This is an environmental or configuration issue (such as incorrect path, missing file, or misconfigured module resolution), not a bug in the source code or the test code itself. The test file syntax and coverage are correct, and the source code for 'extractCodeFromMarkdown' is present and matches the test expectations.)
projects/app/src/web/core/workflow/api/copilot.ts 🔴 Closed #5513
projects/app/src/pages/api/core/workflow/copilot/testCode.ts ❌ Failed (The test job failed because the test runner could not resolve the source file '../../../../../projects/app/src/pages/api/core/workflow/copilot/testCode' from the test file. The error message indicates a module resolution or environmental issue (such as a missing file, incorrect path, or misconfigured module alias), not a bug in the source code or the test code itself. The test code is comprehensive and correct, and there is no indication of a bug in the implementation.)
projects/app/src/pages/api/core/ai/optimizeCode.ts ❌ Failed (The test job failed due to an import path resolution error: 'Does the file exist?'. The error message indicates that Vitest could not resolve or find the source file at '../../../../projects/app/src/pages/api/core/ai/optimizeCode' when running the test. This is an environmental or configuration issue (such as missing files, incorrect paths, or monorepo setup problems), not a bug in the source code or the test logic itself.)

Tip

You can @gru-agent and leave your feedback. TestGru will make adjustments based on your input

@c121914yu c121914yu changed the base branch from main to v4.12.3-dev September 3, 2025 05:45
@@ -660,6 +660,37 @@ export const compareSnapshot = (
return isEqual(node1, node2);
};

export const extractCodeFromMarkdown = (
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

不是通用的逻辑,单独拉个 目录来处理

@@ -14,7 +14,9 @@ export enum UsageSourceEnum {
pdfParse = 'pdfParse',
mcp = 'mcp',
evaluation = 'evaluation',
optimize_prompt = 'optimize_prompt'
optimize_prompt = 'optimize_prompt',
code_copilot = 'code_copilot',
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

仅保留 code_copilot

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这里为什么会放到 common 里

@@ -100,7 +100,7 @@ export const useReference = ({
.map((output) => {
return {
label: t(output.label as any),
value: output.id,
value: output.key,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

好像就是 id?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

看看是改了啥

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

目录调整下,这个应该是属于 NodeCode 里的,nodes/NodeCode/Copliot.tsx

loadingText={t('app:testing')}
onClick={handleTestCode}
>
{t('app:test_code')}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

测试功能没做好的话,就先不展示了

@@ -289,6 +291,24 @@ const NodeCard = (props: Props) => {
<Box color={'red.600'}>{t(error as any)}</Box>
</Flex>
)}
{node?.flowNodeType === FlowNodeTypeEnum.code && (
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TODO: 看看能不能优化成一行,避免很多 IF,或者改成从顶层传入

@@ -143,7 +143,7 @@ export const getEditorVariables = ({
.map((output) => {
return {
label: t((output.label as any) || ''),
key: output.id,
key: output.key,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

检查

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

不算 ai 通用的,放到 core/workflow 里

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants