Skip to content

Conversation

irevoire
Copy link
Contributor

@irevoire irevoire commented Apr 2, 2023

Pull Request

Since we introduced the Authentication: Bearer {api_key} header, sending an empty api_key doesn't work anymore, which means it's impossible to use this SDK without an API key.

A lot of noise is due to the doctest update; it's probably easier to review this PR by reading the first commit alone

Related issue

Fixes #240

What does this PR do?

  • Makes the API key optional when creating a client

PR checklist

Please check if your PR fulfills the following requirements:

  • Does this PR fix an existing issue, or have you listed the changes applied in the PR description (and why they are needed)?
  • Have you read the contributing guidelines?
  • Have you made sure that the title is accurate and descriptive of the changes?

Thank you so much for contributing to Meilisearch!

@irevoire irevoire added enhancement New feature or request SDK Rust breaking-change The related changes are breaking for the users labels Apr 2, 2023
@irevoire irevoire requested a review from bidoubiwa April 2, 2023 12:45
@irevoire irevoire force-pushed the make-the-api-key-optional branch from cdb80a1 to be7054d Compare April 2, 2023 16:55
@bidoubiwa
Copy link
Contributor

Hey @irevoire
Thanks for the contribution 🙏 I think your base branch is not main as per the changes in the .code_samples.
Which btw should be updated as well, for example here:

let client = Client::new("http://localhost:7700", "masterKey");

Could you fix this ? 🥺

@irevoire irevoire force-pushed the make-the-api-key-optional branch from be7054d to c263d26 Compare April 2, 2023 19:01
Copy link
Contributor

@bidoubiwa bidoubiwa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks 🔥🔥🔥🔥🔥

@bidoubiwa
Copy link
Contributor

bors merge

@bidoubiwa bidoubiwa removed the enhancement New feature or request label Apr 3, 2023
bors bot added a commit that referenced this pull request Apr 3, 2023
458: make the api key optional r=bidoubiwa a=irevoire

# Pull Request

Since we introduced the `Authentication: Bearer {api_key}` header, sending an empty `api_key` doesn't work anymore, which means it's impossible to use this SDK without an API key.

A lot of noise is due to the doctest update; it's probably easier to review this PR by reading the first commit alone

## Related issue
Fixes #240

## What does this PR do?
- Makes the API key optional when creating a client

## PR checklist
Please check if your PR fulfills the following requirements:
- [x] Does this PR fix an existing issue, or have you listed the changes applied in the PR description (and why they are needed)?
- [x] Have you read the contributing guidelines?
- [x] Have you made sure that the title is accurate and descriptive of the changes?

Thank you so much for contributing to Meilisearch!


Co-authored-by: Tamo <[email protected]>
@bors
Copy link
Contributor

bors bot commented Apr 3, 2023

Build failed:

@bidoubiwa
Copy link
Contributor

bors merge

@bors
Copy link
Contributor

bors bot commented Apr 3, 2023

@bors bors bot merged commit 2b041fc into main Apr 3, 2023
@bors bors bot deleted the make-the-api-key-optional branch April 3, 2023 10:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

breaking-change The related changes are breaking for the users SDK Rust

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Allow the creation of a Client without any API Key

2 participants