Skip to content

Problem with slickR + shiny, when the xmlSVG-file becomes to large. #67

@RobertOpitz

Description

@RobertOpitz

Hi there!

I'm using slickR with shiny, and I'm happy that this package exists. Unfortunatly, I encountered a strange error, when the necessary xml-Files become large. I traced the error down to the function slick_div_chr. There, it is tested if the input x is a regular file using utils::file_test('-f', x) . Here, x is the (by slickR processed) xml-Input, which is in this case a long string. If that string is to long (>= 1e5 characters) the underlying function file.info throws an error: Error in file.info(x, extra_cols = FALSE) : file name conversion problem -- name too long?.

As I can see, if the xml-Input is short enough, and processed by functions as_svg_character and hash_encode_url, then utils::file_test('-f', x) will always return FALSE, indicating the function file_test is only necessary with certain inputs.

As the function file_test is for a if-statement, maybe this can be solved by adding and extra argument, checking if file_test is actually necessary?

Best regards!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions