Adding an util action that triggers on curls

This commit is contained in:
Zoe Roux
2022-03-04 13:55:13 +01:00
parent feb14c6a1a
commit deb7a5fed1
10 changed files with 48 additions and 24 deletions
+1 -1
View File
@@ -52,7 +52,7 @@ export class Manager {
}
handlePipelineError(pipeline: Pipeline, error: Error): Observable<never> {
console.error(`Unhandled exception while trying to listen for the pipeline ${pipeline.name} (type: ${pipeline.type.toString()}).`, error)
console.error(`Unhandled exception while trying to listen for the pipeline ${pipeline.name} (type: ${pipeline.type?.toString()}).`, error)
fetch(`${process.env["WORKER_API_URL"]}/error/${pipeline.id}?WORKER_API_KEY=${process.env["WORKER_API_KEY"]}`, {
method: "POST",
body: JSON.stringify({error}),
+1
View File
@@ -111,6 +111,7 @@ export class PipelineEnv {
export const pipelineFromApi = (data: any): Pipeline => {
const type: string = data.res.action.pType;
console.log("type::", type);
return {
id: data.res.action.id,
name: data.res.action.name,
+1
View File
@@ -4,3 +4,4 @@ export { Github } from "./github"
export { Spotify } from "./spotify"
export { Discord } from "./discord"
export { Anilist } from "./anilist"
export { UtilsService } from "./utils"