Skip to content
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

Bug - Documentation framework - syntax errors crash server and does not provide any valuable debug info #3827

Open
mcoker opened this issue Nov 29, 2023 · 0 comments

Comments

@mcoker
Copy link
Contributor

mcoker commented Nov 29, 2023

A way to trigger it is to do something like put 2 (or more than 1) colons in a custom property declaration or remove the trailing semicolon from a custom property declaration. Eg,

// valid
.some-selector {
  --bg: red;
  --color: white;
}

// invalid
.some-selector {
  --bg: red // missing trailing semicolon
  --color:: white; // more than 1 colon
}

It will give this error

node:events:491
      throw er; // Unhandled 'error' event
      ^

TypeError: Cannot read properties of undefined (reading 'postcss')
    at Object.loader (/Users/cmichael/repos/patternfly/node_modules/@patternfly/documentation-framework/node_modules/postcss-loader/dist/index.js:103:35)
Emitted 'error' event on Domain instance at:
    at emit (node:internal/process/promises:147:33)
    at processPromiseRejections (node:internal/process/promises:283:27)
    at process.processTicksAndRejections (node:internal/process/task_queues:96:32)

Node.js v18.16.0
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
@mcoker mcoker added the bug label Nov 29, 2023
@github-project-automation github-project-automation bot moved this to Needs triage in PatternFly Issues Nov 29, 2023
@mcoker mcoker changed the title Bug - Documentation framework - Bug - Documentation framework - double colons in css declaration crashes server Nov 29, 2023
@mcoker mcoker changed the title Bug - Documentation framework - double colons in css declaration crashes server Bug - Documentation framework - syntax errors crash server and does not provide any valuable debug info Nov 29, 2023
@jessiehuff jessiehuff moved this from Needs triage to Not started in PatternFly Issues Jan 17, 2024
@edonehoo edonehoo added the Groom label Sep 12, 2024
@kmcfaul kmcfaul removed the bug label Oct 25, 2024
@edonehoo edonehoo removed the Groom label Nov 1, 2024
@edonehoo edonehoo moved this from Not started to Needs triage in PatternFly Issues Nov 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Needs triage
Development

No branches or pull requests

3 participants