camunda / feel-scala

FEEL parser and interpreter written in Scala
https://camunda.github.io/feel-scala/
Apache License 2.0
123 stars 50 forks source link

fix: Invoke `context()` function with a list containing a custom context #858

Closed saig0 closed 4 months ago

saig0 commented 4 months ago

Description

The context() function expects a list argument with context entries that contain a key and a value. The function checks that the key value is a string. To support a custom context value, the value must be resolved via a value-mapper before checking the type. Otherwise, the value may not be a FEEL Val type but something else.

Related issues

closes #856

backport-action commented 4 months ago

Backport failed for 1.16, because it was unable to cherry-pick the commit(s).

Please cherry-pick the changes locally and resolve any conflicts.

git fetch origin 1.16
git worktree add -d .worktree/backport-858-to-1.16 origin/1.16
cd .worktree/backport-858-to-1.16
git switch --create backport-858-to-1.16
git cherry-pick -x 1f896e78b91c44750bb7543ee84739ee44a53d2f f3e737039f1a90fb5a8d270495733a3412bef099 2416531741a7ed592194b7b533fc05e49f155768 60346fe87269bb46432cd39e4ee8ff43a30ed525
backport-action commented 4 months ago

Backport failed for 1.17, because it was unable to cherry-pick the commit(s).

Please cherry-pick the changes locally and resolve any conflicts.

git fetch origin 1.17
git worktree add -d .worktree/backport-858-to-1.17 origin/1.17
cd .worktree/backport-858-to-1.17
git switch --create backport-858-to-1.17
git cherry-pick -x 1f896e78b91c44750bb7543ee84739ee44a53d2f f3e737039f1a90fb5a8d270495733a3412bef099 2416531741a7ed592194b7b533fc05e49f155768 60346fe87269bb46432cd39e4ee8ff43a30ed525
backport-action commented 4 months ago

Backport failed for 1.16, because it was unable to cherry-pick the commit(s).

Please cherry-pick the changes locally and resolve any conflicts.

git fetch origin 1.16
git worktree add -d .worktree/backport-858-to-1.16 origin/1.16
cd .worktree/backport-858-to-1.16
git switch --create backport-858-to-1.16
git cherry-pick -x 1f896e78b91c44750bb7543ee84739ee44a53d2f f3e737039f1a90fb5a8d270495733a3412bef099 2416531741a7ed592194b7b533fc05e49f155768 60346fe87269bb46432cd39e4ee8ff43a30ed525
backport-action commented 4 months ago

Backport failed for 1.17, because it was unable to cherry-pick the commit(s).

Please cherry-pick the changes locally and resolve any conflicts.

git fetch origin 1.17
git worktree add -d .worktree/backport-858-to-1.17 origin/1.17
cd .worktree/backport-858-to-1.17
git switch --create backport-858-to-1.17
git cherry-pick -x 1f896e78b91c44750bb7543ee84739ee44a53d2f f3e737039f1a90fb5a8d270495733a3412bef099 2416531741a7ed592194b7b533fc05e49f155768 60346fe87269bb46432cd39e4ee8ff43a30ed525