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

Update Imports from Blanket to Selective Import for Improved Code Maintainability #5988

Merged
merged 7 commits into from
Mar 8, 2024

Conversation

Nj221102
Copy link
Contributor

@Nj221102 Nj221102 commented Mar 7, 2024

Summary:
This pull request updates the imports in the codebase to use selective imports instead of blanket imports for better maintainability and reduced risk of conflicts.

Changes Made:

  • Replaced import(methods) with importFrom("methods", "S3Part<-", "slotNames").
  • Replaced import(utils) with importFrom("utils", "tail", "head", "packageVersion", "capture.output", "contrib.url", "download.file", "flush.console", "getS3method", "untar", "unzip").
  • Replaced import(stats) with importFrom("stats", "na.omit", "as.formula", "setNames", "terms", "time").

This PR Closes #5970

Copy link

codecov bot commented Mar 7, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 97.49%. Comparing base (e2ce90a) to head (298aede).

❗ Current head 298aede differs from pull request most recent head 2c9006a. Consider uploading reports for the commit 2c9006a to get more accurate results

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #5988   +/-   ##
=======================================
  Coverage   97.49%   97.49%           
=======================================
  Files          80       80           
  Lines       14861    14861           
=======================================
  Hits        14488    14488           
  Misses        373      373           

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

@Nj221102
Copy link
Contributor Author

Nj221102 commented Mar 7, 2024

@MichaelChirico plz checkout this PR if you have time :)

@MichaelChirico
Copy link
Member

thanks! please remove quotes (") wherever possible

@Nj221102
Copy link
Contributor Author

Nj221102 commented Mar 7, 2024

thanks! please remove quotes (") wherever possible

@MichaelChirico I removed quotes from everywhere except "S3Part<-" because it was causing some error.

@MichaelChirico
Copy link
Member

I removed quotes from everywhere except "S3Part<-" because it was causing some error.

right, NAMESPACE needs to parse as R, so S3Part<- needs to be quoted. Any "normal" R name (?make.names) needn't be quoted.

@MichaelChirico
Copy link
Member

Sorry, one more change -- please add yourself to Authors@R field for this change, since it is not just a "documentation" change.

LGTM otherwise, thanks!

@Nj221102
Copy link
Contributor Author

Nj221102 commented Mar 8, 2024

Sorry, one more change -- please add yourself to Authors@R field for this change, since it is not just a "documentation" change.

LGTM otherwise, thanks!

Done 👍

@MichaelChirico MichaelChirico merged commit a8a595f into Rdatatable:master Mar 8, 2024
2 of 3 checks passed
@MichaelChirico
Copy link
Member

Thanks for the PR! You've been added as a project member to facilitate future collaboration! Check your e-mail. You'll be able to create branches directly from this repo going forward. Thanks again!

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.

Use selective imports
2 participants