Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

♻️ refactor: refactor upload method #5111

Merged
merged 4 commits into from
Dec 21, 2024
Merged

Conversation

arvinxx
Copy link
Contributor

@arvinxx arvinxx commented Dec 21, 2024

💻 变更类型 | Change Type

  • ✨ feat
  • 🐛 fix
  • ♻️ refactor
  • 💄 style
  • 👷 build
  • ⚡️ perf
  • 📝 docs
  • 🔨 chore

🔀 变更说明 | Description of Change

将 pglite 迁移部分的 upload to Client S3 的实现先抽取过来,拉齐整个 file 上传的流程,将 client 和 server 保持完全一致

📝 补充信息 | Additional Information

Copy link

vercel bot commented Dec 21, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
lobe-chat-database ✅ Ready (Inspect) Visit Preview 💬 Add feedback Dec 21, 2024 1:27pm
lobe-chat-preview ✅ Ready (Inspect) Visit Preview 💬 Add feedback Dec 21, 2024 1:27pm

@dosubot dosubot bot added the size:L This PR changes 100-499 lines, ignoring generated files. label Dec 21, 2024
@lobehubbot
Copy link
Member

👍 @arvinxx

Thank you for raising your pull request and contributing to our Community
Please make sure you have followed our contributing guidelines. We will review it as soon as possible.
If you encounter any problems, please feel free to connect with us.
非常感谢您提出拉取请求并为我们的社区做出贡献,请确保您已经遵循了我们的贡献指南,我们会尽快审查它。
如果您遇到任何问题,请随时与我们联系。

Copy link

gru-agent bot commented Dec 21, 2024

TestGru Assignment

Summary

Link CommitId Status Reason
Detail b24b914 ✅ Finished

Files

File Pull Request
src/services/file/ClientS3/index.ts ❌ Failure (I failed to write the unit tests for the file.)

Tip

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

Copy link

codecov bot commented Dec 21, 2024

Codecov Report

Attention: Patch coverage is 80.62500% with 31 lines in your changes missing coverage. Please review.

Project coverage is 92.18%. Comparing base (c59c1e2) to head (745a9c5).
Report is 7 commits behind head on main.

Files with missing lines Patch % Lines
src/store/file/slices/upload/action.ts 39.39% 20 Missing ⚠️
src/database/_deprecated/models/file.ts 58.82% 7 Missing ⚠️
src/services/file/client.ts 88.88% 4 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #5111      +/-   ##
==========================================
+ Coverage   91.88%   92.18%   +0.30%     
==========================================
  Files         548      549       +1     
  Lines       41501    41565      +64     
  Branches     3549     2374    -1175     
==========================================
+ Hits        38132    38317     +185     
+ Misses       3369     3248     -121     
Flag Coverage Δ
app 92.18% <80.62%> (+0.30%) ⬆️
server 97.65% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@dosubot dosubot bot added size:XL This PR changes 500-999 lines, ignoring generated files. and removed size:L This PR changes 100-499 lines, ignoring generated files. labels Dec 21, 2024
@lobehubbot
Copy link
Member

❤️ Great PR @arvinxx ❤️

The growth of project is inseparable from user feedback and contribution, thanks for your contribution! If you are interesting with the lobehub developer community, please join our discord and then dm @arvinxx or @canisminor1990. They will invite you to our private developer channel. We are talking about the lobe-chat development or sharing ai newsletter around the world.
项目的成长离不开用户反馈和贡献,感谢您的贡献! 如果您对 LobeHub 开发者社区感兴趣,请加入我们的 discord,然后私信 @arvinxx@canisminor1990。他们会邀请您加入我们的私密开发者频道。我们将会讨论关于 Lobe Chat 的开发,分享和讨论全球范围内的 AI 消息。

github-actions bot pushed a commit that referenced this pull request Dec 21, 2024
### [Version&nbsp;1.36.46](v1.36.45...v1.36.46)
<sup>Released on **2024-12-21**</sup>

#### ♻ Code Refactoring

- **misc**: Refactor client mode upload to match server mode.

<br/>

<details>
<summary><kbd>Improvements and Fixes</kbd></summary>

#### Code refactoring

* **misc**: Refactor client mode upload to match server mode, closes [#5111](#5111) ([0361ced](0361ced))

</details>

<div align="right">

[![](https://img.shields.io/badge/-BACK_TO_TOP-151515?style=flat-square)](#readme-top)

</div>
@lobehubbot
Copy link
Member

🎉 This PR is included in version 1.36.46 🎉

The release is available on:

Your semantic-release bot 📦🚀

github-actions bot pushed a commit to bentwnghk/lobe-chat that referenced this pull request Dec 21, 2024
### [Version&nbsp;1.78.18](v1.78.17...v1.78.18)
<sup>Released on **2024-12-21**</sup>

#### ♻ Code Refactoring

- **misc**: Refactor client mode upload to match server mode.

#### 💄 Styles

- **misc**: Add o1 model in GitHub models.

<br/>

<details>
<summary><kbd>Improvements and Fixes</kbd></summary>

#### Code refactoring

* **misc**: Refactor client mode upload to match server mode, closes [lobehub#5111](https://github.com/bentwnghk/lobe-chat/issues/5111) ([0361ced](0361ced))

#### Styles

* **misc**: Add o1 model in GitHub models, closes [lobehub#5110](https://github.com/bentwnghk/lobe-chat/issues/5110) ([91dc5d7](91dc5d7))

</details>

<div align="right">

[![](https://img.shields.io/badge/-BACK_TO_TOP-151515?style=flat-square)](#readme-top)

</div>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
released size:XL This PR changes 500-999 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants