youngmon/atlassian-qna huggingface dataset:
Bitbucket Pipelines stderr
Asked by Oleg Mikhailov:

Hi! Recently I've got a very strange error during bitbucket pipelines execution:

    2020-12-11T14:36:21.5200365Z stderr P 

Pipelines worked fine, then they stopped working suddenly and started to return that weird message.

My configuration uses docker

```
image: docker/compose:1.25.4

options:
  docker: true

definitions:
  services:
    docker:
      memory: 3072
  caches:
pipelines:
  default:
    - step:
        name: Run Unit tests
        script:
          - apk add --no-cache git openssh
          - git submodule update --init
          - cp .env.example .env
          - cp phpunit.xml.dist phpunit.xml
          - cp /opt/atlassian/pipelines/agent/ssh/id_rsa .docker/node
          - cp /opt/atlassian/pipelines/agent/ssh/id_rsa .docker/composer
          - mkdir -p .docker/.storage/composer && chmod -R a+rw .docker/.storage/composer
          - docker-compose build
          - docker-compose run --rm composer install --no-progress
          - docker-compose run --rm phpunit dockerize -wait tcp://mysql:3306 -wait tcp://mongodb:27017 -timeout 60s
          - docker-compose run --rm phpunit ./artisan migrate --seed
          - docker-compose run --rm phpunit vendor/bin/phpunit --configuration ./phpunit.xml  --testsuite 'Checkout Unit'
          - docker-compose run --rm phpunit vendor/bin/phpunit --configuration ./phpunit.xml --testsuite 'App Api'
          - docker-compose run --rm phpunit vendor/bin/phpunit --configuration ./phpunit.xml --testsuite 'Checkout Api'
```

The first 2 testsuites work fine, pipeline is failing on the third testsuite and returns me

stderr P error that I see in docker-compose logs.

Tests work fine on my local machine, and they worked fine in bitbucket until recently.

Can anybody give me any clue what's wrong?

I checked if anything is spoiling stderr, nothing is logging there.


Answers:
author: jlarroque
body: This happened to me when I tried to import a library called opencv for python, but I guess it could happen for any other language/library. For anyone checking this, try to see if any recent library added could be causing you troubles.  

Anyway, looks like a bug, the error should be visible in the GUI


Tags: bitbucket-pipelines

cloud
Issue with source in pipeline cloud storage
Asked by Md Parvez Alam:

I have below pipeline

    image: node:10.15.3pipelines:  default:      - step:          name: Installing          caches:            - node          script:            - rm -rf package-lock.json            - rm -rf node_modules            - npm install      - step:          name: Build          script:            - npm install --production          artifacts:            - build/**      - step:          name: Deploying          script:          - pipe: atlassian/google-cloud-storage-deploy:0.4.5            variables:              KEY_FILE: $KEY_FILE              PROJECT: $PROJECT              BUCKET: 'bucketname'              SOURCE: 'build'              CACHE_CONTROL: 'max-age=30'              ACL: 'public-read'

The expected behavior is to deploy everything inside the build folder, but it uploads the build folder itself so in my storage, there is a build folder then everything inside this...

I have tried

'build/\*\*' it picks only files and ignore directories

'buiid/' it behave same as 'build' picks build directory along with everything inside it directories and folders

'build/\*' it picks only files and ignore directories

How can I everything inside build folder , files and diectories..

Thanks


Answers:
author: Md Parvez Alam
body: I found the issue it's inside pipeline, I have written gsutil command to copy the folder recursively, and problem resolved


Tags: bitbucket-pipelines

cloud
Commit file to a specific branch using Bitbucket API 2.0
Asked by Patrik:

Hello,

I'm trying to commit files to a specific branch (That's already created) using the Bitbucket API. When executing in Postman it creates a commit on master rather than on a specific branch I've specified according to the documentation.  

Specifically this is the endpoint I'm using:  
<https://developer.atlassian.com/bitbucket/api/2/reference/resource/repositories/%7Bworkspace%7D/%7Brepo_slug%7D/src#post>   

Here's my request:

```
POST https://api.bitbucket.org/2.0/repositories/{workspace}/{slug}/src/?parents=master&branch=TestBranch
```

I've tried omitting parents and just using branch but all attempts fallback to comitting to the master branch.  

What's the proper way to call this endpoint to commit to a specified branch?  

<br />

Thanks in advance.


Answers:
author: Patrik
body: I managed to get it working by posting those Query Parameters as form data as well along with my attached files. I guess I was thrown off a bit when reading the documentation and separated my files in form-data and query parameters attached to the endpoint URL.

Here's the Postman setup I used to get it working:

![Screenshot 2020-12-12 at 01.41.23.png](https://community.atlassian.com/t5/image/serverpage/image-id/121902iC78AF94AFDE7D423/image-size/large?v=v2&px=999 "Screenshot 2020-12-12 at 01.41.23.png")


Tags: api

bitbucket-cloud

cloud
Enter passphrase for key '/c/Users/ailogic/.ssh/id_rsa': Unauthorized fatal: Could not read from rem
Asked by Total Language:

getting response while push the code like as below

Enter passphrase for key '/c/Users/ailogic/.ssh/id_rsa':  
Unauthorized  
fatal: Could not read from remote repository.

Please make sure you have the correct access rights  
and the repository exists.


Answers:
author: Theodora Boudale
body: Hi [@Total Language](/t5/user/viewprofilepage/user-id/4191846) and welcome to the community.

Are you trying to push to a Bitbucket Cloud repository (hosted in <https://bitbucket.org/>) or a Bitbucket Server one (in a self-hosted instance)?

A few suggestions I can make:

* I see in the output that you get asked for a passphrase. Do you remember the passphrase for that SSH key pair? If not, you can try generating a new SSH key pair without a passphrase and set up SSH with that instead.
* Check the remote URL of the repo by executing the command *git remote -v* in your local directory of this repo's clone, and ensure that it is correct.
* Check with one of the repo admins that you have permissions to push to this repo.

Kind regards,  
Theodora
Remove Crowd Directory Sync from Stash
Asked by andy.pawl:

I am responsible for many Atlassian instances from acquisitions and one is a Server based platform that was already sun-setted. However today I was asked to remove the sync from Crowd and manage access locally. #1 Is that possible? #2 If so, how do I remove the sync at the Stach level.

These is a Linux environment.

Side note, no one has the credentials to log into any of the servers - including the DB server.

![Crowd.PNG](/t5/image/serverpage/image-id/121884iDD715EB469F52E30/image-size/large?v=v2&px=999 "Crowd.PNG")


Answers:
author: Christian Glockner
body: Hi Andy,

That is possible - just go to User Directories and disable or delete the Crowd Server user directory.

Cheers,

Christian

Premier Support Engineer

Atlassian

comments: author: andy.pawl
body: Thanks for your reply however I do not see that as an option in any of the links (see attached). ![adminusers.PNG](https://community.atlassian.com/t5/image/serverpage/image-id/122429i3C39361789BF7128/image-size/large?v=v2&px=999 "adminusers.PNG")


Tags: bitbucket-server

server
Fail DNS resolution
Asked by Pluskolec:

Hi everyone!  
I have a little problem on my Bitbucket pipeline. For 2 days now, i have different errors to resolve DNS on docker build with image php:7.4-apache.  
Examples :

    W: Failed to fetch http://deb.debian.org/debian/dists/buster/InRelease  Temporary failure resolving 'http://deb.debian.org'

    Connection to `ssl://pecl.php.net:443' failed: php_network_getaddresses: getaddrinfo failed: Temporary failure in name resolution

    The "https://getcomposer.org/download/2.0.8/composer.phar.sig" file could not be downloaded: php_network_getaddresses: getaddrinfo failed: Temporary failure in name resolution

Do you have any idea why ?


Answers:
author: Theodora Boudale
body: Hi [@Pluskolec](/t5/user/viewprofilepage/user-id/4191415) and welcome to the community!

We haven't had any incidents that would affect DNS resolution the last 2 days. I suspect that the most likely reason for these errors would be some issue with the DNS resolver in the image.

That image was recently updated (I see the last push was about an hour ago):

* <https://hub.docker.com/layers/php/library/php/7.4-apache/images/sha256-bcc2796b003a91dc1b116e825337d50993d841f075e77be0f7aea5ab5b387c31?context=explore>

and an apt-get update command works now without issues, so if there was any issues it looks that it may have been resolved.

Could you please confirm whether you're still experiencing issues now?

In case you're still having issues, you can try [debugging your build locally with Docker](https://support.atlassian.com/bitbucket-cloud/docs/debug-pipelines-locally-with-docker/). If the same issue occurs locally with that image, this would point to an issue with the image itself.

Please feel free to let me know if you have any questions.

Kind regards,  
Theodora


Tags: bitbucket-cloud

bitbucket-pipelines

cloud

dns

docker
Is it possible to run more than one command in the following pipe "atlassian/google-gke-kubectl-run"
Asked by Saurabh Singh:

Hi,  

Can I run more than one command in the *COMMAND* variable section while using the following pipe <https://bitbucket.org/atlassian/google-gke-kubectl-run/src/master/>?  

For instance:

```
- pipe: atlassian/google-gke-kubectl-run:1.3.1  variables:    KEY_FILE: '<string>'    PROJECT: '<string>'    COMPUTE_ZONE: '<string>'    CLUSTER_NAME: '<string>'    KUBECTL_COMMAND: 'command_1','command_2'     <======
```


Answers:
author: Halyna Berezovska
body: [@Saurabh Singh](/t5/user/viewprofilepage/user-id/2387177) no, you cannot do it, this would be too complex pipe and would be hard to understand what actually succeeded and how.

I propose you to use you command in a separate step. You can also define those steps as parallel to save time (but be aware that perhaps this will require more pipeline resources like memory and cpu).

Otherwise, explain please us, your use case, why exactly you need it and we will think how to help you.

comments: author: Srikanth Mamidala
body: [@Halyna Berezovska](/t5/user/viewprofilepage/user-id/3865505) If I want to scale the pods after the deployment. How would you recommend us doing that. Should I add another pipe after apply command ? I tried to replace with SED but its not working because of spaces in manifest. Thought running another kubectl command after deployment to scale pods is easier approach.


Tags: bitbucket-pipelines

cloud

google

kubernetes
Cannot see the repositories of my project and team
Asked by Nagendra_Gounipalli:

I am able to login to bitbucket with my credentials but, I am not able to access repositories related to my team or project and even not getting mails from atlassian to my registered mail. Facing this issue since one month. Please try to fix ASAP. Thank you..!


Answers:
author: Theodora Boudale
body: Hi [@Nagendra_Gounipalli](/t5/user/viewprofilepage/user-id/4191355) ,

I checked in our system and I cannot find a Bitbucket Cloud account with an email same as your Community account (the one you used to post this question).

Were you previously able to access your team's projects and repositories?  
Or did you never have access, and they sent you an invitation but you haven't received it?

If you can let me know the email of your Bitbucket Cloud account and the URL of your company's workspace/repos, I can look into this issue for you.

If you don't feel comfortable sharing this info publicly, you can open a ticket about this issue with Bitbucket Cloud support team via <https://support.atlassian.com/contact/#/>. In "What can we help you with?" select "Technical issues and bugs" and then Bitbucket Cloud as product.

Please feel free to let me know if you have any questions.

Kind regards,  
Theodora

comments: author: Nagendra_Gounipalli
body: Hi Theodora,

I am not receiving any mail from atlassian.com.

One of my teammate sent an invitation but I didn't received yet.

I logged into bitbucket(bitbucket.org) successfully using my credentials but my teammates are not able to add to repository. They can't even find my account.


author: Theodora Boudale
body: Hi [@Nagendra_Gounipalli](/t5/user/viewprofilepage/user-id/4191355) ,

Is this issue with the email that you use in your <https://community.atlassian.com/> account?

I checked in our system, and I found a hard bounce event for that email, created on 18th October 2020, with the error message:

```
550: 550 Invalid Recipient
```

It is possible that an invitation was sent before the email account was operational. The hard bounce informs us that the email does not exist and it is then placed in a suppression list, as we no longer try to send to non-existing emails.

I went ahead and removed your email from the suppression list.

Could you please ask one of your teammates to send you a new invitation now?

A new invitation needs to be sent, as the previous ones were dropped.

If this concerns an account with an email different than the email of your Atlassian Community account, please let me know what this other email is (or reach out to the support team) so we can check that specific email.

Please feel free to let me know if you have any questions.

Kind regards,  
Theodora


Tags: bitbucket-cloud

cloud
"approval" objects suddenly missing from Pull Request Activity API
Asked by Grant Jennings:

So, I wrote a small tool for exporting Pull Requests for review by company processes, and it was working fine up until a while back. All of a sudden, the API endpoint at /2.0/repositories/{workspace}/{repo_slug}/pullrequests/{pull_request_id}/activity returns very few objects with "approval". It was working fantastic before, and my tool was able to grab the list of approvers and display who approved a pull request and when. Now, only a handful of issues have the activity approval present, which means it is impossible to display approvers and their approval dates through this endpoint.

So, my question is, is this an API change, or something that has happened on the specific organization I am trying to pull the activity from? I didn't find anything in the API docs about this changing, so as far as I can tell it should be working as expected, but it isn't.


Answers:
author: Tyler T
body: Here is the documentation: <https://developer.atlassian.com/bitbucket/api/2/reference/resource/repositories/%7Bworkspace%7D/%7Brepo_slug%7D/pullrequests/%7Bpull_request_id%7D/activity>

**2 suggestions**

First

Increase the page length. The approvals might be there but on a pull request with lots of activity they might be on the second page of results, for example.

```
?pagelen=50
```

Or

Try filtering by approvals by adding this to your API call

```
?fields=values.approval
```

Here are the docs on partial responses: <https://developer.atlassian.com/bitbucket/api/2/reference/meta/partial-response>

If you filter by approvals you might not need to adjust the page length.

Hopefully that helps!

comments: author: Grant Jennings
body: I am retrieving all available pages by following the URLs to the next page using the "next" field if it exists and terminating if it does not. There are also very few activity items on these pull requests, and the overall number has not increased since a a week ago. A significant number have 2 or 3 at most, and only 2 of those pull requests show up as having approval activity. Adding a 'pagelen' parameter also gives a 400 Bad Request error for the pullrequests endpoint, but a 'limit' parameter does not, which I am already using and is set to 500.


author: Tyler T
body: Hi [@Grant Jennings](/t5/user/viewprofilepage/user-id/3671151) , after more investigation. Our team has found a bug which affects older pull requests. We are working on a fix now. Thank you for your patience.


author: Tyler T
body: Hi [@Grant Jennings](/t5/user/viewprofilepage/user-id/3671151) .. following up on this. A fix has been deployed so you should be seeing approvals in the API as expected. Thank you for your patience and reporting the issue on the Community.


Tags: bitbucket-cloud

cloud
Probl?me de demarrage de bitbucket :SpringMVC dispatcher [springMvc] could not be started
Asked by DMD CONSULT:

Apr?s une coupure et un red?marrage:  
j'ai ce message:

A fatal error has occurred {#toc-hId--1297206221}
-------------------------------------------------

The following problem occurred, which prevents Atlassian Bitbucket from starting:

* SpringMVC dispatcher \[springMvc\] could not be started

J'ai ?ssay? ceci <https://confluence.atlassian.com/bitbucketserverkb/springmvc-dispatcher-could-not-be-started-779171477.html>

Mais je n'ai pas r?ussi.  
Aider moi s'il vous pla?t


Answers:
author: DMD CONSULT
body: Je l'ai d?ploy? sur linux ubuntu 19.04   
bitbucket: 6.10.0


Tags: bitbucket-server

server
Why isn't the python script running with arguments?
Asked by Ivan Yakushenko:

I want to run a python script for ssh deployment:

```
image: atlassian/default-image:latest

pipelines:
  default:
    - step:
      script:
        - apt-get install sshpass
        - sshpass -p $SSH_PASS ssh -o StrictHostKeyChecking=no -p $SSH_PORT $SSH_USER@$SSH_IP "echo $SSH_PASS | sudo -S python3 /var/www/deploy.py -t api -gu $GITUSER -gp $GITPASSWORD"
```

When I run it through a linux csh client, or windows - everything works as it should, but the pipeline always shows an error:

    + sshpass -p $SSH_PASS ssh -o StrictHostKeyChecking=no -p $SSH_PORT $SSH_USER@$SSH_IP "echo $SSH_PASS | sudo -S python3 /var/www/deploy.py -t api -gu $GITUSER -gp $GITPASSWORD
    Warning: Permanently added '[xxx.xxx.xxx.xxx]:xxx' (ECDSA) to the list of known hosts.
    [sudo] password for kshnkvn: usage: http://deploy.py/ [-h] [--target TARGET]
    http://deploy.py/: error: argument -h/--help: ignored explicit argument 'u'


Answers:
author: Gonchik Tsymzhitov
body: [@Ivan Yakushenko](/t5/user/viewprofilepage/user-id/4190675) did you figure out?


Tags: bitbucket-cloud

bitbucket-pipelines

cloud

python
I stopped receiving email notifications
Asked by Steve Brewer:

With no changes to my notification settings I noticed I have stopped receiving emails when mentioned on tickets I am watching. I suspect I'm on the suppression list mentioned in other questions here.

These are the related questions:

- <https://community.atlassian.com/t5/Bitbucket-questions/I-stopped-receiving-bitbucket-email-notifications/qaq-p/1088558>

- <https://community.atlassian.com/t5/Bitbucket-questions/Not-receiving-emails-of-pull-requests/qaq-p/1350499>

Could anybody please investigate following email: steve.brewer@agvance.net


Answers:
author: Theodora Boudale
body: Hi [@Steve Brewer](/t5/user/viewprofilepage/user-id/4190794) ,

I checked in our system and there was indeed a hard bounce event for your email, created on 30th November 2020, with the message:
> 550: 550 5.1.1 Requested action not taken: mailbox unavailable

The hard bounce informs us that the email does not exist and it is then placed in a suppression list, as we no longer try to send to non-existing emails. This could have happened due to a technical issue with your company's mail server.

I went ahead and removed your email from the suppression list.

Please feel free to let me know if things are ok now and if you need anything further.

Kind regards,  
Theodora

comments: author: Steve Brewer
body: I was able to receive bitbucket notification emails today. Thank you [@Theodora Boudale](/t5/user/viewprofilepage/user-id/818086)


author: Theodora Boudale
body: That's good to hear Steve, thank you for the update and you are very welcome!


author: Steve Brewer
body: Hello. I have the same problem of not getting emails from Confluence and Jira from March 23rd or so. Could you please help me resolve this problem. Thank You!


author: Theodora Boudale
body: Hi [@Steve Brewer](/t5/user/viewprofilepage/user-id/4190794) ,

Apologies for the delay, I didn't see the notification sooner.

Does this issue occur for the same email (the email of your community account)?

I checked in our system and I don't see this email in any suppression list. Checking our email logs, I can also see that emails from Jira and Confluence Cloud are being delivered today.

Are you still experiencing issues? If so, is this perhaps for an account with a different email?

Kind regards,  
Theodora


author: Steve Brewer
body: Thank you for checking. The emails started showing up again yesterday so not sure what happened. It is resolved for now.

Thanks


author: Steve Brewer
body: Hello. I have the same problem of not getting emails from Confluence and Jira from April 29th or so.

Could you please help me resolve this problem. Thank You!


author: Steve Brewer
body: Hello. I have the issue again of not getting emails from Confluence and Jira

Could you please help me resolve this problem. Thank You!


Tags: bitbucket-cloud

cloud
how do I link a reference to a note box on the same page?
Asked by Diaconescu Diana-Ancuta (SO/OPM4.3-Tim):

I have a page and at the bottom i have made an info box to which i need to refer in the text above in the same page, it is a clarification for an occurring issue.

thanks


Answers:
author: Fabio Racobaldo _Herzum_
body: Hi [@Diaconescu Diana-Ancuta (SO/OPM4.3-Tim)](/t5/user/viewprofilepage/user-id/5145681) and welcome,

you can use anchor macro for this purpose .

* Cloud guide <https://support.atlassian.com/confluence-cloud/docs/insert-links-and-anchors/>
* Server guide <https://confluence.atlassian.com/doc/anchors-139442.html>

Hope this helps,

Fabio
Add link in tickets, affect the performance of jira ?
Asked by Alex:

Hi, everyone! Please tell me, adding a link confluence in tickets will greatly affect the performance of jira ?

![SFS.png](https://community.atlassian.com/t5/image/serverpage/image-id/239862iAA711B6B8404A271/image-size/large?v=v2&px=999 "SFS.png")


Answers:
author: Nic Brough -Adaptavist-
body: Technically, yes, it will affect performance. Every extra thing the system has to do will slow it down.

Adding a link to an issue makes Jira do a little bit more work.

But it's so small, you would really struggle to spot it, let alone measure it!

comments: author: Alex
body: [@Nic Brough -Adaptavist-](/t5/user/viewprofilepage/user-id/781454) Hi! Thank you for answer!


Tags: confluence-server

jira

server