Fivefold/linkding-injector

Several URL parameters in GET query break search parameter detection

Closed this issue · 10 comments

The injector works fine with Google, but no longer works with DuckDuckGo. :-(

Running latest Linkding and extension version 1.3.1

And continued gratitude for this extension, I love it and tell everyone about how great it is.

Actually it's a bit weirder than that. It's partially working.

If you got to: https://duckduckgo.com/ and search, the injector doesn't work.

But once you are on the results page, if you search again, it works as expected.

Hey @adamshand, happy to hear you are still using the extension.

I recently was made aware that DDG support was broken in 1.3.0 (in #15 and #16) and it should be fixed with 1.3.1 (which went online two days ago. Is this when your problems started?)

Unfortunately I can't reproduce your behaviour.

If you got to: https://duckduckgo.com/ and search, the injector doesn't work.

This works for me, so I will have to ask you to help me troubleshoot this a bit.

Try this:

  1. In your browser, go to https://duckduckgo.com/
  2. Open the Web Developer Tools by pressing F12 and go to the 'Console' Tab.
  3. Search for a term that actually delivers results on your linkding instance
  4. Look for any errors (shown in red) in the console by searchInjection.js (look to the right side)
  5. If you find one, right-click on the error, choose 'Copy message' and paste it here

An error would look like this (but can be any text):

21:48:24.010 TypeError: d is null searchInjection.js:182:15

Apologies, after some more experimenting it appears that this is caused by the Chrome extension Adguard.

Bit of a weird one, but disabling Adguard definitely fixes the problem, so I'll close this ticket.

Thanks for your help. :-)

Glad to hear you found a fix so quickly!

Since Adguard is a popular extension I would appreciate if you could post here if you find a solution to how to use the injector extension together with Adguard just in case someone else has this problem.

Will figure it out and post here when I figure it out.

Can you assign the ticket to me so I remember?

Okay on further investigation it doesn't appear that Adguard is the problem.

If you go to duckduckgo.com using Brave and search, DDG adds hps=1 to the URL and injector seems unable to show search results.

Hopefully the below URL doesn't work for you?

https://duckduckgo.com/?hps=1&q=dogs&ia=web

If you remove the "hps=1" from the URL, injector to works as expected.

The error message in browser console is:

linkding injector: no message and no search results
(anonymous) @ searchInjection.js:1

Thank you @adamshand for troubleshooting this further, I now know what the issue was. It should be fixed now in the new v1.3.2 (you can check it out immediately with Firefox, Chrome-based browsers will update a bit later).

In case it's not fixed, do reopen though of course!

@Fivefold Sorry to necro this issue but i noticed that in version 1.3.4 with duckduckgo the injector is not working.

imagem

linkding injector: no message and no search results searchInjection.js:150:12 <anónimo> searchInjection.js:150

I did try with google and it works as expected.

I just tested and 1.3.4 seems to be working fine for me on DDG?

image

@GulyFMG I don't mind the necro, but if duckduckgo support actually broke it should be tracked in a separate issue. Please continue the discussion in #25