Add docs content and ensure all exported items have docstrings - #79
Open
kdayday wants to merge 10 commits into
Open
Add docs content and ensure all exported items have docstrings#79kdayday wants to merge 10 commits into
kdayday wants to merge 10 commits into
Conversation
Add DocStringExtensions-style docstrings for PowerData (internal), get_generation_data, get_load_data, get_service_data, no_datetime, and refresh categorize_data, combine_categories, and make_fuel_dictionary so Public/Internal API pages can emit InterLinks inventory entries. Co-authored-by: Cursor <cursoragent@cursor.com>
PowerGraphics documents this helper via @extref; exporting it ensures Documenter emits an InterLinks inventory entry. Co-authored-by: Cursor <cursoragent@cursor.com>
There was a problem hiding this comment.
Pull request overview
This PR expands and restructures the package documentation while tightening docstring coverage for exported APIs, and it exposes combine_categories as a public export to support legacy workflows.
Changes:
- Exported
combine_categoriesand added/expanded docstrings across result-extraction and metric utilities. - Added new “How to…” guides and “Explanation” pages, and updated docs navigation to include them.
- Cleaned up documentation cross-linking (moving toward
@ref/@extref) and removed obsolete stub pages.
Reviewed changes
Copilot reviewed 16 out of 16 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| src/PowerAnalytics.jl | Exports combine_categories (and keeps exports aligned with documented public surface). |
| src/metrics.jl | Adds docstrings for exported metric accessor functions (e.g., get_name, get_time_agg_fn). |
| src/get_data.jl | Adds/expands docstrings for PowerData, data extractors, and category utilities (no_datetime, combine_categories, categorize_data). |
| src/fuel_results.jl | Clarifies make_fuel_dictionary docstrings and adds docstring for the default-mapping method. |
| src/builtin_metrics.jl | Replaces short string docs with richer docstrings for several built-in metrics (formulas/caveats). |
| docs/src/tutorials/PA_workflow_tutorial.jl | Updates external/internal links to use @ref / @extref rather than raw URLs. |
| docs/src/reference/public.md | Updates ComponentSelector references and keeps API reference structure intact. |
| docs/src/reference/developer_guidelines.md | Converts external doc links to @extref doc links. |
| docs/src/index.md | Updates overview wording, cleans up formatting/typos, and adjusts version wording to “5.x”. |
| docs/src/how_to_guides/stub.md | Removes obsolete placeholder stub page. |
| docs/src/how_to_guides/how_to_group_generation_by_fuel.md | Adds a new how-to guide for category-based grouping using built-in selectors/mappings. |
| docs/src/how_to_guides/how_to_define_a_custom_metric.md | Adds a new how-to guide for composing/rebuilding/defining custom metrics. |
| docs/src/explanation/stub.md | Removes obsolete placeholder stub page. |
| docs/src/explanation/metrics_and_component_selectors.md | Adds a conceptual explanation of metrics/selectors and aggregation behavior. |
| docs/src/explanation/choosing_built_in_metrics.md | Adds guidance on selecting among built-in metrics and interpreting caveats. |
| docs/make.jl | Adds the new pages to the navigation structure under “How to…” and “Explanation”. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #79 +/- ##
=======================================
Coverage 87.94% 87.94%
=======================================
Files 7 7
Lines 763 763
=======================================
Hits 671 671
Misses 92 92
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
…t-data' into kd/pa-docstrings-get-data
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
New export:
combine_categories, part of the old PA workflow used by PowerGraphics. Not currently hyperlinking it from PG, and assuming it's about to be deleted anyways as part of PG rework. But if that doesn't happen, it'll be available to linkMajor documentation improvements:
New guides and explanations:
how_to_group_generation_by_fuel.md) and defining custom metrics (how_to_define_a_custom_metric.md), providing step-by-step instructions and code examples. [1] [2]Navigation and structure:
make.jl) to include the new "How to..." and "Explanation" sections, replacing previous TODOs.General documentation cleanup and enhancements:
Improved references and cross-linking:
@refand@extreffor easier navigation, including in the main index, developer guidelines, and tutorial. [1] [2] [3] [4] [5] [6]ComponentSelectorand its documentation. [1] [2]Minor content and formatting fixes: