enjalot / enjalot/blockbuilder

TypeError: Cannot read property 'collection' of null

Open
#243 10 comments 0 reactions 1 assignee Claimed by @micahstubbs View on GitHub
bug
Dominant language
JavaScript
Stars
332
Forks
59
PR merge metrics
No merged PRs in 30d

Description

## steps to reproduce

```bash
cd blockbuilder
yarn build
node server.js

#
# this part is expected for local build without a local ssl cert
#
error with https files Error: ENOENT: no such file or directory, open '/Users/m/workspace/blockbuilder/sslcert/privkey.pem'
at Object.openSync (fs.js:431:3)
at Object.readFileSync (fs.js:333:35)
at Object. (/Users/m/workspace/blockbuilder/server.js:25:19)
at Module._compile (internal/modules/cjs/loader.js:774:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:785:10)
at Module.load (internal/modules/cjs/loader.js:641:32)
at Function.Module._load (internal/modules/cjs/loader.js:556:12)
at Function.Module.runMain (internal/modules/cjs/loader.js:837:10)
at internal/main/run_main_module.js:17:11 {
errno: -2,
syscall: 'open',
code: 'ENOENT',
path: '/Users/m/workspace/blockbuilder/sslcert/privkey.pem'
}
express-session deprecated undefined resave option; provide resave option server.js:108:3
express-session deprecated undefined saveUninitialized option; provide saveUninitialized option server.js:108:3
Elasticsearch INFO: 2019-08-27T03:24:44Z
Adding connection to http://35.226.78.72:9200/

#
# this part is the bug
#
/Users/m/workspace/blockbuilder/node_modules/mongodb/lib/mongo_client.js:421
throw err
^

TypeError: Cannot read property 'collection' of null
at /Users/m/workspace/blockbuilder/server.js:136:20
at connectCallback (/Users/m/workspace/blockbuilder/node_modules/mongodb/lib/mongo_client.js:527:5)
at /Users/m/workspace/blockbuilder/node_modules/mongodb/lib/mongo_client.js:418:11
at processTicksAndRejections (internal/process/task_queues.js:82:9)
```

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.