mirror of
https://github.com/proxmoxer/proxmoxer.git
synced 2026-04-25 07:06:00 +03:00
[GH-ISSUE #49] proxmox.get(item) not working? #24
Labels
No labels
backend:https
backend:local
backend:openssh
backend:ssh_paramiko
pull-request
status:ansible-issue
status:help-wanted
status:info-needed
status:proxmox-issue
status:review-needed
type:bug 🐞
type:dependency ⛓️
type:docs 📝
type:enhancement ⏫
type:maintenance 🛠️
type:meta
type:question ❓
type:request ✋
type:testing 🧪
version:1.x
version:latest
version:py2
version:py3
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/proxmoxer#24
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @edofullin on GitHub (Apr 15, 2021).
Original GitHub issue: https://github.com/proxmoxer/proxmoxer/issues/49
Originally assigned to: @jhollowe on GitHub.
I get errors with this code:
The error in question is on the outermost for loop and is
I'm using Proxmox 6.3-6 and Python 3.9
Using proxmox.nodes.get() insted works correctly, but I would like to use proxmox.get("nodes")
Am I doing something wrong?
@jhollowe commented on GitHub (Apr 16, 2021):
Is there a specific reason you can't use the
proxmox.nodes.get()format?What version of proxmoxer are you using?
@edofullin commented on GitHub (Apr 16, 2021):
The reason was that unit testing was going to be easier, but eventually I managed to use the
proxmox.nodes.get()notation anyway.The README should be updated if the
proxmox.get(string)format is no longer supported.Using latest version, 1.1.1
@jhollowe commented on GitHub (Apr 19, 2021):
Yeah, it looks like
proxmox.something.get()andproxmox.get("something")return different things due to one being aProxmoxResourceobject and one being aProxmoxAPIobject.I think making
ProxmoxAPIinherit fromProxmoxResourcerather thanProxmoxResourceBasemight fix this issue, but I'll need to test that theory and see if that actually works.@jhollowe commented on GitHub (May 13, 2021):
If you don't need the entire path to be on the string, you can use the following: