Coder Social home page Coder Social logo

google / triage-party Goto Github PK

View Code? Open in Web Editor NEW
496.0 14.0 80.0 15.04 MB

๐ŸŽ‰ Triage Party: massively multi-player GitHub triage ๐ŸŽ‰

License: Apache License 2.0

Dockerfile 1.43% Go 93.13% CSS 3.50% Shell 1.94%
github triage golang dashboard

triage-party's Introduction

Triage Party: massively multi-player GitHub triage ๐ŸŽ‰

NOTE: This is not an officially supported Google product

Triage Party is a stateless web app to optimize issue and PR triage for large open-source projects using the GitHub API.

screenshot

Triage Party focuses on reducing response latency for incoming GitHub issues and PR's, and ensure that conversations are not lost in the ether. It was built from the Google Container DevEx team's experience contributing to popular open-source projects, such as minikube, Skaffold, and Kaniko.

Triage Party is configured via YAML, and designed for projects to self-host on anything from a Raspberry Pi, Google Cloud Run, or Kubernetes.

Table of Contents

Novel Features

  • Multiplayer mode: Up to 20 simultaneous players in group triage
  • Conversation direction tracking and filtering
  • Query across GitHub projects or repositories
  • Duplicate issue detection
  • Filters that are not possible on GitHub:
    • Follow-up latency by project members (responded: +15d)
    • Reactions (reactions: >=5)
    • Comment popularity (comments-per-month: >0.9)
  • Code review state-tracking (v1.2.0+)
  • Kanban dashboard (v1.2.0+)
  • Easily open groups of issues into browser tabs
  • YAML configuration for all pages, rules, and filters
  • GitHub Enterprise support (via --github-api-url cli flag)
  • Low latency (yet able to pull live data)

Triage Party in production

See these fine examples in the wild:

Requirements

Try it

Store a GitHub token some place on disk:

echo YOUR_GENERATED_TOKEN > $HOME/.github-token

Run:

go run cmd/server/main.go \
  --github-token-file=$HOME/.github-token \
  --config config/examples/kubernetes.yaml \
  --repos kubernetes/sig-release

If you do not have Go installed, you can run Triage Party using Docker:

export GITHUB_TOKEN="$(cat $HOME/.github-token)"
docker build --tag=tp .
docker run \
  --rm \
  -e GITHUB_TOKEN \
  -v "$PWD/config/examples/kubernetes.yaml:/app/config/config.yaml" \
  -p 8080:8080 tp

You can also use Personal Access Token from the GitHub CLI to run the application:

export GITHUB_TOKEN=$(grep oauth_token ~/.config/gh/hosts.yml| cut -d ":" -f 2 | sed "s/ //g")
docker build --tag=tp .
docker run \
  --rm \
  -e GITHUB_TOKEN \
  -v "$PWD/config/examples/kubernetes.yaml:/app/config/config.yaml" \
  -p 8080:8080 \
  tp

You'll see logs emitted as Triage Party pulls content from GitHub. The first time a new repository is used, it will require some time (~45s in this case) to download the necessary data before minikube will render pages. Your new Triage Party site is now available at http://localhost:8080/, but will initially block page loads until the required content has been downloaded. After the first run, pages are rendered from memory within ~5ms.

Usage Tips

Triage Party can be configured to accept any triage workflow you can imagine. Here are some tips:

box-with-arrow screenshot

  • Use the blue box-with-arrow icon to open issues/pull requests into a new tab
    • If nothing happens when clicked, your browser may be blocking pop-ups
    • The notification to allow-popups for Triage Party may be hidden in the URL bar.
  • Rules work best when there is a documented resolution to remove it from the list
  • Pages work best if the process is defined so that the page is empty when triage is complete
  • If an non-actionable issue is shown as part of a daily or weekly triage, step back to tune your rules and/or define an appropriate resolution.

Multi-player mode

multi-player mode

Use the drop-down labelled Solo on the top-right of any page to enable multi-player mode. In multi-player mode, the number of issues are split among the number of players you have configured. Since Triage Party is state-less, players are assigned via the remainder of the issue or PR divided by the total number of players. Here is a workflow that we have seen work well for triage parties:

  1. Wait for attendees to show up
  2. The meeting host selects the appropriate number of players, and shares the resulting Triage Party URL
  3. If someone is showing up later, we may leave a slot open and re-shard later if they do not appear
  4. The meeting host assigns each attendee a player number
  5. Players move section by section, using the "open items in new tabs" feature to quickly work through issues
  6. When a player does not have the context necessary to resolve an item, they present their screen and discuss it with the other players
  7. When a player leaves, the meeting host "re-shards", and all players select the updated player count in the drop-down

NOTE: Multi-player works best if the "Resolution" field of each rule has a clear action to resolve the item and remove it from the list.

Kanban mode (NEW)

kanban mode

In v1.2.0, pages can now be displayed as a Kanban dashboard. The columns are based on the rule the issue was found in, and the rows are swim-lanes based on the assignee. To see a real-world example:

Best practices for designing a useful Kanban dashboard:

  • Rules should be designed and ordered in a way that represents progress: Not started -> Started -> Under Review -> Completed
  • Rules work best when they are mutually excusive (no issue matches multiple rules)
  • If a collection should be displayed in Kanban form by default, specify display: kanban in its configuration.
  • For velocity measurements and time estimate support, create a rule named __velocity__ containing recently closed issues to include. See the example configuration.

Data freshness

age screenshot

With the default Dockerfile, Triage Party refreshes data at least every 8 minutes, settable using the --max-refresh flag. Triage Party will give popular pages a higher refresh rate, up to every 30 seconds by default (settable using --min-refresh flag). This default is conservative, allowing Triage Party to work with repositories containing 10,000 open issues without hitting GitHub API limits.

Live data can be requested at any time by using forcing a refresh in their browser, typically by holding the Shift button as you reload the page. See forced refresh for your browser.

You can see how fresh a pages data is by mousing-over the "unique items" text in the top-center of the page.

Documentation

Thirsting for more? See:

triage-party's People

Contributors

aj185259 avatar balopat avatar briandealwis avatar dependabot[bot] avatar disktnk avatar eddiezane avatar everpeace avatar geekgonecrazy avatar goern avatar gsquared94 avatar joeyparrish avatar johntitor avatar joshhunt avatar kalafut avatar kensipe avatar knqyf263 avatar masihtehrani avatar medyagh avatar munnerz avatar mushuee avatar plumpy avatar rcheesley avatar sourcefrog avatar spowelljr avatar swayne275 avatar tejal29 avatar tstromberg avatar vavilen84 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

triage-party's Issues

Documentation: clarify token file

Hi there,

Looking to try this out with the Mautic community, however I fell at the first hurdle.

Can you explain how to set up a token file or point me at the appropriate documentation which explains how to create it? I am very familiar with creating the tokens, but have not seen that used in this way before, and could not find anything online.

Implement basic leaderboards

This is to allow users to define leaderboards to incentivize positive behavior, such as:

  • of issues commented on

  • of issues closed without follow-up comment

  • of PR's merged

CloudSQL: Add Postgres support (fails with "driver: bad connection")

I've deployed an instance of triage-party to CloudRun without a persistent backend, and that worked fine.

Then, I deployed a Cloud SQL instance (postgres) and created a user and database. Then, based on minikube-deploy.sh example, I tried to deploy a new revision with CloudSQL by setting the environment variables PERSIST_BACKEND and PERSIST_PATH and that failed.

F0511 19:55:08.934229 1 main.go:94] unable to create persistence layer: new from cloudsql: USER:PASSWORD@tcp(PROJECT/us-central1/jx-teaparty)/tp: driver: bad connection

Advice/tips appreciated.

Add ability to hardcode repo org members

Basically requesting a workaround for the org-permissions issue (referenced here: #105) - If I can't get the permission, I'd still like the ability to filter out repo maintainers from outside contributors.

Add support for GitLab

It would be great if the triage-party can also be used with other systems like gitlab, to get an overview of multiple repos and systems to get a better cross platform overview.
I am aware, that this is not a small feature, but it would be an awesome improvement for bigger communities or companies, who need to use multiple services.

Would love to know your opinion about it. No hard feelings, if the request is just closed ;)

Decrease unnecessary updates for popular collections

With the most recent changes, the updater will keep polling github during idleDuration (5 minutes):

if resultAge > u.minRefreshAge && lastRequestAge < u.idleDuration {

So, a single request could spawn 60 loops to GitHub if minRefresh is set to 15 seconds.

Instead, we poll only as often as the popularity requires. Something like:

if resultAge > max(minRefresh, lastRequest) {
  return true
}

similarity detection: filter unimportant words out

We can get a higher hit-rate for similarity if we filter out a basic list of words which don't impact the nature of an issue or PR:

There are certain adjectives and prepositions that come to mind:

a
about
an
and
are
be
by
can
completely
does
extremely
for
has
have
how
in
is
maybe
of
on
or
should
some
something
still
than
the
then
to
use
very
via
when
why
with

However: we need to be careful not to skew things so badly that the min-similarity index is no longer helpful.

Closed PR's: timeline pull happens too often

Example:

I0617 11:16:34.275803   75669 timeline.go:36] cache miss for kubernetes-minikube-5452-timeline newer than 2020-06-17 11:15:29.210782 -0700 PDT m=+12.177519167
I0617 11:16:35.043964   75669 timeline.go:36] cache miss for kubernetes-minikube-6873-timeline newer than 2020-06-17 11:15:29.210782 -0700 PDT m=+12.177519167
I0617 11:16:35.792263   75669 timeline.go:36] cache miss for kubernetes-minikube-4752-timeline newer than 2020-06-17 11:15:29.210782 -0700 PDT m=+12.177519167
I0617 11:16:36.529062   75669 timeline.go:36] cache miss for kubernetes-minikube-8214-timeline newer than 2020-06-17 11:15:29.210782 -0700 PDT m=+12.177519167
I0617 11:16:37.244689   75669 timeline.go:36] cache miss for kubernetes-minikube-4805-timeline newer than 2020-06-17 11:15:29.210782 -0700 PDT m=+12.177519167
I0617 11:16:38.068430   75669 timeline.go:36] cache miss for kubernetes-minikube-7131-timeline newer than 2020-06-17 11:15:29.210782 -0700 PDT m=+12.177519167
I0617 11:16:38.541926   75669 timeline.go:36] cache miss for kubernetes-minikube-5188-timeline newer than 2020-06-17 11:15:29.210782 -0700 PDT m=+12.177519167

Periodically save state to initcache

At the moment, Triage Party only writes to the initcache at startup.

For larger repositories, it would be nice to have a periodic checkpoint to disk.

Support repo dependent rules

Hi, I would like to manage multiple repos in a single triage-party instance. Fortunately, triage party already support it:

settings:
...
  repos:
    - https://github.com/org1/repo1
    - https://github.com/org2/repo2

However, if I understood correctly, the current configuration scheme doesn't support repo dependent rules. For example, each repository has different SLOs.

Of course, we can prepare separate triage-party instances, But I would like to have only one triage-party site for efficiency (it would be easier for us to access one triage-party instance to perform triage for target multiple repos).

Perhaps, we can implement repo filter that accepts regex ([!]regex). Then user can define repo dependent rules like below:

p0-followup-overdue-repo1:
...
    filters:
      - repo: "org1/repo1"
      - label: "priority/p0"
      - tag: recv
      - responded: +3d
p0-followup-overdue-repo2:
...
    filters:
      - repo: "org2/repo2"
      - label: "priority/p0"
      - tag: recv
      - responded: +7d

FR: shard issues/PR's by label in multi-player mode

let say we have two users
one is windows expert
the other one is docker-driver expert

and we play triage party, we should be able to choose triage by "kind/docker" or "kind/hyperv" , "kind/multinode"

that we can users can play based on their expertise rather than get random set of issues.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.