2

A Bang I added for scoop.sh to the official Bang repository exhibits unusual behavior when used without a search term. Unlike other Bangs, it appends the search variable {{{s}}} into the URL and adds an unnecessary question mark before the hashtag.

A while ago I added a Bang for scoop.sh to the official Bang repository:

  {
    "s": "Scoop",
    "d": "scoop.sh",
    "t": "scoop",
    "u": "https://scoop.sh/#/apps?q={{{s}}}",
    "c": "Tech",
    "sc": "Downloads (software)"
  },

Actual Behaviour

Searching without a term:

  • Query: !scoop
  • Actual redirect: https://scoop.sh/?#/apps?q={{{s}}}
  • The string {{{s}}} remains in the URL, and an extra question mark is added before the hashtag, which differs from the behavior of other Bangs.

Other Bangs (e.g., !github, !youtube) simply redirect to their base domain when no search term is provided.

Expected Behaviour

Searching with a term:

  • Query: !scoop test
  • Expected redirect: https://scoop.sh/#/apps?q=test (works as expected)

Searching without a term:

  • Query: !scoop
  • Expected redirect: https://scoop.sh/ (base domain, without search terms).

    I'm actually not able to reproduce it, for me !scoop is redirecting to https://scoop.sh (without fragment). Do you have this set as a custom bang for yourself?

      nobodywasishere I used to have !scoop as a custom bang, but I removed it after the bang was added to the repository (maybe the bang has been removed from the UI but is still active?). These are my custom bangs:

      This problem has been happening to me for the past few months. I can reproduce it consistently. I can't remember if it was always like this.

        maybe the bang has been removed from the UI but is still active?

        It seems like this is exactly the case! Trying to add a new custom bang named "Scoop" does not work for me. After trying to save the following bang it does not show up in the list:

        Saving a custom bang with a different name, e.g. "Scoop Test", works fine for me. Is it possible for me to give this issue a new title?

          We've made some improvements and bug fixes to bangs on the backend that should fix this issue next release. Thank you for catching this!

          No one is typing