Phabricator/Robots

From mediawiki.org
This page is a translated version of the page Phabricator/Bots and the translation is 76% complete.

Les robots Phabricator sont des utilisateurs de Phabricator pour lesquels les actions sont automatisées ou résultent d'actions de plusieurs utilisateurs. Voir la documentation upstream pour plus d'informations.

Les robots Phabricator sont semblables aux robots MediaWiki, et la majorité des règles des robots Wikimedia leur est applicable.

Vérifiez la liste des robots enregistrés dans phabricator.wikimedia.org.

Séparer les comptes des robots des comptes personnels

A personal user account is not appropriate for repetitive patterns of activity, as in the human case they would almost universally be considered spam, or at best be locked into someone's personal account. L'activité qui émane d'un compte spécifique semblant envoyer des pourriels peut nécessiter de désactiver ou de supprimer le compte. In these instances, if the offending account is also the personal account of a user, they will not be able to appeal or explain the situation.

Posséder un robot

Unlike regular Phabricator accounts, which are tied to a Wikimedia SUL or LDAP account, bot accounts are created natively in Phabricator. Pour demander un compte de robot, veuilez créer une tâche dans le projet Phabricator-Bot-Requests avec les détails suivants :

  • Nom
  • Rôle
  • Une adresse courriel (qui peut être non valide mais doit rester unique)
  • Utilisateur ou organisation responsable

Administrateurs Phabricator : étapes à réaliser

Etapes pour que les administrateurs Phabricator puissent créer de tels comptes :

  • Go to "Manage", go to "Edit Settings", go to "Conduit API Tokens", click "Generate Token".

Copiez ce jeton.

  • Create paste containing that token and set "View policy" to human owner and yourself
  • Paste link in the creation request task and ask human owner to close the task once it works as expected

Possesseurs des comptes robots : étapes à réaliser

Voici les étapes pour configurer arc afin qu'il puisse utiliser votre compte de robot.

  • Acquérir le certificat du compte pour votre robot
  • Create an arc configuration file matching the following, replacing "<your bot account id>" and "<your bot certificate>" with the appropriate values.
 {
   "config": {
     "default": "https:\/\/phabricator.wikimedia.org\/"
   },
   "hosts": {
     "https:\/\/phabricator.wikimedia.org\/api\/": {
       "token": "api-token_which_starts_with_api"
     }
   }
 }
  • Enregistrer ce fichier quelque part. The default location arc looks is ".arcrc" in your home directory (~/.arcrc on Linux and Mac), but if you already have an arcrc file on the machine you're testing with, you may prefer to save it elsewhere. Pour les objectifs de cet exemple, on utilise bot.arcrc dans le répertoire de travail actuel.
  • Exécutez la commande suivante en tant que test :
 $ arc tasks --unassigned --limit 1 --arcrc-file bot.arcrc

Ceci doit renvoyer un court résumé d'une tâche unique de Maniphest.