dessant / search-by-image

Browser extension for reverse image search, available for Chrome, Edge and Safari
https://apps.apple.com/us/app/search-by-image-for-safari/id1544552106
GNU General Public License v3.0
2.16k stars 192 forks source link

Yandex search in "select and upload" mode stopped working #134

Closed alexolog closed 3 years ago

alexolog commented 3 years ago

System

Bug description Yandex search in "select and upload" mode does not work.

Logs

21:48:53.220 Error: Please use $(ref:runtime.getURL). i18n.js:26
21:48:57.881 XHRGEThttps://ukmadcat.com/wp-content/uploads/2019/04/sleepy-cat.jpg
[HTTP/2 200 OK 0ms]

21:48:58.217 Error: Could not establish connection. Receiving end does not exist. background.js:16:22
21:48:58.283 GEThttps://yandex.com/images/
[HTTP/2 200 OK 324ms]

21:48:58.854 Content Security Policy: Ignoring “'unsafe-inline'” within script-src or style-src: nonce-source or hash-source specified
21:48:59.014 Content Security Policy: The page’s settings blocked the loading of a resource at inline (“script-src”). moz-extension:50:25
21:48:59.206 GEThttps://yastatic.net/s3/fiji-static/_/PNsOsGQPnbpquOps9yOVoK89jfE.css
[HTTP/2 200 OK 145ms]

21:48:59.210 GEThttps://yastatic.net/s3/fiji-static/_/AdvancedSearch@desktop.79d07f4ef8978636ea32.css
[HTTP/2 200 OK 174ms]

21:48:59.213 GEThttps://yastatic.net/s3/fiji-static/_/ImagesViewer@desktop.a51a47c38414a9430fcf.css
[HTTP/2 200 OK 300ms]

21:48:59.217 GEThttps://yastatic.net/jquery/2.1.4/jquery.min.js
[HTTP/2 200 OK 390ms]

21:48:59.221 GEThttps://yastatic.net/bem-xjst/7.7.1/bemhtml.min.js
[HTTP/2 200 OK 413ms]

21:48:59.225 GEThttps://yastatic.net/s3/fiji-static/_/_qx_M6PRv55lB49vTbI07wGFJKk.js
[HTTP/2 200 OK 604ms]

21:48:59.229 GEThttps://yastatic.net/s3/fiji-static/_/QwJe1unJUhVCqx9cL2WdjGYUJt4.js
[HTTP/2 200 OK 602ms]

21:48:59.246 GEThttps://yastatic.net/s3/fiji-static/_/oGrHRI5TNy6HkliPeV6RpMaf-J8.js
[HTTP/2 200 OK 592ms]

21:48:59.256 GEThttps://yastatic.net/s3/fiji-static/_/pPeFDYhtzvPbzn1TJ1pf87kuyiE.js
[HTTP/2 200 OK 581ms]

21:48:59.261 GEThttps://yastatic.net/react/16.8.4/react-with-dom-and-polyfills.min.js
[HTTP/2 200 OK 616ms]

21:48:59.278 GEThttps://yastatic.net/s3/fiji-static/_/AdvancedSearch@desktop.en.42437f4ef8978636ea32cb3c9697483f.js
[HTTP/2 200 OK 619ms]

21:48:59.282 GEThttps://yastatic.net/s3/fiji-static/_/PopularRequestList@desktop.en.474742efb1d796353c198c68d302c5fc.js
[HTTP/2 200 OK 614ms]

21:48:59.284 GEThttps://yastatic.net/s3/fiji-static/_/ImagesViewer@desktop.en.466747c38414a9430fcf9145b3a1ffb8.js
[HTTP/2 200 OK 691ms]

21:48:59.288 GEThttps://yastatic.net/s3/fiji-static/_/p8cs9GoXNQf3GS5PLwKEAIuR_oQ.css
[HTTP/2 200 OK 656ms]

21:48:59.336 POSThttps://csp.yandex.net/csp?from=images:desktop:foreign&project=images&reqid=1626313738410189-10535534316918000010-man1-8963-man-l7-balancer-8080-BAL10905-sas1-7946-IMG&yandexuid=6313361295512930762&yandex_login=myuserid
[HTTP/1.1 200 OK 147ms]

21:48:59.619 Error: Please use $(ref:runtime.getURL). 2 i18n.js:26
21:48:59.626 Error: Please use $(ref:runtime.getURL). utils.js:899
21:48:59.626 Error: Please use $(ref:runtime.getURL). 3 downbar.js:286
21:49:00.238 Error: Please use $(ref:runtime.getURL). background.js:31
21:49:00.964 Error: Please use $(ref:runtime.getURL). 2 i18n.js:26
21:49:01.261 GEThttps://yastatic.net/s3/fiji-static/_/zwYO0cbgikjAabOgvCkdJVZS-K0.svg
[HTTP/2 200 OK 0ms]

21:49:01.266 XHRGEThttps://static-mon.yandex.net/static/main.js?pid=yandex_images
[HTTP/1.1 200 OK 1145ms]

21:49:01.473 XHRGEThttps://yastatic.net/s3/fiji-static/_/JaYPHxbyxkC3UjMdM6rT2ohKa_M.js
[HTTP/2 200 OK 138ms]

21:49:01.513 GEThttps://mc.yandex.ru/metrika/watch.js
[HTTP/2 200 OK 0ms]

21:49:01.615 XHRGEThttps://mail.yandex.com/api/v2/serp/counters?silent
[HTTP/1.1 200 OK 186ms]

21:49:02.114 Some cookies are misusing the recommended “SameSite“ attribute 5
21:49:02.115 webrtc.peerconnection.datachannel_created - Unknown scalar.
21:49:02.258 Ignoring unsupported entryTypes: layout-shift. _qx_M6PRv55lB49vTbI07wGFJKk.js:1:70616
21:49:02.258 Ignoring unsupported entryTypes: largest-contentful-paint. _qx_M6PRv55lB49vTbI07wGFJKk.js:1:71168
21:49:02.372 injected quickmenu background.js:583:13
21:49:02.401 Error: Please use $(ref:runtime.getURL). 4 i18n.js:26
21:49:02.485 XHRGEThttps://yandex.com/clck/jclck/rnd=1626313741631/yuid=6313361295512930762/reqid=1626313738410189-10535534316918000010-man1-8963-man-l7-balancer-8080-BAL10905-sas1-7946-IMG/serpid=YxonPC7pDU-1D820GxRxnA/dtype=iweb/path=8.228.629.1465.3223/vars=-items=im:macro photography of nature:20x13:488x389;im:berry pie:488x13:956x389;im:under the sea:955x13:1423x389;im:Altai:1423x13:1891x389;im:tropical island:20x389:488x765;im:jam:488x389:956x765;im:quilling cards:955x389:1423x765;im:Enceladus photos:1423x389:1891x765;im:convertibles:20x764:488x1140;im:kayaking:488x764:956x1140;im:caves around the world:955x764:1423x1140;im:Siberia landscape photos:1423x764:1891x1140;im:Kandinsky paintings:20x1140:488x1516;im:beach:488x1140:956x1516;im:amusement rides:955x1140:1423x1516;im:Sochi photos:1423x1140:1891x1516;im:cherry blossoms in Japan:20x1515:488x1891;im:paragliding:488x1515:956x1891;im:first flowers of spring:955x1515:1423x1891;im:hiking:1423x1515:1891x1891,-screen=1919x1110/table=imgs/cts=1626313741590/service=images.yandex/ui=images.yandex/*https://yandex.com/images/
[HTTP/2 200 OK 142ms]

21:49:02.498 XHRGEThttps://yandex.com/images/search?callback=jQuery214033913227234561805_1626313740173&format=json&request={"blocks":[{"block":"extra-content","params":{},"version":2},{"block":{"block":"i-react-ajax-adapter:ajax"},"params":{"type":"CbirCore","preventAjaxMethod":true},"version":2}],"metadata":{"bundles":{"lb":"jCgK5[yp2V?b*G$"},"assets":{"las":"justifier-height=1;thumb-underlay=1;justifier-setheight=1;fitimages-height=1;justifier-fitincuts=1;react-with-dom=1;124.0=1;628.0=1;548.0=1;789212.0=1;f192a3.0=1;6821bc.0=1"},"extraContent":{"names":["i-react-ajax-adapter"]}},"bmt":{"lb":"jCgK5[yp2V?b*G$"},"amt":{"las":"justifier-height=1;thumb-underlay=1;justifier-setheight=1;fitimages-height=1;justifier-fitincuts=1;react-with-dom=1;124.0=1;628.0=1;548.0=1;789212.0=1;f192a3.0=1;6821bc.0=1"}}&yu=6313361295512930762&rpt=imageview&_=1626313740174
[HTTP/2 200 OK 305ms]

21:49:02.573 XHRGEThttps://yandex.com/images/search?callback=jQuery214033913227234561805_1626313740175&format=json&request={"blocks":[{"block":"extra-content","params":{},"version":2},{"block":{"block":"i-react-ajax-adapter:ajax"},"params":{"type":"CbirPanel","preventAjaxMethod":true},"version":2}],"metadata":{"bundles":{"lb":"jCgK5[yp2V?b*G$"},"assets":{"las":"justifier-height=1;thumb-underlay=1;justifier-setheight=1;fitimages-height=1;justifier-fitincuts=1;react-with-dom=1;124.0=1;628.0=1;548.0=1;789212.0=1;f192a3.0=1;6821bc.0=1"},"extraContent":{"names":["i-react-ajax-adapter"]}},"bmt":{"lb":"jCgK5[yp2V?b*G$"},"amt":{"las":"justifier-height=1;thumb-underlay=1;justifier-setheight=1;fitimages-height=1;justifier-fitincuts=1;react-with-dom=1;124.0=1;628.0=1;548.0=1;789212.0=1;f192a3.0=1;6821bc.0=1"}}&yu=6313361295512930762&rpt=imageview&_=1626313740176
[HTTP/2 200 OK 301ms]

21:49:02.619 XHRGEThttps://mc.yandex.ru/watch/722889?wmode=7&page-url=https://yandex.com/images/&charset=utf-8&site-info={"query":{"page":"index"}}&ut=noindex&browser-info=pv:1:gdpr:13-0:vf:aldhbh95bymtbzyv:fp:919:fu:0:en:utf-8:la:en-CA:v:591:cn:1:dp:0:ls:1122819721396:hid:884577460:z:-240:i:20210714214901:et:1626313742:c:1:rn:659485481:rqn:2:u:16011602511069891132:w:1902x1110:s:1920x1200x24:sk:1:eu:0:ns:1626313738048:ds:0,0,323,34,,0,,2426,33,,,,3161:dsn:0,0,325,33,-4,0,,2585,33,,,,3162:rqnl:1:adb:2:pu:382671794716011602511069891132:zzlc:na:cc:5270851541626314000:fip:735ffa1bddba9c8173beba1c0dd8d281-a81f3b9bcdd80a361c14af38dc09b309-a81f3b9bcdd80a361c14af38dc09b309-4bd84c89c35a312599d807af285e7b5f-cb08a92dc2f0c35309fa27e543eee535-a3fa00e127f881df2924f73305812722-61b9878bbce18de73aafc8582a198c0c-4a5f468d3a1ac30627e6f77767f34b03-a81f3b9bcdd80a361c14af38dc09b309-c6d7b47b2dcff33f80cab17f3a360d0b-2facd2c41a0047c68391f933b930bc3a:afr:dbi8776_dwb5px9-aa8d84a44bd64e4598f6ef74d44ba183-a3fa00e127f881df2924f73305812722-375eba19_24-undefined-57c6a67f_3j8h47eg_2ge943db_30ah20h1-1920x1200x0-unspecified-:ti:2:st:1626313742:t:Yandex.Images: search for images online or search by image
[HTTP/2 200 OK 137ms]

21:49:02.767 Error: Please use $(ref:runtime.getURL). script.js:1
21:49:02.771 Error: Please use $(ref:runtime.getURL). script.js:1
21:49:02.852 POSThttps://yandex.com/clck/jclck/
[HTTP/2 200 OK 187ms]

21:49:03.056 XHRGEThttps://an.yandex.ru/system/context.js
[HTTP/2 200 OK 0ms]

21:49:03.411 Content Security Policy: Ignoring “'unsafe-inline'” within script-src or style-src: nonce-source or hash-source specified 4
21:49:03.637 Promise resolved after context unloaded
content-script.js:11
21:49:03.673 GEThttps://yastatic.net/s3/fiji-static/_/vendor-desktop.87dd0dfb7e205c8e7e7c.js
[HTTP/2 200 OK 146ms]

21:49:03.676 GEThttps://yastatic.net/s3/fiji-static/_/CbirCore@desktop.en.4323f7d6b71bbdab6d6a91d5379ac63e.js
[HTTP/2 200 OK 146ms]

21:49:03.679 GEThttps://yastatic.net/s3/fiji-static/_/vendor-desktop.87dd0dfb7e205c8e7e7c.css
[HTTP/2 200 OK 146ms]

21:49:03.682 XHRGEThttps://yandex.com/clck/jclck/rnd=1626313743275/yuid=6313361295512930762/reqid=1626313738410189-10535534316918000010-man1-8963-man-l7-balancer-8080-BAL10905-sas1-7946-IMG/serpid=YxonPC7pDU-1D820GxRxnA/dtype=iweb/path=8.228.1031.183.4049/table=imgs/cts=1626313743255/service=images.yandex/ui=images.yandex/*https://yandex.com/images/
[HTTP/2 200 OK 138ms]

21:49:03.687 GEThttps://yastatic.net/s3/fiji-static/_/CbirPanel@desktop.en.4515ddfbbf638d1aeb349610b03d5d5a.js
[HTTP/2 200 OK 142ms]

21:49:04.308 Error: Please use $(ref:runtime.getURL). background.js:31
21:49:04.405 GEThttps://yastatic.net/s3/fiji-static/_/vendor-desktop.87dd0dfb7e205c8e7e7c.js
[HTTP/2 200 OK 0ms]

21:49:04.591 GEThttps://yastatic.net/images-thumbs/_/8cS_MbHl6VBweqVjWeI-eNy0tzE.ico
[HTTP/2 200 OK 138ms]

21:49:04.988 POSThttps://yandex.com/clck/jclck/
[HTTP/2 200 OK 141ms]

21:49:04.990 POSThttps://yandex.com/clck/jclck/
[HTTP/2 200 OK 188ms]

21:49:06.465 XHRGEThttps://static-mon.yandex.net/static/optional.js?pid=yandex_images&script_key=10e596uqKrScC156GMDzHx0_0Yn_gCmVI&reasure=true
[HTTP/1.1 200 OK 188ms]

21:49:09.787 POSThttps://yandex.com/clck/jclck/
[HTTP/2 200 OK 189ms]

21:49:09.936 Error: Please use $(ref:runtime.getURL). i18n.js:26
21:49:17.129 POSThttps://yandex.com/clck/jclck/
[HTTP/2 200 OK 182ms]

21:49:17.770 Content Security Policy: Ignoring “'unsafe-inline'” within script-src or style-src: nonce-source or hash-source specified 3
21:49:17.913 XHROPTIONShttps://api.twitter.com/1.1/jot/client_event.json
[HTTP/2 200 OK 52ms]

21:49:18.020 XHRPOSThttps://api.twitter.com/1.1/jot/client_event.json
[HTTP/2 200 OK 72ms]

21:49:18.115 XHRPOSThttps://api.twitter.com/1.1/jot/client_event.json
[HTTP/1.1 200 OK 0ms]

21:49:43.098 Unchecked lastError value: Error: Promised response from onMessage listener went out of scope 2 common.js:4
21:49:43.100 Error: Promised response from onMessage listener went out of scope ExtensionMessagingService.js:89:34
21:50:03.280 Error: DOM node not found: div.cbir-panel_visibility_visible script.js:1:16484
21:50:03.284 Error: DOM node not found: div.cbir-panel_visibility_visible script.js:1:12730
dessant commented 3 years ago

Hi, thanks for the bug report! The issue should be fixed in version 3.6.5, though the update is still under review for Firefox. It may take some time before the update is published, because they have this banner on the submission page:

Attention extension developers: we are currently experiencing a higher than usual volume of submissions. Our team is working as quickly as possible to look at add-ons that have been selected for manual review. If your submission is selected, it may take 3 - 4 weeks for it to be reviewed. We expect the wait time to return to normal near the end of July. We apologize for the inconvenience.

alexolog commented 3 years ago

Can you post an unreviewed version somewhere for those of us running the developer or nightly versions that allow unsigned extensions?

Thank you!

dessant commented 3 years ago

Unsigned packages are automatically published for every release, you can download search_by_image-3.6.5-firefox.zip from the page below.

https://github.com/dessant/search-by-image/releases

alexolog commented 3 years ago

Works well, thank you!

alexolog commented 3 years ago

A short Python snippet that may be interesting: https://stackoverflow.com/a/62136342/181238

Could this approach simplify working with Yandex?

dessant commented 3 years ago

We upload to the private API in a similar way in some cases, but the UI is used whenever possible, to let the search engine display upload progress and any encountered errors.

alexolog commented 3 years ago

The problem with the use of the UI is that it sometimes breaks if the user navigates to another tab before the search finishes.

It may be a personal preference, but I much prefer the way search-by-image handles Google to the way it handles Yandex.