Skip to content

Conversation

seisman
Copy link
Member

@seisman seisman commented Aug 8, 2025

This PR migrates the verbose parameter to the new alias system and let it support descriptive arguments. The long names come from https://github.com/GenericMappingTools/gmt/blob/dd32dd35573e0c54b5b5eb5616f039ab9f6d3614/src/gmt_common_longoptions.h#L91.

@seisman seisman added this to the 0.17.0 milestone Aug 8, 2025
@seisman seisman added enhancement Improving an existing feature needs review This PR has higher priority and needs review. labels Aug 8, 2025
@seisman seisman requested a review from Copilot August 8, 2025 07:08
Copy link
Contributor

@Copilot Copilot AI left a comment

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 migrates the verbose parameter to the new alias system and introduces the .add_common() method to the AliasSystem class to reduce code duplication when handling common parameters across GMT wrappers.

  • Adds the .add_common() method to AliasSystem for centralized management of common parameters like verbose
  • Updates basemap function to use the new alias system for the verbose parameter with type hints and descriptive string arguments
  • Updates documentation to reflect the change from single-letter codes to descriptive argument names

Reviewed Changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
pygmt/src/basemap.py Migrates verbose parameter to use new alias system with descriptive arguments and type hints
pygmt/alias.py Adds add_common method to AliasSystem class and updates docstring examples
doc/techref/common_parameters.md Updates documentation to use descriptive verbose argument names instead of single letters

seisman and others added 2 commits August 8, 2025 15:13
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
@seisman seisman added final review call This PR requires final review and approval from a second reviewer and removed needs review This PR has higher priority and needs review. labels Aug 10, 2025
@seisman seisman changed the title Migrate the parameter 'verbose' to the new alias system and let it support descriptive arguments POC: Migrate the parameter 'verbose' to the new alias system and let it support descriptive arguments Aug 10, 2025
@seisman seisman force-pushed the AliasSystem/verbose branch from f74ff96 to cccf373 Compare August 19, 2025 10:44
@seisman seisman changed the title POC: Migrate the parameter 'verbose' to the new alias system and let it support descriptive arguments Migrate the parameter 'verbose' to the new alias system and let it support descriptive arguments Aug 22, 2025
@seisman
Copy link
Member Author

seisman commented Aug 23, 2025

@GenericMappingTools/pygmt-maintainers Please give this PR a final review. I plan to merge it in 48 hours.

@seisman seisman merged commit 613b623 into main Aug 25, 2025
23 of 24 checks passed
@seisman seisman deleted the AliasSystem/verbose branch August 25, 2025 00:03
@seisman seisman removed the final review call This PR requires final review and approval from a second reviewer label Aug 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Improving an existing feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants