Skip to content

Conversation

saarnold
Copy link
Contributor

The time method in replay returns the base_time (start time) of the stream instead of the time of the last sample. Either the documentation or the retuned value are wrong here.

Using the current_time fixes the issue for the plot2d widget.

@doudou
Copy link
Member

doudou commented Mar 20, 2015

The time method in replay returns the base_time (start time) of the stream instead of the time of the last sample. Either the documentation or the retuned value are wrong here.

I vote that the code is wrong in Replay. Makes no sense for a method called #time to return the start of the stream.

@D-Alex
Copy link
Member

D-Alex commented Mar 21, 2015

The method is defined two times. Therefore, the last one wins which is (the other one is indeed wrong) :

#Returns the time of the current sample
def time
    return @stream.time    
end

This method should give you exactly the same value as current_time as long as no one has defined a default_timestamp or a timestamp.

@goldhoorn
Copy link
Contributor

and the Solution?

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

Successfully merging this pull request may close these issues.

4 participants