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

Improve decoding fractional epoch timestamps #79

Merged
merged 1 commit into from
Nov 28, 2021
Merged

Conversation

amotl
Copy link
Member

@amotl amotl commented Nov 28, 2021

Hi.

this aims to resolve #68, by verifying that Kotori already accepts fractional epoch timestamps. On top, the patch improves the situation by actually carrying over the corresponding precision to the database.

A test has been added to publish a single reading in JSON format to the MQTT broker, using a timestamp as Unix Epoch in seconds, as a floating point number. It proofs that the timestamp is processed and stored correctly.

With kind regards,
Andreas.

Add `test_timestamp_seconds_float`:

  Publish single reading in JSON format to MQTT broker,
  using a timestamp as Unix Epoch in seconds, as float number.
  Proof that the timestamp is processed and stored correctly.
@amotl amotl marked this pull request as ready for review November 28, 2021 12:21
@amotl amotl merged commit 9294369 into main Nov 28, 2021
@amotl amotl deleted the amo/epoch-as-float branch November 28, 2021 12:21
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.

Compatibility with Terkin: Timestamps are not accepted
1 participant