Skip to main content
GoodFirstPicks
DashboardIssuesReposLeaderboard

GoodFirstPicks by Leaveitblank © 2026

CreatorRequest a RepoPrivacy PolicyTerms of Service
`Cannot read properties of null (reading 'f')` introduced in v5.48.0 | GoodFirstPicks

`Cannot read properties of null (reading 'f')` introduced in v5.48.0

sveltejs/svelte 5 comments 1mo ago
View on GitHub
mediumopenScope: somewhat clearSkill match: maybeSvelteTypeScript

Why this is a good first issue

Error in Svelte runtime error handling but lacks minimal repro.

AI Summary

The issue involves a runtime error in Svelte's error handling mechanism when accessing properties of null, specifically in the `handle_error` method. The problem requires understanding Svelte's internal update cycle and error handling, but lacks a minimal reproduction case, making it harder to diagnose and fix.

Issue Description

Describe the bug

This error started popping up after we upgraded Svelte from v5.47.1 to v5.48.0, and it is still present in the latest version v5.49.2

Here's the error logged in the console:

Uncaught TypeError: Cannot read properties of null (reading 'f')
    at handle_error (error-handling.js:20:27)
    at update_reaction (runtime.js:342:10)
    at update_effect (runtime.js:454:18)
    at flush_queued_effects (batch.js:696:4)
    at _Batch.process (batch.js:227:4)
    at flush_effects (batch.js:640:10)
    at _Batch.flush (batch.js:355:4)
    at Array.<anonymous> (batch.js:528:12)
    at run_all (utils.js:46:8)
    at run_micro_tasks (task.js:10:2)

And here's a public link to one of our Sentry alerts, with a more thorough stack trace of the code that caused the error: https://kvist.sentry.io/share/issue/ce1baf62f21c4928bdf9331ceae87721/

Reproduction

I still haven't managed to create a minimal repro, as i am not that familiar with the internal setup of Svelte's update-cycle, so creating a minimal reproduction would take quite some time. I hope that the information is sufficient enough, and if it isn't, then let me know and i'll try my best to help.

It seems to me like error is thrown because of this (active_reaction).f accessor in the handle_error method

// for unowned deriveds, don't throw until we read the value
if (effect === null) {
	/** @type {Derived} */ (active_reaction).f |= ERROR_VALUE;
	return error;
}

Logs

System Info

System:
    OS: macOS 26.2
    CPU: (10) arm64 Apple M2 Pro
    Memory: 4.90 GB / 32.00 GB
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 24.13.0 - /Users/mathiaspicker/.local/share/mise/installs/node/24.13.0/bin/node
    npm: 11.6.2 - /Users/mathiaspicker/.local/share/mise/installs/node/24.13.0/bin/npm
    pnpm: 10.28.2 - /opt/homebrew/bin/pnpm
    bun: 1.2.22 - /opt/homebrew/bin/bun
  Browsers:
    Brave Browser: 143.1.85.117
    Chrome: 144.0.7559.112
    Edge: 144

GitHub Labels

awaiting submitter

Want to work on this?

Claim this issue to let others know you're working on it. You'll earn 10 points when you complete it!

Risk Flags

  • no minimal repro
  • internal Svelte runtime knowledge needed
Loading labels...

Details

Points10 pts
Difficultymedium
Scopesomewhat clear
Skill Matchmaybe
Test Focusedno