Skip to content

Blob physical projection misreads empty non-null values #7598

Description

@zhangyang0418

Problem

Blob columns can be misread when scanning with physical projection / binary blob handling if the column contains an empty but non-null blob value (b""). Empty blobs are encoded with position == 0 and size == 0, which can be confused with rows that have out-of-line blob data in the decode paths.

There is also a related lower-level scheduler contract issue: empty byte ranges should return an empty Bytes entry in result order, but the scheduler reassembly logic can drop empty ranges because empty intervals do not overlap any coalesced request.

Impact

After the first empty blob, subsequent blob values can be read back as empty or the scan can fail due to byte/result misalignment.

Reproduction shape

A blob column with values like:

  • non-empty blob
  • empty non-null blob
  • non-empty blob
  • null
  • non-empty blob

Then scan it as binary with blob_handling="all_binary".

Expected

The scan should preserve empty non-null blobs, nulls, and all following non-empty blob payloads in order.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions