Instead of simply checking if the path exists (which can cause problems if the path points to a directory instead of a file), check if local_nb_nodes.json is an existing file
Checklist
This section is for the PR reviewer
[x] PR has an interpretable title with a prefix ([ENH], [FIX], [REF], [TST], [CI], [MNT], [INF], [MODEL], [DOC]) (see our Contributing Guidelines for more info)
[x] PR has a label for the release changelog or skip-release (to be applied by maintainers only)
[x] PR links to GitHub issue with mention Closes #XXXX
[x] Tests pass
[x] Checks pass
For new features:
[x] Tests have been added
For bug fixes:
[ ] There is at least one test that would fail under the original bug conditions.
Changes proposed in this pull request:
Checklist
This section is for the PR reviewer
[ENH]
,[FIX]
,[REF]
,[TST]
,[CI]
,[MNT]
,[INF]
,[MODEL]
,[DOC]
) (see our Contributing Guidelines for more info)skip-release
(to be applied by maintainers only)Closes #XXXX
For new features:
For bug fixes: