Skip to content

Commit

Permalink
fix integer error on node >8
Browse files Browse the repository at this point in the history
  • Loading branch information
spencermountain committed Dec 4, 2018
1 parent bd010f5 commit afce319
Show file tree
Hide file tree
Showing 4 changed files with 44 additions and 53 deletions.
77 changes: 35 additions & 42 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 6 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,17 +21,17 @@
},
"dependencies": {
"chalk": "2.4.1",
"jsonfn": "^0.31.0",
"mongodb": "3.1.8",
"jsonfn": "0.31.0",
"mongodb": "3.1.10",
"prettysize": "1.1.0",
"sunday-driver": "1.0.1",
"sunday-driver": "1.0.2",
"worker-nodes": "1.6.1",
"wtf_wikipedia": "6.2.1",
"yargs": "12.0.2"
"yargs": "12.0.5"
},
"devDependencies": {
"shelljs": "0.8.2",
"tap-spec": "^5.0.0",
"shelljs": "0.8.3",
"tap-spec": "5.0.0",
"tape": "4.9.1"
},
"license": "MIT"
Expand Down
7 changes: 2 additions & 5 deletions scratch.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,10 @@ const dumpster = require('./src');
const drop = require('./src/lib/drop-db');

//144mb → 2.5 minutes = 57mb per worker per minute
// const path = '/home/spencer/mountain/dumpster-dive/tests/tinywiki-latest-pages-articles.xml';
// const path = '/media/spencer/07d11766-2ce6-4f8a-8ec0-a3d144a3d4cd/big_data/wikipedia/enwiki-latest-pages-articles.xml';
// const path = '/Users/spencer/data/wikipedia/enwiki-latest-pages-articles.xml'
const path = '/Users/spencer/data/wikipedia/enwiki-latest-pages-articles.xml'
// const path = './tests/smallwiki-latest-pages-articles.xml'; //3s
const path = '/Users/spencer/data/wikipedia/twinpeaks_pages_current.xml'; //3s
// const path = './tests/tinywiki-latest-pages-articles.xml'; //2s
const dbName = 'twinpeaks' //path.match(/\/([a-z-]+)-latest-pages/)[1];
const dbName = path.match(/\/([a-z-]+)-latest-pages/)[1];

//db.pages.find({title:'Doppelgängers'})

Expand Down
1 change: 1 addition & 0 deletions src/worker/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ const doSection = async (optionStr, workerCount, workerNum) => {
end: `${end}%`,
splitter: '</page>',
each: (xml, resume) => {
// console.log(workerNum, xml.substr(0, 200))
//pull-out sections from this xml
let page = parsePage(xml, this);
if (page !== null) {
Expand Down

0 comments on commit afce319

Please sign in to comment.