this post was submitted on 07 Jun 2025
32 points (94.4% liked)

hexbear

10428 readers
53 users here now

Hexbear Proposals chapo.chat matrix room.

This will be a place for site proposals and discussion before implementation on the site.
Every proposal will also be mirrored into a pinned post on the hexbear community.

Any other ideas for helping to integrate the two spaces are welcome to be commented here or messaged to me directly.

Within Hexbear Proposals you can see the history of all site proposals and react to them, indicating a vote for or against a proposal.

Sending messages will be restricted to verified and active hexbear accounts older than 1 month with their matrix id in their hexbear user profile.

All top level messages within the channel must be a Proposals (idea for changing the site), Feedback (regarding non-technical aspects of the site, for technical please use https://hexbear.net/c/feedback), or Appeals (regarding admin/moderator actions).

Discussion regarding these will be within nested threads under the post.

To gain matrix verification, all you need to do is navigate to my hexbear userprofile and click the send a secure private message including your hexbear username.

founded 4 years ago
MODERATORS
 

Whenever I've used the search function, it returns almost nothing relevant to what I'm looking for, and the time constraints don't work. If I look for things using the "top (time)" feature, I always get results outside of the desired time period. Why does this happen, is a fix in progress, and how hard would it be to implement?

top 18 comments
sorted by: hot top controversial new old
[–] [email protected] 6 points 21 hours ago (1 children)

I am just a user, but I'll say my workaround has been to sort by new. The things that come up are usually the things I'm looking for and they're sorted chronologically.

[–] [email protected] 7 points 20 hours ago (1 children)

chomsky-yes-honey object permanence is the super power that turns you into a socialist, so I usually am looking for stuff from like 3 years ago and this tactic does not work.

[–] [email protected] 1 points 20 hours ago

like

Okay it's more of a pain in the ass, but the move I do in that case is search, sort by new, hit next and then the url has a numeral in it for what page of results you're on. Manually set that to a higher number to skip through a bunch of results pages.

It requires some playing around because I'm not aware of a way to find out the total number of pages, but you can usually find what you need with trial and error.

[–] [email protected] 4 points 21 hours ago

sorry i ate a lot of beans and then farted in the server room and now the search function can't pick its way through all the methane i released into the air

[–] [email protected] 3 points 22 hours ago

While we're on the topic, when I look at peoples' post histories, the 'time period' function simply doesn't work. I look at "past month" and it'll show me random posts from years ago.

[–] [email protected] 4 points 22 hours ago

Because why would you want to search for anything useful when you can just look at all my terrible no good posts

[–] [email protected] 7 points 23 hours ago

Because of woke...

For real though, I don't know

[–] [email protected] 3 points 23 hours ago

Sort by new just like you should be doing for everything else on Hexbear and it's pretty useful

[–] [email protected] 13 points 1 day ago (1 children)

idk how true this is but I once saw a post saying the search function is basically a database query that replaces spaces with wildcards

[–] [email protected] 11 points 1 day ago (1 children)

Correct

Line 288:

pub fn fuzzy_search(q: &str) -> String {
  let replaced = q
    .replace('\\', "\\\\")
    .replace('%', "\\%")
    .replace('_', "\\_")
    .replace(' ', "%");
  format!("%{replaced}%")
}
[–] [email protected] 6 points 22 hours ago

You can link directly to a line, or even multiple. Clicking on the line number highlights it, shift+clicking on another highlights all in between the two selected.

[–] [email protected] 10 points 1 day ago

I kept searching for "My Little Pony" in users' posts who said Star Wars was for babies and the mods had to ruin search to prevent this from continuing to occur on a regular basis.

[–] [email protected] 10 points 1 day ago* (last edited 1 day ago) (3 children)

The search is simple. As far as I can tell FunkyStuff is wrong in regards to "the words can be in a completely different order", no it has to be in order. But two things:

  1. The words can be surrounded by any number of letters, so long as the word itself is found it is satisfied. So searching for "un", " unoriginal" will satisfy it.
  2. While the words have to be in order, there can be any number of words in between. So searching for "the things", the first paragraph of this comment would satisfy that search. As you can see, "the" is the very first word, and "things" is the very last word in that paragraph.
[–] [email protected] 2 points 11 hours ago

That's very silly

[–] [email protected] 5 points 21 hours ago (1 children)

I'll add that doing search well is a lot of work; just about anything you would do to "improve" it will introduce some drawback as well. I'm sure the lemmy devs just haven't had the time or inclination to focus on it past the basic functionality.

[–] [email protected] 1 points 11 hours ago

Yeah, I doubt I could put in a meaningful PR for search itself, but maybe the chronological filter bug might be easier to tackle.

[–] [email protected] 5 points 1 day ago

Oops, yeah I mixed up order vs being contiguous.

[–] [email protected] 4 points 1 day ago* (last edited 1 day ago)

AFAIK the reason for getting irrelevant results is that the search function doesn't have a way to figure out which posts are closer to what you searched and which ones just happen to have the words but in a completely different order. That's why it sorts by points instead of sorting by relevance.

The time filter thing is just broken across the board, though. You can see it in profiles too.

edit: As Edie pointed out, the search does need the words to be in order. It's actually just replacing spaces with wildcards.