Skip to content

Agent to agent messages can be addressed X in Y #89

@marvinirwin

Description

@marvinirwin

pattern = r"(?P<sender>[\w\s]+) said to (?P<recipient>[\w\s]+): [\"'](?P<message>.*)[\"']"

I've got messages which are addressed to "everyone in location", which breaks this regex, as it doesn't expect recipient to have whitespace in it. This causes the sender_name, recipient, content = re.findall(pattern, event.description)[0] to explode

Adding .* to the regex to allow the recipient to have spaces in it makes it work, though I'm not sure it wont break something else

With the .* added: pattern = r"(?P<sender>[\w\s]+) said to (?P<recipient>[\w\s]+.*): [\"'](?P<message>.*)[\"']"

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