Release 8.x
8.18.0
There are only core component changes in ScriptRunner for Bitbucket 8.18.0, so we do not have any new features or bug fixes to report.
8.17.0
New Example scripts modal
The Example scripts modal is your go-to destination for finding basic script examples (formerly snippets) and Library scripts without having to leave the ScriptRunner app. This modal replaces the Show snippet dropdown.
To access this modal, you can select the Example Scripts button in any code editor within ScriptRunner. Learn more about this new modal on the Example Scripts page.
Code editor refresh
In addition to the new Example Scripts modal, we have redesigned the code editor so it's even more user-friendly. We have moved the Help, Expand editor and Fullscreen buttons so they sit above the code editor and are easily accessible. We've also made the type checking dialog more prominent so you can easily see when there is an error with your code.
8.16.0
There are only core component changes in ScriptRunner for Bitbucket 8.16.0, so we do not have any new features or bug fixes to report.
8.15.0
There are only core component changes in ScriptRunner for Bitbucket 8.15.0, so we do not have any new features or bug fixes to report.
8.14.0
There are only core component changes in ScriptRunner for Bitbucket 8.14.0, so we do not have any new features or bug fixes to report.
8.13.0
There are only core component changes in ScriptRunner for Bitbucket 8.13.0, so we do not have any new features or bug fixes to report.
8.12.0
Bugs Fixed
We have fixed a bug affecting all previous versions of ScriptRunner for Bitbucket that presented a potential security vulnerability. The bug allowed the repository and project administrators to update the user information of other users, specifically in relation to avatars.
8.11.0
There are only core component changes in ScriptRunner for Bitbucket 8.11.0, so we do not have any new features or bug fixes to report.
8.10.0
There are only core component changes in ScriptRunner for Bitbucket 8.10.0, so we do not have any new features or bug fixes to report.
8.9.0
Script plugin bug fixed
We have resolved the known bug that was highlighted in the ScriptRunner for Bitbucket 8.8.0 release, which means that script plugins are working as expected.
UI update for Listeners, Jobs, and Fragments
The Note field has been updated to Name for Listeners, Jobs, and Fragments. It's also been given more prominence on those pages so you can easily identify your configurations.
New Features
Bugs Fixed
8.8.0
Script plugins update
We've done some work on the infrastructure supporting script plugins. As part of this, resources can now be exported and worked on in a script plugin.
Known bug
Currently, there is a bug that causes script plugins to fail to install or work in ScriptRunner for Bitbucket 8.8.0. If you are using script plugins, you should not upgrade until the fix we are working on is resolved. Other ScriptRunner products are unaffected.
Dynamic forms update
You can use optionsGenerator
within the select list annotation to customize your own list options. This is useful if you can't find a dynamic form annotation that is suitable for your purpose.
Bugs Fixed
8.7.0
Updated: Clone repository built-in script
We have updated the Clone repository built-in script. With this built-in script, you can clone the content of a repository, and/or clone the repository configuration, including permissions, hooks and the branch model. Previously you only had the option to close the repository configuration and not the content.
Having the option to clone the repository configuration and the content is useful when you need to generate new repositories with a consistent structure or setup. You can use any existing repository as a template to quickly and easily create new repositories that adhere to any standards you have in your organization.
New Features
8.6.0
New Features
Bugs Fixed
8.5.0
New Built-in Listener
The new Execution Failure Notifier allows you to listen for script execution failures in your instance and to notify you of the failure. Check out the Execution Failure Notifier page for more information.
New Merge Check: Require all comments are resolved
From version 8.9.0, Bitbucket introduced the ability to resolve comments. As is often the case, pull request authors fail to act on feedback provided as comments. This new merge check restricts the merge of a pull request until all the comments on that pull request have been resolved. This helps prevent accidentally missing out on comments and forces the user to act on every comment.
New Features
Bugs Fixed
8.4.0
Documentation update
We've added a Vulnerabilities and Security page to our documentation that provides you with details on how we scan for vulnerabilities and common security concerns.
The new Groovy 4 Breaking Change for Grab Annotations page has also been added, which includes some solutions/fixes. This identifies a breaking change in Groovy 4 that can impact those who use the @Grab
annotation to import certain external libraries.
Bugs Fixed
8.3.0
New Features
Bugs Fixed
8.2.1
Bugs Fixed
8.2.0
New Features
Bugs Fixed
8.1.0
New Features
Bugs Fixed
8.0.0
Groovy 4 update
We have updated ScriptRunner for Bitbucket to Groovy 4!
Our primary motivator for this update is to provide support for JDK 17. Groovy 3 doesn't support JDK 17, and with Jira 9.5.0 and Confluence 8.0 being JDK 17 compatible, an upgrade to Groovy 4 is necessary.
So, apart from JDK 17 compatibility, what comes with this update and how will it benefit you?
New features in Groovy 4
The following are the most significant new features that have been added in Groovy 4 :
- Switch expressions which, unlike switch statements, are optimised towards branches that handle one case and break out rather than fall through to the next case.
- Sealed types
- Records
- Ranges have been enhanced with support for ranges open on the left, for example,
3<..5
, or both sides, for example,0<..<3
- Support for annotating generic types, for example
List<@IntRange(min = 0, max = 10) Integer>
Please have a look at the Groovy 4 Release Notes for a complete list of new features.
Breaking changes in Groovy 4
Groovy 4 contains a number of breaking changes. The ones which are the most significant, and likely to affect ScriptRunner users, are listed below. Please have a look at the Groovy 4 Release Notes for a complete list of breaking changes.
1) Changes to the resolution of properties with both a getter and isser returning different types
An isser is a method to retrieve boolean properties. Instead of the method name starting with get
(as is common for accessor methods), it starts with is
. See the JavaBean Properties tutorial for more information.
For properties that have a getter and an isser returning different types (for example, JiraAuthenticationContext#getLoggedInUser and JiraAuthenticationContext#isLoggedInUser) when accessing the property, instead of calling one of the methods (for example, jiraAuthenticationContext.loggedInUser
), the getter is called in Groovy 3 but the isser is called in Groovy 4 - see GROOVY-10821.
Solution
From Groovy 4 if you have custom classes, or are using external classes that implement conflicting isser and getter methods, and you are using the property syntax to get the getter value, you must re-write the logic to use the getter method directly.
For example, this class demonstrates conflicting isser and getter methods:
class GetterIsser { String getSomething() { 'yes' } boolean isSomething() { false } } def myClass = new GetterIsser() myClass.something // used to return 'yes', as of Groovy 4 will return false
From Groovy 4, this should be written as:
class GetterIsser { String getSomething() { 'yes' } boolean isSomething() { false } } def myClass = new GetterIsser() myClass.getSomething() // will return 'yes'
2) Legacy package removal
Groovy 3 provided duplicate versions of numerous classes (in old and new packages) to allow Groovy users to migrate towards the new JPMS compliant package names - see the section about it in Groovy 3 Release Notes for more details. Groovy 4 no longer provides the duplicate legacy classes.
For backward compatibility reasons ScriptRunner still ships with deprecated version of groovy.util.XmlSlurper
and groovy.xml.XmlParser
. We recommend you don't use these legacy classes going forward and use their equivalents that can be found in groovy.xml
package.
3) Changes related to how Groovy code accesses private fields from within closures
Groovy developers are currently attempting to improve how their code accesses private fields in certain scenarios where such access is expected but problematic. For example, within closure definitions, where subclasses or inner classes are involved (GROOVY-5438). You may notice breakages in Groovy 4 code in such scenarios until they fix this issue.
4) Change to intersect
() default Groovy method
intersect()
default Groovy method used to draw elements from the second argument passed to it, but now it draws elements from the first argument passed to it - see GROOVY-10275.
JVM Flags
Important notice for Java 17 users
There is currently an omission in the Bitbucket archive that may cause compatibility issues with Java 17. You need to manually add the following JVM flags to avoid these issues:
java--add-opens java.base/java.lang.reflect=ALL-UNNAMED --add-opens java.base/java.io=ALL-UNNAMED
See this Resolution in Atlassian’s documentation for an example of how to add a JVM argument. Use this example as a guide to add the JVM flags listed above.
These flags are required to address module encapsulation introduced in Java 9 and later, which can cause issues when using reflection or accessing certain internal APIs. We are working closely with Atlassian to address this issue in future releases.
New Features
Bugs Fixed