Skip to content

The persisted lockfile is out of sync with the recovered package.json #6657

Closed

Description

@masenf

Describe the bug
Error during reflex run:

Debug: Running command: ['/Users/masenf/Library/Application 
Support/reflex/bun/bin/bun', 'install', '--legacy-peer-deps', 
'--frozen-lockfile']
Debug: Installing base frontend packages
Debug: bun install v1.3.0 (b0a6feca)
Debug: error: lockfile had changes, but lockfile is frozen
Debug: note: try re-running without --frozen-lockfile and commit the updated 
lockfile
The persisted lockfile is out of sync with the recovered package.json. Delete 
the 
/Users/masenf/code/reflex-dev/repro-reflex-lock/9e3d6c4f-cdb5-477b-9e07-44ed7912
f3c9_refs_heads_main_77af9d4a00069e5c1d16aeeb4afd2a5cc9299e2d/reflex.lock 
directory and rerun so Reflex regenerates it from scratch.

The lock file got updated with new dependencies, but the locked package.json did NOT get updated and now the project cannot start.

To Reproduce

reflex init --template blank
reflex export --frontend-only --no-zip
(cd reflex.lock && bun add [email protected])
reflex run --loglevel debug

This is a minimal reproducer for at least part of the issue. However, in the initial report, the reflex.lock/package.json did NOT match the reflex.lock/bun.lock (which contained "recharts": "3.8.1")

Expected behavior
package.json and bun.lock stay in sync, so the app can start properly.

Specifics (please complete the following information):

  • Python Version: 3.14
  • Reflex Version: 0.9.5.post2
  • OS: linux

Activity

  1. linear-code commented on Jun 11, 2026

    @linear-code
  2. masenf commented on Jun 11, 2026

    @masenf
    CollaboratorAuthor

    at least one way to reproduce this is by changing the bun.lock and package.json out of band.

    for example:

    reflex init --template blank
    reflex export --frontend-only --no-zip
    
    (cd reflex.lock && bun add [email protected])
    
    reflex run --loglevel debug
    

    Debug: Copying 
    /Users/masenf/code/reflex-dev/repro-reflex-lock/minimal/reflex.lock/bun.lock to 
    .web/bun.lock
    Debug: Running command: ['/Users/masenf/Library/Application 
    Support/reflex/bun/bin/bun', 'install', '--legacy-peer-deps', 
    '--frozen-lockfile']
    Debug: Installing base frontend packages
    Debug: bun install v1.3.0 (b0a6feca)
    Debug: error: lockfile had changes, but lockfile is frozen
    Debug: note: try re-running without --frozen-lockfile and commit the updated 
    lockfile
    The persisted lockfile is out of sync with the recovered package.json. Delete 
    the /Users/masenf/code/reflex-dev/repro-reflex-lock/minimal/reflex.lock 
    directory and rerun so Reflex regenerates it from scratch.
    
  3. masenf commented on Jun 12, 2026

    @masenf
    CollaboratorAuthor

    this can also bite you when checking out a git revision across lock file changes without explicitly re-running reflex init.

  4. self-assigned this
    on Jun 12, 2026
  5. reopened this on Jul 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions