Reviewed & tested by the community
Project:
Block Class
Version:
4.0.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
13 Dec 2024 at 15:33 UTC
Updated:
18 Jan 2026 at 15:01 UTC
Jump to comment: Most recent, Most recent file

Comments
Comment #3
bernardm28 commentedComment #4
bernardm28 commentedComment #5
ericpoir commentedI created a patch based on the work done in the following MR:
https://git.drupalcode.org/project/block_class/-/merge_requests/58
After applying these changes, it works for my on 4.0.0.
Comment #6
npcoder commentedI encountered the same error and have created a patch that could be helpful.
Comment #7
rajab natshahFacing the same issue.
Patch #6 is working
Thank you :)
Comment #8
rajab natshahComment #9
renatog commentedThanks everyone!
Adding this on plan for the next release
Comment #10
johncionci commentedPatch installed and working for me!
Comment #12
dydave commentedThank you very much for raising this issue.
Sorry for this late reply, but unfortunately I was unable to reproduce this with current version of Drupal Core, tested with:
Is this still issue still happening with more recent versions of the module and Drupal Core?
From what I have seen, the config variable
'block_classes_stored'is properly declared as a sequence of string and initialized as an empty array, so I can't seem to think of any reason the variable$block_classes_storedcould be a string...🤔In short: I am unable to reproduce this issue and from the look at the code think the problem should not occur again.
Could anyone please provide clear testing steps to follow, to reproduce the issue, if possible with more context, versions of module/core, etc... ?
Any additional information that could help us reproduce the problem would be greatly appreciated.
Additionally, since there has not been any comments on the issue for half a year, we could also perhaps assume the problem initially reported might have been resolved with some other changes (from other tickets) (?).
Lowering ticket priority back to Normal and switching status to Postponed (maintainer needs more info), for now, until the work expected in this ticket could be clarified.
Feel free to let us know if you would have any questions or concerns on any aspects of this comment or the module in general, we would surely be glad to help.
Thanks in advance!
Comment #13
alae.akalayFacing the same issue with TB Megamenu blocks (https://www.drupal.org/project/tb_megamenu) - after some debug I've found that the conversion is not straigthforward, so I added a check to decode the JSON string into an associative array.
Comment #16
ckhaliloHi
I have added a new MR handle Json and check if empty block_classes_stored.
Best Regards
Khalil
Comment #17
ckhaliloYou can find the patch here
Comment #18
rajab natshah