Opened 7 years ago

Closed 7 years ago

Last modified 7 years ago

#1626 closed improve feature (fixed)

searchoptimizer: change default results

Reported by: mahouni Owned by: mahouni
Priority: major Milestone: 0.7
Component: BW Search Keywords: search members profile picture
Cc:

Description

This is a ticket to change the default search parameters: A search will return

  • only people who can host and have a profile picture
  • people who last logged in will be first

At the moment the default parameters are : active (logged in at least once in the last 3-4 years), no matter if there is a profile picture and if the person can host or not. Default sort order is newest member first. The current default search results can still be found with the advanced search settings.

related bw forum discussion: http://www.bewelcome.org/forums/s2289-Empty_profiles_are_useless

Attachments (1)

1626_searchoptimizer.patch (5.8 KB) - added by mahouni 7 years ago.

Download all attachments as: .zip

Change History (25)

comment:1 Changed 7 years ago by mahouni

  • Status changed from new to assigned

comment:2 Changed 7 years ago by mahouni

Code review and testing needed: see attached patch

Last edited 7 years ago by mahouni (previous) (diff)

comment:3 follow-up: Changed 7 years ago by crumbking

I would add the "maybe" people, too. On some places it seems otherwise quite empty ;-)

comment:4 in reply to: ↑ 3 Changed 7 years ago by mahouni

Replying to crumbking:

I would add the "maybe" people, too. On some places it seems otherwise quite empty ;-)

Hmm, I think we already have a nice coverage of cities with at least one host with status "yes, bewelcome". I would suggest to return only the "yes" when doing a simple location or map search. But I would set "yes" and "maybe" as checked by default for the advanced search. I will need to check the difference between the two search options.

Changed 7 years ago by mahouni

comment:5 Changed 7 years ago by planetcruiser

@mahouni: 0.7 will roughly be released in 2-3 weeks. if you think you can solve this ticket until then, please assign it to milestone 0.7 and commit to develop.

patch feedback:

  • no short tags please - i just updated ProgrammingGuideline with a note about it
  • no ternary operators if any way possible
  • especially no combination of the both above ;)

and i agree, let's see how your suggested defaults feel in practice and fine-tune later, also depending on user feedback

comment:6 Changed 7 years ago by mahouni

  • Milestone changed from unassigned to 0.7
<?=$key=='LastLogin' ? 'selected="selected"' : ''; ?>

Ha! and i was so proud when i eventually have understood what something like this would do! I wanted to use it too, of course :)

Thanks, for the tips. I will try to write code according to the ProgrammingGuide?. Will try to do some cleaning up too, but I fear to mess up and better don't touch more than necessary.

I pushed the branch to develop. (At the moment only the yes-men are in the result list). It works locally, let's see if it works on alpha too.. please test it and give feedback here or in the testing group.

comment:7 Changed 7 years ago by crumbking

I tested locally and seems to work as described.... let's move to alpha to check with bigger user base...

comment:8 Changed 7 years ago by planetcruiser

looking good. :) i just deployed it to alpha. will test thoroughly tomorrow

comment:9 follow-up: Changed 7 years ago by crumbking

Somehow I feel that now we hide lot's of potential hosts. In smaller it seems there is nobody. "No members found." A new user or not so "technical" users will stop here... Nobody will hit the advance search.

A solution could be to show results like this:

(yes/picture/sort last login)+(maybe/picture/sort last login)+(yes/no picture/sort last login)+(maybe/no picture/sort last login)

comment:10 in reply to: ↑ 9 ; follow-up: Changed 7 years ago by mahouni

Replying to crumbking:

A solution could be to show results like this:

(yes/picture/sort last login)+(maybe/picture/sort last login)+(yes/no picture/sort last login)+(maybe/no picture/sort last login)


That would be an ideal solution. Maybe it could be implemented with a second "order by" column. I'll try to work on that...

BTW: There are people without a profile picture, but probably with an entry in the membersphoto table. maybe they deleted the profile picture? Though it seems that all of them have signed up before 2008/2009 and it could be just some relict from older version of the BW software?

comment:11 Changed 7 years ago by mahouni

paaah, very embarassing. membersphotos.IdMember? would be the column we need, not membersphotos.id, of course... !! and IdMember? is not unique.. grrr, I will have a look at it again

comment:12 follow-up: Changed 7 years ago by mahouni

I skipped the membersphoto thing.

Now it just has a different search order: first custom (default accomodation), second accomodation, third LastLogin?. It should return quite useful results.

I think most people without a profile picture have their profile summary empty too. therefore I would suggest to return the results of the following SQL statement:

SELECT m.id,m.Username,m.Accomodation, m.LastLogin, m.ProfileSummary, [[BR]]
IF(m.ProfileSummary != 0, 1, 0) as summary FROM members m where m.Accomodation != 0 [[BR]]
ORDER BY summary DESC, m.Accomodation ASC,  m.LastLogin DESC  ;

However this would probably slow down performance. Maybe someone can check the time difference to the statement without the ProfileSummary? look up. (It is about 0.024 to 0.0009 on test db)

SELECT m.id,m.Username,m.Accomodation, m.LastLogin, m.ProfileSummary [[BR]]
FROM members m where m.Accomodation != 0 [[BR]]
ORDER BY m.Accomodation ASC,  m.LastLogin DESC  ;

comment:13 Changed 7 years ago by crumbking

While testing locally your changes I came up with the idea to replace the " X/0 members found." with:

not logged in:

0 members found. Try it with the [map search].
0 public members found. [Log in] to see X non public members. Or try it with the [map search].
X public members found. [Log in] to see additional X non public members. Or try it with the [map search].

logged in:
0 members found. Try it with the [map search]
X members found. Try it with the [map search], too!

With this information we help the user to find profiles around some places. (map search) And we attract potential users to signup! As the search is somehow buggy (try "Leipzig" you get no results but if you hit the map search button afterwards you get the members) Probably this should go to another ticket?!

comment:14 in reply to: ↑ 12 ; follow-up: Changed 7 years ago by planetcruiser

Replying to mahouni:

However this would probably slow down performance. Maybe someone can check the time difference to the statement without the ProfileSummary? look up. (It is about 0.024 to 0.0009 on test db)

i tested around a little and all queries (with or without the IF statement) took about 0.045 sec on the live db at first run and then 0.0001 once they were in mysql cache. so no worries there.

i deployed your latest commits to alpha. looks good to me. if crumbking likes it too, we can close this ticket.

@crumbking: yes, the message text change should go to a new ticket. could you create it?

comment:15 in reply to: ↑ 10 ; follow-up: Changed 7 years ago by planetcruiser

Replying to mahouni:

BTW: There are people without a profile picture, but probably with an entry in the membersphoto table. maybe they deleted the profile picture? Though it seems that all of them have signed up before 2008/2009 and it could be just some relict from older version of the BW software?

yes, most likely this is due to some old bug. could you write a ticket for that and suggest a solution?

comment:16 in reply to: ↑ 15 Changed 7 years ago by mahouni

Replying to planetcruiser:

Replying to mahouni:

BTW: There are people without a profile picture, but probably with an entry in the membersphoto table. maybe they deleted the profile picture? Though it seems that all of them have signed up before 2008/2009 and it could be just some relict from older version of the BW software?

yes, most likely this is due to some old bug. could you write a ticket for that and suggest a solution?

I think that was really because of the programming error. And even if it is true and there are such records in membersphotos, I guess it wouldn't cause a problem.

comment:17 in reply to: ↑ 14 Changed 7 years ago by mahouni

Replying to planetcruiser:

i deployed your latest commits to alpha. looks good to me. if crumbking likes it too, we can close this ticket.

Great, thanks!

@crumbking: yes, the message text change should go to a new ticket. could you create it?

done, see tickets 1630 and 1631

comment:18 Changed 7 years ago by crumbking

  • Resolution set to fixed
  • Status changed from assigned to closed

Looks good to me too. Tested with a couple of cities..

Thanks for opening the tickets!

Close this one...

comment:19 follow-up: Changed 7 years ago by mahouni

  • Resolution fixed deleted
  • Status changed from closed to reopened

Is it only my problem or is mapsearch broken on the current develop branch?

I am not sure and I can't explain why exactly,but I assume commit f15e7fd might cause that issue: https://gitorious.org/bewelcome/rox/commit/f15e7fdcd189755cab2176af1657ed51f5de8015

Merge branch 'develop' of gitorious.org:bewelcome/rox into develop

comment:20 Changed 7 years ago by mahouni

sorry, wasn't that one. It is probably the refractoring of script loading and BWRox namespace that breaks it ?

git checkout cea16b69673a97972c4635f734a0999b86aab4e8

-> mapsearch works

but then

git checkout b1e65ec0ce4a41816fa14f7897d317490fc334c4

-> mapsearch broken

comment:21 in reply to: ↑ 19 Changed 7 years ago by planetcruiser

Replying to mahouni:

Is it only my problem or is mapsearch broken on the current develop branch?

confirmed, also broken on alpha. argh. will look into it.

comment:22 Changed 7 years ago by planetcruiser

fixed via https://gitorious.org/bewelcome/rox/commit/feed76c498968ab9985250d0457e11496b9c25cf

deployed and tested on alpha.

i tripped over this exception in the old main.js code:

if (req.indexOf('searchmembers') != -1) {
	document.write('<script type="text/javascript" src="script/prototip.js"></script>');
    if (req.indexOf('searchmembers/quicksearch') == -1)
        document.write('<script type="text/javascript" src="script/labeled_marker.js"></script>');
}

i assumed it was a "!=" as everywhere else. ;) so much for the readability of the old main.js code (see #1633)..

comment:23 Changed 7 years ago by planetcruiser

  • Resolution set to fixed
  • Status changed from reopened to closed

comment:24 Changed 7 years ago by mahouni

He he, thanks for the quick fix ;)

if BWRox != -1 {
BWRox!
}
Note: See TracTickets for help on using tickets.