error in File count
See original GitHub issueTesting today with 12.0.1
% DEBUG=dat,dat-node dat share
dat Reading archive in dir /path/to/Directory Name +0ms dat-node Running initArchive on /path/to/Directory Name with opts: { _: [], utp: true, quiet: false, import: true, ignoreHidden: true, ‘ignore-hidden’: true, watch: true, dir: ‘/path/to/Directory Name’, logspeed: 200, port: 3282, debug: ‘dat,dat-node’, server: ‘https://datproject.org/api/v1’, exit: false } +4ms dat-node Making/Reading archive database +5ms dat-node Reading existing keys in drive +8ms dat-node Drive has 0 existing keys. +8ms dat-node No existing feeds in drive, creating new archive. +0ms dat-node Archive initialized +3ms dat-node Archive key 84c28e88181a19dd012d791a308f03106a7a53f5889e0c2d22e7a1952a720822 +0ms dat-node Opening archive 84c28e88181a19dd012d791a308f03106a7a53f5889e0c2d22e7a1952a720822 +1ms dat-node Archive opened +22ms dat-node initArchive callback +0ms dat Share: sync on 84c28e88181a19dd012d791a308f03106a7a53f5889e0c2d22e7a1952a720822 +1ms dat Importing updated & new files into archive +15ms dat-node Importer created. Counting Files. +6ms dat-node File count finished { files: 6, dirs: 3, bytes: NaN } +191ms /home/s/.npm-packages/lib/node_modules/dat/node_modules/pretty-bytes/index.js:6 throw new TypeError(
Expected a finite number, got ${typeof num}: ${num}
); ^TypeError: Expected a finite number, got number: NaN at module.exports.num (/home/s/.npm-packages/lib/node_modules/dat/node_modules/pretty-bytes/index.js:6:9) at null._repeat (/home/s/.npm-packages/lib/node_modules/dat/lib/share.js:131:92) at wrapper [as _onTimeout] (timers.js:270:19) at Timer.listOnTimeout (timers.js:89:15)
and the directory contents are:
% tree . ├── An Escape Act │ ├── An Escape Act.pdf │ └── cover.jpg ├── Kingdom of the Dolls │ ├── cover.jpg │ └── Kingdom of the Dolls.pdf └── Social Studies A Conversation about Art and Social Engagement ├── cover.jpg └── Social Studies A Conversation about Art and Social Engagement.pdf
Issue Analytics
- State:
- Created 7 years ago
- Comments:8
Top GitHub Comments
Yay! Prior to this bug I wasn’t able to successfully clone (well it would fetch metadata but then hang at 0% on contents) and now I can.
Sweet! Thanks for reporting the issue.
You can also now try the directory counter directly:
You should get not
NaN
😄 .