Repository navigation
osn_system_utils v0.0.2
osn_system_utils v0.0.2 - Refined API, Advanced Process Management, and Enhanced Network Discovery
Version 0.0.2 marks a significant step forward for the library, evolving from a collection of system wrappers into a structured, high-level API for system and network management. This release introduces a powerful process filtering engine, renames the package for better consistency, and refines network port discovery strategies.
Key Improvements in v0.0.2:
- New Process Management API: A comprehensive suite of tools has been added in
osn_system_utils.api.process. You can now check for process existence by PID or name, terminate process trees cross-platform, and retrieve detailed process information using a structured table format. - Advanced Filtering & Nested Lookups: The new
get_process_tablefunction supports sophisticated filtering. You can filter processes using regex, equality, or numerical ranges (above, under, between) even for nested attributes (e.g.,memory_info.rss) using dot-notation paths. - Enhanced Network Port Discovery: The networking API has been refactored for flexibility. The new
get_localhost_free_port_offunction replaces older methods, allowing you to find available ports using different strategies:min,max, orrandom. New helpers likeget_localhost_busy_portsalso provide better visibility into system state. - Strict API Exposure: Every module now implements
__all__exports. This ensures a cleaner developer experience by exposing only intended public functions and constants, preventing internal helper functions from cluttering your IDE's autocomplete. - Refined Package Naming & Documentation: The library has transitioned toward the
osn_system_utilsnaming convention across documentation and installation guides. The README has been completely overhauled with clear examples for process filtering and socket statistics. - Improved Type Safety: Enhanced type hinting, including the use of
Literalfor parameter validation andTYPE_CHECKINGblocks, provides better static analysis and reduced runtime errors.
Putting It All Together:
This update transforms osn_system_utils into a more professional and reliable tool for systems programming. By combining low-level OS wrappers with a high-level, pythonic API for processes and networking, v0.0.2 provides developers with a consistent interface for complex system tasks regardless of whether they are running on Linux or Windows.