# \[error\]ERROR: Could not find the pullrequest with key

**URL:** <https://community.sonarsource.com/t/error-error-could-not-find-the-pullrequest-with-key/182481>\
**Category:** SonarQube Cloud\
**Tags:** azuredevops-services, dotnet, sonarqube-cloud\
**Created:** [May 19, 2026, 1:52pm UTC](https://community.sonarsource.com/t/error-error-could-not-find-the-pullrequest-with-key/182481 "2026-05-19T13:52:46Z")\
**Posts on this page:** 13\
**Page:** 1

<div class="post-metadata">

**Author:** ![rufer7](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/rufer7/32/49874_2.png) [@rufer7](https://community.sonarsource.com/u/rufer7)\
**Post date:** [May 19, 2026, 1:52pm UTC](https://community.sonarsource.com/t/error-error-could-not-find-the-pullrequest-with-key/182481/1 "2026-05-19T13:52:46Z")

</div>

We are currently getting the following error in the Azure DevOps YAML pipeline logs of step `SonarCloudAnalyze@3`. However, not in every run of the pipeline which is super strange.

```auto
[error]ERROR: Could not find the pullrequest with key

```

The PAT for PR decoration is specified on organization level, got refreshed last week and is still valid.

Any idea why this happens? May a caching issue on SonarQube Cloud side?

## Detailed information

- Azure DevOps Services
- SonarCloudAnalyze@3 task
- .NET

```auto
...
INFO: Load branch configuration
INFO: ------------------------------------------------------------------------
INFO: EXECUTION FAILURE
INFO: ------------------------------------------------------------------------
INFO: Total time: 6.837s
INFO: Final Memory: 14M/50M
INFO: ------------------------------------------------------------------------
##[error]ERROR: Error during SonarScanner execution
ERROR: Error during SonarScanner execution
##[error]ERROR: Could not find the pullrequest with key '123'
ERROR: Caused by: Error 404 on https://sonarcloud.io/api/alm_integration/show_pullrequest?project=PROJECT_HERE&pullrequestKey=123 : {"errors":[{"msg":"You don\u0027t have permission, or the provided pullrequest with key \u002737687\u0027 doesn\u0027t exist."}]}
ERROR:
ERROR: Could not find the pullrequest with key '123'
ERROR: Caused by: Error 404 on https://sonarcloud.io/api/alm_integration/show_pullrequest?project=PROJECT_HERE&pullrequestKey=123 : {"errors":[{"msg":"You don\u0027t have permission, or the provided pullrequest with key \u002737687\u0027 doesn\u0027t exist."}]}
ERROR: 
##[error]The SonarScanner did not complete successfully
The SonarScanner did not complete successfully
##[error]11:39:20.241 Post-processing failed. Exit code: 1
11:39:20.241 Post-processing failed. Exit code: 1

```

---

<div class="post-metadata">

**Author:** ![ganncamp](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/ganncamp/32/1261_2.png) [@ganncamp](https://community.sonarsource.com/u/ganncamp)\
**Post date:** [May 20, 2026, 4:04pm UTC](https://community.sonarsource.com/t/error-error-could-not-find-the-pullrequest-with-key/182481/2 "2026-05-20T16:04:22Z")

</div>

Hi,

You say this doesn’t happen on every PR. Is the behavior consistent within a given product or do some PRs for a given project work and others don’t?

&nbsp;  
Ann

---

<div class="post-metadata">

**Author:** ![rufer7](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/rufer7/32/49874_2.png) [@rufer7](https://community.sonarsource.com/u/rufer7)\
**Post date:** [May 20, 2026, 4:30pm UTC](https://community.sonarsource.com/t/error-error-could-not-find-the-pullrequest-with-key/182481/3 "2026-05-20T16:30:06Z")

</div>

It didn’t even happen on every run of a PR within the same project.

---

<div class="post-metadata">

**Author:** ![ganncamp](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/ganncamp/32/1261_2.png) [@ganncamp](https://community.sonarsource.com/u/ganncamp)\
**Post date:** [May 20, 2026, 5:04pm UTC](https://community.sonarsource.com/t/error-error-could-not-find-the-pullrequest-with-key/182481/4 "2026-05-20T17:04:16Z")

</div>

Hi,

Are you still experiencing this, currently? Because this sounds like an intermittent connectivity problem.

&nbsp;  
Ann

---

<div class="post-metadata">

**Author:** ![rufer7](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/rufer7/32/49874_2.png) [@rufer7](https://community.sonarsource.com/u/rufer7)\
**Post date:** [May 20, 2026, 5:23pm UTC](https://community.sonarsource.com/t/error-error-could-not-find-the-pullrequest-with-key/182481/5 "2026-05-20T17:23:40Z")

</div>

I experienced it on Monday and on Tuesday. However, it didn’t happen anymore at the moment.

---

<div class="post-metadata">

**Author:** ![ganncamp](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/ganncamp/32/1261_2.png) [@ganncamp](https://community.sonarsource.com/u/ganncamp)\
**Post date:** [May 20, 2026, 5:44pm UTC](https://community.sonarsource.com/t/error-error-could-not-find-the-pullrequest-with-key/182481/6 "2026-05-20T17:44:19Z")

</div>

Hi,

Looking back (I was off) I don’t see any problems declared internally Monday or Tuesday. If this happens again, come back as soon as you can and we’ll look from our end.

&nbsp;  
Thx,  
Ann

---

<div class="post-metadata">

**Author:** ![rufer7](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/rufer7/32/49874_2.png) [@rufer7](https://community.sonarsource.com/u/rufer7)\
**Post date:** [May 21, 2026, 9:33pm UTC](https://community.sonarsource.com/t/error-error-could-not-find-the-pullrequest-with-key/182481/7 "2026-05-21T21:33:47Z")

</div>

Hi,

it just happened again in another project. This morning it worked, now it doesn’t anymore.

Last run which succeeded logged in prepare analysis task the following version.

```auto
[INFO] SonarQube Cloud: Server version: 8.0.0.87945

```

Since then it’s failing and versions is:

```auto
[INFO] SonarQube Cloud: Server version: 8.0.0.88086

```

---

<div class="post-metadata">

**Author:** ![ganncamp](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/ganncamp/32/1261_2.png) [@ganncamp](https://community.sonarsource.com/u/ganncamp)\
**Post date:** [May 22, 2026, 11:22am UTC](https://community.sonarsource.com/t/error-error-could-not-find-the-pullrequest-with-key/182481/8 "2026-05-22T11:22:17Z")

</div>

Hi,

You’re getting exactly that same error? We had an incident last night & earlier this morning where a 401 was returned with the use of an org-level SOT. Were/are you getting a 404 or a 401?

&nbsp;  
Thx,  
Ann

---

<div class="post-metadata">

**Author:** ![rufer7](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/rufer7/32/49874_2.png) [@rufer7](https://community.sonarsource.com/u/rufer7)\
**Post date:** [May 22, 2026, 11:36am UTC](https://community.sonarsource.com/t/error-error-could-not-find-the-pullrequest-with-key/182481/9 "2026-05-22T11:36:39Z")

</div>

Yes.

```auto
ERROR: Error during SonarScanner execution
##[error]ERROR: Could not find the pullrequest with key '123'
ERROR: Caused by: Error 404 on https://sonarcloud.io/api/alm_integration/show_pullrequest?project=PROJECT&pullrequestKey=123 : {"errors":[{"msg":"You don\u0027t have permission, or the provided pullrequest with key \u0027123\u0027 doesn\u0027t exist."}]}
ERROR:
ERROR: Could not find the pullrequest with key '123'
ERROR: Caused by: Error 404 on https://sonarcloud.io/api/alm_integration/show_pullrequest?project=PROJECT&pullrequestKey=123 : {"errors":[{"msg":"You don\u0027t have permission, or the provided pullrequest with key \u0027123\u0027 doesn\u0027t exist."}]}
ERROR: 

```

---

<div class="post-metadata">

**Author:** ![ganncamp](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/ganncamp/32/1261_2.png) [@ganncamp](https://community.sonarsource.com/u/ganncamp)\
**Post date:** [May 22, 2026, 1:45pm UTC](https://community.sonarsource.com/t/error-error-could-not-find-the-pullrequest-with-key/182481/10 "2026-05-22T13:45:39Z")

</div>

Hi,

Could I have the full analysis log, starting from the analysis command itself?

&nbsp;  
Thx,  
Ann

---

<div class="post-metadata">

**Author:** ![rufer7](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/rufer7/32/49874_2.png) [@rufer7](https://community.sonarsource.com/u/rufer7)\
**Post date:** [May 22, 2026, 8:44pm UTC](https://community.sonarsource.com/t/error-error-could-not-find-the-pullrequest-with-key/182481/11 "2026-05-22T20:44:56Z")

</div>

I sent it to you via private message.

Btw it seems to work again.

This is the version it works again.

```auto
[INFO] SonarQube Cloud: Server version: 8.0.0.88170

```

---

<div class="post-metadata">

**Author:** ![rufer7](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/rufer7/32/49874_2.png) [@rufer7](https://community.sonarsource.com/u/rufer7)\
**Post date:** [May 26, 2026, 7:55am UTC](https://community.sonarsource.com/t/error-error-could-not-find-the-pullrequest-with-key/182481/12 "2026-05-26T07:55:37Z")

</div>

@ganncamp it just happened again with the following SonarQube Cloud version…

```auto
SonarQube Cloud: Server version: 8.0.0.88170

```

---

<div class="post-metadata">

**Author:** ![ganncamp](https://dub1.discourse-cdn.com/sonarsource/user_avatar/community.sonarsource.com/ganncamp/32/1261_2.png) [@ganncamp](https://community.sonarsource.com/u/ganncamp)\
**Post date:** [May 28, 2026, 3:24pm UTC](https://community.sonarsource.com/t/error-error-could-not-find-the-pullrequest-with-key/182481/14 "2026-05-28T15:24:13Z")

</div>

Hi,

Sorry for the delay in responding. The fact that this is intermittent, suggests a problem on our side rather than on yours. I’ve flagged this for the team.

&nbsp;  
Ann
