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

Problem with the name of the datafield set #482

Open
matteofg opened this issue Aug 6, 2024 · 8 comments
Open

Problem with the name of the datafield set #482

matteofg opened this issue Aug 6, 2024 · 8 comments
Assignees
Milestone

Comments

@matteofg
Copy link

matteofg commented Aug 6, 2024

If the name of the datafield set contains uppercase characters...

\DeclareDatafieldSet{NAME}{
  \member[...]
}

\DeclareStyleSourcemap{
  \maps{
    \map[foreach={NAME}]{
      \step[fieldsource=\regexp{$MAPLOOP}, match=..., replace=...]
    }
  }
}

... the sourcemapping fails.

Is there any particular reason why loopval must be written in lower case?

@plk
Copy link
Owner

plk commented Aug 7, 2024

Looks like a bug. Which combinations of upper/lower for the set name and loopval don't work?

@matteofg
Copy link
Author

matteofg commented Aug 7, 2024

  • set name can be written in any way (upper case, CamelCase, etc.)
  • loopval can be written only in lower case
  • if set name is written in upper case and loopval is written in lower case, the sourcemapping works fine
  • but, if set name is written in lower case and loopval is written in upper case, the sourcemapping fails

plk added a commit that referenced this issue Aug 7, 2024
@plk
Copy link
Owner

plk commented Aug 7, 2024

Can you try 2.20 DEV version from SF? I think this should be fixed.

@matteofg
Copy link
Author

matteofg commented Aug 8, 2024

I just downloaded and installed biber 2.21 (beta). Unfortunately, nothing has changed.

@plk
Copy link
Owner

plk commented Aug 8, 2024

Works now for me - which platform binary did you download of 2.20?

\documentclass{article}
\usepackage{biblatex}
\addbibresource{biblatex-examples.bib}
\DeclareDatafieldSet{TEST}{
  \member[field=title]
}
\DeclareStyleSourcemap{
  \maps{
    \map[foreach={TEST}]{
      \step[fieldsource=\regexp{$MAPLOOP}, match=a, replace=z]
    }
  }
}
\begin{document}
\cite{kastenholz}
\printbibliography
\end{document}

@matteofg
Copy link
Author

matteofg commented Aug 8, 2024

I'm typesetting on macos 14.5 (Sonoma, latest version) and use the MacTeX-2024 Distribution.
I downloaded and installed the binary compressed into biber-darwin_x86_64.tar

@plk
Copy link
Owner

plk commented Aug 8, 2024

Hmm, can you get 2.21 dev version from sourceforge? This works for me with the above example.

@matteofg
Copy link
Author

matteofg commented Aug 8, 2024

I just reinstalled. Now it works, thanks.

@plk plk added the Bug label Oct 2, 2024
@plk plk self-assigned this Oct 2, 2024
@plk plk added this to the 2.21 milestone Oct 2, 2024
@plk plk added the fixedindev label Oct 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants