spamwax / alfred-pinboard-rs

Alfred Workflow for Pinboard (Rust)
Other
280 stars 13 forks source link

Search results for some tags is missing #7

Closed mingweiarthurli closed 6 years ago

mingweiarthurli commented 6 years ago

Hello,

I found that some search results were missing when I search bookmarks with existing tags. This does not always happen, but when using some keywords to search (I tried several keywords, some works fine, but some have this problem), it will only show the bookmarks that include the keywords in title, but miss the bookmarks that have the keywords in their tags.

I recorded 3 GIF using pt and ps command to search some tags. You can notice the difference between the number of bookmarks using the given tag and the number of results of searching the tag. 2018-05-27 22_28_15

2018-05-27 22_15_48

2018-05-27 22_21_57

For the third GIF, I need to point out that there are two bookmarks contain the tag "iTerm", and the one shown in search result also contain the keyword "iTerm" in its title.

Since I only have a few bookmarks now, this can be easily noticed by me. I am not sure whether other people have keywords that facing the same problem, so please tell me what I can help if there is difficulty to reproduce this.

I pretty appreciate this workflow, which is the best Pinboard workflow I found. Thank you for creating this workflow.

Version information:

spamwax commented 6 years ago

Thanks for your report. I will look into this in more details, however there is an issue with Pinboard itself returning wrong number of tags. Additionally, as you have noticed pt is not documented and it is an incomplete feature I was working on, so it's not stable yet.

Meanwhile, can you manually verify that number of tags you have on your Pinboard account? Also, if you don't mind can you share your bookmark dump with me (privately?) something like: curl -v https://api.pinboard.in/v1/posts/all\&auth_token\=user:token\?format\=json > bookmarks.json

no biggie, if you don't want to share it 🙂

mingweiarthurli commented 6 years ago

Hello spamwax,

I double checked the number of tags shown in pt command results are correct. I started to use Pinboard recently, and I only have a few bookmarks, so it can be easily checked.

I'm glad to offer my bookmark dump, and I attached it with a Dropbox link. If there is any further thing that I can help, just say it. bookmarks.json

spamwax commented 6 years ago

latest release should have this fixed. please report back here if issue still persists.

mingweiarthurli commented 6 years ago

I tested the new release after updated the cache, but the problem seems to still exist :/ I saw you updated rusty-pin with new .rs files, but for alfred-pinboard-rs seems only the .plist file and the shell script for building was updated. I'm not familiar with rust. I'm sorry if I'm wrong.

spamwax commented 6 years ago

Thanks for checking. The binary is not tracked, that's why it doesn't show up as updated. As you saw in rusty-pin, there is a specific test that is based on bookmarks you provided and it passes!

just to get the basics out of the way:

You can see if you have the version 0.13.3 by running this from (~/Dropbox/Alfred/Alfred.alfredpreferences/workflows/user.workflow.665EAB20-5141-463D-8C5A-90093EEAA756)

./alfred-pinboard-rs --version

If problem still persists, I am gonna need to ask you to share the list of tags that Pinboard returns for you: curl -v https://api.pinboard.in/v1/tags/get\&auth_token\=user:token\?format\=json > tags.json

mingweiarthurli commented 6 years ago

After I followed your instruction to uninstall the workflow and clear the cache, the new version does work! 😃 These two steps seem to be essential. Thank you for fixing this bug.

spamwax commented 6 years ago

Great,

If you have time can you do me a favor and do the same thing but this time using the release page download: https://github.com/spamwax/alfred-pinboard-rs/releases/download/0.13.3/alfred-pinboard-rust-0.13.3.alfredworkflow

Just wanna make sure travis built the correct binary.

Thanks again

mingweiarthurli commented 6 years ago

I tested the published release again with that two steps, it doesn't work properly.

I also tried updating to the new build from the published one without uninstalling. The uninstalling step is not necessary, but clearing cache manually is essential. Using pu command seems cannot fix the cache files that saved by the published.

spamwax commented 6 years ago

ok, thanks. pu will force cache update only if you have added/modified something on Pinboard in order to avoid unnecessary network calls.

now I have to figure out what went wrong with that build :(