SyntaxError | Unexpected Identifier issue after 3.3.7 version upgrade #6115
-
I'm running into an issue on a client site when I update them to 3.3.7 or newer. When saving pages in the CP, I'm seeing 'SyntaxError | Unexpected Identifier', and can't save the page — If I downgrade functionality returns to normal. No message in my logs, but If I turn on the debug bar I see:
...I'm guessing this is probably related. I have the following in use in my 'common.yaml' fieldset — am I missing something here?
No luck working it out so far... posting here in the hope someone recognises the issue 🥲 |
Beta Was this translation helpful? Give feedback.
Replies: 5 comments 2 replies
-
It may be caused by an addon. Can you post the results of |
Beta Was this translation helpful? Give feedback.
-
Which field is causing the issue? To determine, slowly take fields out of the blueprint and content and try saving. |
Beta Was this translation helpful? Give feedback.
-
Thank you both for your suggestions! Definitely wasn't an addon (disabled the few addons in place, which didn't resolve the issue). Ended up doing the slow but sure needle in a haystack process of taking fields out of the blueprint as Erin suggested... Seems like a button component within the page_builder is the culprit (this site is built on Peak, so it's pretty much the standard button component from Peak). I believe this line in the 'components__button.yaml' blueprint is causing the problem (If I remove it, the errors resolves):
No idea why this isn't working now, the show/hide conditional renders correctly in the CMS. Seems to be a regression? The flow to get here as follows: [MAIN CALL TO ACTION BLOCK/COMPONENT.yaml]
[BUTTONS COMPONENT components__buttons.yaml]
[BUTTON COMPONENT (EXCERPT OF SYNTAX ERROR) components__button.yaml]
|
Beta Was this translation helpful? Give feedback.
-
I can't replicate this in Peak and v3.3.12. However I do notice you renamed all the fieldsets. Maybe something odd slipped in there? I do notice the log error is coming from Bard though. Which isn't visible in the screenshot you shared. |
Beta Was this translation helpful? Give feedback.
-
Found the issue here through some further detective work. Had a a couple of fields with a handle that used a hyphen '-' I.e
Once I removed these to only use underscores '_', it was back to business. Seems like the syntax check on this was a recent introduction — thanks for your help everyone 👋 |
Beta Was this translation helpful? Give feedback.
Found the issue here through some further detective work. Had a a couple of fields with a handle that used a hyphen '-'
I.e
Once I removed these to only use underscores '_', it was back to business. Seems like the syntax check on this was a recent introduction — thanks for your help everyone 👋