-
Notifications
You must be signed in to change notification settings - Fork 11
Open
Description
Getting these Jason decode errors while using sync_render tranform. It works locally with small amounts of items, but with ~10k items there may be a chunking issue?
sync_render(conn, params, query,
replica: :full,
transform: fn
%{"headers" => %{"operation" => "delete"}} = msg ->
msg
msg ->
Map.update!(msg, "value", &Map.put(&1, "path", construct_full_url(&1)))
end
)2025-10-18T06:25:09.851 app[2860310b6077e8] sjc [info] 06:25:09.851 request_id=GG-B0ANU58ozmvoAASDx [error] ** (Jason.DecodeError) unexpected byte at position 0: 0x28 ("(")
2025-10-18T06:25:09.851 app[2860310b6077e8] sjc [info] (jason 1.4.4) lib/jason.ex:92: Jason.decode!/2
2025-10-18T06:25:09.851 app[2860310b6077e8] sjc [info] (phoenix_sync 0.6.0) lib/phoenix/sync/electric.ex:607: Phoenix.Sync.Electric.map_response_body/2
2025-10-18T06:25:09.851 app[2860310b6077e8] sjc [info] (phoenix_sync 0.6.0) lib/phoenix/sync/electric/client_adapter.ex:64: Phoenix.Sync.Adapter.PlugApi.Phoenix.Sync.Electric.ClientAdapter.fetch_upstream/4
2025-10-18T06:25:09.851 app[2860310b6077e8] sjc [info] (myapp 0.1.0) lib/web/controllers/sync/case_controller.ex:1: MyApp.Sync.CaseController.action/2
2025-10-18T06:25:09.851 app[2860310b6077e8] sjc [info] (myapp 0.1.0) lib/web/controllers/sync/case_controller.ex:1: MyApp.Sync.CaseController.phoenix_controller_pipeline/2
2025-10-18T06:25:09.851 app[2860310b6077e8] sjc [info] (phoenix 1.8.1) lib/phoenix/router.ex:416: Phoenix.Router.__call__/5
2025-10-18T06:25:09.851 app[2860310b6077e8] sjc [info] (myapp 0.1.0) lib/web/endpoint.ex:1: MyApp.Endpoint.plug_builder_call/2
2025-10-18T06:25:09.851 app[2860310b6077e8] sjc [info] (myapp 0.1.0) lib/web/endpoint.ex:1: MyApp.Endpoint.call/2Metadata
Metadata
Assignees
Labels
No labels