Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement maintainer search #685

Closed
wants to merge 1 commit into from
Closed

Conversation

Ma27
Copy link
Member

@Ma27 Ma27 commented Nov 2, 2019

As proposed during the release managers' talk on last NixCon, Hydra
should provide a feature to search for maintainers. I wanted to have
something like this for a long time as well and decided to give it a
try.

This change adds a second search field to the jobset-eval view that can
be used to search for maintainer's github names. Please note that I
intentionally didn't merge this together with the Search by name-form
since this form is only used to compare the builds against another eval.

By default Hydra now searches for github handles of maintainers (IMHO this
is more convenient than email addresses), however emails are
used fallbacks as the github handle isn't mandatory for a package
maintainer. The new values are stored in the Builds table at the new
column maintainers_github.

As proposed during the release managers' talk on last NixCon, Hydra
should provide a feature to search for maintainers. I wanted to have
something like this for a long time as well and decided to give it a
try.

This change adds a second search field to the jobset-eval view that can
be used to search for maintainer's github names. Please note that I
intentionally didn't merge this together with the `Search by name`-form
since this form is only used to compare the builds against another eval.

By default Hydra now searches for github handles of maintainers (IMHO this
is more convenient than email addresses), however emails are
used fallbacks as the github handle isn't mandatory for a package
maintainer. The new values are stored in the `Builds` table at the new
column `maintainers_github`.
Copy link
Member Author

@Ma27 Ma27 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@edolstra @grahamc would you mind taking a look at this? :)

@@ -33,6 +33,9 @@ sub view_GET {
$c->stash->{filter} = $c->request->params->{filter} // "";
my $filter = $c->stash->{filter} eq "" ? {} : { job => { ilike => "%" . $c->stash->{filter} . "%" } };

$c->stash->{maintainers} = $c->request->params->{maintainers} // "";
$filter->{maintainers_github} = { ilike => "%" . $c->stash->{maintainers} . "%" };
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure, but can this be part of the filter functionality as well?

@@ -37,6 +37,11 @@ c.uri_for(c.controller('JobsetEval').action_for('view'),
<input name="full" type="hidden" [% HTML.attributes(value => full) %]/>
</form>

<form class="form-search">
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Those form-fields should be inlined, the current state is just a POC :)

@Ma27 Ma27 marked this pull request as draft April 18, 2020 22:28
@Ma27
Copy link
Member Author

Ma27 commented Apr 18, 2020

Just converted this to a draft for now for the following reasons:

  • I'd like to display maintainer's email and/or github handle (or both if possible). This may cause some changes in the DB schema.
  • The two form-fields for searches should be unified (which requires some changes in the filter logic)
  • When rebasing this onto the current master, the eval-list rendering doesn't seem to work which must be fixed before this is somehow mergable.

@Ma27
Copy link
Member Author

Ma27 commented Apr 27, 2020

Continued in #743

@Ma27 Ma27 closed this Apr 27, 2020
@Ma27 Ma27 deleted the maintainer-search branch April 27, 2020 21:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant