diff --git a/CHANGELOG.md b/CHANGELOG.md index 94fff94..0dd1192 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,12 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [1.60.1] - 2023-10-09 + +### Fixed + +- Send environment key for event arch accounts + ## [1.60.0] - 2023-09-28 ### Added diff --git a/tests/events/test_event_dispatcher.py b/tests/events/test_event_dispatcher.py index a232138..de3cc80 100644 --- a/tests/events/test_event_dispatcher.py +++ b/tests/events/test_event_dispatcher.py @@ -54,6 +54,7 @@ def flush_callback(err, events): "props": { "vwo_sdkName": constants.SDK_NAME, "vwo_sdkVersion": constants.SDK_VERSION, + "vwo_envKey": "testenvkey123456789472c212c972e", "variation": 2, "isFirst": 1, }, diff --git a/tests/events/test_impression_util.py b/tests/events/test_impression_util.py index 1f73155..b079216 100644 --- a/tests/events/test_impression_util.py +++ b/tests/events/test_impression_util.py @@ -78,6 +78,7 @@ def test_get_events_common_properties(self): "props": { "vwo_sdkName": constants.SDK_NAME, "vwo_sdkVersion": constants.SDK_VERSION, + "vwo_envKey": self.settings_file.get("sdkKey") }, "name": event_name, "time": generic_util.get_current_unix_timestamp_milli(), @@ -108,6 +109,7 @@ def test_create_track_user_events_impression(self): "isFirst": 1, "vwo_sdkName": constants.SDK_NAME, "vwo_sdkVersion": constants.SDK_VERSION, + "vwo_envKey": self.settings_file.get("sdkKey") }, "name": constants.EVENTS.VWO_VARIATION_SHOWN, "time": generic_util.get_current_unix_timestamp_milli(), @@ -139,6 +141,7 @@ def test_create_track_goal_events_impression_without_revenue(self): "vwoMeta": {"metric": {"id_1": ["g_1"]}}, "vwo_sdkName": constants.SDK_NAME, "vwo_sdkVersion": constants.SDK_VERSION, + "vwo_envKey": self.settings_file.get("sdkKey") }, "name": "test_goal_identifier", "time": generic_util.get_current_unix_timestamp_milli(), @@ -172,6 +175,7 @@ def test_create_track_goal_events_impression_with_single_revenue(self): "vwoMeta": {"metric": {"id_1": ["g_1"]}, "revKey": 100}, "vwo_sdkName": constants.SDK_NAME, "vwo_sdkVersion": constants.SDK_VERSION, + "vwo_envKey": self.settings_file.get("sdkKey") }, "name": "test_goal_identifier", "time": generic_util.get_current_unix_timestamp_milli(), @@ -210,6 +214,7 @@ def test_create_track_goal_events_impression_with_multiple_revenue(self): }, "vwo_sdkName": constants.SDK_NAME, "vwo_sdkVersion": constants.SDK_VERSION, + "vwo_envKey": self.settings_file.get("sdkKey") }, "name": "test_goal_identifier", "time": generic_util.get_current_unix_timestamp_milli(), @@ -246,6 +251,7 @@ def test_create_push_events_impression_with_single_tag(self): "isCustomEvent": True, "vwo_sdkName": constants.SDK_NAME, "vwo_sdkVersion": constants.SDK_VERSION, + "vwo_envKey": self.settings_file.get("sdkKey") }, "name": constants.EVENTS.VWO_SYNC_VISITOR_PROP, "time": generic_util.get_current_unix_timestamp_milli(), @@ -280,6 +286,7 @@ def test_create_push_events_impression_with_multiple_tags(self): "isCustomEvent": True, "vwo_sdkName": constants.SDK_NAME, "vwo_sdkVersion": constants.SDK_VERSION, + "vwo_envKey": self.settings_file.get("sdkKey") }, "name": constants.EVENTS.VWO_SYNC_VISITOR_PROP, "time": generic_util.get_current_unix_timestamp_milli(), diff --git a/vwo/helpers/impression_util.py b/vwo/helpers/impression_util.py index 53ba1b8..07bb969 100644 --- a/vwo/helpers/impression_util.py +++ b/vwo/helpers/impression_util.py @@ -299,6 +299,7 @@ def get_events_common_properties(settings_file, user_id, event_name): "props": { "vwo_sdkName": constants.SDK_NAME, "vwo_sdkVersion": constants.SDK_VERSION, + "vwo_envKey": sdk_key }, "name": event_name, "time": generic_util.get_current_unix_timestamp_milli(),