Skip to content

suppress messages from read_package #121

Description

@PietrH

Description

read_package() is used in testthat tests within frictionless, where they are locally supressed for example:

p_local <- suppressMessages(read_package(p_path))

I also want to use frictionless::read_package() in some tests for a different package: etn. I'd like to propose adding an argument to the function to suppress messaging like:

Please make sure you have the right to access data from this Data Package
for your intended use.\nFollow applicable norms or requirements to credit
the dataset and its authors.

I imagine this argument could be something like:

silent = TRUE
silently = TRUE
supress_messages = TRUE
verbose = FALSE
show_messages = FALSE

I'll have a go at making this change myself, and adding an appropriate test + changing the tests to use the new argument instead of local versions of the read_package() function.

Proposed changes

  • add argument to read_package()
  • add coverage for new argument in test-read_package()
  • change existing tests to make use of new argument

Scope

I'm not proposing to suppress the assertions/checks made by asserthat, just the message() call (link to line)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions