Skip to content

curl_escape seems to break the call #11

@alansz

Description

@alansz

federalregister 0.2.0, with curl 6.2.2 package

When I issue:

fr_search(type='PRESDOCU',
presidential_document_type='executive_order',
per_page=1000,
page=page,order='newest',
fields=fields,
publication_date=list('gte'='2025-01-19'))

it returns a very high total count (>95,000). But the correct API call (as created at https://www.federalregister.gov/developers/documentation/api/v1#/Federal%20Register%20Documents/get_documents__format_)

curl -X GET "https://www.federalregister.gov/api/v1/documents.json?fields[]=agency_names&per_page=20&conditions[publication_date][gte]=2025-01-19&conditions[type][]=PRESDOCU&conditions[presidential_document_type][]=executive_order&conditions[sections][]=" -H "accept: /"

returns 132.

I can get the same 132 if I modify fr_search to remove all the two curl_escape calls.

  • Alan

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions