Let $X$, $Y$ random variables on $ (Ω, \mathcal A, \mathbb P) $, $ \mathcal F ⊂ \mathcal A $ a sub-σ-algebra and $X$ measurable w.r.t. $\mathcal F$. Let $X$ take values in $(E, \mathcal E)$ and $Y$ values in $(E', \mathcal E')$, and consider a measurable map $ g: E \times E' → \mathbb R$ either nonnegative, or bounded, or such that $ g(X,Y) ∈ \mathcal L_1(\mathbb P)$.
I wonder whether it holds that \begin{equation} \mathbb E[g(X,Y) | \mathcal F] = \mathbb E[g(x,Y) | \mathcal F] \mid_{x = X} \tag{$*$}. \end{equation} If $Y$ happens to be independent from $\mathcal F$, this is indeed the case, as shown in this answer. What can we say without independence? Does it hold or is there a counterexample? If it does not hold in general, does it hold under some additional assumptions on $X$ and $Y$?
Edit: Here is a proof attempt using the 'standard machinery' (and where I think it meets an obstacle):
We will use the functional monotone class theorem. Let $ H $ the set of bounded measurable maps for which $(*)$ holds, which is a vector space containing the constants. For $A ∈ \mathcal E$, $ B ∈ \mathcal E'$ and $ g = I_{A \times B}$, it does indeed hold that \begin{align*} \mathbb E[g(X,Y) | \mathcal F] &= \mathbb E[I_A(X) I_B(Y) | \mathcal F] \\ &=I_A(X) \ E[I_B(Y) | \mathcal F] \\ &= \mathbb E[I_A(x) I_B(Y) | \mathcal F] \mid_{x =X} = \mathbb E[g(x,Y) | \mathcal F] \mid_{x =X}, \end{align*} so $H$ contains indicators of sets in $ \mathcal E \times \mathcal E'$, which is a $π$-system generating $\mathcal E \otimes \mathcal E'$. If we can show that $H$ is in addition closed under nonnegative monotone convergence, it follows that $H$ contains all bounded $\mathcal E \otimes \mathcal E'$ measurable functions and we are (mostly) done. So let $0 \leq g ∈ H$ and $(g_n) ⊂ H$ with $0 \leq g_n ↗ g$. Then \begin{align*} \mathbb E[g(X,Y) | \mathcal F] &\overset{a.s.}{=} \lim_{n → ∞} \mathbb E[g_n(X,Y) | \mathcal F] \\ &= \lim_{n → ∞} \mathbb E[g_n(x,Y) | \mathcal F]\mid_{x = X} \\ &\overset{(?)}{=} \lim_{n → ∞} \mathbb E[g(x,Y) | \mathcal F]\mid_{x = X}. \end{align*} I see the following issue with the last equality. Let $ G_n(ω,x) := \mathbb E[g_n(x,Y)| \mathcal F](ω)$, then from $g_n ↗ g$, $G_n(ω,x) → G(ω,x) =: E[g(x,Y)| \mathcal F](ω) $ almost surely, i.e. for all $ω ∈ N_x^c$ where $\mathbb P [N_x ] = 0$. But the exceptional set $N_x$ of those $ω$ where convergence fails to hold depends on $x$, so unless, say $E$ is countable, these sets may accumulate to prevent convergence on a set with positive measure.