Skip to content

Commit

Permalink
Update
Browse files Browse the repository at this point in the history
[ghstack-poisoned]
  • Loading branch information
clee2000 committed Jan 3, 2025
1 parent c37c312 commit 10b352b
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 74 deletions.
4 changes: 0 additions & 4 deletions torchci/components/NavBar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ import Link from "next/link";
import { useState } from "react";
import { AiFillGithub } from "react-icons/ai";
import LoginSection from "./LoginSection";
import { CHToggle } from "./UseClickhouseProvider";

const NavBarDropdown = ({
title,
Expand Down Expand Up @@ -171,9 +170,6 @@ function NavBar() {
<li style={{ padding: "0 1rem" }}>
<LoginSection></LoginSection>
</li>
<li>
<CHToggle />
</li>
</ul>
</div>
</div>
Expand Down
53 changes: 0 additions & 53 deletions torchci/components/UseClickhouseProvider.tsx

This file was deleted.

3 changes: 0 additions & 3 deletions torchci/components/WorkflowDispatcher.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ import { useRouter } from "next/router";
import { CommitApiResponse } from "pages/api/[repoOwner]/[repoName]/commit/[sha]";
import { useState } from "react";
import useSWR from "swr";
import { useCHContext } from "./UseClickhouseProvider";

const SUPPORTED_WORKFLOWS: { [k: string]: any } = {
"pytorch/pytorch": {
Expand Down Expand Up @@ -169,8 +168,6 @@ export function SingleWorkflowDispatcher({
repoName = "pytorch";
}

const useCH = useCHContext().useCH;

const { data, error } = useSWR<CommitApiResponse>(
runMoreJobsClicked && `/api/${repoOwner}/${repoName}/commit/${sha}`,
fetcher,
Expand Down
2 changes: 0 additions & 2 deletions torchci/pages/[repoOwner]/[repoName]/pull/[prNumber].tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ import CommitStatus from "components/CommitStatus";
import DrCIButton from "components/DrCIButton";
import { useSetTitle } from "components/DynamicTitle";
import ErrorBoundary from "components/ErrorBoundary";
import { useCHContext } from "components/UseClickhouseProvider";
import { PRData } from "lib/types";
import { useRouter } from "next/router";
import { IssueLabelApiResponse } from "pages/api/issue/[label]";
Expand All @@ -22,7 +21,6 @@ function CommitInfo({
repoName: string;
sha: string;
}) {
const useCH = useCHContext().useCH;
const { data: commitData, error } = useSWR<CommitApiResponse>(
sha != null ? `/api/${repoOwner}/${repoName}/commit/${sha}` : null,
fetcher,
Expand Down
21 changes: 9 additions & 12 deletions torchci/pages/_app.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ import AnnouncementBanner from "components/AnnouncementBanner";
import TitleProvider from "components/DynamicTitle";
import NavBar from "components/NavBar";
import SevReport from "components/SevReport";
import { UseCHContextProvider } from "components/UseClickhouseProvider";
import { track } from "lib/track";
import { SessionProvider } from "next-auth/react";
import type { AppProps } from "next/app";
Expand All @@ -24,17 +23,15 @@ function MyApp({ Component, pageProps }: AppProps) {
return (
<>
<SessionProvider>
<UseCHContextProvider>
<TitleProvider>
<NavBar />
<AnnouncementBanner />
<SevReport />
<div style={{ margin: "20px" }}>
<Component {...pageProps} />
<Analytics />
</div>
</TitleProvider>
</UseCHContextProvider>
<TitleProvider>
<NavBar />
<AnnouncementBanner />
<SevReport />
<div style={{ margin: "20px" }}>
<Component {...pageProps} />
<Analytics />
</div>
</TitleProvider>
</SessionProvider>
</>
);
Expand Down

0 comments on commit 10b352b

Please sign in to comment.