Show diagnostics in evaluation project (#1563)
This commit is contained in:
@@ -16,6 +16,7 @@ import { Input } from "@/components/ui/input";
|
|||||||
import { basicLocalTimeFormat, basicTimeFormat } from "@/util/timeFormat";
|
import { basicLocalTimeFormat, basicTimeFormat } from "@/util/timeFormat";
|
||||||
import { useCredentialGetter } from "@/hooks/useCredentialGetter";
|
import { useCredentialGetter } from "@/hooks/useCredentialGetter";
|
||||||
import { Artifact } from "./Artifact";
|
import { Artifact } from "./Artifact";
|
||||||
|
import { apiPathPrefix } from "@/util/env";
|
||||||
|
|
||||||
const enable_log_artifacts =
|
const enable_log_artifacts =
|
||||||
import.meta.env.VITE_ENABLE_LOG_ARTIFACTS === "true";
|
import.meta.env.VITE_ENABLE_LOG_ARTIFACTS === "true";
|
||||||
@@ -39,7 +40,7 @@ function StepArtifacts({ id, stepProps }: Props) {
|
|||||||
queryFn: async () => {
|
queryFn: async () => {
|
||||||
const client = await getClient(credentialGetter);
|
const client = await getClient(credentialGetter);
|
||||||
return client
|
return client
|
||||||
.get(`/step/${id}/artifacts`)
|
.get(`${apiPathPrefix}/step/${id}/artifacts`)
|
||||||
.then((response) => response.data);
|
.then((response) => response.data);
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -5,6 +5,7 @@ import { StepApiResponse } from "@/api/types";
|
|||||||
import { useParams, useSearchParams } from "react-router-dom";
|
import { useParams, useSearchParams } from "react-router-dom";
|
||||||
import { getClient } from "@/api/AxiosClient";
|
import { getClient } from "@/api/AxiosClient";
|
||||||
import { useCredentialGetter } from "@/hooks/useCredentialGetter";
|
import { useCredentialGetter } from "@/hooks/useCredentialGetter";
|
||||||
|
import { apiPathPrefix } from "@/util/env";
|
||||||
|
|
||||||
function StepArtifactsLayout() {
|
function StepArtifactsLayout() {
|
||||||
const [searchParams, setSearchParams] = useSearchParams();
|
const [searchParams, setSearchParams] = useSearchParams();
|
||||||
@@ -21,7 +22,7 @@ function StepArtifactsLayout() {
|
|||||||
queryFn: async () => {
|
queryFn: async () => {
|
||||||
const client = await getClient(credentialGetter);
|
const client = await getClient(credentialGetter);
|
||||||
return client
|
return client
|
||||||
.get(`/tasks/${taskId}/steps`)
|
.get(`${apiPathPrefix}/tasks/${taskId}/steps`)
|
||||||
.then((response) => response.data);
|
.then((response) => response.data);
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -6,6 +6,7 @@ import { useParams, useSearchParams } from "react-router-dom";
|
|||||||
import { PAGE_SIZE } from "../constants";
|
import { PAGE_SIZE } from "../constants";
|
||||||
import { CheckboxIcon, CrossCircledIcon } from "@radix-ui/react-icons";
|
import { CheckboxIcon, CrossCircledIcon } from "@radix-ui/react-icons";
|
||||||
import { useCredentialGetter } from "@/hooks/useCredentialGetter";
|
import { useCredentialGetter } from "@/hooks/useCredentialGetter";
|
||||||
|
import { apiPathPrefix } from "@/util/env";
|
||||||
|
|
||||||
type Props = {
|
type Props = {
|
||||||
activeIndex: number;
|
activeIndex: number;
|
||||||
@@ -27,7 +28,7 @@ function StepNavigation({ activeIndex, onActiveIndexChange }: Props) {
|
|||||||
queryFn: async () => {
|
queryFn: async () => {
|
||||||
const client = await getClient(credentialGetter);
|
const client = await getClient(credentialGetter);
|
||||||
return client
|
return client
|
||||||
.get(`/tasks/${taskId}/steps`, {
|
.get(`${apiPathPrefix}/tasks/${taskId}/steps`, {
|
||||||
params: {
|
params: {
|
||||||
page,
|
page,
|
||||||
page_size: PAGE_SIZE,
|
page_size: PAGE_SIZE,
|
||||||
|
|||||||
Reference in New Issue
Block a user