125 Commits

Author SHA1 Message Date
Eric Hare
e555e470d9 fix: Cherry-pick nightly SDK build fixes to main (#12491)
Some checks failed
Auto-update / Auto-update (push) Has been cancelled
CodeQL / Analyze (javascript) (push) Has been cancelled
CodeQL / Analyze (python) (push) Has been cancelled
Nightly Build / validate-inputs (push) Has been cancelled
Nightly Build / resolve-release-branch (push) Has been cancelled
Nightly Build / create-nightly-tag (push) Has been cancelled
Nightly Build / Run Frontend Tests - Linux (push) Has been cancelled
Nightly Build / Run Frontend Tests - Windows (push) Has been cancelled
Nightly Build / Run Backend Unit Tests (push) Has been cancelled
Nightly Build / Run Nightly Langflow Build (push) Has been cancelled
Nightly Build / Send Slack Notification (push) Has been cancelled
Store pytest durations / Run pytest and store durations (push) Has been cancelled
Update OpenAPI Spec / check-openapi-updates (push) Has been cancelled
* fix: Build and install the langflow-sdk for lfx (fixes nightly) (#12481)

* fix: Build and install the langflow-sdk for lfx

* Publish sdk as a nightly

* Update ci.yml

* Update python_test.yml

* Update ci.yml

* fix: Properly grep for the langflow version (#12486)

* fix: Properly grep for the langflow version

* Mount the sdk where needed

* Skip the sdk

* [autofix.ci] apply automated fixes

* Update setup.py

* fix(docker): Remove broken npm self-upgrade from Docker images (#12309)

* fix: replace grep -oP with sed for Node.js version extraction in Docker builds (#12331)

The grep -oP (PCRE regex) command fails in the python:3.12.12-slim-trixie
Docker base image because PCRE support is not available in the slim variant.

This replaces grep -oP with portable sed -nE in all 5 Dockerfiles and adds
an empty version guard to fail fast with a clear error message instead of
producing a broken download URL.

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Cristhian Zanforlin Lousa <cristhian.lousa@gmail.com>
Co-authored-by: vjgit96 <vijay.katuri@ibm.com>
2026-04-03 14:25:33 -04:00
Adam-Aghili
8dbcbb0928 chore: release nightlies from of release branch (#12181)
* chore: release nightlies from of release branch

in preperation for the new release cycle strategy we will move the nightly to be run off the latest release branch.

One caveat worth documenting: When we create the release branch we need to bump the verions for base and main immediately or else the ngihtly will run off the branch but will use a preveious release tag

I also do not know how to deal with `merge-hash-history-to-main` in this case

* chore: address valid code rabbit comments

add clear error when branch does not exist
make sure valid inputs is respected in the rest of the jobs/steps
release_nightly.yml now uses nightly_tag_release instead of the old nightly_tag_main
2026-03-16 13:21:46 +00:00
Jordan Frazier
67d56947e8 chore: remove hash history (#12183)
* Remove hash history

Custom component checks will be done directly through the
component index. Removing hash history as it no longer
fits into any planned functionality.

* [autofix.ci] apply automated fixes

* baseline format fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2026-03-16 10:42:08 +00:00
Gabriel Luiz Freitas Almeida
91219be56c feat: add secret key rotation script and documentation (#10978)
* feat: add script for migrating encrypted data to a new secret key

* test: add unit tests for secret key migration script

* docs: update SECURITY.md to include secret key rotation process and migration instructions

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* [autofix.ci] apply automated fixes (attempt 3/3)

* update component index

* update component index

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* [autofix.ci] apply automated fixes (attempt 3/3)

* refactor: use atomic transaction for secret key migration

* fix: print new key for both generated and provided cases

Ensure users always see the key being used regardless of whether
it was auto-generated or provided via --new-key flag.

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* fix: improve error handling and test coverage for secret key migration

- Update docstring to accurately reflect migrated fields (remove KB reference)
- Change migrate_auth_settings to return (result, failed_fields) tuple
- Skip folders with failed field migrations instead of silently preserving old values
- Add tests for transaction atomicity and rollback behavior
- Add tests for error handling: invalid data, null values, malformed JSON
- Add test for file permissions (0o600 on Unix)
- Add test for dry-run mode database preservation

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* [autofix.ci] apply automated fixes (attempt 3/3)

* docs: improve docstrings for secret key migration script

- Add detailed description for ensure_valid_key explaining short vs long key handling
- Add Returns section to migrate_value documenting None return on failure
- Add full Args documentation and transaction behavior to migrate function

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* [autofix.ci] apply automated fixes (attempt 3/3)

* fix: update .gitignore to include new data files and user-specific cache

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* [autofix.ci] apply automated fixes (attempt 3/3)

* fix: update usage instructions to include 'uv run' for secret key migration script

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* [autofix.ci] apply automated fixes (attempt 3/3)

* feat: add migration verification functionality and corresponding tests

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* [autofix.ci] apply automated fixes (attempt 3/3)

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2026-03-03 13:06:58 +00:00
vjgit96
c1b423862d fix: preserve [complete] extra in langflow-base pre-release constraint (#11931)
* fix: preserve [complete] extra in langflow-base pre-release constraint

The sed replacement for pre-release builds was dropping the [complete]
extra from the langflow-base dependency, causing the built wheel to
depend on bare langflow-base instead of langflow-base[complete]. This
meant hundreds of optional dependencies (LLM providers, vector stores,
document loaders, etc.) were missing from pre-release installs, breaking
the CLI and all cross-platform installation tests.

* test: add regression test for sed constraint preservation

* [autofix.ci] apply automated fixes

* test: add regression test for sed constraint preservation in release workflow

* [autofix.ci] apply automated fixes

* test: add regression test for sed constraint preservation in release workflow

* [autofix.ci] apply automated fixes

* fix: move noqa comment to correct line for S603 check

* [autofix.ci] apply automated fixes

* test: add regression test for sed constraint preservation in release workflow

* [autofix.ci] apply automated fixes

* test: add regression test for sed constraint preservation in release workflow

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2026-02-27 10:00:39 -05:00
Ram Gopal Srikar Katakam
97e52e977a feat: use uv sources for CPU-only PyTorch (#11884)
* feat: use uv sources for CPU-only PyTorch

Configure [tool.uv.sources] with pytorch-cpu index to avoid ~6GB CUDA
dependencies in Docker images. This replaces hardcoded wheel URLs with
a cleaner index-based approach.

- Add pytorch-cpu index with explicit = true
- Add torch/torchvision to [tool.uv.sources]
- Add explicit torch/torchvision deps to trigger source override
- Regenerate lockfile without nvidia/cuda/triton packages
- Add required-environments for multi-platform support

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* fix: update regex to only replace name in [project] section

The previous regex matched all lines starting with `name = "..."`,
which incorrectly renamed the UV index `pytorch-cpu` to `langflow-nightly`
during nightly builds. This caused `uv lock` to fail with:
"Package torch references an undeclared index: pytorch-cpu"

The new regex specifically targets the name field within the [project]
section only, avoiding unintended replacements in other sections like
[[tool.uv.index]].

* style: fix ruff quote style

* fix: remove required-environments to fix Python 3.13 macOS x86_64 CI

The required-environments setting was causing hard failures when packages
like torch didn't have wheels for specific platform/Python combinations.
Without this setting, uv resolves optimistically and handles missing wheels
gracefully at runtime instead of failing during resolution.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-25 12:25:27 -05:00
vjgit96
0283f5d7e1 feat: merge Release v1.8.0 into main (#11827)
* feat: Pluggable AuthService with abstract base class (#10702) (#11654)

feat(auth): Pluggable AuthService with abstract base class (#10702)

* feat: Introduce service registration decorator and enhance ServiceManager for pluggable service discovery

- Added `register_service` decorator to allow services to self-register with the ServiceManager.
- Enhanced `ServiceManager` to support multiple service discovery mechanisms, including decorator-based registration, config files, and entry points.
- Implemented methods for direct service class registration and plugin discovery from various sources, improving flexibility and extensibility of service management.

* feat: Implement VariableService for managing environment variables

- Introduced VariableService class to handle environment variables with in-memory caching.
- Added methods for getting, setting, deleting, and listing variables.
- Included logging for service initialization and variable operations.
- Created an __init__.py file to expose VariableService in the package namespace.

* feat: Enhance LocalStorageService with Service integration and async teardown

- Updated LocalStorageService to inherit from both StorageService and Service for improved functionality.
- Added a name attribute for service identification.
- Implemented an async teardown method for future extensibility, even though no cleanup is currently needed.
- Refactored the constructor to ensure proper initialization of both parent classes.

* feat: Implement telemetry service with abstract base class and minimal logging functionality

- Added `BaseTelemetryService` as an abstract base class defining the interface for telemetry services.
- Introduced `TelemetryService`, a lightweight implementation that logs telemetry events without sending data.
- Created `__init__.py` to expose the telemetry service in the package namespace.
- Ensured robust async methods for logging various telemetry events and handling exceptions.

* feat: Introduce BaseTracingService and implement minimal TracingService

- Added `BaseTracingService` as an abstract base class defining the interface for tracing services.
- Implemented `TracingService`, a lightweight version that logs trace events without external integrations.
- Included async methods for starting and ending traces, tracing components, and managing logs and outputs.
- Enhanced documentation for clarity on method usage and parameters.

* feat: Add unit tests for service registration decorators

- Introduced a new test suite for validating the functionality of the @register_service decorator.
- Implemented tests for various service types including LocalStorageService, TelemetryService, and TracingService.
- Verified behavior for service registration with and without overrides, ensuring correct service management.
- Included tests for custom service implementations and preservation of class functionality.
- Enhanced overall test coverage for the service registration mechanism.

* feat: Add comprehensive unit and integration tests for ServiceManager

- Introduced a suite of unit tests covering edge cases for service registration, lifecycle management, and dependency resolution.
- Implemented integration tests to validate service loading from configuration files and environment variables.
- Enhanced test coverage for various service types including LocalStorageService, TelemetryService, and VariableService.
- Verified behavior for service registration with and without overrides, ensuring correct service management.
- Ensured robust handling of error conditions and edge cases in service creation and configuration parsing.

* feat: Add unit and integration tests for minimal service implementations

- Introduced comprehensive unit tests for LocalStorageService, TelemetryService, TracingService, and VariableService.
- Implemented integration tests to validate the interaction between minimal services.
- Ensured robust coverage for file operations, service readiness, and exception handling.
- Enhanced documentation within tests for clarity on functionality and expected behavior.

* docs: Add detailed documentation for pluggable services architecture and usage

* feat: Add example configuration file for Langflow services

* docs: Update PLUGGABLE_SERVICES.md to enhance architecture benefits section

- Revised the documentation to highlight the advantages of the pluggable service system.
- Replaced the migration guide with a detailed overview of features such as automatic discovery, lazy instantiation, dependency injection, and lifecycle management.
- Clarified examples of service registration and improved overall documentation for better understanding.

* [autofix.ci] apply automated fixes

* test(services): improve variable service teardown test with public API assertions

* docs(pluggable-service-layer): add docstrings for service manager and implementations

* fix: remove duplicate teardown method from LocalStorageService

During rebase, the teardown method was added in two locations (lines 57 and 220).
Removed the duplicate at line 57, keeping the one at the end of the class (line 220)
which is the more appropriate location for cleanup methods.

* fix(tests): update service tests for LocalStorageService constructor changes

- Add MockSessionService fixtures to test files that use ServiceManager
- Update LocalStorageService test instantiation to use mock session and settings services
- Fix service count assertions to account for MockSessionService in fixtures
- Remove duplicate class-level clean_manager fixtures in test_edge_cases.py

These changes fix test failures caused by LocalStorageService requiring
session_service and settings_service parameters instead of just data_dir.

* fix(services): Harden service lifecycle methods

- Fixed Diamond Inheritance in LocalStorageService
- Added Circular Dependency Detection in _create_service_from_class
- Fixed StorageService.teardown to Have Default Implementation

* docs: Update discovery order for pluggable services

* fix(lfx): replace aiofile with aiofiles for CI compatibility

- The aiofile library uses native async I/O (libaio) which fails with
  EAGAIN (SystemError: 11, 'Resource temporarily unavailable') in
  containerized environments like GitHub Actions runners.
- Switch to aiofiles which uses thread pool executors, providing reliable
  async file I/O across all environments including containers.

* [autofix.ci] apply automated fixes

* fix(lfx): prevent race condition in plugin discovery

  The discover_plugins() method had a TOCTOU (time-of-check to time-of-use)
  race condition. Since get() uses a keyed lock (per service name), multiple
  threads requesting different services could concurrently see
  _plugins_discovered=False and trigger duplicate plugin discovery.

  Wrap discover_plugins() with self._lock to ensure thread-safe access to
  the _plugins_discovered flag and prevent concurrent discovery execution.

* [autofix.ci] apply automated fixes

* feat: Introduce service registration decorator and enhance ServiceManager for pluggable service discovery

- Added `register_service` decorator to allow services to self-register with the ServiceManager.
- Enhanced `ServiceManager` to support multiple service discovery mechanisms, including decorator-based registration, config files, and entry points.
- Implemented methods for direct service class registration and plugin discovery from various sources, improving flexibility and extensibility of service management.

* feat: Enhance LocalStorageService with Service integration and async teardown

- Updated LocalStorageService to inherit from both StorageService and Service for improved functionality.
- Added a name attribute for service identification.
- Implemented an async teardown method for future extensibility, even though no cleanup is currently needed.
- Refactored the constructor to ensure proper initialization of both parent classes.

* docs(pluggable-service-layer): add docstrings for service manager and implementations

* feat(auth): implement abstract base class for authentication services and add auth service retrieval function

* refactor(auth): move authentication logic from utils to AuthService

  Consolidate all authentication methods into the AuthService class to
  enable pluggable authentication implementations. The utils module now
  contains thin wrappers that delegate to the registered auth service.

  This allows alternative auth implementations (e.g., OIDC) to be
  registered via the pluggable services system while maintaining
  backward compatibility with existing code that imports from utils.

  Changes:
  - Move all auth logic (token creation, user validation, API key
    security, password hashing, encryption) to AuthService
  - Refactor utils.py to delegate to get_auth_service()
  - Update function signatures to remove settings_service parameter
    (now obtained from the service internally)

* refactor(auth): update authentication methods and remove settings_service parameter

  - Changed function to retrieve current user from access token instead of JWT.
  - Updated AuthServiceFactory to specify SettingsService type in create method.
  - Removed settings_service dependency from encryption and decryption functions, simplifying the code.

This refactor enhances the clarity and maintainability of the authentication logic.

* test(auth): add unit tests for AuthService and pluggable authentication

- Introduced comprehensive unit tests for AuthService, covering token creation, user validation, and authentication methods.
- Added tests for pluggable authentication, ensuring correct delegation to registered services.
- Enhanced test coverage for user authentication scenarios, including active/inactive user checks and token validation.

These additions improve the reliability and maintainability of the authentication system.

* fix(tests): update test cases to use AuthService and correct user retrieval method

- Replaced the mock for retrieving the current user from JWT to access token in the TestSuperuserCommand.
- Refactored unit tests for MCP encryption to utilize AuthService instead of a mock settings service, enhancing test reliability.
- Updated patch decorators in tests to reflect the new method of obtaining the AuthService, ensuring consistency across test cases.

These changes improve the accuracy and maintainability of the authentication tests.

* docs(pluggable-services): add auth_service to ServiceType enum documentation

* fix(auth): Add missing type hints and abstract methods to AuthServiceBase (#10710)




* [autofix.ci] apply automated fixes

* fix(auth): refactor api_key_security method to accept optional database session and improve error handling

* feat(auth): enhance AuthServiceBase with detailed design principles and JIT provisioning methods

* fix(auth): remove settings_service from encrypt/decrypt_api_key calls

After the pluggable auth refactor, encrypt_api_key and decrypt_api_key
no longer take a settings_service argument - they get it internally.

- Update check_key import path in __main__.py (moved to crud module)
- Remove settings_service argument from calls in:
  - api/v1/api_key.py
  - api/v1/store.py
  - services/variable/service.py
  - services/variable/kubernetes.py
- Fix auth service to use session_scope() instead of non-existent
  get_db_service().with_session()

* fix(auth): resolve type errors and duplicate definitions in pluggable auth branch

  - Add missing imports in auth/utils.py (Final, HTTPException, status,
    logger, SettingsService) that prevented application startup
  - Remove duplicate NoServiceRegisteredError class in lfx/services/manager.py
  - Remove duplicate teardown method in lfx/services/storage/local.py
  - Fix invalid settings_service parameter in encrypt_api_key calls
    in variable/service.py and variable/kubernetes.py
  - Add proper type guards for check_key calls to satisfy mypy
  - Add null checks for password fields in users.py endpoints

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* [autofix.ci] apply automated fixes (attempt 3/3)

* [autofix.ci] apply automated fixes

* replace jose with pyjwt

* [autofix.ci] apply automated fixes

* starter projects

* fix BE mcp tests

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* remive legacy usage of session

* fix user tests

* [autofix.ci] apply automated fixes

* fix lfx tests

* starter project update

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* fix mypy errors

* fix mypy errors on tests

* fix tests for decrypt_api_key

* resolve conflicts in auth utils

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* Add pluggable authentication factory with provider enum

* Add SSO feature flags to AuthSettings

* Add SSO fields to User model

* Add SSO configuration loader with YAML support

* Add unit tests for SSO configuration loader

* Add SSO configuration database model and CRUD operations

* Add CRUD operations for SSO configuration management

* Add SSO configuration service supporting both file and database configs

* Add example SSO configuration file with W3ID and other providers

* Implement OIDC authentication service with discovery and JIT provisioning

* Update AuthServiceFactory to instantiate OIDC service when SSO enabled

* Improve JWT token validation and API key decryption error handling

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes

* fix: resolve ruff linting errors in auth services and add sso-config.yaml to gitignore

* [autofix.ci] apply automated fixes

* fix: use correct function name get_current_user_from_access_token in login endpoint

* fix: remove incorrect settings_service parameter from decrypt_api_key call

* fix: correct encryption logic to properly detect plaintext vs encrypted values

* [autofix.ci] apply automated fixes

* fix tests

* [autofix.ci] apply automated fixes

* fix mypy errors

* fix tests

* [autofix.ci] apply automated fixes

* fix ruff errors

* fix tests in service

* [autofix.ci] apply automated fixes

* fix test security cors

* [autofix.ci] apply automated fixes

* fix webhook issues

* modify component index

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* [autofix.ci] apply automated fixes (attempt 3/3)

* fix webhook tests

* [autofix.ci] apply automated fixes

* build component index

* remove SSO functionality

* [autofix.ci] apply automated fixes

* fix variable creation

* [autofix.ci] apply automated fixes

* refactor: move MCPServerConfig schema to a separate file and update model_dump usage

* refactor: streamline AuthServiceFactory to use service_class for instance creation

* handle access token type

* [autofix.ci] apply automated fixes

* remove SSO fields from user model

* [autofix.ci] apply automated fixes

* replace is_encrypted back

* fix mypy errors

* remove sso config example

* feat: Refactor framework agnostic auth service (#11565)

* modify auth service layer

* [autofix.ci] apply automated fixes

* fix ruff errorrs

* [autofix.ci] apply automated fixes

* Update src/backend/base/langflow/services/deps.py



* address review comments

* [autofix.ci] apply automated fixes

* fix ruff errors

* remove cache

---------




* move base to lfx

* [autofix.ci] apply automated fixes

* resolve review comments

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* add auth protocol

* [autofix.ci] apply automated fixes

* revert models.py execption handling

* revert wrappers to ensure backwards compatibility

* fix http error code

* fix FE tests

* fix test_variables.py

* [autofix.ci] apply automated fixes

* fix ruff errors

* fix tests

* add wrappers for create token methods

* fix ruff errors

* [autofix.ci] apply automated fixes

* update error message

* modify status code for inactive user

* fix ruff errors

* fix patch for webhook tests

* fix error message when getting active users

---------

Co-authored-by: Gabriel Luiz Freitas Almeida <gabriel@logspace.ai>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Mike Pawlowski <mike.pawlowski@datastax.com>
Co-authored-by: Mike Pawlowski <mpawlow@ca.ibm.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Co-authored-by: ogabrielluiz <24829397+ogabrielluiz@users.noreply.github.com>
Co-authored-by: Deon Sanchez <69873175+deon-sanchez@users.noreply.github.com>
Co-authored-by: codeflash-ai[bot] <148906541+codeflash-ai[bot]@users.noreply.github.com>

* fix: adjusted textarea and playground paddings and design (#11635)

* revert textarea to old classes

* fixed text-area-wrapper to handle initial height when value is calculated

* fixed playground padding

* fixed no input text size

* [autofix.ci] apply automated fixes

* fixed flaky test

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* feat: create guardrails component (#11451) (#11671)

* Create guardrails.py

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* Update guardrails.py

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* tests: add unit tests for GuardrailsComponent functionality

* [autofix.ci] apply automated fixes

* fix: resolve linting errors in GuardrailsComponent and tests

- Fix line length issues (E501) by breaking long strings
- Fix docstring formatting (D205, D415) in _check_guardrail
- Use ternary operator for response content extraction (SIM108)
- Replace magic value with named constant (PLR2004)
- Move return to else block per try/except best practices (TRY300)
- Catch specific exceptions instead of blind Exception (BLE001)
- Use list comprehension for checks_to_run (PERF401)
- Mark unused variables with underscore prefix (RUF059, F841)
- Add noqa comment for intentionally unused mock argument (ARG002)

* [autofix.ci] apply automated fixes

* refactor: address pr comments

* [autofix.ci] apply automated fixes (attempt 2/3)

* [autofix.ci] apply automated fixes

* feat: enhance heuristic detection with configurable threshold and scoring system

* refactor: simplify heuristic test assertions by removing unused variable

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* feat: enhance guardrail validation logic and input handling

* refactor: streamline import statements and clean up whitespace in guardrails component

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* Fix: update empty input handling tests to raise ValueError and refactor related assertions

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes

* feat: add Guardrails component with unit tests

Add LLM-based guardrails component for detecting PII, tokens/passwords,
jailbreak attempts, and custom guardrail rules, along with comprehensive
unit tests.

* [autofix.ci] apply automated fixes

* fix: try removing logs

* [autofix.ci] apply automated fixes

---------

Co-authored-by: Lucas Democh <ldgoularte@gmail.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* fix: added remove file from file input (#11667)

* Implemented dismiss file functionality on input file component

* fixed hover behavior

* added test for removing file from input

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* fix: make connected inputs not hideable (#11672)

* fixed react flow utils to clean advanced edges

* Make connected handles not be able to be hidden

* Added test for hiding connected handles

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* fix: make tooltip not appear when closing SessionMore (#11703)

fix tooltip showing up when closing select

* fix(frontend): prevent multiple session menus from stacking in fullscreen mode

* [autofix.ci] apply automated fixes

* fix(frontend): prevent crash when renaming empty sessions (#11712)

* fix(frontend): prevent crash when renaming empty sessions

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* fix(ci): handle PEP 440 normalized versions in pre-release tag script (#11722)

The regex in langflow_pre_release_tag.py expected a dot before `rc`
(e.g. `1.8.0.rc0`), but PyPI returns PEP 440-normalized versions
without the dot (e.g. `1.8.0rc0`). This caused the script to recompute
the same version instead of incrementing, and `uv publish` silently
skipped the duplicate upload.

Update the regex to accept both formats with `\.?rc`.

* fix: align chat history with input field in fullscreen playground (#11725)

* fix: align chat history with input field in fullscreen playground

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* fix: Enforce Webhook singleton rule on paste and duplicate                                                                         (#11692)

* fix singleton webhook on flow

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* fix(frontend): generate unique variable names in Prompt Template Add Variable button (#11723)

* fix: generate unique variable names in Prompt Template Add Variable button

Previously, clicking the Add Variable button always inserted {variable_name},
causing duplicate text without creating new input fields. Now the button
generates incremental names (variable_name, variable_name_1, variable_name_2)
by checking existing variables in the template.

* refactor: extract generateUniqueVariableName and import in tests

Extract the variable name generation logic into an exported function
so tests can import and validate the actual production code instead
of testing a duplicated copy of the logic.

* FIX: Broken Connection Edge Rendering in YouTube Analysis Template (#11709)

add edge between components

Co-authored-by: Olayinka Adelakun <olayinkaadelakun@Olayinkas-MacBook-Pro.local>

* fix: synchronize prompt state, add new mustache prompt component (#11702)

* Update state when exiting modal on accordion prompt component

* Added isDoubleBrackets and show correct modal and use correct brackets when mustache is enabled

* [autofix.ci] apply automated fixes

* added test to see if state is synchronized and mustache is enabled

* [autofix.ci] apply automated fixes

* updated mustache id and removed extra prompt call

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Carlos Coelho <80289056+carlosrcoelho@users.noreply.github.com>

* fix(frontend): add Safari-specific padding for playground chat messages (#11720)

* fix(frontend): add Safari-specific padding for playground chat messages

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* fix: correctly pass headers in mcp stdio connections (#11746)

* fix: parse dicts from tweaks (#11753)

* Correctly parse dicts from tweaks

* Add test

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* fix: sessions overflow issue (#11739)

fix: sessions overflow issue

* feat: playground UI fixes, inspector improvements & canvas reorganization (#11751)

* merge fix

* code improvements

* [autofix.ci] apply automated fixes

* add stop button and fix scroll on message

* [autofix.ci] apply automated fixes

* add new message content for sharable pg

* fix tests until shard 43

* [autofix.ci] apply automated fixes

* fix(frontend): clean up MemoizedSidebarTrigger imports and transition classes

Sort imports, add type modifier to AllNodeType import, and split long transition class string for readability.

* fix tests

* [autofix.ci] apply automated fixes

* fix mr test

* fix jest tests

* fix sidebar jest tes

* [autofix.ci] apply automated fixes

* fix sharable playground

* [autofix.ci] apply automated fixes

* remove rename from sharable pg

* [autofix.ci] apply automated fixes

* add new message content for sharable pg

* fix: synchronize prompt state, add new mustache prompt component (#11702)

* Update state when exiting modal on accordion prompt component

* Added isDoubleBrackets and show correct modal and use correct brackets when mustache is enabled

* [autofix.ci] apply automated fixes

* added test to see if state is synchronized and mustache is enabled

* [autofix.ci] apply automated fixes

* updated mustache id and removed extra prompt call

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Carlos Coelho <80289056+carlosrcoelho@users.noreply.github.com>

* fix(frontend): add Safari-specific padding for playground chat messages (#11720)

* fix(frontend): add Safari-specific padding for playground chat messages

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* fix: correctly pass headers in mcp stdio connections (#11746)

* fix sharable playground

* [autofix.ci] apply automated fixes

* remove rename from sharable pg

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes

* fix sharable playground

* fix mcp server to use shell lexer

* [autofix.ci] apply automated fixes

* fix tests

* fix outaded component tests

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Viktor Avelino <viktor.avelino@gmail.com>
Co-authored-by: Lucas Oliveira <62335616+lucaseduoli@users.noreply.github.com>
Co-authored-by: Carlos Coelho <80289056+carlosrcoelho@users.noreply.github.com>
Co-authored-by: keval shah <kevalvirat@gmail.com>
Co-authored-by: Jordan Frazier <122494242+jordanrfrazier@users.noreply.github.com>

* fix: correct field_order in all starter project JSON templates (#11727)

* fix: correct field_order in all starter project JSON templates

The field_order arrays in starter project nodes were out of sync with
the actual input definitions in the Python component source files,
causing parameters to display in the wrong order in the UI.

Fixed 136 nodes across 32 starter project files including Chat Input,
Chat Output, Language Model, Agent, Prompt Template, Text Input,
Tavily AI Search, Read File, Embedding Model, and others.

* test: add field_order validation test for starter projects

Verifies that field_order arrays in starter project JSONs match the
actual component input order by importing each component and comparing
the relative ordering of fields.

* fix mcp server to use shell lexer

* [autofix.ci] apply automated fixes

* fix: enforce full field_order in starter projects and add node overlap test

Update all starter project JSONs to include the complete component
field_order instead of a subset, preventing layout inconsistency
between template and sidebar. Strengthen the field_order test to
require an exact match and add a new test that verifies no two
generic nodes overlap on the canvas.

---------

Co-authored-by: cristhianzl <cristhian.lousa@gmail.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* fix: dict tweak parsing (#11756)

* Fix dict handling of different formats

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* [autofix.ci] apply automated fixes (attempt 3/3)

* cmp index

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* Fix: The Prompt component has responsiveness issues (#11713)

improve styling of templete input

Co-authored-by: Olayinka Adelakun <olayinkaadelakun@Olayinkas-MacBook-Pro.local>

* clear session on delete chat

* fix(api): prevent users from deactivating their own account (#11736)

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>

* Fix:  UI Overlay: Chat Input Component Overlapping README Note (#11710)

* move chat input arround for travel json starter template

* improve the layout of the component

* fix layout

---------

Co-authored-by: Olayinka Adelakun <olayinkaadelakun@Olayinkas-MacBook-Pro.local>

* fix: Google Generative AI model catalog update (#11735)

* fix: Filter out MCP and models_and_agents categories and MCPTools component from sidebar (#11513)

* fix: hide MCP tool from model & agent

* fix: removing mcp searching

* fix testcases

* fix testcases

---------

Co-authored-by: Olayinka Adelakun <olayinkaadelakun@Olayinkas-MacBook-Pro.local>
Co-authored-by: Carlos Coelho <80289056+carlosrcoelho@users.noreply.github.com>
Co-authored-by: Olayinka Adelakun <olayinkaadelakun@mac.war.can.ibm.com>

* fix: Fix flaky Market Research test timeout on CI  (#11665)

* add wait for statement to prevent race condition

* fix flaky global variable

* add input selection

* [autofix.ci] apply automated fixes

* add disable inspect panel util

* [autofix.ci] apply automated fixes

* fix vector store test

* [autofix.ci] apply automated fixes

* use disable inspect pannel utils

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* ci: make docs deployment manual-only (#11602)

feat: update GitHub Actions workflow to allow manual branch selection for docs deployment

* fix: handle missing capabilities in Ollama API response (#11603)

* fix: handle missing capabilities in Ollama API response

Older Ollama versions don't return the `capabilities` field from
`/api/show`. The previous code defaulted to an empty list and required
"completion" capability, filtering out all models.

Now we treat missing capabilities as backwards-compatible: assume the
model supports completion unless tool_model_enabled is True (where we
can't verify tool support without the capabilities field).

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* [autofix.ci] apply automated fixes

* test: add test cases for Ollama backwards compatibility fix

Add tests for get_models handling of missing capabilities field:
- test_get_models_missing_capabilities_without_tool_model
- test_get_models_missing_capabilities_with_tool_model
- test_get_models_mixed_capabilities_response

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* [autofix.ci] apply automated fixes

* fix: wrap long docstring line to satisfy ruff E501

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* docs: draft hide internal endpoints in spec (#11469)

* test-hide-internal-endpoints

* hide-more-endpoints

* display-mcp-endpoints

* display-mcp-projects

* add-back-health-check

---------

Co-authored-by: Hamza Rashid <74062092+HzaRashid@users.noreply.github.com>

* feat: update opensearch component with raw search component (#11491)

* Update opensearch_multimodal.py

* [autofix.ci] apply automated fixes

* Update opensearch_multimodal.py

* Skip existing knn_vector mapping & handle errors

Before adding a knn_vector field mapping, check the index properties and skip updating if the field already exists (and warn if dimensions differ). Attempt to add the mapping only when missing, and catch failures from the OpenSearch k-NN plugin (e.g. NullPointerException); in that known case log a warning and skip the mapping update instead of failing hard. After adding, verify the field is mapped as knn_vector and raise an error if it is not. Also adjusts logging messages to be clearer.

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* fix(test): Skip Tavily API key fill when global variable is loaded                                                          (#11733)

* update Google models

* [autofix.ci] apply automated fixes

* update tests

* mark deprecated

* build component index

* [autofix.ci] apply automated fixes

---------

Co-authored-by: olayinkaadelakun <olayinka.adelakun@ibm.com>
Co-authored-by: Olayinka Adelakun <olayinkaadelakun@Olayinkas-MacBook-Pro.local>
Co-authored-by: Carlos Coelho <80289056+carlosrcoelho@users.noreply.github.com>
Co-authored-by: Olayinka Adelakun <olayinkaadelakun@mac.war.can.ibm.com>
Co-authored-by: Cristhian Zanforlin Lousa <cristhian.lousa@gmail.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Gabriel Luiz Freitas Almeida <gabriel@logspace.ai>
Co-authored-by: Ram Gopal Srikar Katakam <44802869+RamGopalSrikar@users.noreply.github.com>
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
Co-authored-by: Mendon Kissling <59585235+mendonk@users.noreply.github.com>
Co-authored-by: Hamza Rashid <74062092+HzaRashid@users.noreply.github.com>
Co-authored-by: Edwin Jose <edwin.jose@datastax.com>

* fix: mock clearSessionMessages (#11776)

* fix: mock clearSessionMessages to prevent flowStore.getState error in test

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* [autofix.ci] apply automated fixes

---------

Co-authored-by: Viktor Avelino <viktor.avelino@gmail.com>
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* fix: Misleading Empty State when no Folders (#11728)

* fix: Misleading Empty State when no Folders

now once all folders are deleted we show the default create first flow state

* [autofix.ci] apply automated fixes

* fix(api): prevent users from deactivating their own account (#11736)

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>

* Fix:  UI Overlay: Chat Input Component Overlapping README Note (#11710)

* move chat input arround for travel json starter template

* improve the layout of the component

* fix layout

---------

Co-authored-by: Olayinka Adelakun <olayinkaadelakun@Olayinkas-MacBook-Pro.local>

---------

Co-authored-by: Carlos Coelho <80289056+carlosrcoelho@users.noreply.github.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Ram Gopal Srikar Katakam <44802869+RamGopalSrikar@users.noreply.github.com>
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
Co-authored-by: olayinkaadelakun <olayinka.adelakun@ibm.com>
Co-authored-by: Olayinka Adelakun <olayinkaadelakun@Olayinkas-MacBook-Pro.local>

* fix: Resolve Windows PostgreSQL event loop incompatibility (#11767)

* fix windows integrations with postgres

* add documentation

* cross platform validation

* [autofix.ci] apply automated fixes

* ruff style and checker

* fix import ruff

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* fix: Legacy "Store" Reference in Flows Empty State (#11721)

* fix: Legacy "Store" Reference in Flows Empty State

on delete propigate changes to useFlowsManagerStore to cause re-render in HomePage

* test: fix shard 45 flaky mcp test

Hopefully fix [WebServer] bash: line 1: exec: uvx mcp-server-fetch: not found

* [autofix.ci] apply automated fixes

* fix(api): prevent users from deactivating their own account (#11736)

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>

* Fix:  UI Overlay: Chat Input Component Overlapping README Note (#11710)

* move chat input arround for travel json starter template

* improve the layout of the component

* fix layout

---------

Co-authored-by: Olayinka Adelakun <olayinkaadelakun@Olayinkas-MacBook-Pro.local>

---------

Co-authored-by: Carlos Coelho <80289056+carlosrcoelho@users.noreply.github.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Ram Gopal Srikar Katakam <44802869+RamGopalSrikar@users.noreply.github.com>
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
Co-authored-by: olayinkaadelakun <olayinka.adelakun@ibm.com>
Co-authored-by: Olayinka Adelakun <olayinkaadelakun@Olayinkas-MacBook-Pro.local>

* Fix: UI Bug: "Lock Flow" Toggle in Export Modal is Non-Functional (#11724)

* fix locked component during export

* added locked flag to flow doc

* new testcases

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes

---------

Co-authored-by: Olayinka Adelakun <olayinkaadelakun@Olayinkas-MacBook-Pro.local>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* fix: dropdown delete icon hover visibility (#11774)

fix hidden delete button

Co-authored-by: Olayinka Adelakun <olayinkaadelakun@Olayinkas-MacBook-Pro.local>

* fix: resolve Safari scroll jitter in playground chat views (#11769)

* fix: resolve Safari scroll jitter in playground chat views

Switch StickToBottom resize mode to instant and add a Safari-specific
scroll fix that prevents unnatural jumps while preserving stick-to-bottom
behavior.

* [autofix.ci] apply automated fixes

* fix: add useStickToBottomContext mock to shareable playground tests

* refactor: improve SafariScrollFix reliability and maintainability

- Split into guard/inner components to avoid hooks on non-Safari browsers
- Extract magic numbers into named constants with documentation
- Convert touchStartY closure variable to useRef for proper session scoping
- Remove stopScrollRef indirection, use stopScroll directly in effect deps

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* fix: mock clearSessionMessages to prevent flowStore.getState error in test

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>

* fix: Obsolete "Component Share" shortcut listed in Shortcuts menu (#11775)

remove component share from doc

Co-authored-by: Olayinka Adelakun <olayinkaadelakun@Olayinkas-MacBook-Pro.local>

* fix(frontend): add UI feedback for self-deactivation prevention (#11772)

* fix(frontend): add UI feedback for self-deactivation prevention

Disable the Active checkbox with a tooltip when users try to deactivate
their own account. This provides clear UI feedback instead of relying
solely on the backend 403 error. Protection is added in both the Admin
page table view and the user edit modal.

* [autofix.ci] apply automated fixes

* fix: mock clearSessionMessages to prevent flowStore.getState error in test

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Viktor Avelino <viktor.avelino@gmail.com>

* fix(frontend): preserve sticky note dimensions when importing via canvas drop (#11770)

* fix(frontend): preserve sticky note dimensions when importing via canvas drop

When dragging a JSON file onto the canvas, the paste function now
preserves width and height properties from the original nodes,
ensuring sticky notes retain their custom dimensions.

* [autofix.ci] apply automated fixes

* fix: mock clearSessionMessages to prevent flowStore.getState error in test


---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Viktor Avelino <viktor.avelino@gmail.com>

* rollback playground, inspection panel and shareable playground

* fix: Close button auto-focus creates visual distraction in SaveChanges and FlowLogs modal (#11763)

fix autofocus on close button

Co-authored-by: Olayinka Adelakun <olayinkaadelakun@Olayinkas-MacBook-Pro.local>

* fix: Outdated Instructional Notes and Provider-Specific Branding (#11680)

* fix: improved note guide for language models nots and Need search

* missing starter projects added

* ensured main flows fit are of standard

* [autofix.ci] apply automated fixes

---------

Co-authored-by: Olayinka Adelakun <olayinkaadelakun@Olayinkas-MacBook-Pro.local>
Co-authored-by: Carlos Coelho <80289056+carlosrcoelho@users.noreply.github.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* fix(frontend): synchronize Prompt Template input fields on bracket mode toggle (#11777)

* fix(frontend): synchronize Prompt Template input fields on bracket mode toggle

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* fix(frontend): prevent deleted session messages from reappearing in new session (#11801)

* fix(frontend): prevent deleted session messages from reappearing in new sessions

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* chore: add secert base update

* chore: regenerate package-lock.json

* fix: add clean_output to field_order in SplitText starter project templates (#11842)

---------

Co-authored-by: Himavarsha <40851462+HimavarshaVS@users.noreply.github.com>
Co-authored-by: Gabriel Luiz Freitas Almeida <gabriel@logspace.ai>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Mike Pawlowski <mike.pawlowski@datastax.com>
Co-authored-by: Mike Pawlowski <mpawlow@ca.ibm.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Co-authored-by: ogabrielluiz <24829397+ogabrielluiz@users.noreply.github.com>
Co-authored-by: Deon Sanchez <69873175+deon-sanchez@users.noreply.github.com>
Co-authored-by: codeflash-ai[bot] <148906541+codeflash-ai[bot]@users.noreply.github.com>
Co-authored-by: Lucas Oliveira <62335616+lucaseduoli@users.noreply.github.com>
Co-authored-by: Viktor Avelino <64113566+viktoravelino@users.noreply.github.com>
Co-authored-by: Lucas Democh <ldgoularte@gmail.com>
Co-authored-by: Keval718 <kevalvirat@gmail.com>
Co-authored-by: Cristhian Zanforlin Lousa <cristhian.lousa@gmail.com>
Co-authored-by: Ram Gopal Srikar Katakam <44802869+RamGopalSrikar@users.noreply.github.com>
Co-authored-by: olayinkaadelakun <olayinka.adelakun@ibm.com>
Co-authored-by: Olayinka Adelakun <olayinkaadelakun@Olayinkas-MacBook-Pro.local>
Co-authored-by: Carlos Coelho <80289056+carlosrcoelho@users.noreply.github.com>
Co-authored-by: Jordan Frazier <122494242+jordanrfrazier@users.noreply.github.com>
Co-authored-by: Viktor Avelino <viktor.avelino@gmail.com>
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
Co-authored-by: Olayinka Adelakun <olayinkaadelakun@mac.war.can.ibm.com>
Co-authored-by: Mendon Kissling <59585235+mendonk@users.noreply.github.com>
Co-authored-by: Hamza Rashid <74062092+HzaRashid@users.noreply.github.com>
Co-authored-by: Edwin Jose <edwin.jose@datastax.com>
Co-authored-by: Adam-Aghili <149833988+Adam-Aghili@users.noreply.github.com>
Co-authored-by: Adam Aghili <Adam.Aghili@ibm.com>
2026-02-20 13:56:14 -05:00
Adam-Aghili
0c8c834df3 feat: update pre-release flow to be useable for qa (#11322)
* feat: create prerelease dedicated to qa

allow prerelease versions dedicated to qa

* chore: revert lfx dep to 0.2.1

* chore: lfx pyproject version 0.2.1 for testing

* feat: use pythin script to determine rc version

use a python script to auto incremenet rc version so we do not have to manually maintain what rc version we are on.
add it to both release.yml and docker-build-v2.yml for pypi, docker and ghrc.

* [autofix.ci] apply automated fixes

* chore: change script vars to more meaningful ones

* chore: add meaningful echos

* chore: add quotes to pass empty str if no version

* test: REVERT always pass ci REVERT

* chore: add normalization to built ver tests

* chore: remove unused uv environment set up

* chore: add back in checkout code

* chore: disable caching for ensure-lfx-published

* chore: revert changes added after merge

* fix: allow prerelase python install flag

* chore: test base and main install as 1

* chore: seperate base and main

* chore: install main using local base first

* chore: try using reinstall

* chore: create locl directory and use it first

* chore: try --no-deps

* chore: langflow-*.whl

* [autofix.ci] apply automated fixes

* fix: try using unsafe-best-match

use ./local-packages --index-strategy unsafe-best-match

* fix: add a dynamic constriant for langflow base

add a dynamic constriant for langflow base  during build-main. if this works I will need to go back and remove any unneeded cross-platform test changes

* chore: revert to normal install

* fix: add pre-main option to make build

* chore: remove hyphen in make var

* chore: keep propigation wait for pre-release

* chore: revert cross-platform-test.yml changes

* chore: use else ifdef and add test echos

* chore: remove --no-soruces

* chore: use ifeq

* chore: revert lfx 0.2.1

* chore: downgrade to python 3.12

ragstack-ai-knowledge-store does not support pythong 3.13

* chore: add else to Makefile

* chore: back to ifdef

* chore: reset to Makefile to main and add pre again

* chore: revert to python 3.13

* chore: set compatability check to 3.12

hopeffuly fixes
Found 1 incompatibility
The package `ragstack-ai-knowledge-store` requires Python >=3.9, <3.13, but `3.13.11` is installed

* [autofix.ci] apply automated fixes

* fix: new flow reset.

* chore: update LFX Determine version

* fix: remove buil-lfx dep on lfx release

* chore: remove more inputs.release_lfx if statments

* fix: uv pip install --find-links

* chore: create uv venv before uv pip install

* chire: attempt for reinatll of local whls

* fix: add OBJC_DISABLE_INITIALIZE_FORK_SAFETY: YES

add OBJC_DISABLE_INITIALIZE_FORK_SAFETY: YES to macos cross-platform test builds

* [autofix.ci] apply automated fixes

* chore: add back in ci step

* fix(ci): correctly generate pre-release rc tags

* [autofix.ci] apply automated fixes

* feat: update pre-release flow to be useable for qa

* Revert "feat: update pre-release flow to be useable for qa"

This reverts commit 22737729a2d0ed64ea774a30af070f0010cba9e1.

* feat: update pre-release flow to be useable for qa

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* feat: update pre-release flow to be useable for qa

* feat: update pre-release flow to be useable for qa

* feat: update pre-release flow to be useable for qa

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: vijay kumar katuri <vijaykaturi@vijays-MacBook-Air.local>
Co-authored-by: vijay kumar katuri <vijay.katuri@ibm.com>
2026-02-06 15:10:32 +00:00
Jordan Frazier
a097b685fd ci: add hash history script to nightly workflow (#11409)
* Add nightly hash history script to nightly workflow

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* Add lfx-nightly to script

* Handle first run

* Try fixing version on nightly hash history

* remove lfx lockfile since it does not exist

* Get full version in build, handle the [extras] in pyprojects

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* language update

* Handle extras in langflow-base dependency in all workflows

* [autofix.ci] apply automated fixes

* Fix import in lfx status response

* [autofix.ci] apply automated fixes

* Use built artifact for jobs, remove wait period

* use [complete] when building test cli job

* skip slack message added to success

* Update merge hash histry job to only run when ref is main

* Updates pyproject naming to add nightly suffix

* [autofix.ci] apply automated fixes

* Fix ordering of lfx imports'

* [autofix.ci] apply automated fixes

* Ah, ignore auto-import fixes by ruff

* [autofix.ci] apply automated fixes

* update test to look at _all_ exported instead

* [autofix.ci] apply automated fixes

* perf: Limit enum options in tool schemas to reduce token usage (#11370)

* fix current date tokens usage

* Update src/lfx/src/lfx/io/schema.py

* remove comment

---------

Co-authored-by: Himavarsha <40851462+HimavarshaVS@users.noreply.github.com>

* update date test to reflect changes to lfx

* ruff

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Cristhian Zanforlin Lousa <cristhian.lousa@gmail.com>
Co-authored-by: Himavarsha <40851462+HimavarshaVS@users.noreply.github.com>
2026-01-27 16:27:59 +00:00
Jordan Frazier
6a7512ef7d ci: update regex to handle new [complete] group in langflow-base dependency (#11417)
* Update regex to handle new [complete] group in langflow-base dependency

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* try using test-env python directly

* ruff

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2026-01-22 18:55:13 +00:00
Gabriel Luiz Freitas Almeida
60e3ab4970 fix: Remove blanket real_time_refresh options stripping and add dynamic loading to CurrentDate (#11400)
* fix: Update timezone options loading for CurrentDateComponent

* fix: Remove real-time refresh options stripping to stabilize component index

* Enhance component options in component_index.json

- Added language model options for agent_llm: "Anthropic", "OpenAI" and "OpenAI", "Custom".
- Introduced model_name option: "Select a model".
- Expanded HTTP method options for method: "GET", "POST", "PATCH", "PUT", "DELETE".
- Updated mode options to include: "URL", "cURL".
- Added search_mode options: "Web", "News", "RSS".
- Defined environment options for Astra DB API Endpoint: "prod", "test", "dev".
- Specified search_method options: "Hybrid Search", "Vector Search".
- Included chunker options: "HybridChunker", "HierarchicalChunker".
- Added tokenizer provider options: "Hugging Face", "OpenAI".
- Defined export_format options: "Markdown", "HTML", "Plaintext", "DocTags".
- Introduced auth_mode options: "basic", "jwt".
- Updated pipeline options: "standard", "vlm".
- Specified storage_location options for reading and saving files: "Local", "AWS", "Google Drive".
- Expanded operator options for text comparison.
- Updated repo_source options: "Local", "Remote".
- Updated dependencies version for google to "2.5.0".
- Added model_id options for Hugging Face Hub.
- Defined base_url options for IBM API.
- Updated mode options for message operations: "Retrieve", "Store".
- Enhanced mirostat options: "Disabled", "Mirostat", "Mirostat 2.0".
- Expanded model_name options for various GPT models.
- Updated DataFrame operation options with icons.
- Enhanced text operation options with icons.
- Specified output_type options: "Message", "Data", "DataFrame".
- Updated CurrentDateComponent to dynamically load timezone options.

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2026-01-21 20:47:47 +00:00
Gabriel Luiz Freitas Almeida
862fdaa346 fix: Make component index deterministic and conflict-resolvable (#11392)
* feat: Dynamically load LiteLLM model options in AstraAssistantManager

* fix: Strip options from fields with real_time_refresh to ensure stable component index

* update index

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2026-01-21 15:22:02 +00:00
Steve Haertel
b3df3a7c35 feat: Add global variable support for MCP server headers (#11300)
* feat: Add global variable support for MCP server headers

- Add IOKeyPairInputWithVariables component for header inputs with global variable dropdown
- Integrate global variable selection in MCP Server modal
- Add variable resolution in MCP server headers (_resolve_global_variables_in_headers)
- Add variable loading and decryption in MCP API endpoint and component
- Add unit tests for variable resolution utility function

* test: Add comprehensive unit tests for IOKeyPairInputWithVariables component

- Add 15 test cases covering rendering, user interactions, and edge cases
- Test global variable dropdown functionality and selection
- Test row addition/removal and input validation
- Test duplicate key detection and error handling
- Test initialization from existing values with variable badges
- Addresses CodeRabbit review feedback for frontend test coverage

* [autofix.ci] apply automated fixes

* test: fix frontend Jest tests for IOKeyPairInputWithVariables component

- Added proper mocks for IconComponent, InputComponent, and Input
- Used explicit TypeScript types instead of 'any' for mock props
- Fixed test assertions to match actual component structure (Type key.../Type a value... placeholders)
- All 8 tests now pass without console warnings
- Tests cover: rendering, onChange callbacks, add/delete buttons, global variables toggle

* fix: restore session_scope import to module level for test mocking

The session_scope import was moved inside _process_headers method, which broke
unit tests that mock it at the module level. Restored it to module-level imports
with noqa comment to prevent ruff from removing it, and removed the duplicate
import from inside the method.

Fixes: test_database_config_used_when_no_value_config

* chore: trigger CI rebuild to test for flaky Playwright test

* Update component index

* chore: update Nvidia Remix starter project with session_scope import fix

* perf(mcp): optimize global variable loading to prevent timeouts

Only load global variables from database when headers are actually present
in the MCP server config. This avoids unnecessary database queries for
servers without headers, significantly improving performance and preventing
timeouts in tests that repeatedly connect to MCP servers.

The optimization adds a conditional check before the database query:
- has_headers = server_config.get('headers') and len(server_config.get('headers', {})) > 0
- Only queries database if has_headers is True

This resolves the cumulative delay issue where each MCP connection retry
was performing an expensive database query even when no headers were configured.

* [autofix.ci] apply automated fixes

* fix(test): update Playwright test for new header input component structure

Update MCP server Playwright test to work with the new KeyPairInputWithVariables
component that uses InputComponent with global variable support for header values.

Changes:
- Use getByPlaceholder() instead of getByTestId() for header value fields
- Header value fields now use InputComponent which doesn't expose data-testid

The new component structure wraps the value input in InputComponent to provide
global variable dropdown functionality, requiring a different selector strategy.

* chore: update Nvidia Remix starter project

Update starter project file that was modified by the automated build pipeline.

* Update component index

* fix: replace jose with jwt (#11285)

* replace jose with jwt

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* [autofix.ci] apply automated fixes (attempt 3/3)

* pin to lower pyjwt

* pyjwt version

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* [autofix.ci] apply automated fixes (attempt 3/3)

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* Update component index

* Update component index

* [autofix.ci] apply automated fixes

* Update component index

* chore: trigger CI rebuild

* [autofix.ci] apply automated fixes

* refactor: remove langflow imports from lfx MCP component

Separate lfx from langflow by using the service layer pattern:

Changes:
1. Extended VariableServiceProtocol in lfx with get_all_decrypted_variables()
2. Implemented the method in langflow's DatabaseVariableService
3. Updated MCP component to use get_variable_service() instead of direct imports
4. Added comprehensive unit tests for the new service method

Benefits:
- Clean separation between lfx and langflow packages
- Uses existing service architecture pattern
- Maintains performance optimization (only loads variables when needed)
- No breaking changes to functionality

Removed direct langflow imports from mcp_component.py (auth utils, Variable model, settings service, and sqlmodel select).

Files modified:
- src/lfx/src/lfx/services/interfaces.py
- src/backend/base/langflow/services/variable/service.py
- src/lfx/src/lfx/components/models_and_agents/mcp_component.py
- src/backend/tests/unit/services/variable/test_service.py (added 3 new tests)

* fix: Handle global variables correctly for components

- Fix UUID type conversion in variable service to prevent SQLAlchemy errors
- Add type-based decryption: only decrypt CREDENTIAL variables, not GENERIC
- Improve error handling in decrypt_api_key to prevent crashes on second attempt
- Resolves 'str object has no attribute hex' error when loading global variables

This fixes issues with watsonx.ai and MCP components when using global variables.

* [autofix.ci] apply automated fixes

* Update component index

* Consider other failed decryption cases

* fix(variable-service): Fix UUID conversion and type-based variable decryption

- Convert string to UUID in get_all_decrypted_variables() to prevent SQLAlchemy errors
- Implement type-based decryption: only decrypt CREDENTIAL variables, not GENERIC
- Simplify get_all() to return stored values directly for both variable types
- Fixes watsonx component update error (400 status) when editing values

Resolves issue where editing watsonx.ai component values caused:
'Error while updating the Component' with 400 client error

* [autofix.ci] apply automated fixes

* chore: update starter project files

* fix: remove explicit value assignment to allow credential redaction

* fix: handle credential redaction in frontend and fix Playwright test hangs

- Update GlobalVariableModal to handle None credential values
- Allow credential updates without re-entering value
- Fix userSettings test by using dispatchEvent for clicks
- Add waitForTimeout after clicks to prevent hangs
- Use .first() for Fields selectors to avoid strict mode violations

* [autofix.ci] apply automated fixes

* Update component index

* [autofix.ci] apply automated fixes

* fix: improve error handling and logging for variable decryption

Address code review feedback:

1. Increase log level from debug to warning when decryption fails in
   auth/utils.py. Returning empty string silently could cause issues,
   so warning level makes failures more visible.

2. Follow established pattern in mcp.py for variable decryption:
   - Only decrypt CREDENTIAL type variables (encrypted in storage)
   - Use GENERIC type variables as-is (stored as plaintext)
   - Change from silent fallback (adebug) to explicit error (aerror)
   - This matches the pattern in get_all_decrypted_variables()

These changes make error handling more explicit and consistent across
the codebase.

* Update component index

* Update component index

* [autofix.ci] apply automated fixes

* chore: trigger CI rebuild

* [autofix.ci] apply automated fixes

* Updates to ensure backwards compatibility for encrypted generic variables

* Skip failed decryption

* Fix test

* ruff

* update starter projects

* ruff

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* comp index

* [autofix.ci] apply automated fixes

* remove unnecessary step in pandas series conversion

---------

Co-authored-by: Steve Haertel <shaertel@ca.ibm.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Himavarsha <40851462+HimavarshaVS@users.noreply.github.com>
Co-authored-by: Jordan Frazier <jordan.frazier@datastax.com>
2026-01-20 19:03:30 +00:00
Jordan Frazier
50bab0a4e7 feat: introduce component hash history (#11311)
* Remove hash history from index

* first draft of adding component id and stable hash history

* Simplify - use version -> hash mapping

* Add unit tests and simple safeguards for stable vs nightly

* Add uniqueness check for comp id in comp index build

* Remove component id - use name as unique id

* Use component name as unique identifier - fix tests

* regenerate hash history; add script to makefile

* Remove component id

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* [autofix.ci] apply automated fixes (attempt 3/3)

* ruff

* comp index

* ruff

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* update index

* ruff

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2026-01-20 14:00:54 +00:00
Jordan Frazier
3166d1f08f fix: use lfx versions instead of langflow for comp index (#11260)
* Use lfx versions instead of langflow for comp index

* lfx langugage

* ruff

* [autofix.ci] apply automated fixes

* update index

* [autofix.ci] apply automated fixes

* Update the version key names

* [autofix.ci] apply automated fixes

* update comp index

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2026-01-11 18:04:50 +00:00
Jordan Frazier
3006b139c5 feat: add versioned hash to component index (#11244)
* Add versioned hash to component index

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* Remove fake backwards compatible code and associated tests

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* [autofix.ci] apply automated fixes (attempt 3/3)

* remove unused function, update index

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* fix history merge again

* [autofix.ci] apply automated fixes

* Remove unnecessary concepts, simplify

* ruff

* [autofix.ci] apply automated fixes

* ruff

* [autofix.ci] apply automated fixes

* fail fast

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* Fix tests, fail fast

* ruff

* [autofix.ci] apply automated fixes

* Correctly strip out hash history when loading components from index

* Add tests for the hash history in comps

* [autofix.ci] apply automated fixes

* remove unused logger

* remove deepcopy and attempt to fix logger timeout test

* update comp index

* starter projects

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2026-01-09 15:34:10 +00:00
olayinkaadelakun
46539f5ca8 Fix: component_index autofix (#11093)
* fix: strip runtime variable

* [autofix.ci] apply automated fixes

* fix: install BE dependecies befor generating the component_index

* fix: testcase added

* [autofix.ci] apply automated fixes

---------

Co-authored-by: Olayinka Adelakun <olayinkaadelakun@mac.war.can.ibm.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Olayinka Adelakun <olayinkaadelakun@Olayinkas-MacBook-Pro.local>
2025-12-19 16:30:19 +00:00
Rico Furtado
348b1b86ce feat: Version 1.2 - comprehensive database migration guidelines using… (#10519)
* feat: Version 1.2 - comprehensive database migration guidelines using the Expand-Contract pattern

* Update src/backend/base/langflow/alembic/DB-MIGRATION-GUIDE.MD

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* fix: Cleanup text and typos

* feat: Implement migration validation workflow and add migration validator scripts

* Update src/backend/base/langflow/alembic/migration_validator.py

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update src/backend/base/langflow/alembic/migration_validator.py

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update src/backend/base/langflow/alembic/migration_validator.py

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* fix: moved the test_migrations directory to under tests

* feat: Added migration validator to pre-commit check.

* fix: improved test performance.

* fix: optimized attribute resolution in migration validator

* feat: add comprehensive tests for migration validator and guidelines

* fix: Lint is complaining about shebang declared but not being used.

* fix: Shebang reinstated.

* Update src/backend/base/langflow/alembic/DB-MIGRATION-GUIDE.MD

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update .github/workflows/migration-validation.yml

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* feat: color improvments

* Update .github/workflows/migration-validation.yml

Removed

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update .github/workflows/migration-validation.yml

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* ci: Created relative paths for CI

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* [autofix.ci] apply automated fixes (attempt 3/3)

* fix: Component index json.

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* [autofix.ci] apply automated fixes (attempt 3/3)

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2025-11-24 23:09:11 +00:00
Madhavan
d0f95fd9b9 test: catch import errors upfront (#10632)
* Convert to async and ruff-friendly print

* Implement the checking into existing test file itself

* Remove the newly introduced lfx test which is now incorporated into existing tests

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* [autofix.ci] apply automated fixes (attempt 3/3)

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* [autofix.ci] apply automated fixes (attempt 3/3)

* Run make build_component_index after merging latest from main

* [autofix.ci] apply automated fixes

* Revert "docs: update component documentation links to individual pages"

This reverts commit 1da51d4ccb.

* build component index after origin/main merge into feature branch

* [autofix.ci] apply automated fixes

---------

Co-authored-by: Madhavan <cxo@ibm.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Mendon Kissling <59585235+mendonk@users.noreply.github.com>
2025-11-24 19:02:06 +00:00
Jordan Frazier
f4ba646f21 build: upgrade to 1.7.0 (#10418)
* Update version to 1.6.7

* bump lfx too

* choosed current versino in openapi.json of 1.6.5 vs 1.6.7

* choosed current versino in openapi.json of 1.6.5 vs 1.6.7

* more version bumps

* missed this one

* change pypi_nightly_tag.py version to read it from pyproject.toml directly

* get_latest_version was missing arg build_type

* naming error

* using lfx logic to explore for MAIN_PAGE

* using lfx logic to explore for MAIN_PAGE

* allow --prerelease

* change script in nightly_build

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* [autofix.ci] apply automated fixes (attempt 3/3)

---------

Co-authored-by: Olfa Maslah <olfamaslah@Olfas-MacBook-Pro.local>
Co-authored-by: Olfa Maslah <olfamaslah@macbookpro.war.can.ibm.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2025-11-04 18:46:11 +00:00
Ítalo Johnny
774772eed3 fix(windows): ensure psycopg async compatibility by setting WindowsSe… (#9899)
* fix(windows): ensure psycopg async compatibility by setting WindowsSelectorEventLoopPolicy

* [autofix.ci] apply automated fixes

* add build only script windows

* 📝 (langflow/__main__.py): add type ignore comment to suppress attribute defined error for asyncio set_event_loop_policy on Windows platform

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Cris Zanforlin <cris.zanforlin@datastax.com>
Co-authored-by: Cristhian Zanforlin Lousa <cristhian.lousa@gmail.com>
2025-10-17 15:17:52 +00:00
Gabriel Luiz Freitas Almeida
fd74f194dd feat: add static components index to avoid rebuild on startup (#10181)
* feat: add script to build static component index for fast startup

This script generates a prebuilt index of all built-in components in the lfx.components package, saving it as a JSON file for quick loading at runtime. It includes versioning and integrity verification through SHA256 hashing.

* chore: update package dependencies and versioning

- Bump revision to 3 in uv.lock.
- Update dependency markers for several packages to improve compatibility with Python versions and platforms.
- Increment versions for langflow (1.6.4) and langflow-base (0.6.4).
- Adjust dependency markers for packages related to darwin platform to enhance specificity.

* chore: update .gitignore to include component index cache

- Added entry for user-specific component index cache directory to .gitignore.
- Included member_servers.json in the ignore list for better file management.

* feat: enhance component loading with custom index support

- Introduced functions to detect development mode and read a custom component index from a specified path or URL.
- Added caching mechanism for dynamically generated component indices to improve performance.
- Updated `import_langflow_components` to utilize the new index reading and caching logic, allowing for faster startup in production mode.
- Added `components_index_path` to settings for user-defined index configuration.

* feat: add GitHub Actions workflow to automatically update component index

- Introduced a new workflow that triggers on pull requests and manual dispatch to update the component index.
- The workflow checks for changes in the component index and commits updates if necessary.
- Added a comment feature to notify users when the component index is updated.

* [autofix.ci] apply automated fixes

* fix: enhance development mode detection logic

- Updated the `_dev_mode` function to improve clarity and functionality in detecting development mode.
- Refined environment variable checks to explicitly handle "1"/"true"/"yes" for development and "0"/"false"/"no" for production.
- Maintained the editable install heuristic as a fallback for determining the mode when the environment variable is not set.

* refactor: simplify development mode detection logic

- Revised the `_dev_mode` function to clarify the detection of development mode.
- Removed the editable install heuristic, making the environment variable `LFX_DEV` the sole determinant for development mode.
- Updated documentation to reflect the new behavior and ensure accurate understanding of the mode switching.

* docs: update DEVELOPMENT.md to clarify component development mode

- Added tips for enabling dynamic component loading with `LFX_DEV=1` for faster development.
- Emphasized the importance of using `LFX_DEV=1` for live reloading of components during development.
- Included instructions for manually rebuilding the component index for testing purposes.

* add component index

* test: add unit tests for component index functionality

- Introduced comprehensive unit tests for the component index system, covering functions such as _dev_mode, _read_component_index, _save_generated_index, and import_langflow_components.
- Tests include various scenarios for development mode detection, reading and saving component indices, and handling custom paths and URLs.
- Enhanced test coverage to ensure robustness and reliability of the component index features.

* chore: update GitHub Actions workflow for component index updates

- Modified the workflow to include separate checkout steps for pull requests and manual dispatch events.
- Added an environment variable `LFX_DEV` to the build step for enhanced development mode support.
- Improved clarity in the workflow structure to accommodate different triggering events.

* chore: update component index with new timezones and remove deprecated entries

- Added new timezone options including America/Boise, Australia/North, and Etc/GMT-2.
- Removed outdated timezone entries to streamline the selection process.
- Updated the component index structure to enhance clarity and maintainability.

* docs: clarify output path determination in build_component_index.py

- Updated comment to specify that the output path is relative to the script location and intended for development/CI use, not from the installed package.
- Enhanced clarity for future developers regarding the script's execution context.

* refactor: update component import logic and structure

- Changed the comment to reflect the correct module path for extracting subpackage names.
- Flattened the custom components dictionary if it has a "components" wrapper for consistency.
- Merged built-in and custom components into a single structure, ensuring the output maintains a "components" wrapper.
- Updated the component count calculation to reflect the new merged structure.

* refactor: streamline component merging logic

- Simplified the merging of built-in and custom components by removing the "components" wrapper at the cache level.
- Updated the component count calculation to directly reflect the new structure of the merged components.
- Enhanced code clarity by refining comments related to the merging process.

* chore: enhance GitHub Actions workflow for component index updates

- Updated the workflow to conditionally comment on pull requests from community forks, instructing users to manually update the component index.
- Refined the commit and push logic to ensure it only executes for changes made within the same repository.

* chore: update component index [skip ci]

* chore: refine GitHub Actions workflow for component index checks

- Enhanced the logic to check for changes in the component index file, ensuring it only triggers actions for changes made within the same repository.
- Updated the PR comment step to clarify that it applies only to pull requests from the same repository, improving workflow accuracy.

* chore: update component index [skip ci]

* chore: update component index [skip ci]

* refactor: rename version retrieval function for clarity

- Changed the function name from _get_lfx_version to _get_langflow_version to accurately reflect the version being retrieved.
- Updated the version retrieval logic in the build_component_index function to use the new function name.

* fix: update version check to reflect langflow instead of lfx

- Changed the version check logic in the _read_component_index and _save_generated_index functions to use "langflow" instead of "lfx".
- Ensured that the component index version matches the installed langflow version for better accuracy.

* fix: sort timezone options in CurrentDateComponent

- Updated the timezone options in the CurrentDateComponent to be sorted for better user experience.
- Ensured that the dropdown displays timezones in a consistent and organized manner.

* chore: update component index with new timezone options and MistralAI model configurations

- Replaced outdated timezone options with a more relevant and diverse set for improved user experience.
- Added new configurations for the MistralAI model component, including input fields for API key, model selection, and request parameters.
- Updated version number to reflect recent changes.

* chore: update component index [skip ci]

* chore: update component index [skip ci]

* chore: update component index [skip ci]

* chore: update component index [skip ci]

* chore: minify component index output to reduce file size

* test: Add unit tests for build_component_index script functionality

* chore: enhance push logic in update-component-index workflow to handle concurrent updates with retries

* chore: update component index [skip ci]

* fix: standardize logging messages for MCP server initialization

* chore: update component index [skip ci]

* test: Add unit tests for build_component_index script functionality

* chore: update component index [skip ci]

* fix: improve error handling for missing LangChain dependencies in run.py

* feat: add deterministic normalization for component index serialization

* chore: update component index [skip ci]

* chore: update component index

* chore: update component index

* chore: update component index

* chore: enhance component index update workflow with detailed diff statistics and SHA256 comparison

* chore: update component index

* chore: update component loading message to reflect total components discovered

* chore: sort model options for improved readability in NVIDIA component

* chore: filter out 'localtime' from timezone options for improved user experience

* chore: update component index with sorted lists

* chore: update component index with mistral

* chore: update component index

* fix: improve error message for langflow tests to include detailed instructions for environment setup

* refactor: rename and enhance _dev_mode function to _parse_dev_mode for improved clarity and functionality; support boolean and list modes for module loading

* docs: enhance DEVELOPMENT.md with updated instructions for Component Development Mode, including dynamic loading options for specific components

* fix: enhance error handling in _read_component_index to log specific issues with fetching and parsing component indices, including corrupted JSON and missing SHA256 hash

* chore: update component index

* feat: add metadata to component index including number of modules and components for improved indexing information

* feat: integrate telemetry for component index loading, capturing metrics on modules and components, and enhancing performance tracking

* feat: add build command for dynamic component index generation

* fix: add missing import for json in CustomComponent definition in LoopTest.json

* fix: improve handling of dotted imports in prepare_global_scope function

* chore: update component index

* fix: refine import handling in prepare_global_scope to correctly manage aliased and dotted imports

* chore: update component index

* feat: enhance component index update workflow with detailed change analysis and summary

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2025-10-13 18:54:17 +00:00
Gabriel Luiz Freitas Almeida
719fc0409d ci: Add validation for frontend file coverage in CI workflow (#10052)
* feat: add script to verify frontend file coverage against changes-filter.yaml

* feat: add validation step for filter coverage in CI workflow

* fix: update CI workflow to improve filter coverage validation

- Enhanced the validation step for filter coverage by fetching the base reference dynamically based on the event type.
- Adjusted the diff command to compare against the correct base reference, ensuring accurate coverage checks.
- Minor formatting improvements for clarity in the CI configuration.

* fix: update CI workflow to allow continued execution on filter coverage validation errors

- Set `continue-on-error` to true for the filter coverage validation step, ensuring that the CI process continues even if this step fails.
- Minor formatting adjustments for improved readability in the CI configuration.

* refactor: enhance filter pattern loading and matching in check_changes_filter.py

- Improved the load_filter_patterns function to validate and normalize the YAML structure, ensuring it returns a properly formatted dictionary.
- Added error handling for empty or invalid filter files, including type checks for keys and values.
- Enhanced the matches_pattern function to support brace expansion and improved matching logic using pathlib and fnmatch for better pattern handling.

* chore: update CI workflow to set up Python 3.12 and improve filter coverage validation

- Added a step to set up Python 3.12 in the CI workflow.
- Installed necessary dependencies for coverage checks.
- Enhanced the filter coverage validation step by dynamically fetching the base commit and reference, ensuring accurate comparisons for coverage checks.
2025-10-08 20:45:19 +00:00
Eric Hare
662f0695c8 fix: Proper support for VLM in Docling (#10094)
* fix: Proper support for VLM in Docling

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* Update file.py

* [autofix.ci] apply automated fixes

* Update pyproject.toml

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

* Update uv.lock

* Fix project specs

* Add jpg as accepted file type

* [autofix.ci] apply automated fixes

* Update dep structure

* One more attempt at getting this right

* And again

* Add docling core

* Update pyproject.toml

* Update deps

* [autofix.ci] apply automated fixes

* Update knowledge_bases.py

* Package version bumps

* Add pytest tests for advanced mode

* Update test_file_component.py

* Update test_file_component.py

* Make pipeline a visible option in advanced mode

* Feat tool mode files (#10107)

* feat: Tool Mode Support for File Components

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* feat: Better support for advanced parser in File Component (#10048)

* feat: Better support for advanced parser in files

* [autofix.ci] apply automated fixes

* Add docling mocked tests

* Update file.py

* Update test_file_component.py

* [autofix.ci] apply automated fixes

* Update News Aggregator.json

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* Update file.py

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
2025-10-03 18:39:33 +00:00
Himavarsha
1ebcacf852 fix: Update dependency versions - pyproject.toml (#10028)
* add upper bound to dependencies

* create more relaxed bounds

* change langchain-* to have upper bound

* add upper bound to dependencies

* cleanup root toml

* change base toml and lock files

* update dependencies inside lfx

* rollback cryptography to prev version

* Handle some mypy checks in main

* fix: Update the cryptography package to avoid vuln

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* [autofix.ci] apply automated fixes

* fix: Bump respx version for compat

* Fix ruff

* [autofix.ci] apply automated fixes

* Ran uv lock upgrade

* update starter

* fix mmypy errors

* remove upper bounds for dev dependencies

* [autofix.ci] apply automated fixes

---------

Co-authored-by: Himavarsha Goutham <himavarshagoutham@himavarshas-mbp.home>
Co-authored-by: Eric Hare <ericrhare@gmail.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Jordan Frazier <jordan.frazier@datastax.com>
2025-10-02 14:47:56 +00:00
Edwin Jose
fbad5fad5c fix: Update Ruff issues in lfx and backend (#10006)
* Update test_exception_telemetry.py

* Refactor unused variables in subprocess and test code

Replaced unused variables 'stderr' and 'func' with underscores in subprocess communication and test telemetry code to clarify intent and avoid linting warnings.

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* Use re.escape for exception match in tests

Updated test cases to use re.escape for matching exception messages in pytest.raises, improving reliability when matching error strings containing special characters. Also replaced unused tuple variables with underscores for clarity.

* Fix various ruff errors in lfx

* Reorder pydantic imports in unit tests

Moved pydantic imports below other imports for consistency and improved readability across multiple unit test files.

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* Update test_directory_component.py

* [autofix.ci] apply automated fixes

* Update test_validate.py

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Eric Hare <ericrhare@gmail.com>
2025-09-26 22:35:00 +00:00
Cristhian Zanforlin Lousa
925767d22c fix: Ensure consistent Langflow startup in Windows scripts (#9917)
fix windows .env location
2025-09-24 18:08:42 +00:00
Gabriel Luiz Freitas Almeida
52856ff964 ci: Add LFX release workflow and update nightly build script (#9663) 2025-09-03 16:39:07 -03:00
Gabriel Luiz Freitas Almeida
aaaaed1e59 feat: introduce lfx package (#9133)
* docs: add README for lfx CLI tool

- Created a comprehensive README for the lfx command-line tool, detailing installation instructions, command usage, and examples for both `serve` and `execute` commands.
- Included sections on input sources and development setup to enhance user understanding and facilitate contributions.

* fix: update import paths and test assertions in queryInputComponent.spec.ts

- Modified import statements to reflect the new module structure, changing `langflow` to `lfx` for consistency.
- Adjusted test assertions to ensure proper syntax and functionality, enhancing the reliability of the test suite.

* fix: streamline test assertions and update import paths in tabComponent.spec.ts

- Refactored test assertions for tab visibility to improve readability and maintainability.
- Updated import paths from `langflow` to `lfx` for consistency with the new module structure.
- Ensured proper syntax in test cases to enhance the reliability of the test suite.

* fix: skip table input component test due to UI event conflicts

- Marked the test for user interaction with the table input component as skipped due to conflicts between double-click and single-click events.
- Added a comment to indicate the need for further investigation into event handling issues affecting this branch.

* fix: update CLI test cases to include 'serve' command

- Modified test cases in `test_serve_simple.py` to include the 'serve' command in the CLI invocation, ensuring accurate testing of command behavior.
- Adjusted assertions to maintain consistency and reliability in test outcomes when handling various scenarios, such as missing API keys and invalid JSON inputs.

* feat: implement LFX nightly release workflow in GitHub Actions

- Added a new job for releasing LFX nightly builds, including steps for checking out code, setting up the environment, installing dependencies, verifying versioning, building the package, testing the CLI, publishing to PyPI, and uploading artifacts.
- Introduced a wait step for PyPI propagation to ensure successful package availability post-release.
- Refactored existing release job structure to accommodate the new LFX workflow while maintaining the Langflow nightly base release process.

* refactor: Simplify flow execution validation by removing unnecessary asyncio.wait_for calls

Updated the validate_flow_execution function to directly use the client.post and client.get methods with a timeout parameter, improving code readability and maintainability. This change eliminates redundant timeout handling while ensuring consistent timeout values across API calls.

* refactor: Enhance template tests for improved structure and validation

Refactored the template tests in `test_starter_projects.py` to utilize parameterization for better readability and maintainability. Introduced helper functions to retrieve template files and disabled tracing for all tests. Updated individual test methods to validate JSON structure, flow execution, and endpoint validation, ensuring comprehensive coverage of template functionality. This change streamlines the testing process and enhances the robustness of the test suite.

* refactor: Update project metadata and import paths in starter project JSON files

Modified the metadata section in multiple starter project JSON files to reflect updated code hashes and module paths, transitioning from 'lfx' to 'langflow' components. This change enhances consistency across the codebase and ensures that the correct modules are referenced for improved maintainability and clarity.

* chore: Update template test commands to utilize parallel execution

Modified the commands in the Makefile and CI workflows to include the `-n auto` option for pytest, enabling parallel test execution for the starter project template tests. This change enhances test performance and efficiency across the codebase.

* chore: Remove  news-aggregated.json file

Deleted the news-aggregated.json file

* chore: Update .gitignore to include new files

Added entries for *.mcp.json, news-aggregated.json, and CLAUDE.md to the .gitignore file to prevent these files from being tracked in the repository.

* refactor: Update module paths and code hashes in starter project JSON files

Modified the metadata section in multiple starter project JSON files to transition module paths from 'langflow' to 'lfx' components and updated code hashes accordingly. This change enhances consistency and maintainability across the codebase, ensuring that the correct modules are referenced.

* refactor: Remove debug logging from module processing function

Eliminated the debug log statement in the _process_single_module function to streamline logging output. This change enhances code clarity and reduces unnecessary log clutter during module processing.

* refactor: Update import paths and clean up component exports

Modified import statements to transition from 'langflow' to 'lfx' in the field_typing module and adjusted component exports in various modules by removing unused components. This change enhances code organization and maintainability across the codebase.

* fix: Add timeout header to flow execution validation test

Updated the headers in the flow execution validation test to include a timeout value. This change ensures that the test accurately reflects the expected behavior of the validate_flow_execution function when handling timeouts, enhancing the robustness of the test suite.

* fix: Add timeout to mock client delete assertion in flow execution validation test

Updated the mock client delete assertion in the flow execution validation test to include a timeout value. This change ensures that the test accurately reflects the expected behavior when handling timeouts, contributing to the robustness of the test suite.

* refactor: Update Dockerfile to use Alpine-based Python image and install build dependencies

Changed the base image in the Dockerfile to an Alpine-based Python image for a smaller footprint. Added installation of necessary build dependencies for Python packages on Alpine. Updated user creation to follow best practices for non-root users. This change enhances the efficiency and security of the Docker build process.

* refactor: move development mode toggle functions in settings to lfx

Introduced `_set_dev` and `set_dev` functions in `settings.py` to manage the development mode flag. Updated import path in `base.py` to reflect the new function location. This change enhances the configurability of the development environment.

* feat: Register SettingsServiceFactory in service manager

Added registration of the SettingsServiceFactory in the service manager if it is not already present. This change ensures that the settings service is available for retrieval, enhancing the functionality of the service management system.

* feat: Add global variable validation option to serve and execute commands

Introduced a new option to the serve and execute commands to check global variables for environment compatibility. This enhancement allows users to validate their configurations before execution, improving robustness and error handling in the application. Validation errors are reported clearly, and users can choose to skip this check if desired.

* refactor: Remove unused development mode functions from settings

Eliminated the `_set_dev` and `set_dev` functions from `settings.py` and their associated validator in `base.py`. This change simplifies the code by removing unnecessary functions, enhancing maintainability and clarity in the settings management.

* fix: Update load_graph_from_path to include verbose parameter in JSON handling

Modified the `load_graph_from_path` function to accept the file suffix as an argument when loading JSON graphs. Updated related tests to ensure correct behavior with the new parameter, including assertions for verbose logging. This change enhances error handling and logging clarity during graph loading operations.

* [autofix.ci] apply automated fixes

* refactor: Update import paths for version utilities in settings

Changed the import statements in `base.py` to source version utility functions from `lfx.utils.version` instead of `langflow.utils.version`. Additionally, added the `is_pre_release` function to `version.py` to check for pre-release indicators in version strings. This refactor improves code organization and aligns with the updated module structure.

* feat: Add BuildStatus schema for API compatibility

Introduced a new BuildStatus class in the schema module to define the structure for build status responses. This addition enhances API compatibility by providing a standardized way to convey build status, including optional message and progress fields. Updated import paths in the cache utility to reflect the new schema location.

* refactor: Update import path for EventManager in component_tool.py

Changed the import statement for EventManager to reflect its new location in the lfx.events module. This update improves code organization and maintains consistency with the updated module structure.

* refactor: Improve file upload handling in SaveToFileComponent

Updated the _upload_file method to dynamically import necessary functions for file upload, enhancing error handling for missing Langflow functionality. Refactored session management to use async context with session_scope, improving code clarity and maintainability.

* refactor: Enhance import handling in MCPToolsComponent for Langflow dependencies

Updated the MCPToolsComponent to dynamically import Langflow-related functions within a try-except block, improving error handling for missing functionality. This change ensures that users receive a clear message when the Langflow MCP server features are unavailable, enhancing robustness and maintainability of the code.

* refactor: Update JSON handling in JSONDocumentBuilder to use orjson directly

Replaced the use of orjson_dumps with orjson.dumps for serializing documents in the JSONDocumentBuilder class. This change improves performance and simplifies the code by directly utilizing orjson for JSON serialization, enhancing overall code clarity and maintainability.

* refactor: Improve error handling for Langflow Flow model import in get_flow_snake_case

Updated the get_flow_snake_case function to dynamically import the Flow model within a try-except block. This change enhances error handling by providing a clear message when the Langflow installation is missing, improving the robustness and maintainability of the code.

* chore: Add orjson as a dependency in project configuration

Included orjson in both the uv.lock and pyproject.toml files to ensure proper JSON handling and serialization capabilities. This addition enhances the project's performance and maintains consistency in dependency management.

* [autofix.ci] apply automated fixes

* refactor: Convert execute function to async and update JSON flow loading

Refactored the execute function to be asynchronous using syncify, allowing for non-blocking execution. Updated the JSON flow loading to utilize aload_flow_from_json for improved performance. Adjusted the results handling to support asynchronous graph execution, enhancing overall code efficiency and maintainability.

* refactor: Enhance import handling for Langchain dependencies in validate.py and constants.py

Updated the validate.py file to suppress LangChainDeprecationWarning during dynamic imports. In constants.py, renamed DEFAULT_IMPORT_STRING for clarity and added a conditional import string based on the presence of the Langchain module. These changes improve error handling and maintainability of the code.

* refactor: Improve error handling and output formatting in execute function

Enhanced the execute function by introducing a dedicated output_error function for consistent error messaging in both JSON and verbose formats. Updated error handling throughout the function to utilize this new method, improving clarity and maintainability. Adjusted the handling of input sources and validation errors to provide more informative feedback to users.

* feat: Add simple chat flow example with JSON and Python integration

Introduced a new simple chat flow example demonstrating the use of ChatInput and ChatOutput components. This includes a JSON configuration file and a Python script that sets up a basic conversational flow, enhancing the documentation and usability of Langflow for users. Additionally, integration tests have been added to validate the execution of the flow, ensuring robust functionality.

* refactor: Update message extraction to use json.dumps for improved serialization

Modified the extract_message_from_result function to utilize json.dumps with ensure_ascii=False for better JSON serialization of message content. This change enhances the output formatting and maintains consistency in handling message data.

* feat: Add initial graph module with core components

Introduced a new graph module in Langflow, including essential classes such as Edge, Graph, Vertex, and specific vertex types (CustomComponentVertex, InterfaceVertex, StateVertex). This addition enhances the modularity and functionality of the codebase, laying the groundwork for future graph-related features.

* feat: Add pytest collection modification for automatic test markers

Implemented a new function to automatically add markers to test items based on their file location. This enhancement categorizes tests into unit, integration, and slow tests, improving test organization and clarity in both the backend and lfx test suites.

* chore: Update test configuration for improved organization and clarity

Modified the test paths and markers in both the main and lfx pyproject.toml files. Added new markers for unit, integration, and slow tests, enhancing test categorization. Removed the redundant pytest.ini file to streamline configuration management.

* chore: Update project description in pyproject.toml

Revised the project description to provide a clearer overview of LFX (Langflow Executor) as a lightweight CLI tool for executing and serving Langflow AI flows. This change enhances the documentation and helps users better understand the project's purpose.

* [autofix.ci] apply automated fixes

* chore: Remove redundant per-file ignores from pyproject.toml

Eliminated unnecessary linting ignores for scripts and backend tests in the pyproject.toml file. This streamlines the configuration and improves clarity in the project's linting setup.

* chore: Update Dockerfile project description for clarity

Revised the project description in the Dockerfile to reflect the correct name of the CLI tool as "LFX - Langflow Executor CLI Tool." This change improves clarity and aligns with the project's branding.

* feat: Introduce 'run' command for executing Langflow workflows

Renamed the 'execute' command to 'run' in the lfx CLI for consistency and clarity. Updated the README documentation to reflect this change, including command usage examples. Added a new run.py module that implements the run command functionality, allowing users to execute Langflow workflows from Python scripts or JSON files. Comprehensive unit and integration tests have been added to ensure robust functionality and error handling for the new command.

* fix: Update test command in Makefile to include all tests

Modified the test command in the Makefile to run all tests located in the 'tests' directory instead of just the 'unit' tests. This change ensures comprehensive test coverage during the testing process.

* chore: Clean up pyproject.toml formatting and linting ignores

Adjusted the formatting of the members list in the [tool.uv.workspace] section for improved readability. Removed a redundant linting ignore from the ignore list, streamlining the configuration and enhancing clarity in the project's linting setup.

* docs: Update README.md with environment variable requirement and command examples

Added a note about the necessity of setting the `LANGFLOW_API_KEY` environment variable before running the server. Updated command examples to reflect the correct flow ID display and included additional options for the `uv run lfx` commands, enhancing clarity and usability for users.

* feat: Add LFX release workflow and release script

Introduced a comprehensive GitHub Actions workflow for managing LFX releases, including version validation, testing across multiple Python versions, building and publishing to PyPI, and creating Docker images. Additionally, added a Bash script for local release preparation, which updates versioning in relevant files, runs tests, and facilitates the release process with dry-run capabilities. This enhancement streamlines the release workflow and ensures robust version management.

* feat: Add hypothesis to development dependencies

Included the 'hypothesis' library in both the uv.lock and pyproject.toml files to enhance testing capabilities with property-based testing. This addition supports more robust test coverage and improves the overall quality of the codebase.

* feat: Enhance Makefile with release operations and version bumping

Added new targets to the Makefile for checking the current version, preparing for releases, and bumping the version. The `prepare_release` target outlines next steps for the release process, while `bump_version` allows for version updates directly from the Makefile, improving the release workflow and version management.

* Temporarily modify nightly build to publish release lfx

* fix version

* fix versions

* skip tests

* Revert changes to run release lfx

* refactor: Change logger warning to trace for environment variable loading

Updated the logging level from warning to trace in the `update_params_with_load_from_db_fields` function to provide more granular logging when loading variables from environment variables due to the unavailability of the database. This change enhances the debugging capabilities without altering the functionality.

* chore: Update project description in pyproject.toml

Modified the project description in the pyproject.toml file for clarity, removing the acronym "LFX" to enhance understanding of the Langflow Executor's purpose as a CLI tool for executing and serving Langflow AI flows.

* docs: Update README for inline JSON format clarification

Revised the README to reflect changes in the inline JSON format for commands, ensuring consistency in the structure by including "data" as a key for nodes and edges. This update enhances clarity for users on how to properly format their JSON input when using the CLI.

* fix: Update message extraction logic in script_loader.py

Refactored the `extract_message_from_result` and `extract_text_from_result` functions to improve message handling. The changes include parsing JSON directly from the message's model dump and adding type checks to handle both dictionary and Message object types. This enhances robustness and ensures proper extraction of text content.

* feat: Add complex chat flow example and enhance test coverage

Introduced a new script `complex_chat_flow.py` demonstrating a multi-component chat flow, showcasing the integration of `ChatInput`, `TextInput`, `TextOutput`, and `ChatOutput`. Enhanced unit tests in `test_script_loader.py` to validate loading and execution of real scripts, ensuring proper graph structure and result extraction. This improves the robustness of the testing framework and provides a practical example for users.

* refactor: Enhance unit tests for FastAPI serve app with real graph data

Updated unit tests in `test_serve_app.py` to utilize real graph data from JSON files, improving test accuracy and coverage. Replaced mock graph instances with real graphs created from payloads, ensuring better alignment with actual application behavior. This change enhances the robustness of the testing framework and prepares for future feature expansions.

* refactor: Update unit tests to utilize real graph data and improve structure

Refactored unit tests in `test_serve_components.py` to replace mock graph instances with real graphs created from JSON data. This change enhances the accuracy and robustness of the tests, ensuring better alignment with actual application behavior. Additionally, removed the `create_mock_graph` function in favor of a new `create_real_graph` function, streamlining the test setup process.

* test: Increase timeout for selector in Prompt Chaining tests

Updated the timeout for the selector waiting for "built successfully" in the Prompt Chaining integration tests from 30 seconds to 60 seconds. This change aims to enhance test reliability by allowing more time for the expected output to appear, particularly in environments with variable performance.

* feat: Add nightly build and publish workflow for LFX

Implemented a new GitHub Actions workflow for building and publishing the LFX package nightly. This includes steps for checking out the code, setting up the environment, installing dependencies, verifying the package name and version, building the distribution, testing the CLI, and publishing to PyPI. The workflow is designed to run conditionally based on input parameters, enhancing the CI/CD process for LFX.

* refactor: Remove redundant re-export comments across multiple modules

* fix: Update __all__ to include Component in custom_component module

* Move all of message_original to lfx

* refactor: Update component module to improve imports and maintain backward compatibility

* refactor: Clean up imports and remove unnecessary TYPE_CHECKING block

* refactor: Remove enhanced Data class and update imports for backward compatibility

* refactor: Enhance pytest configuration to check for langflow installation and update error handling

* Refactor import statements in component modules to use new import structure

- Updated import paths in various component  files to reflect the new structure under .
- Ensured all components are correctly importing their respective modules.
- Added unit tests for dynamic imports and import utilities to validate the new import system.

* [autofix.ci] apply automated fixes

* fix: update import paths to use the new lfx structure across multiple components

* style: run pre-commit on all files

* fix: move dotdict import inside TYPE_CHECKING block for better performance

* feat: add MCP session management settings and update knowledge bases directory

* fix: update module paths and code hashes in Knowledge Ingestion and Retrieval JSON files

* fix: reorder imports for better organization and readability

* fix: update KBRetrievalComponent module path and code hash

- Changed module path from `langflow.components.data.kb_retrieval.KBRetrievalComponent` to `lfx.components.data.kb_retrieval.KBRetrievalComponent`.
- Updated code hash to reflect recent changes in the KBRetrievalComponent implementation.
- Refactored import statements and adjusted the logic for handling knowledge bases and embeddings.

* fix: move parse_api_endpoint import inside try block for better error handling

* refactor: clean up base.py by removing unused imports and code

* fix: update version and revision in pyproject.toml and uv.lock files

* refactor: remove unused validation functions and imports from validate.py

* fix: handle langflow import conditionally and adjust code references

* fix: update version to 0.1.3 in pyproject.toml and uv.lock files

* refactor: update code handling in utils.py for custom components

- Refactored the _generate_code_hash function to remove the class_name parameter, simplifying its signature and improving clarity.
- Introduced a new function, get_module_name_from_display_name, to convert display names into valid module names.
- Updated references to custom_component.code to custom_component._code for consistency across the codebase.
- Enhanced error handling during code hash generation to log exceptions, improving debugging capabilities.
- Adjusted metadata handling in build_custom_component_template functions to derive module names when not provided, ensuring accurate metadata generation.

* [autofix.ci] apply automated fixes

* refactor: update type hinting for Graph in load.py

* refactor: implement lazy initialization for storage service in ParameterHandler

* feat: add timing option to run function for performance measurement

* refactor: implement lazy initialization for tracing service in Graph class

* feat: add lazy initialization for tracing service in CustomComponent

* refactor: implement lazy initialization for storage service in Vertex and loading functions

* bump: update version to 0.1.4 in pyproject.toml and uv.lock

* feat: add UUID generation for session_id in LCAgentComponent

* fix: import sqlmodel conditionally in get_flow_snake_case to avoid ImportError

* feat: conditionally import model components to enhance modularity and avoid ImportError

* feat: implement lazy loading for agent and data components to enhance modularity

* fix: conditionally filter OpenAI inputs and handle empty case in AgentComponent

* refactor: enhance verbose logging and error handling in run function

* fix: update USER_AGENT assignment to use importlib for better compatibility

* fix: change async methods to synchronous in Component class for toolkit conversion

* feat: add complete agent example with setup instructions and dependencies in README

* [autofix.ci] apply automated fixes

* fix: update import paths from langflow to lfx for consistency across test files

* fix: bump version to 0.1.5 in pyproject.toml and uv.lock

* fix: enhance _get_tools method to handle both sync and async calls

* fix: bump version to 0.1.6 in pyproject.toml and uv.lock

* fix: streamline _get_tools method to handle sync and async calls more efficiently

* feat: implement lazy loading for searchapi components

* feat: add dynamic imports and lazy loading for component modules

* feat: implement lazy loading for NotDiamondComponent

* fix: add type check for source_code in _generate_code_hash function

* test: add error handling for missing langchain-openai dependency in class import

* fix: update error handling for None source in _generate_code_hash function and correct import paths

* fix: improve error handling for dynamic imports and update import paths in tests

* fix: enhance error handling for dynamic imports and ensure proper caching behavior

* fix: improve error handling for missing modules in import_mod function

* fix: enhance dynamic imports with on-demand discovery and improved error handling

* fix: update error handling in tests to raise ModuleNotFoundError for missing dependencies

* fix: update version to 0.1.7 in pyproject.toml and uv.lock

* fix: update version to 0.1.8 in pyproject.toml and uv.lock; enhance README with flattened component access examples

* [autofix.ci] apply automated fixes

* fix: update import path for Graph in composio_base.py

* merge the createl-lfx changes into the Component

* update code in templates

* feat: Add simple agent flow example in test data

* feat: Add LFX commands as a sub-application in the main app

* feat: Add tests for simple agent workflow execution via lfx run

* fix: update import for KeyedMemoryLockManager to maintain consistency

* refactor: remove unused imports from various modules for cleaner code

* refactor: remove unused import of aget_messages for cleaner code

* update manager in lfx

* update logger to use lfx

* rename lfx_logging to logs

* refactor: remove loguru dependency and add structlog

* chore: update starter project files for consistency

* refactor: update logger calls to use exc_info for better error reporting

* refactor: update import paths to use lfx module instead of langflow

* move vector store components for various databases

- Implement PGVector store component for PostgreSQL with search capabilities.
- Implement Pinecone store component with support for various distance strategies.
- Implement Qdrant store component with customizable server settings.
- Implement Supabase store component for vector storage and retrieval.
- Implement Upstash store component with metadata filtering options.
- Implement Vectara store component with RAG capabilities and document management.
- Implement Weaviate store component with support for API key authentication and capitalized index names.
- Add dynamic imports for all new components to facilitate lazy loading.

* refactor: reorder import statements for better organization

* refactor: improve dynamic import handling for Chroma components

* refactor: update test for ChromaVectorStoreComponent to check for import errors

* refactor: update __init__.py to import all components from lfx and improve attribute forwarding

* refactor: add forwarding for langflow components to lfx counterparts

* refactor: simplify mock setup in component_setup method

* refactor: update module references from langflow.logging to lfx.logs in test_logger.py

* refactor: enhance test structure for simple agent workflow in lfx run

* Refactor logging imports and update code snippets in JSON configuration files

- Changed logger import from `lfx.lfx_logging.logger` to `lfx.logs.logger` in multiple components.
- Updated code snippets in Travel Planning Agents, ChatInputTest, LoopTest, and TwoOutputsTest JSON files to reflect the new logger import.
- Ensured consistency in code formatting and structure across the affected files.

* docs: update README to clarify installation and usage instructions

* refactor: update import paths from langflow to lfx in multiple component __init__.py files

* refactor: improve test structure and organization in test_run_command.py

* refactor: clean up unused imports and improve code organization in kb_ingest.py

* refactor: update test data structure in ChatInputTest.json, LoopTest.json, and TwoOutputsTest.json

* refactor: update dynamic imports and __all__ exports in vectorstores __init__.py

* refactor: clean up and organize test files for MCP and KB components

* refactor: update import paths in test_kb_ingest.py and test_kb_retrieval.py to use lfx namespace

* refactor: update structure and organization of Knowledge Ingestion JSON file

* [autofix.ci] apply automated fixes

* rename lfx.logs to lfx.log to avoid gitignore

* refactor: alias run command in LFX app to lfx_run for clarity

* refactor: update import path for validate_code to improve clarity

* [autofix.ci] apply automated fixes

* revert docs changes for now

* [autofix.ci] apply automated fixes

* fix: mark DataFrame as unhashable due to mutability

* refactor: update function signatures to use keyword-only arguments for clarity

* fix: update import paths from langflow to lfx for consistency

* refactor: reorganize imports and ensure create_input_schema_from_json_schema is consistently defined

* fix: update import statement for Action to use the correct path

* refactor: remove TYPE_CHECKING import for DataFrame to streamline code

* refactor: clean up import statements for improved readability

* refactor: remove unused imports and enhance code clarity

* refactor: improve test structure and organization in test_import_utils.py

* fix: update logger configuration to use environment variable for log level

* fix: remove default log level configuration and set logger initialization

* fix: enhance logger configuration to prevent redundant setup and improve cache handling

* fix: improve cache handling in logger configuration to prevent unintended defaults

* fix: enhance logger configuration to prevent redundant setup and improve early-exit logic

* fix: remove defensive comment in logger configuration for clarity

* fix: update project templates for consistency and clarity

* fix: refactor field handling in set_multiple_field_advanced and set_current_fields for improved clarity and consistency

* fix: update error message in import_mod test for clarity and specificity

* fix: change _get_tools method from async to synchronous for consistency

* fix: update error handling in test_module_not_found_error_handling for clarity

* fix: update import statements in test_custom_component for consistency

* fix: update import statements in test_custom_component_endpoint for consistency

* fix: remove SupabaseComposioComponent from dynamic imports and __all__ for consistency

* fix: mock log method in component_setup to avoid tracing service context issues

* fix: adjust uniqueness threshold for code hashes to account for legitimate sharing

* fix: update test for structured output to support NVIDIA models and handle errors appropriately

* fix: update logger patches and modify pandas inclusion test in validate.py

* fix: update import path for langflow module in get_default_imports function

* fix: replace hard assertions with informative prints in performance tests to avoid CI failures

* fix: ensure all component modules are importable after dynamic import refactor

* fix: enhance composio compatibility checks and improve import handling for Action enum

* fix: remove compatibility check for composio components and always expose all components

* fix: update Slack component documentation link to ensure accuracy

* fix: remove 'Agent' from skipped components list in constants

* fix: remove await from CurrentDateComponent instantiation in AgentComponent

* fix: Filter out None values from headers in URLComponent

* update starter projects hat use url compoennt

* feat: add processing components and converter utilities

* fix: add OpenAI constants forward import

* chore: update Knowledge Ingestion starter project structure

* fix: correct parameter usage in set_multiple_field_display function

* fix: update set_field_display function signature to remove unnecessary keyword argument

* feat: implement backwards compatibility layer and add OpenAI response schemas

* fix: update version to 0.1.9 in pyproject.toml and uv.lock

* feat: add compatibility for langflow.components and related helper modules

* fix: update version to 0.1.10 in pyproject.toml and uv.lock

* fix: remove unnecessary import and update message type check in convert_message_to_data method

* fix: enhance attribute access in LangflowCompatibilityModule with caching

* fix: update import paths in Data class to use lfx module

* fix: add comment to clarify import and re-export purpose in message.py

* fix: remove unused code and improve flow data checks in openai_responses.py

* fix: update LoopTest.json structure for improved data representation

* fix: update test_api_schemas.py for improved hypothesis testing configurations

* fix: update hypothesis strategies for improved test coverage in test_api_schemas.py

* fix: remove unused code and improve structure in __init__.py

* refactor: add knowledge base components for ingestion and retrieval in lfx

- Implemented KnowledgeIngestionComponent for creating and updating knowledge bases from DataFrames.
- Added KnowledgeRetrievalComponent for searching and retrieving data from knowledge bases.
- Introduced dynamic imports for knowledge base components in the main module.
- Created utility functions for managing knowledge base metadata and embeddings.
- Enhanced error handling and logging for better debugging and user feedback.

* fix: enhance convert_to_dataframe function to handle pandas DataFrame and improve type conversion

* refactor: remove knowledge base components and related imports for cleanup

* fix: update TypeConverterComponent to include pandas as a dependency and enhance convert_to_dataframe function for better DataFrame handling

* fix: update imports for knowledge_bases module and enhance compatibility in langflow.base

* refactor: remove unused imports and simplify backwards compatibility module in langflow.base.data

* refactor: streamline inputs module by removing unused code and maintaining compatibility layer

* refactor: remove unused classes and streamline input handling in inputs.py

* Update language model components across multiple starter projects to include new dependencies and model options

- Standardized description format for language model components.
- Added metadata for dependencies including langchain packages and lfx.
- Updated model options to include new versions such as gpt-5 and its variants.
- Ensured consistency in the structure of JSON files for various starter projects including Market Research, Meeting Summary, Memory Chatbot, Portfolio Website Code Generator, Research Agent, and others.

* fix: update import path for custom component

- Changed the import path for the `Component` class from `lfx.custom.custom_component.component` to `langflow.custom.custom_component.component` in the `Youtube Analysis.json` file.

* refactor: update component IDs and streamline connections in Custom Component Generator

* refactor: standardize formatting of source and target handles in Custom Component Generator

* refactor: update component IDs and streamline connections in Custom Component Generator

* [autofix.ci] apply automated fixes

* fix: revert name change in Custom Component Generator

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Jordan Frazier <jordan.frazier@datastax.com>
2025-09-02 17:45:53 +00:00
Cristhian Zanforlin Lousa
ab017bafcd feat: Add not contains filter operator in DataFrame Operations Component (#9415)
* 🐛 (dataframe_operations.py): Fix bug in DataFrameOperationsComponent where "not contains" filter option was missing, causing incorrect filtering behavior.

* [autofix.ci] apply automated fixes

* Update pyproject versions

* fix: Avoid namespace collision for Astra (#9544)

* fix: Avoid namespace collision for Astra

* [autofix.ci] apply automated fixes

* Update Vector Store RAG.json

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* fix: Revert to a working composio release for module import (#9569)

fix: revert to stable composio version

* fix: Knowledge base component refactor (#9543)

* fix: Knowledge base component refactor

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* Update styleUtils.ts

* Update ingestion.py

* [autofix.ci] apply automated fixes

* Fix ingestion of df

* [autofix.ci] apply automated fixes

* Update Knowledge Ingestion.json

* Fix one failing test

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes

* Revert composio versions for CI

* Revert "Revert composio versions for CI"

This reverts commit 9bcb694ea1e20d544cf5e17fed2f9f4c0a3c192b.

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Edwin Jose <edwin.jose@datastax.com>
Co-authored-by: Carlos Coelho <80289056+carlosrcoelho@users.noreply.github.com>

* fix: Fix env file handling in Windows build scripts (#9414)

fix .env load on windows script

Co-authored-by: Ítalo Johnny <italojohnnydosanjos@gmail.com>

* fix: update agent_llm display name to "Model Provider" in AgentComponent (#9564)

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* 📝 (test_mcp_util.py): add a check to skip test if DeepWiki server is rate limiting requests to avoid false test failures

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Jordan Frazier <jordan.frazier@datastax.com>
Co-authored-by: Eric Hare <ericrhare@gmail.com>
Co-authored-by: Edwin Jose <edwin.jose@datastax.com>
Co-authored-by: Carlos Coelho <80289056+carlosrcoelho@users.noreply.github.com>
Co-authored-by: Ítalo Johnny <italojohnnydosanjos@gmail.com>
2025-08-29 17:09:30 +00:00
Eric Pinzur
da4208dcc9 feat: generate custom coverage config to omit legacy and external compoents (#9221)
* feat: generate custom coverage config to omit legacy and external components

* lint

* fix components config

* also remove deactivated componenets

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2025-07-30 04:46:19 +00:00
Cristhian Zanforlin Lousa
86c54de508 feat: Add .env file support to Windows build scripts (#9214)
* 🔧 (build_and_run.bat): add support for loading environment variables from .env file
🔧 (build_and_run.ps1): add support for loading environment variables from .env file

* 🐛 (build_and_run.bat): fix path to .env file to correctly load environment variables
🐛 (build_and_run.ps1): fix path to .env file to correctly load environment variables

* 🔧 (build_and_run.bat): set env file parameter if .env file exists to pass to langflow run
🔧 (build_and_run.ps1): set env file parameter if .env file exists to pass to langflow run

* 📝 (build_and_run.bat): improve script to dynamically find and set .env file path for Langflow run
📝 (build_and_run.ps1): enhance script to dynamically locate and set .env file path for Langflow run

* Update scripts/windows/build_and_run.bat

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

* 🔧 (build_and_run.ps1): refactor script to use a boolean flag 'useEnvFile' instead of a string variable 'envFileParam' to improve readability and maintainability
🔧 (build_and_run.ps1): update uvicorn command to use '--env-file' flag directly instead of building the command with a string variable

---------

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
2025-07-28 21:11:49 +00:00
Gabriel Luiz Freitas Almeida
75e930d847 ci: update nightly script to support other version operators (#8980) 2025-07-10 10:02:04 -03:00
Gabriel Luiz Freitas Almeida
c5083a54ae ci: update regex pattern for langflow-base dependency to support PEP 440 version suffixes (#8979) 2025-07-10 09:49:23 -03:00
Cristhian Zanforlin Lousa
78d64eb7af feat: Add Windows build and run automation scripts (#8861)
* 🔧 (build_and_run.bat): Add a Windows batch script to build frontend, copy build files to backend, and run Langflow
🔧 (build_and_run.ps1): Add a Windows PowerShell script to build frontend, copy build files to backend, and run Langflow

* 📝 scripts/windows/build_and_run.bat: improve script messages for better clarity and consistency
📝 scripts/windows/build_and_run.ps1: update script steps numbering and messages for consistency and clarity

* 📝 (build_and_run.bat): Add attention message to wait for uvicorn to run before opening the browser
📝 (build_and_run.ps1): Add attention message to wait for uvicorn to run before opening the browser
2025-07-03 19:42:17 +00:00
yihong
3b38c2efb7 fix: aws docker file is now in different place (#6706)
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
2025-02-19 14:22:58 +00:00
Eric Hare
28e07be870 feat: Unified File Management API (#6100)
* feat: FIrst pass at file management API

* [autofix.ci] apply automated fixes

* Add delete and edit endpoints

* [autofix.ci] apply automated fixes

* Add file size and duplicate name handling

* Ensure the File model has a unique name

* Ensure count is before extension

* [autofix.ci] apply automated fixes

* Add the correct path to the return

* Added function to handle list of paths in File component

* [autofix.ci] apply automated fixes

* Update input_mixin.py

* Refactor to a v2 endpoint

* Add unit tests

* Update test_files.py

* Update frontend.ts

* [autofix.ci] apply automated fixes

* Remove extension from name

* Cast the string type for like

* Update files.py

* Update base.py

* Update base.py

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Lucas Oliveira <lucas.edu.oli@hotmail.com>
2025-02-06 18:35:24 +00:00
Christophe Bornet
da83dbbcb5 feat: Bump ruff version to 0.9 (#5666)
* Bump ruff version to 0.9

* Rename some modules for A005 ruff rule
2025-01-15 15:14:43 +00:00
Ayush
3de5572c45 docs: add docs to huggingface space restart script (#5051)
* Update factory_restart_space.py

just added more readability by adding more comments

* [autofix.ci] apply automated fixes

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Gabriel Luiz Freitas Almeida <gabriel@langflow.org>
2024-12-19 18:42:27 +00:00
Jordan Frazier
ba31d436c4 ci: script and workflow to update starter projects (#5195) 2024-12-12 02:48:55 +00:00
Christophe Bornet
2f0c67e851 ref: Bump ruff version to 0.8 (#5087) 2024-12-08 11:16:06 +00:00
Sebastián Estévez
c1097d2dde chore: update dockerfiles and docker-build workflows to fix releases (#4317)
* bash -x

* bash verbose

* combine bash calls in uv run

* combined python script

* relative dir

* pass args correctly

* pass args correctly

* function name

* fix arg order

* merge base and main

* remove nightly -ep docker image for now

* set up uv in the get-version job in docker-build.yml

* v prefix for version in build job

* use inputs.nightly_tag_main for checkout actions

* mount root project metadata for base build

* fix comment

* continued dockerfile fixes for workspaces setup

* fix path

* ruff check fix
2024-10-31 11:16:26 +00:00
Christophe Bornet
f96f2eaf8a ref: Add ALL ruff rules for tests (#4183)
Add ALL ruff rules for tests
2024-10-19 20:41:37 +00:00
Ítalo Johnny
7dd85ac0fe fix: update regex to get supported python versions (#4175)
* fix: update regex to get supported python versions

* chore: move version check to bash script
2024-10-19 13:08:50 +00:00
Christophe Bornet
e4e1e1bd86 ref: Add missing __init__.py files in tests (#4180)
Add missing __init__.py files in tests
2024-10-17 18:21:56 +00:00
Christophe Bornet
45c8f98692 ref: Auto-fix ruff rules in tests (#4154) 2024-10-16 15:42:36 +00:00
Samuel Matioli
e04d6b9d2f feat: Add Astra DB Tool components for use with Tool Agents (#3911)
* Adding Astra Tools

* Format

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes

* Lint and Renaming to AstraDB

* Adding Astra Tools

* Format

* [autofix.ci] apply automated fixes

* ignoring .dspy cache

* [autofix.ci] apply automated fixes

* docs: Improve the search UX in Langflow docs (#4089)

* Add Mendable search bar component

* Align Mendable anon_key retrieval

* Update url and tagline in docusaurus config

* Move sitemap config to preset options

* Add Mendable anon key to docusaurus config

* docs: remove old examples (#4102)

Removed old examples

* fix: network error handling and build errors (#4088)

* Fixed API not throwing network errors

* Fix onBuildError assigning wrong status for the components

* Fix Network Error handling, making it call onBuildError

* Fixed build stop not triggering the alert

---------

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Jordan Frazier <122494242+jordanrfrazier@users.noreply.github.com>

* fix: store api key pydantic error (#4103)

Fixed User pydantic error

Co-authored-by: Jordan Frazier <122494242+jordanrfrazier@users.noreply.github.com>

* version: upgrade to 1.0.19 and 0.0.97 (#4104)

* upgrade to 1.0.19 and 0.0.97

* build: add readme to dockerfile (#4105)

Add readme to dockerfile

* feat: Add traceback to fastapi exception handler logs (#4099)

Add traceback to fastapi exception handler logs

* fix: prevent possible race condition on upload flows/folders (#4114)

*  (create-file-upload.ts): improve file upload functionality by adding cleanup logic and handling edge cases for resolving file selection

* 🐛 (create-file-upload.ts): fix removing input element from the DOM by checking if it is contained in the document body before removal
💡 (create-file-upload.ts): add a comment to clarify the purpose of the setTimeout function for a fallback timeout of 1 minute

*  (create-file-upload.ts): change createFileUpload function to be asynchronous to support Promise return type for better handling of file upload operations

* 📝 (create-file-upload.ts): improve error handling when removing input element from the DOM
📝 (create-file-upload.ts): remove unnecessary comment about timeout value in the code

* fix: truncate "params" column on vertex_build table to prevent memory heap on database (#4118)

*  (model.py): add new method `serialize_params` to serialize parameters data in VertexBuildBase class

* 🐛 (util_strings.py): fix truncation logic to correctly handle long strings by truncating them with ellipsis if they exceed the maximum length

*  (test_truncate_long_strings.py): add unit tests for the truncate_long_strings function to ensure it works correctly with various input scenarios

*  (test_truncate_long_strings_on_objects.py): update test assertion message to reflect the expected behavior of the function

* refactor: add pagination on folders (#4020)

* ⬆️ (uv.lock): Update authlib version from 1.3.2 to 1.3.1
⬆️ (uv.lock): Update httpx version from 0.27.2 to 0.27.0
⬆️ (uv.lock): Add new package grpcio-health-checking version 1.62.3

⬆️ (uv.lock): upgrade weaviate-client package from version 3.26.7 to 4.8.1 and add new dependencies grpcio, grpcio-health-checking, grpcio-tools, httpx, and pydantic. Update package source and distribution URLs accordingly.

*  (flows.py): Add pagination support for retrieving a list of flows to improve performance and user experience
📝 (flows.py): Update documentation to reflect changes made for pagination and additional query parameters
📝 (folders.py): Add a new endpoint to retrieve a folder with paginated flows for better organization and readability

*  (model.py): add PaginatedFlowResponse class to handle paginated flow responses in API calls

*  (test_database.py): add support for fetching all flows by adding "get_all" parameter to the request
🐛 (test_database.py): fix endpoint for fetching read-only starter projects to use correct URL path

* packages changes

* packages changes

* 📝 (paginatorComponent/index.tsx): refactor PaginatorComponent to use constants for default values and improve code readability
🐛 (paginatorComponent/index.tsx): fix issue with setting maxPageIndex when pages prop is provided to PaginatorComponent

* 🐛 (storeCardComponent): fix height of store card component to prevent overflow and improve layout aesthetics

*  (constants.ts): introduce new constants for search tabs, pagination settings, and store pagination settings to enhance user experience and improve functionality

*  (use-post-login-user.ts): add queryClient to UseRequestProcessor to enable refetching queries on mutation settled state
📝 (use-post-login-user.ts): update useLoginUser function to include onSettled callback in options to refetch queries after mutation settles

*  (use-get-basic-examples.ts): introduce a new query function to fetch basic examples of flows from the API and update the state with the fetched data.

*  (use-get-refresh-flows.ts): introduce new functionality to fetch and process flows with query parameters for components_only, get_all, folder_id, remove_example_flows, page, and size. This allows for more flexible and specific retrieval of flow data.

*  (use-get-folder.ts): Add support for pagination and filtering options in the useGetFolderQuery function to enhance flexibility and customization for fetching folder data.

* 🔧 (use-get-folders.ts): Remove unused code related to refreshFlows and setStarterProjectId to improve code readability and maintainability
 (use-get-folders.ts): Update useGetFoldersQuery to setFolders with the fetched data instead of filtering out starter projects to simplify the logic and improve performance

*  (use-upload-flow.ts): update refreshFlows function call to include an object with get_all property set to true to fetch all flows when refreshing

* 🔧 (codeAreaModal/index.tsx): remove unused import postCustomComponent to clean up code and improve readability

* 📝 (AdminPage/index.tsx): Update initial page size and index values to use constants for better maintainability
📝 (AdminPage/index.tsx): Update resetFilter function to set page size and index using constants for consistency
📝 (AdminPage/index.tsx): Update logic to handle loading state and empty user list based on isIdle state for better user experience
📝 (AdminPage/index.tsx): Update PaginatorComponent props to use constant for rows count and simplify paginate function assignment

*  (AppInitPage/index.tsx): introduce new queries to fetch basic examples and folders data for improved functionality and user experience

*  (FlowPage/index.tsx): update refreshFlows function call to include a parameter to get all flows at once for better performance.

*  (frontend): introduce flowsPagination and setFlowsPagination functions to manage pagination for flows in the UtilityStoreType

*  (frontend): introduce new 'folders' and 'setFolders' properties to FoldersStoreType to manage folder data efficiently

*  (types.ts): introduce Pagination type to define structure for pagination data in frontend application

*  (frontend): introduce PaginatedFlowsType to represent paginated flow data structure in the application.

*  (frontend): add optional 'pages' property to PaginatorComponentType to allow customization of the number of pages displayed in the paginator

*  (utilityStore.ts): introduce flowsPagination object with default values for page and size to manage pagination in the utility store

*  (foldersStore.tsx): introduce new state 'folders' and setter function 'setFolders' to manage folder data in the store

*  (ViewPage/index.tsx): update refreshFlows function call to include a parameter to get all flows at once, improving efficiency and reducing unnecessary calls to the backend.

* 📝 (StorePage/index.tsx): update constants import to include new pagination constants for better organization
♻️ (StorePage/index.tsx): refactor pagination logic to use new pagination constants for clarity and consistency throughout the file

*  (componentsComponent/index.tsx): Add support for pagination feature in ComponentsComponent to improve user experience and performance.

*  (myCollectionComponent/index.tsx): introduce pagination and search functionality to improve user experience and data handling in the MyCollectionComponent component

*  (Playground/index.tsx): Update refreshFlows function call to include a parameter to get all flows at once for better performance.

*  (entities/index.tsx): introduce PaginatedFolderType to represent a folder with pagination information for better organization and handling of paginated data.

*  (headerTabsSearchComponent/index.tsx): add support for changing tabs and searching functionality in headerTabsSearchComponent
📝 (headerTabsSearchComponent/index.tsx): update tabsOptions to use constant SEARCH_TABS for consistency and reusability

* 📝 (folders.py): Remove redundant import and unused code related to FolderWithPaginatedFlows class
🔧 (folders.py): Update query conditions to use explicit boolean values instead of implicit truthiness for better clarity and readability

* 📝 (folders.py): reorganize imports to improve readability and maintain consistency

* 📝 (flows.py): import FlowSummary model to support new functionality in the API
📝 (flows.py): add header_flows parameter to read_flows function to return a simplified list of flows if set to true

* 📝 (folders.py): remove unnecessary empty line to improve code readability

*  (model.py): introduce new FlowSummary class to represent a summary of flow data for better organization and readability

*  (pagination_model.py): introduce a new model 'FolderWithPaginatedFlows' to represent a folder with paginated flows for better organization and readability.

* 📝 (cardComponent/index.tsx): add missing semicolon to improve code consistency
♻️ (cardComponent/index.tsx): refactor logic to use data parameter directly instead of fetching flow by id to simplify code and improve readability

*  (use-get-refresh-flows.ts): introduce new query parameter 'header_flows' to support fetching header flows in API requests.

*  (use-get-folders.ts): add functionality to refresh flows when fetching folders to ensure data consistency and up-to-date information.

*  (use-upload-flow.ts): add support for fetching header flows along with all flows when refreshing flows in useUploadFlow hook

*  (use-redirect-flow-card-click.tsx): introduce a new custom hook 'useFlowCardClick' to handle flow card click events in the newFlowModal component. This hook utilizes react-router-dom for navigation, custom analytics tracking, and various utility functions to manage flow data and update the UI.

*  (NewFlowCardComponent/index.tsx): refactor onClick event handler into a separate function handleClick for better readability and maintainability

* 📝 (undrawCards/index.tsx): Remove unused imports and variables to clean up the code
♻️ (undrawCards/index.tsx): Refactor onClick event handler to use a separate function for handling flow card click events

*  (flowsManager/index.ts): introduce new state and setter for flowToCanvas to manage the flow displayed on canvas

*  (flowsManagerStore.ts): introduce new feature to set and update the flow to be displayed on the canvas asynchronously

*  (ViewPage/index.tsx): add support for fetching header flows along with all flows when refreshing data to improve data retrieval efficiency

*  (collectionCard/index.tsx): introduce useFlowsManagerStore to manage flows in the application
📝 (collectionCard/index.tsx): update handleClick function to set flow to canvas before navigating to editFlowLink

*  (Playground/index.tsx): add support for fetching header flows along with all flows when refreshing data in the Playground page.

* 🐛 (FlowPage/index.tsx): Fix setCurrentFlow logic to correctly set the current flow based on flowToCanvas value. Add flowToCanvas dependency to useEffect to ensure proper rendering.

*  (use-get-flow.ts): introduce a new file to handle API queries for fetching flow data in the frontend application. This file defines a custom hook 'useGetFlow' that makes a GET request to the API endpoint to retrieve flow data based on the provided flow ID.

* 📝 (flows.py): update import statement to use FlowHeader instead of FlowSummary for better clarity
📝 (flows.py): update response_model in read_flows endpoint to use FlowHeader for consistency and clarity

*  (model.py): rename FlowSummary class to FlowHeader for better clarity and consistency in naming conventions
📝 (model.py): add is_component field to FlowHeader class to indicate if the flow is a component or not

*  (use-get-folder.ts): introduce processFlows function to process flows data
📝 (use-get-folder.ts): add cloneDeep function to safely clone data before processing

* 🔧 (use-get-refresh-flows.ts): refactor useGetRefreshFlows function to simplify processing of dbDataFlows and update state accordingly

*  (FlowPage/index.tsx): Add useGetFlow hook to fetch flow data and update current flow on canvas. Add getFlowToAddToCanvas function to handle fetching and setting flow data on canvas.

*  (nodeToolbarComponent/index.tsx): improve user experience by automatically closing the override modal after successful flow override

*  (use-post-login-user.ts): add queryClient.refetchQueries for "useGetTags" after successful login to update tags data in the frontend.

*  (use-get-flow.ts): add processFlows function to process flow data before returning it to improve code readability and maintainability

* 🐛 (use-get-refresh-flows.ts): fix asynchronous flow to correctly handle data retrieval and processing before setting state and returning flows

*  (use-get-tags.ts): add functionality to set tags in utility store after fetching them from the API

* 📝 (shareModal/index.tsx): Update import statement for useUtilityStore to improve code organization and readability
🔧 (shareModal/index.tsx): Replace useGetTagsQuery with useUtilityStore to manage tags state and remove unnecessary API call for tags data
🔧 (shareModal/index.tsx): Replace references to data with tags variable to ensure consistency and avoid potential bugs
🔧 (shareModal/index.tsx): Update TagsSelector component to use tags variable instead of data for better data management

*  (AppInitPage/index.tsx): introduce useGetTagsQuery to fetch tags data from the store API for AppInitPage.

*  (StorePage/index.tsx): refactor to use useUtilityStore for tags state management instead of useGetTagsQuery for better separation of concerns and code organization. Update TagsSelector component to use tags from useUtilityStore hook.

*  (frontend): introduce Tag type to UtilityStoreType and add tags and setTags functions to manage tags in the store.

*  (types.ts): introduce new Tag type to represent a tag with id and name properties

*  (utilityStore.ts): introduce new 'tags' array and 'setTags' function to manage tags in the utility store

* 📝 (App.css): add a blank line for better readability and consistency in the CSS file

*  (test_database.py): add pagination support for reading flows and folders to improve data retrieval efficiency and user experience

*  (tabsComponent/index.tsx): refactor changeLocation function to use useCallback hook for better performance and stability
 (tabsComponent/index.tsx): update onClick event handler to directly call changeLocation function for cleaner code and improved readability

*  (headerTabsSearchComponent/index.tsx): refactor handleChangeTab, handleSearch, handleInputChange, and handleKeyDown functions to use useCallback for better performance and memoization
📝 (headerTabsSearchComponent/index.tsx): update tabActive prop to use the activeTab prop passed from parent component for consistency and clarity

*  (myCollectionComponent/index.tsx): refactor filter state initialization to dynamically set based on current location pathname
♻️ (myCollectionComponent/index.tsx): refactor onSearch and onChangeTab functions to use useCallback for better performance and memoization

*  (create-query-param-string.ts): introduce a new utility function to build query parameter strings for URLs in the frontend controllers.

*  (use-get-folder.ts): introduce buildQueryStringUrl function to create query parameter strings for API requests
📝 (use-get-folder.ts): add comments to explain the purpose of the code and improve code readability
🔧 (use-get-folder.ts): update useGetFolderQuery function to include additional configuration options for the query, such as refetchOnWindowFocus: false

*  (use-delete-folders.ts): add functionality to update local store after deleting a folder to keep it in sync with the server data

* 📝 (use-post-add-flow.ts): import useFolderStore to access myCollectionId state for refetching queries with the correct folder_id
🐛 (use-post-add-flow.ts): fix queryClient.refetchQueries to include the correct queryKey with folder_id or myCollectionId if response.folder_id is null

*  (use-get-refresh-flows.ts): refactor addQueryParams function to use buildQueryStringUrl utility function for better code readability and maintainability

* ♻️ (flows.py): remove unnecessary commented out code and add pagination functionality to the router for better code organization and readability

* 🔧 (NodeDescription/index.tsx): remove console.log statement for better code cleanliness and readability

*  (index.tsx): Add DialogClose component from @radix-ui/react-dialog to handle cancel action in ConfirmationModal. Refactor handleCancel function to improve code readability and maintainability.

* ♻️ (use-redirect-flow-card-click.tsx): remove unused setFlowToCanvas function to clean up code and improve maintainability

* 📝 (use-patch-update-flow.ts): update onSettled callback to refetch useGetFolders query with the updated folder_id after patching a flow

* 🔧 (use-delete-folders.ts): update onSettled function to correctly refetch queries with the specific folder id when deleting folders

*  (use-get-folder.ts): update useGetFolderQuery to include additional query parameters for pagination and filtering options

* 🔧 (use-post-upload-to-folder.ts): update onSettled callback to refetch useGetFolders query with the correct queryKey and folder_id parameter

*  (use-add-flow.ts): add functionality to refresh flows after adding a new flow to ensure the UI is up to date with the latest data.

*  (AppInitPage/index.tsx): enable fetching basic examples and tags only when isFetched is true to improve performance and reduce unnecessary API calls

*  (myCollectionComponent/index.tsx): refactor onPaginate function to handlePageChange callback for better code organization and readability. Update key prop in ComponentsComponent to include filter and search variables for proper re-rendering.

*  (use-get-folder.ts): add placeholderData option to useGetFolderQuery to provide initial data while fetching folder information

* [autofix.ci] apply automated fixes

* 🐛 (use-post-upload-to-folder.ts): fix queryKey values to correctly refetch queries after uploading a file to a folder

* ⬆️ (folders.spec.ts): increase timeout for waiting in test to improve reliability and prevent flakiness

*  (folders.spec.ts): update selectors to target specific elements by using the first() method to improve test reliability

*  (auto-save-off.spec.ts): update test to match changes in UI for auto-save feature and improve test coverage for hover functionality.

* 📝 (model.py): update model fields to set default values for folder_id, is_component, endpoint_name, and description to None for consistency and clarity

* ♻️ (index.tsx): refactor isUpdatingFolder logic to include isFetchingFolder variable for better accuracy and readability

* 🐛 (index.tsx): fix variable name typo in isLoadingFolder assignment to correctly reference isFetchingFolder

* 🐛 (use-patch-update-flow.ts): fix issue with missing closing parenthesis in queryClient.refetchQueries() method
📝 (use-patch-update-flow.ts): update queryKey in queryClient.refetchQueries() to ["useGetFolder"] to correctly refetch the folder data after updating a flow

*  (use-save-flow.ts): add support for fetching flow data before saving if not already present to ensure data consistency and accuracy

*  (folders.spec.ts): update selectors to target specific elements correctly for testing purposes

*  (use-on-file-drop.tsx): add support for checking flow names in a specific collection to prevent duplicates
♻️ (use-add-flow.ts): refactor to use the same logic for checking flow names in a specific collection to prevent duplicates

*  (index.tsx): Add useIsMutating hook to check if a folder is being deleted to update UI accordingly
♻️ (index.tsx): Refactor logic to determine if a folder is being updated to include check for folder deletion
🔧 (index.tsx): Refactor Select component to use a separate function for handling value change
🔧 (index.tsx): Refactor Button components to disable based on separate variables for first and last page
🔧 (index.ts): Remove unused import and refactor code to use useRef hook for storing the latest folder id in useGetFolderQuery

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>

* Fix: Add UTC timezone info to message.timestamp. (#4129)

* fix: enhance recursive_serialize_or_str to handle BaseModelV1 and improve exception logging (#4132)

Enhance `recursive_serialize_or_str` to handle `BaseModelV1` and improve exception logging

* fix: name/description bug in "Flow as Tool" (#4097)

Fix name/description bug in "Flow as Tool".

* chore: add opensearch-py dependency (#4134)

Add opensearch-py dependency to pyproject.toml

* refactor: starter projects templates and components (#4121)

* Update starter flows

* Update button with new menu variants

* Updated AstraDB icon

* Made header be optional on baseModal and added classname to content

* Removed old newFlowModal

* added a Nav component to show the sidebar categories

* Created new templates modal

* Updated components and modals to use new Templates modal

* Added used icons

* added template card

* changed templates modal to use modular components

* Add template content

* Add get started content

* added other size for templates

* Added size in base modal

* Changed menu ring-0 to be important

* Added all of the images of get started

* Fix hover effect on spirals

* Implement clicking get started templates

* Fix shiny design

* update package lock

* update examples

* updated card design

* Added grid of examples to templates

* Implemented card click

* Changed hover effect

* Added arrows

* delete unused

* implemented fuse search

* Added create blank project

* Made tags be read

* Added tags to basic prompting

* Added types

* Added tags to the tabs

* remove important from tailwind config

* updated setup and model to include icon

* added random-gradient npm package

* updated colors to remove white

* added icons

* inserted metadata of icons and etc into starter flows

* Removed integrations and added blank project creation

* Added gradient to cards

* Reset query when changing tab, reset scroll when typing

* added mix blend overlay to text

* Added id and gradient to templatecard type

* made icons for components still work

* added important on stroke

* formatting

* Fixed infinite render

* added test id to create blank project

* added data test id for templates title

*  (navComponent/index.tsx): add data-testid attribute with converted test name for side navigation options to improve testability and accessibility

*  (starter-projects.spec.ts): add test to ensure user can interact with starter projects in the frontend application

*  (TemplateCardComponent/index.tsx): add data-testid attribute with converted test name for better testability and accessibility

*  (TemplateCategoryComponent/index.tsx): import convertTestName function to convert test names for data-testid attributes in TemplateCategoryComponent

* fixed currentTab not changing results

* Fixed various tests

*  (similarity.spec.ts): improve user experience by adding functionality to fit view and scroll using mouse wheel in the test suite

* Fix other tests relying on multiple

* fix two edges test

* Fix hover on test 3 of generalBugs

---------

Co-authored-by: cristhianzl <cristhian.lousa@gmail.com>

* ref: Add ruff rules TRY3xx (#4098)

Add ruff rules TRY3xx

* ref: Some ruff rule fixes from preview mode (#4131)

Some ruff rule fixes from preview mode

* ref: Add ruff rules for pydocstyle (D) (#4120)

Add ruff rules for pydocstyle (D)

* ref: Add ruff rules for arguments (ARG) (#4123)

Add ruff rules for arguments (ARG)

* ref: Add ruff rules for boolean trap (FBT) (#4126)

Add ruff rules for boolean trap (FBT)

* fix: escape directory to prevent \n on Windows directory name to fail on Pathlib + Tests (#4101)

* 📝 (utils.py): add format_directory_path function to properly escape and format directory paths for consistency and validity

*  (test_format_directory_path.py): add unit tests for the format_directory_path function to ensure correct formatting of directory paths
📝 (test_format_directory_path.py): add documentation and examples for different types of directory paths in the unit tests to improve code readability and maintainability

* 🐛 (utils.py): fix the incorrect replacement of backslashes with newline characters in the format_directory_path function
📝 (test_rewrite_file_path.py): update test cases and function names to reflect the changes made in the format_directory_path function in utils.py

* 🐛 (test_format_directory_path.py): update parameter name from 'path' to 'input_path' for clarity and consistency
📝 (test_format_directory_path.py): improve test case descriptions and handle newline characters in paths correctly

* feat: update theme (#4084)

* update theme

* update component styles

* change output node background

* update background for component folderrs

* update astra icon coloring

* fix: border and editor display issues (#4142)

* Fixed border on chat input on playground

* Fixed ace editor not taking up entire screen

* fix: Union type on components  (#4137)

* 🐛 (type_extraction.py): fix condition to correctly handle UnionType objects in type extraction process

*  (test_schema.py): add support for additional data types and nested structures in post_process_type function to improve type handling and flexibility

*  (test_schema.py): add additional test cases for post_process_type function to cover various Union types and combinations for better test coverage and accuracy

* Adding Astra Tools

* [autofix.ci] apply automated fixes

* Lint and Renaming to AstraDB

* Adding Astra Tools

* Cleanup old files and re-format

* More formatting

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Gabriel Luiz Freitas Almeida <gabriel@langflow.org>
Co-authored-by: Eric Schneider <37347760+eric-schneider@users.noreply.github.com>
Co-authored-by: Lucas Oliveira <62335616+lucaseduoli@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Jordan Frazier <122494242+jordanrfrazier@users.noreply.github.com>
Co-authored-by: Christophe Bornet <cbornet@hotmail.com>
Co-authored-by: Cristhian Zanforlin Lousa <cristhian.lousa@gmail.com>
Co-authored-by: dhlidongming <lidongming@dhgate.com>
Co-authored-by: Mike Fortman <michael.fortman@datastax.com>
2024-10-15 11:52:58 -07:00
Christophe Bornet
eb53f66641 ref: Use pathlib in tests (#4159)
Use pathlib in tests
2024-10-15 17:51:50 +00:00
Gabriel Luiz Freitas Almeida
54dd81a681 chore: removes Poetry references from pyproject.toml and updates the project metadata (#4019)
* Remove Poetry references from pyproject.toml and update project metadata

* Remove '--no-update' flag from 'uv lock' commands in Makefile

* Add script metadata with Python version and dependencies

* Remove Poetry references and integrate UV setup in CI workflow

* Remove Poetry setup and installation from integration tests workflow

* Remove Poetry references and update workflow to use custom setup action

* Remove references to Poetry from configuration files
2024-10-04 17:24:55 +00:00
Jordan Frazier
e19d90bd6c ci: fix releases with uv (#3971)
* Update scripts

* update the base dep in uv deps

* update nightly scripts

* Add uv creds for publish

* skip tests for now

* fix version

* only build the wheel

* try again

* add uv to python run

* [autofix.ci] apply automated fixes

* use uv cache

* more version fixe

* fixing versions

* fix base version

* Try no frozen?

* skip everything to try docker build

* tag

* frozen

* separate script for updating uv dep

* [autofix.ci] apply automated fixes

* hardcoded versions

* hardcoded versions

* add version to editable package

* build project before docker file runs

* try again

* fix uv patht o build

* don't know why this would mkae a difference

* debug statements

* debug statements

* debug statements

* change path to whl 🤷

* manually move the wheel...

* make dir

* try no sources

* add back tests

* refactor uv to action

* add uv action

* Update nightly build workflow to include uv lock files in version update commit

* Update lint-py workflow to use specific ref for setup-uv action

* Add checkout step to style-check-py GitHub Actions workflow

* Remove redundant GitHub ref syntax in lint-py.yml workflow

* Update lint-py.yml to use specific ref for setup-uv action

* Update action.yml: standardize quotes and remove redundant checkout step

* Add checkout step to GitHub Actions workflows for specific ref handling

- Introduced `actions/checkout@v4` step to multiple workflows to ensure code is checked out at a specific ref.
- Updated `.github/workflows/docker-build.yml`, `.github/workflows/release_nightly.yml`, `.github/workflows/lint-py.yml`, and `.github/workflows/style-check-py.yml` to include the new checkout step.
- Ensured credentials are persisted during the checkout process.

* Add checkout step to Python test workflow with specific ref

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Gabriel Luiz Freitas Almeida <gabriel@langflow.org>
2024-10-02 05:37:04 -07:00