Download setup_database.sql from Nithesharaja/Software_Bug_Assistant: direct link, hf CLI and curl.
- Browser
- Download file 5.11 kB
-
https://huggingface.co/spaces/Nithesharaja/Software_Bug_Assistant/resolve/main/setup_database.sql
- Command line
-
hf download hf://spaces/Nithesharaja/Software_Bug_Assistant/setup_database.sql
-
curl -L -o setup_database.sql https://huggingface.co/spaces/Nithesharaja/Software_Bug_Assistant/resolve/main/setup_database.sql
5.11 kB
| -- Connect to the postgres database (Supabase default) | |
| -- \c postgres; | |
| -- Enable pgvector extension (required for vector search) | |
| CREATE EXTENSION IF NOT EXISTS vector; | |
| -- Create the tickets table | |
| CREATE TABLE tickets ( | |
| ticket_id SERIAL PRIMARY KEY, -- PostgreSQL's auto-incrementing integer type (SERIAL is equivalent to INT AUTO_INCREMENT) | |
| title VARCHAR(255) NOT NULL, -- A concise summary or title of the bug/issue. | |
| description TEXT, -- A detailed description of the bug. | |
| assignee VARCHAR(100), -- The name or email of the person/team assigned to the ticket. | |
| priority VARCHAR(50), -- The priority level (e.g., 'P0 - Critical', 'P1 - High'). | |
| status VARCHAR(50) DEFAULT 'Open', -- The current status of the ticket (e.g., 'Open', 'In Progress', 'Resolved'). Default is 'Open'. | |
| creation_time TIMESTAMP WITH TIME ZONE DEFAULT CURRENT_TIMESTAMP, -- Timestamp when the ticket was first created. 'WITH TIME ZONE' is recommended for clarity and compatibility. | |
| updated_time TIMESTAMP WITH TIME ZONE DEFAULT CURRENT_TIMESTAMP, -- Timestamp when the ticket was last updated. Will be managed by a trigger. | |
| embedding vector(384) -- Vector embedding for semantic search (all-MiniLM-L6-v2) | |
| ); | |
| -- Insert sample data | |
| INSERT INTO tickets (title, description, assignee, priority, status) VALUES | |
| ('Login Page Freezes After Multiple Failed Attempts', 'Users are reporting that after 3 failed login attempts, the login page becomes unresponsive and requires a refresh. No specific error message is displayed.', 'samuel.green@example.com', 'P0 - Critical', 'Open'); | |
| INSERT INTO tickets (title, description, assignee, priority, status) VALUES | |
| ('Dashboard Sales Widget Intermittent Data Loading Failure', 'The "Sales Overview" widget on the main dashboard intermittently shows a loading spinner but no data. Primarily affects Chrome browser users.', 'maria.rodriguez@example.com', 'P1 - High', 'In Progress'); | |
| INSERT INTO tickets (title, description, assignee, priority, status) VALUES | |
| ('Broken Link in Footer - Privacy Policy', 'The "Privacy Policy" hyperlink located in the website footer leads to a 404 "Page Not Found" error.', 'maria.rodriguez@example.com', 'P3 - Low', 'Resolved'); | |
| INSERT INTO tickets (title, description, assignee, priority, status) VALUES | |
| ('UI Misalignment on Mobile Landscape View (iOS)', 'On specific iOS devices (e.g., iPhone 14 models), the top navigation bar shifts downwards when the device is viewed in landscape orientation, obscuring content.', 'maria.rodriguez@example.com', 'P2 - Medium', 'In Progress'); | |
| INSERT INTO tickets (title, description, assignee, priority, status) VALUES | |
| ('Critical XZ Utils Backdoor Detected in Core Dependency (CVE-2024-3094)', 'Urgent: A sophisticated supply chain compromise (CVE-2024-3094) has been identified in XZ Utils versions 5.6.0 and 5.6.1. This malicious code potentially allows unauthorized remote SSH access by modifying liblzma. Immediate investigation and action required for affected Linux/Unix systems and services relying on XZ Utils.', 'frank.white@example.com', 'P0 - Critical', 'Open'); | |
| INSERT INTO tickets (title, description, assignee, priority, status) VALUES | |
| ('Database Connection Timeouts During Peak Usage', 'The application is experiencing frequent database connection timeouts, particularly during peak hours (10 AM - 12 PM EDT), affecting all users and causing service interruptions.', 'frank.white@example.com', 'P1 - High', 'Open'); | |
| INSERT INTO tickets (title, description, assignee, priority, status) VALUES | |
| ('Export to PDF Truncates Long Text Fields in Reports', 'When generating PDF exports of reports containing extensive text fields, the text is abruptly cut off at the end of the page instead of wrapping or continuing to the next page.', 'samuel.green@example.com', 'P1 - High', 'Open'); | |
| INSERT INTO tickets (title, description, assignee, priority, status) VALUES | |
| ('Search Filter "Date Range" Not Applying Correctly', 'The "Date Range" filter on the search results page does not filter records accurately; results outside the specified date range are still displayed.', 'samuel.green@example.com', 'P2 - Medium', 'Resolved'); | |
| INSERT INTO tickets (title, description, assignee, priority, status) VALUES | |
| ('Typo in Error Message: "Unathorized Access"', 'The error message displayed when a user attempts an unauthorized action reads "Unathorized Access" instead of "Unauthorized Access."', 'maria.rodriguez@example.com', 'P3 - Low', 'Resolved'); | |
| INSERT INTO tickets (title, description, assignee, priority, status) VALUES | |
| ('Intermittent File Upload Failures for Large Files', 'Users are intermittently reporting that file uploads fail without a clear error message or explanation, especially for files exceeding 10MB in size.', 'frank.white@example.com', 'P1 - High', 'Open'); | |
| -- Verify the data was inserted | |
| SELECT COUNT(*) as total_tickets FROM tickets; | |
| SELECT ticket_id, title, status, priority FROM tickets LIMIT 5; | |