badges-assets/retired_rules/pagure-long-life-50.yml
Otto Urpelainen 66c199817a Retire Long Life to Pagure badges
These badges do not work as they should for the following reasons:

1. If the message contains commits from multiple authors, commits count
   per author is not available.
2. Even if commit count per author was available, there is no way to
   evaluate the criteria separately for each author.
3. Rebasing in forks leads to the same commits being counted more than
   once, without the badge recipient actually doing anything themself.

Item 1 could be solved by simple extension of schema so that Pagure
would include the count per author. If it was the only problem, there
would be no need to retire these rules.

Item 2 has the worst effect by far. It has lead to many users having the
highest level badge only because they happened to appear as an author in
a message that also included a prominent committed. Fixing it would
require extension of the rules language in fedbadges backend. It is
unclear how difficult that would be.

Item 3 would require more changes to messages emitted by Pagure. A way
to distinguish between original work and it being reapplied by others
would be needed. Perhaps comparing 'agent' and 'author' would work. But
it is unclear if fedbadges backend allows such expressions.

All in all, the rules for Pagure badges are specified in a way that is
difficult to implement correctly. Since currently badges are awarded to
users that have not earned them and nobody seems to be willing to put
effort to fix the situation, it is the best to simply retire the rules.
2021-03-23 22:19:59 +02:00

40 lines
1.3 KiB
YAML

%YAML 1.2
---
# Retired due to the following issues:
# 1. If the message contains commits from multiple authors, commits count per
# author is not available.
# 2. Even if commit count per author was available, there is no way to evaluate
# criteria separately for each author.
# 3. Synchronizing forks leads to the same commits being counted more than once.
# This is some metadata about the badge
name: Long Life to Pagure (Pagure III)
description: Pushed 50 commits to a Pagure repository.
creator: robyduck
# This is a link to the discussion about adopting this as a for-real badge.
discussion: https://pagure.io/design/issue/434
# A link to the image for the badge
image_url: https://badges.fedoraproject.org/pngs/pagure-long-life-50.png
# That's us!
issuer_id: fedora-project
# We'll perform our more costly check (defined below) only when
# we receive messages that match this 'trigger'
trigger:
topic: pagure.git.receive
# Once the check has been triggered, this defines what we actually check.
criteria:
datanommer:
filter:
topics:
- "%(topic)s" # The topic of the message that triggered us.
users:
- "%(msg.authors)s"
operation: count
condition:
greater than or equal to: 50
recipient: "%(msg.authors)s"