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

fix invalid escape sequences (python 3.12 SyntaxWarning) #459

Merged

Conversation

ehossack
Copy link
Contributor

I don't see any reason to not do this (nothing in sphinx?).

As referenced in #458

@ehossack
Copy link
Contributor Author

(I could add a changelog section, but not sure what version this would target. 1.30.0? 1.29.1?

@@ -1159,7 +1159,7 @@ class RawSimulator(AbstractRawApi):
DOWNLOAD_URL_MATCHER = re.compile(
DOWNLOAD_URL + '(?:' + '|'.join(
(
'/b2api/v[0-9]+/b2_download_file_by_id\?fileId=(?P<file_id>[^/]+)',
'/b2api/v[0-9]+/b2_download_file_by_id?fileId=(?P<file_id>[^/]+)',
Copy link
Collaborator

@mjurbanski-reef mjurbanski-reef Jan 16, 2024

Choose a reason for hiding this comment

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

This seems like this regexp was invalid from the beginning.

Instead "fix" should be just adding r i.e. r'...' as otherwise this ? will mean d is optional

Copy link
Contributor Author

Choose a reason for hiding this comment

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

good point.

@mjurbanski-reef
Copy link
Collaborator

As for the changelog, we use towncrier to manage main file, so you just create a new one and don't worry about versions yourself.
Please instructions in https://github.com/Backblaze/b2-sdk-python/blob/master/CONTRIBUTING.md#changelog .

P.S. thanks for contributing

@ehossack ehossack force-pushed the fix/invalid-escape-sequence-3.12 branch from 4da69dc to f82a1e8 Compare February 1, 2024 16:56
@vbaltrusaitis-reef
Copy link
Collaborator

vbaltrusaitis-reef commented Feb 1, 2024

@ehossack the changelog files need to follow a specific naming scheme. If it's a fix, it should be +<unique-change-name>.fixed.md, e.g. +syntax_warning.fixed.md. Once you rename the file, it should be good to go. :)

Edit: since this fixes issue #458, the name of the changelog file should be 458.fixed.md.

@ehossack ehossack force-pushed the fix/invalid-escape-sequence-3.12 branch from f82a1e8 to ced69f3 Compare February 2, 2024 05:38
@ehossack
Copy link
Contributor Author

ehossack commented Feb 2, 2024

@ehossack the changelog files need to follow a specific naming scheme. If it's a fix, it should be +<unique-change-name>.fixed.md, e.g. +syntax_warning.fixed.md. Once you rename the file, it should be good to go. :)

Edit: since this fixes issue #458, the name of the changelog file should be 458.fixed.md.

Sorry, new process and also I didn't properly read the section you linked 😅

Copy link
Collaborator

@mjurbanski-reef mjurbanski-reef left a comment

Choose a reason for hiding this comment

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

looks great, thank you!

@mjurbanski-reef mjurbanski-reef merged commit fc23486 into Backblaze:master Feb 2, 2024
24 checks passed
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

3 participants