2DegreesInvesting / tiltIndicator

Indicators for the TILT project
https://2degreesinvesting.github.io/tiltIndicator/
GNU General Public License v3.0
1 stars 1 forks source link

`emissions_profile_any_compute_profile_ranking()` is now internal #669

Closed maurolepore closed 5 months ago

maurolepore commented 5 months ago

Closes #661

This PR deprecates emissions_profile_any_compute_profile_ranking() in favor of an identical, internal function epa_compute_profile_ranking(). The name of the internal function follows the style of other intenal functions, e.g. spa_compute_profile_ranking(). Also a different name is necessary to avoid the user-facing warning in internal calls and tests.

reprex

The old function will still exist for a while but you get a deprecation warning.

devtools::load_all()
#> ℹ Loading tiltIndicator

co2 <- example_products()

internal <- epa_compute_profile_ranking(co2)

deprecated <- emissions_profile_any_compute_profile_ranking(co2)
#> Warning: `emissions_profile_any_compute_profile_ranking()` was deprecated in
#> tiltIndicator 0.0.0.9109.
#> ℹ This function is now internal.
#> This warning is displayed once every 8 hours.
#> Call `lifecycle::last_lifecycle_warnings()` to see where this warning was
#> generated.

identical(deprecated, internal)
#> [1] TRUE

TODO

EXCEPTIONS