Skip to content

fix: display all uploaded S3 assets in the assets tab#4162

Open
yugalkaushik wants to merge 1 commit into
processing:developfrom
yugalkaushik:asset-limit-fix
Open

fix: display all uploaded S3 assets in the assets tab#4162
yugalkaushik wants to merge 1 commit into
processing:developfrom
yugalkaushik:asset-limit-fix

Conversation

@yugalkaushik
Copy link
Copy Markdown
Contributor

@yugalkaushik yugalkaushik commented Jun 7, 2026

Issue:

Fixes #4085
This PR fixes an issue where some files stored in S3 for a user weren't showing up in their Assets tab, even though the total size calculation correctly increased.

In server/controllers/aws.controller.js, listObjectsInS3ForUser was fetching all objects from S3 but then filtering them to only include assets that could be mapped back to an active sketch project. If an asset wasn't referenced in a sketch (e.g. if it was uploaded but not yet used or if the sketch referencing it was deleted) it was hidden from the UI but still counted against the user's storage quota.

Before

Even though the image exists in S3, no image is being displayed in the Assets section. However, its size is still being counted toward the storage limit, as shown in the image.

Screenshot 2026-06-07 142743

Demo with fix:

preview-assetfix.mp4

Changes:

  1. Removed the conditional check that filtered out unassociated assets.
  2. If an asset maps to a sketch, it still gets enriched with the sketch details (sketchId, sketchName). Otherwise, it safely defaults to rendering without them.

I have verified that this pull request:

  • has no linting errors (npm run lint)
  • has no test errors (npm run test)
  • has no typecheck errors (npm run typecheck)
  • is from a uniquely-named feature branch and is up to date with the develop branch.
  • is descriptively named and links to an issue number, i.e. Fixes #123
  • meets the standards outlined in the accessibility guidelines

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Incorrect Asset Size Limit Error

1 participant