Pedro,
Thanks for the question and very clear reproducible example.
This was not entirely obvious, but the relevant items from the 1.1.0 release NEWS (see posts on
r-nimble.org or the complete set in inst/NEWS.md on our GitHub repo) are:
- `configureMCMC` will no longer assign samplers to data nodes, even if
the `nodes` argument includes data nodes (PR #1407).
- Add new argument `allowData` to the `addSampler` method of MCMC
configuration objects, with default value `FALSE`. When `TRUE`,
samplers can be assigned to operate on data nodes (PR #1407).
These changes were intended to provide better fences around data nodes to avoid accidental MCMC sampling if a user is manually changing an MCMC configuration. In your case, the nodes x_cont_miss[1, ] and x_cont_miss[2, ] are vector nodes (following dmnorm) each with one provided element and one missing element. A node is considered all data or all non-data, so these are considered data nodes, and even the missing elements are considered data. For example, model$isData("x_cont_miss[1, 1]") is TRUE. If you add "allowData=TRUE" when you call config$addSampler, it works.
Note that the block sampler you provide is not assigned because zmiss[3] and x_cont_miss[3,] are all sampled by a posterior predictive sampler. It shows the target as vmiss[3], and in its setup code finds dependencies and should in that way include x_cont_miss[3, ]. I think you are aware of this from following the second if() condition of your config modifications.
(Note also that a variable with multiple nodes can contain a mix of data and non-data nodes. For example, some x[i, ] could be data and some non-data, when each x[i, ] follows a dmnorm and thus is a separate node from x[j, ] for i != j. It's just that the elements of a non-scalar node aren't tracked as a mix of data and non-data.)
One could debate the nuances and use cases here, although I don't think it's a bug. I do think we should consider emitting a message when addSampler bails out because of not sampling data nodes. I'll file an issue on that.
HTH
Perry