Skip to content

GH-49654: [R][CI] Add check for non-API calls onto existing r-devel job#49655

Open
thisisnic wants to merge 3 commits intoapache:mainfrom
thisisnic:GH-49654_nonapi_ci
Open

GH-49654: [R][CI] Add check for non-API calls onto existing r-devel job#49655
thisisnic wants to merge 3 commits intoapache:mainfrom
thisisnic:GH-49654_nonapi_ci

Conversation

@thisisnic
Copy link
Copy Markdown
Member

@thisisnic thisisnic commented Apr 2, 2026

Rationale for this change

I wanna know when we get NOTEs about this so we don't need to wait til CRAN pings us

What changes are included in this PR?

Add check to r-devel jobs

Are these changes tested?

Those CI jobs should fail now

Are there any user-facing changes?

Nah

@github-actions github-actions bot added the awaiting committer review Awaiting committer review label Apr 2, 2026
@thisisnic
Copy link
Copy Markdown
Member Author

@github-actions crossbow submit test-r-linux-as-cran

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 2, 2026

Revision: b13bedc

Submitted crossbow builds: ursacomputing/crossbow @ actions-b88d947b45

Task Status
test-r-linux-as-cran GitHub Actions

Comment on lines +58 to +64
- name: Check for non-API calls
run: |
if grep -q "non-API" arrow/r/check/arrow.Rcheck/00check.log; then
echo "Found non-API calls in R CMD check output:"
grep -A2 "non-API" arrow/r/check/arrow.Rcheck/00check.log
exit 1
fi
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I'm fine with this, but I wonder if we actually want to have a NOTE scan here (and maybe ignore a handful of them like submission time, large components, and top-level files)?

── R CMD check results ────────────────────────────────── arrow 23.0.1.9000 ────
Duration: 6m 2.2s

❯ checking CRAN incoming feasibility ... [0s/0s] NOTE
  Maintainer: ‘Jonathan Keane <jkeane@gmail.com>’
  
  Version contains large components (23.0.1.9000)

❯ checking top-level files ... NOTE
  Files ‘README.md’ or ‘NEWS.md’ cannot be checked without ‘pandoc’ being installed.

❯ checking compiled code ... NOTE
  File ‘arrow/libs/arrow.so’:
    Found non-API calls to R: ‘R_NamespaceRegistry’, ‘R_UnboundValue’
  
  Compiled code should not call non-API entry points in R.
  
  See ‘Writing portable packages’ in the ‘Writing R Extensions’ manual,
  and section ‘Moving into C API compliance’ for issues with the use of
  non-API entry points.

There also might be flags we can use to turn those notes off BTW too. I have to grep the r source every time to get them, but claude might be able to do that for us?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Great idea!

@github-actions github-actions bot added awaiting changes Awaiting changes and removed awaiting committer review Awaiting committer review labels Apr 2, 2026
@github-actions github-actions bot added awaiting change review Awaiting change review and removed awaiting changes Awaiting changes labels Apr 2, 2026
@thisisnic
Copy link
Copy Markdown
Member Author

@github-actions crossbow submit test-r-linux-as-cran

@github-actions github-actions bot added awaiting changes Awaiting changes and removed awaiting change review Awaiting change review labels Apr 2, 2026
@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 2, 2026

Revision: 7a6fbf8

Submitted crossbow builds: ursacomputing/crossbow @ actions-50e40e7f7f

Task Status
test-r-linux-as-cran GitHub Actions

@github-actions github-actions bot added awaiting change review Awaiting change review and removed awaiting changes Awaiting changes labels Apr 2, 2026
@thisisnic
Copy link
Copy Markdown
Member Author

@github-actions crossbow submit test-r-linux-as-cran

@github-actions
Copy link
Copy Markdown

github-actions bot commented Apr 3, 2026

Revision: 88c7447

Submitted crossbow builds: ursacomputing/crossbow @ actions-c856b69e0d

Task Status
test-r-linux-as-cran GitHub Actions

@thisisnic
Copy link
Copy Markdown
Member Author

@jonkeane - the output now look like this, what do you think?


Run if grep -q "^.* checking .* \\.\\.\\. NOTE$" arrow/r/check/arrow.Rcheck/00check.log; then
Found R CMD check NOTE(s) in output:
73:* checking compilation flags used ... NOTE
74-Compilation used the following non-portable flag(s):
75-  ‘-Wp,-D_FORTIFY_SOURCE=3’
76:* checking compiled code ... NOTE
77-File ‘arrow/libs/arrow.so’:
78-  Found non-API calls to R: ‘R_NamespaceRegistry’, ‘R_UnboundValue’
79-
80-Compiled code should not call non-API entry points in R.
81-
82-See ‘Writing portable packages’ in the ‘Writing R Extensions’ manual,
83-and section ‘Moving into C API compliance’ for issues with the use of
84-non-API entry points.

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

Labels

awaiting change review Awaiting change review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants