youngmon/atlassian-qna huggingface dataset:
How to delete a folder repository in source?
Asked by Nica:

Good day!

I just wanted to ask how to delete directly a folder file in bitbucket instead of deleting it locally and commit push?

Since I'm encountering an issue during push I can't update the deleted file in my project, so I'm planning to delete the folder directly in the bitbucket. Do you have any ideas?


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

It is not possible to delete a folder directly in Bitbucket. The deletion needs to be done locally and then it needs to be committed and pushed.

Please keep in mind that this won't delete the folder or file from the previous commits. Deleting a folder or file from history would require rewriting history, e.g. with a tool like [BFG repo cleaner](https://rtyley.github.io/bfg-repo-cleaner/). However, if you are not looking to remove it from history, then committing the deletion should be ok.

What issues are you facing when you try to push? What is the output of the push command? Perhaps we can help with that.

We also offer an API endpoint to create a commit that deletes files:

* <https://developer.atlassian.com/cloud/bitbucket/rest/api-group-source/#api-repositories-workspace-repo-slug-src-post>

You can see an example below the line that reads "To create a commit that deletes files, use the files parameter:"

Kind regards,  
Theodora


author: Aron Gombas _Midori_
body: It doesn't matter where it is done, deleting a folder must be done with an *actual* commit!

But I think you're approaching it in the wrong way. Instead of trying to delete that folder for whatever reason, why don't you "git pull"? It would "sync" your local repo to the remote one,. It could even result in conflicts that you have to resolve, but it *is* the way to do it.


Tags: bitbucket-cloud

cloud
how to delete a failed import repo?
Asked by allauddin ali ahmad:

I imported a repo from one workspace to the current workspace but it failed with an error. It initiated the repo in the workspace but if I try opening it, gives an error that "We can't let you see this page". How can I delete this repo if I can not access it?

Thanks,

Ali


Answers:
author: Mark C
body: Hi [@allauddin ali ahmad](/t5/user/viewprofilepage/user-id/5113260),

Thank you for reaching out to the community.  

It seems the repository was stuck in the "Importing" state.  
I went ahead and deleted the repository.  
You can now try to import again.  

Regards,  
Mark C

comments: author: allauddin ali ahmad
body: Thanks, Marc.


Tags: bitbucket-cloud

cloud
Pipelines build consistently slow since the end of July 2023
Asked by Alex Panchenko:

Hi,

Approximately since July 30 our pipelines take much longer.

It's specially painful when when build runs without caches (when those are removed after 7 days)

We use java and gradle to manage dependencies.

A few repositories are relatively big and the build takes more than 1 hour without caches, while previously it was OK with max-time=24 minutes in one of them.

Was there any infrastructure change in that time frame or what could be a possible reason?

Thanks,

Alex


Answers:
author: Theodora Boudale
body: Hi Alex,

Do these Pipelines builds run on Atlassian infrastructure or are you using one of our [self-hosted runners](https://support.atlassian.com/bitbucket-cloud/docs/runners/)? You are asking about infrastructure changes so I assume they run on Atlassian infrastructure, but I would like to make sure.

Is it a certain command in your yml file that takes longer than before? Or more than one? Or does this happen in the **Build setup**?

You mentioned caches. Have you configured your build to download additional dependencies than before? Are there any additional tasks in your build that weren't there before?

If this concern builds running on Atlassian infrastructure, you can try [debugging locally with Docker](https://confluence.atlassian.com/bbkb/debug-pipelines-locally-with-docker-1167698072.html) (a) a build that was previously taking less time with no cache and (b) a build that now takes longer with no cache, and observe if the times are similar to the respective Pipelines builds.

Infrastructure changes are announced here: <https://confluence.atlassian.com/bbkb/infrastructure-changes-in-bitbucket-pipelines-1142431176.html> The recent ones are the Kubernetes cluster upgrades, but I'm not sure if that would affect the duration of your builds.

If your workspace is on a paid billing plan, you can create a ticket with the support team. If we have an open support ticket, the engineer working on it will be able to access the build logs and help you with the investigation. You can create a ticket via <https://support.atlassian.com/contact/#/>, in "What can we help you with?" select "Technical issues and bugs" and then Bitbucket Cloud as product.

Kind regards,  
Theodora


Tags: bitbucket-cloud

cloud
Which characters are allowed in Personal Access Tokens (PATs) on Bitbucket?
Asked by Elchanan Arbiv:

Can special characters like \*, \&, %, $, #, and @ be used in Personal Access Tokens (PATs) in the self-hosted version of Bitbucket?


Answers:
author: Kurt Klinner
body: [@Elchanan Arbiv](/t5/user/viewprofilepage/user-id/5178031)

Hi Elchanan

welcome to the Atlassian community?

Are you referring to the name of the PAT?

Cheers

Kurt


Tags: bitbucket-server

server
We can't let you see this page
Asked by Sebastian:

I tried to import a repository from GitHub. The process failed with an error, and now, while the repository has been created anyway, I get the message 'We can't let you see this page.' when i try to access this repo. This also means I can't delete this repository. How do I get rid of this repository?


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

The Bitbucket Cloud account with the same email as your community account has access to several repositories. I checked these repositories, however, none of them seem to be in an IMPORTING state (which is the case for failed imports).

Do you have a second Bitbucket Cloud account with a different email that you used to make the import? If so, could you log in to <https://community.atlassian.com/> using the email of this other account and leave a comment here? I can then check the repos this other account has access to.

Kind regards,  
Theodora


author: allauddin ali ahmad
body: I have exactly the same problem when I try copying the repo from one workspace to another. I am unable to delete this failed repo. Any leads to get rid of this repo?

Thanks.

comments: author: Theodora Boudale
body: Hi [@allauddin ali ahmad](/t5/user/viewprofilepage/user-id/5113260),

I see you created a separate question about this issue and one of my colleagues assisted you.

Kind regards,  
Theodora


author: Ali Mughal
body: I made an attempt to import a GitHub repository. Even though the repository has been created, the process failed with an error[,](https://bit.ly/3Rajzqq) and now whenever I try to visit this repository[,](https://bit.ly/442B0wb%20 ) I see the message "We can't let you see this page[.](https://bit.ly/3Qx6bwr)" I am also unable to delete this repository as a result. What need I do to remove this repository?

comments: author: Theodora Boudale
body: Hi Ali,

There is no Bitbucket Cloud account with the same email as your community account. Could you please log in to <https://community.atlassian.com/> using the same email you use to log in to Bitbucket and create a new question via <https://community.atlassian.com/t5/forums/postpage/board-id/bitbucket-questions>. We will then look into this.

Kind regards,  
Theodora


author: Catharina von Hobe
body: I have exactly the same problem and I cannot delete the failed repo. Please help. Thanks.

comments: author: Theodora Boudale
body: Hi Catharina,

Your Bitbucket Cloud account has access to two repositories that were stuck in the IMPORTING state with a size of 0 bytes. These repos cannot be deleted by end users, so I went ahead and deleted them for you.

Kind regards,  
Theodora


Tags: bitbucket-cloud

cloud
After Import repository failed I cant access new repository
Asked by Guanyi Du:

![image.png](https://community.atlassian.com/t5/image/serverpage/image-id/274819iE3DAC04AD0727D37/image-size/large?v=v2&px=999 "image.png")I am trying to use Import existing code to import my code from GitHub, but failed.  
And after failing, a new repo is been created, but I can't access this repo (with admin permission), and its displays "We can't let you see this page".![image.png](https://community.atlassian.com/t5/image/serverpage/image-id/274823i487A3397C99CE57B/image-size/large?v=v2&px=999 "image.png")

so how can I delete this repo from my project?

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


Answers:
author: Ben
body: Hi [@Guanyi Du](/t5/user/viewprofilepage/user-id/5291268)

I have just forced deletion of that repository - unfortunately, this is something that needs to be deleted from our end when there is an issue during import.

Please double-check this reflects on your end.

Cheers!

- Ben (Bitbucket Cloud Support)

comments: author: Guanyi Du
body: Thanks!! It already disappears from my end


Tags: bitbucket-cloud

cloud
Can't see my repositories.
Asked by gil_benzvi:

When I log into my account I see no repositories although I can access them using GitExtension.


Answers:
author: Syahrul
body: G'day, [@gil_benzvi](/t5/user/viewprofilepage/user-id/2713255)

Can you try to navigate to the top right corner of the cog icon \> Select all workspace?

Then choose which workspace you wish to view the repository and open the repositories tab to see the list of repositories.

If you don't know which workspace, check the repository URL for example bitbucket.org/abc/repo1.git then the workspace ID is the abc in the URL.

I hope this helps.

Regards,  
Syahrul

comments: author: gil_benzvi
body: Bingo - I can see my repositories now.

Many thanks !!!!


Tags: bitbucket-cloud

cloud
"This workspace ID is not available" right after deletion and months after (not taken)
Asked by Patryk Kowejsza:

Hi everyone,

I've created and deleted workspaces when testing. None of them currently exist, but I still get the "This workspace ID is not available." error whenever I try to create one. (it's not taken)

I realised I can't fix the problem by myself and wanted to ask here. I could choose from all the workspaces that were deleted.

Any idea what the issue might be?


Answers:
author: Patryk Kowejsza
body: **Update**: The fact that those deleted workspaces were suggested doesn't actually mean that I can't create one if not taken.

Just tried to create a workspace with the same name as my oldest deleted one and it worked!

The status probably just needs some time to get updated across services.

comments: author: Rinaldo Persichini
body: Sorry to bother, but how long did it take until the workspace was available again? Due to import complications from Git-Lab we need the same Workspace-ID. We know it's not taken but it still won't allow us to rename (This workspace ID is not available.)


author: Kedar Joshi
body: I am also curious about time after which the **workspace id** was available again. It has been 20 hours and still can't use the deleted workspace id.


author: Matt Schonert
body: I'm wondering the same. I deleted a workspace and am trying to rename another workspace to use the name of the one that I deleted. It's been 24 hours and it still says "This workspace ID is not available."


Tags: bitbucket-cloud

cloud
Unable to login to Bitbucket
Asked by strings:

Hi!

I have an old Bitbucket account linked to my email. I got an invite to a new project and need to accept it using that account, but simply logging causes a URL with the following message to appear:  
> We couldn't log you in
>
> You may run into this issue when you use specific browsers or add-ons that hide the referer header for id.atlassian.com and other Atlassian sites. Check for these and then try logging in again.
I've seen some similar issues online and tried multiple options to unblock myself: clearing the cache and deleting all website data, switching to incognito mode, multiple browsers (Chrome and Firefox) and devices (PC and cellphone). Still, I always get the same message. In case that's relevant, the account is now linked to my Google account.

Could you provide assistence or alternative steps to help me with this?  
Thanks in advance!


Answers:
author: Theodora Boudale
body: Hi and welcome to the community!

The Bitbucket Cloud account with the same email as your community account was deactivated, which I believe is the reason for the error you were seeing.

I went ahead and reactivated the account. Could you try logging in now and let me know if the issue is resolved?

Kind regards,  
Theodora


author: strings
body: Hello Theodora,

Thank you for your reply and for reactivating my account. I just confirmed that I can access Bitbucket normally now.

Cheers,

Pedro.


Tags: bitbucket-cloud

cloud
Bitbucket does not work
Asked by simon-xie:

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


Answers:
author: simon-xie
body: Hello?I finally login account again and change to other wifi for my computer.


author: Theodora Boudale
body: Hi [@simon-xie](/t5/user/viewprofilepage/user-id/1458236),

This usually indicates a server-side error. I would like to ask for some additional info to investigate:

**1.** Can you consistently reproduce this error if you go to the **Repositories** page you posted here?

**2.** Does this occur when you are viewing the Repositories of your own workspace or of a different workspace?

**3.** If the issue is still occurring, can you do the following while viewing this page:

* open **Developer tools** on your browser
* select the tab **Network**
* do a hard refresh on the page

Does any of the requests in the **Network** tab show a status of 5\*\* or 4\*\*?   
If so, can you select it and at the **Headers** tab look for a field named **x-sentry-id** or **sentry-id**? I would need the value of that field in order to look it up on our system for more info.

Kind regards,  
Theodora

comments: author: simon-xie
body: Hello?I finally login account again and change to other wifi for my computer.


author: Theodora Boudale
body: Hi, that's good to hear, I'm glad that the issue was resolved.


author: Robert Wen_ReleaseTEAM_
body: Could you provide some context as to what operation you were performing?


Tags: bitbucket-cloud

cloud
Workspace plan details
Asked by Elixir Labs:

Hi,

Can I get bitbucket workspace plan details by API instead of using console. Please provide the answer for my query.

Thanks in advance.


Answers:
author: Theodora Boudale
body: Hi [@Elixir Labs](/t5/user/viewprofilepage/user-id/1709457),

I'm afraid that it is not possible to get these details via API.

We have a feature request that you can vote for (by selecting the **Vote for this issue** link) to express your interest:

* <https://jira.atlassian.com/browse/BCLOUD-22127>

Implementation of features is done as per our policy [here](https://confluence.atlassian.com/support/implementation-of-new-features-policy-201294576.html) and any updates will be posted in the feature request.

Kind regards,  
Theodora


Tags: bitbucket-cloud

cloud
Bitbucket deactivated my account without any reason or notice
Asked by Anton Trehubau:

Yesterday everything was fine, but today I can't log in into my account. I am seeing the message that says that Bitbucket deactivated my account. Also, the message says that they have sent me some email, but it is not true. I haven't received any email from them.

Why did Bitbucket do that?

Is there a way to contact support to know the reasons?

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


Answers:
author: Kseniia Trushnikova
body: Hi [@Anton Trehubau](/t5/user/viewprofilepage/user-id/5290276),

You must have received the following email from Atlassian:
> We are contacting you to let you know that Atlassian is winding down its operations in Russia and Belarus, and our records identify you are using Atlassian's no-charge product(s) within these identified regions. As such, this email constitutes notice that, in accordance with our Cloud Terms of Service, we will terminate your Atlassian account in 30 days.
>
> We understand this is difficult news and we know that you are operating in a country waging a war you may neither support nor have the ability to stop. However, due to implementation of laws compelling all Russian businesses to support the invasion of Ukraine, we have made the difficult decision to wind down operations in these markets.

Please contact the support <https://www.atlassian.com/company/contact/purchasing-licensing#/> for more information.


Tags: bitbucket-cloud

cloud
I didn't realize Atlassian acquired bitbucket and I need to get the old data back
Asked by Jace Benson:

I used to login without an email, now to login it requires an email. I tried to open a support request but they required a workspace and then it just directed me here.

How can I get these accounts merged?


Answers:
author: Nic Brough -Adaptavist-
body: Welcome to the Atlassian Community!

A lot has happened since the acquisition - Atlassian got Bitbucket while I was working for my previous employer, and I've been with Adaptavist for 8-9 years at least, so it's a lot older.

I think they are asking you to log in with an Atlassian account, do you have one of those?


Tags: bitbucket-cloud

cloud
Reduce repo size
Asked by subhojit1480:

The size of the repo showing is 2.57 GB.

Could you delete large files from old commit history so size will be decreased?


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

I ran a git gc for the repo that was over 2 GB and its size has been reduced a bit.

The Atlassian team cannot remove any large files from your repo, this is something that you need to do yourself (e.g. with BFG repo cleaner like Mikael suggested) and we can then trigger a git gc for your repo to remove any unreachable commits after history rewrite.

You can check [this post](https://community.atlassian.com/t5/Bitbucket-questions/Revert-bitbucket-repository-state-to-one-day-prior/qaq-p/1908360#M76762) of mine for more details on how to identify large files and what options you have.

Please feel free to reach out if you have any questions!

Kind regards,  
Theodora


author: Mikael Sandberg
body: Have a look at this [KB](https://support.atlassian.com/bitbucket-cloud/docs/maintain-a-git-repository/) on how to reduce the repo size. You can either use a BFG Repo Cleaner to removes files that are over a certain size, or use git filter-branch to rewrite the history. I have used BFG in the past to do this.

comments: author: subhojit1480
body: Thanks


Tags: bitbucket-cloud

cloud
How to get the mfa status of bitbucket workspace users
Asked by jawad_abbasi:

Hi Community,

I have an admin rights to the bitbucket workspace and atlassian product but I don't find any way to retrieve the mfa status for all the bitbucket users. Also I don't see any such api available under the documentation.

It'll be helpful for me if someone provide me any bitbucket api to retrieve such user details ?

Thanks \& Regards,

Jawad Abbasi


Answers:
author: Saxea _Flowie_
body: <https://developer.atlassian.com/cloud/bitbucket/rest/api-group-workspaces/#api-workspaces-workspace-members-get> can do that, however it will not include the mfa status by default. You need to request the additional fields.  

e.g.:

\`<https://api.bitbucket.org/2.0/>workspaces/{workspace}/members?fields=%2Bvalues.user.\*%2C%2Bnext\`

The response will have a field named \`has_2fa_enabled\`

comments: author: jawad_abbasi
body: [@Saxea _Flowie_](/t5/user/viewprofilepage/user-id/5230209) Thank you so much. I got expected result by using the above api.   

Command :   
curl --request GET --user \<username\>:\<app_pass\> --url '<https://api.bitbucket.org/2.0/workspaces/terratrak/members?fields=%2Bvalues.user.display_name%2C%2Bvalues.user.has_2fa_enabled%2C%2Bnext>' \| jq '.values\[\] \| {Name: .user.display_name, MFA_status: .user.has_2fa_enabled}'  

<br />


Tags: bitbucket-cloud

cloud
Can atlassian/scp-deploy overwrite an executable ?
Asked by Yohan Le Bricquer:

Hello,

I'm writing a pipeline with scp-deploy and the pipeline is working fine if my executable is not on the server. However if it is already there my pipeline fails. Do I have to remove the file before deploying ?

Pipeline:

![Screenshot 2023-08-10 at 17.56.17.png](https://community.atlassian.com/t5/image/serverpage/image-id/274474i1B27BABC2A6642F2/image-size/large?v=v2&px=999 "Screenshot 2023-08-10 at 17.56.17.png")

Error if the executable is on the server already:

![Screenshot 2023-08-10 at 18.00.51.png](https://community.atlassian.com/t5/image/serverpage/image-id/274478i0D39DFBD1423E107/image-size/large?v=v2&px=999 "Screenshot 2023-08-10 at 18.00.51.png")


Answers:
author: Saxea _Flowie_
body: Possibly because /home/ubuntu/fago is read only? Can change the permissions before copying, or \`atlassian/ssh-run\` and change the permissions remotely only, or use rsync instead?


author: Yohan Le Bricquer
body: Thanks for replying. I tried with rsync and it's working now whether the executable is on the server or not.


author: Igor Stoyanov
body: [@Yohan Le Bricquer](/t5/user/viewprofilepage/user-id/5289834) Hi.  
Thanks for your question.  
Try to run scp without pipe usage to understand the problem is with the pipe or with the scp command.  

Regards, Igor


Tags: bitbucket-cloud

bitbucket-pipelines

cloud

scp
Is there a way to exclude certain files when making pulling a repo via ssh?
Asked by U4EA22:

I have a number of private repos I used in my projects.

Package.json: -

"myaccount/myrepo": "git+ssh://git@bitbucket.org/myrepo/blah.git"  
Is there a way I can exclude certain files being pulled when this happens? I believe with npm this functionality is represented with the package.json "files" key or by inclusion of an .npmignore file.  
Thanks.


Answers:
author: Syahrul
body: G'day, [@U4EA22](/t5/user/viewprofilepage/user-id/5289561) and Welcome to the community.

Can clarify your intention behind inquiring about excluding files during a git pull?

I ask because the purpose of git pull is to fetch commits from a remote repository and integrate them into your local branch. The standard git pull command does not offer a built-in feature to exclude specific files during the process. Its primary function is to retrieve and incorporate new commits into your local repository, including all tracked files.

If your objective is to prevent specific files from being overwritten or merged during a git pull, you might need to consider alternative strategies.

One approach is to use [.gitignore](https://www.atlassian.com/git/tutorials/saving-changes/gitignore) to specify files or patterns that Git should ignore when performing operations like pull, commit, and push. This can help prevent unintended changes to specific files.

I hope this helps.  

Regards,  
Syahrul

comments: author: U4EA22
body: Sorry, I meant to refer to it as installing, not pulling.

When I install the package via SSH, I would like to do so without installing certain files. For example, I might have a repo of UI components with a sub directory containing a react app to show examples but would only way to install the components library. Thanks.


Tags: cloud