Summary
In R code using the box module system, functions imported from other modules are called using $ accessor syntax — e.g., validation$validate_input(x). The call resolution pipeline does not resolve this pattern, so no CALLS edge is created between the calling function and validate_input. Call chains are silently truncated at module boundaries.
Expected behaviour
module$function() call syntax should be resolved to a CALLS edge where the target is the qualified name of the function in the source module, provided the source module can be identified from an IMPORTS edge (see companion issue on box::use() parsing).
Actual behaviour
No CALLS edge is created. trace_path on any function called via $ syntax shows zero callers, regardless of actual usage in the codebase.
Minimal example
# app/view/map_panel.R
box::use(
app/logic/validation[validate_input]
)
map_server <- function(id) {
shiny::moduleServer(id, function(input, output, session) {
result <- validation$validate_input(input$track) # not resolved
})
}
trace_path on validation$validate_input (or app/logic/validation::validate_input) returns no callers. map_server does not appear in any call chain originating from validate_input.
Context
This pattern is ubiquitous in Rhino applications and in any R code using box. It is distinct from the standard package::function() namespace syntax (which uses :: and may already be handled). The $ accessor is specific to box's imported-alias calling convention.
Both issues are related: resolving the call target in this issue depends on knowing what module the alias refers to, which requires IMPORTS edge support from the companion issue.
Version
0.6.0 (Windows amd64)
Summary
In R code using the
boxmodule system, functions imported from other modules are called using$accessor syntax — e.g.,validation$validate_input(x). The call resolution pipeline does not resolve this pattern, so no CALLS edge is created between the calling function andvalidate_input. Call chains are silently truncated at module boundaries.Expected behaviour
module$function()call syntax should be resolved to a CALLS edge where the target is the qualified name of the function in the source module, provided the source module can be identified from an IMPORTS edge (see companion issue onbox::use()parsing).Actual behaviour
No CALLS edge is created.
trace_pathon any function called via$syntax shows zero callers, regardless of actual usage in the codebase.Minimal example
trace_pathonvalidation$validate_input(orapp/logic/validation::validate_input) returns no callers.map_serverdoes not appear in any call chain originating fromvalidate_input.Context
This pattern is ubiquitous in Rhino applications and in any R code using
box. It is distinct from the standardpackage::function()namespace syntax (which uses::and may already be handled). The$accessor is specific tobox's imported-alias calling convention.Both issues are related: resolving the call target in this issue depends on knowing what module the alias refers to, which requires IMPORTS edge support from the companion issue.
Version
0.6.0 (Windows amd64)