com.atlassian.bamboo.repository.RepositoryDefinitionException: Job has task that uses source control but no repositories exists.

Atlassian JIRA | Rafael Sperafico [Atlassian] | 3 years ago
tip
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.
  1. 0

    h6. To reproduce the issue # Create a linked repository # Create a Deployment Plan and add an Environment "ENV1" ## Add a "{{Source Code Checkout}}" task and use the linked repository above created. # Run your deployment. # Clone the Environment "ENV1" by naming it as "ENV2" # Run the "ENV2" deployment by promoting the same release or generating a new one. The following message comes up: !bamboo560.noRepositoryExists.png|thumbnail! h6. Stacktrace {code} ... 2014-08-13 15:52:24,659 INFO [10-BAM::Default Agent::Agent:pool-25-thread-1] [DefaultErrorHandler] Recording an error: Error occurred while executing the build for Deployment of 'release-1.2' on 'ENV2' : 917505-983042 : Job has task that uses source control but no repositories exists. 2014-08-13 15:52:24,659 WARN [10-BAM::Default Agent::Agent:pool-25-thread-1] [BuildAgentControllerImpl] Error occurred while executing the build for Deployment of 'release-1.2' on 'ENV2' com.atlassian.bamboo.repository.RepositoryDefinitionException: Job has task that uses source control but no repositories exists. at com.atlassian.bamboo.repository.RepositoryFunctions$IdSelectorToRepositoryDefinition.apply(RepositoryFunctions.java:70) at com.atlassian.bamboo.repository.RepositoryFunctions$IdSelectorToRepositoryDefinition.apply(RepositoryFunctions.java:51) at com.atlassian.bamboo.task.repository.RepositoryTaskHelper.getRepositoryDefinitionByIdSelector(RepositoryTaskHelper.java:129) at com.atlassian.bamboo.v2.build.task.CheckoutDirectoriesSnapshotHelper.<init>(CheckoutDirectoriesSnapshotHelper.java:124) at com.atlassian.bamboo.v2.build.task.InitializeBuild.prepareWorkingDirectory(InitializeBuild.java:101) at com.atlassian.bamboo.v2.build.task.InitializeBuild.doCall(InitializeBuild.java:82) at com.atlassian.bamboo.v2.build.task.InitializeBuild.call(InitializeBuild.java:53) at com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent.build(DefaultBuildAgent.java:188) at com.atlassian.bamboo.v2.build.agent.BuildAgentControllerImpl.waitAndPerformBuild(BuildAgentControllerImpl.java:112) at com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent$1.run(DefaultBuildAgent.java:110) at com.atlassian.bamboo.utils.BambooRunnables$1.run(BambooRunnables.java:49) at com.atlassian.bamboo.security.ImpersonationHelper.runWith(ImpersonationHelper.java:31) at com.atlassian.bamboo.security.ImpersonationHelper.runWithSystemAuthority(ImpersonationHelper.java:20) at com.atlassian.bamboo.security.ImpersonationHelper$1.run(ImpersonationHelper.java:52) at java.lang.Thread.run(Thread.java:744) ... {code} h6. Workaround suggested # Edit you environment "ENV2" tasks and hit the "{{Save}}" button under the "{{Source Code Checkout}}" task.

    Atlassian JIRA | 3 years ago | Rafael Sperafico [Atlassian]
    com.atlassian.bamboo.repository.RepositoryDefinitionException: Job has task that uses source control but no repositories exists.
  2. 0

    h6. To reproduce the issue # Create a linked repository # Create a Deployment Plan and add an Environment "ENV1" ## Add a "{{Source Code Checkout}}" task and use the linked repository above created. # Run your deployment. # Clone the Environment "ENV1" by naming it as "ENV2" # Run the "ENV2" deployment by promoting the same release or generating a new one. The following message comes up: !bamboo560.noRepositoryExists.png|thumbnail! h6. Stacktrace {code} ... 2014-08-13 15:52:24,659 INFO [10-BAM::Default Agent::Agent:pool-25-thread-1] [DefaultErrorHandler] Recording an error: Error occurred while executing the build for Deployment of 'release-1.2' on 'ENV2' : 917505-983042 : Job has task that uses source control but no repositories exists. 2014-08-13 15:52:24,659 WARN [10-BAM::Default Agent::Agent:pool-25-thread-1] [BuildAgentControllerImpl] Error occurred while executing the build for Deployment of 'release-1.2' on 'ENV2' com.atlassian.bamboo.repository.RepositoryDefinitionException: Job has task that uses source control but no repositories exists. at com.atlassian.bamboo.repository.RepositoryFunctions$IdSelectorToRepositoryDefinition.apply(RepositoryFunctions.java:70) at com.atlassian.bamboo.repository.RepositoryFunctions$IdSelectorToRepositoryDefinition.apply(RepositoryFunctions.java:51) at com.atlassian.bamboo.task.repository.RepositoryTaskHelper.getRepositoryDefinitionByIdSelector(RepositoryTaskHelper.java:129) at com.atlassian.bamboo.v2.build.task.CheckoutDirectoriesSnapshotHelper.<init>(CheckoutDirectoriesSnapshotHelper.java:124) at com.atlassian.bamboo.v2.build.task.InitializeBuild.prepareWorkingDirectory(InitializeBuild.java:101) at com.atlassian.bamboo.v2.build.task.InitializeBuild.doCall(InitializeBuild.java:82) at com.atlassian.bamboo.v2.build.task.InitializeBuild.call(InitializeBuild.java:53) at com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent.build(DefaultBuildAgent.java:188) at com.atlassian.bamboo.v2.build.agent.BuildAgentControllerImpl.waitAndPerformBuild(BuildAgentControllerImpl.java:112) at com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent$1.run(DefaultBuildAgent.java:110) at com.atlassian.bamboo.utils.BambooRunnables$1.run(BambooRunnables.java:49) at com.atlassian.bamboo.security.ImpersonationHelper.runWith(ImpersonationHelper.java:31) at com.atlassian.bamboo.security.ImpersonationHelper.runWithSystemAuthority(ImpersonationHelper.java:20) at com.atlassian.bamboo.security.ImpersonationHelper$1.run(ImpersonationHelper.java:52) at java.lang.Thread.run(Thread.java:744) ... {code} h6. Workaround suggested # Edit you environment "ENV2" tasks and hit the "{{Save}}" button under the "{{Source Code Checkout}}" task.

    Atlassian JIRA | 3 years ago | Rafael Sperafico [Atlassian]
    com.atlassian.bamboo.repository.RepositoryDefinitionException: Job has task that uses source control but no repositories exists.

    Root Cause Analysis

    1. com.atlassian.bamboo.repository.RepositoryDefinitionException

      Job has task that uses source control but no repositories exists.

      at com.atlassian.bamboo.repository.RepositoryFunctions$IdSelectorToRepositoryDefinition.apply()
    2. com.atlassian.bamboo
      ImpersonationHelper$1.run
      1. com.atlassian.bamboo.repository.RepositoryFunctions$IdSelectorToRepositoryDefinition.apply(RepositoryFunctions.java:70)
      2. com.atlassian.bamboo.repository.RepositoryFunctions$IdSelectorToRepositoryDefinition.apply(RepositoryFunctions.java:51)
      3. com.atlassian.bamboo.task.repository.RepositoryTaskHelper.getRepositoryDefinitionByIdSelector(RepositoryTaskHelper.java:129)
      4. com.atlassian.bamboo.v2.build.task.CheckoutDirectoriesSnapshotHelper.<init>(CheckoutDirectoriesSnapshotHelper.java:124)
      5. com.atlassian.bamboo.v2.build.task.InitializeBuild.prepareWorkingDirectory(InitializeBuild.java:101)
      6. com.atlassian.bamboo.v2.build.task.InitializeBuild.doCall(InitializeBuild.java:82)
      7. com.atlassian.bamboo.v2.build.task.InitializeBuild.call(InitializeBuild.java:53)
      8. com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent.build(DefaultBuildAgent.java:188)
      9. com.atlassian.bamboo.v2.build.agent.BuildAgentControllerImpl.waitAndPerformBuild(BuildAgentControllerImpl.java:112)
      10. com.atlassian.bamboo.v2.build.agent.DefaultBuildAgent$1.run(DefaultBuildAgent.java:110)
      11. com.atlassian.bamboo.utils.BambooRunnables$1.run(BambooRunnables.java:49)
      12. com.atlassian.bamboo.security.ImpersonationHelper.runWith(ImpersonationHelper.java:31)
      13. com.atlassian.bamboo.security.ImpersonationHelper.runWithSystemAuthority(ImpersonationHelper.java:20)
      14. com.atlassian.bamboo.security.ImpersonationHelper$1.run(ImpersonationHelper.java:52)
      14 frames
    3. Java RT
      Thread.run
      1. java.lang.Thread.run(Thread.java:744)
      1 frame