Skip to content

Comments

Pandas follow-ups: categorical conversion + threaded starter guardrails#1883

Merged
t-kalinowski merged 4 commits intomainfrom
fix/pandas3-followups
Feb 12, 2026
Merged

Pandas follow-ups: categorical conversion + threaded starter guardrails#1883
t-kalinowski merged 4 commits intomainfrom
fix/pandas3-followups

Conversation

@t-kalinowski
Copy link
Member

Summary

  • fix direct py_to_r() conversion for pandas.Categorical on pandas 3 by adding short-class S3 dispatch (pandas.Categorical) and switching categorical value extraction to to_numpy()
  • reject free-threaded CPython builds in virtualenv_starter() and can_be_virtualenv_starter() using a python -VV probe for free-threaded build markers
  • keep the intentional py_require warning assertion in its dedicated test, and disable that warning path in test-python-virtual-environments.R so it does not leak uncaptured output from subprocess stderr

Testing

  • devtools::test()
  • devtools::test(filter = 'python-envs')
  • devtools::test(filter = 'python-virtual-environments')
  • devtools::test(filter = 'py_require')
  • interactive check in fresh session: py_require('pandas<3') with pandas 2.3.3 and py_to_r(pd$Categorical(...)) returns ordered factor

@t-kalinowski t-kalinowski merged commit f391804 into main Feb 12, 2026
13 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.

1 participant