GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — revert util.expand_path() due to regression by Yobmod · Pull Request #1240 · gitpython-developers/GitPython

Conversation

@Yobmod

@Yobmod Yobmod commented May 13, 2021 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor

Hopefully to fix #1238.

The orginal change (commit 39eb0e6) was attempting to get mypy consistant with expand_path(None), as it doesn't like try except blocks without some type narrowing and expanduser doesn't accept None (triggering the Exception). Added mypy ignores for now, to allow CI to pass.

It passes tests either way, so can't be sure, but the traceback points to an overload of cmd.Git.excecute(), wherein cwd = self._working_dir.
That leads to Git.init(), where self._working_dir = expand_user(working_dir)

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@Yobmod
revert util.expand_path() due to regression
cfa3782
@Yobmod Yobmod mentioned this pull request May 13, 2021
ImportError on latest GitPython 3.1.16 #1238
Closed
@Byron Byron added this to the v3.1.17 - Bugfixes milestone May 14, 2021
@Byron

Byron commented May 14, 2021

Copy link
Copy Markdown
Member

Thanks for the fix! What I understand is that the try-catch block has to be entered with None, which previously was prevented by the additional type check that mypi wanted to enforce.

It's quite amazing how GitPython seems to be at a state where minor changes will break someone, somewhere, under certain situations like multi-threading. It's a little frightening too.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@Byron
Byron merged commit 572bbb3 into gitpython-developers:main May 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

No reviews

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

None yet

Milestone

v3.1.17 - Bugfixes

Development

Successfully merging this pull request may close these issues.

ImportError on latest GitPython 3.1.16

Uh oh!

There was an error while loading. Please reload this page.

2 participants

@Yobmod @Byron
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.