0
0
mirror of https://github.com/PostHog/posthog.git synced 2024-11-24 00:47:50 +01:00
Commit Graph

74 Commits

Author SHA1 Message Date
Zach Waterfield
23db9545fc
feat: add access control model (#26076) 2024-11-07 19:45:21 -05:00
Zach Waterfield
003ac8a029
feat: trials UI on teams (#25885)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2024-11-01 11:50:36 -04:00
Michael Matloka
84db60babb
ci: Split Temporal backend suite into three (#25880)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2024-10-30 16:15:46 +00:00
Zach Waterfield
878422a583
feat: enter cc in app (round 2) (#25434)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2024-10-11 15:37:01 -04:00
Zach Waterfield
1bb5016d50
feat: set the user id in the billing token (#25441) 2024-10-10 12:31:55 -04:00
Zach Waterfield
862082f10d
revert: revert the revert for annual credits (#24898) (#24900) 2024-09-11 10:38:03 -04:00
Zach Waterfield
f01b44db05
revert: "feat: annual credit purchases (#24691)" (#24898) 2024-09-10 16:30:15 -07:00
Zach Waterfield
0240afc6d3
feat: annual credit purchases (#24691) 2024-09-10 17:51:17 -04:00
timgl
acda90e363
fix: Fix UUID typing issues (#24815) 2024-09-05 15:52:01 +00:00
Tom Owers
9842e97b58
chore(data-warehouse): Updated billing limits to work per sync (#24752) 2024-09-04 15:21:00 +01:00
Juraj Majerik
3f2337539d
chore(experiments): rename A/B testing -> Experiments (#24716) 2024-09-02 17:14:49 +02:00
Julian Bez
1e1a740b6b
chore: Revert "chore(deps): Upgrade to Django 5" (#24668) 2024-08-29 10:51:36 +00:00
Julian Bez
9418235763
chore(deps): Upgrade to Django 5 (#23626) 2024-08-29 10:56:28 +01:00
Zach Waterfield
6f82ba2c82
chore: set billing limit values to only be ints (#24353)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2024-08-20 10:51:58 -04:00
Zach Waterfield
4bdd564eeb
feat: update billing manager sync to use a single func (#24205) 2024-08-07 14:40:03 -04:00
Eric Duong
0e64d85e7d
fix(data-warehouse): use rows synced from pg (#24203) 2024-08-05 22:13:30 -04:00
Zach Waterfield
a174c11fde
chore: expand frontend to support billing limit as number (#23932)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2024-07-30 16:42:31 -04:00
David Newell
c564b0ce63
feat: error tracking sparklines (#23330) 2024-07-08 10:03:03 +01:00
Zach Waterfield
c62058c33f
feat: add a portal redirect endpoint (#23375)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Eric Duong <eric@posthog.com>
Co-authored-by: Dylan Martin <dylan@posthog.com>
Co-authored-by: Sandy Spicer <sandy@posthog.com>
Co-authored-by: Robbie <robbie.coomber@gmail.com>
Co-authored-by: Xavier Vello <xavier.vello@gmail.com>
Co-authored-by: Paul D'Ambra <paul@posthog.com>
Co-authored-by: Marcus Hof <13001502+MarconLP@users.noreply.github.com>
Co-authored-by: Juraj Majerik <juro.majerik@gmail.com>
Co-authored-by: Tom Owers <tom@posthog.com>
Co-authored-by: Phani Raj <phani@posthog.com>
2024-07-02 15:25:04 -04:00
Raquel Smith
8b3b31a0fa
fix: cache key interpolation bug (#23200)
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2024-06-27 10:29:49 -07:00
Bianca Yang
7bf5bddf49
feat: Revert changes to /billing page month-to-date dollar amount calculation (#22863)
* revert any changes to local updates to current_amount_usd, keep changes in current_usage accumulation

* fix tests

* add some text saying the dollar values update once daily

* Update UI snapshots for `chromium` (1)

* Update UI snapshots for `chromium` (1)

* Update UI snapshots for `chromium` (2)

* Update UI snapshots for `chromium` (2)

* Update UI snapshots for `chromium` (2)

* Update UI snapshots for `chromium` (2)

* add in banner about tiers data

* Update UI snapshots for `chromium` (2)

* Update UI snapshots for `chromium` (1)

* Update UI snapshots for `chromium` (2)

* Update UI snapshots for `chromium` (1)

* Update UI snapshots for `chromium` (2)

* Update UI snapshots for `chromium` (2)

---------

Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2024-06-11 12:35:30 -07:00
Bianca Yang
78d7daa3fc
fix: Billing product card display issues (#22767)
* fix the upgrade card?

* fix the month to date dollar amount display?

* Update frontend/src/scenes/billing/BillingProduct.tsx

* Update UI snapshots for `chromium` (2)

* fix tests

* Update UI snapshots for `chromium` (2)

* Update UI snapshots for `chromium` (2)

* Update UI snapshots for `chromium` (2)

* Update UI snapshots for `chromium` (2)

* Update UI snapshots for `chromium` (2)

* Update UI snapshots for `chromium` (1)

* Update UI snapshots for `chromium` (2)

* Update UI snapshots for `chromium` (1)

* Update UI snapshots for `chromium` (2)

* Update UI snapshots for `chromium` (1)

* Update UI snapshots for `chromium` (1)

---------

Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2024-06-07 20:58:52 +00:00
Bianca Yang
0a72f26df8
fix: /billing page usage calculations (#22696) 2024-06-05 08:18:08 -07:00
Bianca Yang
5d2639606c
fix: Add in checks on dictionary accessors when updating local usage information in posthog (#22688)
* fix the dictionary accessors

* lint
2024-06-04 12:28:16 -07:00
Bianca Yang
ff5b2f1782
feat: Current bill value should respect usage limits (#22597)
* have current usage dollar value respect billing limits

* add test

* update according to pr feedback
2024-06-04 10:49:12 -07:00
Bianca Yang
1eb6661c7e
fix: Patch the usage_summary value for rows_synced (#22600)
* patch the usage_summary value for rows_synced

* break up code for readability
2024-06-03 21:27:17 +00:00
Bianca Yang
9dd22a3757
feat: Deprecate available_features pt 2 (#22373)
* everything except plugin server and sync_available_features

* sync_available_features_done, some plugin_server done?

* and a tiny bit more

* linting

* try to fix some tests

* more test fixes/

* clean up typos

* weed wacking bugs

* more test shenanigans

* fix plugin server

* actually fix plugin server test?

* still fixing tests

* another attempt

* some pr feedback

* small fix

* fix database query accessor

* fix functional tests

* fix tests

* Update query snapshots

* Update query snapshots

* Update query snapshots

* update some comments and fxn names

* fix plugin server test

* Update query snapshots

* Update query snapshots

* Update query snapshots

---------

Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2024-05-28 17:29:24 -07:00
Bianca Yang
0ffd1b78ba
fix: Trust score update in quota_limiting was using the wrong key (#22535)
* fix dict update

* add test
2024-05-27 20:55:08 -07:00
Bianca Yang
db8b0033c2
fix: Fix customer_trust_score dict update (#22530)
* fix the trust_score dict updater

* fix test
2024-05-27 21:39:09 +00:00
Zach Waterfield
a5375dfa0d
feat: send updated owner/admin emails to billing (#22374)
* Send updated admin emails to billing

* add tests

* sync when a user is removed from an org

* fix the admin email filter

* sync admin emails on level change

* add more tests
2024-05-22 15:49:13 -04:00
Zach Waterfield
187c1265c0
fix: make sure available features get set (#22423)
make sure available features get set
2024-05-22 10:48:24 -04:00
Bianca Yang
008698a785
feat: remove most frontend references to available_features (#22337)
* remove most frontend references to available_features

* some more

* Update UI snapshots for `chromium` (1)

* Update UI snapshots for `chromium` (2)

* adding back some items, fix tests

* Update UI snapshots for `chromium` (1)

* Update UI snapshots for `chromium` (2)

* fix test

* Update UI snapshots for `chromium` (1)

* Update UI snapshots for `chromium` (1)

---------

Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2024-05-20 14:24:32 -07:00
Bianca Yang
cb95d71723
fix: Fix dict accessor for subscription status on addons (#22280)
* fix dict accessor

* more comprehensive fix
2024-05-14 15:06:51 +00:00
Bianca Yang
8af7c7ea5f
fix: Use safer dict accessor when computing tiers information (#22203)
change dict accessor
2024-05-08 23:32:21 +00:00
Bianca Yang
69dfe43e8a
feat: Block subscriptions if there are open invoices on the customer (#22057)
* retrieve open invoices as part of /billing loading, show warning

* small fixes

* address pr feedback

* small grammar update

* Update UI snapshots for `chromium` (2)

* Update UI snapshots for `chromium` (2)

* Update UI snapshots for `chromium` (1)

* Update UI snapshots for `chromium` (1)

---------

Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2024-05-08 10:30:53 -07:00
Bianca Yang
a266ffc60e
feat: Update tiers usage information with local org usage information (#21957)
* update tiers usage with local org usage information

* type finagling

* update addon tiers as well

* test

* Update ee/billing/billing_manager.py

* update tests

---------

Co-authored-by: Raquel Smith <raquelmsmith@users.noreply.github.com>
2024-05-07 23:25:22 +00:00
Bianca Yang
d785d8cbe2
fix: Use requests.exception.JSONDecodeError in try/except for billing service errors (#21907)
silence mypy error about exception not existing
2024-04-26 21:45:39 +00:00
Bianca Yang
5f296b44b3
fix: Adds fallback to res.text in billing error handler (#21904)
* add fallback to res.text

* lint
2024-04-26 11:56:30 -07:00
Bianca Yang
f4fe46378c
feat: Show error messages from server on billing page (#21765)
* show error messages on billing page

* some more updates

* extraneous exception and pr feedback

* Move error display into the unsubscribe modal
* Only show link to stripe if the error detail is about open invoices

* Update frontend/src/scenes/billing/billingLogic.tsx

Co-authored-by: Raquel Smith <raquelmsmith@users.noreply.github.com>

* remove opensupportform from billingLogic

---------

Co-authored-by: Raquel Smith <raquelmsmith@users.noreply.github.com>
2024-04-25 19:50:55 +00:00
Julian Bez
9576fab1e4
chore: Add Pyupgrade rules (#21714)
* Add Pyupgrade rules
* Set correct Python version
2024-04-25 08:22:28 +01:00
Julian Bez
487ca39064
chore: Enable more ruff rules (#21043) 2024-04-08 16:21:51 +01:00
Bianca Yang
376fb232ae
feat: Implement Quota Limiting Suspension Strategy (#20469)
* add db field, add automatic scoring mechanism, update billing response types

* implement score override system

* add migration file, small change

* add model fields, fix ff implementation

* add is_hipaa field to organization
* fix ff quota_limiting implementation so only not already limited orgs have limiting suspended

* update automatic limiting logic, existing tests

* update ff test

* beefing up tests

* Update query snapshots

* Update query snapshots

* Update query snapshots

* rebase upon customer score pr

* Update query snapshots

* typo fix

Co-authored-by: Raquel Smith <raquelmsmith@users.noreply.github.com>

* remove needs_save, claen up migration

* Update query snapshots

* Update query snapshots

* another set of small cleanup

* Update query snapshots

* Update query snapshots

* fix type errors

* Update query snapshots

* tests and typing

* actually fix tests

* Update query snapshots

* Update query snapshots

* Update query snapshots

* update fields to match backend

* Update query snapshots

* Update query snapshots

* Update query snapshots

* Update query snapshots

* Update query snapshots

* some pr comments

* undo migrations as they are moved to another pr

* undo model changes to organization

* Update query snapshots

* Update query snapshots

---------

Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Raquel Smith <raquelmsmith@users.noreply.github.com>
2024-03-07 10:15:11 -08:00
Ben White
11c0506bee
fix: revert #19938 (#20232) 2024-02-09 14:14:18 +00:00
Bianca Yang
879fb81d8e
feat: Don't Label Users as Quota Limited for N Days After They Exceed Their Quota (#19938)
* wip

* add tests

* fix up mypy

* Update query snapshots

* Update query snapshots

* address pr feedback

* small updates

* fix tests

* use better types and no key defaults

* fix typing

* fix up some test setup

---------

Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Raquel Smith <raquelmsmith@users.noreply.github.com>
2024-02-08 17:56:28 -08:00
Raquel Smith
037541af8e
fix: quota limiting memory usage (#20161)
* only get the team data we need

* make sure we got all the fields (with assert num queries)
2024-02-06 23:59:20 +00:00
Bianca Yang
31807262c0
fix: fix structure of group properties param in feature_enabled call (#20079)
fix structure of group properties param
2024-02-01 03:32:36 +00:00
Bianca Yang
c3623b039f
feat: use feature flag to control whether to quota limit or not (#19996)
* use feature flag to control whether to quota limit or not

* add simple test

* Update query snapshots

* fix up the feature flag activation logic

* confirm that the fixed feature flag logic works

* remove unnecessary change

* Update query snapshots

* Update query snapshots

* fix up tests

* another fix for tests

* Update query snapshots

* still fixing tests

* Update query snapshots

* pr feedback, more tests

* tune up ff enabled call, add capture check to test for quota limit changed

* i really need to run tests locally

---------

Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2024-01-31 21:37:40 +00:00
Raquel Smith
5590acbb7f
fix: rows synced doesn't exist (#19469)
* fix rows synced doesn't exist

* use default value
2023-12-21 16:49:05 +00:00
Bianca Yang
ecd525644d
feat: Update the organization customer email upon signup (#18724)
* Update the organization customer email upon signup

* Only do this is the person signing up is the owner of the org and there isn't already a
  stripe subscription associated with the org

* undo local changes that shouldn't be in prod

* small tweaks to match backend

* fix test

* Update query snapshots

* Update query snapshots

---------

Co-authored-by: Bianca Yang <bianca@posthog.com>
Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2023-11-21 10:39:37 -08:00
Raquel Smith
db82cff3e2
fix: tolerate missing rows_synced in billing response (#18695)
* tolerate missing rows_synced

* more fix
2023-11-16 15:36:29 -05:00