AtomLinter / linter-eslint-node

ESLint plugin for Atom/Pulsar Linter (v8 and above)
https://web.pulsar-edit.dev/packages/linter-eslint-node
MIT License
4 stars 3 forks source link

fix: use non-strict ndjson parsing #21

Closed savetheclocktower closed 2 years ago

savetheclocktower commented 2 years ago

Should fix #20.

Despite our efforts to ensure the worker only emits JSON to stdout and stderr, any ESLint plugin can write plain text to either one. In this case of #20, it's probably stderr, but we can't guarantee that either stream will only contain valid JSON. Hence we set strict: false on both and discard anything that won't parse.

I was able to reproduce this issue in an empty project with eslint-plugin-react installed and the following .eslintrc

{
  "parserOptions": {
    "ecmaVersion": "latest",
    "sourceType": "module",
    "ecmaFeatures": {
      "jsx": true
    }
  },
  "extends": [
    "plugin:react/recommended"
  ],
  "settings": {
    "pragma": "React",
    "version": "detect"
  }
}

…along with a minimal index.js just to trigger the linting.

savetheclocktower commented 2 years ago

No clue what's going on with the CI jobs.

UziTech commented 2 years ago

The ci errors are because Atom broke something with their download links. I'm working on a fix. See https://github.com/UziTech/action-setup-atom/issues/301

UziTech commented 2 years ago

The ci errors should have been fixed by #22 you can rebase this to get passing tests.

savetheclocktower commented 2 years ago

@UziTech release job failed for auth reasons. Is this something that I can somehow fix when it happens, or do I have to bug you?

savetheclocktower commented 2 years ago

@UziTech bumping this — this release isn't going through because the release action encountered an auth error, and re-running it doesn't work either.

UziTech commented 2 years ago

Sorry I didn't see this sooner. I released v1.0.6 manually. It seems Atom has been having some issues with their website and changed the access tokens.

savetheclocktower commented 2 years ago

Not a problem. But did it go through? The package's page on atom.io still shows 1.0.5.

AlexWayfer commented 1 year ago

Can you please release 1.0.6 for Pulsar Editor?

https://web.pulsar-edit.dev/packages/linter-eslint-node

savetheclocktower commented 1 year ago

The GitHub actions need to be updated to point at the Pulsar package repo, but that's in the works.

@UziTech: would it be feasible to do a one-off manual publish of 1.0.6?

UziTech commented 1 year ago

I have not tried to publish to ppm yet but I don't think I will have time soon. In the mean time you should be able to install packages from the repo with ppm install AtomLinter/linter-eslint-node