Fixed
Project:
CAPTCHA
Version:
2.0.5
Component:
Code
Priority:
Major
Category:
Task
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
22 Nov 2023 at 10:15 UTC
Updated:
2 Nov 2026 at 21:33 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
kuldeep_mehra27 commentedComment #3
kuldeep_mehra27 commentedTested on Drupal 10.1.6. Working as expected.
Comment #4
pbouchereau commentedNo, it doesn't.
See https://www.drupal.org/project/captcha/issues/3375618#comment-15333248
Comment #5
pbouchereau commentedOk. The title and description are broad.
The patch though is very specific and now that I've looked at it I understand why the issue was closed.
I still leave it open for visibility.
Comment #6
pbouchereau commentedWow... I really need some sleep.
I confused the "Working as expected" comment with the status.
Sorry for the noise on this issue.
I suppose it's ok to unassign @kuldeep_mehra27 ?
Comment #9
japerryDug into this a little, and the cause appears to be `image_captcha.settings:image_captcha_fonts` stores fonts as sha256 tokens of the font file path. If the path changes, the stored tokens no longer match.
The patch above gets around it with `reset()`, which only happens to return 'BUILTIN' because that is the first array entry. It also leaves the per-character directory rescan in place. I've taken a different approach in the new branch/MR:
Re-saving the fonts on the Image CAPTCHA settings page still restores your chosen fonts. #2985060: Moving the module in the file system breaks configured fonts deals with keeping the bundled font tokens stable when the module moves, so the config does not go stale in the first place.
Comment #12
japerry