question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Strict configuration

See original GitHub issue

It seems I can do stuff like

[tool.ward]
lol = "roflmao"

or worse, minor typos

[tool.ward]
ordet = "random"

I’d like to propose making Ward error hard on invalid configuration (and print the name of the invalid conf option).

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:6 (6 by maintainers)

github_iconTop GitHub Comments

2reactions
hukkincommented, Jun 11, 2021

Haha, oh yeah that could work (just replace in with not in 😉 )

0reactions
darrenburnscommented, Jun 11, 2021

getmembers was the wrong thing… it’s late 😄 . I think something like

if config_key_from_toml in Config.__dataclass_fields__:
    # return error 

would work? If the key defined in the TOML isn’t defined in our Config dataclass, then tell the user

Read more comments on GitHub >

github_iconTop Results From Across the Web

strict - TSConfig Option - TypeScript
All the configuration options for a project. Classes. How to provide types to JavaScript ES6 classes. Made with ♥ in Redmond, Boston, SF...
Read more >
config | npm Docs
The command to run for npm edit and npm config edit . engine-strict. Default: false; Type: Boolean. If set to true, then npm...
Read more >
Example: Configuring Strict-Priority Queuing | Junos OS
This example shows how to configure strict-priority queuing and prevent starvation of other queues.
Read more >
TypeScript strict | webhint documentation
typescript-config/strict` checks if the property `strict` is enabled in the TypeScript configuration file (i.e `tsconfig.json`).
Read more >
"Strict Mode" TypeScript config options - DEV Community ‍ ‍
strictNullChecks; strictFunctionTypes; strictPropertyInitialization. So yeah, I lied. We're not just going to talk about one configuration ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found