Bug? Seeing inconsistent cached data

mattbaker
mattbaker
Community Member

Querying for an item (op get item "My Item") is returning stale data, providing a password value that I changed over a month ago. However, very occasionally I'll get the newer, correct data.

Any thoughts on this?

op version 0.2.1


1Password Version: Not Provided
Extension Version: Not Provided
OS Version: 10.12.6
Sync Type: Not Provided

Comments

  • mattbaker
    mattbaker
    Community Member

    (Just realized I'm presuming this is some kind of caching issue, I don't know, but hopefully my description of the problem outlines what's going on!)

  • AGAlumB
    AGAlumB
    1Password Alumni

    @mattbaker: The CLI app should be pulling data directly from the server (which is where you'll often see a slight delay), so the first thing to do would be to sign into your account in the browser and see if the item is "updated" there. Did you perhaps change it on another device, and the app wasn't able to upload the changes?

  • mattbaker
    mattbaker
    Community Member
    edited February 2018

    Hey @brenty, thanks for the reply. The web client shows the correct password.

    As I mentioned, I updated the password value a while ago. Glancing at the item history in the web interface, it appears I made the change 11/20/2017. Plenty of time to propagate I presume.

    Repeatedly running the same command (op get item "My Item") yields inconsistent results moment to moment, usually providing the incorrect (non-updated) value, and only occasionally returning the correct (post-11/20/2017) value. I just tried it again on my home machine as well, and can confirm that it's still occurring. Out of 20 runs, 1 run provided the correct data, not sure if that percentage is useful but I figured it could be helpful.

    All of this leads me to the hunch that this is something to do with data consistency on the server end, especially since the same command can yield different results, but if there's anything I can do to debug locally let me know, obviously you know the architecture of the system and I don't :)

  • mattbaker
    mattbaker
    Community Member

    @brenty - shall I file a bug report?

  • Hi @mattbaker,

    Is it possible that you have a trashed item with the same name, or another item? We have an issue currently where op get item can return different items if you have two items with the same name and are querying by name. I've filed an issue on our end so that we can look at doing that better.

    Something to test would be to see if you get perfectly consistent results by doing op get item and passing in the item uuid.

    Rick

  • mattbaker
    mattbaker
    Community Member

    Hi @rickfillion — sorry for the delay. I don't believe I have a trashed item with the same name, but I have updated that password over time. I tried the UUID lookup and it appears consistent which will work for the time being. Thanks for the help.

  • If the UUID lookup works consistently, then it must be a case of multiple matches coming back for the search query performed, and it picking one arbitrarily. It'd really be nice if we handled that better.

    Rick

This discussion has been closed.