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

Change regex validation for names #313

Closed
wants to merge 2 commits into from

Conversation

fsxfreak
Copy link
Contributor

@fsxfreak fsxfreak commented Feb 16, 2024

Problem

We allow index names to be alphanumeric with dashes in between, and require the first and last character be alphanumeric. The existing regex doesn't allow for that, so here's the proposed regex

Solution

Cross checked with internal specs

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update
  • Infrastructure change (CI configs, etc)
  • Non-code change (docs, etc)
  • None of the above: (explain here)

Test Plan

Played around with the regex in https://regex101.com/

@fsxfreak fsxfreak requested a review from jhamon February 16, 2024 01:28
@fsxfreak fsxfreak marked this pull request as ready for review February 16, 2024 01:34
Copy link
Collaborator

@jhamon jhamon left a comment

Choose a reason for hiding this comment

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

Hey, thanks for helping out again here. The files you're attempting to edit (and everything under pinecone/core/) are generated from our privately held openapi spec. So the way to update these values is to make a change to the spec and then regenerate this part of the client. If you ask in #apis slack channel people can walk you through these steps.

@fsxfreak
Copy link
Contributor Author

Hey, thanks for helping out again here. The files you're attempting to edit (and everything under pinecone/core/) are generated from our privately held openapi spec. So the way to update these values is to make a change to the spec and then regenerate this part of the client. If you ask in #apis slack channel people can walk you through these steps.

thanks, let me open another PR after I figure out where the source of truth spec is

@fsxfreak fsxfreak closed this Feb 20, 2024
@fsxfreak fsxfreak mentioned this pull request Feb 21, 2024
7 tasks
jhamon added a commit that referenced this pull request Feb 22, 2024
## Problem

See context in #313. This PR also includes other changes such as
renaming vector_operations_api to data_plane_api and updating
documentation.

## Solution

Followed steps to regenerate the python client from the protos.

## Type of Change

- [x] Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing
functionality to not work as expected)
- [ ] This change requires a documentation update
- [ ] Infrastructure change (CI configs, etc)
- [ ] Non-code change (docs, etc)
- [ ] None of the above: (explain here)

---------

Co-authored-by: Jen Hamon <jhamon@pinecone.io>
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.

None yet

2 participants