Commit a39cb509 authored by Yakubov, Sergey's avatar Yakubov, Sergey
Browse files

Merge branch 'fix-galaxy-update-errors' into '132-update-galaxy-version'

Fix conflicts with upstream Galaxy

See merge request !109
parents 1ae13009 d7deaa74
Loading
Loading
Loading
Loading
Loading
+62 −3
Original line number Diff line number Diff line
@@ -2934,6 +2934,23 @@ export interface paths {
        patch?: never;
        trace?: never;
    };
    "/api/jobs/{job_id}/finish": {
        parameters: {
            query?: never;
            header?: never;
            path?: never;
            cookie?: never;
        };
        get?: never;
        /** Finished a job regardless of execution status (ie early job finish) */
        put: operations["finish_job_api_jobs__job_id__finish_put"];
        post?: never;
        delete?: never;
        options?: never;
        head?: never;
        patch?: never;
        trace?: never;
    };
    "/api/jobs/{job_id}/inputs": {
        parameters: {
            query?: never;
@@ -8123,9 +8140,8 @@ export interface components {
            | "setting_metadata"
            | "failed_metadata"
            | "deferred"
/** ndip_todo: is this a right place?      */
            | "stopped"
            | "discarded";
            | "discarded"
            | "stopped";
        /** DatasetStorageDetails */
        DatasetStorageDetails: {
            /**
@@ -28239,6 +28255,49 @@ export interface operations {
            };
        };
    };
    finish_job_api_jobs__job_id__finish_put: {
        parameters: {
            query?: never;
            header?: {
                /** @description The user ID that will be used to effectively make this API call. Only admins and designated users can make API calls on behalf of other users. */
                "run-as"?: string | null;
            };
            path: {
                job_id: string;
            };
            cookie?: never;
        };
        requestBody?: never;
        responses: {
            /** @description Successful Response */
            200: {
                headers: {
                    [name: string]: unknown;
                };
                content: {
                    "application/json": boolean;
                };
            };
            /** @description Request Error */
            "4XX": {
                headers: {
                    [name: string]: unknown;
                };
                content: {
                    "application/json": components["schemas"]["MessageExceptionModel"];
                };
            };
            /** @description Server Error */
            "5XX": {
                headers: {
                    [name: string]: unknown;
                };
                content: {
                    "application/json": components["schemas"]["MessageExceptionModel"];
                };
            };
        };
    };
    get_inputs_api_jobs__job_id__inputs_get: {
        parameters: {
            query?: never;
+1 −1
Original line number Diff line number Diff line
@@ -107,8 +107,8 @@ export const STATES: StateMap = {
    },
    /** the job has been manually stopped */
    stopped: {
        text: "This job was stopped manually.",
        status: "stopped",
        text: "This job was stopped manually.",
        icon: "stop-circle",
    },
    /** the dataset is not yet loaded in the UI. This state is only visual and transitional, it does not exist in the database. */
+7 −9
Original line number Diff line number Diff line
@@ -36,17 +36,15 @@ export async function deleteContent(
* Stops job and marks it as complete.
*/
export async function stopJob(jobId: string) {
// todo: gcage
//    const { data, error } = await GalaxyApi().PUT("api/jobs/${job_id}/finish", {
//        params: { path: { job_id: jobId, theme } },
//    });
    const { data, error } = await GalaxyApi().PUT("/api/jobs/{job_id}/finish", {
       params: { path: { job_id: jobId } },
    });


//    if (error) {
//        rethrowSimple(error);
//    }
//    return data;
    return {}
    if (error) {
        rethrowSimple(error);
    }
    return data;
}


+0 −8
Original line number Diff line number Diff line
@@ -77,14 +77,6 @@ function updateConsoleOutputs(output) {
            stderr_text.value += output.stderr;
        }
    }
    if (jobIsTerminal.value) {
        if (newJob.tool_stdout) {
            stdout_text.value = newJob.tool_stdout;
        }
        if (newJob.tool_stderr) {
            stderr_text.value = newJob.tool_stderr;
        }
    }
}

function filterMetadata(jobMessages) {
+47 −35
Original line number Diff line number Diff line
@@ -10,7 +10,6 @@ import { createDatasetCollection } from "components/History/model/queries";

import { UploadQueue } from "@/utils/upload-queue.js";

import { collectionBuilder } from "./builders.js";
import { defaultModel } from "./model.js";
import { COLLECTION_TYPES, DEFAULT_FILE_NAME, hasBrowserSupport } from "./utils";

@@ -60,7 +59,7 @@ const props = defineProps({
    },
    lazyLoad: {
        type: Number,
        default: 50,
        default: 150,
    },
    listDbKeys: {
        type: Array,
@@ -74,10 +73,18 @@ const props = defineProps({
        type: String,
        default: "",
        required: false,
    }
    },
    disableFooter: {
        type: Boolean,
        default: false,
    },
    emitUploaded: {
        type: Boolean,
        default: false,
    },
});

const emit = defineEmits(["dismiss", "progress", "updateCollectionName"]);
const emit = defineEmits(["dismiss", "progress", "uploaded", "updateCollectionName"]);

const collectionType = ref("list");
const counterAnnounce = ref(0);
@@ -164,6 +171,7 @@ function eventAnnounce(index, file) {

/** Populates collection builder with uploaded files */
function eventBuild() {
    try {
        const Galaxy = getGalaxyInstance();
        const models = {};
        uploadValues.value.forEach((model) => {
@@ -192,6 +200,9 @@ function eventBuild() {
            options: {}
        };
        createDatasetCollection({ id: Galaxy.currHistoryPanel.model.id }, queryBody);
    } catch (err) {
        console.error(err)
    }
    counterRunning.value = 0;
    eventReset();
    emit("dismiss");
@@ -435,8 +446,8 @@ defineExpose({
                    :file-name="uploadItem.fileName"
                    :file-size="uploadItem.fileSize"
                    :info="uploadItem.info"
                    :list-extensions="isCollection ? null : listExtensions"
                    :list-db-keys="isCollection ? null : listDbKeys"
                    :list-extensions="!isCollection && listExtensions.length > 1 ? listExtensions : null"
                    :list-db-keys="!isCollection && listDbKeys.length > 1 ? listDbKeys : null"
                    :percentage="uploadItem.percentage"
                    :space-to-tab="uploadItem.spaceToTab"
                    :status="uploadItem.status"
@@ -453,7 +464,7 @@ defineExpose({
            </div>
            <input ref="uploadFile" type="file" :multiple="multiple" @change="addFiles($event.target.files)" />
        </UploadBox>
        <div class="upload-footer text-center">
        <div v-if="!disableFooter" class="upload-footer text-center">
            <span v-if="isCollection" class="upload-footer-title">Collection:</span>
            <UploadSelect
                v-if="isCollection"
@@ -482,6 +493,7 @@ defineExpose({
                placeholder="Select Reference"
                @input="updateDbKey" />
        </div>
        <slot name="footer" />
        <div class="upload-buttons d-flex justify-content-end">
            <BButton id="btn-local" :disabled="!enableSources" @click="singleFileUpload()">
                <FontAwesomeIcon icon="fa-laptop" />
Loading