A post function to add additional watchers fails

If we add additional watchers via a post function and the user has added a watcher the creation fails with the following error.

Error creating issue: Unable to update custom field customfield_10000 - Watchers in issue [new issue].

If the user leaves the watcher field blank then the issue creation is successful and the watchers are added.

We are using the append button and it still does not work. 

Any way around this?

2 answers

Maybe you should try to place your post function to the bottom of post functions list?

I have tried it putting it every where in the list. If the watchers field is left blank then it works fine but if the user adds a watcher the creation of the issue fails.

I found away around this by doing the following. It is a HACK but it works.

  1. Create another custom field. I called mine temp_watchers.
  2. Copy the value of watchers to temp_watchers
  3. Append the users you want to the temp_watchers field
  4. Clear the watchers field
  5. Copy the temp_watchers field to the watchers field
  6. clear the temp_watchers field.

Not pretty but it is working.

Suggest an answer

Log in or Sign up to answer
Community showcase
Published Mar 13, 2019 in Marketplace Apps

Marketplace Spotlight: Marketing apps for Confluence to keep your teams working on the same page


251 views 0 6
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you