op 2.3 via Connect broken
Looks like op 2.3 and/or Connect is broken (reading fields from sections?), breaking almost all of my automations...
On my Raspberry Pi or router (both talking to 1Password Connect on my Pi).
➜ op read op://Automation/fastmail/webdav/password [ERROR] 2022/05/23 09:24:49 could not read secret op://Automation/fastmail/webdav/password: could not find field or file password in section webdav on item fastmail in vault Automation ➜ op read op://Automation/fastmail/username me@fastmail.com
On my MacBook Pro (directly talking to 1password.com):
➜ op read op://Automation/fastmail/webdav/password my password ➜ op read op://Automation/fastmail/username me@fastmail.com
Please fix (reading fields from sections?) ASAP.
1Password Version: CLI 2.3 / Connect
Extension Version: n/a
OS Version: n/a
Comments
-
Hey @XIII,
Thank you for reaching out to us!
If your automations worked before, and only fail now, it is likely that this is a regression with the 1Password CLI, since Connect did not release any new versions, in the past few days.
I have tried, using 2.3.0 (with a Connect backend), to read fields from sections, both with names and IDs, as well as sectionless fields, and I was not able to reproduce this issue. Can you please give us more details about your setup?
For example, the json structure of an item where you noticed this happening (with all the sensitive details concealed, of course) could help us a lot.
Have you noticed that reading fields from sections is consistently broken, or only in specific scenarios/for specific items or fields?
Please, also let us know anything else that you think would be relevant.Looking forward to hearing from you!
Best,
Horia0 -
- reading those fields with 2.3.0 is consistently broken
- I reverted to 2.2.0 on one of my machines and then I can read the fields fine (using Connect)
- please try a concealed (password) field in a section of a secure note (that's what failing for me with 2.3.0 & Connect only)
0 -
Might me more complicated:
op://Automation/fastmail/webdav/password
does failop://Automation/fastmail/imap/password
returns a password
0 -
Thanks for the additional details. I'll look a bit into it, and will post here any updates that I come across.
Best,
Horia0 -
I don't know whether this is relevant, but I also noticed this when executing
op item get fastmail --format=json
:- On MacBook Pro (via 1password.com): JSON with item info
- On Pi/router (via Connect):
[ERROR] 2022/05/23 14:29:28 vault not found:
(and nothing after that colon)
EDIT: probably not; same error with 2.2.0, while that does return the webDAV password
0 -
This is indeed a known bug, limitation of Connect: vault has to always be mentioned.
Please let us know if you notice anything unusual in the output of:op item get fastmail --format json --vault <your-vault>
I'm opening a ticket now, to make sure a more useful error is being added.
Best,
Horia0 -
In particular, can you please let us know if the
webdav
(that seems to be problematic, when retrieving) has a properly formatted UUID (i.e. 26 characters, digits and lowcase letters?)Have you noticed any other fields that behave similarly? Do the items that exhibit these problems have anything in common? For example, have they been created with the same client?
Looking forward to hearing from you.
Best,
Horia0 -
Looks like item and vault are case sensitive for Connect, but case-insensitive for 1password.com?
- vault
Automation
works for both - vault
automation
works for 1password.com only
However, with the correct casing (or even when using the item
id
instead of the itemtitle
), I get this:- On MacBook Pro (via 1password.com): JSON with item info
- On Pi/router (via Connect): either
item Fastmail not found
0 - vault
-
It seems that there might be two bugs.
The bug that you described in your last reply is related to retrieving items. I was able to pinpoint the specific change that caused it, and will address it.
However, this does not seem to be linked to the inability to retrieve fields within sections. Am I correct to understand that you were able to reproduce this bug (erroring when retrieving fields in sections) both using Connect and 1Password as backend?
Looking forward to hearing from you.
Best,
Horia0 -
Am I correct to understand that you were able to reproduce this bug (erroring when retrieving fields in sections) both using Connect and 1Password as backend?
No, so far fetching a field (
webdav/password
) value works fine using 1password.com, but fails using Connect.(but a similar field
imap/password
in the same item works on both 1password.com and Connect...)0 -
I've looked a bit into the code responsible for this, and have confirmed that this error can be returned in two cases:
- the section cannot be properly identified
- the field cannot be properly identified
In order to continue diagnosing this, can you please take another look at your item's json and let us know if there is anything that appears unusual about the section/the field that this error happens for?
In particular, I am interested whether the field ID and the section ID (as they can be seen in the item's json format) are properly formatted: i.e. strings made out of 26 characters (lowercase letters and digits). My hunch is that there may be something off with the validation that the CLI performs when passing queries to Connect, when looking up sections/fields.
Looking forward to hearing from you.
Best,
Horia0 -
I think the issue occurs because the field names in two sections of one item are identical...
This is what happens with different field names:
webdav/password
&imap/password
: only readingimap/password
workswebdav/passwork
&imap/password
: reading both fields workwebdav/password
&imap/passwork
: reading both fields work
Does this help in finding/fixing the bug?
0 -
Indeed, we think we've identified it!
Thank you for all your help here.
We're currently working on a fix, and will notify you as soon as this rolls out!Best,
Horia0 -
That's good news!
Hope the fix will be available soon; several automations are broken here because of this...
(apparently I got quit dependent on this new 1Password product;)
0 -
Hey @XIII
This should fix it: https://app-updates.agilebits.com/product_history/CLI2#v2030101
Thank you once again for raising this with us, and helping us diagnose and fix this.
Looking forward to hearing your feedback!Best,
Horia0 -
Did not see it appear in my RSS feed yet (oh wait, that also does not work because of this bug), so thank you for informing me here.
CLI version 2.3.1 indeed solves the problem; I can now read that password using both 1password.com and Connect! Thank you!
0