jupyterlab-slurm
Version:
A JupyterLab extension to interface with the Slurm workload manager.
41 lines (40 loc) • 1.23 kB
TypeScript
import { Component } from 'react';
import { AlertProps } from 'react-bootstrap';
import { FileBrowser } from '@jupyterlab/filebrowser';
declare namespace types {
type JobAction = 'kill' | 'hold' | 'release';
type JobStatus = 'sent' | 'received' | 'error';
type RequestStatusTable = Map<string, JobStatus>;
type Alert = AlertProps & {
message: string;
};
type Props = {
filebrowser: FileBrowser;
serverRoot: string;
user: string;
};
type State = {
alerts: Alert[];
jobSubmitModalVisible: boolean;
jobSubmitError?: string;
jobSubmitDisabled?: boolean;
processingJobs: boolean;
userOnly: boolean;
reloading: boolean;
};
}
export default class SlurmManager extends Component<types.Props, types.State> {
readonly JOBID_IDX = 0;
readonly USER_IDX = 3;
private requestStatusTable;
constructor(props: types.Props);
private toggleUserOnly;
private showJobSubmitModal;
private hideJobSubmitModal;
private addAlert;
private makeJobRequest;
processSelectedJobs(action: types.JobAction, rows: string[][]): void;
private submitJob;
render(): JSX.Element;
}
export {};