Skip to content

fwrite: Improve validation of the na argument - #7867

Merged
MichaelChirico merged 5 commits into
Rdatatable:masterfrom
mcol:issue_7866
Jul 30, 2026
Merged

fwrite: Improve validation of the na argument#7867
MichaelChirico merged 5 commits into
Rdatatable:masterfrom
mcol:issue_7866

Conversation

@mcol

@mcol mcol commented Jul 30, 2026

Copy link
Copy Markdown
Contributor

This moves the conversion to character after the stopifnot(), so that we get a consistent error message for both na = data.frame() and na = data.table().

Fixes #7866.

@mcol
mcol requested a review from MichaelChirico as a code owner July 30, 2026 19:01
Comment thread R/fwrite.R
@codecov

codecov Bot commented Jul 30, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 99.01%. Comparing base (6793af2) to head (9f32888).
⚠️ Report is 1 commits behind head on master.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #7867   +/-   ##
=======================================
  Coverage   99.01%   99.01%           
=======================================
  Files          88       88           
  Lines       17292    17292           
=======================================
  Hits        17122    17122           
  Misses        170      170           

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@MichaelChirico
MichaelChirico merged commit 7bc8bc1 into Rdatatable:master Jul 30, 2026
11 of 12 checks passed
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.

fwrite(..., na = data.frame()) has an unhelpful error message

2 participants