Skip to content

Setting default branch uses Version.slug instead of identifier #5032

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
humitos opened this issue Dec 24, 2018 · 0 comments
Closed

Setting default branch uses Version.slug instead of identifier #5032

humitos opened this issue Dec 24, 2018 · 0 comments
Labels
Accepted Accepted issue on our roadmap Bug A bug

Comments

@humitos
Copy link
Member

humitos commented Dec 24, 2018

Details

Expected Result

Build the branch set as default branch as when it's built as non default.

NOTE: the correct command here is git checkout --force origin/branch/with/slashes

Actual Result

The git checkout --force branch-with-slashes command fails because the branch does not exist.


Project.default_branch is saved in an improperly way.

>>> Version.objects.get(slug='branch-with-slashes').__dict__
...
 'type': 'branch',
 'identifier': 'origin/branch/with/slashes',
 'verbose_name': 'branch/with/slashes',
 'slug': 'branch-with-slashes',
>>> Version.objects.get(slug='branch-with-slashes').project.default_branch                                                                                                               
'branch-with-slashes'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Accepted Accepted issue on our roadmap Bug A bug
Projects
None yet
Development

No branches or pull requests

1 participant