Skip to content

[Bug] Cross-Origin Request Blocked #1529

@SnowyTheVampire

Description

@SnowyTheVampire

Bug Report

Hi, this is more personalized to a fork of ever-demand than the origin, so I apologize in advance. I did reach out on discord for the best tangible means of asking for assistance. I've tried to replicate ever-demand mostly for educational purposes, with the hope to find a tangible ecommerce solution at the same time.

The first issue I experienced was with MongoDB localhost, that I solved by changing the http:// links from localhost to 127.0.0.1, due to it wanting to handshake on ipv6 (::1) instead of ipv4...

But the second issue which I am currently stuck on is an error thrown in browser, during yarn run:server and run:shopweb, stating: "Cross-Origin Request Blocked: The Same Origin policy disallows reading the remote resource at http;//****. (Reason: CORS header 'Access-Control-Allow-Origin' missing). Status code: 200."

🔎 Search Terms

Cross-Origin Request Blocked
Socket.io + Node.js Cross-Origin Request Blocked
How to fix this CORS issue in socket.io?

🕗 Version & Regression Information

  • This is a bug in azure live development browser window
  • This is the development fork of ever-demand
  • I tried creating a build of the master branch, but had several bugs that were overtly difficult with my limited knowledge and ultimately went back to the development branch.

🙁 Actual behavior

After fresh installing Node + everything that's bundle with it (npm, python, Microsoft tools, etc), globally re-installing yarn latest, installing MongoDB, running 'yarn install' within the relevant origin folder to download dependencies, running 'yarn build:all' and launching the servers with 'yarn run:server' and 'yarn run:shopweb', I am greeted with working environments. (I had better luck with 'yarn install', than trying to use 'yarn bootstrap', 'yarn lerna bootstrap' or npm installing lerna globally).

However, when i connect to localhost:4200, which both 'yarn run:shopweb' and 'yarn run:admin' are wanting to load onto (shopweb not running on 3000 for some reason?), I am greeted with the Cross-Origin Request Blocked error. This is a repeating error that is preventing then sending and receiving of information.

Screenshot: firefox_eiAAD6J6ed

Edit: Random paragraph duplication made it illegible

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions