Troubleshooting
Common errors and troubleshooting for the Turbine App Framework.
Find Turbine library specific troubleshooting guides here:
Uncommitted changes
You must commit to your local project git repository before deploying. If you have any uncommitted changes, you will encounter the following error:
$ meroxa apps deploy
Checking for uncommitted changes...
On branch master
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git restore <file>..." to discard changes in working directory)
modified: index.js
no changes added to commit (use "git add" and/or "git commit -a")
Error: unable to proceed with deployment because of uncommitted changes
To resolve this error, simply follow the instructions by running the following commands:
$ git add .
$ git commit -m "First commit"
[master (root-commit) a1b2c34] First commit
10 files changed, 953 insertions(+)
// List of Turbine data app project files
Once you've committed, you can run the meroxa apps deploy
command.
Could not find resource
Your production data is available to your Turbine streaming apps through resources configured on the Meroxa Platform. Any references to resources must correspond to a resource that exists. If the resources do not exist or are misidentified in your code, you will run into the following error:
$ meroxa apps deploy
Checking for uncommitted changes...
✔ No uncommitted changes!
Validating branch...
✔ Deployment allowed from master branch!
Preparing application "liveapp" (language) for deployment...
✔ Application built!
x Resource availability check failed
Error: could not find resource "my-resource-with-a-typo";
⚠️ Run 'meroxa resources list' to verify that the resource names defined in your Turbine app are identical to the resources you have created on the Meroxa Platform before deploying again
If you've already configured your resources, check your code to make sure you've identified your resources appropriately.
If need be, refer to our documentation on creating resources to configure your resources.
Once the discrepancy has been identified, you can run the meroxa apps deploy
command.
Collection validation errors
Downstream collection used in another app
All destination resource collections referenced in your Turbine code are checked against data app instances running on the Meroxa Platform when deployed. If another data app uses the same destination resource collection, the deployment process will fail and result in an error. This validation prevents accidental record duplication in downstream resources.
$ meroxa apps deploy
Checking for uncommitted changes...
✔ No uncommitted changes!
✔ Feature branch (test) detected, setting app name to liveapp-test...
Preparing application "liveapp-test" (javascript) for deployment...
✔ Application built!
x Resource availability check failed
Error: ⚠️ Application resource "prod" with collection "orders" cannot be used as a destination. It is also being used as a destination by another application "liveapp".
Please modify your Turbine data application code. Then run `meroxa apps deploy` again. To skip collection validation, run `meroxa apps deploy --skip-collection-validation`.
Source and destination collection are the same in the application
If a data app references a source resource collection that is the same as the destination resource collection in the Turbine code, this will result in the deploy process failing with a resulting error. This validation prevents accidental looping effects within a data app.
$ meroxa apps deploy
Checking for uncommitted changes...
✔ No uncommitted changes!
✔ Feature branch (test) detected, setting app name to liveapp-test...
Preparing application "liveapp-test" (javascript) for deployment...
✔ Application built!
x Resource availability check failed
Error: ⚠️ Application resource "prod" with collection "orders" cannot be used as a destination. It is also the source.
Please modify your Turbine data application code. Then run `meroxa apps deploy` again. To skip collection validation, run `meroxa apps deploy --skip-collection-validation`.
Remedy for Collection Validation Errors
If the changes are correct and you wish to proceed and skip collection validation, run meroxa apps deploy --skip-collection-validation
.
Updated Meroxa CLI and Outdated Turbine library
The Meroxa CLI does not yet track a required version of the associated Turbine libraries. Therefore, you may encounter the situation in which you have just updated to the latest version of the Meroxa CLI and the next time you try to deploy a Turbine Application, you see an error like this:
Error: flag provided but not defined: -gitsha
Usage of /apps/security/securityculcxm3352tqoqjmq1lt:
-deploy
deploy the data app
-imagename string
image name of function image
-listfunctions
list available functions
-listresources
list currently used resources
-serve string
serve function via gRPC
In this case, updating your Turbine library to the latest version should correct the mismatch and unblock deployment.
Golang
$ cd <path-to-app>
$ go get -u github.com/meroxa/turbine-go
$ go mod tidy
# optional: save modules to vendor directory
$ go mod vendor
# prepare for next deployment
$ git add .
$ git commit -m "update turbine-go"Javascript
$ yarn upgrade turbine-js
Python
$ pip install -u turbine-py
Once you have done this, you can run the meroxa apps deploy
command.