Troubleshooting
Common Issues & Solutions
1. Git Provider Authentication
- GitHub: Ensure the GitHub App is installed on the specific repository and that the
GITHUB_APP_PRIVATE_KEYis correctly formatted in the.envfile (including newlines). - GitLab: Check that the
redirect_uriin your GitLab application settings matchesYOUR_DOMAIN/gitlab-installed.
2. Media Upload Failures
- Verify that DigitalOcean Spaces (or S3) credentials are correct.
- Check the
NEXT_PUBLIC_BUCKET_URLin your environment variables. - Ensure the file size does not exceed the limit (10MB for images, 25MB for videos).
3. Editor Loading Issues
- Plate Editor: If the visual editor fails to render content, check the browser console for MDX parsing errors.
- Monaco Editor: Ensure that the
isRawModeflag is correctly toggled in the configuration.
4. Build & Cache Errors
If you encounter persistent build errors or stale data:
# Clear Next.js cache
rm -rf .next
# Clear Yarn/NPM cache
yarn cache cleanDebugging Tools
Fetch Logging
Sitepins is configured to log all backend and Git API fetches in development mode to help trace data flow.
// next.config.mjs
logging: {
fetches: {
fullUrl: true,
},
}Environment Validation
If the application fails to start, verify that all required variables from .env.example are present in your local .env. Pay special attention to the NEXT_PUBLIC_BACKEND_URL and provider-specific IDs.
Last updated on