Skip to content

Create issue number 20#24

Merged
otis22 merged 1 commit intomainfrom
cursor/create-issue-number-20-gpt-5.1-codex-1f02
Dec 2, 2025
Merged

Create issue number 20#24
otis22 merged 1 commit intomainfrom
cursor/create-issue-number-20-gpt-5.1-codex-1f02

Conversation

@otis22
Copy link
Owner

@otis22 otis22 commented Dec 2, 2025

Add Xdebug version selection to Dockerfile to prevent incompatibility errors when building images with different PHP versions.


Open in Cursor Open in Web


Note

Adds conditional Xdebug version selection based on PHP major and refactors Dockerfile install steps for reliability.

  • Dockerfile (docker/Dockerfile):
    • Xdebug installation:
      • Determines PHP_MAJOR from VERSION and installs xdebug-3.1.6 for PHP < 8, otherwise xdebug.
      • Explicitly enables Xdebug via docker-php-ext-enable xdebug.
    • Build robustness/refactor:
      • Uses set -eux and consolidates apk commands with --no-cache.
      • Keeps linux-headers, ICU libs/dev, pcre-dev + ${PHPIZE_DEPS} during build; removes them after.
    • Extensions/Tools:
      • Unchanged: installs bcmath, intl, and Composer 2.

Written by Cursor Bugbot for commit 0861c1f. This will update automatically on new commits. Configure here.

Co-authored-by: vromanichev24 <vromanichev24@gmail.com>
@cursor
Copy link

cursor bot commented Dec 2, 2025

Cursor Agent can help with this pull request. Just @cursor in comments and I'll start working on changes in this branch.
Learn more about Cursor Agents

@coveralls
Copy link

coveralls commented Dec 2, 2025

Pull Request Test Coverage Report for Build 19872606544

Details

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 92.91%

Totals Coverage Status
Change from base Build 19871756010: 0.0%
Covered Lines: 249
Relevant Lines: 268

💛 - Coveralls

1 similar comment
@coveralls
Copy link

Pull Request Test Coverage Report for Build 19872606544

Details

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 92.91%

Totals Coverage Status
Change from base Build 19871756010: 0.0%
Covered Lines: 249
Relevant Lines: 268

💛 - Coveralls

@otis22 otis22 marked this pull request as ready for review December 2, 2025 20:33
@otis22 otis22 merged commit 4947abe into main Dec 2, 2025
1 of 13 checks passed
Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

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

This PR is being reviewed by Cursor Bugbot

Details

Your team is on the Bugbot Free tier. On this plan, Bugbot will review limited PRs each billing cycle for each member of your team.

To receive Bugbot reviews on all of your PRs, visit the Cursor dashboard to activate Pro and start your 14-day free trial.

apk --no-cache add icu-libs icu-data-full icu-dev; \
apk --no-cache add pcre-dev ${PHPIZE_DEPS}; \
PHP_MAJOR="${VERSION%%.*}"; \
if [ "${PHP_MAJOR}" -lt 8 ]; then \
Copy link

Choose a reason for hiding this comment

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

Bug: ARG variable not available inside RUN command

The VERSION ARG declared before FROM is not available in the RUN instruction. Docker ARG variables declared before FROM are only scoped to the FROM line itself and must be re-declared after FROM to be used in subsequent instructions. As a result, ${VERSION} will be empty, making PHP_MAJOR empty, and the comparison [ "${PHP_MAJOR}" -lt 8 ] will fail with an integer expression error. Adding ARG VERSION after the FROM line would make the variable available in the build stage.

Fix in Cursor Fix in Web

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants