File tree Expand file tree Collapse file tree 4 files changed +12
-13
lines changed
Expand file tree Collapse file tree 4 files changed +12
-13
lines changed Original file line number Diff line number Diff line change @@ -83,13 +83,13 @@ async def observe_events(
8383 if options .lower_bound is not None :
8484 # For inclusive, include events with ID >= lower bound
8585 if (
86- options .lower_bound .type == 'inclusive' and # pylint: disable=R2004
86+ options .lower_bound .type == 'inclusive' and # pylint: disable=R2004
8787 int (event_id ) < int (options .lower_bound .id )
8888 ):
8989 continue
9090 # For exclusive, include events with ID > lower bound
9191 if (
92- options .lower_bound .type == 'exclusive' and # pylint: disable=R2004
92+ options .lower_bound .type == 'exclusive' and # pylint: disable=R2004
9393 int (event_id ) <= int (options .lower_bound .id )
9494 ):
9595 continue
Original file line number Diff line number Diff line change 1010@dataclass
1111class ObserveEventsOptions :
1212 recursive : bool
13- lower_bound : LowerBound | None = None
13+ lower_bound : LowerBound | None = None
1414 from_latest_event : ObserveFromLatestEvent | None = None
1515
1616 def validate (self ) -> None :
Original file line number Diff line number Diff line change @@ -79,27 +79,27 @@ async def read_events(
7979 if options .lower_bound is not None :
8080 # For inclusive, include events with ID >= lower bound
8181 if (
82- options .lower_bound .type == 'inclusive' and # pylint: disable=R2004
82+ options .lower_bound .type == 'inclusive' and # pylint: disable=R2004
8383 int (event_id ) < int (options .lower_bound .id )
8484 ):
8585 continue
8686 # For exclusive, include events with ID > lower bound
8787 if (
88- options .lower_bound .type == 'exclusive' and # pylint: disable=R2004
88+ options .lower_bound .type == 'exclusive' and # pylint: disable=R2004
8989 int (event_id ) <= int (options .lower_bound .id )
9090 ):
9191 continue
9292
9393 if options .upper_bound is not None :
9494 # For inclusive, include events with ID <= upper bound
9595 if (
96- options .upper_bound .type == 'inclusive' and # pylint: disable=R2004
96+ options .upper_bound .type == 'inclusive' and # pylint: disable=R2004
9797 int (event_id ) > int (options .upper_bound .id )
9898 ):
9999 continue
100100 # For exclusive, include events with ID < upper bound
101101 if (
102- options .upper_bound .type == 'exclusive' and # pylint: disable=R2004
102+ options .upper_bound .type == 'exclusive' and # pylint: disable=R2004
103103 int (event_id ) >= int (options .upper_bound .id )
104104 ):
105105 continue
Original file line number Diff line number Diff line change @@ -9,13 +9,12 @@ class UpperBound:
99 type : str
1010
1111 def __post_init__ (self ):
12- if self .type not in {' inclusive' , ' exclusive' }:
12+ if self .type not in {" inclusive" , " exclusive" }:
1313 raise InvalidParameterError (
14- parameter_name = ' UpperBound' ,
15- reason = 'type must be either "inclusive" or "exclusive"'
14+ parameter_name = " UpperBound" ,
15+ reason = 'type must be either "inclusive" or "exclusive"' ,
1616 )
1717 if int (self .id ) < 0 :
1818 raise InvalidParameterError (
19- parameter_name = 'UpperBound' ,
20- reason = 'id must be non-negative'
21- )
19+ parameter_name = "UpperBound" , reason = "id must be non-negative"
20+ )
You can’t perform that action at this time.
0 commit comments