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

chore(renovate): major Update module github.com/shirou/gopsutil/v3 to v4 #127

Closed
wants to merge 1 commit into from

Conversation

renovate[bot]
Copy link
Contributor

@renovate renovate bot commented Nov 2, 2024

This PR contains the following updates:

Package Change Age Adoption Passing Confidence
github.com/shirou/gopsutil/v3 v3.24.5 -> v4.24.10 age adoption passing confidence

Release Notes

shirou/gopsutil (github.com/shirou/gopsutil/v3)

v4.24.10

Compare Source

What's Changed

cpu
mem
Other Changes

New Contributors

Full Changelog: shirou/gopsutil@v4.24.9...v4.24.10

v4.24.9

Compare Source

Important Change

Since #​1702, the Darwin implementation has been switched from cgo to purego (Great contribution from @​uubulb). As a result, cgo has been removed from the Darwin implementation, making cross-compilation easier. We believe this change will not have any impact, but if you encounter any issues, please create an issue.

What's Changed

cpu, mem, sensors, disk, process on darwin
process
Other Changes

New Contributors

Full Changelog: shirou/gopsutil@v4.24.8...v4.24.9

v4.24.8

Compare Source

What's Changed

disk
process
Other Changes

New Contributors 🎉

Full Changelog: shirou/gopsutil@v4.24.7...v4.24.8

v4.24.7

Compare Source

Important Notice Regarding Value Changes on mem.SwapMemory() on Windows

In change #​1677, the values returned by mem.SwapMemory() on Windows have been significantly revised. Previously, these values were calculated from the PERFORMANCE_INFORMATION structure of the GetPerformanceInfo win32 function, but this calculation was incorrect. Consequently, it has been adjusted to align with the psutil implementation. As a result, the values returned by mem.SwapMemory() are expected to differ greatly from previous values.

What's Changed

docker
mem
Other Changes

New Contributors

Full Changelog: shirou/gopsutil@v4.24.6...v4.24.7

v4.24.6

Compare Source

What's Changed

host
sensors
Other Changes

New Contributors

Full Changelog: shirou/gopsutil@v4.24.5...v4.24.6

What's Changed

host
Other Changes

New Contributors

Full Changelog: shirou/gopsutil@v4.24.5...v4.24.6

v4.24.5

Compare Source

What's Changed

gopsutil v4 is released as v4.24.5. v3 will not be updated except for high level security issues.

Breaking Changes

  • host/SensorsTemperatures() moved to in the new sensors package.
  • process.Groups() now returns uint32. (#​1424)
  • process.Uids() and process.Gids() also now uint32.
    • The Pid remains int32. This is because changing it is expected to have a significant impact.
  • mem.VirtualMemoryExStat is now ExVirtualMemory with ExLinux and ExWindows. See document about Ex structs.

Other

  • Add SPDX license header line.
  • Remove coveralls.io
  • Remove old go build tag such as // +build

Full Changelog: shirou/gopsutil@v3.24.5...v4.24.5


Configuration

📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

Copy link

@llamapreview llamapreview bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PR Review: chore(renovate): major Update major (major)

Overview

The PR updates the dependencies of the github.com/charmbracelet/lipgloss and github.com/shirou/gopsutil/v3 packages to their latest major versions. The purpose is to ensure compatibility with the latest features and security updates.

  • Business Context: Ensure the application uses the latest versions of critical dependencies to leverage new features and security patches.
  • Technical Context: Update lipgloss from v0.13.1 to v1.0.0 and gopsutil from v3.24.5 to v4.24.10.
  • Expected Impact: Potential breaking changes due to major version updates, requiring thorough testing and code adjustments.

Technical Assessment

Critical Issues (Must Fix)

  • Issue Description: The update to gopsutil from v3.24.5 to v4.24.10 introduces breaking changes. The host/SensorsTemperatures() function has been moved to the sensors package, and process.Groups(), process.Uids(), and process.Gids() now return uint32.
  • Risk Level: High
  • Specific Example: host/SensorsTemperatures() function call will fail due to the function being moved.
  • Recommended Solution with Code Sample:
    // Old Code
    temp := gopsutil.SensorsTemperatures()
    
    // New Code
    temp := gopsutil.sensors.SensorsTemperatures()

Important Considerations

  • Dependency Changes: The lipgloss package update introduces significant changes that may affect the application's UI components. Ensure compatibility with the new version and update API calls accordingly.
  • Configuration Changes: The introduction of SPDX license headers and removal of coveralls.io in gopsutil may require updates to CI/CD pipelines and license management tools.

Minor Suggestions

  • Code Organization: Refactor the code to handle the new uint32 return types for process.Groups(), process.Uids(), and process.Gids().
  • Test Coverage: Ensure that all unit and integration tests are updated to reflect the changes in the dependencies and their APIs.

Functional Analysis

  • Requirements Coverage Matrix: Ensure all functional requirements are covered by the updated dependencies. Verify that any deprecated functions or methods are replaced with their new equivalents.
  • Edge Cases Identification: Identify edge cases such as handling uint32 return types and moving functions to new packages.
  • Performance Implications:
    • Expected Load: The updates should not significantly impact the expected load.
    • Resource Usage: Monitor resource usage post-update to ensure no regressions.
    • Scalability Concerns: The updates should not introduce scalability issues, but thorough testing is recommended.
  • Security Considerations:
    • Attack Vectors: Review the security implications of the new dependencies, especially changes to data handling and access control.
    • Data Protection: Ensure that sensitive data is protected and not exposed through new APIs or changes in data structures.
    • Access Control: Verify that access control mechanisms are not affected by the updates.

Implementation Review

Dependency Updates

  • Changes Overview: Update lipgloss to v1.0.0 and gopsutil to v4.24.10.
  • Technical Details:
    • Code Samples:
      // go.mod changes
      require (
        ...
        github.com/charmbracelet/lipgloss v1.0.0
        github.com/shirou/gopsutil/v4 v4.24.10
        ...
      )
    • Configuration Changes: Update CI/CD pipelines to handle the new dependencies and their build requirements.
    • Architecture Impacts: Ensure that the application architecture can accommodate the breaking changes introduced by the updates.
  • Issues:
    • Current Problems: The host/SensorsTemperatures() function and changes to process methods need to be addressed.
    • Potential Risks: Incompatibility with existing code, potential regressions in functionality.
    • Edge Cases: Handling of uint32 return types and moved functions.
  • Recommendations:
    • Specific Code Changes: Update all calls to SensorsTemperatures() and handle the new return types for process methods.
    • Configuration Updates: Update CI/CD pipelines to handle the new dependencies.
    • Best Practices: Follow best practices for handling major version updates, including thorough testing and code review.

Testing & Documentation

Test Coverage

  • Unit Test Requirements: Update all unit tests to reflect the changes in the dependencies.
  • Integration Test Scenarios: Ensure that integration tests cover the new APIs and data structures.
  • Performance Test Cases: Conduct performance tests to ensure no regressions.
  • Current vs. Required Coverage Metrics: Aim for 100% test coverage for the affected functional areas.

Documentation Updates

  • API Changes: Document all API changes resulting from the dependency updates.
  • Configuration Changes: Update documentation to reflect changes in CI/CD pipelines and build requirements.
  • Deployment Instructions: Ensure deployment instructions are updated to reflect the new dependencies.
  • Migration Guide: Provide a migration guide for users to update their environments to the new dependencies.

Security & Performance

  • Security Impact Analysis: Review the security implications of the new dependencies and update security policies accordingly.
  • Performance Benchmarks: Conduct performance benchmarks to ensure no regressions.
  • Scalability Considerations: Ensure that the updates do not introduce scalability issues.
  • Monitoring Requirements: Update monitoring to track the performance and security of the new dependencies.

Summary and Recommendations

  • Overall Assessment: The updates introduce significant changes that require thorough testing and code adjustments.
  • Risk Analysis: High risk due to breaking changes and potential incompatibilities.
  • Prioritized Action Items (with effort estimation):
    • Update all calls to SensorsTemperatures() and handle new return types for process methods (High, 2 days)
    • Update CI/CD pipelines to handle the new dependencies (Medium, 1 day)
    • Conduct thorough testing and code review (High, 3 days)
  • Migration Strategy: Provide a detailed migration plan to update the application and its environment to the new dependencies.

CI/CD Results

  • Overall State: None
  • Check Runs:
    • cleanup: completed, skipped
    • build: in_progress
    • GitGuardian Security Checks: in_progress

These updates are critical for maintaining the application's compatibility with the latest features and security patches. Thorough testing and code review are essential to ensure a smooth transition.

@renovate renovate bot changed the title chore(renovate): major Update major (major) chore(renovate): major Update module github.com/shirou/gopsutil/v3 to v4 Nov 19, 2024
@renovate renovate bot force-pushed the renovate/major-major branch 5 times, most recently from 38f1e45 to c376bd2 Compare November 26, 2024 02:11
@renovate renovate bot force-pushed the renovate/major-major branch from c376bd2 to 31f32a5 Compare November 26, 2024 21:13
@renovate renovate bot force-pushed the renovate/major-major branch from 31f32a5 to 8d5cf7d Compare November 26, 2024 21:21
Copy link
Contributor Author

renovate bot commented Nov 29, 2024

ℹ Artifact update notice

File name: go.mod

In order to perform the update(s) described in the table above, Renovate ran the go get command, which resulted in the following additional change(s):

  • The go directive was updated for compatibility reasons

Details:

Package Change
go 1.21.0 -> 1.22.8

@sammcj
Copy link
Owner

sammcj commented Nov 29, 2024

no, AWS's crappy AMIs can't run current golang.

@sammcj sammcj closed this Nov 29, 2024
Copy link
Contributor Author

renovate bot commented Nov 29, 2024

Renovate Ignore Notification

Because you closed this PR without merging, Renovate will ignore this update. You will not get PRs for any future 4.x releases. But if you manually upgrade to 4.x then Renovate will re-enable minor and patch updates automatically.

If you accidentally closed this PR, or if you changed your mind: rename this PR to get a fresh replacement PR.

@renovate renovate bot deleted the renovate/major-major branch November 29, 2024 00:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant