Skip to content

Conversation

Sai-Raveendra-Kandregula

Fixes #891

@@ -539,6 +539,13 @@ def get_scm_type(self):
if scm_element:
# multibranch pipeline.
self._scm_prefix = multibranch_scm_prefix
if not scm_element:
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Couldn't we change this to be an else for line 539?
Would you add test coverage for this?

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@clintonsteiner, I have updated the alternate scm_element fetch mechanism. Please check. As per the test coverage, I have added the test case for the change, but it seems like the Jenkins instance used in the tests does not have the Pipeline suite. Please advise on how to proceed.

@Sai-Raveendra-Kandregula Sai-Raveendra-Kandregula marked this pull request as draft April 24, 2025 03:21
@Sai-Raveendra-Kandregula Sai-Raveendra-Kandregula marked this pull request as ready for review April 24, 2025 03:32
@clintonsteiner
Copy link
Collaborator

Single test failures
FAILED jenkinsapi_tests/systests/test_job_pipeline_scm.py::test_pipeline_scm - jenkinsapi.custom_exceptions.JenkinsAPIException: Operation failed. url=http://localhost:50607/createItem?name=xthuwbefqg, data=



2

<hudson.plugins.git.UserRemoteConfig>
https://example.com/sairk/pipeline-test.git
</hudson.plugins.git.UserRemoteConfig>


<hudson.plugins.git.BranchSpec>
main
</hudson.plugins.git.BranchSpec>


@mwPandoraid
Copy link

any movement on this? this bug is blocking me right now

@Sai-Raveendra-Kandregula
Copy link
Author

any movement on this? this bug is blocking me right now

@mwPandoraid I am not completely familiar with these tests, and I don't have much time right so it is going to be a while before I can get all the tests to pass. Might I interest you in a workaround for the moment?

@mwPandoraid
Copy link

any movement on this? this bug is blocking me right now

@mwPandoraid I am not completely familiar with these tests, and I don't have much time right so it is going to be a while before I can get all the tests to pass. Might I interest you in a workaround for the moment?

I need to change the SCM branch using a script, pretty sure I can do that by editing the branch config XML directly so if this won't be fixed too soon I'll probably just do that

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

get_scm_type() throws NotSupportSCM for Standard Pipeline Jobs with SCM
3 participants