medusajs / medusa

The world's most flexible commerce platform.
https://medusajs.com
MIT License
25.93k stars 2.6k forks source link

[Bug]: The search by email id in the invite modal is calling the user API instead of invite API in the V2 preview version #9968

Closed lokeswaran-a closed 1 week ago

lokeswaran-a commented 1 week ago

Package.json file

{
  "name": "medusa-starter-default",
  "version": "0.0.1",
  "description": "A starter for Medusa projects.",
  "author": "Medusa (https://medusajs.com)",
  "license": "MIT",
  "keywords": [
    "sqlite",
    "postgres",
    "typescript",
    "ecommerce",
    "headless",
    "medusa"
  ],
  "scripts": {
    "dev": "medusa develop",
    "build": "medusa build",
    "start": "medusa start",
    "seed": "medusa exec ./src/scripts/user-seed.ts && medusa exec ./src/scripts/seed.ts",
    "migrate": "medusa db:migrate",
    "migrate:gen": "npx medusa db:generate",
    "test": "jest --testPathPattern=spec\\.ts$",
    "test:watch": "jest --watch --testPathPattern=spec\\.ts$",
    "test:coverage:local": "jest --coverage --testPathPattern=spec\\.ts$",
    "test:coverage": "jest --coverage",
    "lint": "yarn eslint",
    "lint:fix": "yarn eslint --fix",
    "prepare": "husky",
    "test:env": "cross-env NODE_ENV=test yarn run dev",
    "test:integration": "jest integration-tests"
  },
  "dependencies": {
    "@aws-sdk/client-s3": "^3.658.1",
    "@aws-sdk/client-ses": "^3.637.0",
    "@aws-sdk/credential-provider-web-identity": "^3.621.0",
    "@aws-sdk/s3-request-presigner": "^3.675.0",
    "@medusajs/admin-sdk": "preview",
    "@medusajs/api-key": "preview",
    "@medusajs/auth": "preview",
    "@medusajs/auth-emailpass": "preview",
    "@medusajs/cache-inmemory": "preview",
    "@medusajs/cart": "preview",
    "@medusajs/cli": "preview",
    "@medusajs/currency": "preview",
    "@medusajs/customer": "preview",
    "@medusajs/event-bus-local": "preview",
    "@medusajs/event-bus-redis": "preview",
    "@medusajs/file": "preview",
    "@medusajs/file-local-next": "preview",
    "@medusajs/framework": "^2.0.1",
    "@medusajs/fulfillment": "preview",
    "@medusajs/fulfillment-manual": "preview",
    "@medusajs/inventory-next": "preview",
    "@medusajs/medusa": "preview",
    "@medusajs/notification": "preview",
    "@medusajs/notification-local": "preview",
    "@medusajs/order": "preview",
    "@medusajs/payment": "preview",
    "@medusajs/pricing": "preview",
    "@medusajs/product": "preview",
    "@medusajs/promotion": "preview",
    "@medusajs/region": "preview",
    "@medusajs/sales-channel": "preview",
    "@medusajs/stock-location-next": "preview",
    "@medusajs/store": "preview",
    "@medusajs/tax": "preview",
    "@medusajs/user": "preview",
    "@medusajs/workflow-engine-inmemory": "preview",
    "@types/express-serve-static-core": "^5.0.0",
    "@types/multer": "^1.4.12",
    "csv-parser": "^3.0.0",
    "express": "^4.17.2",
    "get-port": "^7.1.0",
    "http-status-codes": "^2.3.0",
    "json-2-csv": "^5.5.6",
    "multer": "^1.4.5-lts.1",
    "newrelic": "latest",
    "typeorm": "^0.3.20",
    "uuid": "^10.0.0"
  },
  "devDependencies": {
    "@babel/preset-env": "^7.24.8",
    "@eslint/js": "^9.6.0",
    "@mikro-orm/cli": "5.9.7",
    "@mikro-orm/core": "5.9.7",
    "@mikro-orm/migrations": "5.9.7",
    "@mikro-orm/postgresql": "5.9.7",
    "@stdlib/number-float64-base-normalize": "0.0.8",
    "@stylistic/eslint-plugin": "^2.3.0",
    "@swc/core": "1.5.7",
    "@types/express": "^4.17.13",
    "@types/jest": "^29.5.12",
    "@types/mime": "1.3.5",
    "@types/node": "^17.0.8",
    "@types/react": "^18.3.2",
    "@types/uuid": "^10.0.0",
    "cross-env": "^7.0.3",
    "eslint": "^9.6.0",
    "eslint-plugin-react": "^7.34.3",
    "globals": "^15.8.0",
    "husky": "^9.0.11",
    "jest": "^29.7.0",
    "jest-sonar": "^0.2.16",
    "medusa-test-utils": "^1.1.45",
    "supertest": "^7.0.0",
    "ts-jest": "^29.2.3",
    "ts-node": "^10.9.2",
    "typescript": "5.5.4",
    "typescript-eslint": "^7.16.0"
  },
  "engines": {
    "node": ">=20"
  }
}

Node.js version

v20.0.0

Database and its version

postgresql 16

Operating system name and version

Macos

Browser name

No response

What happended?

When we were in preview version 8, the search on email ID used to work in the invite popup, but a couple of days ago, we upgraded to the latest preview version, and the search is not working. From the networks tab, I found that the search is triggering the user API instead of the invite API. Is this bug already identified and resolved in any of the latest V2 releases?

image

Expected behavior

Screenshot 2024-11-07 at 10 54 59 AM

The search in the invite pop up should work

Actual behavior

But it is not working in the latest preview version

Link to reproduction repo

NA

fPolic commented 1 week ago

Thanks for the report @lokeswaran-a. We will fix it ASAP.