Skip to content

Avoid npm start silently hanging forever on pollutants such as .DS_Store #616

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 8, 2016

Conversation

monfera
Copy link
Contributor

@monfera monfera commented Jun 8, 2016

No description provided.

@monfera monfera force-pushed the try-to-parse-json-only branch from 916ea9e to a709cb4 Compare June 8, 2016 13:50
@@ -72,7 +72,7 @@ function readFiles(files) {
}

function createMocksList(files) {
var mocksList = files.map(function(file) {
var mocksList = files.filter(function(file) {return file.extname === '.json';}).map(function(file) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice find!

Can we make this filter clearer though? Something like:

// in case pollutants (e.g .DS_Store) got in the mock directory
var jsonFiles = files.filter( /* */ );

var mockList = jsonFiles.map(function(mock) { /* */ })

@monfera monfera force-pushed the try-to-parse-json-only branch from a709cb4 to 34e07fa Compare June 8, 2016 14:45
@etpinard etpinard merged commit 9ee53c9 into plotly:master Jun 8, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants