* [json-rpc] Fix encoding of watchImageBuildLogs data to number[]
Because json-rpc can't handle complex objects like UInt8Array properly.
Conversion is done using "Array.from(UInt8Array)" and "new UInt8Array(data)"
* [dashboard] Fix "workspaceId is required" errors
* Review suggestions
Co-authored-by: Filip Troníček <filip@gitpod.io>
---------
Co-authored-by: Filip Troníček <filip@gitpod.io>
* [supervisor] Make sure we read the last chunk of message when task is closed
* [server, dashboard] Prebuild logs: stream as UInt8Array instead of string, and make sure we send the last chunk before closing the response
* Make log buffer more efficient
Merging done with `TypedArray.prototype.set()` as suggested here:
https://stackoverflow.com/a/73074813/10199319
* [dashboard] PrebuildTaskTab: use hash(err.message) as toastId
* [server] prebuild logs: Only call res.end after a timeout, so clients can continue reading from the stream
* [dashboard] prebuild logs emitter: If we receive code "200", forward prefixChunk, and stop streaming
* fixup! [dashboard] PrebuildTaskTab: use hash(err.message) as toastId
---------
Co-authored-by: Filip Troníček <filip@gitpod.io>
* Start prebuilds on started workspaces
* Fix circl dep
* move out to workspace creation
* Do it in the workspace service
* remove webhook tests
* remove webhook handling code
* Revert "remove webhook handling code"
This reverts commit d7c4550ec6b16091344607bfeee234b1f0e5705b.
* Anotate new setups with an `activity-based` activation strategy
* Update tests
* Alert banner
* add correct changelog path
* fix tests
* Remove code for registering prebuilds
* Still pass prebuild preconditions in order to run
* Re-add link to prebuild history of a repo
* Rename to trigger strategy and change project activity indicator
* redirect in the offline case
* [public-api] generate noise
* [server] Refactor Prebuild resolution to happen in a single place
* [dashboard, api] Show Prebuild details
* fixup! [server] Refactor Prebuild resolution to happen in a single place
* [bridge] Revive Prebuild QUEUED state: it's everything before running
* [server] Fix dead-end for streaming logs when starting too early
* [dashboard] Adds SHA + duration, fix re-rendering when prebuildId changes, and uses the new/old streaming logic
WIP because still has the "duplicate (sometimes triple!) logs" react re-rendering issue
* Prevent unnecessary re-renders of task output
* remove double-comment
* Duration display improvements
* Properly dismiss toasts and render durations
* Remove SHA from prebuild list
* Clean up and implement the `reset` event for workspace logs
* fix comment
* Tiny cleanup
---------
Co-authored-by: Filip Troníček <filip@gitpod.io>
* Use `__Host-` prefix for cookie
* Fix tests
* Remove domain from cookie
* Fix logout
* remove unused fn
* fix user logout properly
* [server] Make domain-only cookie work for GitHub oauth login
... by adding additional step so we can set the cookie for the base domain only
* test: fix by redirecting before callbacl/authorize
* [server] SessionHandler: Allow to login with both primary and secondary cookies
* [server] Clear 2ndary cookie on logout
* Fix filtering cookie values when primary cookie is empty
* Fix logouts
* Fix tests
---------
Co-authored-by: Gero Posmyk-Leinemann <gero@gitpod.io>
* [JetBrains] add more integration tests
* Add deps
* Add in workspace JetBrains integration test
* Support papi
* fixup
* Test succeed
* remove unnecessary code
* Fixup
* Remove warmup TODO item
* Add doc for sh file
* Increase timeout and make it run in parallel
* Use empty
* fixup
* Sleep
* db wait
* speed up
* [yarn] Bump @grpc/grpc-js to 1.10.8 and @authzed/authzed-node to 0.15.0
* [server] SpiceDB: explicit re-try on UNAVAILABLE
We tried to configured this inside the SpiceDBClientProvider already, but somehow it still surfaced.
* [server, bridge] Configure "grpc.dns_min_time_between_resolutions_ms" to be 2s instead of 30s
* necessary changes for github to comply
* try automating the popup
* Simplify with an effect
* try redirecting
* try redirecting somewhere authenticated
* pass the original search and hash
* Fix `TypeError: setting getter-only property "searchParams"`
* allow scm redirect
* Auomatically redirect git after signin
* quickstart the quickstart page
* Use unauthed router for quickstart
* Include the leading slash
* Redirect to new WS page on sucess
* Do not require OIDC signing, allow git login
* Do not be too clever around git auth
* Clear `message` from search params on success
* 🐬
* Retain hash when clearing message
* don't use URL.parse
It does not work in all browsers
* Make sure we properly handle all errors on `/quickstart`
* Revert ssologinform changes
* Tidy up
* Re-enable first-class git auth
* Do not require git api response for scm auth
* Enable logging in with SCM properly
* keep pathname for redirect functions
* Remove routing in multiple places
* Document empty org
* Allow `quickstart/`
* Use react's location
* Group routes registerings
* Try registering router in the query error boundary
* Try not using location 🤷♂️
* Revert "Try registering router in the query error boundary"
This reverts commit 228c1606d77550fab24089557aa7b4eed48257b4.
* Revert "Try not using location 🤷♂️"
This reverts commit 28ca3574820f958cd6936e1627662f376348408d.
* Make sure to load user first before acting on sideeffect
* Reapply "Try registering router in the query error boundary"
This reverts commit a73ac8fc732fa231fefa8ba9190451642fb55185.
* Fix position for only rendering when not authed
* do not retry auth fetch calls
* Do not cache the query
* Remove user cache on login begin
* Do not allow empty auths
* Try refetching auth providers when authed
* Try no queries
* [server] allow to update org settings
* [dashboard] allow org-level editor restriction
* Org owned user's editor settings should be restricted too
* Never pass empty array
* Fix user onboarding editors always loading
* Fix incorrect loading state of ide versions
* Show available editors for org owned users
* Update components/dashboard/src/user-settings/SelectIDE.tsx
Co-authored-by: Filip Troníček <filip@gitpod.io>
* Address feedback
* Revert version pin on user settings page
* Add json rpc checking
---------
Co-authored-by: Filip Troníček <filip@gitpod.io>
* Add repo migrate coachmark
* Public API: `coachmarksDismissals`
* Early exit for new signups
* Try to inject dismissal to link
* Dismiss on path visit
* Align to the left
* Dismiss on trigger
* Simplify show logic
Co-authored-by: Siddhant Khare <siddhant@gitpod.io>
* Consider `showPrebuildsMenuItem` when hiding projects
* update tests
* Adjust date for testing
* fix projects hide condition
* Fix repo link id ref
* Do not dismiss accidentally
* up-date
* move prebuild detail to correct folder
* Make sure errors are displayed properly for prebuilds list
* don't throw
* Report dismiss
---------
Co-authored-by: Siddhant Khare <siddhant@gitpod.io>
* Update spicedb schema
* SpiceDB gen code
* [server] add collaborator
* Update papi
* Dashboard
* nit
* Complete TODOs
* server dataops pass teamId
* Add test cases for collaborator's PAT and cookie API fetch
* Add test case description
* remove unnecessary export
* Redirect to dashboard after join an org
* Hide settings for collaborator
* dataops join via oidc should be collaborator
* Fix test
* Goes back to /workspaces
* [dashboard] remove unused service mock
* [dashboard] use `GetAuthenticatedUser` instead of `getLoggedInUser`
* fixup: override workspaceAutostartOptions
also fix toDurationString call
* fixup: move `isOnboardingUser` to dashboard
* fixup: move getProfile from protocol to common
* fixup fromWorkspaceAutostartOption
* move getPrimaryEmail to common and clean up
* rm getProfile from protocol, use ProfileDetails
* fixup missing leeway dependencies
* fix getPrimaryEmail
* fix resetting workspace timeout
* [gitpod-db] remove dependency to `@gitpod/public-api-common`
* cleanup BUILD.yaml
* [papi] add user.proto and GetAuthenticatedUser
* [papi] (generate.sh) Run end-of-file-fixer
* rename to EditoSettings
* clean up proto
* fix import
* update WorkspaceTimeoutSettings
* fix typo
* update WorkspaceTimeoutSettings
* clarify User.name is full name in doc line