Skip to content

Error reporting for queries assembled with funsql macro #83

@xitology

Description

@xitology

For queries assembled with @funsql macro, error messages should print a "stacktrace" of nested definitions. For example:

@funsql take_earliest(; order_by = [datetime]) = begin
    partition(person_id, order_by = $order_by, name = by_person)
    filter(by_person.row_number() <= 1)
end

q = @funsql begin
    from(person)
    take_earliest()
end

The error message should look like this:

FunSQL.ReferenceError: cannot find `datetime` in
# take_earliest filename.jl:111
partition(person_id, order_by = $order_by, name = by_person)
# filename.jl:222
take_earliest()

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