Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Strange import from data.table #1

Open
MichaelChirico opened this issue Mar 14, 2024 · 1 comment · May be fixed by #2
Open

Strange import from data.table #1

MichaelChirico opened this issue Mar 14, 2024 · 1 comment · May be fixed by #2

Comments

@MichaelChirico
Copy link

do/NAMESPACE

Line 127 in 7d91dc3

importFrom(data.table,`.__T__[:base`)

This is a very unusual object to import in your NAMESPACE -- as far as I can tell, these are an implementation detail / not to be relied upon.

We recently encountered this when removing import(methods) from data.table's own NAMESPACE:

Rdatatable/data.table#6000

Could you elaborate on why this entry is needed?

@dmurdoch
Copy link

This message: https://stat.ethz.ch/pipermail/r-package-devel/2024q1/010584.html describes the issue, and suggests a better solution: insert code

.datatable.aware = TRUE

somewhere in the source of your package (outside any function). There's no need to export this value, it just needs to be visible to any function that uses data.table syntax when subsetting.

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 a pull request may close this issue.

2 participants