-
Notifications
You must be signed in to change notification settings - Fork 1
feat: Update support for Python versions > 3.10 #286
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
Conversation
ansible-runner came out 1 year after the machine-stats and the library matched how we wanted to use ansible, as a way to interact with ansible through a custom cli. So, I've added ansible-runner to be our primary interface to ansible and plan on cleaning up the code in __init__ to more closely match our new usage.
SamDesmondKing
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome work, you're a magician. Like I said I'll take it for a spin later today and report back if any issues
| author="Tidal", | ||
| author_email="[email protected]", | ||
| description="A simple and effective way to gather machine statistics (RAM, Storage, CPU, etc.) from virtual environment", | ||
| description="This program is now deprecated.\n\nA simple and effective way to gather machine statistics (RAM, Storage, CPU, etc.) from virtual environment", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🫗
unix/Pipfile
Outdated
|
|
||
| [packages] | ||
| ansible = "<2.10" | ||
| ansible = "<6" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
phew that's a lot of major versions
unix/Pipfile
Outdated
|
|
||
| [packages] | ||
| ansible = "<6" | ||
| ansible-core = "==2.12" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ah yep I remember you talking about this
| nargs="*", | ||
| ) | ||
|
|
||
| parser.add_argument( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
awesome 👍
In previous versions of machine stats we used an outdated way of wrapping the ansible CLI. This refactor allows us to use Ansible's approved way of programmatically running Ansible, through
ansible-runner.Now, we can more easily maintain the same support for Ansible versions as
ansible-runnerwhich, as of this writing, is anything 3.10 and above.Additionally, for convenience I've also added a
--versionflag command for ease of future debugging efforts.