Automatically decline inactive pull requests

On this page

Still need help?

The Atlassian Community is here for you.

Ask the community

Bitbucket Data Center and Server can automatically decline pull requests that are inactive, reducing the number of pull requests in the list that can add up. For example, if an older pull request has not had any activity (like commits, comments or approvals) in a set amount of time, it will be declined. By default, the option is on and set to 4 weeks. This period of inactivity can be overwritten for projects and repositories.

On this page:

There is an instance-wide configuration property for this feature in the bitbucket.properties file that allows admins to disable or turn the feature off.

feature.pull.request.auto.decline=false

Automatically decline inactive pull requests for all repositories in a project

To configure the automatic declining of inactive pull requests in a project:

  1. Select Project settings > Auto-decline.

  2. Select the Auto-decline pull requests check-box to enable it.

  3. Set the amount of time before a pull request will be automatically declined from 1, 2, 4, 8, or 12 weeks.

  4. Select Save.

Automatically decline inactive pull requests for a repository

Configuring this setting at the repository level, will override the setting for it at the project level.

To configure the automatic declining of inactive pull requests in a single repository:

  1. Select Repository settings > Auto-decline.

    1. By default, settings are inherited from the project settings.

  2. Select Use custom settings.

  3. Select the Auto-decline pull requests check-box to enable it.

  4. Set the amount of time before a pull request will be automatically declined from 1, 2, 4, 8, or 12 weeks.

  5. Select Save.

Once the configuration is saved, inactive pull requests will become declined by the Bitbucket system user. This will add a comment indicating that the reason for the decline is due to inactivity.

Last modified on Apr 6, 2021

Was this helpful?

Yes
No
Provide feedback about this article
Powered by Confluence and Scroll Viewport.