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

901 Commits

Author SHA1 Message Date
Marius Andra
3259f8e706
Some typescript fixes (#3049)
* fix sceneLogic and teamLogic

* personLogic one fix

* navigationLogic type

* topContentLogic type

* personalAPIKeysLogic type

* BackTo type

* few other quick wins

* Update blacklist after rebase

Co-authored-by: Karl-Aksel Puulmann <oxymaccy@gmail.com>
2021-01-25 11:05:36 +02:00
Marius Andra
88e1300a14
fix exception when using a bad selector to select actions (#3067) 2021-01-25 09:35:07 +01:00
Karl-Aksel Puulmann
365243a102
Fix session recording breakage (#3045)
* Fix broken session recording case

No strict typescript makes me sad. This property was gone during
refactoring, probably broken due to parallel PRs.

* Make pagination respect filters
2021-01-25 08:49:55 +02:00
Marius Andra
19b453c996
Kea TypeGen types in the same folder as logic (#3048)
* update kearc to generate types in the same folder, add types to gitignore

* update type imports
2021-01-22 10:21:48 +01:00
Yakko Majuri
7c0cc81105
Hide plugins from nav in Cloud (#3038)
* Add plugins on new nav behind feature flag (cloud)

* filter by plugin org access

* remove accidental commit
2021-01-21 16:23:02 -03:00
Eric Duong
7001a1ce02
patch null check (#3037) 2021-01-21 11:22:52 -05:00
Karl-Aksel Puulmann
29c1ed954d
Allow filtering by unseen recordings (#3000)
* Add model for session recording viewed

* Save view when querying for session recording data

* Send information to FE about whether session has been viewed

* Allow filtering by "recording unseen"

* Rename property

* Update migration
2021-01-21 09:42:00 +02:00
Tim Glaser
811e414ce3
Standardize created at and by table columns (#2961)
Co-authored-by: Paolo D'Amico <paolodamico@users.noreply.github.com>
2021-01-20 20:08:31 -06:00
Eric Duong
6e7ff0d4db
Revert "Add timeout and error messages (#2876)" (#3012)
This reverts commit c2f844c832.
2021-01-20 09:51:35 -05:00
Marius Andra
10b5f20f80
Plugins page UX improvement (#3006)
* open drawer if plugin installed but never configured when toggling switch

* ?.

* set initial/unsaved changes when opening plugin drawer

* set "enabled" to true when installing plugin

* use plugin url as key to remove installed plugins from repository, not name

* extra fix

* disallow multiple plugin installations from the same URL
2021-01-20 14:16:29 +01:00
Tim Glaser
c2f844c832
Add timeout and error messages (#2876)
* Only grab recent events in Events list

* Add timeout and error messages

* Add timeout messages to other items

* Add instrumentation, fixed issues

* Longer timeout for plugins

* update UI for error message

* UI for timeout message

* Fix funnel timer, improve error message

* change icons when timeout has elapsed

* Fix error messages

* Fix funnel loading timeout

* fix errors

* fix exception

Co-authored-by: Paolo D'Amico <paolodamico@users.noreply.github.com>
2021-01-20 12:45:08 +01:00
Karl-Aksel Puulmann
9354b7ce64
Highlight filtered events in events table and in session recording (#2954)
* Highlight rows from sessions which are matched by the filter

* Send start_time of recording to frontend

This helps us calculate offsets a bit better

* Use timestamp by server for date shown

* Load session events via kea logic

* Update rrweb, rrweb-player

* Highlight events user is filtering for in sessions player

* Handle empty case properly

* Add positive test

* Order session recording events in query

* Fix filtering by multiple events with differing names

previously only the first would have been used due to overlapping
params.

* Return all highlighted times as action_filter_times

* Send back ids not timestamps

This avoids weird rounding errors causing issues

* Show skeleton for longer

* update typing

Co-authored-by: Paolo D'Amico <paolodamico@users.noreply.github.com>
2021-01-19 21:16:42 -06:00
Karl-Aksel Puulmann
c245af6a3e
Filters design followups (#2993)
Co-authored-by: Paolo D'Amico <paolodamico@users.noreply.github.com>
2021-01-19 20:58:21 -06:00
Eric Duong
0a68184cc4
Use utc moment for retention dates and fix modal title (#2998) 2021-01-19 20:54:15 -06:00
Marius Andra
2dc132e388
Plugins Design Refresh (#2939)
Co-authored-by: Paolo D'Amico <paolodamico@users.noreply.github.com>
2021-01-19 18:16:18 -06:00
Karl-Aksel Puulmann
a612a6b6bd
Sessions filters design (#2987) 2021-01-19 08:20:21 -06:00
Yakko Majuri
f39877f869
Add Community tag to plugins (#2982) 2021-01-19 11:11:41 +01:00
Paolo D'Amico
6daaae8cfd
add and indicator to feat flags (#2959) 2021-01-19 11:08:37 +02:00
Eric Duong
7bc28ca282
Fix prop operator not changing (#2981)
* always allow operator to be changed

* use diff solution
2021-01-18 16:28:48 -05:00
Tim Glaser
e6b7ac88ca
Fix options not loaded (#2973) 2021-01-18 15:29:21 +01:00
Paolo D'Amico
c2d38947b3
fix text_muted var (#2969) 2021-01-18 07:53:20 -06:00
Marius Andra
e3256e3ef0
Add link to plugin troubleshooting if server offline (#2936)
* add link to plugin troubleshooting

* Link directly to "Plugin server is offline"

Co-authored-by: Michael Matloka <dev@twixes.com>
2021-01-18 13:55:03 +01:00
Marius Andra
0a990ff0e3
Lessen the language in the plugin opt-in warning (#2968)
* lessen the language in the plugin optin warning

* Reword slightly for approachability

Co-authored-by: Michael Matloka <dev@twixes.com>
2021-01-18 13:51:29 +01:00
Calvin
7b74845cb7
Fixes #2942: Order tooltip by volume (#2960) 2021-01-16 10:06:29 +01:00
Karl-Aksel Puulmann
7103c37a7b
Trends: small fixes (#2956) 2021-01-15 08:53:36 -06:00
Karl-Aksel Puulmann
62dedd9610
Capture rageclicks for posthog (#2957)
Let's see if/how it works, this way we can shout this out next release.
2021-01-15 15:49:49 +01:00
Tim Glaser
1a6207d791
Upload static cohort csv (#2932)
* Upload static cohort using CSV, closes #2868

* fix tests

* Fix tests

* Fix e2e test

* Avoid double inserts

* Speed up query

* Move to params

* fix tests

* Use JSON instead of protobuf

* unused import

* produce instead of produce_proto

* Insert directly into clickhouse, no need for kafka

* a few quick fixes

* insert in batch to clickhouse

* test SQLi since we can't really trust what we are inserting

* Extra check for duplicates

Co-authored-by: James Greenhill <fuziontech@gmail.com>
2021-01-15 11:19:31 +01:00
Karl-Aksel Puulmann
17a31f0b43
Speed up sessions list query (#2934)
* Remove (apparently) useless person joins from sessions sql

* WIP: Make sessions list query use python iteration

* WIP: Show loader while session data is loading

* Aggregate together sessions

* Calculate start and end points of session separately

* Remove cruft code

* Load session events asynchronously for self-hosted

Note clickhouse behavior is unchanged.

* Update pagination logic for sessions

In addition to offset, postgres now returns a dict containing person_id,
timestamp which is used to make sure we filter events on different pages
correctly

* Add some tests to SessionListBuilder

* Fix typing errors

* Fix pagination limit

* Move tests to right file

* Query less events for sessions list

Since we're ordering by end_time we know events before last end_time are
all processed.

* Add test for current_url behavior

* Make sure old tests remain working

* Remove unused base class

* Move sessions-related queries to separate subfolder

* Extract sessions list code to separate file(s)

* Sort sessions by end time in ch as well

* List end time in sessions table

* Return person email when querying sessions lists on postgres

This gets used by the view

* Return email over all user properties for sessions in clickhouse and view

* Fix an ordering bug

* Fix a pagination bug

* Fix endpoint

* Fix basic sessions tests for pagination

* Sort consistently for sessions list builder

* Roll pagination into filters
2021-01-15 01:53:28 +02:00
Paolo D'Amico
39270b3249
Insights data instrumentation (#2787) 2021-01-14 10:59:20 -06:00
Eric Duong
e0980027eb
make flag explicit (#2947) 2021-01-14 09:53:08 -06:00
Paolo D'Amico
d91cc21217
More key feature instrumentation (#2811) 2021-01-14 07:36:44 -06:00
Paolo D'Amico
6c31678016
Add pinned dashboards to new navigation (#2906)
Co-authored-by: Michael Matloka <dev@twixes.com>
2021-01-13 09:18:31 -06:00
Eric Duong
ca54574374
remove unnecessary action properties iterating (#2926) 2021-01-13 15:13:19 +01:00
Eric Duong
953509b849
change datepickers to rangepicker (#2922) 2021-01-13 14:41:51 +01:00
Karl-Aksel Puulmann
19c50a2bfe
Sessions filtering system (#2912)
* Refactor adding filtering component

* Fix a type error

* Rename events to entries

This makes much more sense since you can select e.g. actions

* Start of the session filter box

* WIP: Sessions filtering

* Make SelectBox more generic

* Make sessions filtering visuals

* Extract operator value selection code

* Make action properties filterable

* Make it possible to filter by cohorts

* Filtering by events

* Make loading sessions possible with the new logic

* Make it possible to filter by actions/events via backend with new code

Note that it's all relying on old 'paths' - will refactor these later.

* Make it possible to filter by user properties

* Update imports

* Small fixes for sessions filter

* Add UserFilter file

* Ignore extra args to Property

* Make it possile to filter by recording duration

* Update how session duration filter works in the backend

* Rename a few columns

* Remove dead mixins

* Remove duplicated logic, put code behind feature flag

* Move sessions filters logic to subfolder

* Don't show properties if feature flag.

* Add saved filters support

This will require some discussion with Paolo - probably want to show
this on the side?

* Add divider before sessions table

* Narrower typing for recordings

* Some frontend for saving filters

* Small rename

* Add SessionsFilter model

* Save filter on backend

* add missing filter

* Extract const

* Make ActionFilterDropdown be able to pick actions again.

* Fix links from person modal to sessions

* Update tests.

* Fix database model

* Use proper deep equal for detecting active filter

* Remove unneeded field

* Only return filters from correct page

* Add missing data-attr

* Add instrumentation

* rename component

* Fix analytics metadata
2021-01-13 14:55:06 +02:00
Michael Matloka
598aea06b9
Make Jest tests work better with TypeScript (#2558)
Co-authored-by: Paolo D'Amico <paolodamico@users.noreply.github.com>
2021-01-12 17:46:59 -06:00
Eric Duong
c3f248513f
Switch user prompt location (#2924)
Co-authored-by: Paolo D'Amico <paolodamico@users.noreply.github.com>
2021-01-12 16:00:31 -06:00
Eric Duong
650bc428d3
Remove shownas filter and move stickiness/lifecycle into separate insight tabs (#2899)
Co-authored-by: Paolo D'Amico <paolodamico@users.noreply.github.com>
2021-01-12 12:12:42 -06:00
Marius Andra
db7b3fef96
fix clearRetention (#2919) 2021-01-12 16:53:14 +01:00
Eric Duong
ed324fd793
add bordercolor var to missing change (#2921) 2021-01-12 16:23:56 +01:00
Marius Andra
1031329986
Fix dashboard colors with non-white backgrounds (#2911)
* fix local variable bug

* add "no-shadow" rule as a warning

* fix two blue lines on line graphs
2021-01-12 12:43:54 +01:00
Eric Duong
70a6ecb407
Separate math aggregates (#2885)
* separate math aggregates

* add data attr back

* adjust cypress

* make sure tooltip is viewable

* Show total by default

Co-authored-by: Tim Glaser <tim@glsr.nl>
2021-01-11 14:28:29 +01:00
Paolo D'Amico
5f726ee485
Hotfix - Papercups chat collision (#2908)
* use distinct ID in Papercups to avoid collision

* Add user_id to Papercups customer metadata

Co-authored-by: Michael Matloka <dev@twixes.com>
2021-01-11 02:02:01 +01:00
Eric Duong
11a7388477
fix missing action when returning from dashboard (#2884) 2021-01-08 16:29:26 +01:00
Eric Duong
95c9a4ee1c
fix dataindex (#2883) 2021-01-08 16:00:53 +01:00
Eric Duong
3b32961254
fix var name (#2882) 2021-01-08 16:00:37 +01:00
Marius Andra
663d853a07
Make funnel steps sortable (#2862)
* Make funnel steps sortable

* sortableElement eats the `index` prop, must pass separately

* properly sort all types of filters

* Lock dragging to Y axis

* Sorting UI improvements (#2888)

* use icon for drag handle

* allow sorting only when there's at least two steps

* add instrumentation

Co-authored-by: Michael Matloka <dev@twixes.com>
Co-authored-by: Paolo D'Amico <paolodamico@users.noreply.github.com>
2021-01-08 09:35:12 +01:00
Paolo D'Amico
f9a35e2dbf
Instrument toolbar (#2859)
* elements instrumentation, stats & heatmaps

* add events for action & inspect mode

* more events

* fix capture on setExtensionPercentage

* update posthog imports

* add heatmap and action counts

* update heatmap and action counts

* fix few type errors

* track down all data-* attributes when selecting an HTML element in the toolbar

* exchange extensionPercentage for toolbar loaded

* rename event (lost in some rebase)

Co-authored-by: Marius Andra <marius.andra@gmail.com>
2021-01-07 12:55:25 +01:00
Eric Duong
476da265d2
Clickhouse caching (#2855)
* split params into mixins

* add typing

* split func

* dedicated paths filter

* make basefilter

* restructure directories

* move prop mixin

* implement cached_property and fix circular import

* remove unused imports

* stickiness filter converted

* temp patch for breakdown

* correct naming for derived mixins in paths

* fix types

* fix types

* fix casing

* fix breakdown arg

* merge master

* add to_dict

* DRY to_dict

* scoped to_dict ability

* fix types

* add missing fields

* refactor session filter

* remove unused imports

* remove unused imports

* add stickiness filter test

* fix dict for pathfilter

* properly load strs

* add default

* standardize loading

* retention filter separate

* add update filter to retention

* change back decorator

* don't allow setting on filter date_from date_to

* remove seconds on default timestamp

* remove derived values

* fix date formatting

* fix typo

* ch caching endpoints

* add cache funnel and remove ee flag for check cache items

* reorg update cache

* postgres refresh working

* change test so it doesn't hit cache

* minor adjustments

* add cache type testing

* run again

* remove unnecessary imports

* add back ee check for celery tasK

* fix setallfilters

* fix path dashboarditem calling

* fix path func names
2021-01-06 22:37:43 +01:00
Tim Glaser
027708c345
Fix retention entity selection (#2825)
* Fix retention entity selection

* Fix tests

* Remove

* Retnetion

* Fix loading retention on dashboard

* fix graph result interval type

* add comment

* fix period check

* fix type

Co-authored-by: Eric <eeoneric@gmail.com>
2021-01-06 17:09:33 +01:00