Skip to content
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

frontend: opt-in the log-detective.com button #3171

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions frontend/coprs_frontend/config/copr.conf
Original file line number Diff line number Diff line change
Expand Up @@ -203,6 +203,10 @@ HIDE_IMPORT_LOG_AFTER_DAYS = 14
# builds in database, otherwise implying rather expensive SQL queries).
#RECENT_BUILDS_ON_FRONTPAGE = False

# Whether we want to show the green "Feed Log-detective.com" button for
# failed builds. Currently only integrated with the Fedora Copr instance.
#LOG_DETECTIVE_BUTTON = False

Copy link
Member

Choose a reason for hiding this comment

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

Nitpick but I don't like the LOG_DETECTIVE_FEED name because of the "feed" part. It can be easily confused with a feed in the sense of RSS feed, news feed, social media feed, etc.

I'd prefer something like LOG_DETECTIVE, LOG_DETECTIVE_INTEGRATION, LOG_DETECTIVE_ENABLED, LOG_DETECTIVE_BUTTON.

Copy link
Member Author

Choose a reason for hiding this comment

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

Going with LOG_DETECTIVE_BUTTON then :) we can call it "_INTEGRATION" in the future once we have more "integration" than this.

#############################
##### DEBUGGING Section #####

Expand Down
1 change: 1 addition & 0 deletions frontend/coprs_frontend/coprs/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -196,6 +196,7 @@ class Config(object):

RECENT_BUILDS_ON_FRONTPAGE = False

LOG_DETECTIVE_BUTTON = False

class ProductionConfig(Config):
DEBUG = False
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ <h2 class="build-detail"> Build {{ build.id }} doesn't belong to this project. <
{% endif %}
{% endif %}

{% if build.state == "failed" %}
{% if config.LOG_DETECTIVE_BUTTON and build.state == "failed" %}
{{ copr_build_feed_log_detective(build, class="pull-right button-build-action") }}
{% endif %}

Expand Down
Loading