taylonr / postman Goto Github PK
View Code? Open in Web Editor NEWLicense: MIT License
License: MIT License
localhost:3000/books/1 throws internal server error.
Response:
{
"name": "SequelizeConnectionRefusedError",
"parent": {
"errno": "ECONNREFUSED",
"code": "ECONNREFUSED",
"syscall": "connect",
"address": "127.0.0.1",
"port": 5432
},
"original": {
"errno": "ECONNREFUSED",
"code": "ECONNREFUSED",
"syscall": "connect",
"address": "127.0.0.1",
"port": 5432
}
}
Status: 500 Internal Server Error
But this url works: http://localhost:3000/landing
Not sure how to proceed.
I'm not sure if the course material has been updated but I can't seem to find config.json file under server->config folder. Please advise. The file (and the folder) seems missing in the project files.
Not all the JavaScript was installing after the npm audit fix.....
when going to run the cmd npm run db:create .....this was also being an issue
Is there anything specific that i would need to do to get all the libraries installed?
Many thanks
Originally posted by @Halsy03 in #11 (comment)
I am trying to connect Postgres within a Docker image.
This is error I am getting..
> sequelize db:create && npm run db:migrate && npm run `db:seed`
/usr/bin/env: ‘node’: No such file or directory
npm ERR! Linux 4.4.0-122-generic
npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "run" "db:create"
npm ERR! node v4.2.6
npm ERR! npm v3.5.2
npm ERR! file sh
npm ERR! code ELIFECYCLE
npm ERR! errno ENOENT
npm ERR! syscall spawn
npm ERR! [email protected] db:create: `sequelize db:create && npm run db:migrate && npm run db:seed`
npm ERR! spawn ENOENT
npm ERR!
npm ERR! Failed at the [email protected] db:create script 'sequelize db:create && npm run db:migrate && npm run db:seed'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the postman package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! sequelize db:create && npm run db:migrate && npm run db:seed
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs postman
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls postman
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! /home/everlak/Documents/postmanAPI/postman/npm-debug.log
Hi,
I just downloaded the solution and I noticed that there are some vulnerabilities:
added 642 packages from 782 contributors and audited 2091 packages in 17.691s
found 122 vulnerabilities (44 low, 29 moderate, 48 high, 1 critical)
run npm audit fix
to fix them, or npm audit
for details
Thanks,
Patrick
Hey @BuxomSpaceFish...... What did you update in the class to get this back up & running...appreciate if you can detail?
Apparently after installing node.js and github my browser didn't save my place in the class and I missed that part.
Thank you very much for the quick response!
Originally posted by @BuxomSpaceFish in #9 (comment)
I got 500 Internal Server Error and message "error": "Title cannot be null" even after adding content type (application/json). API is up and running on localhost.
What could be the problem?
Unable to create DB. Reference below for the error. Please advise.
ERROR: Error reading "server\config\config.json". Error: SyntaxError: C:\Users\Charles\Desktop\Postman\postman-master\server\config\config.json: Unexpected token c in JSON at position 65
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] db:create: sequelize db:create && npm run db:migrate && npm run db:seed
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] db:create script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\Charles\AppData\Roaming\npm-cache_logs\2018-01-03T01_46_34_576Z-debug.log
C:\Users\Charles\Desktop\Postman\postman-master\server\config>npm install
openssl config failed: error:02001003:system library:fopen:No such process
npm WARN rollback Rolling back [email protected] failed (this is probably harmless): EPERM: operation not permitted, rmdir 'C:\Users\Charles\Desktop\Postman\postman-master\node_modules\fsevents\node_modules'
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: [email protected] (node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})
(Im searching 201 status)
If I add ID of the post earlier, there is Error occured during testing "Error: Insert failed, duplicate id" - status code 500
If I do not add ID of post earlier, there is response 201 - Created, but also during test, Postman adds new POST. - status code 201
Is it standard? can I turn it off somehow?
At the second part of the ReadMe file, when running npm run db:create, this warning appeared in the terminal "password authentication failed for user "postgres""
Hi Nate. First of all, really enjoying your Pluralsight course - Postman Fundamentals. Excellent presentation -so easy to follow and learn from.
I stumbled over the test environment db.test.json because there is only one book but the id is 5.
I reset it locally after cloning locally and it returns 1 as expected. If I missed a reason it was to start with 5 instead of 1 for one book, please let me know otherwise putting it out there.
Yeah, it must be something on your environment. I just pulled latest, and spun up a psql DB, set my password to "secret" and tried it, and the database was created without issue.
I know that people have done the course on Windows, so I'm kind of at a loss for why it's not working for youl
Originally posted by @taylonr in #2 (comment)
I'm trying to get set up for your class on Pluralsight and I'm getting this error. I've installed node.js, Postman and git. I've tried googling with zero luck. Any thoughts?
Thank you!
At first I got this error
'sequelize' is not recognized as an internal or external command,
operable program or batch file.
and fixed it by running
C:\Users\buxom\Documents\GitHub\postman>npm install --save sequelize
ERROR FOLLOWS
C:\Users\buxom\Documents\GitHub\postman>npm run db:create
[email protected] db:create C:\Users\buxom\Documents\GitHub\postman
sequelize db:create && npm run db:migrate && npm run db:seed
Sequelize CLI [Node: 12.13.1, CLI: 3.2.0, ORM: 4.44.3]
WARNING: This version of Sequelize CLI is not fully compatible with Sequelize v4. https://github.com/sequelize/cli#sequelize-support
Loaded configuration file "server\config\config.json".
Using environment "development".
sequelize deprecated String based operators are now deprecated. Please use Symbol based operators for better security, read more at http://docs.sequelizejs.com/manual/tutorial/querying.html#operators node_modules\sequelize\lib\sequelize.js:245:13
ERROR: connect ECONNREFUSED 127.0.0.1:5432
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] db:create: sequelize db:create && npm run db:migrate && npm run db:seed
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] db:create script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\buxom\AppData\Roaming\npm-cache_logs\2019-11-21T15_07_18_448Z-debug.log
I'm hoping I'm just doing a dumb-dumb, but I can't seem to create the db with sequelize-cli.
C:\repos\postman>npm run db:create
> [email protected] db:create C:\repos\postman
> sequelize db:create && npm run db:migrate && npm run db:seed
Sequelize CLI [Node: 8.9.4, CLI: 3.2.0, ORM: 4.28.0]
WARNING: This version of Sequelize CLI is not fully compatible with Sequelize v4. https://github.com/sequelize/cli#sequelize-support
Loaded configuration file "server\config\config.json".
ERROR: Dialect undefined does not support db:create / db:drop commands
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] db:create: `sequelize db:create && npm run db:migrate && npm run db:seed`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the [email protected] db:create script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\dhines\AppData\Roaming\npm-cache\_logs\2018-04-26T16_11_26_029Z-debug.log
Thoughts?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.