-
-
Notifications
You must be signed in to change notification settings - Fork 240
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
docs: Fix typo in grouping.md (filenameWithoutExtension) #2369
docs: Fix typo in grouping.md (filenameWithoutExtension) #2369
Conversation
Good spot - and thank you very much for the fix... This is interesting to me on many levels... tl;drI will accept the change - thanks! The text is definitely a typo - but surprisingly it does actually behave as documented... After I've merged the PR, I'll go ahead and update the bit of the Tasks automated tests that generates this text, to prevent the error coming back again next time I update the docs... 1. The documentation is machine-generated from the automated tests..This is one of a lot of pieces in the Tasks documentation that is machine-generated and automatically tested. Your correction is inside these lines - see the obsidian-tasks/docs/Queries/Grouping.md Lines 833 to 847 in dacaf09
And here is the bit of the source-code that contains the data that generates the text that later gets inserted in the docs.... obsidian-tasks/tests/Scripting/ScriptingReference/CustomGrouping/CustomGroupingExamples.test.ts Lines 266 to 276 in dacaf09
2. The output of the tests looks good...That test, run on a selection of tasks, generates this output: Lines 1 to 23 in dacaf09
So yes you're definitely correct that the text is not what was intended... And also, looking at the files generated by running that test, is shows that the code does actually work (surprisingly...) 3. Oh the irony...I've given a few conference lightning talks on the technique I'm using...
So yes, the tests work and the sample in the documentation works - but it is also still not 'correct'! |
Irony on irony....
Having updated the source code I see the changed output... I was looking past all the undefined... The output was clearly wrong. I will now need to search through the rest of the test output and make sure there are no more undefined that crept through! 😊 |
Co-Authored-By: Andrew M. White <[email protected]>
Description
The docs refer to
task.file.filename.filenameWithoutExtension
, which is undefined. The correct path istask.file.filenameWithoutExtension
.Motivation and Context
n/a
How has this been tested?
Locally.
Screenshots (if appropriate)
Types of changes
Changes visible to users:
fix
- non-breaking change which fixes an issue)feat
- non-breaking change which adds functionality)feat!!
orfix!!
- fix or feature that would cause existing functionality to not work as expected)docs
- improvements to any documentation content for users)vault
- improvements to the Tasks-Demo sample vault)contrib
- any improvements to documentation content for contributors - see Contributing to Tasks)Internal changes:
refactor
- non-breaking change which only improves the design or structure of existing code, and making no changes to its external behaviour)test
- additions and improvements to unit tests and the smoke tests)chore
- examples include GitHub Actions, issue templates)Checklist
yarn run lint
.Terms