jhudson8 / smocks

Stateful mock HTTP server using HAPI
MIT License
25 stars 10 forks source link

Upgrade to smocks version 4.*.* breaks shifu admin #18

Closed abhagupta closed 8 years ago

abhagupta commented 8 years ago

@walmart/shifu is an internal project which can be accessed via https://gecgithub01.walmart.com/otto/shifu . The server starts up fine but when admin console is accessed using http://dev.walmart.com:8080/_admin, the issue is seen with babel. Here are some stack logs
exports.default (/Users/agupt13/Documents/workspace/mocks/shifu/node_modules/babel-template/lib/index.js:19:27),Object.<anonymous> (/Users/agupt13/Documents/workspace/mocks/shifu/node_modules/babel-helpers/lib/helpers.js:17:70),Module._compile (module.js:541:32),Object.Module._extensions..js (module.js:550:10),Module.load (module.js:458:32),tryModuleLoad (module.js:417:12),Function.Module._load (module.js:409:3),Module.require (module.js:468:17),require (internal/module.js:20:19),Object.<anonymous> (/Users/agupt13/Documents/workspace/mocks/shifu/node_modules/babel-helpers/lib/index.js:12:40),Module._compile (module.js:541:32),Object.Module._extensions..js (module.js:550:10),Module.load (module.js:458:32),tryModuleLoad (module.js:417:12),Function.Module._load (module.js:409:3),Module.require (module.js:468:17)

Note that when smocks is executed on its own, admin console is accessed successfully.

jhudson8 commented 8 years ago

Given the details, I'm not exactly sure why this would break but I suspect it's related to this commit.

https://github.com/jhudson8/smocks/commit/cf9b94fd5f0ee5fb1790b4bc758f45b9964280f9

Still trying to figure out what to do about it though...

abhagupta commented 8 years ago

Hi @jhudson8 . Shifu is walmart's internal project. The repo is https://gecgithub01.walmart.com/otto/shifu. The best way to reproduce is to

Now to reproduce the issue, change the version of smocks to latest in shifu's package .json, and do an npm install which should get the latest version of smocks (4.0.7). If you visit the admin url again, it will break with error i mentioned above.

I have been cloning smocks locally and doing an npm link with shifu to troubleshoot on my system.

Thanks for looking into this. (My node version is v5.11.0 and npm version is 3.9.2).

abhagupta commented 8 years ago

Closing this issue, since its fixed from shifu side