You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
SPEL: no viable alternative at input '#{' [JAVA_SPEL_EXPRESSION_SYNTAX] #1353
You are seeing an error because we added syntax validation for SPEL expressions. This error doesn't affect the compilation so this error is just for information purposes. STS shows error because it expects the SPEL expression not to have #{ prefix and } suffix. It expects SPEL without prefix and suffix: @ConditionalOnExpression("${some.property.delay-seconds:0} > 0")
Activity
BoykoAlex commentedon Sep 13, 2024
You can disable SPEL validations via settings:

You are seeing an error because we added syntax validation for SPEL expressions. This error doesn't affect the compilation so this error is just for information purposes. STS shows error because it expects the SPEL expression not to have
#{prefix and}suffix. It expects SPEL without prefix and suffix:@ConditionalOnExpression("${some.property.delay-seconds:0} > 0")martinlippert commentedon Sep 13, 2024
Probably something we need to support as well for the validation
BoykoAlex commentedon Sep 13, 2024
The question is whether SPEL wrapped in
#{}in@ConditionalOnExpressionis a valid syntax. I'm not sure it is...syedyusufh commentedon Sep 13, 2024
@BoykoAlex I can confirm it is a valid expression as application with the mentioned
SPELworks dynamically as expectedBoykoAlex commentedon Sep 13, 2024
I think the reason for this might be the ability to nest SPEL expressions inside SPEL expressions (to be verified)
BoykoAlex commentedon Sep 15, 2024
Looks like Spring allows it either wrapped in
#{}or without and then it just automatically wraps it in#{}at runtime.Fixed with 80de787