Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Avoids env var warning when path contains $/%; fix #832#961

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged

Conversation

rgkimball
Copy link
Contributor

I ran into the same issue as @kamadoatfluid in#832, as I have a mounted disk path including a$ (valid file & folder character in most operating systems, as is%). Since this is intended to catch environment variables per#662, I propose the use of regex instead to prevent irrelevant warnings from cluttering logs/console output.

This PR supports all expansion conventions demonstrated inos.path.expandvars, and also aligns with environment variable naming specifications. Illegal variables simply will cause errors and therefore don't present a security risk: word characters only, beginning witha-z or_.

Supported formats:

  • % APPDATA % or%APPDATA%
  • $MYVAR
  • ${MYVAR}

@Byron
Copy link
Member

Sorry for the late response and thanks a lot for the improvement!

@ByronByron merged commit313b3b4 intogitpython-developers:masterDec 6, 2019
@ByronByron added this to thev3.0.6 - Bugfixes milestoneDec 6, 2019
wip-sync referenced this pull request in NetBSD/pkgsrc-wipMar 7, 2020
3.1.0=====* Switched back to using gitdb package as requirement  (`gitdb#59 <https://github.com/gitpython-developers/gitdb/issues/59>`_)3.0.9=====* Restricted GitDB (gitdb2) version requirement to < 4* Removed old nose library from test requirementsBugfixes--------* Changed to use UTF-8 instead of default encoding when getting information about a symbolic reference  (`#774 <https://github.com/gitpython-developers/GitPython/issues/774>`_)* Fixed decoding of tag object message so as to replace invalid bytes  (`#943 <https://github.com/gitpython-developers/GitPython/issues/943>`_)3.0.8=====* Added support for Python 3.8* Bumped GitDB (gitdb2) version requirement to > 3Bugfixes--------* Fixed Repo.__repr__ when subclassed  (`#968 <https://github.com/gitpython-developers/GitPython/pull/968>`_)* Removed compatibility shims for Python < 3.4 and old mock library* Replaced usage of deprecated unittest aliases and Logger.warn* Removed old, no longer used assert methods* Replaced usage of nose assert methods with unittest3.0.7=====Properly signed re-release of v3.0.6 with new signature(See `#980 <https://github.com/gitpython-developers/GitPython/issues/980>`_)3.0.6=====| Note: There was an issue that caused this version to be released to PyPI without a signature| See the changelog for v3.0.7 and `#980 <https://github.com/gitpython-developers/GitPython/issues/980>`_Bugfixes--------* Fixed warning for usage of environment variables for paths containing ``$`` or ``%``  (`#832 <https://github.com/gitpython-developers/GitPython/issues/832>`_,  `#961 <https://github.com/gitpython-developers/GitPython/pull/961>`_)* Added support for parsing Git internal date format (@<unix timestamp> <timezone offset>)  (`#965 <https://github.com/gitpython-developers/GitPython/pull/965>`_)* Removed Python 2 and < 3.3 compatibility shims  (`#979 <https://github.com/gitpython-developers/GitPython/pull/965>`_)* Fixed GitDB (gitdb2) requirement version specifier formatting in requirements.txt  (`#979 <https://github.com/gitpython-developers/GitPython/pull/965>`_)
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers
No reviews
Assignees
No one assigned
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants
@rgkimball@Byron

[8]ページ先頭

©2009-2025 Movatter.jp