From ef86a09ee8d8fc287b382cf9092af8726b44ceae Mon Sep 17 00:00:00 2001 From: Ariel Costas Guerrero Date: Mon, 17 Nov 2025 16:39:48 +0100 Subject: Drop support for Santiago de Compostela, add collection script --- .gitignore | 1 + .vscode/settings.json | 4 +- .../Controllers/SantiagoController.cs | 72 ------- src/delay_collector/.env.example | 16 ++ src/delay_collector/DB_SETUP.md | 71 +++++++ src/delay_collector/database.py | 125 ++++++++++++ src/delay_collector/delay-collector.service | 33 ++++ src/delay_collector/main.py | 218 +++++++++++++++++++++ src/delay_collector/pyproject.toml | 11 ++ src/delay_collector/schema.sql | 41 ++++ src/delay_collector/uv.lock | 142 ++++++++++++++ src/frontend/app/components/LineIcon.css | 30 --- src/frontend/app/data/LineColors.ts | 28 --- src/frontend/app/data/RegionConfig.ts | 22 +-- src/frontend/app/routes/settings.tsx | 7 - src/frontend/public/maps/styles/carto-dark.json | 32 --- src/frontend/public/maps/styles/carto-light.json | 34 ---- 17 files changed, 663 insertions(+), 224 deletions(-) delete mode 100644 src/Costasdev.Busurbano.Backend/Controllers/SantiagoController.cs create mode 100644 src/delay_collector/.env.example create mode 100644 src/delay_collector/DB_SETUP.md create mode 100644 src/delay_collector/database.py create mode 100644 src/delay_collector/delay-collector.service create mode 100644 src/delay_collector/main.py create mode 100644 src/delay_collector/pyproject.toml create mode 100644 src/delay_collector/schema.sql create mode 100644 src/delay_collector/uv.lock delete mode 100644 src/frontend/public/maps/styles/carto-dark.json delete mode 100644 src/frontend/public/maps/styles/carto-light.json diff --git a/.gitignore b/.gitignore index 8ed8f99..f74132c 100644 --- a/.gitignore +++ b/.gitignore @@ -1,6 +1,7 @@ # Typescript incremental build .tsbuildinfo *.tsbuildinfo +.env # Python __pycache__/ diff --git a/.vscode/settings.json b/.vscode/settings.json index ccafd3e..a9d4a09 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -18,7 +18,7 @@ "editor.defaultFormatter": "esbenp.prettier-vscode" }, "[json]": { - "editor.defaultFormatter": "esbenp.prettier-vscode" + "editor.defaultFormatter": "vscode.json-language-features" }, "[jsonc]": { "editor.defaultFormatter": "esbenp.prettier-vscode" @@ -33,7 +33,7 @@ "editor.defaultFormatter": "esbenp.prettier-vscode" }, "[python]": { - "editor.defaultFormatter": "charliermarsh.ruff", + "editor.defaultFormatter": "ms-python.autopep8", "editor.codeActionsOnSave": { "source.fixAll.ruff": "explicit", "source.organizeImports.ruff": "explicit" diff --git a/src/Costasdev.Busurbano.Backend/Controllers/SantiagoController.cs b/src/Costasdev.Busurbano.Backend/Controllers/SantiagoController.cs deleted file mode 100644 index 24ecab9..0000000 --- a/src/Costasdev.Busurbano.Backend/Controllers/SantiagoController.cs +++ /dev/null @@ -1,72 +0,0 @@ -using System.Text.Json; -using Costasdev.VigoTransitApi.Types; -using Microsoft.AspNetCore.Mvc; -using Microsoft.Extensions.Caching.Memory; - -namespace Costasdev.Busurbano.Backend.Controllers; - -[ApiController] -[Route("api/santiago")] -public class SantiagoController : ControllerBase -{ - private readonly IMemoryCache _cache; - private readonly HttpClient _httpClient; - - public SantiagoController(HttpClient http, IMemoryCache cache) - { - _cache = cache; - _httpClient = http; - } - - [HttpGet("GetStopEstimates")] - public async Task Run() - { - var argumentAvailable = Request.Query.TryGetValue("id", out var requestedStopIdString); - if (!argumentAvailable) - { - return BadRequest("Please provide a stop id as a query parameter with the name 'id'."); - } - - var argumentNumber = int.TryParse(requestedStopIdString, out var requestedStopId); - if (!argumentNumber) - { - return BadRequest("The provided stop id is not a valid number."); - } - - try - { - var obj = await _httpClient.GetFromJsonAsync( - $"https://app.tussa.org/tussa/api/paradas/{requestedStopId}"); - - if (obj is null) - { - return BadRequest("No response returned from the API, or whatever"); - } - - var root = obj.RootElement; - - List estimates = root - .GetProperty("lineas") - .EnumerateArray() - .Select(el => new StopEstimate( - el.GetProperty("sinoptico").GetString() ?? string.Empty, - el.GetProperty("nombre").GetString() ?? string.Empty, - el.GetProperty("minutosProximoPaso").GetInt32(), - 0 - )).ToList(); - - // Return only the estimates array, not the stop metadata - return new OkObjectResult(estimates); - } - catch (InvalidOperationException) - { - return BadRequest("Stop not found"); - } - } - - [HttpGet("GetStopTimetable")] - public async Task GetStopTimetable() - { - throw new NotImplementedException(); - } -} diff --git a/src/delay_collector/.env.example b/src/delay_collector/.env.example new file mode 100644 index 0000000..80ff054 --- /dev/null +++ b/src/delay_collector/.env.example @@ -0,0 +1,16 @@ +# Collection frequency in seconds (default: 30) +FREQUENCY_SECONDS=36 + +# PostgreSQL Database Configuration +DB_HOST=localhost +DB_PORT=5432 +DB_NAME=busurbano +DB_USER=postgres +DB_PASSWORD=your_password_here + +# Service hours (Madrid timezone) +# The collector will only run during these hours +SERVICE_START_HOUR=7 # Start at 7:00 AM +SERVICE_END_HOUR=23 # End at 11:30 PM +SERVICE_END_MINUTE=30 +SERVICE_TIMEZONE=Europe/Madrid diff --git a/src/delay_collector/DB_SETUP.md b/src/delay_collector/DB_SETUP.md new file mode 100644 index 0000000..fedfb93 --- /dev/null +++ b/src/delay_collector/DB_SETUP.md @@ -0,0 +1,71 @@ +# PostgreSQL Database Setup + +This document describes how to set up the PostgreSQL database for the delay collector. + +## Prerequisites + +- PostgreSQL 18 +- psql + +## Database Setup + +### 1. Create Database and User + +Connect to PostgreSQL as superuser: + +```bash +sudo -u postgres psql +``` + +Create database and user: + +```sql +-- Create database +CREATE DATABASE busurbano; + +-- Create user +CREATE USER busurbano_collector WITH PASSWORD 'your_secure_password'; + +-- Grant privileges +GRANT CONNECT ON DATABASE busurbano TO busurbano_collector; +\c busurbano +GRANT USAGE ON SCHEMA public TO busurbano_collector; +GRANT INSERT, SELECT ON ALL TABLES IN SCHEMA public TO busurbano_collector; +GRANT USAGE, SELECT ON ALL SEQUENCES IN SCHEMA public TO busurbano_collector; +ALTER DEFAULT PRIVILEGES IN SCHEMA public GRANT INSERT, SELECT ON TABLES TO busurbano_collector; +ALTER DEFAULT PRIVILEGES IN SCHEMA public GRANT USAGE, SELECT ON SEQUENCES TO busurbano_collector; +``` + +### 2. Create Schema + +Run the schema file: + +```bash +psql -U postgres -d busurbano -f schema.sql +``` + +Or from within psql: + +```sql +\c busurbano +\i schema.sql +``` + +## Configuration + +Update your `.env` file: + +```bash +cp .env.example .env +nano .env +``` + +Set the following: + +```env +DB_HOST=localhost +DB_PORT=5432 +DB_NAME=busurbano +DB_USER=busurbano_collector +DB_PASSWORD=your_secure_password +``` diff --git a/src/delay_collector/database.py b/src/delay_collector/database.py new file mode 100644 index 0000000..b3f58f0 --- /dev/null +++ b/src/delay_collector/database.py @@ -0,0 +1,125 @@ +"""Database module for storing delay observations.""" + +import os +from datetime import datetime +from typing import List, Dict + +import psycopg2 +from psycopg2.extras import execute_values + + +def get_connection(): + """Get a PostgreSQL database connection.""" + conn = psycopg2.connect( + host=os.getenv("DB_HOST", "localhost"), + port=int(os.getenv("DB_PORT", "5432")), + database=os.getenv("DB_NAME", "busurbano"), + user=os.getenv("DB_USER", "postgres"), + password=os.getenv("DB_PASSWORD", "") + ) + return conn + + +def insert_observations( + observations: List[Dict], + stop_code: int, + observed_at: datetime +) -> int: + """ + Insert delay observations into the database. + + Args: + observations: List of observation dicts with keys: + line, route, service_id, trip_id, running, scheduled_minutes, real_time_minutes + stop_code: The stop code where observations were made + observed_at: The datetime when observations were collected + + Returns: + Number of records inserted + """ + if not observations: + return 0 + + conn = get_connection() + try: + cursor = conn.cursor() + + insert_sql = """ + INSERT INTO delay_observations ( + observed_at, + stop_code, + line, + route, + service_id, + trip_id, + running, + scheduled_minutes, + real_time_minutes + ) VALUES %s + """ + + records = [ + ( + observed_at, + stop_code, + obs["line"], + obs["route"], + obs["service_id"], + obs["trip_id"], + obs["running"], + obs["scheduled_minutes"], + obs["real_time_minutes"], + ) + for obs in observations + ] + + execute_values(cursor, insert_sql, records) + conn.commit() + return len(records) + finally: + cursor.close() + conn.close() + + +def get_statistics() -> Dict: + """Get basic statistics about the collected data.""" + conn = get_connection() + cursor = conn.cursor() + try: + # Total observations + cursor.execute("SELECT COUNT(*) as total FROM delay_observations") + result = cursor.fetchone() + total = result[0] if result else 0 + + # Date range + cursor.execute( + """ + SELECT + MIN(observed_at) as first_observation, + MAX(observed_at) as last_observation + FROM delay_observations + """ + ) + date_range = cursor.fetchone() + + # Unique stops and lines + cursor.execute( + """ + SELECT + COUNT(DISTINCT stop_code) as unique_stops, + COUNT(DISTINCT line) as unique_lines + FROM delay_observations + """ + ) + unique_counts = cursor.fetchone() + + return { + "total_observations": total, + "first_observation": str(date_range[0]) if date_range and date_range[0] else None, + "last_observation": str(date_range[1]) if date_range and date_range[1] else None, + "unique_stops": unique_counts[0] if unique_counts else 0, + "unique_lines": unique_counts[1] if unique_counts else 0, + } + finally: + cursor.close() + conn.close() diff --git a/src/delay_collector/delay-collector.service b/src/delay_collector/delay-collector.service new file mode 100644 index 0000000..926cc04 --- /dev/null +++ b/src/delay_collector/delay-collector.service @@ -0,0 +1,33 @@ +[Unit] +Description=Busurbano Delay Collector Service +After=network-online.target +Wants=network-online.target + +[Service] +Type=simple +User=app +Group=app +WorkingDirectory=/opt/delay_collector +EnvironmentFile=/opt/delay_collector/.env + +# Restart policy - always restart if it crashes +Restart=always +RestartSec=10 + +# Start the Python script +ExecStart=/usr/bin/python3 /opt/busurbano/delay_collector/main.py + +# Logging +StandardOutput=journal +StandardError=journal +SyslogIdentifier=delay-collector + +# Security hardening +NoNewPrivileges=true +PrivateTmp=true +ProtectSystem=strict +ProtectHome=true +ReadWritePaths=/opt/busurbano/delay_collector + +[Install] +WantedBy=multi-user.target diff --git a/src/delay_collector/main.py b/src/delay_collector/main.py new file mode 100644 index 0000000..cab6cf6 --- /dev/null +++ b/src/delay_collector/main.py @@ -0,0 +1,218 @@ +import os +import sys +from datetime import datetime +from time import sleep, time +from zoneinfo import ZoneInfo +import logging +from pathlib import Path + +import requests + +from database import insert_observations + + +STOP_CODES = [ + 14227, # (Torrecedeira 86) + 8460, # (Torrecedeira 105) + 20206, # (Marqués Valladares ft. 19) + 14264, # (Urzáiz-Príncipe) + 8770, # (Urzáiz, 13) + 5610, # (Gran Vía, 12) + 5660, # (Gran Vía, 19) + 6940, # (Praza América 3) + 2780, # (Camelias, 135) + 8630, # (Travesía 7) + 8610, # (Travesía 8) + 5410, # (Fragoso, 12) + 1360, # (Castrelos, 16) + 8040, # (Sanjurjo Badía, 167) + 14132, # (Sanjurjo Badía, 252) +] + +FREQUENCY_SECONDS = int(os.getenv("FREQUENCY_SECONDS", "30")) +SERVICE_START_HOUR = int(os.getenv("SERVICE_START_HOUR", "7")) # 7 AM +SERVICE_START_MINUTE = int(os.getenv("SERVICE_START_MINUTE", "00")) # 7 AM +SERVICE_END_HOUR = int(os.getenv("SERVICE_END_HOUR", "23")) # 11 PM +SERVICE_END_MINUTE = int(os.getenv("SERVICE_END_MINUTE", "00")) # 11:30 PM +SERVICE_TIMEZONE = os.getenv("SERVICE_TIMEZONE", "Europe/Madrid") + + +def setup_logging(): + """Configure logging for daemon operation.""" + # Configure logging to both file and console + logging.basicConfig( + level=logging.INFO, + format='%(asctime)s - %(levelname)s - %(message)s', + handlers=[ + logging.StreamHandler(sys.stdout) + ] + ) + return logging.getLogger(__name__) + + +def is_within_service_hours() -> bool: + """Check if current time is within configured service hours (Madrid time).""" + tz = ZoneInfo(SERVICE_TIMEZONE) + now = datetime.now(tz) + + current_hour = now.hour + current_minute = now.minute + + # Check if before start time + if current_hour < SERVICE_START_HOUR: + return False + if current_hour == SERVICE_START_HOUR and current_minute < SERVICE_START_MINUTE: + return False + + # Check if after end time + if current_hour > SERVICE_END_HOUR: + return False + if current_hour == SERVICE_END_HOUR and current_minute >= SERVICE_END_MINUTE: + return False + + return True + + +def wait_until_service_hours(logger): + """Wait until service hours begin.""" + tz = ZoneInfo(SERVICE_TIMEZONE) + + while not is_within_service_hours(): + now = datetime.now(tz) + logger.info( + f"Outside service hours (current time: {now.strftime('%H:%M %Z')}). Waiting...") + # Check every 5 minutes + sleep(300) + + +def download_consolidated_data(stop_code: int) -> list[dict]: + URL = f"https://busurbano.costas.dev/api/vigo/GetConsolidatedCirculations?stopId={stop_code}" + + response = requests.get(URL) + if response.status_code == 200: + return response.json() + else: + return [] + + +def get_consolidated_data(stop_code: int): + raw_data = download_consolidated_data(stop_code) + + processed_items = [] + for item in raw_data: + line = item.get("line") + route = item.get("route") + schedule = item.get("schedule", None) + real_time = item.get("realTime", None) + + # If either is missing, skip this item + if schedule is None or real_time is None: + continue + + processed_items.append( + { + "line": line, + "route": route, + "service_id": schedule.get("serviceId"), + "trip_id": schedule.get("tripId"), + "running": schedule.get("running", False), + "scheduled_minutes": schedule.get("minutes"), + "real_time_minutes": real_time.get("minutes"), + } + ) + + return processed_items + + +def main(): + """Main collection loop that continuously gathers and stores delay data.""" + # Setup logging + logger = setup_logging() + + # Log system time on startup + tz = ZoneInfo(SERVICE_TIMEZONE) + system_time = datetime.now(tz) + logger.info(f"=== Delay Collector Starting ===") + logger.info(f"System time: {system_time.strftime('%Y-%m-%d %H:%M:%S %Z')}") + logger.info( + f"Database: {os.getenv('DB_HOST', 'localhost')}:{os.getenv('DB_PORT', '5432')}/{os.getenv('DB_NAME', 'busurbano')}") + + # Calculate spacing between requests to evenly distribute them + # We want to complete all stops every FREQUENCY_SECONDS, so space them evenly + request_interval = FREQUENCY_SECONDS / len(STOP_CODES) + + logger.info(f"Monitoring {len(STOP_CODES)} stops") + logger.info(f"Collection cycle: {FREQUENCY_SECONDS} seconds (all stops)") + logger.info( + f"Request interval: {request_interval:.2f} seconds (between stops)") + logger.info( + f"Service hours: {SERVICE_START_HOUR}:00 - {SERVICE_END_HOUR}:{SERVICE_END_MINUTE:02d} {SERVICE_TIMEZONE}") + logger.info("Press Ctrl+C to stop\n") + + total_records = 0 + + try: + while True: + # Check if within service hours + if not is_within_service_hours(): + tz = ZoneInfo(SERVICE_TIMEZONE) + now = datetime.now(tz) + logger.info( + f"Outside service hours (current: {now.strftime('%H:%M %Z')}). Pausing collection.") + logger.info(f"Total records collected today: {total_records}") + + # Wait until service hours resume + wait_until_service_hours(logger) + logger.info("Service hours resumed. Resuming collection...") + # Reset daily counter + total_records = 0 + continue + + cycle_start = time() + + # Collect from each stop, evenly spaced + for stop_code in STOP_CODES: + request_start = time() + + try: + # Capture the exact time of observation + observed_at = datetime.now(ZoneInfo('UTC')) + + # Fetch and process data + data = get_consolidated_data(stop_code) + + # Store in database + if data: + records_inserted = insert_observations( + data, stop_code, observed_at) + total_records += records_inserted + logger.info( + f"Stop {stop_code}: {records_inserted} observations (Total today: {total_records})") + else: + logger.debug(f"Stop {stop_code}: No observations") + + except Exception as e: + logger.error(f"Error processing stop {stop_code}: {e}") + + # Sleep to maintain even spacing between requests + request_elapsed = time() - request_start + sleep_time = request_interval - request_elapsed + if sleep_time > 0: + sleep(sleep_time) + + # After completing all stops, wait if we finished early to maintain the cycle time + cycle_elapsed = time() - cycle_start + remaining_time = FREQUENCY_SECONDS - cycle_elapsed + if remaining_time > 0: + logger.debug( + f"Cycle completed in {cycle_elapsed:.1f}s, waiting {remaining_time:.1f}s") + sleep(remaining_time) + + except KeyboardInterrupt: + logger.info("\n=== Collection stopped by user ===") + logger.info(f"Total records collected: {total_records}") + sys.exit(0) + + +if __name__ == "__main__": + main() diff --git a/src/delay_collector/pyproject.toml b/src/delay_collector/pyproject.toml new file mode 100644 index 0000000..7d1c927 --- /dev/null +++ b/src/delay_collector/pyproject.toml @@ -0,0 +1,11 @@ +[project] +name = "delay-collector" +version = "0.1.0" +description = "Add your description here" +readme = "README.md" +requires-python = ">=3.13" +dependencies = [ + "psycopg2-binary>=2.9.11", + "requests>=2.32.5", + "tzdata>=2025.2", +] diff --git a/src/delay_collector/schema.sql b/src/delay_collector/schema.sql new file mode 100644 index 0000000..c16ecd3 --- /dev/null +++ b/src/delay_collector/schema.sql @@ -0,0 +1,41 @@ +-- Database schema for bus delay observations (PostgreSQL) +-- This stores real-time vs scheduled arrival data for analyzing delays +-- Partitioned by month for optimal performance with large datasets + +CREATE TABLE IF NOT EXISTS delay_observations ( + id BIGSERIAL NOT NULL, + observed_at TIMESTAMPTZ NOT NULL, + stop_code INTEGER NOT NULL, + line VARCHAR(10) NOT NULL, + route VARCHAR(100) NOT NULL, + service_id VARCHAR(50) NOT NULL, + trip_id VARCHAR(50) NOT NULL, + running BOOLEAN NOT NULL, + scheduled_minutes SMALLINT NOT NULL, + real_time_minutes SMALLINT NOT NULL, + delay_minutes SMALLINT GENERATED ALWAYS AS (real_time_minutes - scheduled_minutes) STORED, + PRIMARY KEY (id, observed_at) +) PARTITION BY RANGE (observed_at); + +-- Create initial partitions (monthly) +-- You should create new partitions before each month starts +CREATE TABLE IF NOT EXISTS delay_observations_2025_11 PARTITION OF delay_observations + FOR VALUES FROM ('2025-11-01') TO ('2025-12-01'); + +CREATE TABLE IF NOT EXISTS delay_observations_2025_12 PARTITION OF delay_observations + FOR VALUES FROM ('2025-12-01') TO ('2026-01-01'); + +CREATE TABLE IF NOT EXISTS delay_observations_2026_01 PARTITION OF delay_observations + FOR VALUES FROM ('2026-01-01') TO ('2026-02-01'); + +-- Indexes for efficient querying (created on parent table, applied to all partitions) +CREATE INDEX IF NOT EXISTS idx_observed_at ON delay_observations(observed_at DESC); +CREATE INDEX IF NOT EXISTS idx_stop_code ON delay_observations(stop_code); +CREATE INDEX IF NOT EXISTS idx_line ON delay_observations(line); +CREATE INDEX IF NOT EXISTS idx_trip_id ON delay_observations(trip_id, observed_at DESC); +CREATE INDEX IF NOT EXISTS idx_stop_line ON delay_observations(stop_code, line); +CREATE INDEX IF NOT EXISTS idx_running ON delay_observations(running) WHERE running = true; + +-- Partitioning by date for better performance (optional, uncomment if needed) +-- This requires converting to a partitioned table +-- ALTER TABLE delay_observations PARTITION BY RANGE (observation_date); diff --git a/src/delay_collector/uv.lock b/src/delay_collector/uv.lock new file mode 100644 index 0000000..df3b5ef --- /dev/null +++ b/src/delay_collector/uv.lock @@ -0,0 +1,142 @@ +version = 1 +revision = 3 +requires-python = ">=3.13" + +[[package]] +name = "certifi" +version = "2025.11.12" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/a2/8c/58f469717fa48465e4a50c014a0400602d3c437d7c0c468e17ada824da3a/certifi-2025.11.12.tar.gz", hash = "sha256:d8ab5478f2ecd78af242878415affce761ca6bc54a22a27e026d7c25357c3316", size = 160538, upload-time = "2025-11-12T02:54:51.517Z" } +wheels = [ + { url = "https://files.pythonhosted.org/packages/70/7d/9bc192684cea499815ff478dfcdc13835ddf401365057044fb721ec6bddb/certifi-2025.11.12-py3-none-any.whl", hash = "sha256:97de8790030bbd5c2d96b7ec782fc2f7820ef8dba6db909ccf95449f2d062d4b", size = 159438, upload-time = "2025-11-12T02:54:49.735Z" }, +] + +[[package]] +name = "charset-normalizer" +version = "3.4.4" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/13/69/33ddede1939fdd074bce5434295f38fae7136463422fe4fd3e0e89b98062/charset_normalizer-3.4.4.tar.gz", hash = "sha256:94537985111c35f28720e43603b8e7b43a6ecfb2ce1d3058bbe955b73404e21a", size = 129418, upload-time = "2025-10-14T04:42:32.879Z" } +wheels = [ + { url = "https://files.pythonhosted.org/packages/97/45/4b3a1239bbacd321068ea6e7ac28875b03ab8bc0aa0966452db17cd36714/charset_normalizer-3.4.4-cp313-cp313-macosx_10_13_universal2.whl", hash = "sha256:e1f185f86a6f3403aa2420e815904c67b2f9ebc443f045edd0de921108345794", size = 208091, upload-time = "2025-10-14T04:41:13.346Z" }, + { url = "https://files.pythonhosted.org/packages/7d/62/73a6d7450829655a35bb88a88fca7d736f9882a27eacdca2c6d505b57e2e/charset_normalizer-3.4.4-cp313-cp313-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl", hash = "sha256:6b39f987ae8ccdf0d2642338faf2abb1862340facc796048b604ef14919e55ed", size = 147936, upload-time = "2025-10-14T04:41:14.461Z" }, + { url = "https://files.pythonhosted.org/packages/89/c5/adb8c8b3d6625bef6d88b251bbb0d95f8205831b987631ab0c8bb5d937c2/charset_normalizer-3.4.4-cp313-cp313-manylinux2014_armv7l.manylinux_2_17_armv7l.manylinux_2_31_armv7l.whl", hash = "sha256:3162d5d8ce1bb98dd51af660f2121c55d0fa541b46dff7bb9b9f86ea1d87de72", size = 144180, upload-time = "2025-10-14T04:41:15.588Z" }, + { url = "https://files.pythonhosted.org/packages/91/ed/9706e4070682d1cc219050b6048bfd293ccf67b3d4f5a4f39207453d4b99/charset_normalizer-3.4.4-cp313-cp313-manylinux2014_ppc64le.manylinux_2_17_ppc64le.manylinux_2_28_ppc64le.whl", hash = "sha256:81d5eb2a312700f4ecaa977a8235b634ce853200e828fbadf3a9c50bab278328", size = 161346, upload-time = "2025-10-14T04:41:16.738Z" }, + { url = "https://files.pythonhosted.org/packages/d5/0d/031f0d95e4972901a2f6f09ef055751805ff541511dc1252ba3ca1f80cf5/charset_normalizer-3.4.4-cp313-cp313-manylinux2014_s390x.manylinux_2_17_s390x.manylinux_2_28_s390x.whl", hash = "sha256:5bd2293095d766545ec1a8f612559f6b40abc0eb18bb2f5d1171872d34036ede", size = 158874, upload-time = "2025-10-14T04:41:17.923Z" }, + { url = "https://files.pythonhosted.org/packages/f5/83/6ab5883f57c9c801ce5e5677242328aa45592be8a00644310a008d04f922/charset_normalizer-3.4.4-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:a8a8b89589086a25749f471e6a900d3f662d1d3b6e2e59dcecf787b1cc3a1894", size = 153076, upload-time = "2025-10-14T04:41:19.106Z" }, + { url = "https://files.pythonhosted.org/packages/75/1e/5ff781ddf5260e387d6419959ee89ef13878229732732ee73cdae01800f2/charset_normalizer-3.4.4-cp313-cp313-manylinux_2_31_riscv64.manylinux_2_39_riscv64.whl", hash = "sha256:bc7637e2f80d8530ee4a78e878bce464f70087ce73cf7c1caf142416923b98f1", size = 150601, upload-time = "2025-10-14T04:41:20.245Z" }, + { url = "https://files.pythonhosted.org/packages/d7/57/71be810965493d3510a6ca79b90c19e48696fb1ff964da319334b12677f0/charset_normalizer-3.4.4-cp313-cp313-musllinux_1_2_aarch64.whl", hash = "sha256:f8bf04158c6b607d747e93949aa60618b61312fe647a6369f88ce2ff16043490", size = 150376, upload-time = "2025-10-14T04:41:21.398Z" }, + { url = "https://files.pythonhosted.org/packages/e5/d5/c3d057a78c181d007014feb7e9f2e65905a6c4ef182c0ddf0de2924edd65/charset_normalizer-3.4.4-cp313-cp313-musllinux_1_2_armv7l.whl", hash = "sha256:554af85e960429cf30784dd47447d5125aaa3b99a6f0683589dbd27e2f45da44", size = 144825, upload-time = "2025-10-14T04:41:22.583Z" }, + { url = "https://files.pythonhosted.org/packages/e6/8c/d0406294828d4976f275ffbe66f00266c4b3136b7506941d87c00cab5272/charset_normalizer-3.4.4-cp313-cp313-musllinux_1_2_ppc64le.whl", hash = "sha256:74018750915ee7ad843a774364e13a3db91682f26142baddf775342c3f5b1133", size = 162583, upload-time = "2025-10-14T04:41:23.754Z" }, + { url = "https://files.pythonhosted.org/packages/d7/24/e2aa1f18c8f15c4c0e932d9287b8609dd30ad56dbe41d926bd846e22fb8d/charset_normalizer-3.4.4-cp313-cp313-musllinux_1_2_riscv64.whl", hash = "sha256:c0463276121fdee9c49b98908b3a89c39be45d86d1dbaa22957e38f6321d4ce3", size = 150366, upload-time = "2025-10-14T04:41:25.27Z" }, + { url = "https://files.pythonhosted.org/packages/e4/5b/1e6160c7739aad1e2df054300cc618b06bf784a7a164b0f238360721ab86/charset_normalizer-3.4.4-cp313-cp313-musllinux_1_2_s390x.whl", hash = "sha256:362d61fd13843997c1c446760ef36f240cf81d3ebf74ac62652aebaf7838561e", size = 160300, upload-time = "2025-10-14T04:41:26.725Z" }, + { url = "https://files.pythonhosted.org/packages/7a/10/f882167cd207fbdd743e55534d5d9620e095089d176d55cb22d5322f2afd/charset_normalizer-3.4.4-cp313-cp313-musllinux_1_2_x86_64.whl", hash = "sha256:9a26f18905b8dd5d685d6d07b0cdf98a79f3c7a918906af7cc143ea2e164c8bc", size = 154465, upload-time = "2025-10-14T04:41:28.322Z" }, + { url = "https://files.pythonhosted.org/packages/89/66/c7a9e1b7429be72123441bfdbaf2bc13faab3f90b933f664db506dea5915/charset_normalizer-3.4.4-cp313-cp313-win32.whl", hash = "sha256:9b35f4c90079ff2e2edc5b26c0c77925e5d2d255c42c74fdb70fb49b172726ac", size = 99404, upload-time = "2025-10-14T04:41:29.95Z" }, + { url = "https://files.pythonhosted.org/packages/c4/26/b9924fa27db384bdcd97ab83b4f0a8058d96ad9626ead570674d5e737d90/charset_normalizer-3.4.4-cp313-cp313-win_amd64.whl", hash = "sha256:b435cba5f4f750aa6c0a0d92c541fb79f69a387c91e61f1795227e4ed9cece14", size = 107092, upload-time = "2025-10-14T04:41:31.188Z" }, + { url = "https://files.pythonhosted.org/packages/af/8f/3ed4bfa0c0c72a7ca17f0380cd9e4dd842b09f664e780c13cff1dcf2ef1b/charset_normalizer-3.4.4-cp313-cp313-win_arm64.whl", hash = "sha256:542d2cee80be6f80247095cc36c418f7bddd14f4a6de45af91dfad36d817bba2", size = 100408, upload-time = "2025-10-14T04:41:32.624Z" }, + { url = "https://files.pythonhosted.org/packages/2a/35/7051599bd493e62411d6ede36fd5af83a38f37c4767b92884df7301db25d/charset_normalizer-3.4.4-cp314-cp314-macosx_10_13_universal2.whl", hash = "sha256:da3326d9e65ef63a817ecbcc0df6e94463713b754fe293eaa03da99befb9a5bd", size = 207746, upload-time = "2025-10-14T04:41:33.773Z" }, + { url = "https://files.pythonhosted.org/packages/10/9a/97c8d48ef10d6cd4fcead2415523221624bf58bcf68a802721a6bc807c8f/charset_normalizer-3.4.4-cp314-cp314-manylinux2014_aarch64.manylinux_2_17_aarch64.manylinux_2_28_aarch64.whl", hash = "sha256:8af65f14dc14a79b924524b1e7fffe304517b2bff5a58bf64f30b98bbc5079eb", size = 147889, upload-time = "2025-10-14T04:41:34.897Z" }, + { url = "https://files.pythonhosted.org/packages/10/bf/979224a919a1b606c82bd2c5fa49b5c6d5727aa47b4312bb27b1734f53cd/charset_normalizer-3.4.4-cp314-cp314-manylinux2014_armv7l.manylinux_2_17_armv7l.manylinux_2_31_armv7l.whl", hash = "sha256:74664978bb272435107de04e36db5a9735e78232b85b77d45cfb38f758efd33e", size = 143641, upload-time = "2025-10-14T04:41:36.116Z" }, + { url = "https://files.pythonhosted.org/packages/ba/33/0ad65587441fc730dc7bd90e9716b30b4702dc7b617e6ba4997dc8651495/charset_normalizer-3.4.4-cp314-cp314-manylinux2014_ppc64le.manylinux_2_17_ppc64le.manylinux_2_28_ppc64le.whl", hash = "sha256:752944c7ffbfdd10c074dc58ec2d5a8a4cd9493b314d367c14d24c17684ddd14", size = 160779, upload-time = "2025-10-14T04:41:37.229Z" }, + { url = "https://files.pythonhosted.org/packages/67/ed/331d6b249259ee71ddea93f6f2f0a56cfebd46938bde6fcc6f7b9a3d0e09/charset_normalizer-3.4.4-cp314-cp314-manylinux2014_s390x.manylinux_2_17_s390x.manylinux_2_28_s390x.whl", hash = "sha256:d1f13550535ad8cff21b8d757a3257963e951d96e20ec82ab44bc64aeb62a191", size = 159035, upload-time = "2025-10-14T04:41:38.368Z" }, + { url = "https://files.pythonhosted.org/packages/67/ff/f6b948ca32e4f2a4576aa129d8bed61f2e0543bf9f5f2b7fc3758ed005c9/charset_normalizer-3.4.4-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl", hash = "sha256:ecaae4149d99b1c9e7b88bb03e3221956f68fd6d50be2ef061b2381b61d20838", size = 152542, upload-time = "2025-10-14T04:41:39.862Z" }, + { url = "https://files.pythonhosted.org/packages/16/85/276033dcbcc369eb176594de22728541a925b2632f9716428c851b149e83/charset_normalizer-3.4.4-cp314-cp314-manylinux_2_31_riscv64.manylinux_2_39_riscv64.whl", hash = "sha256:cb6254dc36b47a990e59e1068afacdcd02958bdcce30bb50cc1700a8b9d624a6", size = 149524, upload-time = "2025-10-14T04:41:41.319Z" }, + { url = "https://files.pythonhosted.org/packages/9e/f2/6a2a1f722b6aba37050e626530a46a68f74e63683947a8acff92569f979a/charset_normalizer-3.4.4-cp314-cp314-musllinux_1_2_aarch64.whl", hash = "sha256:c8ae8a0f02f57a6e61203a31428fa1d677cbe50c93622b4149d5c0f319c1d19e", size = 150395, upload-time = "2025-10-14T04:41:42.539Z" }, + { url = "https://files.pythonhosted.org/packages/60/bb/2186cb2f2bbaea6338cad15ce23a67f9b0672929744381e28b0592676824/charset_normalizer-3.4.4-cp314-cp314-musllinux_1_2_armv7l.whl", hash = "sha256:47cc91b2f4dd2833fddaedd2893006b0106129d4b94fdb6af1f4ce5a9965577c", size = 143680, upload-time = "2025-10-14T04:41:43.661Z" }, + { url = "https://files.pythonhosted.org/packages/7d/a5/bf6f13b772fbb2a90360eb620d52ed8f796f3c5caee8398c3b2eb7b1c60d/charset_normalizer-3.4.4-cp314-cp314-musllinux_1_2_ppc64le.whl", hash = "sha256:82004af6c302b5d3ab2cfc4cc5f29db16123b1a8417f2e25f9066f91d4411090", size = 162045, upload-time = "2025-10-14T04:41:44.821Z" }, + { url = "https://files.pythonhosted.org/packages/df/c5/d1be898bf0dc3ef9030c3825e5d3b83f2c528d207d246cbabe245966808d/charset_normalizer-3.4.4-cp314-cp314-musllinux_1_2_riscv64.whl", hash = "sha256:2b7d8f6c26245217bd2ad053761201e9f9680f8ce52f0fcd8d0755aeae5b2152", size = 149687, upload-time = "2025-10-14T04:41:46.442Z" }, + { url = "https://files.pythonhosted.org/packages/a5/42/90c1f7b9341eef50c8a1cb3f098ac43b0508413f33affd762855f67a410e/charset_normalizer-3.4.4-cp314-cp314-musllinux_1_2_s390x.whl", hash = "sha256:799a7a5e4fb2d5898c60b640fd4981d6a25f1c11790935a44ce38c54e985f828", size = 160014, upload-time = "2025-10-14T04:41:47.631Z" }, + { url = "https://files.pythonhosted.org/packages/76/be/4d3ee471e8145d12795ab655ece37baed0929462a86e72372fd25859047c/charset_normalizer-3.4.4-cp314-cp314-musllinux_1_2_x86_64.whl", hash = "sha256:99ae2cffebb06e6c22bdc25801d7b30f503cc87dbd283479e7b606f70aff57ec", size = 154044, upload-time = "2025-10-14T04:41:48.81Z" }, + { url = "https://files.pythonhosted.org/packages/b0/6f/8f7af07237c34a1defe7defc565a9bc1807762f672c0fde711a4b22bf9c0/charset_normalizer-3.4.4-cp314-cp314-win32.whl", hash = "sha256:f9d332f8c2a2fcbffe1378594431458ddbef721c1769d78e2cbc06280d8155f9", size = 99940, upload-time = "2025-10-14T04:41:49.946Z" }, + { url = "https://files.pythonhosted.org/packages/4b/51/8ade005e5ca5b0d80fb4aff72a3775b325bdc3d27408c8113811a7cbe640/charset_normalizer-3.4.4-cp314-cp314-win_amd64.whl", hash = "sha256:8a6562c3700cce886c5be75ade4a5db4214fda19fede41d9792d100288d8f94c", size = 107104, upload-time = "2025-10-14T04:41:51.051Z" }, + { url = "https://files.pythonhosted.org/packages/da/5f/6b8f83a55bb8278772c5ae54a577f3099025f9ade59d0136ac24a0df4bde/charset_normalizer-3.4.4-cp314-cp314-win_arm64.whl", hash = "sha256:de00632ca48df9daf77a2c65a484531649261ec9f25489917f09e455cb09ddb2", size = 100743, upload-time = "2025-10-14T04:41:52.122Z" }, + { url = "https://files.pythonhosted.org/packages/0a/4c/925909008ed5a988ccbb72dcc897407e5d6d3bd72410d69e051fc0c14647/charset_normalizer-3.4.4-py3-none-any.whl", hash = "sha256:7a32c560861a02ff789ad905a2fe94e3f840803362c84fecf1851cb4cf3dc37f", size = 53402, upload-time = "2025-10-14T04:42:31.76Z" }, +] + +[[package]] +name = "delay-collector" +version = "0.1.0" +source = { virtual = "." } +dependencies = [ + { name = "psycopg2-binary" }, + { name = "requests" }, + { name = "tzdata" }, +] + +[package.metadata] +requires-dist = [ + { name = "psycopg2-binary", specifier = ">=2.9.11" }, + { name = "requests", specifier = ">=2.32.5" }, + { name = "tzdata", specifier = ">=2025.2" }, +] + +[[package]] +name = "idna" +version = "3.11" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/6f/6d/0703ccc57f3a7233505399edb88de3cbd678da106337b9fcde432b65ed60/idna-3.11.tar.gz", hash = "sha256:795dafcc9c04ed0c1fb032c2aa73654d8e8c5023a7df64a53f39190ada629902", size = 194582, upload-time = "2025-10-12T14:55:20.501Z" } +wheels = [ + { url = "https://files.pythonhosted.org/packages/0e/61/66938bbb5fc52dbdf84594873d5b51fb1f7c7794e9c0f5bd885f30bc507b/idna-3.11-py3-none-any.whl", hash = "sha256:771a87f49d9defaf64091e6e6fe9c18d4833f140bd19464795bc32d966ca37ea", size = 71008, upload-time = "2025-10-12T14:55:18.883Z" }, +] + +[[package]] +name = "psycopg2-binary" +version = "2.9.11" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/ac/6c/8767aaa597ba424643dc87348c6f1754dd9f48e80fdc1b9f7ca5c3a7c213/psycopg2-binary-2.9.11.tar.gz", hash = "sha256:b6aed9e096bf63f9e75edf2581aa9a7e7186d97ab5c177aa6c87797cd591236c", size = 379620, upload-time = "2025-10-10T11:14:48.041Z" } +wheels = [ + { url = "https://files.pythonhosted.org/packages/ff/a8/a2709681b3ac11b0b1786def10006b8995125ba268c9a54bea6f5ae8bd3e/psycopg2_binary-2.9.11-cp313-cp313-macosx_10_13_x86_64.whl", hash = "sha256:b8fb3db325435d34235b044b199e56cdf9ff41223a4b9752e8576465170bb38c", size = 3756572, upload-time = "2025-10-10T11:12:32.873Z" }, + { url = "https://files.pythonhosted.org/packages/62/e1/c2b38d256d0dafd32713e9f31982a5b028f4a3651f446be70785f484f472/psycopg2_binary-2.9.11-cp313-cp313-macosx_11_0_arm64.whl", hash = "sha256:366df99e710a2acd90efed3764bb1e28df6c675d33a7fb40df9b7281694432ee", size = 3864529, upload-time = "2025-10-10T11:12:36.791Z" }, + { url = "https://files.pythonhosted.org/packages/11/32/b2ffe8f3853c181e88f0a157c5fb4e383102238d73c52ac6d93a5c8bffe6/psycopg2_binary-2.9.11-cp313-cp313-manylinux2014_aarch64.manylinux_2_17_aarch64.whl", hash = "sha256:8c55b385daa2f92cb64b12ec4536c66954ac53654c7f15a203578da4e78105c0", size = 4411242, upload-time = "2025-10-10T11:12:42.388Z" }, + { url = "https://files.pythonhosted.org/packages/10/04/6ca7477e6160ae258dc96f67c371157776564679aefd247b66f4661501a2/psycopg2_binary-2.9.11-cp313-cp313-manylinux2014_ppc64le.manylinux_2_17_ppc64le.whl", hash = "sha256:c0377174bf1dd416993d16edc15357f6eb17ac998244cca19bc67cdc0e2e5766", size = 4468258, upload-time = "2025-10-10T11:12:48.654Z" }, + { url = "https://files.pythonhosted.org/packages/3c/7e/6a1a38f86412df101435809f225d57c1a021307dd0689f7a5e7fe83588b1/psycopg2_binary-2.9.11-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.whl", hash = "sha256:5c6ff3335ce08c75afaed19e08699e8aacf95d4a260b495a4a8545244fe2ceb3", size = 4166295, upload-time = "2025-10-10T11:12:52.525Z" }, + { url = "https://files.pythonhosted.org/packages/f2/7d/c07374c501b45f3579a9eb761cbf2604ddef3d96ad48679112c2c5aa9c25/psycopg2_binary-2.9.11-cp313-cp313-manylinux_2_38_riscv64.manylinux_2_39_riscv64.whl", hash = "sha256:84011ba3109e06ac412f95399b704d3d6950e386b7994475b231cf61eec2fc1f", size = 3983133, upload-time = "2025-10-30T02:55:24.329Z" }, + { url = "https://files.pythonhosted.org/packages/82/56/993b7104cb8345ad7d4516538ccf8f0d0ac640b1ebd8c754a7b024e76878/psycopg2_binary-2.9.11-cp313-cp313-musllinux_1_2_aarch64.whl", hash = "sha256:ba34475ceb08cccbdd98f6b46916917ae6eeb92b5ae111df10b544c3a4621dc4", size = 3652383, upload-time = "2025-10-10T11:12:56.387Z" }, + { url = "https://files.pythonhosted.org/packages/2d/ac/eaeb6029362fd8d454a27374d84c6866c82c33bfc24587b4face5a8e43ef/psycopg2_binary-2.9.11-cp313-cp313-musllinux_1_2_ppc64le.whl", hash = "sha256:b31e90fdd0f968c2de3b26ab014314fe814225b6c324f770952f7d38abf17e3c", size = 3298168, upload-time = "2025-10-10T11:13:00.403Z" }, + { url = "https://files.pythonhosted.org/packages/2b/39/50c3facc66bded9ada5cbc0de867499a703dc6bca6be03070b4e3b65da6c/psycopg2_binary-2.9.11-cp313-cp313-musllinux_1_2_riscv64.whl", hash = "sha256:d526864e0f67f74937a8fce859bd56c979f5e2ec57ca7c627f5f1071ef7fee60", size = 3044712, upload-time = "2025-10-30T02:55:27.975Z" }, + { url = "https://files.pythonhosted.org/packages/9c/8e/b7de019a1f562f72ada81081a12823d3c1590bedc48d7d2559410a2763fe/psycopg2_binary-2.9.11-cp313-cp313-musllinux_1_2_x86_64.whl", hash = "sha256:04195548662fa544626c8ea0f06561eb6203f1984ba5b4562764fbeb4c3d14b1", size = 3347549, upload-time = "2025-10-10T11:13:03.971Z" }, + { url = "https://files.pythonhosted.org/packages/80/2d/1bb683f64737bbb1f86c82b7359db1eb2be4e2c0c13b947f80efefa7d3e5/psycopg2_binary-2.9.11-cp313-cp313-win_amd64.whl", hash = "sha256:efff12b432179443f54e230fdf60de1f6cc726b6c832db8701227d089310e8aa", size = 2714215, upload-time = "2025-10-10T11:13:07.14Z" }, + { url = "https://files.pythonhosted.org/packages/64/12/93ef0098590cf51d9732b4f139533732565704f45bdc1ffa741b7c95fb54/psycopg2_binary-2.9.11-cp314-cp314-macosx_10_13_x86_64.whl", hash = "sha256:92e3b669236327083a2e33ccfa0d320dd01b9803b3e14dd986a4fc54aa00f4e1", size = 3756567, upload-time = "2025-10-10T11:13:11.885Z" }, + { url = "https://files.pythonhosted.org/packages/7c/a9/9d55c614a891288f15ca4b5209b09f0f01e3124056924e17b81b9fa054cc/psycopg2_binary-2.9.11-cp314-cp314-macosx_11_0_arm64.whl", hash = "sha256:e0deeb03da539fa3577fcb0b3f2554a97f7e5477c246098dbb18091a4a01c16f", size = 3864755, upload-time = "2025-10-10T11:13:17.727Z" }, + { url = "https://files.pythonhosted.org/packages/13/1e/98874ce72fd29cbde93209977b196a2edae03f8490d1bd8158e7f1daf3a0/psycopg2_binary-2.9.11-cp314-cp314-manylinux2014_aarch64.manylinux_2_17_aarch64.whl", hash = "sha256:9b52a3f9bb540a3e4ec0f6ba6d31339727b2950c9772850d6545b7eae0b9d7c5", size = 4411646, upload-time = "2025-10-10T11:13:24.432Z" }, + { url = "https://files.pythonhosted.org/packages/5a/bd/a335ce6645334fb8d758cc358810defca14a1d19ffbc8a10bd38a2328565/psycopg2_binary-2.9.11-cp314-cp314-manylinux2014_ppc64le.manylinux_2_17_ppc64le.whl", hash = "sha256:db4fd476874ccfdbb630a54426964959e58da4c61c9feba73e6094d51303d7d8", size = 4468701, upload-time = "2025-10-10T11:13:29.266Z" }, + { url = "https://files.pythonhosted.org/packages/44/d6/c8b4f53f34e295e45709b7568bf9b9407a612ea30387d35eb9fa84f269b4/psycopg2_binary-2.9.11-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.whl", hash = "sha256:47f212c1d3be608a12937cc131bd85502954398aaa1320cb4c14421a0ffccf4c", size = 4166293, upload-time = "2025-10-10T11:13:33.336Z" }, + { url = "https://files.pythonhosted.org/packages/4b/e0/f8cc36eadd1b716ab36bb290618a3292e009867e5c97ce4aba908cb99644/psycopg2_binary-2.9.11-cp314-cp314-manylinux_2_38_riscv64.manylinux_2_39_riscv64.whl", hash = "sha256:e35b7abae2b0adab776add56111df1735ccc71406e56203515e228a8dc07089f", size = 3983184, upload-time = "2025-10-30T02:55:32.483Z" }, + { url = "https://files.pythonhosted.org/packages/53/3e/2a8fe18a4e61cfb3417da67b6318e12691772c0696d79434184a511906dc/psycopg2_binary-2.9.11-cp314-cp314-musllinux_1_2_aarch64.whl", hash = "sha256:fcf21be3ce5f5659daefd2b3b3b6e4727b028221ddc94e6c1523425579664747", size = 3652650, upload-time = "2025-10-10T11:13:38.181Z" }, + { url = "https://files.pythonhosted.org/packages/76/36/03801461b31b29fe58d228c24388f999fe814dfc302856e0d17f97d7c54d/psycopg2_binary-2.9.11-cp314-cp314-musllinux_1_2_ppc64le.whl", hash = "sha256:9bd81e64e8de111237737b29d68039b9c813bdf520156af36d26819c9a979e5f", size = 3298663, upload-time = "2025-10-10T11:13:44.878Z" }, + { url = "https://files.pythonhosted.org/packages/97/77/21b0ea2e1a73aa5fa9222b2a6b8ba325c43c3a8d54272839c991f2345656/psycopg2_binary-2.9.11-cp314-cp314-musllinux_1_2_riscv64.whl", hash = "sha256:32770a4d666fbdafab017086655bcddab791d7cb260a16679cc5a7338b64343b", size = 3044737, upload-time = "2025-10-30T02:55:35.69Z" }, + { url = "https://files.pythonhosted.org/packages/67/69/f36abe5f118c1dca6d3726ceae164b9356985805480731ac6712a63f24f0/psycopg2_binary-2.9.11-cp314-cp314-musllinux_1_2_x86_64.whl", hash = "sha256:c3cb3a676873d7506825221045bd70e0427c905b9c8ee8d6acd70cfcbd6e576d", size = 3347643, upload-time = "2025-10-10T11:13:53.499Z" }, + { url = "https://files.pythonhosted.org/packages/e1/36/9c0c326fe3a4227953dfb29f5d0c8ae3b8eb8c1cd2967aa569f50cb3c61f/psycopg2_binary-2.9.11-cp314-cp314-win_amd64.whl", hash = "sha256:4012c9c954dfaccd28f94e84ab9f94e12df76b4afb22331b1f0d3154893a6316", size = 2803913, upload-time = "2025-10-10T11:13:57.058Z" }, +] + +[[package]] +name = "requests" +version = "2.32.5" +source = { registry = "https://pypi.org/simple" } +dependencies = [ + { name = "certifi" }, + { name = "charset-normalizer" }, + { name = "idna" }, + { name = "urllib3" }, +] +sdist = { url = "https://files.pythonhosted.org/packages/c9/74/b3ff8e6c8446842c3f5c837e9c3dfcfe2018ea6ecef224c710c85ef728f4/requests-2.32.5.tar.gz", hash = "sha256:dbba0bac56e100853db0ea71b82b4dfd5fe2bf6d3754a8893c3af500cec7d7cf", size = 134517, upload-time = "2025-08-18T20:46:02.573Z" } +wheels = [ + { url = "https://files.pythonhosted.org/packages/1e/db/4254e3eabe8020b458f1a747140d32277ec7a271daf1d235b70dc0b4e6e3/requests-2.32.5-py3-none-any.whl", hash = "sha256:2462f94637a34fd532264295e186976db0f5d453d1cdd31473c85a6a161affb6", size = 64738, upload-time = "2025-08-18T20:46:00.542Z" }, +] + +[[package]] +name = "tzdata" +version = "2025.2" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/95/32/1a225d6164441be760d75c2c42e2780dc0873fe382da3e98a2e1e48361e5/tzdata-2025.2.tar.gz", hash = "sha256:b60a638fcc0daffadf82fe0f57e53d06bdec2f36c4df66280ae79bce6bd6f2b9", size = 196380, upload-time = "2025-03-23T13:54:43.652Z" } +wheels = [ + { url = "https://files.pythonhosted.org/packages/5c/23/c7abc0ca0a1526a0774eca151daeb8de62ec457e77262b66b359c3c7679e/tzdata-2025.2-py2.py3-none-any.whl", hash = "sha256:1a403fada01ff9221ca8044d701868fa132215d84beb92242d9acd2147f667a8", size = 347839, upload-time = "2025-03-23T13:54:41.845Z" }, +] + +[[package]] +name = "urllib3" +version = "2.5.0" +source = { registry = "https://pypi.org/simple" } +sdist = { url = "https://files.pythonhosted.org/packages/15/22/9ee70a2574a4f4599c47dd506532914ce044817c7752a79b6a51286319bc/urllib3-2.5.0.tar.gz", hash = "sha256:3fc47733c7e419d4bc3f6b3dc2b4f890bb743906a30d56ba4a5bfa4bbff92760", size = 393185, upload-time = "2025-06-18T14:07:41.644Z" } +wheels = [ + { url = "https://files.pythonhosted.org/packages/a7/c2/fe1e52489ae3122415c51f387e221dd0773709bad6c6cdaa599e8a2c5185/urllib3-2.5.0-py3-none-any.whl", hash = "sha256:e6b01673c0fa6a13e374b50871808eb3bf7046c4b125b216f6bf1cc604cff0dc", size = 129795, upload-time = "2025-06-18T14:07:40.39Z" }, +] diff --git a/src/frontend/app/components/LineIcon.css b/src/frontend/app/components/LineIcon.css index 0b93023..721de76 100644 --- a/src/frontend/app/components/LineIcon.css +++ b/src/frontend/app/components/LineIcon.css @@ -64,36 +64,6 @@ --line-vigo-u1-text: #ffffff; --line-vigo-u2: rgb(172, 100, 4); --line-vigo-u2-text: #ffffff; - - --line-santiago-l1: #f32621; - --line-santiago-l4: #ffcc33; - --line-santiago-l5: #fa8405; - --line-santiago-l6: #d73983; - --line-santiago-l6a: #d73983; - --line-santiago-l7: #488bc1; - --line-santiago-l8: #6aaf48; - --line-santiago-l9: #46b8bb; - --line-santiago-c11: #aec741; - --line-santiago-l12: #842e14; - --line-santiago-l12-text: #ffffff; - --line-santiago-l13: #336600; - --line-santiago-l13-text: #ffffff; - --line-santiago-l15: #7a4b2a; - --line-santiago-l15-text: #ffffff; - --line-santiago-c2: #283a87; - --line-santiago-c2-text: #ffffff; - --line-santiago-c4: #283a87; - --line-santiago-c4-text: #ffffff; - --line-santiago-c5: #999999; - --line-santiago-c6: #006666; - --line-santiago-c6-text: #ffffff; - --line-santiago-p1: #537eb3; - --line-santiago-p2: #d23354; - --line-santiago-p3: #75bd96; - --line-santiago-p4: #f1c54f; - --line-santiago-p6: #999999; - --line-santiago-p7: #d2438c; - --line-santiago-p8: #e28c3a; } .line-icon { diff --git a/src/frontend/app/data/LineColors.ts b/src/frontend/app/data/LineColors.ts index 0d23211..f0599a3 100644 --- a/src/frontend/app/data/LineColors.ts +++ b/src/frontend/app/data/LineColors.ts @@ -53,32 +53,6 @@ const vigoLineColors: Record = { u2: { background: "rgb(172, 100, 4)", text: "#ffffff" }, }; -const santiagoLineColors: Record = { - l1: { background: "#f32621", text: "#ffffff" }, - l4: { background: "#ffcc33", text: "#000000" }, - l5: { background: "#fa8405", text: "#ffffff" }, - l6: { background: "#d73983", text: "#ffffff" }, - l6a: { background: "#d73983", text: "#ffffff" }, - l7: { background: "#488bc1", text: "#ffffff" }, - l8: { background: "#6aaf48", text: "#ffffff" }, - l9: { background: "#46b8bb", text: "#ffffff" }, - c11: { background: "#aec741", text: "#000000" }, - l12: { background: "#842e14", text: "#ffffff" }, - l13: { background: "#336600", text: "#ffffff" }, - l15: { background: "#7a4b2a", text: "#ffffff" }, - c2: { background: "#283a87", text: "#ffffff" }, - c4: { background: "#283a87", text: "#ffffff" }, - c5: { background: "#999999", text: "#000000" }, - c6: { background: "#006666", text: "#ffffff" }, - p1: { background: "#537eb3", text: "#ffffff" }, - p2: { background: "#d23354", text: "#ffffff" }, - p3: { background: "#75bd96", text: "#000000" }, - p4: { background: "#f1c54f", text: "#000000" }, - p6: { background: "#999999", text: "#000000" }, - p7: { background: "#d2438c", text: "#ffffff" }, - p8: { background: "#e28c3a", text: "#ffffff" }, -}; - const defaultLineColor: LineColorInfo = { background: "#d32f2f", text: "#ffffff", @@ -93,8 +67,6 @@ export function getLineColor( if (region === "vigo") { return vigoLineColors[formattedLine.toLowerCase().trim()] ?? defaultLineColor; - } else if (region === "santiago") { - return santiagoLineColors[formattedLine] ?? defaultLineColor; } return defaultLineColor; diff --git a/src/frontend/app/data/RegionConfig.ts b/src/frontend/app/data/RegionConfig.ts index 7722170..0c188ef 100644 --- a/src/frontend/app/data/RegionConfig.ts +++ b/src/frontend/app/data/RegionConfig.ts @@ -1,4 +1,4 @@ -export type RegionId = "vigo" | "santiago"; +export type RegionId = "vigo"; export interface RegionConfig { id: RegionId; @@ -33,23 +33,7 @@ export const REGIONS: Record = { textColour: "#e72b37", defaultZoom: 14, showMeters: true, - }, - santiago: { - id: "santiago", - name: "Santiago de Compostela", - stopsEndpoint: "/stops/santiago.json", - estimatesEndpoint: "/api/santiago/GetStopEstimates", - consolidatedCirculationsEndpoint: null, // Not available for Santiago - timetableEndpoint: null, // Not available for Santiago - defaultCenter: [42.8782, -8.5448], - bounds: { - sw: [-8.884454, 42.719102], - ne: [-8.243814, 43.02205], - }, - textColour: "#6bb238", - defaultZoom: 14, - showMeters: false, // Santiago doesn't provide distance data - }, + } }; export const DEFAULT_REGION: RegionId = "vigo"; @@ -63,5 +47,5 @@ export function getAvailableRegions(): RegionConfig[] { } export function isValidRegion(regionId: string): regionId is RegionId { - return regionId === "vigo" || regionId === "santiago"; + return regionId === "vigo"; } diff --git a/src/frontend/app/routes/settings.tsx b/src/frontend/app/routes/settings.tsx index 85ec5a1..d9c882d 100644 --- a/src/frontend/app/routes/settings.tsx +++ b/src/frontend/app/routes/settings.tsx @@ -190,13 +190,6 @@ export default function Settings() { .

)} - {region === "santiago" && ( -

- Datos obtenidos de app MaisBus (Concello de Santiago/TUSSA), gracias a - la documentación de [TP - Galicia](https://tpgalicia.github.io/urban/santiago/) en GitHub. -

- )} {showModal && (
diff --git a/src/frontend/public/maps/styles/carto-dark.json b/src/frontend/public/maps/styles/carto-dark.json deleted file mode 100644 index dbaa515..0000000 --- a/src/frontend/public/maps/styles/carto-dark.json +++ /dev/null @@ -1,32 +0,0 @@ -{ - "version": 8, - "name": "Light", - "sources": { - "carto": { - "type": "raster", - "tiles": ["https://d.basemaps.cartocdn.com/dark_all/{z}/{x}/{y}.png"], - "attribution": "© OpenStreetMap contributors, © CARTO", - "tileSize": 256, - "maxzoom": 22, - "minzoom": 0 - } - }, - "layers": [ - { - "id": "background", - "type": "background", - "paint": { - "background-color": "#f0f0f0" - } - }, - { - "id": "raster", - "type": "raster", - "source": "carto", - "minzoom": 0, - "maxzoom": 22 - } - ], - "sprite": "/maps/spritesheet/sprite", - "glyphs": "/maps/fonts/{fontstack}/{range}.pbf" -} diff --git a/src/frontend/public/maps/styles/carto-light.json b/src/frontend/public/maps/styles/carto-light.json deleted file mode 100644 index 563af6d..0000000 --- a/src/frontend/public/maps/styles/carto-light.json +++ /dev/null @@ -1,34 +0,0 @@ -{ - "version": 8, - "name": "Light", - "sources": { - "carto": { - "type": "raster", - "tiles": [ - "https://d.basemaps.cartocdn.com/rastertiles/voyager/{z}/{x}/{y}.png" - ], - "attribution": "© OpenStreetMap contributors, © CARTO", - "tileSize": 256, - "maxzoom": 22, - "minzoom": 0 - } - }, - "layers": [ - { - "id": "background", - "type": "background", - "paint": { - "background-color": "#f0f0f0" - } - }, - { - "id": "raster", - "type": "raster", - "source": "carto", - "minzoom": 0, - "maxzoom": 22 - } - ], - "sprite": "/maps/spritesheet/sprite", - "glyphs": "/maps/fonts/{fontstack}/{range}.pbf" -} -- cgit v1.3