File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -12,9 +12,8 @@ For full documentation visit
1212
1313### Sending flag analytics to a different host than evaluations
1414
15- When evaluating flags through an Edge Proxy (or another host that does not handle
16- the analytics endpoint), pass ` analytics_url ` to send flag analytics directly to the
17- core Flagsmith API while keeping flag evaluations on the proxy:
15+ When evaluating flags through an Edge Proxy (or another host that does not handle the analytics endpoint), pass
16+ ` analytics_url ` to send flag analytics directly to the core Flagsmith API while keeping flag evaluations on the proxy:
1817
1918``` python
2019from flagsmith import Flagsmith
@@ -28,8 +27,7 @@ flagsmith = Flagsmith(
2827)
2928```
3029
31- When ` analytics_url ` is unset, analytics continue to post to
32- ` <api_url>/analytics/flags/ ` as before.
30+ When ` analytics_url ` is unset, analytics continue to post to ` <api_url>/analytics/flags/ ` as before.
3331
3432## Contributing
3533
Original file line number Diff line number Diff line change 22from datetime import datetime , timedelta
33from unittest import mock
44
5- from flagsmith .analytics import ANALYTICS_ENDPOINT , ANALYTICS_TIMER , AnalyticsProcessor
5+ from flagsmith .analytics import (
6+ ANALYTICS_ENDPOINT ,
7+ ANALYTICS_TIMER ,
8+ AnalyticsProcessor ,
9+ )
610
711
812def test_analytics_processor_track_feature_updates_analytics_data (
Original file line number Diff line number Diff line change @@ -1201,12 +1201,8 @@ def test_flagsmith_posts_analytics_to_analytics_url_when_set(
12011201 enable_analytics = True ,
12021202 )
12031203
1204- expected_analytics_url = (
1205- "http://core-api.flagsmith.com/api/v1/analytics/flags/"
1206- )
1207- responses .add (
1208- method = "GET" , url = flagsmith .environment_flags_url , body = flags_json
1209- )
1204+ expected_analytics_url = "http://core-api.flagsmith.com/api/v1/analytics/flags/"
1205+ responses .add (method = "GET" , url = flagsmith .environment_flags_url , body = flags_json )
12101206 responses .add (method = "POST" , url = expected_analytics_url , status = 200 )
12111207
12121208 # When the customer-facing evaluation API is exercised. This is the path
You can’t perform that action at this time.
0 commit comments