-
Notifications
You must be signed in to change notification settings - Fork 9.6k
feat: ship langflow-core for 1.11 #14099
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
c7a17d6
db4b17c
a33b411
969d348
7a4881d
036549b
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -12,11 +12,15 @@ on: | |||||||||||||||||||||||||||||||
| inputs: | ||||||||||||||||||||||||||||||||
| base-artifact-name: | ||||||||||||||||||||||||||||||||
| description: "Name of the base package artifact" | ||||||||||||||||||||||||||||||||
| required: true | ||||||||||||||||||||||||||||||||
| required: false | ||||||||||||||||||||||||||||||||
| type: string | ||||||||||||||||||||||||||||||||
| core-artifact-name: | ||||||||||||||||||||||||||||||||
| description: "Name of the langflow-core package artifact" | ||||||||||||||||||||||||||||||||
| required: false | ||||||||||||||||||||||||||||||||
| type: string | ||||||||||||||||||||||||||||||||
| main-artifact-name: | ||||||||||||||||||||||||||||||||
| description: "Name of the main package artifact" | ||||||||||||||||||||||||||||||||
| required: true | ||||||||||||||||||||||||||||||||
| required: false | ||||||||||||||||||||||||||||||||
| type: string | ||||||||||||||||||||||||||||||||
| lfx-artifact-name: | ||||||||||||||||||||||||||||||||
| description: "Name of the LFX package artifact" | ||||||||||||||||||||||||||||||||
|
|
@@ -43,6 +47,7 @@ jobs: | |||||||||||||||||||||||||||||||
| if: inputs.langflow-version == '' && contains(github.workflow_ref, 'cross-platform-test.yml') | ||||||||||||||||||||||||||||||||
| outputs: | ||||||||||||||||||||||||||||||||
| base-artifact-name: ${{ steps.set-names.outputs.base-artifact-name }} | ||||||||||||||||||||||||||||||||
| core-artifact-name: ${{ steps.set-names.outputs.core-artifact-name }} | ||||||||||||||||||||||||||||||||
| main-artifact-name: ${{ steps.set-names.outputs.main-artifact-name }} | ||||||||||||||||||||||||||||||||
| lfx-artifact-name: ${{ steps.set-names.outputs.lfx-artifact-name }} | ||||||||||||||||||||||||||||||||
| sdk-artifact-name: ${{ steps.set-names.outputs.sdk-artifact-name }} | ||||||||||||||||||||||||||||||||
|
|
@@ -69,6 +74,8 @@ jobs: | |||||||||||||||||||||||||||||||
| # Base package builds to dist/ but should be in src/backend/base/dist/ | ||||||||||||||||||||||||||||||||
| mkdir -p src/backend/base/dist | ||||||||||||||||||||||||||||||||
| mv dist/langflow_base*.whl src/backend/base/dist/ | ||||||||||||||||||||||||||||||||
| - name: Build core package | ||||||||||||||||||||||||||||||||
| run: make build_langflow_core args="--wheel" | ||||||||||||||||||||||||||||||||
| - name: Build LFX package | ||||||||||||||||||||||||||||||||
| run: | | ||||||||||||||||||||||||||||||||
| cd src/lfx | ||||||||||||||||||||||||||||||||
|
|
@@ -113,6 +120,11 @@ jobs: | |||||||||||||||||||||||||||||||
| with: | ||||||||||||||||||||||||||||||||
| name: adhoc-dist-base | ||||||||||||||||||||||||||||||||
| path: src/backend/base/dist | ||||||||||||||||||||||||||||||||
| - name: Upload core artifact | ||||||||||||||||||||||||||||||||
| uses: actions/upload-artifact@v6 | ||||||||||||||||||||||||||||||||
| with: | ||||||||||||||||||||||||||||||||
| name: adhoc-dist-core | ||||||||||||||||||||||||||||||||
| path: src/langflow-core/dist | ||||||||||||||||||||||||||||||||
| - name: Upload main artifact | ||||||||||||||||||||||||||||||||
| uses: actions/upload-artifact@v6 | ||||||||||||||||||||||||||||||||
| with: | ||||||||||||||||||||||||||||||||
|
|
@@ -128,6 +140,7 @@ jobs: | |||||||||||||||||||||||||||||||
| id: set-names | ||||||||||||||||||||||||||||||||
| run: | | ||||||||||||||||||||||||||||||||
| echo "base-artifact-name=adhoc-dist-base" >> $GITHUB_OUTPUT | ||||||||||||||||||||||||||||||||
| echo "core-artifact-name=adhoc-dist-core" >> $GITHUB_OUTPUT | ||||||||||||||||||||||||||||||||
| echo "main-artifact-name=adhoc-dist-main" >> $GITHUB_OUTPUT | ||||||||||||||||||||||||||||||||
| echo "lfx-artifact-name=adhoc-dist-lfx" >> $GITHUB_OUTPUT | ||||||||||||||||||||||||||||||||
| echo "sdk-artifact-name=adhoc-dist-sdk" >> $GITHUB_OUTPUT | ||||||||||||||||||||||||||||||||
|
|
@@ -140,7 +153,10 @@ jobs: | |||||||||||||||||||||||||||||||
| test-installation-stable: | ||||||||||||||||||||||||||||||||
| name: Install & Run - ${{ matrix.os }} ${{ matrix.arch }} ${{ matrix.python-version }} | ||||||||||||||||||||||||||||||||
| needs: [build-if-needed] | ||||||||||||||||||||||||||||||||
| if: always() && (needs.build-if-needed.result == 'success' || needs.build-if-needed.result == 'skipped') | ||||||||||||||||||||||||||||||||
| if: | | ||||||||||||||||||||||||||||||||
| always() && | ||||||||||||||||||||||||||||||||
| (needs.build-if-needed.result == 'success' || needs.build-if-needed.result == 'skipped') && | ||||||||||||||||||||||||||||||||
| (inputs.langflow-version != '' || inputs.main-artifact-name != '' || needs.build-if-needed.outputs.main-artifact-name != '') | ||||||||||||||||||||||||||||||||
| runs-on: ${{ matrix.runner }} | ||||||||||||||||||||||||||||||||
| strategy: | ||||||||||||||||||||||||||||||||
| fail-fast: false | ||||||||||||||||||||||||||||||||
|
|
@@ -257,7 +273,7 @@ jobs: | |||||||||||||||||||||||||||||||
| path: ./base-dist | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| - name: Download main package artifact | ||||||||||||||||||||||||||||||||
| if: steps.install-method.outputs.method == 'wheel' | ||||||||||||||||||||||||||||||||
| if: steps.install-method.outputs.method == 'wheel' && (inputs.main-artifact-name != '' || needs.build-if-needed.outputs.main-artifact-name != '') | ||||||||||||||||||||||||||||||||
| uses: actions/download-artifact@v7 | ||||||||||||||||||||||||||||||||
| with: | ||||||||||||||||||||||||||||||||
| name: ${{ inputs.main-artifact-name || needs.build-if-needed.outputs.main-artifact-name || 'adhoc-dist-main' }} | ||||||||||||||||||||||||||||||||
|
|
@@ -464,7 +480,10 @@ jobs: | |||||||||||||||||||||||||||||||
| test-installation-experimental: | ||||||||||||||||||||||||||||||||
| name: Install & Run - ${{ matrix.os }} ${{ matrix.arch }} ${{ matrix.python-version }} (Experimental) | ||||||||||||||||||||||||||||||||
| needs: [build-if-needed] | ||||||||||||||||||||||||||||||||
| if: always() && (needs.build-if-needed.result == 'success' || needs.build-if-needed.result == 'skipped') | ||||||||||||||||||||||||||||||||
| if: | | ||||||||||||||||||||||||||||||||
| always() && | ||||||||||||||||||||||||||||||||
| (needs.build-if-needed.result == 'success' || needs.build-if-needed.result == 'skipped') && | ||||||||||||||||||||||||||||||||
| (inputs.langflow-version != '' || inputs.main-artifact-name != '' || needs.build-if-needed.outputs.main-artifact-name != '') | ||||||||||||||||||||||||||||||||
| runs-on: ${{ matrix.runner }} | ||||||||||||||||||||||||||||||||
| continue-on-error: true | ||||||||||||||||||||||||||||||||
| strategy: | ||||||||||||||||||||||||||||||||
|
|
@@ -553,7 +572,7 @@ jobs: | |||||||||||||||||||||||||||||||
| path: ./base-dist | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| - name: Download main package artifact | ||||||||||||||||||||||||||||||||
| if: steps.install-method.outputs.method == 'wheel' | ||||||||||||||||||||||||||||||||
| if: steps.install-method.outputs.method == 'wheel' && (inputs.main-artifact-name != '' || needs.build-if-needed.outputs.main-artifact-name != '') | ||||||||||||||||||||||||||||||||
| uses: actions/download-artifact@v7 | ||||||||||||||||||||||||||||||||
| with: | ||||||||||||||||||||||||||||||||
| name: ${{ inputs.main-artifact-name || needs.build-if-needed.outputs.main-artifact-name || 'adhoc-dist-main' }} | ||||||||||||||||||||||||||||||||
|
|
@@ -889,19 +908,204 @@ jobs: | |||||||||||||||||||||||||||||||
| " | ||||||||||||||||||||||||||||||||
| shell: bash | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| test-core-runtime: | ||||||||||||||||||||||||||||||||
| name: Core Distribution Wheel - Linux Python 3.14 | ||||||||||||||||||||||||||||||||
| needs: [build-if-needed] | ||||||||||||||||||||||||||||||||
| if: | | ||||||||||||||||||||||||||||||||
|
Comment on lines
+913
to
+914
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🔒 Security & Privacy | 🟡 Minor | ⚡ Quick win 🧩 Analysis chain🏁 Script executed: #!/bin/bash
set -euo pipefail
printf '\n## Top-level workflow permissions and job context\n'
rg -n --no-heading '^(permissions:| test-core-runtime:| permissions:| needs:| if:| steps:| uses:| runs-on:)' .github/workflows/cross-platform-test.yml
printf '\n## Nearby lines around the cited job\n'
sed -n '900,960p' .github/workflows/cross-platform-test.yml
printf '\n## Any explicit permissions blocks in this workflow\n'
rg -n --no-heading '^(\s*)permissions:' .github/workflows/cross-platform-test.ymlRepository: langflow-ai/langflow Length of output: 3471 🌐 Web query:
💡 Result: When using the Citations:
Restrict this job’s token scope. It only downloads artifacts and runs local validation, so add an explicit least-privilege block; for Proposed fix test-core-runtime:
name: Core Distribution Wheel - Linux Python 3.14
needs: [build-if-needed]
+ permissions:
+ actions: read
+ contents: read📝 Committable suggestion
Suggested change
🤖 Prompt for AI AgentsSource: Linters/SAST tools |
||||||||||||||||||||||||||||||||
| always() && | ||||||||||||||||||||||||||||||||
| inputs.langflow-version == '' && | ||||||||||||||||||||||||||||||||
| (needs.build-if-needed.result == 'success' || needs.build-if-needed.result == 'skipped') && | ||||||||||||||||||||||||||||||||
| (inputs.base-artifact-name != '' || inputs.core-artifact-name != '' || | ||||||||||||||||||||||||||||||||
| needs.build-if-needed.outputs.base-artifact-name != '' || | ||||||||||||||||||||||||||||||||
| needs.build-if-needed.outputs.core-artifact-name != '') | ||||||||||||||||||||||||||||||||
| runs-on: ubuntu-latest | ||||||||||||||||||||||||||||||||
| steps: | ||||||||||||||||||||||||||||||||
| - name: Setup UV | ||||||||||||||||||||||||||||||||
| uses: astral-sh/setup-uv@v6 | ||||||||||||||||||||||||||||||||
| with: | ||||||||||||||||||||||||||||||||
| enable-cache: false | ||||||||||||||||||||||||||||||||
| python-version: "3.14" | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| - name: Download langflow-sdk package artifact | ||||||||||||||||||||||||||||||||
| if: inputs.sdk-artifact-name != '' || needs.build-if-needed.outputs.sdk-artifact-name != '' | ||||||||||||||||||||||||||||||||
| uses: actions/download-artifact@v7 | ||||||||||||||||||||||||||||||||
| with: | ||||||||||||||||||||||||||||||||
| name: ${{ inputs.sdk-artifact-name || needs.build-if-needed.outputs.sdk-artifact-name || 'adhoc-dist-sdk' }} | ||||||||||||||||||||||||||||||||
| path: ./sdk-dist | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| - name: Download LFX package artifact | ||||||||||||||||||||||||||||||||
| if: inputs.lfx-artifact-name != '' || needs.build-if-needed.outputs.lfx-artifact-name != '' | ||||||||||||||||||||||||||||||||
| uses: actions/download-artifact@v7 | ||||||||||||||||||||||||||||||||
| with: | ||||||||||||||||||||||||||||||||
| name: ${{ inputs.lfx-artifact-name || needs.build-if-needed.outputs.lfx-artifact-name || 'adhoc-dist-lfx' }} | ||||||||||||||||||||||||||||||||
| path: ./lfx-dist | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| - name: Download base package artifact | ||||||||||||||||||||||||||||||||
| if: inputs.base-artifact-name != '' || needs.build-if-needed.outputs.base-artifact-name != '' | ||||||||||||||||||||||||||||||||
| uses: actions/download-artifact@v7 | ||||||||||||||||||||||||||||||||
| with: | ||||||||||||||||||||||||||||||||
| name: ${{ inputs.base-artifact-name || needs.build-if-needed.outputs.base-artifact-name || 'adhoc-dist-base' }} | ||||||||||||||||||||||||||||||||
| path: ./base-dist | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| - name: Download langflow-core package artifact | ||||||||||||||||||||||||||||||||
| if: inputs.core-artifact-name != '' || needs.build-if-needed.outputs.core-artifact-name != '' | ||||||||||||||||||||||||||||||||
| uses: actions/download-artifact@v7 | ||||||||||||||||||||||||||||||||
| with: | ||||||||||||||||||||||||||||||||
| name: ${{ inputs.core-artifact-name || needs.build-if-needed.outputs.core-artifact-name || 'adhoc-dist-core' }} | ||||||||||||||||||||||||||||||||
| path: ./core-dist | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| - name: Install only core wheels | ||||||||||||||||||||||||||||||||
| shell: bash | ||||||||||||||||||||||||||||||||
| run: | | ||||||||||||||||||||||||||||||||
| set -euo pipefail | ||||||||||||||||||||||||||||||||
| shopt -s nullglob | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| SDK_WHEELS=(./sdk-dist/*.whl) | ||||||||||||||||||||||||||||||||
| LFX_WHEELS=(./lfx-dist/*.whl) | ||||||||||||||||||||||||||||||||
| BASE_WHEELS=(./base-dist/*.whl) | ||||||||||||||||||||||||||||||||
| CORE_WHEELS=(./core-dist/*.whl) | ||||||||||||||||||||||||||||||||
| [ ${#SDK_WHEELS[@]} -le 1 ] || { echo "Expected at most one SDK wheel, found ${#SDK_WHEELS[@]}"; exit 1; } | ||||||||||||||||||||||||||||||||
| [ ${#LFX_WHEELS[@]} -le 1 ] || { echo "Expected at most one LFX wheel, found ${#LFX_WHEELS[@]}"; exit 1; } | ||||||||||||||||||||||||||||||||
| [ ${#BASE_WHEELS[@]} -le 1 ] || { echo "Expected at most one base wheel, found ${#BASE_WHEELS[@]}"; exit 1; } | ||||||||||||||||||||||||||||||||
| [ ${#CORE_WHEELS[@]} -le 1 ] || { echo "Expected at most one core wheel, found ${#CORE_WHEELS[@]}"; exit 1; } | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| FIND_LINKS=() | ||||||||||||||||||||||||||||||||
| for directory in sdk-dist lfx-dist base-dist core-dist; do | ||||||||||||||||||||||||||||||||
| if [ -d "$directory" ]; then | ||||||||||||||||||||||||||||||||
| FIND_LINKS+=(--find-links "./$directory") | ||||||||||||||||||||||||||||||||
| fi | ||||||||||||||||||||||||||||||||
| done | ||||||||||||||||||||||||||||||||
| if [ ${#CORE_WHEELS[@]} -eq 1 ]; then | ||||||||||||||||||||||||||||||||
| INSTALL_ROOTS=("${CORE_WHEELS[0]}") | ||||||||||||||||||||||||||||||||
| echo "EXPECT_LANGFLOW_CORE=true" >> "$GITHUB_ENV" | ||||||||||||||||||||||||||||||||
| elif [ ${#BASE_WHEELS[@]} -eq 1 ]; then | ||||||||||||||||||||||||||||||||
| INSTALL_ROOTS=("${BASE_WHEELS[0]}") | ||||||||||||||||||||||||||||||||
| echo "EXPECT_LANGFLOW_CORE=false" >> "$GITHUB_ENV" | ||||||||||||||||||||||||||||||||
| else | ||||||||||||||||||||||||||||||||
| echo "A base or langflow-core wheel is required for the core runtime test." | ||||||||||||||||||||||||||||||||
| exit 1 | ||||||||||||||||||||||||||||||||
| fi | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| uv venv core-test-env --seed --python 3.14 | ||||||||||||||||||||||||||||||||
| uv pip install --python core-test-env/bin/python \ | ||||||||||||||||||||||||||||||||
| --prerelease=if-necessary-or-explicit \ | ||||||||||||||||||||||||||||||||
| "${FIND_LINKS[@]}" "${SDK_WHEELS[@]}" "${LFX_WHEELS[@]}" "${INSTALL_ROOTS[@]}" | ||||||||||||||||||||||||||||||||
| uv pip check --python core-test-env/bin/python | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| - name: Verify core boundary and indexed imports | ||||||||||||||||||||||||||||||||
| shell: bash | ||||||||||||||||||||||||||||||||
| run: | | ||||||||||||||||||||||||||||||||
| core-test-env/bin/python - <<'PY' | ||||||||||||||||||||||||||||||||
| import importlib | ||||||||||||||||||||||||||||||||
| import os | ||||||||||||||||||||||||||||||||
| import re | ||||||||||||||||||||||||||||||||
| from importlib.metadata import distributions, entry_points | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| from lfx.interface.components import _read_component_index | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| normalize = lambda value: re.sub(r"[-_.]+", "-", value).lower() | ||||||||||||||||||||||||||||||||
| installed = {normalize(dist.metadata["Name"]) for dist in distributions() if dist.metadata["Name"]} | ||||||||||||||||||||||||||||||||
| assert {"langflow-base", "langflow-sdk", "lfx"} <= installed, installed | ||||||||||||||||||||||||||||||||
| assert "langflow" not in installed, installed | ||||||||||||||||||||||||||||||||
| if os.environ["EXPECT_LANGFLOW_CORE"] == "true": | ||||||||||||||||||||||||||||||||
| assert "langflow-core" in installed, installed | ||||||||||||||||||||||||||||||||
| else: | ||||||||||||||||||||||||||||||||
| assert "langflow-core" not in installed, installed | ||||||||||||||||||||||||||||||||
| extensions = sorted(name for name in installed if name.startswith("lfx-")) | ||||||||||||||||||||||||||||||||
| assert not extensions, f"Extension distributions installed: {extensions}" | ||||||||||||||||||||||||||||||||
| for group in ("lfx.bundles", "langflow.extensions", "langflow.plugins"): | ||||||||||||||||||||||||||||||||
| assert not entry_points(group=group), f"Extension entry points registered in {group}" | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| index = _read_component_index() | ||||||||||||||||||||||||||||||||
| assert index is not None, "Installed LFX rejected its bundled component index" | ||||||||||||||||||||||||||||||||
| assert index["metadata"] == {"num_modules": 17, "num_components": 130} | ||||||||||||||||||||||||||||||||
| for category, components in index["entries"]: | ||||||||||||||||||||||||||||||||
| for component_name, component in components.items(): | ||||||||||||||||||||||||||||||||
| module_path = component.get("metadata", {}).get("module") | ||||||||||||||||||||||||||||||||
| assert module_path, f"{category}.{component_name} has no module" | ||||||||||||||||||||||||||||||||
| module_name, class_name = module_path.rsplit(".", 1) | ||||||||||||||||||||||||||||||||
| getattr(importlib.import_module(module_name), class_name) | ||||||||||||||||||||||||||||||||
| PY | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| - name: Boot installed core server | ||||||||||||||||||||||||||||||||
| shell: bash | ||||||||||||||||||||||||||||||||
| timeout-minutes: 5 | ||||||||||||||||||||||||||||||||
| run: | | ||||||||||||||||||||||||||||||||
| set -euo pipefail | ||||||||||||||||||||||||||||||||
| RUNTIME_DIR=$(mktemp -d) | ||||||||||||||||||||||||||||||||
| export LANGFLOW_CONFIG_DIR="$RUNTIME_DIR/config" | ||||||||||||||||||||||||||||||||
| export LANGFLOW_SAVE_DB_IN_CONFIG_DIR=true | ||||||||||||||||||||||||||||||||
| export LANGFLOW_AUTO_LOGIN=true | ||||||||||||||||||||||||||||||||
| export DO_NOT_TRACK=true | ||||||||||||||||||||||||||||||||
| LOG_FILE="$RUNTIME_DIR/server.log" | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| if [ "$EXPECT_LANGFLOW_CORE" = "true" ]; then | ||||||||||||||||||||||||||||||||
| LANGFLOW_CLI=core-test-env/bin/langflow | ||||||||||||||||||||||||||||||||
| else | ||||||||||||||||||||||||||||||||
| LANGFLOW_CLI=core-test-env/bin/langflow-base | ||||||||||||||||||||||||||||||||
| fi | ||||||||||||||||||||||||||||||||
| "$LANGFLOW_CLI" run \ | ||||||||||||||||||||||||||||||||
| --host 127.0.0.1 --port 7861 --backend-only --workers 1 >"$LOG_FILE" 2>&1 & | ||||||||||||||||||||||||||||||||
|
Comment on lines
+1042
to
+1048
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win Exercise the new The test currently validates only the compatibility Proposed fix if [ "$EXPECT_LANGFLOW_CORE" = "true" ]; then
- LANGFLOW_CLI=core-test-env/bin/langflow
+ core-test-env/bin/langflow --help >/dev/null
+ LANGFLOW_CLI=core-test-env/bin/langflow-core
else
LANGFLOW_CLI=core-test-env/bin/langflow-base
fi📝 Committable suggestion
Suggested change
🤖 Prompt for AI Agents |
||||||||||||||||||||||||||||||||
| SERVER_PID=$! | ||||||||||||||||||||||||||||||||
| cleanup() { | ||||||||||||||||||||||||||||||||
| kill "$SERVER_PID" 2>/dev/null || true | ||||||||||||||||||||||||||||||||
| wait "$SERVER_PID" 2>/dev/null || true | ||||||||||||||||||||||||||||||||
| } | ||||||||||||||||||||||||||||||||
| trap cleanup EXIT | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| READY=false | ||||||||||||||||||||||||||||||||
| for _ in $(seq 1 90); do | ||||||||||||||||||||||||||||||||
| if curl -fsS http://127.0.0.1:7861/health_check >/dev/null 2>&1; then | ||||||||||||||||||||||||||||||||
| READY=true | ||||||||||||||||||||||||||||||||
| break | ||||||||||||||||||||||||||||||||
| fi | ||||||||||||||||||||||||||||||||
| if ! kill -0 "$SERVER_PID" 2>/dev/null; then | ||||||||||||||||||||||||||||||||
| cat "$LOG_FILE" | ||||||||||||||||||||||||||||||||
| exit 1 | ||||||||||||||||||||||||||||||||
| fi | ||||||||||||||||||||||||||||||||
| sleep 2 | ||||||||||||||||||||||||||||||||
| done | ||||||||||||||||||||||||||||||||
| if [ "$READY" != true ]; then | ||||||||||||||||||||||||||||||||
| cat "$LOG_FILE" | ||||||||||||||||||||||||||||||||
| exit 1 | ||||||||||||||||||||||||||||||||
| fi | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| curl -fsS -c "$RUNTIME_DIR/cookies" http://127.0.0.1:7861/api/v1/auto_login >/dev/null | ||||||||||||||||||||||||||||||||
| curl -fsS --compressed -b "$RUNTIME_DIR/cookies" \ | ||||||||||||||||||||||||||||||||
| http://127.0.0.1:7861/api/v1/all >"$RUNTIME_DIR/catalog.json" | ||||||||||||||||||||||||||||||||
| jq -e 'del(.component_display_names) | (length == 17 and ([.[] | length] | add) == 130)' \ | ||||||||||||||||||||||||||||||||
| "$RUNTIME_DIR/catalog.json" | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| test-summary: | ||||||||||||||||||||||||||||||||
| name: Cross-Platform Test Summary | ||||||||||||||||||||||||||||||||
| needs: [test-installation-stable, test-installation-experimental] | ||||||||||||||||||||||||||||||||
| needs: [test-installation-stable, test-installation-experimental, test-core-runtime] | ||||||||||||||||||||||||||||||||
| runs-on: ubuntu-latest | ||||||||||||||||||||||||||||||||
| if: always() | ||||||||||||||||||||||||||||||||
| steps: | ||||||||||||||||||||||||||||||||
| - name: Check test results | ||||||||||||||||||||||||||||||||
| run: | | ||||||||||||||||||||||||||||||||
| stable_result="${{ needs.test-installation-stable.result }}" | ||||||||||||||||||||||||||||||||
| experimental_result="${{ needs.test-installation-experimental.result }}" | ||||||||||||||||||||||||||||||||
| core_result="${{ needs.test-core-runtime.result }}" | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| echo "Stable platforms result: $stable_result" | ||||||||||||||||||||||||||||||||
| echo "Experimental platforms result: $experimental_result" | ||||||||||||||||||||||||||||||||
| echo "Core runtime result: $core_result" | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| if [ "$stable_result" = "skipped" ] && [ "$core_result" = "skipped" ]; then | ||||||||||||||||||||||||||||||||
| echo "✅ No Langflow application distribution was selected; package build tests passed" | ||||||||||||||||||||||||||||||||
| exit 0 | ||||||||||||||||||||||||||||||||
| fi | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| if [ "${{ inputs.langflow-version }}" = "" ] && [ "$core_result" != "success" ]; then | ||||||||||||||||||||||||||||||||
|
Comment on lines
1085
to
+1100
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🔒 Security & Privacy | 🟠 Major | ⚡ Quick win 🧩 Analysis chain🏁 Script executed: #!/bin/bash
set -euo pipefail
# Inspect the relevant workflow section with line numbers
sed -n '1040,1120p' .github/workflows/cross-platform-test.yml | cat -n
printf '\n---\n'
# Inspect the workflow triggers and input declarations
rg -n "workflow_call|inputs:|langflow-version|on:" .github/workflows/cross-platform-test.yml
printf '\n---\n'
# Show the top of the file for reusable-workflow context
sed -n '1,120p' .github/workflows/cross-platform-test.yml | cat -nRepository: langflow-ai/langflow Length of output: 12233 Avoid expanding the workflow input directly in the shell. 🧰 Tools🪛 zizmor (1.26.1)[error] 1100-1100: code injection via template expansion (template-injection): may expand into attacker-controllable code (template-injection) 🤖 Prompt for AI AgentsSource: Linters/SAST tools |
||||||||||||||||||||||||||||||||
| echo "❌ Core runtime wheel test failed: $core_result" | ||||||||||||||||||||||||||||||||
| exit 1 | ||||||||||||||||||||||||||||||||
| fi | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| if [ "$stable_result" = "skipped" ] && [ "$core_result" = "success" ]; then | ||||||||||||||||||||||||||||||||
| echo "✅ Core-only wheel installation tests passed" | ||||||||||||||||||||||||||||||||
| exit 0 | ||||||||||||||||||||||||||||||||
| fi | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
| # Stable platforms must succeed, experimental can fail | ||||||||||||||||||||||||||||||||
| if [ "$stable_result" = "success" ]; then | ||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🩺 Stability & Availability | 🟠 Major | ⚡ Quick win
Do not make experimental Python 3.14 the blocking core release gate.
The workflow explicitly treats Python 3.14 as non-blocking elsewhere, but this job makes its dependency compatibility mandatory for release. Run the blocking core check on a stable version such as 3.13; retain 3.14 separately as experimental coverage.
Proposed fix
Also applies to: 923-927, 989-993, 1100-1103
🤖 Prompt for AI Agents