0
0
mirror of https://github.com/PostHog/posthog.git synced 2024-12-01 12:21:02 +01:00
Commit Graph

1427 Commits

Author SHA1 Message Date
James Greenhill
8c372070b2
refactor how we grab kafka_host to make it reusable for migrations (#1677) 2020-09-17 11:09:41 -07:00
James Greenhill
be4373e96c
Test if person exists before getting from it (#1676) 2020-09-17 09:46:15 -07:00
James Greenhill
463ce40ba6
Make get_is_identified more tolerant of missing person (#1675)
* Make get_is_identified more tolerant of missing person

* better test of out of range
2020-09-17 09:26:58 -07:00
Tim Glaser
b175cac5ce
Use cached results for funnels (#1671)
* Test commit

* use cached results for funnels
2020-09-17 13:58:15 +02:00
Paolo D'Amico
17bb22062b
Core action tracking I (#1612)
* feat: capture team member deleted event

* feat: capture annotation creation & update events

* feat: annotation deleted event

* fix: typechecking

* fix: fixes action signal

* Merge branch 'master' into 1575-core-action-tracking

* black

* refactor annotation analytics

* feature flag analytics

* formatting & typechecking

* fix
2020-09-17 11:38:41 +02:00
Yakko Majuri
0f1b5953b2
Added warning for changing feature flag key (#1646)
* added warning for changing feature flag key

* update link to docs
2020-09-17 11:36:43 +02:00
James Greenhill
bd1b5b7c64
Remove default json serializer from kafka_helper (#1669) 2020-09-16 12:19:16 -07:00
James Greenhill
247b7c1912
put process_event_ee back on celery with delay (#1667) 2020-09-16 10:47:40 -07:00
James Greenhill
adeb7694cc
Publish events to Kafka for consumption (#1644)
* Publish events to Kafka for consumption

* Commit avro idl's for event schemas

* convert client to use github.com/dpkp/kafka-python

* events loaded into clickhouse from Kafka

* remove cruft

* Publish events to Kafka for consumption

* convert client to use github.com/dpkp/kafka-python

* remove cruft

* include kafka migrations

* bugfixes for migrations

* use constants for consistency

* wrap up local migrations

* small fixes

* tune ups
2020-09-15 20:04:38 -07:00
Marius Andra
50c683e691
Clickhouse process event (#1652)
* generate clickhouse uuid script

* set CLICKHOUSE_SECURE=False by default if running in TEST or DEBUG

* convert person_id to UUID, make adding `person_id` optional, add distinct_ids already in the `create_person` function

* Fix test_process_event_ee.py, remove all calls to Person.objects.*

* add back util

* fix broken imports

* improve process_event test clickhouse queries

* change property parsing

* indentation wrong missing calls

* uuid4 instead of call to CH

Co-authored-by: Eric <eeoneric@gmail.com>
Co-authored-by: James Greenhill <fuziontech@gmail.com>
2020-09-15 12:40:35 -07:00
Tim Glaser
10c0819d27
Add detailed label to actionstable (#1653)
* Test commit

* Add detailed label to actionstable
2020-09-15 13:16:44 +02:00
Tim Glaser
fe3c8e7c24
Add "is_simple_flag" to Feature flags (#1639)
* Test commit

* Add is_simple_flag to api
2020-09-11 08:02:44 +00:00
Tim Glaser
2421793228
Add tests for FOSS (#1600)
* Add tests for FOSS

* Ignore ee specific tests

* Exclude more ee only tests

* conditional tests, nice

* Add ee_available to settings

* fix test

* Fix test

* Test commit

* Fix test again

* Remove EE_MISSING in favor of EE_AVAILABLE completely

* Rename bottom-notice.html to overlays.html, to better reflect purpose

* Add greeting

* Fix ee import

Co-authored-by: Michael Matloka <dev@twixes.com>
2020-09-10 18:20:29 +02:00
Marius Andra
5a6853654c
Fix a few "Unchanged files with check annotations" issues (#1641)
* fix a few "Unchanged files with check annotations" issues

* fix one more issue
2020-09-10 17:09:56 +02:00
Marius Andra
bfd856bb95
Nicer API Failure Errors (#1633)
* convert api to async/await

* throw a nicer error if received a HTML error
2020-09-10 16:32:31 +02:00
Eric Duong
c3b6d62d83
change the default so local dev works well (#1637) 2020-09-10 16:09:40 +02:00
Marius Andra
270c5f4a78
1) upgrade kea to 2.2.0 final and kea-typegen to 0.3.0, 2) fix some broken types (#1634) 2020-09-10 15:29:24 +02:00
Michael Matloka
36dd684861
Fix optional trailing slash routing (#1631) 2020-09-10 12:06:32 +02:00
James Greenhill
87f54610cc
Enable Clickhouse event processing (#1629)
* Enable Clickhouse event processing
2020-09-09 21:21:01 -07:00
James Greenhill
f8c48c0779
Remove function call to see impact on performance (#1627) 2020-09-09 20:32:03 -07:00
James Greenhill
eaff39388d
Refactor get_or_create_person function in process_event (#1626)
* Refactor get_or_create_person function in process_event

* optimize get_or_create person
2020-09-09 19:58:31 -07:00
James Greenhill
1de047b10d
Migrate process_event shared functions to be public (#1625)
* Migrate process_event shared functions to be public

* mypy and adjust

* exclude tests that are tagged 'skip_on_multitenancy'
2020-09-09 18:34:13 -07:00
James Greenhill
2e6a5ed79b
Make hash elements public function on element_group (#1622)
* Make hash elements public function on element_group

* Remove self from function 🧘
2020-09-09 11:36:47 -07:00
Michael Matloka
fd9df64b92
Improve API routing (#1557)
* Make trailing slash optional in DRF endpoints

* Update tests

* Make authenticate_secondarily a util

* Use @authenticate_secondarily in /decide

* Add API-specific 404 error and improve URLs

* Update tests

* Don't use @authenticate_secondarily in /decide

* Update urlpatterns

* Update test_user.py

* fixed formatting

* minor changes to tests and _ endpoints

Co-authored-by: Yakko Majuri <yakko.majuri@gmail.com>
2020-09-09 16:54:50 +02:00
James Greenhill
fdfe7a4459
Revert "Convert private functions to public for ee access (#1618)" (#1620)
This reverts commit 245bf27857.
2020-09-08 22:51:20 -07:00
James Greenhill
245bf27857
Convert private functions to public for ee access (#1618)
* Final ClickHouse module before wiring up to Posthog

* convert private functions to public for ee access

* Fix mypy error

* fix up a few typos breaking tests
2020-09-08 22:35:26 -07:00
James Greenhill
70868fc7db
Final ClickHouse module before wiring up to Posthog (#1617) 2020-09-08 21:00:37 -07:00
James Greenhill
7d80f7631e
clickhouse views and management commands (#1616) 2020-09-08 20:13:54 -07:00
James Greenhill
712e790f8d
Add clickhouse queries (#1615) 2020-09-08 19:23:10 -07:00
James Greenhill
f2680a61e3
clickhouse models (#1614) 2020-09-08 18:55:01 -07:00
James Greenhill
dedf5582c1
first chunk of clickhouse framework (#1613)
* first chunk of clickhouse framework

* prod, not dev docker-compose.yml

* add clickhouse sql files
2020-09-08 16:12:27 -07:00
James Greenhill
5293b4004a
Remove celerybeat.pid before starting docker worker (#1608) 2020-09-08 10:32:41 -07:00
Paolo D'Amico
c0124aa1d7
fix: skip some tests on multitenancy (#1607) 2020-09-08 17:56:22 +02:00
Tim Glaser
7b875aeaba
Fix papercups (#1606) 2020-09-08 17:07:09 +02:00
Michael Matloka
2c242abdcb
Fix Papercups not appearing in app 2020-09-08 16:00:03 +02:00
Jonathan Hyde
8b306989bd
Typo in licenses.tsx (#1599)
More unlock than unluck :)
2020-09-08 15:30:24 +02:00
Tim Glaser
a0e77935ae
Bump posthog-js 1.4.5 (#1597) 2020-09-08 15:28:35 +02:00
Paolo D'Amico
9b93966b4c
fix: load debug_toolbar if not testing (#1598) 2020-09-08 14:33:42 +02:00
Yakko Majuri
e7db9194ce
Make /decide endpoint more flexible (#1592)
* made #1553's changes in a separate branch

* stopped accessing request.body twice

* fixed request.body issues

* unpack request.body

* fixed code quality

* Refactor slightly

Co-authored-by: Michael Matloka <dev@twixes.com>
2020-09-08 09:21:15 +00:00
James Greenhill
5bce20abe4
Add statsd to celery tasks and add task to monitor queue size (#1595)
* Add statsd to celery tasks and add task to monitor queue size

* no type checking for statsd lib

* Don't complain about statsd not being around if it's not there
2020-09-07 12:40:26 -07:00
Tim Glaser
f6fcb2f2bc
Papercups identify user (#1593) 2020-09-07 18:29:23 +02:00
Paolo D'Amico
cf2ec2894c
Signup improvements (#1535)
Co-authored-by: Yakko Majuri <yakko.majuri@gmail.com>
Co-authored-by: Michael Matloka <dev@twixes.com>
2020-09-07 09:23:13 -05:00
Tim Glaser
02f8205526
Fix multiple elementgroup returned (#1549)
* Fix multiple elementgroup returned

* Fix mypy
2020-09-07 14:59:46 +02:00
Weyert de Boer
832b55f71e
fix: handle the case of invalid json gracefully (#1581)
* fix: handle the case of invalid json gracefully

This changes the behaviour how invalid json is handled in the `/decide`-endpoint instead of failing hard by throwing a 500 internal server error it instead will throw a 400 Bad Request error instead to make the Developer Experience better

fixes #1576

* set JSON error to POST req only

* improved json error handling

* removed unused Tuple import

Co-authored-by: Weyert de Boer <weyert.deboer@tapico.io>
Co-authored-by: Yakko Majuri <yakko.majuri@gmail.com>
2020-09-07 12:43:21 +01:00
James Greenhill
49994a4b28
Revert "Add monitoring of celery queue size to statsd (#1589)" (#1591)
This reverts commit bc4e7c83a0.
2020-09-04 22:11:31 -07:00
James Greenhill
bc4e7c83a0
Add monitoring of celery queue size to statsd (#1589)
* add celery queue monitoring

* Add monitoring of celery queue size to statsd

* remove unnecessary functions

* mypy ignores for libs
2020-09-04 21:46:50 -07:00
James Greenhill
c2e03a3a46
Revert this to bring back the working copy of ee / clickhouse (#1588) 2020-09-04 21:12:07 -07:00
James Greenhill
8631ee232b
Noop on celery worker if ee is not enabled (#1587)
* Noop on celery side if ee is not enabled

* Formatting and stub async and sync executors
2020-09-04 19:35:17 -07:00
James Greenhill
1e905e2913
Update async events to clickhouse to use python 3.6 api (#1586) 2020-09-04 18:37:38 -07:00
James Greenhill
8e26357770
Async writes to clickhouse (#1585)
* Initial commit async-ing clickhouse

* Async writes to clickhouse

* deconflict master

* sync events listing

* mypy checks
2020-09-04 17:46:02 -07:00