Troubleshooting @gofynd/fdk-cli errors
Categories
- Theme serve / Build failures
- Theme sync / publish failures
- Installation failures
- Authentication & OAuth token failures
- Failed to fix the issue via troubleshooting
Theme serve / Build failures
- Delete .fdk/dist/ folder.
- Delete package-lock.json file & node-modules folder.
- Hit npm install
- Now try building it once.
- If it doesn’t solves your problem move here ''Failed to fix the issue via troubleshooting''
Theme sync / publish failures
- Check your theme version in package.json in your theme project.
- Verify the same version on platform panel theme library list. i.e Sales channel → Appearance → Themes.
- In case of both of these versions do not match, then the above error will be thrown.
- Apply the same version in your theme package.json file and retry syncing the same.
- If it doesn’t solves your problem move here Failed to fix the issue via troubleshooting
Installation failures
Install Rosetta on your mac and then install fdk-cli
Authentication & Auth token failures
- Check if you have access to platform panel of the company. If not, get access to platform panel for the specific company you are building theme for. At times access gets revoked for development environments of platform panel.
- Try using email flow once. i.e fdk login.
- Check if you are connected to any VPN or any private network, Disconnect that and try logging in once.
- The reason for this is environment instability. Majority of the times it will be temporary, you can check running the same command after a while ideally it should work.
- If it doesn’t solve your problem move here Failed to fix the issue via troubleshooting
Failed to fix the issue via troubleshooting
Before reporting any error except for those mentioned above or not able to troubleshoot via the recommended steps make sure you checked all the below listed points.
- You are using latest version of @gofynd/fdk-cli (If not explicitly mentioned to use one particular version). Download the latest version using npm install -g @gofynd/fdk-cli .
- Check your node version by hitting node --version. We currently support @gofynd/fdk-cli on node versions v12.x.x ... v15.x.x and have developed the tool on node 12.x.x. We highly recommend our end users to keep their node versions in this range v12.x.x ... v15.x.x to keep themselves out of unknown troubles.
- [Theme sync specific] No code should be synced in any of the environments before testing once on your local machine by running fdk theme serve & fdk theme serve —ssr false. If either of them fails fix that on your local machine first and then try syncing.
- Note: For @gofynd/fdk-cli versions >= 2.3.0 there is no dependency of adding localhost proxies in /etc/hosts file. The server will be powered on localhost domain itself.
If the above checklist is marked as done and the issue still persists.
- Post this in slack #theme-devs channel with the following details mentioned below along with a snapshot of error.
{
Command: sync/serve/publish etc;
Node version: ;
fdk-cli version: ;
Operating system: Windows/MAC/Linux;
Environment: ;
Platform panel URL: ;
Sales channel link: ;
Project repository URL: ;
Branch name: ;
}