Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 4 additions & 6 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,10 @@
language: ruby

rvm:
- 2.0.0
- 2.1.10
- 2.2.9
- 2.3.6
- 2.4.3
- 2.5.0 # Performs deploys. Change condition below when changing this.
- 2.5.0
- 2.6.0
- 2.7.0 # Performs deploys. Change condition below when changing this.

script:
- make check
Expand All @@ -17,6 +15,6 @@ deploy:
provider: rubygems
on:
tags: true
condition: "$TRAVIS_RUBY_VERSION == 2.5.0"
condition: "$TRAVIS_RUBY_VERSION == 2.7.0"
api_key:
secure: Ceq6J4aBpsoqRfSiC7z+/J4moOXNjcPMFb2Bfm5qE51cIZzeyuOIOc6zhrad9tUgoX6uTRRxLxkybyu4wNYSluMA3IXW20CJyXZeJEHIaTYIDTWFAIYyerBJyMujJycSo7XueWb0faKBENrBQKx1K1tS0EiXpA2rMhdA6RM3DOY=
6 changes: 6 additions & 0 deletions History.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
2.3.0 / 2020-03-26
==================

* [Improvement](https://github.com/segmentio/analytics-ruby/pull/225): Update timestamp for sub-millisecond reporting
* Update supported Ruby versions (2.4, 2.5, 2.6, 2.7), remove unsupported Ruby versions (2.0, 2.1, 2.2, 2.3)

2.2.8 / 2020-02-10
==================

Expand Down
8 changes: 2 additions & 6 deletions lib/segment/analytics/utils.rb
Original file line number Diff line number Diff line change
Expand Up @@ -64,12 +64,8 @@ def datetime_in_iso8601(datetime)
end
end

def time_in_iso8601(time, fraction_digits = 3)
fraction = if fraction_digits > 0
('.%06i' % time.usec)[0, fraction_digits + 1]
end

"#{time.strftime('%Y-%m-%dT%H:%M:%S')}#{fraction}#{formatted_offset(time, true, 'Z')}"
def time_in_iso8601(time)
"#{time.strftime('%Y-%m-%dT%H:%M:%S.%6N')}#{formatted_offset(time, true, 'Z')}"
end

def date_in_iso8601(date)
Expand Down
2 changes: 1 addition & 1 deletion lib/segment/analytics/version.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
module Segment
class Analytics
VERSION = '2.2.8.pre'
Comment thread
nd4p90x marked this conversation as resolved.
VERSION = '2.3.0'
end
end