@@ -115,6 +115,7 @@ def __init__(self, **kwargs):
115115 self ._handle_error (error )
116116
117117 self ._handle_unknown_kwargs (unknown_kwargs )
118+ self .values_changed = True
118119
119120 def _handle_error (self , error ):
120121 """Handle exceptions raised by param assignment and add them as annotations.
@@ -179,18 +180,20 @@ def set_previous_tendency(self, prev_tendency):
179180 # If the tendency is the first tendency of a repeated tendency, it is linked to
180181 # the last tendency in the repeated tendency. In this case we can ignore this
181182 # error.
182- if self .prev_tendency .end > self .start and not self .is_first_repeated :
183- error_msg = (
184- f"The end of the previous tendency ({ self .prev_tendency .end } )\n is "
185- f"later than the start of the current tendency ({ self .start } ).\n "
186- )
187- self .annotations .add (self .line_number , error_msg )
188- elif self .prev_tendency .end < self .start :
189- error_msg = (
190- "Previous tendency ends before the start of the current tendency.\n "
191- "The values inbetween the tendencies will be linearly interpolated.\n "
192- )
193- self .annotations .add (self .line_number , error_msg , is_warning = True )
183+ if not np .isclose (self .prev_tendency .end , self .start ):
184+ if self .prev_tendency .end > self .start and not self .is_first_repeated :
185+ error_msg = (
186+ f"The end of the previous tendency ({ self .prev_tendency .end } )\n is "
187+ f"later than the start of the current tendency ({ self .start } ).\n "
188+ )
189+ self .annotations .add (self .line_number , error_msg )
190+ elif self .prev_tendency .end < self .start :
191+ error_msg = (
192+ "Previous tendency ends before the start of the current tendency.\n "
193+ "The values inbetween the tendencies will be linearly interpolated."
194+ "\n "
195+ )
196+ self .annotations .add (self .line_number , error_msg , is_warning = True )
194197
195198 self .param .trigger ("annotations" )
196199
0 commit comments