-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
Refine PR Builder Code #5933
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
Refine PR Builder Code #5933
Changes from 9 commits
763b857
2537fc3
9e643dc
999070b
4f1709e
ce1353e
f84ee69
b1fe82f
8ed0345
290bab8
bf8247f
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -578,17 +578,24 @@ def run_build(self, docker, record): | |
|
||
if self.build_env.failed: | ||
self.send_notifications(self.version.pk, self.build['id']) | ||
# send build failure status to git Status API | ||
# if the build failed, send build failure status to git Status API | ||
# to show status report on the providers pull/merge request UI. | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is still just explaining what the code does. We can just remove these comments, we don't need to explain anything here. |
||
send_external_build_status( | ||
version=self.version, build_pk=self.build['id'], status=BUILD_STATUS_FAILURE | ||
) | ||
elif self.build_env.successful: | ||
# send build successful status to git Status API | ||
# if the build succeed, send build successful status to git Status API | ||
# to show status report on the providers pull/merge request UI. | ||
send_external_build_status( | ||
version=self.version, build_pk=self.build['id'], status=BUILD_STATUS_SUCCESS | ||
) | ||
else: | ||
msg = 'Unhandled Build Status' | ||
# if unhandled build status found, send build failure status to git Status API | ||
# to show status report on the providers pull/merge request UI. | ||
send_external_build_status( | ||
version=self.version, build_pk=self.build['id'], status=BUILD_STATUS_FAILURE | ||
) | ||
log.warning( | ||
LOG_TEMPLATE, | ||
{ | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -91,7 +91,11 @@ | |
{% endif %} | ||
</span> | ||
<span class="build-commit" data-bind="visible: commit"> | ||
{% if build.get_commit_url %} | ||
(<a data-bind="attr: {href: commit_url}"><span data-bind="text: commit">{{ build.commit }}</span></a>) | ||
{% else %} | ||
(<span data-bind="text: commit">{{ build.commit }}</span>) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Does this break the JS code that tries to update There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Okay I'll check this :) There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I have checked. there is no error on the browsers console window. and |
||
{% endif %} | ||
</span> | ||
</div> | ||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why are we calling
join
on a slug?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Opps! I was doing something else forgot to remove it sorry.