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

(PXP-10172): Fix invalid sequence warning #1056

Open
wants to merge 6 commits into
base: master
Choose a base branch
from
Open

Conversation

BinamB
Copy link
Contributor

@BinamB BinamB commented Nov 9, 2022

Bug Fixes

  • Fixed warning DeprecationWarning: invalid escape sequence '\d' in usersync while trying to read whitelist filename patterns.

@coveralls
Copy link

coveralls commented Nov 9, 2022

Pull Request Test Coverage Report for Build 13314

  • 11 of 11 (100.0%) changed or added relevant lines in 1 file are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 74.52%

Totals Coverage Status
Change from base Build 13310: 0.0%
Covered Lines: 7136
Relevant Lines: 9576

💛 - Coveralls

@@ -717,7 +717,7 @@ def mock_merge(dbgap_servers, sess):

# this function will be called once for each sftp server
# the test config file has 3 dbgap sftp servers
Copy link
Contributor

Choose a reason for hiding this comment

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

guessing this changed to 2?

Copy link
Contributor

Choose a reason for hiding this comment

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

why is this change in the tests needed? the code change shouldn't have any impact

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Lol i dont remember making this change. Changing this back because its obviously breaking the unit tests

@@ -370,7 +369,7 @@ def _match_pattern(filepath, id_patterns, encrypted=True):
Returns:
bool: whether the pattern matches
"""
id_patterns.append("authentication_file_phs(\d{6}).(csv|txt)")
id_patterns.append("authentication_file_phs(\\\d{6}).(csv|txt)")
Copy link
Contributor

Choose a reason for hiding this comment

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

doesn't this mean that you expect an actual \ in the file name?

i fixed the same warning in other repos last week, you can use a raw string to address this warning: r"..."

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yeah i thought that was the solution too but it doesn't work :/

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.

4 participants