Summary
Several Puppet::Util helpers are explicitly deprecated in favor of direct ENV usage.
Evidence
lib/puppet/util.rb:44 get_env deprecated.
lib/puppet/util.rb:51 get_environment deprecated.
lib/puppet/util.rb:58 clear_environment deprecated.
lib/puppet/util.rb:65 set_env deprecated.
lib/puppet/util.rb:72 merge_environment deprecated.
Proposed OpenVox 9 Change
- Remove deprecated wrapper methods.
- Update internal callers to use
ENV directly or withenv where scoped overrides are needed.
Compatibility / Risk
- Medium risk for external code importing these helpers.
- Internal migration is straightforward.
Implementation Notes
- Identify internal call sites with
rg before removal.
- Keep
withenv behavior if still actively used and not deprecated.
- Update developer docs that reference deprecated wrappers.
Acceptance Criteria
- Deprecated wrapper methods no longer exist in
Puppet::Util.
- Internal codebase contains no calls to removed wrappers.
- Environment manipulation behavior is unchanged where supported APIs remain.
Suggested Tests
- Unit tests for environment-sensitive code paths.
- Scoped environment restoration tests around
withenv.
Summary
Several
Puppet::Utilhelpers are explicitly deprecated in favor of directENVusage.Evidence
lib/puppet/util.rb:44get_envdeprecated.lib/puppet/util.rb:51get_environmentdeprecated.lib/puppet/util.rb:58clear_environmentdeprecated.lib/puppet/util.rb:65set_envdeprecated.lib/puppet/util.rb:72merge_environmentdeprecated.Proposed OpenVox 9 Change
ENVdirectly orwithenvwhere scoped overrides are needed.Compatibility / Risk
Implementation Notes
rgbefore removal.withenvbehavior if still actively used and not deprecated.Acceptance Criteria
Puppet::Util.Suggested Tests
withenv.