Skip to content

Conversation

@AlexSkrypnyk
Copy link
Member

@AlexSkrypnyk AlexSkrypnyk commented Jul 26, 2025

Summary by CodeRabbit

  • New Features

    • Added a confirmation prompt before key commands to ensure explicit user approval.
    • Introduced a utility command for consistent user confirmation prompts, supporting environment variable overrides and optional wait time.
  • Refactor

    • Improved confirmation logic for clearer output and better control flow.
    • Updated test logging to include clearer step delimiters and direct output to standard error.
    • Refined command structures for clarity and consistency in command chaining.
    • Adjusted command matching patterns and indentation for provisioning steps.
  • Chores

    • Simplified the linting command for tests into a single line.
    • Suppressed verbose output during dependency installation in test setup scripts.
    • Corrected usage descriptions for login and PHPUnit test commands.
    • Updated test environment variable from TEST_VORTEX_VERBOSE to TEST_VORTEX_DEBUG.
    • Adjusted namespace order and increased process timeout in test configuration.

@coderabbitai
Copy link

coderabbitai bot commented Jul 26, 2025

"""

Walkthrough

The .ahoy.yml file was updated to add a new internal confirm utility command for standardized user confirmation prompts, including support for environment variable overrides and optional wait times. The provision, build, down, reload-db, reset, and deploy commands now require explicit user confirmation before proceeding, with updated logic using logical OR and clearer command structure. The lint-tests command was simplified into a single line. Minor usage text corrections were made in several commands. Test files were updated to reflect the removal of the cmd: prefix in the provision command string, aligning string matching and replacement logic accordingly. The test workflow script was modified to suppress output from dependency installation commands. The GitHub workflow was updated to pass a debug environment variable to test jobs. The PSR-4 autoload-dev order was swapped and a composer process timeout was added. Logger output methods were adjusted to write newlines explicitly to stderr. The environment variable controlling verbosity in functional tests was changed from TEST_VORTEX_VERBOSE to TEST_VORTEX_DEBUG.

Changes

File(s) Change Summary
.ahoy.yml Added hidden confirm utility command; modified multiple commands (build, down, reload-db, provision, reset, deploy) to require confirmation with updated logic; simplified lint-tests; fixed usage texts
.vortex/tests/phpunit/Traits/Steps/StepPrepareSutTrait.php Updated string matching and replacement logic to reflect removal of cmd: prefix in provision command string
.vortex/tests/bats/_helper.bash Narrowed pattern matching for provision command replacement to include indentation and omit cmd: prefix; replacement logic unchanged
.vortex/tests/test.workflow.sh Suppressed output of yarn install and composer install commands by redirecting to /dev/null
.github/workflows/vortex-test-common.yml Added TEST_VORTEX_DEBUG environment variable to test job steps
.vortex/tests/composer.json Swapped order of PSR-4 autoload-dev namespaces; added process-timeout config
.vortex/tests/phpunit/Functional/FunctionalTestCase.php Changed verbosity environment variable check from TEST_VORTEX_VERBOSE to TEST_VORTEX_DEBUG
.vortex/tests/phpunit/Traits/LoggerTrait.php Added explicit newline output to stderr after step start/finish logs; changed substep logging to direct stderr writes

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~15 minutes

Poem

A bunny hops with careful cheer,
Confirming scripts before they clear.
With prompts and waits, we now proceed,
Ensuring safety in every deed.
Linting swift, commands refined—
In code and carrots, peace of mind! 🥕
"""

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 phpcs (3.7.2)
.vortex/tests/phpunit/Functional/FunctionalTestCase.php

ERROR: Referenced sniff "Drupal" does not exist

Run "phpcs --help" for usage information

.vortex/tests/phpunit/Traits/Steps/StepPrepareSutTrait.php

ERROR: Referenced sniff "Drupal" does not exist

Run "phpcs --help" for usage information

✨ Finishing Touches
  • 📝 Generate Docstrings
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch feature/add-confirm-to-ahoy-provision

🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai generate unit tests to generate unit tests for this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@github-actions github-actions bot temporarily deployed to commit July 26, 2025 00:37 Inactive
Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

📜 Review details

Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 7c9a23d and bf9d3f3.

⛔ Files ignored due to path filters (3)
  • .vortex/installer/tests/Fixtures/install/_baseline/.ahoy.yml is excluded by !.vortex/installer/tests/Fixtures/**
  • .vortex/installer/tests/Fixtures/install/theme_absent/.ahoy.yml is excluded by !.vortex/installer/tests/Fixtures/**
  • .vortex/installer/tests/Fixtures/install/theme_absent/web/themes/custom/star_wars/-yarn.lock is excluded by !**/*.lock, !.vortex/installer/tests/Fixtures/**
📒 Files selected for processing (1)
  • .ahoy.yml (3 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (12)
  • GitHub Check: build (0)
  • GitHub Check: build (1)
  • GitHub Check: vortex-test-deployment (1)
  • GitHub Check: vortex-test-workflow (2)
  • GitHub Check: vortex-test-workflow (3)
  • GitHub Check: vortex-test-deployment (0)
  • GitHub Check: vortex-test-workflow (1)
  • GitHub Check: vortex-test-common
  • GitHub Check: vortex-test-installer (8.2)
  • GitHub Check: vortex-test-installer (8.4)
  • GitHub Check: vortex-test-installer (8.3)
  • GitHub Check: vortex-test-docs
🔇 Additional comments (2)
.ahoy.yml (2)

145-147: Confirmation step added correctly – looks good.

The extra ahoy confirm guard is correctly chained with &&, so the provisioning script will only run when the user explicitly approves (or automation injects AHOY_CONFIRM_RESPONSE=y).
No issues spotted here.


214-214: Single-line simplification is fine.

Inlining the Gherkin-lint command improves readability without changing behaviour.

Comment on lines +283 to +292

# Internal utility command to confirm actions before running them.
# Accepts a message as an argument and waits for user confirmation.
# Will proceed only if the user types 'y' or 'true'.
# If AHOY_CONFIRM_RESPONSE is set, it will use that value without prompting
# the user, and will print the prompt with an answer. It will also give a
# 3 seconds delay before proceeding to allow the user to cancel the operation.
# If AHOY_CONFIRM_WAIT_SKIP is also set to '1', it will skip the wait and
# proceed immediately.
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🛠️ Refactor suggestion

Docs list accepted answers, but code later ignores incorrect presets.

The comment says the command “will proceed only if the user types y or true”.
That is true for interactive input (validated below), but not when AHOY_CONFIRM_RESPONSE
is pre-set: any value (including n/false) will currently bypass validation.
This mismatch can lead to destructive operations running in CI or scripts that were
meant to abort.

See next comment for a concrete fix.

🤖 Prompt for AI Agents
In the .ahoy.yml file around lines 283 to 291, the documentation states that the
command proceeds only if the user inputs 'y' or 'true', but when the
AHOY_CONFIRM_RESPONSE environment variable is set, the code bypasses this
validation and proceeds regardless of the value. To fix this, modify the code to
validate the AHOY_CONFIRM_RESPONSE value against the accepted answers ('y' or
'true') before proceeding, ensuring it aborts if the value is not one of these
accepted inputs, thus aligning the behavior with the documented expectations.

Comment on lines 294 to +306
if [ -z "${AHOY_CONFIRM_RESPONSE}" ]; then
read -r -p ">> $1 [y/N] " AHOY_CONFIRM_RESPONSE
[ "${AHOY_CONFIRM_RESPONSE}" = "y" ] || [ "${AHOY_CONFIRM_RESPONSE}" = true ] || ( echo "The operation was canceled." && exit 1 )
if [ "${AHOY_CONFIRM_RESPONSE}" != "y" ] && [ "${AHOY_CONFIRM_RESPONSE}" != "true" ]; then
echo "The operation was canceled."
exit 1
fi
else
echo ">> $1 [y/N] ${AHOY_CONFIRM_RESPONSE}" \
&& if [ "${AHOY_CONFIRM_WAIT_SKIP}" != "1" ]; then echo "Waiting for 3 seconds... Press Ctrl+C to cancel."; sleep 3; fi
if [ "${AHOY_CONFIRM_WAIT_SKIP}" != "1" ]; then
echo ">> $1 [y/N] ${AHOY_CONFIRM_RESPONSE}"
echo "Waiting for 3 seconds... Press Ctrl+C to cancel."
sleep 3
fi
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue

AHOY_CONFIRM_RESPONSE is not validated – destructive commands may run unintentionally.

When the environment variable is preset, the branch starting on line 301 skips the
approval check entirely. If someone sets AHOY_CONFIRM_RESPONSE=n (or any other
string), the command still exits 0 and the caller proceeds:

AHOY_CONFIRM_RESPONSE=n ahoy provision   # ← will happily wipe DB

At the same time, interactive input only accepts the lower-case literal y or true,
ignoring Y, yes, etc.

Proposed hardened logic:

-else
-  if [ "${AHOY_CONFIRM_WAIT_SKIP}" != "1" ]; then
-    echo ">> $1 [y/N] ${AHOY_CONFIRM_RESPONSE}"
-    echo "Waiting for 3 seconds... Press Ctrl+C to cancel."
-    sleep 3
-  fi
-fi
+else
+  # Normalise to lowercase for comparison.
+  _resp=$(printf '%s' "${AHOY_CONFIRM_RESPONSE}" | tr '[:upper:]' '[:lower:]')
+  case "${_resp}" in
+    y|yes|true)
+      if [ "${AHOY_CONFIRM_WAIT_SKIP}" != "1" ]; then
+        echo ">> $1 [y/N] ${AHOY_CONFIRM_RESPONSE}"
+        echo "Waiting for 3 seconds... Press Ctrl+C to cancel."
+        sleep 3
+      fi
+      ;;
+    *)
+      echo "The operation was canceled."
+      exit 1
+      ;;
+  esac
+fi

Benefits:

  1. Rejects any preset value other than y|yes|true.
  2. Accepts common affirmative variants (yes, uppercase).
  3. Keeps the optional wait.

A similar case-folding check can be applied to the interactive branch to accept
Y/YES/True.

🤖 Prompt for AI Agents
In .ahoy.yml around lines 294 to 305, the current logic does not properly
validate the preset AHOY_CONFIRM_RESPONSE environment variable, allowing any
value other than "y" or "true" to proceed and potentially run destructive
commands unintentionally. Update the validation to accept only affirmative
values like "y", "yes", or "true" in any case (case-insensitive), and reject all
others by exiting with an error. Also, modify the interactive input check to
accept common affirmative variants such as "Y", "YES", and "True" in a
case-insensitive manner, while preserving the optional wait behavior.

@codecov
Copy link

codecov bot commented Jul 26, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 75.11%. Comparing base (07699b1) to head (83a1a84).

Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #1846      +/-   ##
===========================================
+ Coverage    75.05%   75.11%   +0.06%     
===========================================
  Files           84       84              
  Lines         4835     4835              
  Branches        35       35              
===========================================
+ Hits          3629     3632       +3     
+ Misses        1206     1203       -3     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@AlexSkrypnyk AlexSkrypnyk force-pushed the feature/add-confirm-to-ahoy-provision branch from bf9d3f3 to e77a3ee Compare July 26, 2025 01:14
@github-actions github-actions bot temporarily deployed to commit July 26, 2025 01:16 Inactive
@AlexSkrypnyk AlexSkrypnyk force-pushed the feature/add-confirm-to-ahoy-provision branch from e77a3ee to a02e012 Compare July 26, 2025 01:26
@github-actions github-actions bot temporarily deployed to commit July 26, 2025 01:29 Inactive
@AlexSkrypnyk AlexSkrypnyk force-pushed the feature/add-confirm-to-ahoy-provision branch from a02e012 to ac5cbe6 Compare July 26, 2025 03:04
@github-actions github-actions bot temporarily deployed to commit July 26, 2025 03:06 Inactive
Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

♻️ Duplicate comments (2)
.ahoy.yml (2)

285-292: Documentation claims validation but implementation bypasses it for preset values.

The documentation states that the command "will proceed only if the user types y or true", but this is only true for interactive input. When AHOY_CONFIRM_RESPONSE is preset, any value (including n/false) will bypass validation and proceed, potentially allowing destructive operations to run unintentionally.


295-307: Critical security issue: AHOY_CONFIRM_RESPONSE validation is completely bypassed.

When the environment variable is preset, the else branch (lines 301-307) skips validation entirely. This means destructive commands will proceed regardless of the preset value:

AHOY_CONFIRM_RESPONSE=n ahoy provision  # ← will still proceed and wipe DB
AHOY_CONFIRM_RESPONSE=false ahoy reset  # ← will still proceed and remove containers

The interactive branch correctly validates only y and true, but preset values need the same validation.

Apply this fix to validate preset responses:

 else
-  if [ "${AHOY_CONFIRM_WAIT_SKIP}" != "1" ]; then
-    echo ">> $1 [y/N] ${AHOY_CONFIRM_RESPONSE}"
-    echo "Waiting for 3 seconds... Press Ctrl+C to cancel."
-    sleep 3
-  fi
+  # Validate preset response
+  if [ "${AHOY_CONFIRM_RESPONSE}" != "y" ] && [ "${AHOY_CONFIRM_RESPONSE}" != "true" ]; then
+    echo "The operation was canceled."
+    exit 1
+  fi
+  if [ "${AHOY_CONFIRM_WAIT_SKIP}" != "1" ]; then
+    echo ">> $1 [y/N] ${AHOY_CONFIRM_RESPONSE}"
+    echo "Waiting for 3 seconds... Press Ctrl+C to cancel."
+    sleep 3
+  fi
 fi
📜 Review details

Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between a02e012 and ac5cbe6.

⛔ Files ignored due to path filters (7)
  • .vortex/installer/tests/Fixtures/install/_baseline/.ahoy.yml is excluded by !.vortex/installer/tests/Fixtures/**
  • .vortex/installer/tests/Fixtures/install/provision_profile/.ahoy.yml is excluded by !.vortex/installer/tests/Fixtures/**
  • .vortex/installer/tests/Fixtures/install/services_no_solr/.ahoy.yml is excluded by !.vortex/installer/tests/Fixtures/**
  • .vortex/installer/tests/Fixtures/install/services_no_valkey/.ahoy.yml is excluded by !.vortex/installer/tests/Fixtures/**
  • .vortex/installer/tests/Fixtures/install/services_none/.ahoy.yml is excluded by !.vortex/installer/tests/Fixtures/**
  • .vortex/installer/tests/Fixtures/install/theme_absent/.ahoy.yml is excluded by !.vortex/installer/tests/Fixtures/**
  • .vortex/installer/tests/Fixtures/install/theme_absent/web/themes/custom/star_wars/-yarn.lock is excluded by !**/*.lock, !.vortex/installer/tests/Fixtures/**
📒 Files selected for processing (8)
  • .ahoy.yml (10 hunks)
  • .github/workflows/vortex-test-common.yml (3 hunks)
  • .vortex/tests/bats/_helper.bash (1 hunks)
  • .vortex/tests/composer.json (1 hunks)
  • .vortex/tests/phpunit/Functional/FunctionalTestCase.php (1 hunks)
  • .vortex/tests/phpunit/Traits/LoggerTrait.php (1 hunks)
  • .vortex/tests/phpunit/Traits/Steps/StepPrepareSutTrait.php (1 hunks)
  • .vortex/tests/test.workflow.sh (1 hunks)
🧰 Additional context used
🧠 Learnings (7)
.github/workflows/vortex-test-common.yml (2)

Learnt from: AlexSkrypnyk
PR: #1714
File: scripts/vortex/doctor.sh:69-70
Timestamp: 2025-06-03T03:15:29.849Z
Learning: In the Vortex project, logging functions (task(), info(), note(), pass(), fail(), warn()) are intentionally duplicated across all script files to make each script self-contained and independent, rather than sharing them through a common library. This design choice prioritizes script independence over reducing code duplication.

Learnt from: AlexSkrypnyk
PR: #1714
File: scripts/vortex/doctor.sh:69-70
Timestamp: 2025-06-03T03:15:29.849Z
Learning: In the Vortex project, logging functions (task(), info(), note(), pass(), fail(), warn()) are intentionally duplicated across all script files to make each script self-contained and independent, rather than sharing them through a common library. This design choice prioritizes script independence over reducing code duplication.

.vortex/tests/test.workflow.sh (4)

Learnt from: AlexSkrypnyk
PR: drevops/vortex#0
File: :0-0
Timestamp: 2025-05-29T12:15:32.188Z
Learning: Do not review files in .vortex/installer/tests/Fixtures/install directory as they are test fixtures.

Learnt from: AlexSkrypnyk
PR: #1697
File: .vortex/installer/tests/Fixtures/install/provision_database_lagoon/docs/onboarding.md:16-17
Timestamp: 2025-06-02T00:41:36.321Z
Learning: DO NOT EVER REVIEW FILES IN .vortex/installer/tests/Fixtures/ directory - these are test fixtures and should not be reviewed under any circumstances.

Learnt from: AlexSkrypnyk
PR: #1693
File: .vortex/installer/tests/Fixtures/install/hosting_acquia/docs/deployment.md:6-8
Timestamp: 2025-06-01T08:09:18.993Z
Learning: Do not review files in test fixture directories (e.g., files under paths containing /tests/Fixtures/ or similar test fixture patterns). These files are used for testing purposes and should remain as-is.

Learnt from: CR
PR: drevops/vortex#0
File: CLAUDE.md:0-0
Timestamp: 2025-07-18T15:00:28.327Z
Learning: Node.js dependencies are updated in theme directories via RenovateBot

.vortex/tests/composer.json (2)

Learnt from: CR
PR: drevops/vortex#0
File: CLAUDE.md:0-0
Timestamp: 2025-07-18T15:00:28.327Z
Learning: Composer dependencies are updated automatically with compatibility checks via RenovateBot

Learnt from: AlexSkrypnyk
PR: #1693
File: .vortex/installer/src/Prompts/Handlers/Internal.php:52-52
Timestamp: 2025-06-01T08:10:15.903Z
Learning: The File utility class in .vortex/installer/src/Utils/File.php extends AlexSkrypnyk\File\File, and methods like collapseRepeatedEmptyLines() are available from this external parent class dependency.

.vortex/tests/phpunit/Functional/FunctionalTestCase.php (1)

Learnt from: AlexSkrypnyk
PR: #1697
File: .vortex/installer/tests/Fixtures/install/provision_database_lagoon/docs/onboarding.md:16-17
Timestamp: 2025-06-02T00:41:36.321Z
Learning: DO NOT EVER REVIEW FILES IN .vortex/installer/tests/Fixtures/ directory - these are test fixtures and should not be reviewed under any circumstances.

.vortex/tests/bats/_helper.bash (1)

Learnt from: AlexSkrypnyk
PR: #1816
File: .docker/cli.dockerfile:72-76
Timestamp: 2025-07-23T01:16:30.963Z
Learning: In the Vortex project, unauthenticated Composer installs should be allowed, so GitHub token secrets should not be marked as required=true in Docker build mounts. The conditional check if [ -s /run/secrets/github_token ] is the preferred approach to allow builds to proceed without a token when needed.

.vortex/tests/phpunit/Traits/Steps/StepPrepareSutTrait.php (1)

Learnt from: AlexSkrypnyk
PR: drevops/vortex#0
File: :0-0
Timestamp: 2025-05-29T12:15:32.188Z
Learning: Do not review files in .vortex/installer/tests/Fixtures/install directory as they are test fixtures.

.ahoy.yml (1)

Learnt from: CR
PR: drevops/vortex#0
File: CLAUDE.md:0-0
Timestamp: 2025-07-18T15:00:28.327Z
Learning: Applies to tests/behat/**/*.feature : All Behat feature files must use the standard user story format: 'As a [user type]\nI want to [action]\nSo that [benefit]'

⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (13)
  • GitHub Check: build (1)
  • GitHub Check: build (0)
  • GitHub Check: vortex-test-installer (8.3)
  • GitHub Check: vortex-test-installer (8.4)
  • GitHub Check: vortex-test-installer (8.2)
  • GitHub Check: vortex-test-deployment (1)
  • GitHub Check: vortex-test-workflow (3)
  • GitHub Check: vortex-test-deployment (0)
  • GitHub Check: vortex-test-workflow (2)
  • GitHub Check: vortex-test-workflow (1)
  • GitHub Check: vortex-test-workflow (0)
  • GitHub Check: vortex-test-common
  • GitHub Check: vortex-test-docs
🔇 Additional comments (21)
.ahoy.yml (9)

22-22: Good use of confirmation for destructive build operation.

The confirmation prompt appropriately warns users about the destructive nature of the build command (removing containers, build files, and database) and uses proper exit handling.


64-64: Confirmation added to prevent accidental database removal.

Good safety measure for the down command which removes databases and volumes.


135-135: Appropriate confirmation for database replacement.

The warning message clearly communicates that the current database will be replaced.


145-147: Provision command now properly protected with confirmation.

The confirmation prevents accidental database removal, which aligns with the PR objective of adding confirmation to ahoy provision.


164-167: Reset command improved with confirmation and cleaner structure.

The confirmation protects against accidental removal of containers and build files. The command structure is also improved by breaking the chained commands into separate lines for better readability.


264-264: Deployment confirmation helps prevent accidental manual deployments.

The detailed warning message appropriately discourages manual deployment while still allowing it when intentional.


215-215: Simplified lint-tests command structure.

The command was consolidated from multi-line to single-line format without changing functionality.


122-122: Minor correction in login command usage text.

Fixed the usage description to properly describe generating a login link.


241-241: Corrected PHPUnit test command descriptions.

The usage descriptions now properly specify "PHPUnit" instead of just "unit", "kernel", and "functional" tests, providing clearer context.

Also applies to: 245-245, 249-249

.github/workflows/vortex-test-common.yml (3)

93-94: Added debug environment variable for consistent test verbosity control.

The TEST_VORTEX_DEBUG variable enables debug output control in the common test job, aligning with the environment variable changes in the test suite.


162-163: Debug variable added to workflow test job.

Consistent with the debug environment variable pattern across all test jobs.


239-240: Debug variable added to deployment test job.

Completes the consistent debug variable pattern across all three test job types.

.vortex/tests/composer.json (1)

31-32: PSR-4 autoload order change is cosmetic.

Swapping the order of namespace mappings doesn't affect functionality.

.vortex/tests/phpunit/Functional/FunctionalTestCase.php (1)

50-50: Environment variable updated for consistent debug naming.

The change from TEST_VORTEX_VERBOSE to TEST_VORTEX_DEBUG aligns with the debug variable naming used in the GitHub workflow and provides consistent verbosity control across the test suite.

.vortex/tests/test.workflow.sh (1)

28-29: Suppressed dependency installation output for cleaner test logs.

The output redirection reduces console verbosity during test setup while preserving the conditional installation logic. This aligns with the broader test output control improvements in this PR.

.vortex/tests/phpunit/Traits/LoggerTrait.php (3)

21-21: LGTM: Consistent newline handling for step boundaries.

The explicit newline write to stderr improves the visual separation of test step boundaries in the output.


29-29: LGTM: Consistent newline handling for step boundaries.

The explicit newline write to stderr improves the visual separation of test step boundaries in the output.


33-33: LGTM: Direct stderr output for substeps with consistent formatting.

The change to use fwrite(STDERR, ...) directly provides better control over substep output formatting and ensures consistent indentation with the --> prefix.

.vortex/tests/bats/_helper.bash (1)

1427-1427: LGTM: Pattern adjustment aligns with .ahoy.yml format changes.

The removal of the cmd: prefix in the sed pattern correctly reflects the updated command structure in .ahoy.yml after the confirmation mechanism was added.

.vortex/tests/phpunit/Traits/Steps/StepPrepareSutTrait.php (2)

105-109: LGTM: Assertion pattern updated to match new .ahoy.yml format.

The removal of the cmd: prefix in the assertion correctly reflects the updated command structure in .ahoy.yml after the confirmation mechanism changes.


111-114: LGTM: String replacement pattern updated consistently.

The File::replaceContent call correctly removes the cmd: prefix from both the search pattern and replacement string, maintaining consistency with the .ahoy.yml format changes.

@github-actions github-actions bot temporarily deployed to commit July 26, 2025 03:56 Inactive
Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

📜 Review details

Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between ac5cbe6 and 6280853.

📒 Files selected for processing (1)
  • .vortex/tests/bats/_helper.bash (1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (13)
  • GitHub Check: build (1)
  • GitHub Check: build (0)
  • GitHub Check: vortex-test-deployment (1)
  • GitHub Check: vortex-test-deployment (0)
  • GitHub Check: vortex-test-workflow (3)
  • GitHub Check: vortex-test-workflow (2)
  • GitHub Check: vortex-test-workflow (1)
  • GitHub Check: vortex-test-workflow (0)
  • GitHub Check: vortex-test-common
  • GitHub Check: vortex-test-installer (8.4)
  • GitHub Check: vortex-test-installer (8.2)
  • GitHub Check: vortex-test-installer (8.3)
  • GitHub Check: vortex-test-docs

@github-actions github-actions bot temporarily deployed to commit July 26, 2025 04:00 Inactive
Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

♻️ Duplicate comments (1)
.vortex/tests/bats/_helper.bash (1)

1427-1427: Sed pattern remains overly rigid despite previous feedback

The sed substitution pattern still hardcodes exactly six leading spaces, making it fragile to indentation changes in .ahoy.yml. This is the same issue raised in the previous review that suggested using ^[[:space:]]* for flexible whitespace matching.

The pattern should be updated to handle any amount of leading whitespace:

-  sed "${sed_opts[@]}" 's|      ahoy cli ./scripts/vortex/provision.sh|      if [ -f .data/db.sql ]; then docker compose exec cli mkdir -p .data; docker compose cp -L .data/db.sql cli:/app/.data/db.sql; fi; ahoy cli \.\/scripts\/vortex\/provision\.sh|g' .ahoy.yml
+  sed "${sed_opts[@]}" 's|^[[:space:]]*ahoy cli[[:space:]]./scripts/vortex/provision\.sh|      if [ -f .data/db.sql ]; then docker compose exec cli mkdir -p .data; docker compose cp -L .data/db.sql cli:/app/.data/db.sql; fi; ahoy cli ./scripts/vortex/provision.sh|g' .ahoy.yml
📜 Review details

Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 6280853 and 83a1a84.

📒 Files selected for processing (2)
  • .vortex/tests/bats/_helper.bash (2 hunks)
  • .vortex/tests/phpunit/Traits/Steps/StepPrepareSutTrait.php (1 hunks)
🧰 Additional context used
🧠 Learnings (2)
.vortex/tests/phpunit/Traits/Steps/StepPrepareSutTrait.php (1)

Learnt from: AlexSkrypnyk
PR: drevops/vortex#0
File: :0-0
Timestamp: 2025-05-29T12:15:32.188Z
Learning: Do not review files in .vortex/installer/tests/Fixtures/install directory as they are test fixtures.

.vortex/tests/bats/_helper.bash (2)

Learnt from: AlexSkrypnyk
PR: drevops/vortex#0
File: :0-0
Timestamp: 2025-05-29T12:15:32.188Z
Learning: Do not review files in .vortex/installer/tests/Fixtures/install directory as they are test fixtures.

Learnt from: AlexSkrypnyk
PR: #1816
File: .docker/cli.dockerfile:72-76
Timestamp: 2025-07-23T01:16:30.963Z
Learning: In the Vortex project, unauthenticated Composer installs should be allowed, so GitHub token secrets should not be marked as required=true in Docker build mounts. The conditional check if [ -s /run/secrets/github_token ] is the preferred approach to allow builds to proceed without a token when needed.

⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (13)
  • GitHub Check: build (0)
  • GitHub Check: build (1)
  • GitHub Check: vortex-test-workflow (3)
  • GitHub Check: vortex-test-workflow (2)
  • GitHub Check: vortex-test-workflow (1)
  • GitHub Check: vortex-test-workflow (0)
  • GitHub Check: vortex-test-deployment (1)
  • GitHub Check: vortex-test-deployment (0)
  • GitHub Check: vortex-test-common
  • GitHub Check: vortex-test-installer (8.4)
  • GitHub Check: vortex-test-installer (8.3)
  • GitHub Check: vortex-test-installer (8.2)
  • GitHub Check: vortex-test-docs
🔇 Additional comments (3)
.vortex/tests/bats/_helper.bash (1)

32-34: LGTM - Conditional platform setting commented out appropriately

The conditional ARM architecture platform setting is appropriately commented out and marked for code coverage exclusion. This change appears intentional and maintains the existing logic structure while disabling the automatic platform detection.

.vortex/tests/phpunit/Traits/Steps/StepPrepareSutTrait.php (2)

105-109: Good adjustment for new .ahoy.yml command structure

The removal of the cmd: prefix from the assertion aligns well with the new multi-line command structure in .ahoy.yml. This change ensures the test continues to work with the updated provision command format.


111-116: Excellent documentation of replacement logic

The added comments clearly explain the purpose of the replacement and the important caveat about the provision script potentially appearing in multiple sections. This documentation will help future maintainers understand the specific targeting requirement.

Comment on lines 117 to 121
File::replaceContent('.ahoy.yml',
'cmd: ahoy cli ./scripts/vortex/provision.sh',
'cmd: if [ -f .data/db.sql ]; then docker compose exec cli mkdir -p .data; docker compose cp -L .data/db.sql cli:/app/.data/db.sql; fi; ahoy cli ./scripts/vortex/provision.sh',
' ahoy cli ./scripts/vortex/provision.sh',
' if [ -f .data/db.sql ]; then docker compose exec cli mkdir -p .data; docker compose cp -L .data/db.sql cli:/app/.data/db.sql; fi; ahoy cli ./scripts/vortex/provision.sh',
);
}
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick (assertive)

Replacement logic is sound but uses hardcoded indentation

The replacement command structure correctly handles the new confirmation-based provision workflow. However, the hardcoded 6-space indentation (' ahoy cli ./scripts/vortex/provision.sh') makes this fragile to indentation changes in .ahoy.yml.

Consider using a more flexible pattern that matches any leading whitespace to make the code more maintainable:

-        '      ahoy cli ./scripts/vortex/provision.sh',
+        '/^[[:space:]]*ahoy cli[[:space:]]\.\/scripts\/vortex\/provision\.sh/',

This would make the replacement more resilient to formatting changes while maintaining the precise targeting mentioned in the comments.

Committable suggestion skipped: line range outside the PR's diff.

🤖 Prompt for AI Agents
In .vortex/tests/phpunit/Traits/Steps/StepPrepareSutTrait.php around lines 117
to 121, the replacement uses a hardcoded 6-space indentation which makes it
fragile to changes in the .ahoy.yml file's formatting. Modify the replacement
logic to match any leading whitespace before the command instead of fixed
spaces, using a regex pattern that captures all leading whitespace and replaces
the command accordingly. This will make the replacement more flexible and
maintainable against indentation changes.

@AlexSkrypnyk AlexSkrypnyk force-pushed the feature/add-confirm-to-ahoy-provision branch from 83a1a84 to 0eca68e Compare July 26, 2025 04:16
@github-actions github-actions bot temporarily deployed to commit July 26, 2025 04:18 Inactive
Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

♻️ Duplicate comments (1)
.ahoy.yml (1)

295-307: Environment-variable bypass still unvalidated – destructive commands can run unintentionally

The else branch trusts any preset AHOY_CONFIRM_RESPONSE value and proceeds, contradicting the earlier doc-comment (“will proceed only if the user types y or true”).
export AHOY_CONFIRM_RESPONSE=n ahoy provision will still wipe the database.

The same issue was raised in a previous review and is still unresolved.
Harden the check by normalising/validating the preset value and aborting on anything but an affirmative answer.

-else
-  if [ "${AHOY_CONFIRM_WAIT_SKIP}" != "1" ]; then
-    echo ">> $1 [y/N] ${AHOY_CONFIRM_RESPONSE}"
-    echo "Waiting for 3 seconds... Press Ctrl+C to cancel."
-    sleep 3
-  fi
-fi
+else
+  _resp=$(printf '%s' "${AHOY_CONFIRM_RESPONSE}" | tr '[:upper:]' '[:lower:]')
+  case "${_resp}" in
+    y|yes|true)
+      if [ "${AHOY_CONFIRM_WAIT_SKIP}" != "1" ]; then
+        echo ">> $1 [y/N] ${AHOY_CONFIRM_RESPONSE}"
+        echo "Waiting for 3 seconds... Press Ctrl+C to cancel."
+        sleep 3
+      fi
+      ;;
+    *)
+      echo "The operation was canceled."
+      exit 1
+      ;;
+  esac
+fi
📜 Review details

Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 83a1a84 and 0eca68e.

⛔ Files ignored due to path filters (7)
  • .vortex/installer/tests/Fixtures/install/_baseline/.ahoy.yml is excluded by !.vortex/installer/tests/Fixtures/**
  • .vortex/installer/tests/Fixtures/install/provision_profile/.ahoy.yml is excluded by !.vortex/installer/tests/Fixtures/**
  • .vortex/installer/tests/Fixtures/install/services_no_solr/.ahoy.yml is excluded by !.vortex/installer/tests/Fixtures/**
  • .vortex/installer/tests/Fixtures/install/services_no_valkey/.ahoy.yml is excluded by !.vortex/installer/tests/Fixtures/**
  • .vortex/installer/tests/Fixtures/install/services_none/.ahoy.yml is excluded by !.vortex/installer/tests/Fixtures/**
  • .vortex/installer/tests/Fixtures/install/theme_absent/.ahoy.yml is excluded by !.vortex/installer/tests/Fixtures/**
  • .vortex/installer/tests/Fixtures/install/theme_absent/web/themes/custom/star_wars/-yarn.lock is excluded by !**/*.lock, !.vortex/installer/tests/Fixtures/**
📒 Files selected for processing (7)
  • .ahoy.yml (10 hunks)
  • .github/workflows/vortex-test-common.yml (3 hunks)
  • .vortex/tests/bats/_helper.bash (1 hunks)
  • .vortex/tests/composer.json (2 hunks)
  • .vortex/tests/phpunit/Functional/FunctionalTestCase.php (1 hunks)
  • .vortex/tests/phpunit/Traits/Steps/StepPrepareSutTrait.php (1 hunks)
  • .vortex/tests/test.workflow.sh (1 hunks)
🧰 Additional context used
🧠 Learnings (6)
.vortex/tests/test.workflow.sh (5)

Learnt from: AlexSkrypnyk
PR: drevops/vortex#0
File: :0-0
Timestamp: 2025-05-29T12:15:32.188Z
Learning: Do not review files in .vortex/installer/tests/Fixtures/install directory as they are test fixtures.

Learnt from: AlexSkrypnyk
PR: #1714
File: scripts/vortex/doctor.sh:69-70
Timestamp: 2025-06-03T03:15:29.849Z
Learning: In the Vortex project, logging functions (task(), info(), note(), pass(), fail(), warn()) are intentionally duplicated across all script files to make each script self-contained and independent, rather than sharing them through a common library. This design choice prioritizes script independence over reducing code duplication.

Learnt from: AlexSkrypnyk
PR: #1714
File: scripts/vortex/doctor.sh:69-70
Timestamp: 2025-06-03T03:15:29.849Z
Learning: In the Vortex project, logging functions (task(), info(), note(), pass(), fail(), warn()) are intentionally duplicated across all script files to make each script self-contained and independent, rather than sharing them through a common library. This design choice prioritizes script independence over reducing code duplication.

Learnt from: AlexSkrypnyk
PR: #1697
File: .vortex/installer/tests/Fixtures/install/provision_database_lagoon/docs/onboarding.md:16-17
Timestamp: 2025-06-02T00:41:36.321Z
Learning: DO NOT EVER REVIEW FILES IN .vortex/installer/tests/Fixtures/ directory - these are test fixtures and should not be reviewed under any circumstances.

Learnt from: CR
PR: drevops/vortex#0
File: CLAUDE.md:0-0
Timestamp: 2025-07-18T15:00:28.327Z
Learning: Node.js dependencies are updated in theme directories via RenovateBot

.github/workflows/vortex-test-common.yml (2)

Learnt from: AlexSkrypnyk
PR: #1714
File: scripts/vortex/doctor.sh:69-70
Timestamp: 2025-06-03T03:15:29.849Z
Learning: In the Vortex project, logging functions (task(), info(), note(), pass(), fail(), warn()) are intentionally duplicated across all script files to make each script self-contained and independent, rather than sharing them through a common library. This design choice prioritizes script independence over reducing code duplication.

Learnt from: AlexSkrypnyk
PR: #1714
File: scripts/vortex/doctor.sh:69-70
Timestamp: 2025-06-03T03:15:29.849Z
Learning: In the Vortex project, logging functions (task(), info(), note(), pass(), fail(), warn()) are intentionally duplicated across all script files to make each script self-contained and independent, rather than sharing them through a common library. This design choice prioritizes script independence over reducing code duplication.

.vortex/tests/phpunit/Functional/FunctionalTestCase.php (1)

Learnt from: AlexSkrypnyk
PR: #1697
File: .vortex/installer/tests/Fixtures/install/provision_database_lagoon/docs/onboarding.md:16-17
Timestamp: 2025-06-02T00:41:36.321Z
Learning: DO NOT EVER REVIEW FILES IN .vortex/installer/tests/Fixtures/ directory - these are test fixtures and should not be reviewed under any circumstances.

.vortex/tests/composer.json (2)

Learnt from: CR
PR: drevops/vortex#0
File: CLAUDE.md:0-0
Timestamp: 2025-07-18T15:00:28.327Z
Learning: Composer dependencies are updated automatically with compatibility checks via RenovateBot

Learnt from: AlexSkrypnyk
PR: #1816
File: .docker/cli.dockerfile:72-76
Timestamp: 2025-07-23T01:16:30.963Z
Learning: In the Vortex project, unauthenticated Composer installs should be allowed, so GitHub token secrets should not be marked as required=true in Docker build mounts. The conditional check if [ -s /run/secrets/github_token ] is the preferred approach to allow builds to proceed without a token when needed.

.vortex/tests/bats/_helper.bash (3)

Learnt from: AlexSkrypnyk
PR: drevops/vortex#0
File: :0-0
Timestamp: 2025-05-29T12:15:32.188Z
Learning: Do not review files in .vortex/installer/tests/Fixtures/install directory as they are test fixtures.

Learnt from: AlexSkrypnyk
PR: #1697
File: .vortex/installer/tests/Fixtures/install/provision_database_lagoon/docs/onboarding.md:16-17
Timestamp: 2025-06-02T00:41:36.321Z
Learning: DO NOT EVER REVIEW FILES IN .vortex/installer/tests/Fixtures/ directory - these are test fixtures and should not be reviewed under any circumstances.

Learnt from: AlexSkrypnyk
PR: #1693
File: .vortex/installer/tests/Fixtures/install/hosting_acquia/docs/deployment.md:6-8
Timestamp: 2025-06-01T08:09:18.993Z
Learning: Do not review files in test fixture directories (e.g., files under paths containing /tests/Fixtures/ or similar test fixture patterns). These files are used for testing purposes and should remain as-is.

.ahoy.yml (1)

Learnt from: CR
PR: drevops/vortex#0
File: CLAUDE.md:0-0
Timestamp: 2025-07-18T15:00:28.327Z
Learning: Applies to tests/behat/**/*.feature : All Behat feature files must use the standard user story format: 'As a [user type]\nI want to [action]\nSo that [benefit]'

⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (13)
  • GitHub Check: build (0)
  • GitHub Check: build (1)
  • GitHub Check: vortex-test-installer (8.3)
  • GitHub Check: vortex-test-installer (8.4)
  • GitHub Check: vortex-test-installer (8.2)
  • GitHub Check: vortex-test-deployment (1)
  • GitHub Check: vortex-test-workflow (3)
  • GitHub Check: vortex-test-workflow (2)
  • GitHub Check: vortex-test-common
  • GitHub Check: vortex-test-deployment (0)
  • GitHub Check: vortex-test-workflow (0)
  • GitHub Check: vortex-test-workflow (1)
  • GitHub Check: vortex-test-docs
🔇 Additional comments (7)
.github/workflows/vortex-test-common.yml (1)

62-66: Verify pinned Node.js version exists

actions/setup-node will fail if the requested version (22.17.1) is not yet published.
Double-check the version string or switch to an LTS version to keep CI green.

Also applies to: 144-147, 209-211

.vortex/tests/phpunit/Functional/FunctionalTestCase.php (1)

50-52: LGTM – env-variable switch correctly updated

The verbosity flag now honours TEST_VORTEX_DEBUG; implementation is straightforward and consistent with workflow changes.

.vortex/tests/composer.json (1)

31-33: Structure corrected and timeout added – looks good

Nested config issue is gone and process-timeout is now at the right level.

Also applies to: 41-41

.vortex/tests/bats/_helper.bash (1)

1427-1427: Code change correctly adapts to new .ahoy.yml format.

The sed substitution pattern has been appropriately updated to match the new provision command structure without the cmd: prefix. The replacement logic correctly handles the unmounted volumes scenario by conditionally copying the database file before executing the provision script.

.vortex/tests/phpunit/Traits/Steps/StepPrepareSutTrait.php (3)

106-106: Assertion correctly updated for new .ahoy.yml format.

The file content assertion has been appropriately updated to match the provision command without the cmd: prefix, aligning with the new command structure.


111-116: Comments clearly explain the targeted replacement logic.

The updated comments provide good context about why the replacement targets specifically the provision section and the challenges of handling multiple occurrences of the provision script call.


118-119: Replacement logic correctly handles unmounted volumes scenario.

The file replacement correctly targets the indented provision command and adds appropriate conditional logic to copy database files when volumes are not mounted. This maintains consistency with the BATS helper implementation.

Comment on lines 295 to +300
if [ -z "${AHOY_CONFIRM_RESPONSE}" ]; then
read -r -p ">> $1 [y/N] " AHOY_CONFIRM_RESPONSE
[ "${AHOY_CONFIRM_RESPONSE}" = "y" ] || [ "${AHOY_CONFIRM_RESPONSE}" = true ] || ( echo "The operation was canceled." && exit 1 )
if [ "${AHOY_CONFIRM_RESPONSE}" != "y" ] && [ "${AHOY_CONFIRM_RESPONSE}" != "true" ]; then
echo "The operation was canceled."
exit 1
fi
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick (assertive)

Make interactive check case-insensitive & accept common variants

Requiring exactly y or true is unnecessarily strict—users tend to type Y, yes, Yes, etc.
Convert the input to lowercase and match y|yes|true to improve UX.

🤖 Prompt for AI Agents
In the .ahoy.yml file around lines 295 to 300, the interactive confirmation
check only accepts lowercase 'y' or 'true', which is too strict. Modify the
script to convert the user input to lowercase before the comparison, then check
if it matches 'y', 'yes', or 'true' to allow common variants and improve user
experience.

Comment on lines +28 to 30
[ ! -d "${TEST_DIR}/node_modules" ] && echo " > Install test Node dependencies." && yarn --cwd="${TEST_DIR}" install --frozen-lockfile >/dev/null 2>&1
[ ! -d "${TEST_DIR}/vendor" ] && echo " > Install test PHP dependencies." && composer --working-dir="${TEST_DIR}" install --no-interaction --no-progress --optimize-autoloader >/dev/null 2>&1

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick (assertive)

Consider keeping dependency install output under debug flag

Swallowing all yarn/composer output can hide useful failure clues. Redirect only when TEST_VORTEX_DEBUG is not set, e.g.:

-... install --frozen-lockfile >/dev/null 2>&1
+... install --frozen-lockfile ${TEST_VORTEX_DEBUG:+} >/dev/null 2>&1

Committable suggestion skipped: line range outside the PR's diff.

🤖 Prompt for AI Agents
In .vortex/tests/test.workflow.sh around lines 28 to 30, the current code
redirects all output from yarn and composer installs to /dev/null, hiding useful
error messages. Modify the script to conditionally redirect output only if the
environment variable TEST_VORTEX_DEBUG is not set, so that when debugging is
enabled, the full output is visible. Implement this by checking
TEST_VORTEX_DEBUG before deciding whether to redirect output.

@AlexSkrypnyk AlexSkrypnyk merged commit d371c7d into develop Jul 26, 2025
22 of 25 checks passed
@AlexSkrypnyk AlexSkrypnyk deleted the feature/add-confirm-to-ahoy-provision branch July 26, 2025 04:22
@github-project-automation github-project-automation bot moved this from BACKLOG to Release queue in Vortex Jul 26, 2025
@AlexSkrypnyk AlexSkrypnyk added this to the 25.7.0 milestone Jul 26, 2025
@AlexSkrypnyk AlexSkrypnyk moved this from Release queue to Released in 25.7.0 in Vortex Jul 26, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

2 participants