Skip to content

Commit b2cc800

Browse files
committed
Merge remote-tracking branch 'origin/main' into ft/bitbucket-files-not-found
2 parents af1d5f6 + 42a0293 commit b2cc800

File tree

40 files changed

+112
-70
lines changed

40 files changed

+112
-70
lines changed

components/blobserve/leeway.Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
# Licensed under the GNU Affero General Public License (AGPL).
33
# See License.AGPL.txt in the project root for license information.
44

5-
FROM cgr.dev/chainguard/wolfi-base:latest@sha256:3fb2c86d005ec60f0335ff4b7678480da78014fa9e6432436a9bfd9886f71dea
5+
FROM cgr.dev/chainguard/wolfi-base:latest@sha256:28f57f6a9fb2478f3a3dd160794831bd0099ec92d0d7b81cd203fae67bcb5339
66

77
# Ensure latest packages are present, like security updates.
88
RUN apk upgrade --no-cache \

components/content-service/leeway.Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
# Licensed under the GNU Affero General Public License (AGPL).
33
# See License.AGPL.txt in the project root for license information.
44

5-
FROM cgr.dev/chainguard/wolfi-base:latest@sha256:3fb2c86d005ec60f0335ff4b7678480da78014fa9e6432436a9bfd9886f71dea
5+
FROM cgr.dev/chainguard/wolfi-base:latest@sha256:28f57f6a9fb2478f3a3dd160794831bd0099ec92d0d7b81cd203fae67bcb5339
66

77
# Ensure latest packages are present, like security updates.
88
RUN apk upgrade --no-cache \

components/dashboard/leeway.Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
# Licensed under the GNU Affero General Public License (AGPL).
33
# See License.AGPL.txt in the project root for license information.
44

5-
FROM cgr.dev/chainguard/wolfi-base:latest@sha256:3fb2c86d005ec60f0335ff4b7678480da78014fa9e6432436a9bfd9886f71dea as compress
5+
FROM cgr.dev/chainguard/wolfi-base:latest@sha256:28f57f6a9fb2478f3a3dd160794831bd0099ec92d0d7b81cd203fae67bcb5339 as compress
66

77
RUN apk add brotli gzip
88

components/dashboard/src/AppNotifications.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ import { useOrgBillingMode } from "./data/billing-mode/org-billing-mode-query";
2020
import { Organization } from "@gitpod/public-api/lib/gitpod/v1/organization_pb";
2121

2222
const KEY_APP_DISMISSED_NOTIFICATIONS = "gitpod-app-notifications-dismissed";
23-
const PRIVACY_POLICY_LAST_UPDATED = "2023-12-20";
23+
const PRIVACY_POLICY_LAST_UPDATED = "2024-10-01";
2424

2525
interface Notification {
2626
id: string;

components/dashboard/src/Login.tsx

Lines changed: 33 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,26 @@ export function hasLoggedInBefore() {
3737
return GitpodCookie.isPresent(document.cookie);
3838
}
3939

40+
const SEGMENT_SEPARATOR = "/";
41+
const getContextUrlFromHash = (input: string): URL | undefined => {
42+
if (typeof URL.canParse !== "function") {
43+
return undefined;
44+
}
45+
if (URL.canParse(input)) {
46+
return new URL(input);
47+
}
48+
49+
const chunks = input.split(SEGMENT_SEPARATOR);
50+
for (const chunk of chunks) {
51+
input = input.replace(`${chunk}${SEGMENT_SEPARATOR}`, "");
52+
if (URL.canParse(input)) {
53+
return new URL(input);
54+
}
55+
}
56+
57+
return undefined;
58+
};
59+
4060
type LoginProps = {
4161
onLoggedIn?: () => void;
4262
};
@@ -49,10 +69,19 @@ export const Login: FC<LoginProps> = ({ onLoggedIn }) => {
4969
const enterprise = !!authProviders.data && authProviders.data.length === 0;
5070

5171
useEffect(() => {
52-
if (urlHash.length > 0) {
53-
const url = new URL(urlHash);
54-
setHostFromContext(url.host);
55-
setRepoPathname(url.pathname);
72+
try {
73+
if (urlHash.length > 0) {
74+
const url = new URL(urlHash);
75+
setHostFromContext(url.host);
76+
setRepoPathname(url.pathname);
77+
}
78+
} catch (error) {
79+
// hash is not a valid URL, try to extract the context URL when there are parts like env vars or other prefixes
80+
const contextUrl = getContextUrlFromHash(urlHash);
81+
if (contextUrl) {
82+
setHostFromContext(contextUrl.host);
83+
setRepoPathname(contextUrl.pathname);
84+
}
5685
}
5786
}, [urlHash]);
5887

components/dashboard/src/menu/Menu.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,7 @@ const UserMenu: FC<UserMenuProps> = ({ user, className, withAdminLink, withFeedb
200200
},
201201
{
202202
title: "Docs",
203-
href: "https://www.gitpod.io/docs/",
203+
href: "https://www.gitpod.io/docs/introduction",
204204
target: "_blank",
205205
rel: "noreferrer",
206206
},

components/dashboard/src/workspaces/Workspaces.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,7 @@ const WorkspacesPage: FunctionComponent = () => {
188188
<h3 className="text-lg font-semibold text-pk-content-primary">Documentation</h3>
189189
<div className="flex flex-col gap-1 w-fit">
190190
<a
191-
href="https://www.gitpod.io/docs"
191+
href="https://www.gitpod.io/docs/introduction"
192192
target="_blank"
193193
rel="noopener noreferrer"
194194
className="text-sm text-pk-content-primary items-center gap-x-2 flex flex-row"

components/ee/agent-smith/leeway.Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55

66

7-
FROM cgr.dev/chainguard/wolfi-base:latest@sha256:3fb2c86d005ec60f0335ff4b7678480da78014fa9e6432436a9bfd9886f71dea
7+
FROM cgr.dev/chainguard/wolfi-base:latest@sha256:28f57f6a9fb2478f3a3dd160794831bd0099ec92d0d7b81cd203fae67bcb5339
88

99
RUN apk add --no-cache git bash ca-certificates
1010
COPY components-ee-agent-smith--app/agent-smith /app/

components/gitpod-cli/cmd/docs.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ import (
99
)
1010

1111
// URL of the Gitpod documentation
12-
const DocsUrl = "https://www.gitpod.io/docs"
12+
const DocsUrl = "https://www.gitpod.io/docs/introduction"
1313

1414
var docsCmd = &cobra.Command{
1515
Use: "docs",

components/gitpod-protocol/src/util/parse-workspace-id.spec.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,5 +81,9 @@ export class ParseWorkspaceIdTest {
8181
const actual = matchesNewWorkspaceIdExactly("moccasin-ferret-15599b3");
8282
expect(actual).to.be.false;
8383
}
84+
@test public matchesWorkspaceIdExactly_new_negative_empty() {
85+
const actual = matchesNewWorkspaceIdExactly(undefined);
86+
expect(actual).to.be.false;
87+
}
8488
}
8589
module.exports = new ParseWorkspaceIdTest();

0 commit comments

Comments
 (0)