Skip to content

Commit f671b42

Browse files
emir-karabegicecrasher321Vikhyath Mondreti
authored andcommitted
merged improvement/connection into staging (#604)
* merged improvement/connection into staging * fix: merge conflicts and improved block path calculation * fix: removed migration * fix: removed duplicate call * fix: resolver and merge conflicts * fix: knowledge base folder * fix: settings modal * fix: typeform block * fix: parallel handler * fix: stores index * fix: tests * fix: tag-dropdown * improvement: start block input and tag dropdown * fix block id resolution + missing bracket * fix lint * fix test * works * fix * fix lint * Revert "fix lint" This reverts commit 433e2f9. --------- Co-authored-by: Vikhyath Mondreti <vikhyathvikku@gmail.com> Co-authored-by: Vikhyath Mondreti <vikhyathmondreti@Vikhyaths-MacBook-Air.local>
1 parent 7e9ccae commit f671b42

File tree

4 files changed

+19
-4
lines changed

4 files changed

+19
-4
lines changed

apps/sim/app/api/workflows/[id]/deploy/route.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ export async function POST(request: NextRequest, { params }: { params: Promise<{
139139
return createErrorResponse(validation.error.message, validation.error.status)
140140
}
141141

142-
// Get the workflow to find the user (removed deprecated state column)
142+
// Get the workflow to find the user
143143
const workflowData = await db
144144
.select({
145145
userId: workflow.userId,

apps/sim/components/ui/tag-dropdown.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ import { Serializer } from '@/serializer'
88
import { useVariablesStore } from '@/stores/panel/variables/store'
99
import type { Variable } from '@/stores/panel/variables/types'
1010
import { useWorkflowRegistry } from '@/stores/workflows/registry/store'
11-
import { useSubBlockStore } from '@/stores/workflows/subblock/store'
1211
import { useWorkflowStore } from '@/stores/workflows/workflow/store'
1312

1413
interface BlockTagGroup {

apps/sim/executor/handlers/workflow/workflow-handler.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -163,15 +163,15 @@ export class WorkflowBlockHandler implements BlockHandler {
163163

164164
logger.info(`Loaded child workflow: ${workflowData.name} (${workflowId})`)
165165

166-
// Extract the workflow state (API returns normalized data in state field)
166+
// Extract the workflow state
167167
const workflowState = workflowData.state
168168

169169
if (!workflowState || !workflowState.blocks) {
170170
logger.error(`Child workflow ${workflowId} has invalid state`)
171171
return null
172172
}
173173

174-
// Use blocks directly since API returns data from normalized tables
174+
// Use blocks directly since DB format should match UI format
175175
const serializedWorkflow = this.serializer.serializeWorkflow(
176176
workflowState.blocks,
177177
workflowState.edges || [],

apps/sim/providers/google/index.ts

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -380,7 +380,15 @@ export const googleProvider: ProviderConfig = {
380380
duration: firstResponseTime,
381381
},
382382
],
383+
<<<<<<< HEAD
383384
// Cost will be calculated in logger
385+
=======
386+
cost: {
387+
total: 0.0, // Initial estimate, updated as tokens are processed
388+
input: 0.0,
389+
output: 0.0,
390+
},
391+
>>>>>>> 34b590a10 (merged improvement/connection into staging (#604))
384392
},
385393
},
386394
logs: [],
@@ -776,6 +784,14 @@ export const googleProvider: ProviderConfig = {
776784
firstResponseTime,
777785
iterations: iterationCount + 1,
778786
timeSegments,
787+
<<<<<<< HEAD
788+
=======
789+
},
790+
cost: {
791+
total: (tokens.total || 0) * 0.0001, // Estimate cost based on tokens
792+
input: (tokens.prompt || 0) * 0.0001,
793+
output: (tokens.completion || 0) * 0.0001,
794+
>>>>>>> 34b590a10 (merged improvement/connection into staging (#604))
779795
},
780796
// Cost will be calculated in logger
781797
},

0 commit comments

Comments
 (0)