• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

supabase / storage / 37919932309
85%

Build:
DEFAULT BRANCH: master
Ran 09 Oct 2026 10:50AM UTC
Jobs 2
Files 319
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

09 Oct 2026 10:49AM UTC coverage: 85.259% (+0.3%) from 84.946%
37919932309

push

github

web-flow
feat: add bucket versioning status and version-aware object writes (#1347)

## What kind of change does this PR introduce?

Feature to factor in the bucket versioning status into object write and
delete operations.

## What is the current behavior?

Currently, a bucket's versioning status can only be `DISABLED` and is
not factored into operations such as PUT or DELETE.

## What is the new behavior?

All object write and delete operations now factor in the bucket's
versioning status. The status can be `DISABLED`, `ENABLED`, or
`SUSPENDED`.

Once versioning is enabled, the bucket can never return to `DISABLED`
because enabling it permanently changes how certain operations are
performed. Distinguishing a bucket that has never had versioning enabled
is important because it requires less bookkeeping.

For example, in the `SUSPENDED` state, a PUT on an existing key still
preserves the current object if it has `is_versioned` set to `true`,
meaning it was created while the bucket was `ENABLED`. In the `DISABLED`
state, we know the current object could never be versioned, so we can
continue using the normal upsert behavior instead of archiving and
inserting.

Here are the main changes for each status:

### ENABLED

**PUT**: We update the current version's `archived_at` and insert a new
row with a different `version`. I refer to this as archive and insert.

**DELETE**: This follows the same archive-and-insert flow as PUT, but
the newly inserted row has `is_delete_marker` set to `true`.

### SUSPENDED

**PUT**: This is similar to the archive-and-insert flow, with one key
distinction. We archive the current row and then upsert on `(bucket_id,
name) WHERE NOT is_versioned`. If a null version already exists for this
object, it is replaced rather than retained as another historical
version.

**DELETE**: This follows the same archive-and-upsert flow as PUT, but
the null version becomes a delete marker. This is another important
distinction between `SUSPENDED` and `DI... (continued)

7580 of 9421 branches covered (80.46%)

Branch coverage included in aggregate %.

594 of 631 new or added lines in 19 files covered. (94.14%)

1 existing line in 1 file now uncovered.

13242 of 15001 relevant lines covered (88.27%)

847.05 hits per line

Uncovered Changes

Lines Coverage ∆ File
18
90.9
0.34% src/storage/database/pg.ts
13
92.83
-1.01% src/storage/object.ts
3
70.37
src/storage/versioning/guards.ts
2
80.65
0.18% src/storage/protocols/s3/s3-handler.ts
1
94.84
-0.05% src/storage/uploader.ts

Coverage Regressions

Lines Coverage ∆ File
1
90.9
0.34% src/storage/database/pg.ts
Jobs
ID Job ID Ran Files Coverage
1 rest-pg18 - 37919932309.1 09 Oct 2026 10:54AM UTC 299
63.54
GitHub Action Run
2 unit - 37919932309.2 09 Oct 2026 10:50AM UTC 313
66.37
GitHub Action Run
Source Files on build 37919932309
  • Tree
  • List 319
  • Changed 37
  • Source Changed 28
  • Coverage Changed 33
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • Github Actions Build #37919932309
  • f31599e1 on github
  • Prev Build on master (#37762925825)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc