`Export mish-platform-Layers:ExportsOutputRefPrism...
# help
m
Export mish-platform-Layers:ExportsOutputRefPrismaLayer958161C6A54DA9DC cannot be updated as it is in use by mish-platform-CacheAdminService, mish-platform-CandidateListService and mish-platform-CandidateMatchService (and 8 more)
f
Hey @Mischa Spiegelmock, once you export something, the value of that cant be changed.
Can u check the current value for
Layers:ExportsOutputRefPrismaLayer958161C6A54DA9DC
ends with colon and a number?
The layer value changes everytime the layer code changes, and that will give u an error on deploy.
Are you using the layer in non
sst.Function
?
m
yeah - I'm using my hacky NodejsFunction
I tried commenting out
scope.addDefaultFunctionLayers([prismaLayer])
and any references to the layer and doing
exportValue()
but the old value is still being exported
i want to kill the second one
I tried manually deleting the second export and uploading it to CF but I still get the error
Copy code
Export mish-platform-Layers:ExportsOutputRefPrismaLayer958161C6A54DA9DC cannot be updated as it is in use by mish-platform-CacheAdminService, mish-platform-CandidateListService and mish-platform-CandidateMatchService (and 8 more)
so maybe I just need to delete all my functions and service stacks and start over?
I did that, so I can at least deploy and roll back now. but I still can't make any changes to the layer
:x:  mish-platform-Layers failed: Export mish-platform-Layers:ExportsOutputRefPrismaLayer958161C6A54DA9DC cannot be updated as it is in use by mish-platform-CacheAdminService, mish-platform-CandidateListService and mish-platform-CandidateMatchService (and 9 more)
seems like I can comment out
addDefaultFunctionLayers
, do a deployment, then uncomment it and deploy again. must be a better way though
actually that's no good either because then my migration script fails
f
Hey @Mischa Spiegelmock, I added an optimization to how SST auto-fixes missing exports.
0.69.3
should fix this.
m
tight thanks!
i'm trying to switch to sst.Function but have some issues to work through https://serverless-stack.slack.com/archives/C01JG3B20RY/p1648139908292739
testing out 0.69.3 now
still getting the same error mish-platform-Layers failed: Export mish-platform-Layers:ExportsOutputRefPrismaLayer958161C6A54DA9DC cannot be updated as it is in use by mish-platform-CacheAdminService, mish-platform-CandidateListService and mish-platform-CandidateMatchService (and 9 more)
seems I have no way to update a layer unless I comment out
addLayers()
each time