title: How do I discover the additional causes of my Jenkins build?
body: <p>When attempting to query a build using groovy, I call</p>
  
  <pre><code>myBuild.getCauses()
  </code></pre>
  
  <p>I can see in the interface of Jenkins (the build screen) that this build has two causes, a UserIdCause, and an UpstreamCause. However, when I interrogate the same build with the groovy above, I only get a single cause back, which is the UserIdCause. There must be some method of getting the UpstreamCause from the build, or it wouldn't be present in the user interface.</p>
  
  <p>I am using the Build Pipeline plugin to manually trigger the builds.</p>