Skip to content

Rephrase exception message when unable to combine branches #12

@hampusboesenfunnel

Description

@hampusboesenfunnel

If the function main._combine_branches fails to combine branches, it raises a ValueError with this message:

Multiple branches dont know how to handle these, either

I think this message can be improved to better communicate the context in which the problem arises.

Suggestions

  • Include the selected method in the message
  • Include the branches that couldn't be processed in the message (this can potentially be quite long, but if at least the point(s) of branching can be communicated I think it would be quite helpful)
  • I don't quite understand what the "either" means in the context of this exception—maybe it can be rephrased or omitted?

What do you think about something like this?

Unable to combine branches with the selected method:
    method: None
    branches: {'a': {'A': 123}, 'b':[{'c':1},{'c':2}]}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions