Skip to content

Wip 0.4.4#110

Merged
dpieski merged 2 commits intomainfrom
wip-0.4.4
Mar 8, 2026
Merged

Wip 0.4.4#110
dpieski merged 2 commits intomainfrom
wip-0.4.4

Conversation

@dpieski
Copy link
Copy Markdown
Contributor

@dpieski dpieski commented Mar 8, 2026

Description

Adds three convenience methods to PatentDataClient: get_patent(), get_publication(), and get_pct() for looking up patent file wrappers by patent number, publication number, or PCT number respectively. Also fixes sanitize_application_number to strip leading zeros from PCT serial numbers.

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update
  • Code refactoring

Testing

  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • I have tested this manually (if applicable)

Checklist

  • My code follows the project's style guidelines
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • Any dependent changes have been merged and published

Related Issues

Closes #109

Additional Notes

  • get_patent(patent_number) and get_publication(publication_number) use search_applications with the appropriate query parameter and return the first result.
  • get_pct(pct_number) auto-detects the input format: PCT application numbers (starting with "PCT") use direct lookup via get_application_by_number, PCT publication numbers (starting with "WO") use search via pctPublicationNumber_q.
  • sanitize_application_number now strips leading zeros from the PCT serial portion (e.g., PCT/US2025/047756PCTUS2547756).
  • 173 unit tests and 28 integration tests pass.

@dpieski dpieski merged commit 03afdcd into main Mar 8, 2026
7 checks passed
@dpieski dpieski deleted the wip-0.4.4 branch March 12, 2026 15:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FEAT] New Helper functions

1 participant