youngmon/atlassian-qna huggingface dataset:
Stale ticket automation
Asked by Colby Cliffe:

Is this possible in Jira and if it is, how would I achieve it?  

*** ** * ** ***

If the ticket is in the "waiting for customer" or "pending" state for more than a week

and the last comment is one of the possible assignees

remind the reporter

if no response from the reporter for 5 days, close the ticket

*** ** * ** ***


Answers:
author: Paul Wiggers
body: Hello [@Colby Cliffe](/t5/user/viewprofilepage/user-id/5384869)

Thank you for your questions and yes, this is possible!

Here are the steps you will need to take:

1. Create a new SLA to keep track of the Waiting for Customer status and set a time goal that you want to trigger. In your case, a week.
2. Create an automation that checks for a SLA breach
3. Add an additional check to see if the author of the last comment is one of the possible assignee's. This might be tedious to maintain and I have skipped this logic since I don't really care who made the last comment. I am using an additional automation to change the status when a customer replies to an issue.
4. Add a public comment to the issue to remind them that they need to provide additional information
5. Create an additional automation that checks for an SLA breach longer than 5 days
6. Add a component to comment that the issue will be closed since there was no response
7. Transition the issue to the desired status
8. Enjoy!

Please let me know if this is something you can work with or if you would need additional information.


Tags: cloud

jira-service-management

jira-service-management-cloud
Edit description 'Raise this request on behalf of'
Asked by Evert Morren Atlas Admin:

Is it possible to edit the decription 'Raise this request on behalf of' on the portal. I want more explanation to the portal-user which email address they can use if they are forom outside the company.

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


Answers:
author: Marc - Devoteam
body: Hi [@Evert Morren Atlas Admin](/t5/user/viewprofilepage/user-id/4775056)

Just some clarification - only Agents will see that field. The thought is that someone might call the help desk or send and email and the Agent will enter the request on the behalf of the user.

Users coming directly to the Portal will not see that field in the form and their name will be automatically added as the Reporter of the Request/Ticket.

comments: author: Evert Morren Atlas Admin
body: Dear Marc,

Thanks for answering, you are right, I mde a mistake in the user groups.

Regards,

Evert


Tags: cloud

jira-service-management

jira-service-management-cloud
Automate adding a Component for when a specific Request Type is submitted
Asked by Martha Haley:

Hi. I want to create a rule that will automate populating an issue with a specific Component when a specific Request Type is submitted. Is this possible?

I got as far as setting up a rule where:

* Trigger: when an issue is created,
* Condition: Request Type = the specific request type I'm targeting,
* Action: then an action of Edit Issue fields, but not sure how to tell it that the edit is to add the specific component to the issue.

Thanks in advance for any assistance.


Answers:
author: Mikael Sandberg
body: You are on the right track, and in the edit issue action you select the components field and then it will allow you to pick from the list of components that you have in the project.

![Screenshot 2023-12-14 at 11.50.25?AM.png](https://community.atlassian.com/t5/image/serverpage/image-id/296906i9DA2CB6A2B6E75F3/image-dimensions/440x321?v=v2 "Screenshot 2023-12-14 at 11.50.25?AM.png")


Tags: cloud

jira-service-management

jira-service-management-cloud
do i know if a customer is using the help center?
Asked by Carla Gonzalez:

Most of my customers create requests by sending emails and the entire communication is done through emails.

However, they are also able to view the request in the help center, where they can turn notifications off/ resolve the issue, etc.

Is there any way for me to know if the customer is using the help center or using only emails?

Thanks in advance!


Answers:
author: Marcus Jones
body: Hi [@Carla Gonzalez](/t5/user/viewprofilepage/user-id/5219849) - Are you requiring your customers to log into the portal or is yours open and will accept anonymous requests?

If they are signing in, you can check status and last active to see if they have logged into the portal. If you log into the admin portal \> Products \> Your JSM Site and then navigate to Portal-only customers. You will be able to see if they have logged into your portal with last login date and timestamp.

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

Not the best solution for your problem, but may help.

comments: author: Carla Gonzalez
body: Hi [@Marcus Jones](/t5/user/viewprofilepage/user-id/5132701), thanks for the reply. Ours is open, anyone can submit a request through the portal. They do become customers in the system, with the following info:

![2023-12-15_15-12-27.png](https://community.atlassian.com/t5/image/serverpage/image-id/297079i57AC16D56BF09B45/image-size/large?v=v2&px=999 "2023-12-15_15-12-27.png")

However, I do not have the login date + timestamp. Is there a way to add these columns to my view?

I did realize that when the user has never used the portal, that list will report their email address. Once they sign into the portal, it'll report their username. So that'll give me an indication of whether they've ever signed into the portal, but not if they're using it for the request I'm actively trying to help them with.

Carla


Tags: cloud

jira-service-management

jira-service-management-cloud
Error while updating assets with dates via the REST API
Asked by DB:

When updating or creating assets with a date via the REST api I receive the following error.

```
Your code had an error! Traceback (most recent call last): File "<string>", line 110, in the_function File "<string>", line 39, in update_object Exception: Failed to update object. Status code: 400. Response text: {"errorMessages":[],"errors":{"rlabs-insight-attribute-211":"2024-18-09T00:00:00.000+00:00 is not valid (Date)"}}
```

What is the correct date format? I've tried:  
2024-18-09T00:00:00.000+00:00  
2024-18-09T00:00:00Z  
2024-18-09T00:00:00.000Z  
2024-18-09  
18-09-2024  
09-18-2024  
All result in the same issue. I can only find this article that suggests my date format is correct.  
<https://confluence.atlassian.com/jirakb/creating-asset-object-via-rest-api-fails-with-error-1223821596.html>  
I've also tested with a new Attribute using DateTime. This also doesn't work.  

```
Your code had an error! Traceback (most recent call last): File "<string>", line 110, in the_function File "<string>", line 39, in update_object Exception: Failed to update object. Status code: 400. Response text: {"errorMessages":[],"errors":{"rlabs-insight-attribute-247":"\"2024-09-18T00:00:00.000Z\" is not valid (DateTime)"}}
```

I've manually set the DateTime in the asset, copied the value that is returned for the DateTime value and it still fails.  

```
            "objectTypeAttributeId": "247",

            "objectAttributeValues": [

                {

                    "value": "2024-09-18T00:00:00.000Z",

                    "displayValue": "18/Sep/24 12:00 AM",

                    "searchValue": "2024-09-18T00:00:00.000Z",

                    "referencedType": false

                }

            ],

            "objectId": "7878"
```

I'm not sure if theres a bug in the Date and DateTime asset API or I'm making a very simple error. If I do not escape the quotes are the time it reports that its not serializable json, which is a bit odd...


Answers:
author: DB
body: There was actually a formatting issue with my json payload which was causing the date issue.


Tags: cloud

jira-service-management

jira-service-management-cloud
hide "notifications on/off" in help center
Asked by Carla Gonzalez:

Is there a way to hide the "notifications on/off" button in the help center?

![2023-12-14_14-26-51.png](/t5/image/serverpage/image-id/296900iD9723CEB7A9FBD55/image-size/large?v=v2&px=999 "2023-12-14_14-26-51.png")

If it's not possible, is there any way for me to know if the customer has disabled notifications?

Any help is appreciated!

Carla


Answers:
author: eugenio_onofre
body: Hello [@Carla Gonzalez](/t5/user/viewprofilepage/user-id/5219849)

Unfortunately there is no way to hide this option using Jira Default functionalities.  
About seeing if customer enabled/disabled notifications, you can check for it under "watchers" of the already created ticket.

Please remember to accept this answer in case it helps you resolve the issue as this may also help other community members!

Regards!

comments: author: Carla Gonzalez
body: Hi [@eugenio_onofre](/t5/user/viewprofilepage/user-id/5002338) , thanks for the reply.

We are using JSM as a support system for external clients, and while they get the automated replies + agent replies + can look at the conversation in the portal, i don't believe they are added as watchers to the issue.

![2023-12-19_10-16-53.png](https://community.atlassian.com/t5/image/serverpage/image-id/297409iBD535BF8C3B6CC9B/image-dimensions/215x182?v=v2 "2023-12-19_10-16-53.png")

I'm assuming this is specific to global Jira watcher settings?

Carla


author: eugenio_onofre
body: Hi [@Carla Gonzalez](/t5/user/viewprofilepage/user-id/5219849)

You can create an automation to have them added to the Watchers list if needed but, per default, it sets the user. A configuration may have been changed and causing it no to add the user as a Watcher.


author: Carla Gonzalez
body: Hi [@eugenio_onofre](/t5/user/viewprofilepage/user-id/5002338)

But I would only want to add people that are using the portal as the watcher, not the ones that are replying only by email. Not sure i can make that distinction in the automation?

I'll give it a try, thanks for your help!

Carla


Tags: cloud

jira-service-management

jira-service-management-cloud
Help copying the contents of one field into another when the form opens
Asked by Gary Holgate:

Hi

I am pretty new to Jira scripting and have a small issue.

I have a field that I would like to copy the contents into another custom field when the form opens.

Copy from: Live Text created as a custom field and used in 5 projects (Sales dept updated for AD)

Copy To: A single select field with approx 200 options. This is also the field that I reference in my project automations as the sales dept determines the actions taken.

I tried to apply the script on the behaviours initialization and a number of other placves but I cannot get the field to update.

Cheers

Gary


Answers:
author: Eugenio Onofre
body: Hi [@Gary Holgate](/t5/user/viewprofilepage/user-id/1539274)

I would suggest creating an automation and setting "Issue created" as the trigger. Please not you will not be able to populate the field in real time when the create issue form pops up.

My suggestion would be having this automation created and, when you open the edit issue form, the field will be already populated.

Please do not forget to accept this answer in case it helps you resolve your question so it can help other community members in the future.

Regards,  
Eugenio


Tags: cloud

jira-service-management

jira-service-management-cloud
i cant login to my bitbucket account
Asked by cozycactus:

is it deactivated?


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

We can't tell you that, it's up to your admins. We can't really really tell you anything about the problem - "I can't login" does not tell us anything - what are the error messages or other symptoms when you try to log in?


Tags: bitbucket-cloud

cloud
How do I deploy a Jar artifact to Bitbucket Staging deployment
Asked by Video Guy:

I have a pipeline runner that builds Java app and generates a Jar file.

I want to deploy it to common place so that testers and developers can download it.

I was looking at Yaml deployment step. I don't see anything like JFrog Artifactory to deploy to.

That makes me wonder if I am understanding the deployments in BitBucket right.


Answers:
author: Video Guy
body: Thanks Theodora!

I figured that I can add "artifacts:" to my yml then I would see "Artifacts" tab with tar zip of the files that I want to publish.

I figured a way to upload files using JFrong jf cli command too.


author: Theodora Boudale
body: Hi [@Video Guy](/t5/user/viewprofilepage/user-id/551282),

Jfrog has developed the following pipe which I believe can be used to upload artifacts to JFrog Artifactory:

* <https://bitbucket.org/jfrog/jfrog-setup-cli/src/master/>

The ReadMe file in that repo includes some examples of how to set it up and use it in your bitbucket-pipelines.yml file.

If you have any questions or issues with the configuration, I would suggest reaching out to JFrog support team, as this pipe is developed by them and not by Atlassian.

Kind regards,  
Theodora


Tags: artifactory

bitbucket-cloud

bitbucket-pipelines

bitbucket-runners

cloud

deployment
how to clone using HTTPS
Asked by Suprava Puhan:

how to change and clone using HTTPS


Answers:
author: Ben
body: Hey Suprava,

Bitbucket cloud recently stopped supporting the usage of basic GIT username/password authentication in favour of App Passwords.  
Therefore, you will need to make use of an App Password for communicating to GIT via HTTPS.  
We have documentation for usage of app passwords at the following link:  
<https://support.atlassian.com/bitbucket-cloud/docs/app-passwords/#Create-an-app-password>  
Essentially, when connecting via \*HTTPS\* you will use your AppPassword alongside your username seperated with a ":" character.  
Therefore if you are authenticating to \*GIT over HTTPS\* to push/pull you will need to update your remote URL's to include the \*AppPassword\*:

```
git remote set-url origin https://USERNAME:APP_PASSWORD@bitbucket.org/username/reposlug.git
```

The same applies when performing git clone:

```
git clone https://USERNAME:APP_PASSWORD@bitbucket.org/username/reposlug.git
```

Hope this helps.

Cheers!

- Ben (Bitbucket Cloud Support)


Tags: bitbucket-cloud

cloud
Bitbucket Cloud Rest API: Trace a PR to Deployment
Asked by Muffadal Hamid:

Hi All,

I want to calculate the lead time of a change i.e. amount of time between pr merged to develop and release.

I have explored the results "Get Deployment" \& "List \& Get PR" endpoints, but I am not able to trace PR to a deployment. I can see that in the UI but it is not obvious how to do it via that API. Can someone please shed some light on this topic? The docs for the rest APIs are pretty much useless.

Thanks,


Answers:
author: Patrik S
body: Hey [@Muffadal Hamid](/t5/user/viewprofilepage/user-id/4969797) ,

Thank you for reaching out to Atlassian Community.

I think the normal path to achieve this would be to call the **[Get Pull Request](https://developer.atlassian.com/cloud/bitbucket/rest/api-group-pullrequests/#api-repositories-workspace-repo-slug-pullrequests-pull-request-id-get)** endpoint, which would return the hash of the merge commit in the field **merge_commit** , and then query the [**List** **Deployments endpoint**](https://developer.atlassian.com/cloud/bitbucket/rest/api-group-deployments/#api-repositories-workspace-repo-slug-deployments-get) for this commit.

However, I'm afraid the Deployments endpoint currently does not support filtering, so you would not be able able to filter directly using the API. We have already a feature request to implement filtering/sorting to this endpoint :

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

I would suggest you to add your vote there and add yourself as a watcher in case you want to receive first-hand updates from that ticket.

As an alternative, until filtering is not implemented in that endpoint, you could use an external tool, like **jq**, to filter the returned deployments JSON for the merge commit. The caveat of this is that you would have to iterate through all the pages from the Deployments endpoint to get all the deployment records, before applying the filter in an external application.

Thank you [@Muffadal Hamid](/t5/user/viewprofilepage/user-id/4969797) ,

Kind regards,

Patrik S

comments: author: Muffadal Hamid
body: Thanks, [@Patrik S](/t5/user/viewprofilepage/user-id/4603309) for your response. Is there a report that I run on a weekly basis rather than using APIs?


author: Patrik S
body: Hey [@Muffadal Hamid](/t5/user/viewprofilepage/user-id/4969797) ,

I'm sorry to say there's currently no native Bitbucket report to trace PRs to a deployment.

There are, however, some third-party plugins on the [Marketplace](https://marketplace.atlassian.com/), such as [Awesome Graphs for Bitbucket](https://marketplace.atlassian.com/apps/1210934/awesome-graphs-for-bitbucket?tab=overview&hosting=cloud), that can provide you some reports/analyses on the repo, but I don't think they currently track deployments.

In this case, the way to get this information would be indeed through the public Bitbucket API, once the feature [BCLOUD-18729](https://jira.atlassian.com/browse/BCLOUD-18729) is implemented, and you can do filtering/querying in the deployments endpoint.

Kind regards,

Patrik S


Tags: bitbucket-cloud

cloud

rest-api
Application authorizations to sourcetree
Asked by Vasco Martins:

how do I re-authorise sourcetree to use with bitbucket since I removed the token in bitbucket and in my mac keychain but sourcetree doesn't prompt me to authorize it anymore !  
![Screenshot 2022-06-24 at 20.53.57.png](/t5/image/serverpage/image-id/203384i32DE422C5BC495E5/image-size/large?v=v2&px=999 "Screenshot 2022-06-24 at 20.53.57.png")  

Thank you very much in advance for the help.


Answers:
author: Ben
body: Hey Vasco,

The most common issue customers are experiencing related to HTTPS authentication in SourceTree is due to the deprecation of GIT username/password in favour of App Passwords:  
<https://bitbucket.org/blog/deprecating-atlassian-account-password-for-git-and-bitbucket-api-activity>  
We have a blog post however which explains the steps to troubleshoot this issue, please follow these accordingly and this should resolve the issue:  
<https://community.atlassian.com/t5/Sourcetree-articles/Bug-Fix-Sourcetree-for-Windows-authentication-error-when/ba-p/1965968>  
Hope this helps.  
Cheers!

- Ben (Bitbucket Cloud Support)


Tags: bitbucket-cloud

cloud

sourcetree
Bitbucket DIY backup (with postgres) fails on second execution
Asked by Dominik Kaspar:

I followed the official documentation on the [Bitbucket DIY Backup](https://confluence.atlassian.com/bitbucketserver/bitbucket-diy-backup-776640056.html) and managed to successfully run it to backup my PostgreSQL 14.3 database and the Bitbucket home. However, in a second execution the DIY script fails like this:

```
[bitbucket.diy-backup.sh:136 -> wait_for_bg_jobs][bb-001] ERROR: Database backup failed with status 1 (PID=25819)
[common.sh:138 -> unlock_bitbucket][bb-001] DEBUG: Running curl -L -s -f -u ******:****** http://localhost:7991/bitbucket/mvc/maintenance/lock?token=2ab330d0a9db44348d9c25d57e5f8d9fb102f421
[bitbucket.diy-backup.sh:139 -> cleanup_incomplete_backup][bb-001] DEBUG: Cleaning up after failed backup
[bitbucket.diy-backup.sh:0 -> main][bb-001] ERROR: Backing up Bitbucket failed
[common.sh:1 -> run_cleanup][bb-001] DEBUG: Running cleanup jobs...
```

When executing the pg_dump command alone, I see the problem: you cannot dump the database into the same directory (which already contains the first dump) a second time!

```
pg_dump -U bitbucketuser -h localhost --port=5432 -j 5 -Fd -d bitbucket --no-synchronized-snapshots -f /tmp/pg_dump
pg_dump: error: could not create directory "/tmp/pg_dump": File exists
```

My questions are now:

1. Is there any easy option to configure the DIY backup to clean the previous dump?
2. Why is Bitbucket still in maintenance mode after such an error!? It should get unlocked, but it's not! The Web UI keeps informing about "Performing backup - Backup is currently underway and shouldn't take long."


Answers:
author: Piotr Biegun _Gitprotect_io_
body: If you are looking for a more automated Bitbucket backup and recovery solution you should check [Gitprotect.io.](http://gitprotect.io)

We have an official app listed on the Atlassian marketplace it works both for Bitbucket Cloud and DC. [https://marketplace.atlassian.com/apps/1225728/gitprotect-io-backup-for-bitbucket?hosting=cloud\&tab=overview](https://marketplace.atlassian.com/apps/1225728/gitprotect-io-backup-for-bitbucket?hosting=cloud&tab=overview)  

<br />


author: Christian Glockner
body: Hi Dominik,

The DIY backup actually has a cleanup function defined in <https://bitbucket.org/atlassianlabs/atlassian-bitbucket-diy-backup/src/master/database-postgresql.sh#lines-52> by default it just runs an rm of the dump file - if that's not working as expected you may need to change or amend the function to delete the temporary file.

Cheers,

Christian

Premier Support Engineer

Atlassian


Tags: backup

bitbucket-server

server
How to configure bitbucket pipeline to publish a python package in GCP artifact registry
Asked by David Gomez Garcia:

Hello dears, I am new and if it is possible that you help me with the doubt of carrying out a publication process of a python package with the bitbucket pipeline in GCP artifact registry.


Answers:
author: Dam
body: Hi [@David Gomez Garcia](/t5/user/viewprofilepage/user-id/4973966)

Here is the documentation to push a python package in Google Cloud Platform using Bitbucket Pipelines: <https://support.atlassian.com/bitbucket-cloud/docs/deploy-to-google-cloud/>

I hope it helps.

Cheers,  
Dam.


Tags: bitbucket-cloud

bitbucket-pipelines

cloud

google
list and check the size of all feature branches
Asked by anil kumar K:

Hello,

Is there a way to list all feature branches in a project and also check the size of the same?

Thanks,

Anil


Answers:
author: Ben
body: Hey Anil,

Checking for a list of branches can be performed in git by matching a search pattern using the **git branch --list** command, this would not include the project as this is purely present in the UI and therefore git does not know about these.

For example, if the branch had "feature" in the title, the wildcard matches branches which start with "feature" followed by \* as a wildcard to match any text after this:

```
git branch --list 'feature*'
```

You could then capture the output of this command into a variable (for instance in bash) and then calculate the size of each branch returned from the above by using the git rev-list command:

```
git rev-list --disk-usage --objects HEAD..$branchname
```

Hope this helps.

Cheers!

- Ben (Bitbucket Cloud Support)


Tags: bitbucket-cloud

cloud
Cannot receive invitation mail
Asked by ???:

Hi,

My colleague is trying to add me to their new workspace, but I did receive any invitation letter. Any suggestion that I can do ?  

thank you


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

I checked the email of your community account in our system and it is not in any of our suppression lists.

I also checked our email logs for any emails sent from Atlassian to the same email address.  
I can see some Bitbucket Cloud invitations sent a few hours ago, and all these emails show to have been delivered to your mail server.

Could you please let me know if the invitation was sent to the same email as the email of your community account (the one you used to post this question)? Or was it sent to a different email address?

In case the invitations were sent to the email of your community account and you still haven't received them, I would suggest:

* checking your Spam folder, in case the emails ended up there
* checking if you have any filters that would make our emails skip your inbox
* talking with the administrator of your mail server, and asking them to check why our emails do not make it from your mail server to your inbox.

Kind regards,  
Theodora


Tags: bitbucket-cloud

cloud