Skip to content

fix(postgrest): narrow column types after not(column, is, null) - #2264

Merged
mandarini merged 3 commits into
masterfrom
fix/postgrest-not-null-narrowing
Apr 24, 2026
Merged

mandarini merged 3 commits into
masterfrom
fix/postgrest-not-null-narrowing

Conversation

@mandarini

@mandarini mandarini commented Apr 21, 2026 •

Copy link
Copy Markdown
Contributor

When filtering with .not(col, 'is', null), the resulting row type now marks that column as non-nullable in both the Row (for filter chaining) and Result (for the returned data type).

Closes #1360

Thanks to @DevanshTyagi04 and #2028 for the motivation to address the issue.

@mandarini
mandarini requested review from a team as code owners April 21, 2026 14:41
@github-actions github-actions Bot added the postgrest-js Related to the postgrest-js library. label Apr 21, 2026
@pkg-pr-new

pkg-pr-new Bot commented Apr 21, 2026 •

Copy link
Copy Markdown

Open in StackBlitz

@supabase/auth-js

npm i https://pkg.pr.new/@supabase/auth-js@2264

@supabase/functions-js

npm i https://pkg.pr.new/@supabase/functions-js@2264

@supabase/postgrest-js

npm i https://pkg.pr.new/@supabase/postgrest-js@2264

@supabase/realtime-js

npm i https://pkg.pr.new/@supabase/realtime-js@2264

@supabase/storage-js

npm i https://pkg.pr.new/@supabase/storage-js@2264

@supabase/supabase-js

npm i https://pkg.pr.new/@supabase/supabase-js@2264

commit: e47215b

@mandarini mandarini linked an issue Apr 21, 2026 that may be closed by this pull request
2 tasks done
@mandarini mandarini self-assigned this Apr 21, 2026
@mandarini
mandarini requested a review from steve-chavez April 21, 2026 15:02

@steve-chavez steve-chavez left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM

@mandarini
mandarini merged commit d72bd9f into master Apr 24, 2026
21 checks passed
@mandarini
mandarini deleted the fix/postgrest-not-null-narrowing branch April 24, 2026 06:07
mandarini pushed a commit to supabase/ssr that referenced this pull request Apr 27, 2026
This PR updates `@supabase/supabase-js` to v2.105.0.

**Source**: supabase-js-stable-release

---

## Release Notes

## v2.105.0

## 2.105.0 (2026-04-27)

### 🚀 Features

- **auth:** add passkey support with WebAuthn registration,
authentication, and management
([#2283](supabase/supabase-js#2283))
- **realtime:** Realtime deferred disconnect
([#2282](supabase/supabase-js#2282))

### 🩹 Fixes

- **postgrest:** narrow column types after not(column, is, null)
([#2264](supabase/supabase-js#2264))
- **realtime:** annotate Timer/Vsn getters to avoid deep phoenix imports
([#2284](supabase/supabase-js#2284))
- **storage:** apply metadata, headers, and cacheControl dedupe to
uploadToSignedUrl
([#2275](supabase/supabase-js#2275))
- **storage:** forward duplex option for stream uploads via
uploadToSignedUrl
([#2289](supabase/supabase-js#2289))

### ❤️ Thank You

- Katerina Skroumpelou @mandarini
- oniani1

This PR was created automatically.

Co-authored-by: supabase-workflow-trigger[bot] <266661614+supabase-workflow-trigger[bot]@users.noreply.github.com>
mandarini pushed a commit to supabase/supabase that referenced this pull request May 6, 2026
This PR updates @supabase/*-js libraries to version 2.105.3.

**Source**: supabase-js-stable-release

**Changes**:
- Updated @supabase/supabase-js to 2.105.3
- Updated @supabase/auth-js to 2.105.3
- Updated @supabase/realtime-js to 2.105.3
- Updated @supabase/postgest-js to 2.105.3
- Refreshed pnpm-lock.yaml

---

## Release Notes

## v2.105.3

## 2.105.3 (2026-05-04)

### 🩹 Fixes

- **auth:** narrow OAuth/CustomProvider types to fix downstream consumer
typecheck ([#2326](supabase/supabase-js#2326))
## v2.105.2

## 2.105.2 (2026-05-04)

### 🩹 Fixes

- **auth:** forward lockAcquireTimeout to SupabaseAuthClient
([#2309](supabase/supabase-js#2309))
- **auth:** add toJSON to WebAuthnError for correct JSON serialization
([#2317](supabase/supabase-js#2317))
- **misc:** widen enum-like unions with (string & {}) for forward compat
([#2303](supabase/supabase-js#2303))
- **misc:** reduce any usage across packages
([#2314](supabase/supabase-js#2314))
- **postgrest:** unify insert/upsert signatures
([#2315](supabase/supabase-js#2315))

### ❤️ Thank You

- Muzzaiyyan Hussain @MuzzaiyyanHussain
## v2.105.1

## 2.105.1 (2026-04-28)

### 🩹 Fixes

- **postgrest:** query reassignment regression
([#2292](supabase/supabase-js#2292))
- **realtime:** surface real Error on transport-level CHANNEL_ERROR
([#2299](supabase/supabase-js#2299))

### ❤️ Thank You

- Vaibhav @7ttp
## v2.105.0

## 2.105.0 (2026-04-27)

### 🚀 Features

- **auth:** add passkey support with WebAuthn registration,
authentication, and management
([#2283](supabase/supabase-js#2283))
- **realtime:** Realtime deferred disconnect
([#2282](supabase/supabase-js#2282))

### 🩹 Fixes

- **postgrest:** narrow column types after not(column, is, null)
([#2264](supabase/supabase-js#2264))
- **realtime:** annotate Timer/Vsn getters to avoid deep phoenix imports
([#2284](supabase/supabase-js#2284))
- **storage:** apply metadata, headers, and cacheControl dedupe to
uploadToSignedUrl
([#2275](supabase/supabase-js#2275))
- **storage:** forward duplex option for stream uploads via
uploadToSignedUrl
([#2289](supabase/supabase-js#2289))

### ❤️ Thank You

- Katerina Skroumpelou @mandarini
- oniani1

This PR was created automatically.

Co-authored-by: supabase-workflow-trigger[bot] <266661614+supabase-workflow-trigger[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

postgrest-js Related to the postgrest-js library.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Inferred types for nullable columns after not null checks should be non-nullable

2 participants