Nuxt Slicemachine not logging in

Describe your question/issue in detail

I'm trying to set up slicemachine in a Nuxt 3 project. I'm using bun and am running on linux (openSUSE Tumbleweed). When I run npx @slicemachine/init@latest --repository <reponame>, it gets to the "Logging in to Prismic..." and it spins forever. No browser window is opened and I cannot seem to move past this step.

Impacted feature

Slicemachine.

What steps have you taken to resolve this issue already?

Attempted to look for a verbose flag to see what might be happening, but there's no such option. Reviewed the forums and searched online to see if there's been a solution, but nothing matched my scenario from what I could find.

Errors

None

Your Role

Hosting provider

Steps to reproduce

Set up new bun-based Nuxt 3 project, run cli command to init slicemachine.

Package.json file

  "name": "<reponame>",
  "private": true,
  "type": "module",
  "scripts": {
    "build": "nuxt build",
    "dev": "nuxt dev",
    "generate": "nuxt generate",
    "preview": "nuxt preview",
    "postinstall": "nuxt prepare",
    "lint": "eslint .",
    "lintfix": "eslint --fix ."
  },
  "dependencies": {
    "@nuxt/eslint": "^0.3.13",
    "@nuxt/fonts": "^0.7.0",
    "nuxt": "^3.12.1",
    "vue": "^3.4.29",
    "vue-router": "^4.3.3"
  },
  "devDependencies": {
    "@eslint/js": "^9.5.0",
    "@slicemachine/adapter-nuxt": "^0.3.42",
    "@types/bun": "latest",
    "@types/eslint__js": "^8.42.3",
    "autoprefixer": "^10.4.19",
    "eslint": "^9.5.0",
    "eslint-plugin-nuxt": "^4.0.0",
    "eslint-plugin-tailwindcss": "^3.17.3",
    "eslint-plugin-vue": "^9.26.0",
    "husky": "^9.0.11",
    "lint-staged": "^15.2.7",
    "postcss": "^8.4.38",
    "slice-machine-ui": "^2.2.1",
    "tailwindcss": "^3.4.4",
    "typescript-eslint": "^7.13.0",
    "vue-tsc": "^1.8.27"
  },
  "lint-staged": {
    "**/*.{js,ts,vue}": "bun run lintfix"
  },
  "module": "index.ts",
  "peerDependencies": {
    "typescript": "^5.4.5"
  }
}`

A similar issue was resolved by ensuring the repository name was correctly set in the slicemachine.config.json file. Verify that your repository name is correct.

Also make sure your default browser settings allow pop-ups. You can also try logging into Prismic manually using the Prismic CLI to log in via the console, run prismic login

Logging in with the Prismic CLI separately did the trick. Thank you!

1 Like