Skip to content

22 improve api documentation#37

Open
AdrianBenson wants to merge 28 commits into
mainfrom
22-improve-api-documentation
Open

22 improve api documentation#37
AdrianBenson wants to merge 28 commits into
mainfrom
22-improve-api-documentation

Conversation

@AdrianBenson

Copy link
Copy Markdown
Collaborator

No description provided.

@AdrianBenson AdrianBenson self-assigned this Jul 14, 2026
@AdrianBenson AdrianBenson added the documentation Improvements or additions to documentation label Jul 14, 2026
@AdrianBenson AdrianBenson linked an issue Jul 14, 2026 that may be closed by this pull request
5 tasks
@codecov

codecov Bot commented Jul 14, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 57.14286% with 24 lines in your changes missing coverage. Please review.
✅ Project coverage is 67.59%. Comparing base (ad638e2) to head (b258892).

Files with missing lines Patch % Lines
src/gsolve/tide/earth_tide.py 0.00% 11 Missing ⚠️
src/gsolve/observations.py 63.15% 6 Missing and 1 partial ⚠️
src/gsolve/reports.py 55.55% 3 Missing and 1 partial ⚠️
src/gsolve/gsolve_outputs.py 0.00% 1 Missing ⚠️
src/gsolve/reductions/terrain_corrections.py 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main      #37      +/-   ##
==========================================
+ Coverage   67.51%   67.59%   +0.07%     
==========================================
  Files          22       22              
  Lines        3780     3780              
  Branches      793      793              
==========================================
+ Hits         2552     2555       +3     
+ Misses        963      957       -6     
- Partials      265      268       +3     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR focuses on improving gSolve’s API documentation and Sphinx site structure by expanding/standardizing docstrings, introducing a more modular autosummary-based API reference layout, and updating docs dependencies/configuration to support the new doc build.

Changes:

  • Expanded and standardized NumPy-style docstrings across core classes/functions (observations, sites, tides, reductions, utilities).
  • Reworked Sphinx API docs into per-module pages with autosummary templates and updated tutorial asset paths.
  • Updated project/docs dependencies and tooling configuration (Sphinx theme dependency, Ruff rule selection, docs build ignores).

Reviewed changes

Copilot reviewed 46 out of 53 changed files in this pull request and generated 9 comments.

Show a summary per file
File Description
uv.lock Adds locked dependencies for new/updated tooling and docs requirements.
tests/test_reports.py Minor test helper signature tweak for clarity.
tests/test_core_utils.py Removes stray commented-out test fragment.
src/gsolve/tide/ocean_load.py Adds/expands docstrings and clarifies parameter documentation.
src/gsolve/tide/earth_tide.py Cleans imports and substantially improves docstrings/parameter docs.
src/gsolve/sites.py Improves class/method documentation; small API surface wording/param naming adjustments.
src/gsolve/scintrex.py Docstring cleanup and minor data handling tweak (to_list()).
src/gsolve/reports.py Improves report docs and adds deep-copy support.
src/gsolve/reductions/terrain_corrections.py Documentation overhaul for parameters/corrector/data classes.
src/gsolve/reductions/corrections.py Docstring improvements and clearer parameter descriptions.
src/gsolve/reductions/anomalies.py Docstring improvements; clarifies types/attributes for terrain params.
src/gsolve/observations.py Adds module docstring, improves docs, and adjusts some behavior/docs around summaries/plotting.
src/gsolve/meter_conversion.py Docstring expansion and clearer parameter/return/error descriptions.
src/gsolve/gsolve_outputs.py Docstring cleanup and small lint suppression adjustment.
src/gsolve/gsolve_algorithms.py Docstring cleanup and parameter name wording alignment.
src/gsolve/core/xr_methods.py Docstring improvements for DEM utilities.
src/gsolve/core/xr_accessor.py Docstring improvements and parameter default/documentation refinements.
src/gsolve/core/utils.py Docstring improvements and small doc clarifications.
src/gsolve/core/excel_io.py Renames worksheet writer argument and improves docs/behavior notes.
src/gsolve/core/data.py Updates imports/wording for sheet-name parsing and documentation cleanups.
pyproject.toml Adds docs theme dependency and expands Ruff/numpydoc validation configuration.
examples/scripts/TeMaari_ocean_loading_pyhardisp.py Updates tutorial example to use ETERNA predictor and fixes calibration factor expression.
docs/source/Tutorial_network_adjustment_and_anomaly_calculation.md Fixes tutorial image paths to _static/.
docs/source/Tutorial_calculate_calibration_beta_factor.md Expands tutorial section on earth tide correction options.
docs/source/terrain_corrections.md Fixes image path to _static/.
docs/source/requirements.txt Removes docs requirements file (likely migrating to pyproject-managed deps).
docs/source/fundamentals.md Fixes/updates internal link targets.
docs/source/conf.py Updates Sphinx/numpydoc/autodoc/autosummary configuration.
docs/source/api/xarray_methods.rst New autosummary API page for xarray utilities/accessor.
docs/source/api/tide_ocean_load.rst New autosummary API page for ocean loading corrections.
docs/source/api/tide_earth_tide.rst New autosummary API page for earth tide corrections.
docs/source/api/survey.rst New autosummary API page for survey API.
docs/source/api/sites.rst New autosummary API page for sites/reference gravity.
docs/source/api/scintrex.rst New autosummary API page for Scintrex import utilities.
docs/source/api/reports.rst New autosummary API page for GSolveReport.
docs/source/api/reductions_terrain_corrections.rst New autosummary API page for terrain corrections.
docs/source/api/observations.rst New autosummary API page for observations.
docs/source/api/meter_conversion.rst New autosummary API page for meter conversion.
docs/source/api/gsolve_algorithms.rst New autosummary API page for solver + outputs.
docs/source/api/core_utils.rst New autosummary API page for core utilities.
docs/source/api/core_typing.rst New typing/protocols API page.
docs/source/api/core_excel_io.rst New autosummary API page for Excel IO helpers.
docs/source/api/core_data.rst New autosummary API page for base data/parameter/table classes.
docs/source/api/api_index.rst Replaces monolithic automodule output with structured toctrees.
docs/source/api/anomalies_corrections.rst New autosummary API page for anomalies/corrections APIs.
docs/source/_templates/autosummary/class.rst Adds custom autosummary class template controlling members/attrs listing.
docs/source/_templates/autosummary/class_without_autosummary.rst Adds simplified class template variant.
.gitignore Ignores Sphinx build and generated API artifacts.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/gsolve/observations.py Outdated
The path to the Excel file.
sheet_name : str, default "observation_parameters"
The name of the worksheet to write the parameters to.
if_workbook_exists : {"append, "replace", "error"}, default "append"
Comment thread src/gsolve/reports.py Outdated
Comment on lines +42 to +43
This class provides a simple interface for collating the various inputs
and outputs from a GSolve run. The report can be
printed to the console or saved to an Excel workbook.
to and outputs from a gSolve run. The report can be written to an Excel workbook.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Addressed in 2688f8b.

Comment thread src/gsolve/reports.py Outdated
Comment thread src/gsolve/reductions/terrain_corrections.py Outdated
Comment thread src/gsolve/core/utils.py
Comment thread docs/source/conf.py Outdated
Comment thread src/gsolve/core/excel_io.py
Comment thread src/gsolve/observations.py Outdated
Comment thread src/gsolve/observations.py Outdated
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
@AdrianBenson AdrianBenson requested a review from alkirkby July 16, 2026 02:43

@AdrianBenson AdrianBenson left a comment

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Improve API documentation

4 participants