Closed irons closed 2 years ago
Hi there!
I've just released version v1.2.0 that contains the code you tested on c809bfa0f
. In the previously released versions the item returned was only a summary item so not all data was included. The get_item_by_title
method should be updated now to include field data. Please let me know if you run into any issues!
Thanks, that's very helpful.
Your environment
SDK Version: 1.0, 1.1, and tip of main (c809bfa0f)
Connect Server Version: 1.5.0
OS: macOS 11.6.4
Python Version: 3.9.10, 3.9.11, 3.10.2, 3.10.3
What happened?
Upon upgrading from Python 3.9.10 to last week's 3.9.11, some pretty basic 1Password item retrieval code broke. On later examination, 3.9.10 only continued to work because I had previously built the library locally to troubleshoot #36 — the problem was in the released library versions.
Here's the complete json skeleton from a synthesized item I'm trying to retrieve:
Here's some code to retrieve it:
Versions 1.0 and 1.1 of onepasswordconnectsdk get back a SummaryItem object which doesn't contain any
fields
attribute, which is where all my stuff is.pprint(item)
on the failing versions returns this:What did you expect to happen?
When I build
c809bfa0f
locally and install it, the pprint output looks like this:In the library version built from
c809bfa0f
, the list comprehension in the second-to-last line successfully squeezes a password out of this item. In the released versions, the list comprehension results in:"AttributeError: 'SummaryItem' object has no attribute 'fields'".