Skip to content
This repository was archived by the owner on Oct 13, 2025. It is now read-only.
This repository was archived by the owner on Oct 13, 2025. It is now read-only.

stream.delete_all_rules() is broken. #21

@wraithsec

Description

@wraithsec

Found the issue to be in this line of delete_all_rules():

    def delete_all_rules(self) -> json:
        """Deletes all your rules automatically"""
        try:
--->            rules = self.get_rules().json()
            ids = list(map(lambda rule: rule["id"], rules["data"]))
            return self.delete_rule({"delete": {"ids": ids}})
        except Exception as e:
            pass

No need for .json() as self.get_rules() already returns it as such.

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