Commit Graph

30 Commits

Author SHA1 Message Date
Gergő Jedlicska baeeace9d5 gergo/mailchimpOnboarding (#2098)
* feat: add mailchimp onboarding

* feat: add mailchimp onboarding journey

* feat: add mailchimp helm chart secrets

* refactor: move mailchimp id-s to plain helm values
2024-03-01 15:18:35 +01:00
Gergő Jedlicska b84b24467d feat: make automate app registration optional based on the existence of the url config (#2094)
* feat: make automate app registration optional based on the existence of the url config

* docs: add back automate env var with docs

* feat: app redirect url application side override

* chore: cleanup
2024-02-29 13:32:29 +01:00
Kristaps Fabians Geikins 5cd573355d feat(server): ability for apps to create new app tokens (#1942)
* /graphql endpoint fix

* app token creation seems to be done

* added tests

* more tests

* cleaned up TS annotations

* CR cleanup

* TS type fixes

* test fixes
2024-01-09 11:58:38 +02:00
Kristaps Fabians Geikins c67f6d9c92 feat: clearer email verification flow & related error messages (#1904)
* fix: fe2 auth error page + various minor UI bugs

* clean up & reporting failing email to fe

* new mutation to resend verification as guest

* email text updates

* fixing issues brought up by agi

* more text fixes

* swapping out space-XXX for gap-XXX
2023-12-15 13:09:26 +02:00
andrewwallacespeckle 76cbcef4e6 Feature - FE2 - Developer Settings (#1822)
* WIP Developer Settings

* Access Tokens

* scopes load fix

* mapping to correct struct

* Updates to Application

* Update to apps.js to fix scopes error

* Application table done

* Token confirmation done.

* Application Success

* Fix ts

* Darkmode fixes

* Responsive fix

* Fixes for PR

* Pass size prop to Editable Avatar

* Updates from PR comments

* Section Header - TS Types

* Add Typeguard to Delete Dialog

* Add Description to scopes query

* minor type guard fix

* edit application cache update fix

* Fix Dialog Expansion

* Rename mutations to correct casing

* Remove unneeded import for defineProps

---------

Co-authored-by: Kristaps Fabians Geikins <fabis94@live.com>
2023-10-26 12:51:05 +01:00
Kristaps Fabians Geikins d8640bbdc9 feat(ui-components): tags input component (#1810)
* FormSelectBase converted to generic Vue component

* WIP tags w/ custom input box

* a11y works

* proper tags wrapping

* errors/validation/icon styling

* styling fixes

* autocomplete item resolution

* feat: configurable tags input

* various fixes

* moved avatar components to ui-components

* replaced avatar in frontend-2 w/ new ui-components exports

* new icon loader

* added validation support for avatar editor

* updated fe-2 to use new avatar editor api

* disabled support for avatar editor

* more fixes and improvements

* attempted preview-service fix

* attempted preview-service fix

* added story

* linting fix

* more fixes

* server test fix
2023-10-16 14:10:41 +03:00
Dimitrie Stefanescu 802f3c9924 fix(fe2): newsletter changes 2023-06-22 16:35:49 +01:00
Dimitrie Stefanescu 56ea1bc843 feat(server): cleaned up boilerplate & using injected ref for consent tracking in fe register panel. 2023-06-16 15:57:33 +01:00
Dimitrie Stefanescu d5bb3b9923 feat(server): mailchimp plumbing 2023-06-16 13:34:04 +01:00
Dimitrie Stefanescu e72ed56eee feat(fe2): wip newsletter registration consent box 2023-06-15 17:52:25 +01:00
Iain Sproat 4d01e13a84 feat(structured logging) (#1242)
* Revert "Revert structured logging 2 (#1240)"
This reverts commit 78ecaeffcb.
* Logging should not be bundled into core shared directory
* making sure observability stuff isnt bundled into frontend


Co-authored-by: Kristaps Fabians Geikins <fabis94@live.com>
2022-12-06 11:51:18 +00:00
Iain Sproat 78ecaeffcb Revert structured logging 2 (#1240)
* Revert "'@' shortcut must come after it is configured in bootstrap (#1239)"

This reverts commit 967329473f.

* Revert "Structured logging (attempt 2) (#1234)"

This reverts commit 444d2ca7dd.
2022-12-05 15:46:09 +00:00
Iain Sproat 444d2ca7dd Structured logging (attempt 2) (#1234)
* Revert "Revert "feat(structured logging): implements structured logging for backend (#1217)" (#1227)"

This reverts commit 63e6581162.

* Use pino-http instead of express pino logger
* Use correct reference to knex and do not instantiate HttpLogger prematurely
* Adds missing dependency for pino to webhook-service
* Do not instantiate middleware when passed to express
* Refactor to move logging into shared
* Copy shared packages into dockerfiles
* Build shared workspace in docker build-stage for fileimport & webhook
2022-12-05 14:49:52 +00:00
Iain Sproat a537d34dcc Rate limit all endpoints (#1213)
* Demonstration of bug to test when middleware added
- Adding middleware, even no-op, causes test to fail

* Make middleware async, but introduce delay.
Revert test back to original.

* Revert tests

* Add a 1ms sleep to the test to reduce likelihood of flakiness

* Rate limiting on all express endpoints using middleware

* Adds all configuration for existing rate limited endpoints

* It is helpful to add the package to yarn first

* Implements respectsLimits using Redis rate limiter

* Fix for test `Should rate-limit user creation`
- if rate limit error, post to `/auth/local/register` will return a 429 status code

* All rate limiting provided by new ratelimiter.ts

* Consolidate typescript interfaces

* Amend signature of function to require source to be passed in, and not try to guess it from the request

* Rename respectsLimits to isWithinRateLimits

* Throw within catch of Promise

* Replace rejectsRequestWithRatelimitStatusIfNeeded throughout code

* Sending rate limit response should deal with other types of error
- Sentry notified of the error

* Express middleware rate limits by a 3 second burst or a daily rate
- Provide action when generating 429 response

* Prevent DOS of Redis

* Add 'Retry-After' for all cases when responding with 429 status code
- default of 1 day, but dynamic based on available information

* Generate rate limiters once, on init
- Improved and consistent handling of exit from functions
- fixed environment variable names

* WIP Refactor rate limiting setup

Co-authored-by: Iain Sproat <iainsproat@users.noreply.github.com>

* WIP: fixed references, now runs but tests fail

* Use getSourceFromRequest where possible

* WIP: unit tests for rate limiter

* Unit tests for ratelimiter

* feat(IFC): WIP IFC parser improvements

* Revert "feat(IFC): WIP IFC parser improvements"

This reverts commit 093089a2c4.

* refactor authz, rate limiting middleware to global

Co-authored-by: Kristaps Fabians Geikins <fabis94@users.noreply.github.com>
Co-authored-by: Iain Sproat <iainsproat@users.noreply.github.com>

* invites tests fix

* fix(server ratelimiter): export public interfaces

* Unit test for rate limiter use in memory rate limiter
- in memory rate limiter is configured with zero limit by default

* Fixed #1219 (#1221)

* WIP: improve auth test for rate limiting user creation

* ci(circleci config): publishing was broken when main branch was tagged (i.e. for releases) (#1224)

* Gitignore CPU profiles

* All tests are  now passing locally

* Fixed an issue in the frontend which was causing the views not to work. Fixed an issue with object selection camera animation where the dolly lerp factor was much too high for smooth animation (#1225)

* feat(structured logging): implements structured logging for backend (#1217)

* each log line is a json object
* structured logging allows logs to be ingested by machines and the logs to be indexed and queried addresses #1105
* structured logging allows arbitrary properties to be appended to each log line, and ingestion of logs to remain robust
* Structured logging provided by `pino` library
* Add `express-pino-logger` dependency
* Remove `debug`, `morgan`, and `morgan-debug` and replace with structured logging
* `console.log` & `console.error` replaced with structured logging in backend
* Remove `DEBUG` environment variable and replace with `LOG_LEVEL`
- Note that there is a test which reads from a logged line on `stdout`. This is not robust, it would be better to use the childProcess.pid to look up the port number.
* Log errors at points we explicitly send error to Sentry
* Amend indentation of a couple of log messages to align indentation with others

* Revert "feat(structured logging): implements structured logging for backend (#1217)" (#1227)

This reverts commit 84cb74e8b3.

* Move error to core/errors
- augmented typescript types moved to type-augmentations

* Added a missing wait in the screenshot generation loop (#1228)

* refactor(server rest api): remove duplicate rate limit requests

* feat(server rate limits): increase rate limits for the upload endpoints

* chore(server rate limits): final cleanup

Co-authored-by: Gergő Jedlicska <gergo@jedlicska.com>
Co-authored-by: Iain Sproat <iainsproat@users.noreply.github.com>
Co-authored-by: Dimitrie Stefanescu <didimitrie@gmail.com>
Co-authored-by: Kristaps Fabians Geikins <fabis94@users.noreply.github.com>
Co-authored-by: Kristaps Fabians Geikins <fabis94@live.com>
Co-authored-by: Alexandru Popovici <alexandrupopoviciioan@gmail.com>
2022-11-29 17:06:11 +01:00
Iain Sproat 63e6581162 Revert "feat(structured logging): implements structured logging for backend (#1217)" (#1227)
This reverts commit 84cb74e8b3.
2022-11-25 16:57:28 +00:00
Iain Sproat 84cb74e8b3 feat(structured logging): implements structured logging for backend (#1217)
* each log line is a json object
* structured logging allows logs to be ingested by machines and the logs to be indexed and queried addresses #1105
* structured logging allows arbitrary properties to be appended to each log line, and ingestion of logs to remain robust
* Structured logging provided by `pino` library
* Add `express-pino-logger` dependency
* Remove `debug`, `morgan`, and `morgan-debug` and replace with structured logging
* `console.log` & `console.error` replaced with structured logging in backend
* Remove `DEBUG` environment variable and replace with `LOG_LEVEL`
- Note that there is a test which reads from a logged line on `stdout`. This is not robust, it would be better to use the childProcess.pid to look up the port number.
* Log errors at points we explicitly send error to Sentry
* Amend indentation of a couple of log messages to align indentation with others
2022-11-25 16:05:05 +00:00
Gergő Jedlicska 908bbfb937 Gergo/file imports hotfix (#1025)
* fix(server): fix 'speckle:error(s)' mismatching naming

* fix(frontend): add mtl as documented file import format, fix missing computed prop

* fix(fileimports): specklepy operations.send shouldn't use local cache for sending

fixes #1017

* obj import skip using default cache
2022-09-23 13:20:53 +02:00
Kristaps Fabians Geikins da9224a069 feat: server & stream invites rework
feat: server & stream invites rework

Co-authored-by: Dimitrie Stefanescu <didimitrie@gmail.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2022-07-19 13:01:19 +03:00
Dimitrie Stefanescu 88be9dad60 fix(apps): selects all relevant fields in get all apps query (inc. trustByDefault) 2022-05-11 10:39:44 +01:00
Gergő Jedlicska 4812d53aa4 Merge branch 'main' of github.com:specklesystems/speckle-server into eslintAllTheThings 2022-04-04 22:06:53 +02:00
Fabians 4699e6794c reformatting again for 88 width 2022-04-04 19:21:28 +03:00
Fabians 1c7436e7ff extra prefer-const & object-shorthand 2022-04-04 19:00:24 +03:00
Kristaps Fabians Geikins 16da51b96a fix(server): awaiting revokeRefreshToken to ensure it fails within request scope (#652)
* fix(server): awaiting revokeRefreshToken to ensure it fails within request scope

* removed unnecessary error throw
2022-04-04 17:00:27 +03:00
Gergő Jedlicska d53df11f77 style(server): fix all eslint errors and break the tests 2022-03-31 14:18:44 +02:00
Fabians abe6d5e086 chore: re-formatted everything with prettier 2022-03-30 12:54:24 +03:00
Gergő Jedlicska 569b4688fa style(all): reformat with print width 88 2022-03-29 19:46:49 +02:00
Fabians aa5e94d640 chore: reformatting everything with prettier 2022-03-29 17:12:31 +03:00
Cristian Balas 9329265708 Upgrade dependencies (#577) 2022-02-07 14:04:26 +02:00
Dimitrie Stefanescu c452b91aa6 fix(server): checks for matching appIds in acces token exchange service 2021-04-29 21:28:28 +01:00
Dimitrie Stefanescu cd95c28939 refactor(global): restructures repo with lerna 2021-01-03 13:35:53 +02:00