Skip to content

When using datashield.assign, no message is returned if trying to assign variables which don't exist #25

@timcadman

Description

@timcadman

How to reproduce

demo_url <- "https://armadillo-demo.molgenis.net/"
demo_token <- armadillo.get_token(demo_url)

builder <- DSI::newDSLoginBuilder()

  builder$append(
    server = "armadillo",
    url = demo_url,
    profile = "xenon",
    driver = "ArmadilloDriver",
    token = demo_token
  )
  
logindata <- builder$build()
conns <- DSI::datashield.login(logins = logindata, assign = F)

datashield.assign.table(conns, "testdata", "xenon-tests/survival/veteran", variables = c("doesnt_exist", "also_not_there"))

Expected behaviour

A warning is returned stating something like:
Warning: variables "doesnt_exist", "also_not_there", do not exist in table "veteran"

Actual behaviour

ds.colnames("testdata")
$armadillo character(0)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions