-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Data/filter block standard example is no longer functional #172
Comments
Before my changes, at a985dc9, I see this: My changes silence the validation (will fix this) but the underlying problem was there before. Perhaps introduced by the changes in |
The filter is working well in the |
@DivadNojnarg, I have a replication problem. When I check out your branch Perhaps the errors are meaningful and the user inputs need to be tweaked? |
@nbenn @christophsax : shouldn't it be: stack <- new_stack(
data_block,
filter_block
)
serve_stack(stack) Calling filter_block <- function(data, ...) {
initialize_block(new_filter_block(data, ...), data)
} and we need this to initialise fields: initialize_block.transform_block <- function(x, data, ...) {
env <- list(data = data)
for (field in names(x)) {
x[[field]] <- initialize_field(x[[field]], env)
env <- c(env, set_names(list(value(x[[field]])), field))
}
x
} EDIT: I checked the codebase 4 months ago with one the first working version: https://github.com/blockr-org/blockr/tree/54ae5802b4986165fb9fdc91a86562b727add47f. The readme example also did not contain any call to Below is when I call Below is when I call This isn't due to the latest PRs. |
@DivadNojnarg @christophsax I was not precise when stating that this worked previously. My comparison was against the fix I had proposed in #161. With that I get for a stack initialized with the basic block constructors something that works: With branch stack1 <- new_stack(
new_data_block,
new_filter_block
)
serve_stack(stack1) Screen.Recording.2024-01-11.at.16.22.48.movTwo things:
The problem is caused in a change introduced with ad4b55c. The way this change was introduced has the following issue:
I will open a separate issue. I leave it up to you @christophsax if you want to investigate why my implementation would "self-heal" a not properly initialized field while yours does not. It might have to do with your choice of https://github.com/blockr-org/blockr/blob/008965264e9843ff43defe4692434d81decc46e4/R/server.R#L132 It is unclear to me whether we want |
Closing as 0.0.2 is functional |
Using latest main I have trouble running our standard example
The resulting app is no longer functional in that the column drop down for filter choices does not work. I suspect this is due to the recent changes in block server logic @christophsax.
The text was updated successfully, but these errors were encountered: