Skip to content

Is should be changed to ==  #166

@cn-kali-team

Description

@cn-kali-team
  • I changed my data ID, and finally I couldn't ack it
    def _find_item_id(self, item, search=True):
        if item is None:
            return None
        elif isinstance(item, dict) and "pqid" in item:
            return item.get("pqid")
        elif search:
            for key, value in self._unack_cache.items():
                if value is item:
                    return key
            log.warning("Can't find item in unack cache.")
        elif isinstance(item, int) or (
            isinstance(item, str) and item.isnumeric()
        ):
            return int(item)
        return None
  • value is item

  • value == item

  • warning Can't find item in unack cache.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions