Skip to content

feat(spx-gui): raise sb upload limit to 128 MiB#3352

Open
fennoai[bot] wants to merge 1 commit into
devfrom
fennoai/issue-3351-1784190907
Open

feat(spx-gui): raise sb upload limit to 128 MiB#3352
fennoai[bot] wants to merge 1 commit into
devfrom
fennoai/issue-3351-1784190907

Conversation

@fennoai

@fennoai fennoai Bot commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

Summary

Raise the sb (.sb2/.sb3) upload limit from 64 MiB to 128 MiB on the frontend, tracking #3351.

Changes

  • spx-gui/src/apis/project-conversion.ts: change the hardcoded local pre-check maxFileSize from 64 * 1024 * 1024 to 128 * 1024 * 1024. This was the only hardcoded 64 MiB frontend limit.
  • docs/openapi.yaml: update the /project-conversions request body description from "Maximum size is 64 MiB." to "Maximum size is 128 MiB.".

Notes

  • The general cloud upload path (spx-gui/src/models/common/cloud.ts) already follows the backend-provided maxSize and needs no change — it will pick up 128 MiB once the backend raises the value.
  • The UpInfo.maxSize example in docs/openapi.yaml (26214400) is a generic illustrative value unrelated to the sb limit, so it is left unchanged.
  • Requires the companion backend change in goplus/builder-backend (maxMultipartMemory 64 → 128 MiB) to fully take effect.

Fixes #3351

Generated with FennoAI

Raise the hardcoded local pre-check for Scratch (.sb2/.sb3) project
conversion from 64 MiB to 128 MiB so larger projects can be uploaded.
The general upload path in cloud.ts already follows the backend-provided
maxSize, so no change is needed there. Update the openapi.yaml
project-conversions description to match.

Fixes #3351

Generated with [FennoAI](https://github.com/apps/fennoai)
Co-authored-by: go-wyvern <15845637+go-wyvern@users.noreply.github.com>

@fennoai fennoai Bot left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Review summary

Small, focused change that raises the frontend sb (.sb2/.sb3) upload pre-check limit from 64 MiB to 128 MiB and updates the matching OpenAPI description. The change is correct and internally consistent:

  • project-conversion.ts is the only hardcoded frontend limit (confirmed via repo-wide search for 64 * 1024 * 1024 / 67108864 / 64 MiB — no other references remain).
  • The general cloud upload path in models/common/cloud.ts already follows the backend-provided maxSize, so it needs no change here.

One minor, non-blocking nit inline. As the PR description notes, the companion backend change (maxMultipartMemory 64 → 128 MiB) is required for this to fully take effect; this frontend-only pre-check will otherwise reject at 128 MiB while the backend still rejects earlier — worth landing them together.

No blocking issues found.

import { humanizeFileSize } from '@/utils/utils'

const maxFileSize = 64 * 1024 * 1024 // 64MB
const maxFileSize = 128 * 1024 * 1024 // 128MB

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Nit (pre-existing, non-blocking): the value is binary (128 * 1024 * 1024 = 128 MiB), but the comment says // 128MB and the user-facing error uses humanizeFileSize, which labels base-1024 units as MB (not MiB). So the doc/PR say "128 MiB" while the UI will show "128 MB" for the same value. Consider aligning the terminology (e.g. // 128 MiB) for consistency with docs/openapi.yaml.

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.

[sb2xbp] Support uploading sb files up to 128 MiB (raise 64 MiB limit)

0 participants