Skip to content
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

Fix: es_ES doi() to use standard DOI format #2162

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

jasur-py
Copy link

@jasur-py jasur-py commented Feb 3, 2025

Type of changes

  • Bug fix
  • New feature
  • Documentation / docstrings
  • Tests
  • Other

What does this change

This change introduces a dedicated DOI (Digital Object Identifier) provider and fixes the incorrect DOI implementation in the Spanish locale. Previously, the Spanish locale's doi() method was returning Spanish identification numbers (CIF/NIE/NIF) instead of actual DOIs.
Changes:

  • Added new DOI provider with correct implementation
  • Removed incorrect DOI implementation from Spanish locale
  • Added tests for DOI provider
  • Updated CHANGELOG.md

What was wrong

The es_ES locale had an incorrect implementation of the doi() method that returned Spanish identification numbers instead of Digital Object Identifiers, which was inconsistent with the method's intended purpose.

How this fixes it

  • Created a new dedicated DOI provider that generates valid DOI formats (10.xxxx/xxxx)
  • Removed the incorrect DOI implementation from Spanish locale
  • Added tests for DOI provider
  • Maintains proper separation of concerns by having identification numbers in SSN provider and DOIs in their own provider

Fixes #2161

Checklist

  • I have read the documentation about CONTRIBUTING
  • I have read the documentation about Coding style
  • I have run make lint

Tests are passing and the changes have been tested with both default and Spanish locales.

- Added new DOI provider with correct implementation
- Removed incorrect DOI implementation from Spanish locale
- Added tests for DOI provider
- Updated CHANGELOG.md
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.

es_ES doi() inconsistent with definition
1 participant