Skip to content

Fix/stor return type - #18355

Merged
Bahex merged 2 commits into
nushell:mainfrom
Bahex:fix/stor-return-type
Jun 6, 2026
Merged

Bahex merged 2 commits into
nushell:mainfrom
Bahex:fix/stor-return-type

Conversation

@Bahex

@Bahex Bahex commented Jun 6, 2026 •

Copy link
Copy Markdown
Member

User-facing changes (Release notes)

Fixed stor open return type

stor open returns the custom value SQLiteDatabase, yet it's signature had sqlite-in-memory as the return type. This causes problems with the enforce-runtime-annotations experimental option:

let db = stor open
# Error: nu::shell::cant_convert
# 
#   × Can't convert to sqlite-in-memory.
#    ╭─[repl_entry #1:1:10]
#  1 │ let db = stor open 
#    ·          ────┬────
#    ·              ╰── can't convert SQLiteDatabase to sqlite-in-memory
#    ╰────

The return type has been corrected to SQLiteDatabase.

Additional notes

Bahex added 2 commits June 6, 2026 13:52
This caused problems with `enforce-runtime-annotations`:
```nushell
let db = stor open
# Error: nu::shell::cant_convert
# 
#   × Can't convert to sqlite-in-memory.
#    ╭─[repl_entry #1:1:10]
#  1 │ let db = stor open 
#    ·          ────┬────
#    ·              ╰── can't convert SQLiteDatabase to sqlite-in-memory
#    ╰────
```
@Bahex Bahex added A:type-system Problems or features related to nushell's type system notes:fixes Noted in "Bug fixes" section notes:ready Indicates Ready for Release notes labels Jun 6, 2026
@Bahex
Bahex requested a review from cptpiepmatz June 6, 2026 12:26

@fdncred fdncred left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

That's weird. I wonder why I did that. Looks good to me.

@Bahex
Bahex merged commit 989aace into nushell:main Jun 6, 2026
18 checks passed
@github-actions github-actions Bot added this to the v0.114.0 milestone Jun 6, 2026
@Bahex
Bahex deleted the fix/stor-return-type branch June 6, 2026 18:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A:type-system Problems or features related to nushell's type system notes:fixes Noted in "Bug fixes" section notes:ready Indicates Ready for Release notes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants