mirror of
https://github.com/n8n-io/n8n.git
synced 2026-10-18 14:56:50 +02:00
n8n now parses the same allowlist the Python runner enforces, so the two can drift: the runner's suite and n8n's unit tests could both stay green while the builder describes a policy that is not applied. - Add a shared fixture, read by a test on each side, pinning how N8N_RUNNERS_STDLIB_ALLOW / N8N_RUNNERS_EXTERNAL_ALLOW parse. It caught a real divergence on the first run: the runner returns a set and collapses duplicates, n8n's parser did not. Fixed. - Add an integration test that starts the Python runner for real and drives a Code node through the broker, covering config -> spawned runner env -> enforcement in one path: import-free code runs, an allowlisted import runs, a non-allowlisted one is rejected, and the rejection names the configured list (so it cannot pass against an empty default). The integration test needs the runner's virtualenv and skips without it, which is most Node CI lanes today; verified it skips rather than fails. Making `getVenvPath` public is what lets it decide that synchronously. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> |
||
|---|---|---|
| .. | ||
| test_allowlist_parsing_contract.py | ||
| test_env.py | ||
| test_import_validation.py | ||
| test_sandbox_hardening.py | ||
| test_sentry.py | ||
| test_task_analyzer.py | ||
| test_task_executor.py | ||
| test_task_runner_config.py | ||
| test_task_runner.py | ||
| test_transitive_dependency_trust.py | ||