Skip to content

Conversation

@xqvvu
Copy link
Contributor

@xqvvu xqvvu commented Dec 8, 2025

Note

Pass pathStyle to the external S3 client, handle invalid object-name errors during TTL cleanup, add a key invalid-char map, and update docs to forbid |, /, \ in uid.

  • Backend (S3):
    • Forward pathStyle to external S3 client in packages/service/common/s3/buckets/base.ts.
    • Add S3_KEY_PATH_INVALID_CHARS_MAP in packages/service/common/s3/constants.ts.
    • Improve TTL cleanup in packages/service/common/s3/controller.ts to catch S3Error for unsupported characters and remove stale DB entries.
  • Docs:
    • Update document/content/docs/introduction/development/openapi/share.mdx to clarify uid must not contain |, /, or \.

Written by Cursor Bugbot for commit 05eb753. This will update automatically on new commits. Configure here.

@gru-agent
Copy link
Contributor

gru-agent bot commented Dec 8, 2025

TestGru Assignment

Summary

Link CommitId Status Reason
Detail e807c3b 🚫 Skipped No files need to be tested {"document/content/docs/introduction/development/openapi/share.mdx":"File path does not match include patterns.","packages/service/common/s3/buckets/base.ts":"File path does not match include patterns.","packages/service/common/s3/constants.ts":"File path does not match include patterns.","packages/service/common/s3/controller.ts":"File path does not match include patterns."}

History Assignment

Tip

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

@github-actions
Copy link

github-actions bot commented Dec 8, 2025

Preview mcp_server Image:

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

@github-actions
Copy link

github-actions bot commented Dec 8, 2025

Preview sandbox Image:

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

@github-actions
Copy link

github-actions bot commented Dec 8, 2025

Docs Preview:


🚀 FastGPT Document Preview Ready!

🔗 👀 Click here to visit preview

@github-actions
Copy link

github-actions bot commented Dec 8, 2025

Preview fastgpt Image:

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

return config; // bytes
};

export const S3_KEY_PATH_INVALID_CHARS = ['/', '\\', '|'];
Copy link
Collaborator

Choose a reason for hiding this comment

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

用 MAP,o1

@c121914yu c121914yu merged commit 3a238e1 into labring:v4.14.4-dev Dec 8, 2025
7 checks passed
Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

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

This is the final PR Bugbot will review for you during this billing cycle

Your free Bugbot reviews will reset on January 12

Details

You are on the Bugbot Free tier. On this plan, Bugbot will review limited PRs each billing cycle.

To receive Bugbot reviews on all of your PRs, visit the Cursor dashboard to activate Pro and start your 14-day free trial.

error instanceof S3Error &&
error.message.includes('Object name contains unsupported characters.')
) {
await MongoS3TTL.deleteOne({ _id: file._id });
Copy link

Choose a reason for hiding this comment

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

Bug: Unhandled MongoDB error stops file cleanup loop

The await MongoS3TTL.deleteOne() call inside the catch block isn't wrapped in its own try-catch. If this MongoDB operation throws (due to connection issues, timeouts, etc.), the error propagates to the outer catch handler, terminating the entire cleanup loop. This means all remaining files in the batch won't be processed until the next cron run, potentially leaving expired files uncleaned for an extended period.

Fix in Cursor Fix in Web

c121914yu added a commit that referenced this pull request Dec 8, 2025
* fix: s3 configs

* s3

---------

Co-authored-by: archer <545436317@qq.com>
c121914yu added a commit that referenced this pull request Dec 8, 2025
* fix: s3 configs

* s3

---------

Co-authored-by: archer <545436317@qq.com>
c121914yu added a commit that referenced this pull request Dec 8, 2025
* perf: faq

* index

* delete dataset

* delete dataset

* perf: delete dataset

* init

* fix: outLink UID (#6048)

* perf: query extension

* fix: s3 configs (#6050)

* fix: s3 configs

* s3

---------

Co-authored-by: archer <545436317@qq.com>

* s3 valid string check

* perf: completion api

* fix: model test

* perf: init

* fix: init

* fix: init shell

* fix: faq

---------

Co-authored-by: Roy <whoeverimf5@gmail.com>
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