Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is should be changed to == #166

Open
cn-kali-team opened this issue Jun 9, 2021 · 0 comments
Open

Is should be changed to == #166

cn-kali-team opened this issue Jun 9, 2021 · 0 comments

Comments

@cn-kali-team
Copy link

  • 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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant