youngmon/atlassian-qna huggingface dataset:
Corrupt repository after import
Asked by Guy Maurice Coll?:

I have imported a repository from another git server. The import has not finished and after a 15 minutes I closed the browser tab. Now I can not open the repository. It shows a message "We can't let you see this page". The size of the repository is 0kb.

I want to delete that repository and restart the import.

I found a similar question: <https://community.atlassian.com/t5/Bitbucket-questions/Cannot-remove-empty-repository/qaq-p/2112931>

Can anyone help me?

Thanks


Answers:
author: Caroline R
body: Hi, [@Guy Maurice Coll?](/t5/user/viewprofilepage/user-id/5046050), welcome to the community!

Checking the repositories under your workspaces, I confirmed that there was a repo on "importing" status and it was empty. In this case, I went ahead and removed it from this workspace. Could you please try to import it again and let me know how it goes?

Feel free to share any additional questions or concerns regarding this case.

Kind regards,  
Caroline

comments: author: Guy Maurice Coll?
body: Hi Caroline

The import was processed perfectly.

Thank you,

Guy


author: Caroline R
body: Thanks for your confirmation, [@Guy Maurice Coll?](/t5/user/viewprofilepage/user-id/5046050)! I'm glad to know it worked.


author: Mehmet ?ALI?KAN
body: Hello, I have the same problem, can you help?

comments: author: Guy Maurice Coll?
body: [@Mehmet ?ALI?KAN](/t5/user/viewprofilepage/user-id/5214603) I contacted Atlassian support. They removed the repo for me.


Tags: bitbucket-cloud

cloud

repository
How do I fix build error with '@sentry/react'
Asked by Alice Kim:

Whenever I try to implement Pipelines, I got this error message during npm build time.

\`Module not found: Error: Can't resolve '@sentry/react' in '/opt/atlassian/pipelines/agent/build/src'`

To fix this error, I put below command in bitbucket-pipelines.yml file but still build module not found error is happened.

\`\`\`  
- step:  
name: 'installing dependencies...'  
caches:  
- node  
script:  
- rm -r node_modules  
- npm install -g npm  
- npm install  
- step:  
name: 'Building project'  
caches:  
- node  
script:  
- CI=false npm run build  
artifacts:  
- build/\*\*

\`\`\`

How can I fix this module issue during pipeline work?

Build is working well in local environment and also Jenkins environment.


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

Which command is giving you this error? I assume it is the command **CI=false npm run build** ?

I see that you are installing dependencies in the previous step named '*installing dependencies...* '. Are these dependencies needed in order to run the build in the next step, '*Building project*'? If so, I would suggest building the project in the same step where you install the dependencies, and then checking if that eliminates the error.

For every step in your bitbucket-pipelines.yml file, a Docker container starts, your repo is cloned (unless you have disabled clone), then the commands of that step's script are executed, and afterwards the container gets destroyed. If you need any dependencies to run a build, they should be installed in the same step that uses them.

I see that you are using node cache, but please keep in mind that (1) caches are saved after the first successful build, and (2) caches are cleared automatically after 1 week and repopulated during the next successful build. Therefore, builds should be configured to work whether or not the cache is present.

Kind regards,  
Theodora

comments: author: Alice Kim
body: I don't know why it is working now but it works.

Thank you for your kindful answer. ?

Later if it is not working then I'll try your suggestion!


Tags: bitbucket-pipelines

build
bitbucket.org gives 502 Bad Gateway
Asked by Samet Akp?nar:

Bitbucket website has been throwing "502 Bad Gateway" since 2-3 hours ago.


Answers:
author: Alex Koxaras _Relational_
body: Hi [@Samet Akp?nar](/t5/user/viewprofilepage/user-id/4733477)

There is an outage on bitbucket. More info here <https://bitbucket.status.atlassian.com/>


author: Peter Van de Voorde
body: Hi Samet,  

Atlassian is aware and working on it.   
You can find more information on their bitbucket statuspage: <https://bitbucket.status.atlassian.com/>  

Cheers,  
Peter


Tags: bitbucket-cloud

cloud
Bitbucket website is throwing a 502 error on the browser
Asked by Victor Machimana:

Bitbucket website is throwing a 502 error on the browser, I have clear cache and local data, I've tried reloading multiple times and navigating to the main home page, but I'm still getting 502 error


Answers:
author: Alex Koxaras _Relational_
body: Hi [@Victor Machimana](/t5/user/viewprofilepage/user-id/4636152)

There is currently an incident . Watch here <https://bitbucket.status.atlassian.com/>


Tags: bitbucket-cloud

cloud
Bitbucket is giving 502 Bad Gateway
Asked by Harvinder Singh:

when I try to open [bitbucket.org](https://bitbucket.org/) , it gives 502 bad gateway error message on the page


Answers:
author: Alex Koxaras _Relational_
body: Hi [@Harvinder Singh](/t5/user/viewprofilepage/user-id/5045737) and welcome to the community.

There is currently an incident <https://bitbucket.status.atlassian.com/>

comments: author: Shubham Thakur
body: Hi [@Alex Koxaras _Relational_](/t5/user/viewprofilepage/user-id/4150197) what was the cause of this outage?


author: Alex Koxaras _Relational_
body: [@Shubham Thakur](/t5/user/viewprofilepage/user-id/5045818) when Atlassian will find out, they will make an update on the status page about the cause.


author: Anil Patil
body: +1

comments: author: Anil Patil
body: Thanks for the update [@Alex Koxaras](/t5/user/viewprofilepage/user-id/1766141)


Tags: bitbucket-cloud

cloud
Push content of a JSON file as a PR Comment
Asked by Srinivas Aluka:

I am trying to post a comment with the content of JSON file(example: cat somefile.json) as a PR comment via rest API 2.0.

Any help can be appreciated

Thanks,

Srinivas Aluka


Answers:
author: Theodora Boudale
body: Hi [@Srinivas Aluka](/t5/user/viewprofilepage/user-id/5042387),

You will need to pass the content of the file in the data of the request and any new lines should be escaped.

For example, if the content of the JSON file is the following:

```
{
"a": "a",
"b": "b"
}
```

You can post it as a PR comment via API with a call like the following:

```
curl -u BitbucketUsername:AppPassword \
   -X POST "https://api.bitbucket.org/2.0/repositories/workspace-id/repo-slug/pullrequests/pr-id/comments" \
   --header 'Accept: application/json' \
   --header 'Content-Type: application/json' \
   --data '{"content":{"raw": "{  \n\"a\": \"a\",  \n \"b\": \"b\"  \n}"}}'
```

where

**BitbucketUsername** is the username of a Bitbucket account with access to the repo  
**AppPassword** is an app password for the account  
**workspace-id** is the workspace id of the workspace that owns the repo  
**pr-id** is the id of the PR where you want to post the comment

Please feel free to let me know if that works for you and if you have any questions

Kind regards,  
Theodora


Tags: bitbucket-cloud

cloud
502 Bad Gateway
Asked by Johnny Kikambi:

Hi ,

i don't understand why am getting Bad Gateway error. Please help resolve the problem.


Answers:
author: Alex Koxaras _Relational_
body: Hi [@Johnny Kikambi](/t5/user/viewprofilepage/user-id/4125789) and [@Andy Lo](/t5/user/viewprofilepage/user-id/2865180)

There is currently an open incident <https://bitbucket.status.atlassian.com/>


author: Peter Van de Voorde
body: Hi Johnny and Andy,  

Atlassian is aware and working on it.   
You can find more information on their bitbucket statuspage: <https://bitbucket.status.atlassian.com/>  

Cheers,  
Peter


author: Andy Lo
body: Same problem here.

comments: author: Johnny Kikambi
body: good to know i ain't sailing alone!


Tags: bitbucket-cloud

cloud
What would be the best way to install yarn on amazon/aws-cli:2.7.4 image?
Asked by Yusuf Doctor:

I need to deploy a serverless file but before deploying we need to run 'yarn install'. I have tried different ways to install yarn but keep facing errors.

Installing directly with yum doesn't work, it gives an error 'no package yarn found'

I tried installing using script but that also didn't work,  
- curl -sL <https://dl.yarnpkg.com/rpm/yarn.repo> -o /etc/yum.repos.d/yarn.repo  
- yum install yarn -y  
Is there a way to install without needing to install npm?


Answers:
author: Igor Stoyanov
body: [@Yusuf Doctor](/t5/user/viewprofilepage/user-id/4617225) hi. You can try to use [serverless-deploy pipe](https://bitbucket.org/atlassian/serverless-deploy/src/master/) with preexecution scripts.

Example passing preexecution hook script file (file should have at least read and execute permissions):  

```
script:  - echo 'npm install serverless-additional@2.*' > .my-script.sh  - chmod 005 my-script.sh  - pipe: atlassian/serverless-deploy:1.2.0    variables:      AWS_ACCESS_KEY_ID: $AWS_ACCESS_KEY_ID      AWS_SECRET_ACCESS_KEY: $AWS_SECRET_ACCESS_KEY      PRE_EXECUTION_SCRIPT: '.my-script.sh'
```

Regards, Igor


author: Yusuf Doctor
body: ![Screen Shot 2022-10-04 at 14.59.25.png](https://community.atlassian.com/t5/image/serverpage/image-id/219010iF43397DDD1AD38A8/image-size/large?v=v2&px=999 "Screen Shot 2022-10-04 at 14.59.25.png")


Tags: bitbucket-cloud

cloud
SourceTree setup does not start
Asked by AlinaBeelina:

When starting the SourceTree setup a small window is opening and closing again after less than a second. Although I am not able to go through the setup I get a 55Mb folder at AppData\\Local\\SourceTree including a SourceTree.exe . When opening this one nothing is happening. Both .exe files won't do something else when run as admin. I have already tried uninstalling, deleting the app data folders, restarting my computer, restarting the setup. Nothing happens. Hope that someone knows a way to fix this.


Answers:
author: Ana Retamal
body: Hi Jan, can you check the log and see if there's any error? You can also paste it here for us to take a look ;)

Please let us know also which version of Sourcetree are you using.

Cheers!

Ana

comments: author: AlinaBeelina
body: Thanks for your response.

I was trying to install the version 2.3.1.0, which was the one I downloaded from the main page of the SourceTree website.

I would love to share a log, but I don't know where to find it. There are several files called log4net at AppData\\Local\\SourceTree\\app-2.3.1\\ , but I believe that is not what you mean.

As I mentioned before I am not able to install it, so the AppData\\Local\\SourceTree\\ folder is the only thing I have besides the installer and a desktop link to the SourceTree.exe in that folder, which won't open, even as admin.


Tags: administration

windows
taking a pluralsight class on Sourcetree and teacher showing what looks to be useful: workspace...
Asked by Tien Le:

How do I enable this view? Thanks,

Tien.![sourcetree.workspaceView.howDoIEnableThisQm.PNG](/t5/image/serverpage/image-id/8450i000230FF9C8B214A/image-size/large?v=v2&px=999 "sourcetree.workspaceView.howDoIEnableThisQm.PNG")


Answers:
author: bgannin
body: That's an older version of the Windows application when it had a sidebar. The sidebar was replaced for a number of reasons with the "new tab" experience. We are aware that there's some missing functionality between the two and are looking into options for the future to restore them while retaining the benefits of our new design.

Brian Ganninger  
Senior Mac Developer, Sourcetree

comments: author: Tien Le
body: Thank you, Brian!


Tags: workspace
macOS High Sierra (10.13) preferences
Asked by Zsolt Balint:

After I installed macOS High Sierra, Sourcetree cannot keep track of my settings. It even forgets the window size, the toolbar elements and everything. I removed completely (delete the app and all the files/folders from \~/Library). For a day it was working and after 2 restarts it started to forget everything again. Is there any known bug here?


Answers:
author: bgannin
body: We're not aware of any bugs like this currently. We've not started on a High Sierra specific compatibility update yet, please file a ticket with details at <https://jira.atlassian.com/browse/SRCTREE> and we'll add it to the list to investigate for that release.

Brian Ganninger  
Senior Mac Developer, Sourcetree

comments: author: Zsolt Balint
body: Thanks [@bgannin](/t5/user/viewprofilepage/user-id/744444)! I already did this. I also added a comment, because in the meantime I discovered one more hint regarding this issue.


Tags: mac
number of pull requests not going down.
Asked by paaps:

Hello,  
I'm working on a project with a colleague, and he is always lacking behind in pulls/ pushes, he just doesn't push or pull during the week. We are currently at a stage where I have pushed A LOT , and he is \~25 pulls behind me. He tries to pull all the changes, and merge the files that need merging - the number of pulls is not going down for him. he tried refreshing the repo, restarting his pc. Any advice?


Answers:
author: Ana Retamal
body: Hi Folrikas, does this also happen when he uses the command line or only in Sourcetree?

Which Sourcetree and OS version is he using?

Cheers!

Ana

comments: author: paaps
body: only Sourcetree, and I think he uses the latest version, although i can check that
How to disable opening my home folder at startup?
Asked by Jan S.:

Every time I start Sourcetree it opens a tab for my home folder. This tab requires 10 seconds to load (and my system disk is a SSD and everything is in the file cache!).

During that time SourceTree is nearly unusable.

If I close the tab and restart SourceTree the home folder tab is there again.

**How to I permanently disable this annoying home folder tab!?**

BTW: Opening the home folder (not the document folder) is totally useless on Windows.


Answers:
author: Ana Retamal
body: Hi Jan Peter, is it possible that your Home directory became a repository by mistake?

To check this, go to your home directory and check if there's a ".git" folder (it will be hidden). You just need to delete the .git folder and Home shouldn't show up in Sourcetree anymore.

Let us know if this fixed your issue!

Regards,

Ana

comments: author: aajjss3
body: This solution worked for me, thanks.


author: Georgi Vladimirov Peev
body: **This is really important!**

The fix is the following ,when you open sourcetree and the Desktop,Home,USERNAME or whatever is opened just click Exporer (Right upper corner) and delete .git folder ,which is hidden by the way.

This solution also fixes the UNREAL amount of RAM even if you close the repository!


author: alsouza
body: hello guys.

In your directory you need enable to show hidden files, so you delete the folder named ".git" and the git files(ex: .gitignore). When you start your git again this folder will be ignored.

bye.


author: Jan S.
body: No there is no .git folder in my home directory (all hidden and system files are shown). Only a .hg directory but that only contains the global "hgrc" file, "sourcetreeconfig" and "thgstatus".

Anyway from my perspective this looks like a hard-coded behavior as it is opened every time even if I close the tab before restarting Sourcetree.

Anyway I am not satisfied with Sourcetree. It often hangs, shows the waiting spinner or similar problems so that I have to kill the Sourcetree process. It looks like Sourcetree has severe problems with Windows 10 and/or .Net 4.7 or my system config.

Additionally it has problems with the git authentication (putty key) which works perfectly in command-line git as well as TortoiseGit. As I only need Sourcetree for Git this is a big problem (for HG TortoiseHg is way better than SourceTree - faster and easier to use).

comments: author: stuart_fraser
body: Same is happening to me, my first thought was maybe it was something I did accidentally. But there is no branch in SourceTree or any .git files in my documents folder. I assume it's hanging as it's trying to scan the entire documents folder which probably has lots of and large files (if it's like mine.) This feels like a bug TBH.

I just tried updating to the latest version, suddenly it doesn't happen. I assume this was a bug in an old version. The whole thing is still pretty sluggish though.


author: doughb
body: Same thing happens to me on Windows 7. No .git directory


author: doughb
body: Turns out there was, in fact, a .git directory in my user directory. Deleted it, problem solved.


Tags: windows
wild card search not working as expected in SourceTree
Asked by Amit:

SourceTree version 2.3.1.0 under windows.

I have multiple files in Unstaged area and want to find all file with cpp extension. When I type \*.cpp in the search box, I don't get any result back. But if I type only cpp (without preceding dot) I get all the file which have cpp in their file name including file path.

My question is how do I search for file with a particular extension ? (e.g. \*.cpp)


Answers:
author: bgannin
body: Try skipping the wildcard character and simply search for .cpp by itself. Let us know if that's not the case and it still fails.

Cheers,

Brian Ganninger  
Senior Mac Developer, Sourcetree

comments: author: Amit
body: Thanks for reply.

I got it working by selecting Pending filed filter on the left.

Do you know if there is any documentation around how to use wild cards or regular expressions for filtering ?
SourceTree on Windows keeps showing "authentication via ssh keys failed"
Asked by Louis Qui Tran:

I am using the latest Version of SourceTree 2.3.1.0 on Windows.

- At PuTTY Key Generator dialog box, I click Load button to load my Git SSH key -\> Save private Key.

- I then do right-click on Pageant on system tray to Add key. It was successfully added.

After that I can work with sourceTree, like pull, push, etc.

But when ever I restart SourceTree, the SSH keys seems lost, and I have to repeat this process again.

Is there anyway to add a SSH key permanently? Thanks


Answers:
author: Ana Retamal
body: Hi Louis, do you have any keys loaded in your agent when you reboot your computer? You can check that using the command

    ssh-add -l

You can also try pushing or pulling using the command line right when you restart your computer and see if you get the same error. In that case the error won't be with Sourcetree btu with the SSH keys not being properly stored in your pc.

Let us know!

Ana

comments: author: Louis Qui Tran
body: Hi Ana, thanks for our reply. To answer your question: no, unfortunately, everytime I reboot my computer and SourceTree, there is no keys loaded in Pageant, even though it was there before.

The thing is, I still can pull, push, and everything with Git Bash. That means, SSH Keys is stored properly in my PC, isn't it.


Tags: authentication

windows
git describe in Sourcetree
Asked by Chris Harper:

Problem:

I would like to have instant access to the "git describe" description of a commit. When we have a compiled build, it's how we identify the associated source.

For those unfamiliar, it returns (for example): "v1.01-14-g1234abcd", in the format of {Closest Tag}-{Distance from Tag}-g{Hash}.

What I've tried:

I've tried adding a custom action, for script to run: "git", parameters: "describe --long --tags --always $SHA"

However, this opens a command line window that instantly closes. I'm sure I can work around that with a bash script, but it's really not the easy access I'm looking for.

Ideal:

Is there a way to add a new column in the Log/History viewer (with Graph, Descripton, Date, etc.) where it could show the result of the "git describe --long --tags --always $SHA" command?

Less ideal but good:

Can a custom command appear inside any docked window automatically?

Is there a way to make the "Custom Action" just post a return string in Sourcetree without launching a separate window? Even if "Show Full Output" is on, Sourectree just lists the command and adds "Completed successfully."


Answers:
author: bgannin
body: Custom actions are just commands that run in their own windows, much like the underlying Git or Mercurial ones.

The options you listed aren't currently possible, please vote on or file tickets in <https://jira.atlassian.com/SRCTREE> and/or <https://jira.atlassian.com/SRCTREEWIN>.

Brian Ganninger  
Senior Mac Developer, Sourcetree


Tags: description

git
Source tree cloning issue
Asked by sampath shetty:

When trying to Clone the SSH project git path to the Project Folder repository, The folder structure did not try to Clone to the git server.


Answers:
author: Ana Retamal
body: Hi Sampath, I'm afraid I don't fully understand what the problem is. Can you clarify a bit more so we can help you? Remember to include:

1. Which Sourcetree and OS version are you using?
2. Have you tried cloning from the command line? are you getting the same problem?
3. Screenshot of the error?

Best regards,

Ana
How to fix LF will be replaced with CRLF
Asked by TheLogan475:

I've been using sourcetree for some years and so far it's just worked with no problems. However last week it started coming up with this error:  

![Jfk_n1o_Rxi6CbpwGnlWNw](/t5/image/serverpage/image-id/8334i10C35F7541E8FD3B/image-size/large?v=v2&px=999 "Jfk_n1o_Rxi6CbpwGnlWNw")

As you can see it just goes on and on and on.  
I've googled and the only solution I've found is to set autocrlf to true.  
This doesn't work for me though.  
It's quite a problem as I can't really do anything in sourcetree at the moment, despite not having committed for over a week it says "nothing to commit", and then pops up a few more errors every time I alt+tab back to sourcetree.  
Does anyone have a solution for this? :)  

I've tried both re-installing sourcetree and rebooting my computer to no avail.


Answers:
author: TheLogan475
body: I just tried to put my screens in portrait mode and then drag the error window as far up as I could to see if there were any options buttons at the bottom, but there are just too many files being changed xD

comments: author: TheLogan475
body: Doh, that was meant as a comment, not an answer.  

Also another thing that strikes me as odd, I'm on a windows machine, the git repository is also on a windows computer (or at least I suspect microsoft would be running windows computers... ), so to my knowledge there are no unix machines involved in the process, yet many (if not all) files have been changed to UNIX style line ending..
Password Required dialog fails
Asked by ajs9:

I recently reformatted my Macbook's HD when upgrading to MacOS High Sierra. Since getting it set back up, I have been having problems accessing my Bitbucket repos using SourceTree.

I scoured the community and have tried everything suggested on previous similar issues, but none of them have worked.

My account is set up properly \& connected. I am using Oauth for my auth type \& https for my protocol. My account is connected.

I can see my repos listed when I click on remote but if I try to clone them, I get a dialog box:

Password Required  
For user \[my account id\] on host bitbucket.org

When I enter my account's password, it is rejected.

Help with this would be immensely appreciated. I am out of ideas here.


Answers:
author: Manju
body: Hi [@ajs9](/t5/user/viewprofilepage/user-id/1093260),

You shouldn't need to enter the password. Sourcetree should be able to use the OAuth token already stored. I'd recommend you to remove the account once, verify that keychain item for the bitbucket account is removed and add the account back afresh. If you still see issues, please enable debug logging by running following statement in the terminal and send us the logs.

```
defaults write com.torusknot.SourceTreeNotMAS logLevel 5
```


Tags: authentication

bitbucket

login

mac