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

[Conversations - Fragment] Return 400 on image format not supported #11451

Merged
merged 3 commits into from
Mar 18, 2025

Conversation

philipperolet
Copy link
Contributor

Description

Fixes issue from thread here, so there is no unhandled api error.

Receiving a 3rd party message "Image format not supported", an unhandled api error is not warranted since not actionable by us. The best is to throw a 400.

Risks

low

Deploy

front

Description
---
Fixes issue from thread [here](), so there is no unhandled api
error.

Receiving a 3rd party message "Image format not supported", an
unhandled api error is not warranted since not actionable by us. The
best is to throw a 400.

Risks
---
low

Deploy
---
front
Copy link

github-actions bot commented Mar 18, 2025

Warnings
⚠️

Files in **/api/v1/ have been modified and the PR has the documentation-ack label.
Don't forget to run npm run docs and use the Deploy OpenAPI Docs Github action to update https://docs.dust.tt/reference.

Generated by 🚫 dangerJS against 03441a7

@philipperolet philipperolet added the documentation-ack Used to acknowledge that documentation is up-to-date with this PR label Mar 18, 2025
@philipperolet
Copy link
Contributor Author

PMRR

@philipperolet philipperolet merged commit f6444bb into main Mar 18, 2025
4 checks passed
@philipperolet philipperolet deleted the fix-untitled-docs branch March 18, 2025 15:34
@@ -58,8 +61,10 @@ export async function toFileContentFragment(

if (processRes.isErr()) {
return new Err({
Copy link
Contributor

Choose a reason for hiding this comment

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

Can we avoid raw object as error 🙏 ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

In this case, unfortunately, no, or it would require too much work to make old code consistent, change the DustError type from which ProcessAndStoreFileError is derived, etc.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation-ack Used to acknowledge that documentation is up-to-date with this PR
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants