Skip to content

Figure.timestamp: Refactor to use the new alias system #4012

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

Merged
merged 3 commits into from
Aug 2, 2025

Conversation

seisman
Copy link
Member

@seisman seisman commented Jul 24, 2025

With the new alias system, the Figure.timestamp method can be simplified.

@seisman seisman added maintenance Boring but important stuff for the core devs skip-changelog Skip adding Pull Request to changelog labels Jul 24, 2025
@seisman seisman added this to the 0.17.0 milestone Jul 24, 2025
@seisman seisman changed the title Figure.timestamp: Refactor using the new alias system WIP: Figure.timestamp: Refactor using the new alias system Jul 26, 2025
Base automatically changed from AliasSystem/aliassystem to main July 29, 2025 04:09
@seisman seisman force-pushed the refactor/timestamp branch from f31ab3c to a2989b9 Compare July 29, 2025 04:28
@seisman seisman changed the title WIP: Figure.timestamp: Refactor using the new alias system Figure.timestamp: Refactor using the new alias system Jul 29, 2025
@seisman seisman added the needs review This PR has higher priority and needs review. label Jul 29, 2025
@seisman seisman marked this pull request as ready for review July 29, 2025 05:04
@seisman seisman force-pushed the refactor/timestamp branch 2 times, most recently from c305455 to 2f442fe Compare July 29, 2025 05:30
@seisman seisman requested a review from Copilot July 29, 2025 05:30
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 refactors the Figure.timestamp method to use PyGMT's new alias system instead of the previous manual argument building approach. The refactor simplifies the code by leveraging structured alias definitions for parameter handling.

  • Replaces manual dictionary building and string concatenation with the new AliasSystem and Alias classes
  • Improves error message clarity for the text parameter length validation
  • Consolidates GMT version compatibility workarounds with better documentation

@seisman seisman force-pushed the refactor/timestamp branch 3 times, most recently from e818b30 to d78c9ff Compare July 31, 2025 06:41
@seisman seisman force-pushed the refactor/timestamp branch from d78c9ff to a038b80 Compare July 31, 2025 08:38
@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 Jul 31, 2025
@seisman seisman changed the title Figure.timestamp: Refactor using the new alias system Figure.timestamp: Refactor to use the new alias system Aug 1, 2025
@seisman seisman removed the final review call This PR requires final review and approval from a second reviewer label Aug 2, 2025
@seisman seisman merged commit e490616 into main Aug 2, 2025
21 of 24 checks passed
@seisman seisman deleted the refactor/timestamp branch August 2, 2025 03:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
maintenance Boring but important stuff for the core devs skip-changelog Skip adding Pull Request to changelog
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant