-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #38 from fedecarboni7/dev
Dev
- Loading branch information
Showing
25 changed files
with
199 additions
and
51 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
import logging | ||
import os | ||
|
||
import colorlog | ||
|
||
# Configuración del colorlog | ||
handler = colorlog.StreamHandler() | ||
formatter = colorlog.ColoredFormatter( | ||
'%(log_color)s%(levelname)s%(white)s: %(message)s', | ||
log_colors={ | ||
'DEBUG': 'cyan', | ||
'INFO': 'green', | ||
'WARNING': 'yellow', | ||
'ERROR': 'red', | ||
'CRITICAL': 'red,bg_white', | ||
} | ||
) | ||
handler.setFormatter(formatter) | ||
|
||
# Configuración básica del logging | ||
logger = logging.getLogger() | ||
logging_level = os.getenv('LOGGING_LEVEL', 'INFO').upper() | ||
|
||
try: | ||
logger.setLevel(getattr(logging, logging_level)) | ||
except AttributeError: | ||
logger.setLevel(logging.INFO) | ||
|
||
logger.addHandler(handler) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,4 +5,5 @@ pytest==8.2.2 | |
SQLAlchemy==2.0.31 | ||
starlette==0.37.2 | ||
itsdangerous | ||
sqlalchemy-libsql | ||
sqlalchemy-libsql | ||
colorlog |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
File renamed without changes.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,81 @@ | ||
<!DOCTYPE html> | ||
<html lang="es"> | ||
<head> | ||
<meta charset="UTF-8"> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | ||
<title>Error 500 - Error del servidor</title> | ||
<link rel="apple-touch-icon" sizes="180x180" href="../static/favicon-v1.0/apple-touch-icon.png"> | ||
<link rel="icon" type="image/png" sizes="32x32" href="../static/favicon-v1.0/favicon-32x32.png"> | ||
<link rel="icon" type="image/png" sizes="16x16" href="../static/favicon-v1.0/favicon-16x16.png"> | ||
<link rel="manifest" href="../static/favicon-v1.0/site.webmanifest"> | ||
<style> | ||
body { | ||
display: flex; | ||
flex-direction: column; | ||
justify-content: center; | ||
align-items: center; | ||
height: 100vh; | ||
margin: 0; | ||
background-color: #f8d7da; | ||
color: #721c24; | ||
font-family: Arial, sans-serif; | ||
} | ||
.container { | ||
text-align: center; | ||
} | ||
.countdown { | ||
font-size: 1rem; | ||
font-weight: bold; | ||
margin-top: 10px; | ||
} | ||
.icon { | ||
font-size: 3rem; | ||
margin-bottom: 10px; | ||
} | ||
.message { | ||
margin-top: 20px; | ||
font-size: 1.2rem; | ||
} | ||
.contact-button { | ||
margin-top: 10px; | ||
padding: 10px 20px; | ||
font-size: 1rem; | ||
color: #ffffff; | ||
background-color: #721c24; | ||
border: none; | ||
border-radius: 5px; | ||
cursor: pointer; | ||
} | ||
.contact-button:hover { | ||
background-color: #d3d3d3; | ||
color: #721c24; | ||
} | ||
</style> | ||
</head> | ||
<body> | ||
<div class="container"> | ||
<h1>500 - Error del servidor</h1> | ||
<p>Lo sentimos, tuvimos un problema en el servidor.</p> | ||
<p>Serás redirigido al login en <span id="countdown" class="countdown">10</span> segundos...</p> | ||
<p class="message">Si sigues teniendo este problema, por favor comunícate con el creador del sitio.</p> | ||
<a href="mailto:fedecarboni7@gmail.com" class="contact-button">Enviar email</a> | ||
</div> | ||
<script> | ||
let countdownElement = document.getElementById('countdown'); | ||
let timeLeft = 10; // Tiempo en segundos | ||
|
||
function updateCountdown() { | ||
countdownElement.textContent = timeLeft; | ||
if (timeLeft <= 0) { | ||
window.location.href = '/login'; | ||
} else { | ||
timeLeft--; | ||
setTimeout(updateCountdown, 1000); // Actualiza cada segundo | ||
} | ||
} | ||
|
||
// Inicia el contador | ||
updateCountdown(); | ||
</script> | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.