Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

[R][Parquet] ParquetReaderProperties does not expose page_checksum_verification, so a corrupt page CRC reads silently

Open Beginner friendly
#53,138 1 comment 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

  • #53289 by @gitedmond — closed without merging

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
72/100
Issue type
Feature
Clarity
Clearly specified
Activity status
Active
Tech stack
cpp, r
Domain
data

Research direction

Start in r/R/parquet.R around the ParquetReaderProperties class, where the existing thrift_string_size_limit accessors show the pattern to follow, then check the matching cpp11 functions in r/src/parquet.cpp and the exports in NAMESPACE. Confirm the C++ getter and setter in cpp/src/parquet/properties.h are reachable from the shim. Done means the R class exposes page_checksum_verification get and set, and reading datapage_v1-corrupt-checksum.parquet with it enabled raises an error. Check first whether maintainers want this before opening a pull request.

Written by the indexing model from the issue text.

Description

Component: R good-first-issue Type: enhancement
Describe the bug

The R bindings do not expose page_checksum_verification, so an R user has no way to turn on page-CRC verification when reading Parquet. Arrow's own deliberately-corrupt test files are read without error.

C++ has the option and Python exposes it; only R does not.

C++ cpp/src/parquet/properties.h:148-150 — page_checksum_verification() / set_page_checksum_verification(bool check_crc), defaulting to false at line 166
Python python/pyarrow/parquet/core.py:269,325,346 — a documented page_checksum_verification=False parameter
R r/R/parquet.R:656-682 — ParquetReaderProperties declares and implements only thrift_string_size_limit and thrift_container_size_limit
Reproduction

Using the files parquet-testing ships expressly so readers can be shown to reject a bad CRC — datapage_v1-corrupt-checksum.parquet ("uncompressed INT32 columns in v1 data pages with a mismatching CRC") and rle-dict-uncompressed-corrupt-checksum.parquet:

library(arrow)
packageVersion("arrow")          # 25.0.0, libarrow 25.0.0

nrow(read_parquet("datapage_v1-corrupt-checksum.parquet"))            # 5120  -- no error
nrow(read_parquet("rle-dict-uncompressed-corrupt-checksum.parquet"))  # 1000  -- no error

ls(ParquetReaderProperties$create())
#>  [1] "class_title" "clone" "initialize" "pointer" "print" "set_pointer"
#>  [7] "set_thrift_container_size_limit" "set_thrift_string_size_limit"
#>  [9] "thrift_container_size_limit" "thrift_string_size_limit"
# no page_checksum_verification

Measured on linux/aarch64, R 4.5.3, arrow 25.0.0 / libarrow 25.0.0, with parquet-testing at e74785d85a4e (the cpp/submodules/parquet-testing commit at apache-arrow-25.0.0).

Why it matters

Reading without CRC verification is a reasonable default — it matches C++ and Python. The gap is that R offers no way to opt in, so an R pipeline cannot detect page-level corruption even when it wants to. Silent corruption is the failure mode page CRCs exist to prevent, and the files above exist to prove a reader catches it.

It also means Arrow's own conformance corpus cannot be used from R for its intended purpose: those two files are supposed to fail, and from R they are indistinguishable from the matching-CRC files beside them (datapage_v1-uncompressed-checksum.parquet, plain-dict-uncompressed-checksum.parquet).

Component(s)

R, Parquet

Sketch of a fix

Not offering a PR, but the shape looks small — two accessors alongside the existing thrift ones in r/R/parquet.R:

page_checksum_verification = function() {
  parquet___arrow___ReaderProperties__get_page_checksum_verification(self)
},
set_page_checksum_verification = function(check_crc) {
  parquet___arrow___ReaderProperties__set_page_checksum_verification(self, check_crc)
},

plus the two cpp11 shims in r/src/parquet.cpp forwarding to the existing C++ getter/setter, and a line each in the @description block and NAMESPACE. Happy to be told if there is a reason it was left out deliberately — #36997 touched the same class for a different reason and did not add it.

Dominant language
C++
Stars
17.2k
Forks
4.4k
Avg merge
3d 5h
Merged PRs (30d)
67

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from apache/arrow

All issues in apache/arrow

Similar issues

More C++ issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.