Spaces:
Configuration error
Configuration error
Upload app.py with huggingface_hub
Browse files
app.py
CHANGED
|
@@ -305,6 +305,7 @@ EXAMPLES_QA = [
|
|
| 305 |
# ---------------------------------------------------------------------------
|
| 306 |
ZEROGPU_QUEUE_HINT = "No GPU was available after"
|
| 307 |
SPACES_PAGE_URL = "https://huggingface.co/spaces/vibesecurityguy/veris-classifier"
|
|
|
|
| 308 |
|
| 309 |
|
| 310 |
def _is_zerogpu_queue_timeout(err: Exception) -> bool:
|
|
@@ -599,6 +600,12 @@ def build_app() -> gr.Blocks:
|
|
| 599 |
login_btn = gr.LoginButton("Sign in with Hugging Face")
|
| 600 |
# Gradio 4.44 can miss auto-activation in some Spaces contexts.
|
| 601 |
login_btn.activate()
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 602 |
else:
|
| 603 |
gr.HTML("""
|
| 604 |
<div class="model-banner">
|
|
|
|
| 305 |
# ---------------------------------------------------------------------------
|
| 306 |
ZEROGPU_QUEUE_HINT = "No GPU was available after"
|
| 307 |
SPACES_PAGE_URL = "https://huggingface.co/spaces/vibesecurityguy/veris-classifier"
|
| 308 |
+
SPACE_HOST_URL = "https://vibesecurityguy-veris-classifier.hf.space"
|
| 309 |
|
| 310 |
|
| 311 |
def _is_zerogpu_queue_timeout(err: Exception) -> bool:
|
|
|
|
| 600 |
login_btn = gr.LoginButton("Sign in with Hugging Face")
|
| 601 |
# Gradio 4.44 can miss auto-activation in some Spaces contexts.
|
| 602 |
login_btn.activate()
|
| 603 |
+
gr.HTML(
|
| 604 |
+
f'<a href="{SPACE_HOST_URL}/login/huggingface" target="_top" '
|
| 605 |
+
'style="display:inline-block;padding:10px 14px;border-radius:8px;'
|
| 606 |
+
'border:1px solid #334155;color:#cbd5e1;text-decoration:none;font-weight:600;">'
|
| 607 |
+
"Direct sign-in (if button refreshes)</a>"
|
| 608 |
+
)
|
| 609 |
else:
|
| 610 |
gr.HTML("""
|
| 611 |
<div class="model-banner">
|