Repository navigation
Riddler: fix undefined CAPTCHA_DEFAULT_VALIDATION_* constant - #450
Merged
miromichalicka merged 1 commit intoOct 23, 2026
Merged
Conversation
riddler 2.0.2 still references the global CAPTCHA_DEFAULT_VALIDATION_* constants in riddler_captcha_validate(). captcha 1.17 only provides them as Drupal\captcha\Constants\CaptchaConstants, so every riddle answer submission fatals on dev. Backport the upstream fix from riddler 2.0.5 as a local patch; 2.0.5 itself declares core ^8.9 || ^9 and riddler 3.x needs captcha ^2. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
miromichalicka
deleted the
claude/riddler-captcha-constant-error-55a47f
branch
October 23, 2026 21:58
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Dev logs show a fatal error whenever a riddle CAPTCHA is submitted:
riddler 2.0.2 still uses the old global constants, but captcha 1.17 only defines them as
Drupal\captcha\Constants\CaptchaConstants.Fix
Add a local patch (
patches/riddler-captcha-constants.patch) that importsCaptchaConstantsand uses it in the twocaselabels. This is the same change upstream made in riddler 2.0.5.We can't just upgrade riddler: 2.0.3–2.0.5 declare core
^8.9 || ^9, and 3.x needs captcha^2. Upgrading to captcha 2.x and riddler 3.x would make the patch unnecessary; that's left for a separate change.composer.lock: only the content-hash changed (composer update --lock, no package changes).Testing
patch -p1) to a fresh riddler 2.0.2 tarballphp -lpasses on the patched file🤖 Generated with Claude Code