From 2916ff98619960be5196afee605d28761ea36cd6 Mon Sep 17 00:00:00 2001 From: Shahed Nasser Date: Mon, 26 Dec 2022 16:19:10 +0200 Subject: [PATCH] docs: added troubleshooting docs (#2900) --- docs/content/admin/quickstart.mdx | 6 +++++ .../starters/gatsby-medusa-starter.mdx | 6 +++++ .../starters/nextjs-medusa-starter.mdx | 6 +++++ .../common-installation-errors.mdx | 27 +++++++++++++++++++ .../content/troubleshooting/database-error.md | 20 ++++++++++++++ www/docs/sidebars.js | 10 +++++++ 6 files changed, 75 insertions(+) create mode 100644 docs/content/troubleshooting/common-installation-errors.mdx create mode 100644 docs/content/troubleshooting/database-error.md diff --git a/docs/content/admin/quickstart.mdx b/docs/content/admin/quickstart.mdx index 3462d3005e..9c164ad337 100644 --- a/docs/content/admin/quickstart.mdx +++ b/docs/content/admin/quickstart.mdx @@ -66,6 +66,12 @@ npm install negativeQuestion="Please describe the issue you faced." /> +:::tip + +If you run into errors during the installation, check out [this troubleshooting guide](../troubleshooting/common-installation-errors.mdx). + +::: + --- ## Test it Out diff --git a/docs/content/starters/gatsby-medusa-starter.mdx b/docs/content/starters/gatsby-medusa-starter.mdx index e193b3298b..4c892c8f8f 100644 --- a/docs/content/starters/gatsby-medusa-starter.mdx +++ b/docs/content/starters/gatsby-medusa-starter.mdx @@ -64,6 +64,12 @@ Your Gatsby storefront is now running at `localhost:8000`! negativeQuestion="Please describe the issue you faced." /> +:::tip + +If you run into errors during the installation, check out [this troubleshooting guide](../troubleshooting/common-installation-errors.mdx). + +::: + --- ## Development Notes diff --git a/docs/content/starters/nextjs-medusa-starter.mdx b/docs/content/starters/nextjs-medusa-starter.mdx index cbfa73a2dc..56947a6e60 100644 --- a/docs/content/starters/nextjs-medusa-starter.mdx +++ b/docs/content/starters/nextjs-medusa-starter.mdx @@ -58,6 +58,12 @@ Your Next.js storefront is now running at `localhost:8000`! negativeQuestion="Please describe the issue you faced." /> +:::tip + +If you run into errors during the installation, check out [this troubleshooting guide](../troubleshooting/common-installation-errors.mdx). + +::: + --- ## Development Notes diff --git a/docs/content/troubleshooting/common-installation-errors.mdx b/docs/content/troubleshooting/common-installation-errors.mdx new file mode 100644 index 0000000000..fd57372694 --- /dev/null +++ b/docs/content/troubleshooting/common-installation-errors.mdx @@ -0,0 +1,27 @@ +import Tabs from '@theme/Tabs'; +import TabItem from '@theme/TabItem'; + +# Resolve "Cannot find module X" Errors + +This error can occur while installing one of the storefronts or the Medusa admin. There is no specific cause to this error. + +One way to resolve it is by removing the `node_modules` directory in the project and re-installing the dependencies: + + + + +```bash +rm -rf node_modules +yarn install +``` + + + + +```bash +rd /s /q node_modules +yarn install +``` + + + \ No newline at end of file diff --git a/docs/content/troubleshooting/database-error.md b/docs/content/troubleshooting/database-error.md new file mode 100644 index 0000000000..e3da1ef9e8 --- /dev/null +++ b/docs/content/troubleshooting/database-error.md @@ -0,0 +1,20 @@ +# Error: SASL: SCRAM-SERVER-FIRST-MESSAGE: Client password must be a string + +You can get the following error while running `medusa new` or while running integration tests during [local development](../usage/local-development.md): + +```bash +Error: SASL: SCRAM-SERVER-FIRST-MESSAGE: client password must be a string +``` + +If the error occurs while running `medusa new` and you've selected to enter your database credentials, either: + +1. Make sure your database credentials are correct; +2. Or choose the Skip option to skip entering your database credentials. + +If the error occurs while running integration tests, make sure the following variable is set in your system's environment variable: + +```bash +DB_HOST= +DB_USERNAME= +DB_PASSWORD= +``` diff --git a/www/docs/sidebars.js b/www/docs/sidebars.js index 8cb72fd781..a3a6287b02 100644 --- a/www/docs/sidebars.js +++ b/www/docs/sidebars.js @@ -622,6 +622,16 @@ module.exports = { id: "troubleshooting/cli-installation-errors", label: "Errors Installing CLI", }, + { + type: "doc", + id: "troubleshooting/common-installation-errors", + label: "Installation Errors", + }, + { + type: "doc", + id: "troubleshooting/database-error", + label: "Database SASL Error", + }, { type: "doc", id: "troubleshooting/cors-issues",