Open
Conversation
…endencies from the bqapi module
…->util submodules
…ssible after the fixes n temporary patches, need to fix main arguments
…g issues on mock request, session
…elated issues, resolved string encoding related issues during qouted() check, upgraded make_password and check_passwords for auth, resolved sqlalchemy mapper list related issues, resolved deprecated pylons.response related issues in core error controller
…source/legacy_upgraded
…w working without causing any issues
…ues and modified invalid test cases
… locks.py, resolved byte in path string related issues, resolved etree writing in a file issues, resolved some other issues, image service now seems to be working
…upload), updated all archiver codes from export service
Resolved broken archive issue in zip archiver Fixed unhandled multi-file compressed uploads with unordered filenames (blocked_alpha_num_sort) Added encoding to etree.tostring to resolve bytestring output issues Fixed bytestring filename issue in compressed download headers
Core Table Service Improvements: - Fix CSV format recognition by changing file mode from 'rb' to 'r' for Python 3 compatibility - Replace deprecated pandas as_matrix() with .values property for modern pandas support - Resolve Excel multi-tab data corruption with proper sheet selection flag implementation - Enhance column conversion for numeric column names in Excel sheets - Add proper range operation detection and processing (semicolon-based syntax: 0;499,;) - Fix Excel callback column bounds checking for variable sheet sizes - Remove xlrd dependency conflicts and simplify Excel engine selection Infrastructure and Plugin Fixes: - Resolve plugin loading compatibility issues across Python modules - Fix libtiff library dependency conflicts preventing proper image processing - Improve module import and dependency resolution mechanisms - Enhance error handling and validation across table operations - Address Python 2/3 compatibility issues in core components System Reliability and Performance: - Eliminate data corruption between Excel sheet operations - Prevent column index out of range errors during query processing - Ensure proper handling of various file formats and encodings - Maintain backward compatibility while supporting modern dependencies - Clean up temporary debug files and improve code maintainability Tested with multi-sheet Excel files, various CSV formats, plugin loading scenarios, and image processing workflows. Resolves critical issues preventing proper table data access, and plugin functionality.
…n with email verification This major update modernizes Bisque's email infrastructure and registration system: Email Service Modernization New Unified Email Service (bq.core.mail) - Replace deprecated TurboMail: Created modern EmailService class with unified SMTP configuration - Centralized configuration: Single configuration point for all email functionality - Multi-format support: HTML and plain text emails with template system - Robust error handling: Comprehensive logging and connection testing - Backward compatibility: Graceful fallback to legacy configurations during transition Configuration Updates - site.cfg: Added unified email configuration section with examples for Gmail, Outlook, AWS SES - Legacy support: Maintains compatibility with existing TurboMail/SMTP configurations - Service mounting: Fixed root controller service mounting with debug logging Enhanced User Registration System Extended Registration Controller - Rich user profiles: Support for research area, institution affiliation, funding agency - Multiple endpoints: JSON API, redirect-based, and fallback registration methods - Real-time validation: Username/email availability checking - Comprehensive validation: Research area and funding agency validation with predefined options Email Verification System - Optional verification: Configurable email verification for new registrations - Secure tokens: Cryptographically secure verification tokens with expiration - Template-based emails: Professional HTML/text verification emails - Graceful degradation: Auto-verification when email service unavailable - Admin tools: Configuration validation and SMTP testing endpoints Authentication Integration - Login enforcement: Email verification requirement integrated into auth service - User experience: Clear flash messages and verification status handling - Security: Prevents unverified users from accessing the system Service Integration Notification Service Updates - Unified email backend: Migrated from deprecated TurboMail to new email service - Improved reliability: Better error handling and logging for email notifications - Multiple recipient support: Enhanced email distribution capabilities Setup and Installation - Mail system detection: Updated installer to support unified email service - Configuration questions: New setup questions for modern email configuration - Legacy support: Maintains compatibility with existing mail configurations during migration Template and UI Improvements - Registration templates: Enhanced UI with email verification status indicators - Verification pages: New templates for email verification and resend functionality - User feedback: Clear messaging about verification requirements and status - Responsive design: Improved styling for registration and verification pages Technical Improvements - Import safety: Conditional imports prevent system failures during service loading - Database integration: Proper tag-based storage for verification tokens and user metadata - Error recovery: Graceful handling of email service failures with appropriate fallbacks - Debugging support: Comprehensive logging for troubleshooting email and registration issues Migration Path - Zero-downtime: Existing installations continue working with legacy configurations - Feature toggles: Email verification can be enabled/disabled as needed - Backward compatibility: Legacy email configurations remain functional This update provides a solid foundation for modern email functionality in Bisque while maintaining full backward compatibility with
…out breaking current functionality This commit integrates email verification capabilities into the current authentication system while maintaining backward compatibility and resolving critical datetime deprecation issues. Key changes: - Replace deprecated datetime.utcnow() with timezone-aware datetime.now(timezone.utc) to resolve Python 3.12+ compatibility issues - Add email verification integration that works alongside existing authentication without disrupting current user workflows - Implement admin user bypass for email verification to ensure administrative access remains unaffected - Enhance error handling and logging throughout registration and verification processes Email verification integration features: - Non-breaking integration that allows existing users to continue logging in normally - Graceful fallback when email verification services are unavailable - Comprehensive error handling for token generation and email sending failures - Enhanced token validation with improved debugging capabilities - Support for both AJAX and browser-based verification workflows - Automatic user verification fallback when email services fail Authentication improvements: - Updated session expiration handling across controllers with proper timezone awareness - Enhanced security with timezone-aware CSRF token generation - Improved exception handling to properly distinguish redirects from actual errors - Better user lookup and verification token management System compatibility: - Maintains existing authentication behavior while adding optional email verification - Preserves current user experience with seamless integration - Resolves datetime deprecation warnings for future Python version compatibility - Ensures administrative users can always access the system regardless of email verification status This implementation ensures the email verification system enhances security without breaking existing functionality or requiring changes to current system operations.
This commit introduces a full password reset workflow that allows users to securely reset their passwords via email verification. The implementation includes both frontend and backend components with proper security measures and fallback mechanisms. Key Changes: Backend Implementation: - Added password reset methods to RegistrationController including lost_password, request_password_reset, reset_password, and process_password_reset endpoints - Implemented secure token generation and verification in EmailVerificationService with SHA256 hashing and timestamp validation - Added email sending capability for password reset notifications with both HTML and text formats - Integrated with existing BQUser and TurboGears User models for password updates - Added proper error handling and logging throughout the reset process - Implemented security measures including token expiration (24 hours) and consistent response messages Frontend Templates: - Created lost_password.html template for initial password reset request form - Created reset_password.html template for setting new password after token verification - Added comprehensive styling and responsive design for both templates - Implemented AJAX form submission with fallback to standard form submission - Added real-time password validation and matching verification - Included proper error and success message handling Security Features: - Secure token generation using secrets module and SHA256 hashing - Token includes timestamp, email, username, and random component for uniqueness - Consistent success messages regardless of email existence to prevent user enumeration - Token expiration after 24 hours to limit exposure window - Proper cleanup of reset tokens after successful password change Integration Improvements: - Updated all login links from /client_service/ to /auth_service/login/ for consistency - Added email service status indicators to inform users of service availability - Proper integration with existing flash message and redirect systems - Support for both AJAX and traditional form submissions Error Handling: - Comprehensive error logging for debugging while maintaining security - Graceful degradation when email service is unavailable - Proper exception handling for redirect scenarios - User-friendly error messages without exposing system details This implementation provides a complete, secure, and user-friendly password reset system that integrates seamlessly with the existing Bisque registration and
…ation system This commit introduces a complete user profile editing system that allows users to view and modify their account information through a dedicated web interface. New Features: - Added edit_user endpoint with form display for profile editing - Added update_user endpoint with validation and error handling - Created comprehensive HTML template (edit_user.html) with modern styling - Implemented AJAX-based form submission with fallback to traditional POST - Added password change functionality with validation - Integrated email verification status display - Added mark_user_as_unverified method to email verification service Controller Enhancements (registration_controller.py): - New edit_user method to display user profile editing form - New update_user method to process profile updates with comprehensive validation - Added _handle_edit_user_response helper for consistent response handling - Implemented debug_user_tags endpoint for troubleshooting user tag operations - Added proper authentication checks and session validation - Integrated with existing BQUser and Tag models for data persistence - Added cache invalidation to ensure fresh user data after updates Template Features (edit_user.html): - Responsive design with modern CSS styling - Organized sections for basic info, academic details, and password changes - Form validation with client-side and server-side error handling - AJAX submission with graceful fallback to standard form POST - Integration with TurboGears flash messaging system - Comprehensive field validation and user feedback - Password strength requirements and confirmation matching - Read-only fields for username and email display Email Verification Integration: - Added mark_user_as_unverified method to handle email status changes - Proper cleanup of verification tokens and status tags - Error handling and logging for verification operations Data Model Integration: - Full integration with BQUser model for user data storage - Tag-based storage for extended user profile information - Proper handling of existing vs new tag creation using findtag method - Transaction management through TurboGears framework - Support for profile fields: fullname, research_area, institution_affiliation, funding_agency Security and Validation: - Authentication required for all profile operations - Input validation for all user-provided data - Password strength enforcement (minimum 6 characters) - Proper error handling with user-friendly messages - Session validation and redirect handling User Experience: - Clean, professional interface design - Progressive enhancement with AJAX - Clear field labeling and help text - Organized form sections with collapsible password change - Success/error message display with proper styling - Breadcrumb navigation and cancel options This implementation provides a complete solution for user profile management while maintaining security best practices and providing a smooth user experience.
Refactored ffmpeg command construction to use a single string with shell=True for subprocess.run. Increased ffmpeg thread count to 8 for faster processing. Improved logging: now logs the full ffmpeg command before execution. Enhanced error handling: cleans up partial output files if conversion fails. Used time-based seeking in slice method for more robust frame extraction. Updated code formatting for clarity and consistency. Improved info extraction: parses ffprobe output more robustly and logs extracted video info.
… cleaned up legacy files - Added deletion logic for auto-generated all_css.css and all_js.js from the bqcore module after deploy to ensure fresh assets are always generated. - Updated js_includes to resolve plugin paths as /core/plugins/... for table, text, pipeline, system, and branding plugins in production, improving static asset resolution. - Changed mail config file loader to use a relative config/site.cfg path, making configuration more portable and less dependent on absolute paths. - Added logging to remove_safe in io_misc.py for better diagnostics when file removal fails. - Fixed the registration controller to properly show flash messages when users click verification links from mailbox clients, addressing session/cookie issues. - Corrected config parsing for boolean values, ensuring that string "false" is not interpreted as True, which previously caused unintended enabling of features. - Removed legacy and unused files: email_verification_old.py, email_verification_new.py, email_verification_fixed.py, and the typo file resgistration_controller.py. - Temporarily commented out all EXTERNAL_FILES dependencies to disable external binary fetching during setup. - Set the default JS environment to production in site.cfg.default, enabling production asset bundling and minification by
- Uncommented and activated platform-specific sections in EXTERNAL_FILES for Windows, Linux, and Darwin (macOS), allowing automatic fetching of binaries such as imgcnv, ImarisConvert, openslide-bisque, feature_extractors, and opencv for each platform. - commented out extjs.zip entry to prevent conflicts with the internally managed extjs - disable ssl verification in bisque_setup.py to avoid SSL errors during downloads - currently commented how external ext.js setup to avoid conflicts with the internal ext.js management
Experimental
…th hybrid authentication architecture This commit represents the culmination of a comprehensive multi-phase migration and debugging effort that resolved critical compatibility, authentication, and infrastructure issues in BisQue's transition to Python 3.10+. The work addressed interconnected problems across the entire technology stack. ## Phase 1: Python 3.10+ BQAPI Refactoring ### BQAPI Compatibility Issues Resolved: - **String/Bytes Handling**: Fixed decode operations in test_bqclass.py for Python 3 string compatibility - **Print Statement Migration**: Updated all print statements to Python 3 function calls in test utilities - **Import Path Modernization**: Updated deprecated import mechanisms and module references - **UTF-8 Encoding**: Resolved subprocess output handling in io_misc.py (bytes to string conversion) - **Error Handling Enhancement**: Added graceful degradation for offline/test mode execution ### Test Infrastructure Modernization: - **Mock File Generation**: Automatic creation of test files when external resources unavailable - **Configuration Path Updates**: Updated test.ini paths and external resource URLs - **Graceful Test Skipping**: Server-dependent tests skip appropriately in offline mode - **Resource URL Migration**: Updated from deprecated test data sources to AWS S3 ## Phase 2: Authentication Architecture Discovery & Debugging ### Root Cause Analysis: - **Missing Middleware**: Discovered repoze.who middleware completely absent from WSGI stack - **TurboGears Integration Conflict**: Identified conflict between manual auth setup and TG's setup_auth - **Plugin Compatibility**: Resolved deprecated friendlyform vs modern redirector plugin issues - **Configuration Parsing**: Fixed WhoConfig usage and parameter compatibility problems ### Authentication Challenge Resolution: - **"No Challengers Found" Error**: Traced to missing middleware registration in application stack - **Session Authentication Failure**: Web login broken due to missing login_handler and logout_handler - **API vs Web Conflict**: Competing authentication systems interfering with each other ## Phase 3: Hybrid Authentication System Implementation ### ConditionalAuthMiddleware Development: - **Smart Request Routing**: Routes based on Authorization header presence rather than client detection - **Dual Authentication Support**: Basic Auth for APIs, session auth for web interface - **No Password Prompts**: Eliminated JavaScript authentication dialogs on web pages - **Browser API Support**: Enables both session-based and Basic Auth for browser API calls ### Authentication Plugin Modernization: - **Simplified SQLAuth**: Replaced complex SQLAlchemy plugins with working admin/admin authentication - **Deprecated Plugin Removal**: Removed friendlyform, updated to modern repoze.who patterns - **Clean Configuration**: Streamlined who.ini with only necessary API authentication plugins - **TurboGears Integration**: Proper sa_auth configuration for web interface compatibility ## Phase 4: Third-party Integration & Docker Infrastructure ### Converter Tool Integration: - **Bioformats Support**: Java environment configuration and JAR file integration - **ImarisConvert Libraries**: Fixed library dependencies with libjpeg symlinks - **OpenSlide Python**: Added openslide-python to requirements.txt for converter support - **Wrapper Scripts**: Created system PATH scripts for seamless tool integration ### Docker Infrastructure: - **Persistent Volume Support**: Config, data, reports, public, modules, staging directories - **Environment Configuration**: Flexible .env file support for deployment customization - **Health Monitoring**: Automatic health checks via /image_service/formats endpoint - **Intelligent Build Caching**: Optimized Docker layer caching for development efficiency ## Phase 5: Web Interface & Upload System Restoration ### File Upload & Preview Resolution: - **Authentication Context Fix**: Resolved web session vs API authentication conflicts - **Image Service Integration**: Restored proper format detection and converter communication - **Data Service Access**: Fixed authentication for file upload and database operations - **Session-based Web Access**: Eliminated authentication prompts while preserving API access ### Format Detection Verification: - **Multi-converter Support**: Confirmed detection of ffmpeg, openslide, imgcnv, bioformats, imaris - **API Endpoint Testing**: Verified /image_service/formats returns all converter capabilities - **Upload Workflow**: Confirmed end-to-end file upload, processing, and storage functionality
…d Docker Compose usage - Updated Docker Compose documentation to use the modern `docker compose` CLI instead of the deprecated `docker-compose` command, improving clarity and future compatibility. - Enhanced BQSession authentication logic in `source/bqapi/bqapi/comm.py`: - Changed session validation to raise explicit exceptions when authentication fails, rather than silently allowing test/offline mode. - Improved error handling to distinguish between authentication errors and true offline/server connection errors. - Ensured failed authentication for non-admin users is properly reported. - Refined test error handling in `source/bqapi/bqapi/tests/test_comm.py`: - Modified `test_run_mex` to mark authentication and server configuration errors as test failures (`pytest.fail`) instead of skips, providing more accurate test reporting. - Improved error categorization for authentication and challenger/server errors. - Fixed ConditionalAuthMiddleware in `source/bqcore/bq/config/app_cfg.py`: - Extended middleware to route requests with `Authorization: Mex ...` and `/module_service/` endpoints to the API authentication stack, resolving "no challengers found" errors for MEX operations. - Replaced the simplified authenticator plugin in `source/bqcore/bq/core/lib/sqlauth.py` with an enhanced version: - Added support for authenticating real database users, including BisQue's native password hashing and legacy formats. - Integrated BisQue's `validate_password` method for robust password checking. - Improved logging for authentication attempts, failures, and metadata/group assignment. - Enhanced metadata and group provider plugins to fetch user and group info from the database, with fallbacks for admin and default groups. - Ensured that authentication failures for valid users (e.g., `wskoly/123456`) are now properly handled and reported, and that MEX POST operations no longer fail due to missing challengers. - Improved overall test reliability and error visibility, making it easier to debug authentication and server configuration issues. This commit resolved complex issues involving authentication for non-admin users, improved error reporting in tests, and fixed middleware routing for API and MEX operations. The changes also modernized Docker Compose usage and enhanced the authentication plugin to support BisQue's password formats and user/group metadata.
…hanced authentication Converted legacy unittest/nose test suites to pytest framework across multiple services: - Image service tests (core, extended, multifile, operational, thirdparty, tiles, unicode) - Data service document tests with modernized authentication patterns - Ingest service tests with enhanced blob handling - Preference service tests with improved XML comparison utilities - Table service tests with query optimization and data fixtures Added comprehensive authentication integration: - Implemented admin_session and user_session fixtures for enhanced testing - Added authentication validation across all service endpoints - Created cleanup_resources fixtures for proper test resource management - Integrated BQSession-based authentication with proper credential handling Fixed Python 3 compatibility issues: - Resolved bytes vs string handling in response processing - Fixed tuple indexing in NumPy array operations - Updated XML parsing to handle encoding declarations properly - Corrected configparser usage with raw=True for interpolation handling Enhanced test infrastructure: - Created global conftest.py with shared fixtures and configurations - Added pytest-bisque plugin integration for application fixtures - Implemented modern test patterns with proper setup/teardown - Added comprehensive error handling and skip conditions Updated configurations and dependencies: - Modified test.ini configurations with authentication-enabled sections - Updated requirements.dev with pytest and related dependencies - Fixed database URL configuration for SQLite testing - Enhanced blob service with proper XML content type responses Bug fixes and improvements: - Fixed SQLAlchemy query issues in authentication module - Resolved Imaris converter encoding and string formatting problems - Updated table base controller with proper NumPy array indexing - Enhanced error handling in various service controllers - Improved XML comparison utilities with better BisQue-specific attribute handling All changes maintain backward compatibility while providing a robust, modern testing foundation for the BisQue platform.
…GitHub) to BisQue login - Integrated Firebase Authentication as an alternative login method alongside local BisQue accounts. - Added new endpoints in `auth_service.py` for Firebase authentication flow: - `/auth_service/firebase_auth` for provider selection and frontend handoff. - `/auth_service/firebase_token_verify` to verify Firebase ID tokens and auto-register users. - `/auth_service/firebase_session_create` to create BisQue sessions after Firebase login. - Implemented automatic user registration and tag management for new Firebase users, including email verification and profile tags. - Updated login page (`login.html`) to display Firebase social login buttons (Google, Facebook, GitHub, Twitter) with SVG icons. - Added a new template (`firebase_auth.html`) for the Firebase authentication UI, including provider selection and error handling. - Improved login CSS for better layout, button styling, and clear separation between social and local login. - Added SVG icons for all supported providers in `public/core/images/signin/`. - Updated `.gitignore` to exclude Firebase service account JSON files. - Updated `site.cfg.default` with Firebase configuration options and provider entries. - Updated `who.ini.default` to support the optional Firebase authentication plugin. - Added Firebase-related Python dependencies to `requirements.txt`.
…ompose configuration - Modified `BisqueAppConfig.setup_sqlalchemy` to return `app` instead of relying on the superclass method, allowing PostgreSQL configuration to work without TurboGears' legacy `setup_sqlalchemy` logic. - Adjusted logic to skip SQLAlchemy engine setup for non-SQLite databases, delegating handling to external configuration or explicit setup. - Retained SQLite-specific handling with `NullPool` and custom timeout, preserving backward compatibility for local/dev environments. - Updated `requirements.txt` to include `psycopg2-binary==2.9.10` for PostgreSQL driver support. - Added commented-out configuration in `docker-compose.yml` for a production-ready PostgreSQL container (`postgres:15`), including: - Environment variables for database name, user, and password. - Volume mounting for persistent data (`postgres_data`). - Healthcheck for PostgreSQL readiness using `pg_isready`. - Added placeholder for `postgres_data` named volume. - Included optional `depends_on` section for healthcheck-based dependency linking (currently commented out). This refactor ensures compatibility with TurboGears 2.5.0 while maintaining flexibility for both SQLite and PostgreSQL backends.git
… handling - Refactored blob and image service controllers to use cache max-age values from config (`bisque.blob_service.cache_max_age` and `bisque.image_service.cache_max_age`) instead of hardcoded values. This enables global control of browser-side caching duration for images, tiles, and blobs. - Updated `source/config-defaults/site.cfg.default` to include default values for `bisque.blob_service.cache_max_age` (6 weeks) and `bisque.image_service.cache_max_age` (6 weeks). - Modified the `cache_control` function in the image service to append `max-age` from config if not already present in the header value. - Improved Dream3D pipeline import logic in `from_dream3d.py` to handle cases where the uploaded file does not have a local path. Now creates a temporary file if needed, reads from the file object, and ensures proper cleanup. - Fixed a bug when writing JSON to a temporary file by encoding the string as UTF-8 bytes. - Commented out the temporary debug endpoint for user tags in the registration controller.
…, which was ignored in gitignore due to generic /lib ignore
- Enhanced DICOM to video conversion logic in `converter_ffmpeg.py`: - Added detection for multi-frame DICOMs (z-stacks, multi-file series) and routed them to a new frame extraction pipeline. - Implemented `_convert_dicom_via_frames` method to extract frames using `imgcnv` and assemble them into a video with FFmpeg, supporting both single multi-frame DICOMs and multi-file series. - Improved error handling, logging, and cleanup of temporary files/directories. - Added fallback logic: if direct FFmpeg conversion fails, the frame extraction method is used. - Ensured proper handling of resizing and pixel depth conversion for extracted frames. - Updated `format.py` operation logic: - Ensured that video format conversions always use the FFmpeg converter, regardless of input format. - Improved logging for converter selection and error cases. - Improved default channel color assignment in `bq_api.js`: - Used grayscale for single-channel images, white/red for two channels, and RGB sequence for three or more channels. - Provided more intuitive and visually distinct defaults for scientific/medical images.
…e image service - Added file time-based ETag support in image service backend to enable smart HTTP caching and revalidation; ETags now change only when files are regenerated or modified. - Updated backend to set 'Cache-Control: public, must-revalidate' for image file responses, improving browser cache efficiency and consistency. - Enhanced cache clearing operation (`cleancache`) to also clear ResourceCache for the current user and resource, ensuring backend cache is fully invalidated. - Improved URL operation parsing in `imgsrv.py` to better distinguish between known operations and subpaths, and to skip non-operation query parameters. - Added frontend "Clear Cache" button to the image viewer toolbar, with a custom icon and horizontal separator for better UI organization. - Implemented frontend logic to call the backend cache clearing endpoint, display success messages, and refresh the viewer and/or window after cache is cleared. - Added and styled a new cache clear icon (`icon-clean-cache`) for the toolbar. - Updated requirements to include `pyproj` for KML and GeoJSON export support. - Commented out legacy cache control logic for clarity and maintainability.
…istration - Introduced a new domain management feature for BisQue: - Added SQLAlchemy models and Alembic migration for `authorized_email_domains` table. - Created admin UI (`domain_management.html`) for adding, listing, and deleting authorized email domains. - Implemented backend endpoints for domain CRUD operations in `AdminController`. - Enforced domain authorization for registration and social login; only users from authorized domains can register or sign in via social login. - Implemented admin approval workflow for user registrations: - Users are no longer automatically verified if email verification is unavailable or fails; admin approval is now required. - Added admin UI (`pending_registrations.html`) for viewing, approving, and rejecting pending user registrations. - Provided backend endpoints for listing pending registrations, approving (adds `email_verified` tag), and rejecting (deletes user) registrations. - Modified registration controller logic to check domain authorization and require admin approval if email verification is not available. - Updated authentication logic to deny login for unverified users when email verification is disabled, unless manually approved by admin. - Updated BisQue admin toolbar to include "Domain Management" and "Pending Registrations" menu items. - Ensured backward compatibility: if domain management tables are missing, registration and login default to allow all domains. - Added new Alembic migration: `domain_management_001_add_domain_tables.py` for domain management schema. This commit enables institutions to restrict BisQue registration and social login to specific email domains and provides a full admin approval workflow for new users.
…and pending registrations - Refactored CSS in both domain_management.html and pending_registrations.html to use a consistent ExtJS 4-inspired theme for tables, buttons, panels, and input fields. - Increased input field heights in domain management for improved usability and visual balance. - Overhauled DataTables pagination styling in pending_registrations to match domain management, fixing bullet point issues and ensuring proper button alignment and appearance. - Standardized sorting indicator arrows for DataTables in both templates, resolving previous inconsistencies and ensuring clear visual feedback for sorting state. - Converted action buttons in both tables (delete, approve, reject) to icon-only buttons with tooltips, improving clarity and saving space while maintaining accessibility. - Improved status badge styling for pending registrations to match the overall theme. - Enhanced header action layouts for better alignment and responsiveness. - Removed legacy and conflicting styles, ensuring a clean, unified look and consistent user experience across both admin pages.
…nt navigation - Replaced all native `alert` and `confirm` calls with `Ext.Msg.alert` and `Ext.Msg.confirm` in `domain_management.html` and `pending_registrations.html` for improved UI consistency and better user experience. - Updated domain management and pending registrations workflows to display error, success, and confirmation dialogs using ExtJS messaging. - Removed the "Back to Admin" button from both templates to streamline navigation and reduce clutter. - Ensured all error handling and user notifications are now managed through Ext.Msg dialogs, providing a unified look and feel across admin pages. - Improved code readability and maintainability by consolidating dialog logic.
- Implemented a unified approval system by introducing the `is_approved` tag for users, ensuring that both email verification and explicit admin approval are required for login. - Updated `auth_service.py`: - Added `_is_approved` and `_is_email_verified` helper methods to check user approval and email verification status via tags. - Modified login flow to check both email verification and admin approval before allowing user login, including for manual and Firebase-authenticated users. - Updated error handling and user feedback to reflect new approval requirements. - Updated `admin_service/controllers/service.py`: - Modified user approval logic to set both `email_verified` and `is_approved` tags, along with corresponding timestamps. - Changed user status reporting to require both tags for a user to be considered "approved". - Ensured that Firebase registration and login flows also require admin approval before granting access. - Improved logging for approval and verification checks to aid in debugging and auditing. - These changes enforce a stricter, more consistent user approval process across all authentication methods.
Improved dicom video gen, and addressed other new requirements
- Refactored Google Maps initialization in `view.html` to use dynamic script loading, avoiding Genshi template issues with `&` characters. - Added async/defer and `v=weekly&loading=async` to Google Maps API loading for best performance and future compatibility. - Suppressed Google Maps Marker deprecation warnings in the console, as standard markers are intentionally used for now. - Implemented comprehensive global error handling in both `view.html` and `map.js`: - Handles both synchronous errors and unhandled promise rejections. - Ensures these errors do not break the user experience or application flow. - Refactored `map.js`: - Improved code style and formatting for readability and maintainability. - Added `setupGlobalMapErrorHandler` and `safeEventListener` for robust error suppression. - Debounced map type change and resize events to reduce race conditions. - Ensured all Google Maps event listeners are wrapped in error handlers. - Cleaned up and modernized AJAX and utility function code. - Updated `utils.js` for consistent code style and minor bug fixes. - Added author attribution for recent changes. Known Issue: There is a persistent, unexplained error originating from the Google Maps package (`b.Ri is not a function`) that occurs when switching map modes (e.g., from map to satellite). Despite extensive error handling and research, this appears to be a bug or race condition within the Google Maps API itself and could not be fully debugged or suppressed at the application level. The root cause remains unresolved.
- Moved global error handler setup to initComponent for earlier interception of Google Maps API errors. - Enhanced error suppression for Google Maps internal errors, including cross-origin script errors and unhandled promise rejections, to prevent disruptive console messages. - Removed redundant and legacy error handler code, consolidating all error suppression logic into setupGlobalErrorHandler. - Simplified map initialization in afterRender, removing unnecessary try/catch and legacy event handler setup. - Implemented a robust fix for gray tiles issue when switching map types by using the "zoom trick" (temporarily increasing and restoring zoom) and triggering resize and bounds recalculation. - Cleaned up map event handler logic, removing debounced and wrapped listeners in favor of a direct maptypeid_changed listener. - Ensured proper ExtJS layout and map container sizing using layout: 'fit' and bodyStyle for 100% width and height. - Streamlined dataset and image loading logic into dedicated loadDataset and loadImage methods. - Updated resized handler to preserve map center after resize and trigger a resize event with a short delay.
…oved UI and marker handling - Refactored map panel to support both Google Maps and OpenStreetMap (Leaflet.js), allowing users to switch providers via a toolbar toggle. - Implemented dynamic loading of Leaflet resources for OpenStreetMap integration. - Updated toolbar to include provider switch and map type dropdown, with icons for Google Maps and OSM. - Ensured map type dropdown refreshes and synchronizes with the selected provider and map type. - Improved error handling for both Google Maps and Leaflet, suppressing internal errors and cross-origin script issues. - Fixed gray tiles issue when switching back to Google Maps with Satellite view by applying a zoom trick and resize event. - Enhanced marker management: markers are now stored and restored across provider switches, and bounds fitting is performed only after all markers are loaded. - Improved marker positioning for Google Maps to match OpenStreetMap accuracy. - Added utility functions for clearing markers, getting bounds, fitting bounds, and panning to locations for both providers. - Updated CSS to provide icons and improved styling for the map toolbar and container.
…eam3D support, and cleaned up debug code - Enhanced Unicode filename handling in urlpaths.py and mount_service.py to properly support Cyrillic and other non-ASCII characters, avoiding latin1 corruption. - Improved url2unicode decoding logic for robust handling of percent-encoded and double-encoded URLs. - Cleaned up blob_drivers.py by removing unnecessary debug logging and commented code. - Updated converter_bioformats.py to robustly parse OME-XML metadata, handling both string and bytes input and multiple encodings, with better error handling and logging. - Fixed series argument handling in converter_bioformats.py to safely convert to int and avoid type errors. - Refactored converter_ffmpeg.py to dynamically support video conversion for scientific formats (Dream3D, CZI, LSM, LIF, ND2, OIB, OIF, VSI, IMS, DICOM), including new frame extraction methods for Dream3D and generic non-FFmpeg formats. - Made Dream3D video conversion dynamic by extracting the dataset path from the token, supporting all Dream3D datasets. - Added support for 4-channel Dream3D data (e.g., quaternions) by converting to RGB using the first three channels. - Improved converter_ffmpeg.py to use shlex.quote for safe command construction and direct subprocess calls for reliability. - Updated imgsrv.py to improve converter validation and info extraction for both images and videos, with more flexible handling of dimension and format info. - Improved meta.py to exhaustively search for converter metadata and handle empty results. - Added h5py==3.15.1 to requirements.txt for Dream3D HDF5 data access. - Cleaned up all debug and commented code, keeping only finalized and production-ready logging and logic.
…d map type switching, resolved czi and some more other formats video gen issues Updated and resolved google map issues, implemented openstreet map and map type switching, resolved czi and some more other formats video gen issues
Signed-off-by: Charvi Mendiratta <charvi077@gmail.com>
Signed-off-by: Charvi Mendiratta <charvi077@gmail.com>
Signed-off-by: Charvi Mendiratta <charvi077@gmail.com>
…erable' errors for thumbnails - Wrapped all FileApp and BQFileApp responses with use_wsgi_app() in engine_service, blob_service, feature service, and proxy controller to ensure TurboGears 2.4+ compatibility. - Fixed the issue where requests for engine module thumbnails (and other file-serving endpoints) caused 'TypeError: FileApp object is not iterable' by properly wrapping WSGI file responses. - Ensured proxy controller also wraps proxied WSGI apps to prevent similar errors when proxying file responses. - Cleaned up unnecessary debug and diagnostic code related to troubleshooting.
Signed-off-by: CharviMendiratta <charvi077@gmail.com>
…er_env Signed-off-by: CharviMendiratta <charvi077@gmail.com>
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.