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

[BUG] Inconsistent OAI-PMH results for empty sets #1428

Open
stweil opened this issue Jan 13, 2025 · 0 comments
Open

[BUG] Inconsistent OAI-PMH results for empty sets #1428

stweil opened this issue Jan 13, 2025 · 0 comments
Labels
🐛 bug A non-security related bug.

Comments

@stweil
Copy link
Member

stweil commented Jan 13, 2025

Description

For an empty set OAI-PMH ListIdentifiers should return the error noRecordsMatch.

It does so for metadataPrefix=oai_dc or metadataPrefix=epicur, but not for metadataPrefix=mets.

Examples

These two examples were produced with the latest release 5.0.7 (which produces much more empty lines than old releases).

Good result for https://example.com/oai/?verb=ListIdentifiers&metadataPrefix=oai_dc&set=newspapers:

<?xml version="1.0" encoding="utf-8"?>



        <?xml-stylesheet type="text/xsl" href="/typo3conf/ext/dlf/Resources/Public/Stylesheets/OaiPmh.xsl"?><!-- fixed -->
    
<OAI-PMH
    xmlns="http://www.openarchives.org/OAI/2.0/"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/ http://www.openarchives.org/OAI/2.0/OAI-PMH.xsd">
    <responseDate>2025-01-13T20:42:14Z</responseDate>
    
    
    <request verb="ListIdentifiers" metadataPrefix="oai_dc" set="newspapers">/oai</request>
    
            <error code="noRecordsMatch">
                Die Anfrage ergab eine leere Treffermenge.
            </error>
        
<!--
-->
</OAI-PMH>



















Bad result for https://example.com/oai/?verb=ListIdentifiers&metadataPrefix=mets&set=newspapers with release 5.0.7:

<?xml version="1.0" encoding="utf-8"?>



        <?xml-stylesheet type="text/xsl" href="/typo3conf/ext/dlf/Resources/Public/Stylesheets/OaiPmh.xsl"?><!-- fixed -->
    
<OAI-PMH
    xmlns="http://www.openarchives.org/OAI/2.0/"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/ http://www.openarchives.org/OAI/2.0/OAI-PMH.xsd">
    <responseDate>2025-01-13T20:40:20Z</responseDate>
    
    
    <request verb="ListIdentifiers" metadataPrefix="mets" set="newspapers">/oai</request>
    
            
    

        
<!--
-->
</OAI-PMH>



















@sebastian-meyer sebastian-meyer added the 🐛 bug A non-security related bug. label Jan 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐛 bug A non-security related bug.
Projects
None yet
Development

No branches or pull requests

2 participants