Skip to content

Defer rubyzip/CSV loading and drop the unused logger require - #98

Closed
pcai wants to merge 6 commits into
mainfrom
perf/defer-heavy-requires
Closed

pcai wants to merge 6 commits into
mainfrom
perf/defer-heavy-requires

Conversation

@pcai

@pcai pcai commented Sep 14, 2026

Copy link
Copy Markdown
Contributor

Reimplementation of the load-time cleanup from @tas50 (Tim Smith) in chef/chef-winrm-fs@643d72b.

  • require "zip" / require "csv" move from load time to first use (inside FileTransporter#initialize and #parse_response respectively), so requiring winrm-fs no longer pulls in rubyzip and CSV up front.
  • TmpZip requires zip in #initialize instead of at load.
  • Drops the unused top-level require "logger" in lib/winrm-fs.rb (nothing references Logger at load).

Note: Zip.unicode_names = true stays in FileTransporter#initialize rather than moving elsewhere, because it affects the archive SHA1 used for the dirty check.

@pcai pcai closed this Sep 14, 2026
@pcai
pcai deleted the perf/defer-heavy-requires branch September 14, 2026 12:57
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