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

Linting guidance #354

Open
10 tasks
tamsinforbes opened this issue Jul 13, 2023 · 0 comments
Open
10 tasks

Linting guidance #354

tamsinforbes opened this issue Jul 13, 2023 · 0 comments
Labels
Data Platform Core Infrastructure This issue is owned by Data Platform Core Infrastructure

Comments

@tamsinforbes
Copy link
Contributor

tamsinforbes commented Jul 13, 2023

Linting guidance is a more general thing - perhaps it warrants it's own page in the AP guidance that the create-a-derived-table guidance can internally link?

Approach 1: new linting page

  • create a separate general linting guidance page for yamllint and sqlfluff that create-a-derived-table guidance references
  • update/improve linting guidance specific to create-a-derived-table such as what lint rules are enforced
  • include linting commands used in create-a-derived-table in QuickRef page
  • include how to auto fix SQLfluff lint errors and use templating=ignore option to ignore Jijna templating
  • include how to use YAML online formatter [note you still need to add the final empty line to pass the yamllint rule]

Approach 2: just update create-a-derived-table linting guidance

  • improve general linting guidance with create-a-derived-table instructions
  • update/improve linting guidance specific to create-a-derived-table such as what lint rules are enforced
  • include linting commands used in create-a-derived-table in QuickRef page
  • include how to auto fix SQLfluff lint errors and use templating=ignore option to ignore Jijna templating
  • include how to use YAML online formatter [note you still need to add the final empty line to pass the yamllint rule]
    Notes to include/expand on
  • SQLFluff has a fix command which auto-formats what it can (must NOT be run without a config). For YAML there is a helpful online website that will format code correctly (though it requires copy pasting). Add this to the user guidance.
  • Useful to know what the rules are that the YAML/SQL linters will apply up front so as to try to write the code correctly from the start.
@tamsinforbes tamsinforbes added the Data Platform Core Infrastructure This issue is owned by Data Platform Core Infrastructure label Jul 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Data Platform Core Infrastructure This issue is owned by Data Platform Core Infrastructure
Projects
None yet
Development

No branches or pull requests

1 participant