Skip to content

Attempting to convert old non-existing history file fails #2449

@toddself

Description

@toddself

Just upgraded to 3.0.0 from 0.10.28 on linux.

↳ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 14.04.3 LTS
Release:    14.04
Codename:   trusty

trying to launch the repl results in:

todd@scripto-local 18:14:50 /home/.../src/deploybot:couch
↳ node
>
Converting old JSON repl history to line-separated history.
The new repl history file can be found at /home/todd/.node_repl_history.
> node.js:129
              throw err;
              ^

Error: Could not parse history data in /home/todd/.node-history.
    at onread (internal/repl.js:126:13)
    at FSReqWrap.readFileAfterClose [as oncomplete] (fs.js:380:3)
todd@scripto-local 18:16:22 /home/.../src/deploybot:couch
↳ node --version
v3.0.0

This seems to be due to the fact that i have NODE_REPL_HISTORY_FILE set, but there is no actual file present:

todd@scripto-local 18:16:24 /home/.../src/deploybot:couch
↳ echo $NODE_REPL_HISTORY_FILE
/home/todd/.node-history
todd@scripto-local 18:16:48 /home/.../src/deploybot:couch
↳ cat $NODE_REPL_HISTORY_FILE
cat: /home/todd/.node-history: No such file or directory

Metadata

Metadata

Assignees

No one assigned

    Labels

    replIssues and PRs related to the REPL subsystem.

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions