Can't add new build configuration via Kotlin script
I'm using Kotlin configuration on TeamCity 2019.1 (build 65998). After editing the script, new configuration did not appear in the UI. Where should I start investigation of the problem?
Please sign in to leave a comment.
Hi Generalgda!
Thirst of all please check Versioned Settings page, in case of any error, a message should be displayed there. Also, please check teamcity-versioned-settings.log.
Could it be the cause that you created a build configuration but forget to add it to any project?
There are no any errors. The build configuration is in the project.
Can build configuration's uuid be the cause? I generated it locally. What is the right way to generate it?
Hi Generalgda,
any arbitrary string can be used. Having any random string of your own with a prefix for example works, provided that isn't in use for any other item.
In DSL API version v2018_1
`uuid`can be omitted, in this case, TeamCity infers it from theid. If you're adding a new build configuration could you please try to omit `uuid` and tell me if it helps?I made several things at once. Do not know which of them helped, but now new build config. has appeared:
1) created dummy build config from TeamCity UI
2) forced TC to commit changes -> it deleted all my Kotlin scripts and added a merged one in a single file
3) I reverted TC's changes and remove the uuid from desired configuration -> commit
4) the configuration appeared in the UI