fix: update go and typesript client

This commit is contained in:
Ruben Fiszel
2024-04-18 11:06:11 +02:00
parent 1b131f310e
commit f3666ea140
5 changed files with 42 additions and 20 deletions
+6 -3
View File
@@ -9747,6 +9747,11 @@ components:
- $ref: "../../openflow.openapi.yaml#/components/schemas/OpenFlow"
- $ref: "#/components/schemas/FlowMetadata"
ExtraPerms:
type: object
additionalProperties:
type: boolean
FlowMetadata:
type: object
properties:
@@ -9762,9 +9767,7 @@ components:
archived:
type: boolean
extra_perms:
type: object
additionalProperties:
type: boolean
$ref: "#/components/schemas/ExtraPerms"
starred:
type: boolean
draft_only:
+14 -10
View File
@@ -76,16 +76,20 @@
let logViewer: Drawer
async function getStoreLogs() {
scroll = false
let res = (await JobService.getLogFileFromStore({
workspace: $workspaceStore ?? '',
path: downloadStartUrl
})) as string
downloadStartUrl = undefined
LOG_LIMIT += Math.min(LOG_INC, res.length)
loadedFromObjectStore = res + loadedFromObjectStore
let newC = truncateContent(content, loadedFromObjectStore, LOG_LIMIT)
LOG_LIMIT -= newC.indexOf('\n') + 1
if (downloadStartUrl) {
scroll = false
let res = (await JobService.getLogFileFromStore({
workspace: $workspaceStore ?? '',
path: downloadStartUrl
})) as string
downloadStartUrl = undefined
LOG_LIMIT += Math.min(LOG_INC, res.length)
loadedFromObjectStore = res + loadedFromObjectStore
let newC = truncateContent(content, loadedFromObjectStore, LOG_LIMIT)
LOG_LIMIT -= newC.indexOf('\n') + 1
} else {
console.error('No file detected to download from')
}
}
function showMoreTruncate(len: number) {
+3 -3
View File
@@ -4,11 +4,11 @@ script_dirpath="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
rm -rf "${script_dirpath}/src"
npx --yes openapi-typescript-codegen --input "${script_dirpath}/../backend/windmill-api/openapi.yaml" \
--output "${script_dirpath}/src" --useOptions \
&& sed -i '213 i \\ request.referrerPolicy = \"no-referrer\"\n' src/core/request.ts
npx --yes @hey-api/openapi-ts --input "${script_dirpath}/../backend/windmill-api/openapi.yaml" --output "${script_dirpath}/src" --useOptions
cp "${script_dirpath}/client.ts" "${script_dirpath}/src/"
cp "${script_dirpath}/s3Types.ts" "${script_dirpath}/src/"
echo "" >> "${script_dirpath}/src/index.ts"
echo 'export type { S3Object, DenoS3LightClientSettings } from "./s3Types";' >> "${script_dirpath}/src/index.ts"
echo "" >> "${script_dirpath}/src/index.ts"
echo 'export { type Base64, setClient, getVariable, setVariable, getResource, setResource, getResumeUrls, setState, getState, getIdToken, denoS3LightClientSettings, loadS3FileStream, loadS3File, writeS3File, task, runScript, runScriptAsync, waitJob, getRootJobId, setFlowUserState, getFlowUserState } from "./client";' >> "${script_dirpath}/src/index.ts"
+17 -3
View File
@@ -1,15 +1,16 @@
{
"name": "windmill-client",
"version": "1.146.0",
"version": "1.309.1",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"name": "windmill-client",
"version": "1.146.0",
"version": "1.309.1",
"license": "Apache 2.0",
"devDependencies": {
"@types/node": "^20.4.10"
"@types/node": "^20.4.10",
"typescript": "^5.4.5"
}
},
"node_modules/@types/node": {
@@ -17,6 +18,19 @@
"resolved": "https://registry.npmjs.org/@types/node/-/node-20.4.10.tgz",
"integrity": "sha512-vwzFiiy8Rn6E0MtA13/Cxxgpan/N6UeNYR9oUu6kuJWxu6zCk98trcDp8CBhbtaeuq9SykCmXkFr2lWLoPcvLg==",
"dev": true
},
"node_modules/typescript": {
"version": "5.4.5",
"resolved": "https://registry.npmjs.org/typescript/-/typescript-5.4.5.tgz",
"integrity": "sha512-vcI4UpRgg81oIRUFwR0WSIHKt11nJ7SAVlYNIu+QpqeyXP+gpQJy/Z4+F0aGxSE4MqwjyXvW/TzgkLAx2AGHwQ==",
"dev": true,
"bin": {
"tsc": "bin/tsc",
"tsserver": "bin/tsserver"
},
"engines": {
"node": ">=14.17"
}
}
}
}
+2 -1
View File
@@ -5,7 +5,8 @@
"author": "Ruben Fiszel",
"license": "Apache 2.0",
"devDependencies": {
"@types/node": "^20.4.10"
"@types/node": "^20.4.10",
"typescript": "^5.4.5"
},
"main": "dist/index.js",
"types": "dist/index.d.ts",