filters plugin uses msg.frm.room which does not exist for DMs on Zulip

Open Beginner friendly
#407 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
62/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Stale
Tech stack
python
Domain
backend

Research direction

Start in corobo/utils/filters.py at line 21 and trace how _process_command_filters in errbot/core.py passes direct messages into the filter. Check the ZulipPerson message shape and existing room-filter behavior. Done means direct messages no longer raise AttributeError while room-based filtering continues to work.

Written by the indexing model from the issue text.

Description

backend/zulip bug

7dcc1e07 introduces filters. On Zulip, in direct messages, this causes

Traceback (most recent call last):
  File "/.../errbot/errbot/core.py", line 345, in _process_command_filters
    msg, cmd, args = cmd_filter(msg, cmd, args, dry_run)
  File "/.../corobo/utils/filters.py", line 21, in filters
    if cmd in commands and msg.frm.room.uri == room:
AttributeError: 'ZulipPerson' object has no attribute 'room'
Dominant language
Python
Stars
67
Forks
98
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from coala/corobo

All issues in coala/corobo

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.