Skip to content

docs: note that SQL results Parquet can't store aren't cached - #693

Draft
tkislan wants to merge 1 commit into
mainfrom
tomaskislan/docs-sql-cache-parquet-only
Draft

tkislan wants to merge 1 commit into
mainfrom
tomaskislan/docs-sql-cache-parquet-only

Conversation

@tkislan

@tkislan tkislan commented Dec 4, 2026

Copy link
Copy Markdown
Contributor

Summary

Adds one limitation to SQL query caching → Exceptions: if a query result contains values that can't be stored in the Parquet format, such as integers that don't fit in 64 bits, the result isn't cached.

Why

deepnote/deepnote-toolkit#157 changes the SQL cache to store and read only Parquet. Until now, a result Parquet couldn't hold was still cached, in another format. After that change the toolkit skips caching it, so the query runs against the warehouse every time.

Merge order

Merge this after deepnote/deepnote-toolkit#157 is merged and released. Until then, the new line describes behavior users don't have yet.

Checks

  • prettier@3.9.6 --check and cspell@9.2.2 pass on the page.
  • The example matches the toolkit. I checked it with pandas 2.2.3 and pyarrow 24.0.0, through the function pandas.read_sql_query uses to build its DataFrame. An integer column that fits int64 or uint64 is stored. One that fits neither, such as a value of 2⁶⁴ or 2⁶³ next to −1, becomes an object column, and to_parquet raises OverflowError, so the toolkit doesn't cache the result.

deepnote-toolkit now stores and reads cached SQL results only as Parquet.
A result with values Parquet can't hold, such as integers that don't fit
in 64 bits, is no longer cached, so add it to the caching limitations.
@coderabbitai

coderabbitai Bot commented Dec 4, 2026

Copy link
Copy Markdown
Contributor

Important

Draft PR not reviewed

Draft PRs are not automatically reviewed by default.

  • Trigger a manual review

To automatically review draft PRs, update your CodeRabbit configuration:

reviews:
  auto_review:
    drafts: true
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

@codecov

codecov Bot commented Dec 4, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 91.47%. Comparing base (4b289f9) to head (b522216).

Additional details and impacted files
@@           Coverage Diff            @@
##             main     #693    +/-   ##
========================================
  Coverage   91.47%   91.47%            
========================================
  Files         235      235            
  Lines       13940    13940            
  Branches     4011     3889   -122     
========================================
  Hits        12751    12751            
  Misses       1186     1186            
  Partials        3        3            

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant