We have an OSX dev box that is getting this error.
result += decoder.write(readBuffer);
RangeError: Invalid string length---
cusage
WARN Fetching latest model pricing from LiteLLM... ccusage 11:56:33 am
ℹ Loaded pricing for 1679 models ccusage 11:56:34 am
node:internal/fs/promises:594
result += decoder.write(readBuffer);
^
RangeError: Invalid string length
at readFileHandle (node:internal/fs/promises:594:25)
at async loadDailyUsageData (file:///opt/homebrew/lib/node_modules/ccusage/dist/data-loader-BGg_9orY.js:3557:19)
at async Object.run (file:///opt/homebrew/lib/node_modules/ccusage/dist/index.js:4506:21)
at async executeCommand (file:///opt/homebrew/lib/node_modules/ccusage/dist/index.js:881:2)
at async cli (file:///opt/homebrew/lib/node_modules/ccusage/dist/index.js:794:2)
at async run (file:///opt/homebrew/lib/node_modules/ccusage/dist/index.js:6391:2)
at async file:///opt/homebrew/lib/node_modules/ccusage/dist/index.js:6399:1
We have an OSX dev box that is getting this error.
result += decoder.write(readBuffer);
RangeError: Invalid string length---
cusage
WARN Fetching latest model pricing from LiteLLM... ccusage 11:56:33 am
ℹ Loaded pricing for 1679 models ccusage 11:56:34 am
node:internal/fs/promises:594
result += decoder.write(readBuffer);
^
RangeError: Invalid string length
at readFileHandle (node:internal/fs/promises:594:25)
at async loadDailyUsageData (file:///opt/homebrew/lib/node_modules/ccusage/dist/data-loader-BGg_9orY.js:3557:19)
at async Object.run (file:///opt/homebrew/lib/node_modules/ccusage/dist/index.js:4506:21)
at async executeCommand (file:///opt/homebrew/lib/node_modules/ccusage/dist/index.js:881:2)
at async cli (file:///opt/homebrew/lib/node_modules/ccusage/dist/index.js:794:2)
at async run (file:///opt/homebrew/lib/node_modules/ccusage/dist/index.js:6391:2)
at async file:///opt/homebrew/lib/node_modules/ccusage/dist/index.js:6399:1