Skip to content

Rename get_schema() (and helper functions) to schema() #263

@peterdesmet

Description

@peterdesmet

With #262 we plan to introduce a version(), a function that doesn't start with a verb. This is similar to some camtrapdp functions (version(), deployments(), etc.). The functions have the advantage that they can have an equivalent set function version()<-.

Frictionless currently has other verb-less functions, mainly resources() (and also example_package() and the private locale(), col_types(), ...).

For consistency, I think we then need:

version() # new
version()<- # new
resources()
schema() # currently not the case
create_schema() # creates a schema from a data frame, doesn't "get" it

The alternative is:

get_version() # new
set_version() # new
get_resources() # currently not the case
get_schema()
create_schema() # creates a schema from a data frame, doesn't "get" it

That alternative is less appealing to me. @PietrH @sannegovaert @damianooldoni thoughts?


If we implement this:

  • Rename get_schema() to schema()
  • Deprecate get_schema()
  • Rename private function get_resource() to resource()
  • Change description for GitHub issue label function:get

Metadata

Metadata

Assignees

No one assigned

    Labels

    function:accessorAccessor functions schema(), resource(), resource_names()

    Type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions