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

Fix version_info cache invalidation, typing, parsing, and serialization#1838

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
Byron merged 19 commits intogitpython-developers:mainfromEliahKagan:refresh-version
Feb 23, 2024

Conversation

EliahKagan
Copy link
Member

@EliahKaganEliahKagan commentedFeb 23, 2024
edited
Loading

Fixes#1829 - cache invalidation
Fixes#1830 - typing
Fixes#1833 - parsing
Fixes#1836 - serialization

Much of the design in the fixes for#1830,#1833, and#1836, as well as why I think it makes sense to include them here with#1829, is already largely covered in the discussion/comments in those three issues.

Design goals for#1829

For#1829, which I would regard to be the biggest of the changes here, and which is the change for which the most additional code is added to the test suite, I made sure to preserve three important properties of the code:

  1. Refreshing is global but affects allGit instances. Changing the way refreshing itself fundamentally works is beyond the scope of this PR and would also be a breaking change that I think could only be made in a new major release, and there are good reasons for refreshing to be global. Allowing a per-instance overriding refresh might be useful, but would be much more complicated than the current system unless accompanied by other design changes that would likely be breaking.
  2. Caching is performed forversion_info attributes. This has been explicitly promised in theversion_info docstring for a long time, with the intention that accessingversion_info be understood as cheap, and it is likely that substantial code exists that assumes it is cheap (or that throttles parts of GitPython that use it and benefit from it being cheap).
  3. Caching does not take place acrossGit instances, and accessingversion_info on oneGit instance never has any effect on what happens whenversion_info is accessed on anotherGit instance. Since the actual validity of cached version information depends on when the global operation of refreshing was last done, it may seem like the caching should be made global as well. But this can lead to some new problems, such that I suggest it either be put off until later or never done.

Why not cache globally?

To expand on why the that third property is something I've taken care to preserve, these are the three problems I anticipate will arise if the caching were to be made global, in increasing order of significance:

  • Although GitPython is not in general thread-safe (#1052), caching globally may still make it less capable of concurrency than before, and the interaction with multiprocessing would also have to be considered.
  • That the cache is per-instance is a long-standing behavior, which existing code may rely on. It is not explicitly stated in the property docstring, and I've taken care not to start stating it, in case it is to be changed. But I think it is how readers would have understood the docstring, since it is documenting aninstance property and does not describe the cache as global or shared.
  • Not sharing the cache ensures that the codeGit().version_info always makes a subprocess call to get fresh information. Besides being one of the ways this behavior may have been relied on already, changing it would also, in practice, lead to code that uses GitPython being written to refresh more often, which would have the opposite effect on speed and resource usage than is intended by caching.

The cache invalidation implementation

Rather than having the refresh operation reach out to allGit instances to invalidate their caches, I've added a_refresh_token class attribute that is set and reset along withGIT_PYTHON_GIT_EXECUTABLE during a refresh, and added a_version_info_token instance attribute (that, like_version_info, is excluded from pickle serialization).

Whenversion_info is accessed, if_version_info_token is the same object as_refresh_token, then the cache is valid and the cached value in_version_info is returned. Otherwise, the cache is invalid, andgit version is run to obtain the version; the version information is cached in_version_info,_version_info_token is updated to_refresh_token, and the newly computed value is returned.

The_version_info_token instance attribute starts out asNone to simplify debugging and unpickling. Its value is always eitherNone or a value that has at some point been the value of the_refresh_token class attribute. The_refresh_token class attribute is neverNone, but always a direct instance ofobject, even before the first refresh, which ensures it never wrongly matches the initialNone value of a_version_info_token instance attribute.

A successful refresh always causes_refresh_token to differ from any_version_info_token that exists at that time. This is important--and, in particular, these tokens must not be tied to the value ofGit.GIT_PYTHON_GIT_EXECUTABLE--because refreshing must properly update for a change towhich git implementation is accessed by the same command or even via the same path. The most common and important such case is probably whenGIT_PYTHON_GIT_EXECUTABLE is the default value of"git", and git has been upgraded or a new version installed in a$PATH directory.

Dropping theLazyMixin base class

An aspect of this PR that I recommend be double-checked in review is my assumption thatGit havingLazyMixin as a base class can be considered a mere implementation detail ofGit, and thus that it is non-breaking to remove inheritance from that base class.

I removed it because it was only being used to implement caching for theversion_info property. It is well-suited to some forms of caching elsewhere in GitPython, but not well-suited to the changes needed inversion_info for#1829 and#1836 (as discussed in#1836). Because I stopped usingLazyMixin for this, it was no longer used for anything. Removing it simplified the code, though if necessary it could be brought back and just not used for anything. (The newversion_info implementation would still work withLazyMixin present but unused.)

Other considerations

Keeping thesuper().__init__ call

Git.__init__ contains this line:

super().__init__()

This superficially appears related to the use ofLazyMixin, but I believe that is not the case.LazyMixin, which is provided by the gitdb dependency, at least currently does not define an__init__ method. Furthermore, such asuper() call was present even beforeLazyMixin was brought in as a base class ine583a9e to provide caching for theversion_info property (which was also introduced at that time). At that time,Git had no base class besidesobject, yet this was still present.

Callingsuper().__init__() helps with cooperative multiple inheritance in some cases. It is sometimes done even in the absence of a specific need, though sometimes it's not the correct logic, if the next class in the MRO has an__init__ that is not callable with no arguments (or, rather, with only aself argument). Furthermore, you'vegiven feedback that I have understood to mean that havingGit support inheritance is not a design priority.

So I don't think thissuper().__init__() is present based on a general preference for it. Instead, looking back to when it was first introduced, this was in the first commit that had theGit class,039bfe3. At that time,Git did have a base class,MethodMissingMixin.

It may be that it should either be removed or commented with an explanation. But I think it is sufficiently unconnected toLazyMixin (andversion_info) that no change should be made to it in connection with the changes in this PR.

Effect of directly accessing_version_info has changed

WhenLazyMixin was used, reading from the nonpublic_version_info attribute behaved the same as reading fromversion_info. Code outside theGit class should not do that, but there is one place in GitPython's own tests where it did:

ifrw_repo.git._version_info< (2,29):

That had to be changed to useversion_info instead. If necessary, a different backing attribute could be used, and_version_info could be made an undocumented alternative toversion_info that issues a warning but otherwise behaves the same. However, it seems to me that this is not necessary;_version_info was never advertised as part of the public interface ofGit, as far as I can tell.

GIT_PYTHON_GIT_EXECUTABLE as an instance attribute is not supported

IfGit instances could have their ownGIT_PYTHON_GIT_EXECUTABLE attributes, then they would be used instead of the same-named class attribute that is written in a refresh. This cannot happen on a directGit instance, becauseGit is slotted and has no such slot (and cannot, since the descriptor would conflict with the class attribute). But it is possible to make a subclass ofGit whereGIT_PYTHON_GIT_EXECUTABLE is an instance attribute. This has never been supported and should not be done, and will likely work poorly in other ways, but it is possible for caching to "support" it by detecting that this is the case and just never cachingversion_info.

I have neither done this nor commented about it, and even this mention of it may be gratuitous. However, in general the effect of attempting to set what is assumed to be a class attribute on an instance should be considered. My reasoning for not dealing with this at all is that, even if a reasonable use case arises to derive fromGit and shadow base-class class attributes as instance attributes (which seems unlikely), the onus is then on the author of the derived class to override base-class members likeversion_info accordingly.

(This also uses assertRaises as a context manager, but that isjust for improved clarity.)
This begins to test the established version_info caching behavior.
This independence is also established caching behavior forversion_info.
This reorganization is to facilitate using two separate fake gitcommands with different versions, in forthcoming tests.
The new test doesn't pass yet, asgitpython-developers#1836 is not yet fixed.
Forgitpython-developers#1836.This uses a property with the same logic as before for version_infocaching, except that the _version_info backing attribute holds thevalue None, rather than being unset, for the uncomputed state. Thisrectifies the inconistency between the property's behavior and theway the associated states are represented by its __setstate__ and__getstate__ methods for pickling.Because the Git class only used LazyMixin as an implementationdetail of the version_info attribute, it is removed as a subclass.
Instead of directly accessing the _version_info attribute.This fixes a new test failure since the way the public version_infoproperty uses the _version_info backing attribute has changed, andalso shows the usage that is documented (accessing _version_infowas never guaranteed to work, and now no longer works as before).
Most of these don't pass yet, as such invalidation isn'timplemented yet (gitpython-developers#1829).
This is trickier to test than the other cases, but important enoughthat I think it deserves its own test.
This also makes the xfail marking for Windows correct.
This enables it to run on Windows, removing the xfail marking.+ Rename the test.+ Add comments and reformat.The test still does not pass (on any platform) because it is one ofthe tests of the invalidation feature that is not yet implemented.
That is, that its value is not pickle serialized/deserialized, butalways recomputed with a subprocess call the first time it isaccessed even on a Git instance that is created by unpickling.
+ Put assertion only on the branch where mypy benefits from it.
This broadens the type annoation on the Git.version_info property,forgitpython-developers#1830.It also revises the docstring for clarity, and continuesrefactoring and comment changes (also for clarity).
This modifies two existing test cases to include an assertion aboutthe length. These test cases are retained as there is value intesting on output from a real git command rather than only withtest doubles.More importantly, this also adds a parameterized test method tocheck parsing of:- All numeric, shorter than the limit - all fields used.- All numeric, at the limit - all fields used.- All numeric, longer than the limit - extra fields dropped.- Has unambiguous non-numeric - dropped from there on.- Has ambiguous non-numeric, negative int - dropped from there on.- Has ambiguous non-numeric, number+letter - dropped from there on.The cases for parsing when a field is not numeric (or not fully orunambiguously numeric) currently all fail, because the existinglogic drops intermediate non-numeric fields (gitpython-developers#1833).Parsing should instead stop at (or, *perhaps* in cases like "2a",after) such fields. When the code is changed to stop at themrather than dropping them and presenting the subsequent field asthough it were a previous field, these test cases should also pass.
Forgitpython-developers#1833.This makes version_info parsing stop including fields after thefirst non-numeric field, rather than skipping non-numeric fieldsand including subsequent numeric fields that then wrongly appear tohave the original position and significance of the dropped field.This actually stops at (rather than merely after) a non-numericfield, i.e., potentially parseable fields that are not fullynumeric, such as "2a", are stopped at, rather than parsed as "2".
Copy link
Member

@ByronByron left a comment

Choose a reason for hiding this comment

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

Thanks so much for this fix, which was planned with incredible consideration.

The explanation done in the fantastic PR text is very helpful, and so are the tests. I read each one of them this time and found them very graspable. The sprinkled-in comments also helped.

Great work!

EliahKagan reacted with thumbs up emoji
@ByronByron merged commiteba6fce intogitpython-developers:mainFeb 23, 2024
@EliahKaganEliahKagan deleted the refresh-version branchFebruary 23, 2024 15:02
@ByronByron changed the titleFix version_info cache invalidation, typing, parsing, and serialization📣Fix version_info cache invalidation, typing, parsing, and serialization📣Feb 23, 2024
@ByronByron added the 📣highlight-in-changelog📣Specifically highlight this PR in the changelog after it was created labelMar 19, 2024
@ByronByron changed the title📣Fix version_info cache invalidation, typing, parsing, and serialization📣Fix version_info cache invalidation, typing, parsing, and serializationMar 19, 2024
renovatebot referenced this pull request in allenporter/flux-localMar 31, 2024
[![MendRenovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)This PR contains the following updates:| Package | Change | Age | Adoption | Passing | Confidence ||---|---|---|---|---|---|| [GitPython](https://togithub.com/gitpython-developers/GitPython) |`==3.1.42` -> `==3.1.43` |[![age](https://developer.mend.io/api/mc/badges/age/pypi/GitPython/3.1.43?slim=true)](https://docs.renovatebot.com/merge-confidence/)|[![adoption](https://developer.mend.io/api/mc/badges/adoption/pypi/GitPython/3.1.43?slim=true)](https://docs.renovatebot.com/merge-confidence/)|[![passing](https://developer.mend.io/api/mc/badges/compatibility/pypi/GitPython/3.1.42/3.1.43?slim=true)](https://docs.renovatebot.com/merge-confidence/)|[![confidence](https://developer.mend.io/api/mc/badges/confidence/pypi/GitPython/3.1.42/3.1.43?slim=true)](https://docs.renovatebot.com/merge-confidence/)|---### Release Notes<details><summary>gitpython-developers/GitPython (GitPython)</summary>###[`v3.1.43`](https://togithub.com/gitpython-developers/GitPython/releases/tag/3.1.43)[CompareSource](https://togithub.com/gitpython-developers/GitPython/compare/3.1.42...3.1.43)#### Particularly Important ChangesThese are likely to affect you, please do take a careful look.- Issue and test deprecation warnings by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1886](https://togithub.com/gitpython-developers/GitPython/pull/1886)- Fix version_info cache invalidation, typing, parsing, andserialization by [@&#8203;EliahKagan](https://togithub.com/EliahKagan)in[https://github.com/gitpython-developers/GitPython/pull/1838](https://togithub.com/gitpython-developers/GitPython/pull/1838)- Document manual refresh path treatment by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1839](https://togithub.com/gitpython-developers/GitPython/pull/1839)- Improve static typing and docstrings related to git object types by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1859](https://togithub.com/gitpython-developers/GitPython/pull/1859)#### Other Changes- Test in Docker with Alpine Linux on CI by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1826](https://togithub.com/gitpython-developers/GitPython/pull/1826)- Build online docs (RTD) with -W and dependencies by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1843](https://togithub.com/gitpython-developers/GitPython/pull/1843)- Suggest full-path refresh() in failure message by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1844](https://togithub.com/gitpython-developers/GitPython/pull/1844)- `repo.blame` and `repo.blame_incremental` now accept `None` as the`rev` parameter. by [@&#8203;Gaubbe](https://togithub.com/Gaubbe) in[https://github.com/gitpython-developers/GitPython/pull/1846](https://togithub.com/gitpython-developers/GitPython/pull/1846)- Make sure diff always uses the default diff driver when`create_patch=True` by[@&#8203;can-taslicukur](https://togithub.com/can-taslicukur) in[https://github.com/gitpython-developers/GitPython/pull/1832](https://togithub.com/gitpython-developers/GitPython/pull/1832)- Revise docstrings, comments, and a few messages by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1850](https://togithub.com/gitpython-developers/GitPython/pull/1850)- Expand what is included in the API Reference by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1855](https://togithub.com/gitpython-developers/GitPython/pull/1855)- Restore building of documentation downloads by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1856](https://togithub.com/gitpython-developers/GitPython/pull/1856)- Revise type annotations slightly by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1860](https://togithub.com/gitpython-developers/GitPython/pull/1860)- Updating regex pattern to handle unicode whitespaces. by[@&#8203;jcole-crowdstrike](https://togithub.com/jcole-crowdstrike) in[https://github.com/gitpython-developers/GitPython/pull/1853](https://togithub.com/gitpython-developers/GitPython/pull/1853)- Use upgraded pip in test fixture virtual environment by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1864](https://togithub.com/gitpython-developers/GitPython/pull/1864)- lint: replace `flake8` with `ruff` check by[@&#8203;Borda](https://togithub.com/Borda) in[https://github.com/gitpython-developers/GitPython/pull/1862](https://togithub.com/gitpython-developers/GitPython/pull/1862)- lint: switch Black with `ruff-format` by[@&#8203;Borda](https://togithub.com/Borda) in[https://github.com/gitpython-developers/GitPython/pull/1865](https://togithub.com/gitpython-developers/GitPython/pull/1865)- Update readme and tox.ini for recent tooling changes by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1868](https://togithub.com/gitpython-developers/GitPython/pull/1868)- Split tox lint env into three envs, all safe by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1870](https://togithub.com/gitpython-developers/GitPython/pull/1870)- Slightly broaden Ruff, and update and clarify tool configuration by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1871](https://togithub.com/gitpython-developers/GitPython/pull/1871)- Add a "doc" extra for documentation build dependencies by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1872](https://togithub.com/gitpython-developers/GitPython/pull/1872)- Describe `Submodule.__init__` parent_commit parameter by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1877](https://togithub.com/gitpython-developers/GitPython/pull/1877)- Include TagObject in git.types.Tree_ish by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1878](https://togithub.com/gitpython-developers/GitPython/pull/1878)- Improve Sphinx role usage, including linking Git manpages by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1879](https://togithub.com/gitpython-developers/GitPython/pull/1879)- Replace all wildcard imports with explicit imports by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1880](https://togithub.com/gitpython-developers/GitPython/pull/1880)- Clarify how tag objects are usually tree-ish and commit-ish by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1881](https://togithub.com/gitpython-developers/GitPython/pull/1881)#### New Contributors- [@&#8203;Gaubbe](https://togithub.com/Gaubbe) made their firstcontribution in[https://github.com/gitpython-developers/GitPython/pull/1846](https://togithub.com/gitpython-developers/GitPython/pull/1846)- [@&#8203;can-taslicukur](https://togithub.com/can-taslicukur) madetheir first contribution in[https://github.com/gitpython-developers/GitPython/pull/1832](https://togithub.com/gitpython-developers/GitPython/pull/1832)- [@&#8203;jcole-crowdstrike](https://togithub.com/jcole-crowdstrike)made their first contribution in[https://github.com/gitpython-developers/GitPython/pull/1853](https://togithub.com/gitpython-developers/GitPython/pull/1853)- [@&#8203;Borda](https://togithub.com/Borda) made their firstcontribution in[https://github.com/gitpython-developers/GitPython/pull/1862](https://togithub.com/gitpython-developers/GitPython/pull/1862)**Full Changelog**:gitpython-developers/GitPython@3.1.42...3.1.43</details>---### Configuration📅 **Schedule**: Branch creation - At any time (no schedule defined),Automerge - At any time (no schedule defined).🚦 **Automerge**: Enabled.♻ **Rebasing**: Whenever PR becomes conflicted, or you tick therebase/retry checkbox.🔕 **Ignore**: Close this PR and you won't be reminded about this updateagain.---- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, checkthis box---This PR has been generated by [MendRenovate](https://www.mend.io/free-developer-tools/renovate/). Viewrepository job log[here](https://developer.mend.io/github/allenporter/flux-local).<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy4yNjkuMiIsInVwZGF0ZWRJblZlciI6IjM3LjI2OS4yIiwidGFyZ2V0QnJhbmNoIjoibWFpbiJ9-->Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
lettuce-botbot referenced this pull request in lettuce-financial/github-bot-signed-commitApr 1, 2024
[![MendRenovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)This PR contains the following updates:| Package | Change | Age | Adoption | Passing | Confidence ||---|---|---|---|---|---|| [GitPython](https://togithub.com/gitpython-developers/GitPython) |`==3.1.42` -> `==3.1.43` |[![age](https://developer.mend.io/api/mc/badges/age/pypi/GitPython/3.1.43?slim=true)](https://docs.renovatebot.com/merge-confidence/)|[![adoption](https://developer.mend.io/api/mc/badges/adoption/pypi/GitPython/3.1.43?slim=true)](https://docs.renovatebot.com/merge-confidence/)|[![passing](https://developer.mend.io/api/mc/badges/compatibility/pypi/GitPython/3.1.42/3.1.43?slim=true)](https://docs.renovatebot.com/merge-confidence/)|[![confidence](https://developer.mend.io/api/mc/badges/confidence/pypi/GitPython/3.1.42/3.1.43?slim=true)](https://docs.renovatebot.com/merge-confidence/)|---### Release Notes<details><summary>gitpython-developers/GitPython (GitPython)</summary>###[`v3.1.43`](https://togithub.com/gitpython-developers/GitPython/releases/tag/3.1.43)[CompareSource](https://togithub.com/gitpython-developers/GitPython/compare/3.1.42...3.1.43)#### Particularly Important ChangesThese are likely to affect you, please do take a careful look.- Issue and test deprecation warnings by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1886](https://togithub.com/gitpython-developers/GitPython/pull/1886)- Fix version_info cache invalidation, typing, parsing, andserialization by [@&#8203;EliahKagan](https://togithub.com/EliahKagan)in[https://github.com/gitpython-developers/GitPython/pull/1838](https://togithub.com/gitpython-developers/GitPython/pull/1838)- Document manual refresh path treatment by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1839](https://togithub.com/gitpython-developers/GitPython/pull/1839)- Improve static typing and docstrings related to git object types by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1859](https://togithub.com/gitpython-developers/GitPython/pull/1859)#### Other Changes- Test in Docker with Alpine Linux on CI by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1826](https://togithub.com/gitpython-developers/GitPython/pull/1826)- Build online docs (RTD) with -W and dependencies by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1843](https://togithub.com/gitpython-developers/GitPython/pull/1843)- Suggest full-path refresh() in failure message by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1844](https://togithub.com/gitpython-developers/GitPython/pull/1844)- `repo.blame` and `repo.blame_incremental` now accept `None` as the`rev` parameter. by [@&#8203;Gaubbe](https://togithub.com/Gaubbe) in[https://github.com/gitpython-developers/GitPython/pull/1846](https://togithub.com/gitpython-developers/GitPython/pull/1846)- Make sure diff always uses the default diff driver when`create_patch=True` by[@&#8203;can-taslicukur](https://togithub.com/can-taslicukur) in[https://github.com/gitpython-developers/GitPython/pull/1832](https://togithub.com/gitpython-developers/GitPython/pull/1832)- Revise docstrings, comments, and a few messages by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1850](https://togithub.com/gitpython-developers/GitPython/pull/1850)- Expand what is included in the API Reference by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1855](https://togithub.com/gitpython-developers/GitPython/pull/1855)- Restore building of documentation downloads by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1856](https://togithub.com/gitpython-developers/GitPython/pull/1856)- Revise type annotations slightly by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1860](https://togithub.com/gitpython-developers/GitPython/pull/1860)- Updating regex pattern to handle unicode whitespaces. by[@&#8203;jcole-crowdstrike](https://togithub.com/jcole-crowdstrike) in[https://github.com/gitpython-developers/GitPython/pull/1853](https://togithub.com/gitpython-developers/GitPython/pull/1853)- Use upgraded pip in test fixture virtual environment by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1864](https://togithub.com/gitpython-developers/GitPython/pull/1864)- lint: replace `flake8` with `ruff` check by[@&#8203;Borda](https://togithub.com/Borda) in[https://github.com/gitpython-developers/GitPython/pull/1862](https://togithub.com/gitpython-developers/GitPython/pull/1862)- lint: switch Black with `ruff-format` by[@&#8203;Borda](https://togithub.com/Borda) in[https://github.com/gitpython-developers/GitPython/pull/1865](https://togithub.com/gitpython-developers/GitPython/pull/1865)- Update readme and tox.ini for recent tooling changes by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1868](https://togithub.com/gitpython-developers/GitPython/pull/1868)- Split tox lint env into three envs, all safe by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1870](https://togithub.com/gitpython-developers/GitPython/pull/1870)- Slightly broaden Ruff, and update and clarify tool configuration by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1871](https://togithub.com/gitpython-developers/GitPython/pull/1871)- Add a "doc" extra for documentation build dependencies by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1872](https://togithub.com/gitpython-developers/GitPython/pull/1872)- Describe `Submodule.__init__` parent_commit parameter by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1877](https://togithub.com/gitpython-developers/GitPython/pull/1877)- Include TagObject in git.types.Tree_ish by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1878](https://togithub.com/gitpython-developers/GitPython/pull/1878)- Improve Sphinx role usage, including linking Git manpages by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1879](https://togithub.com/gitpython-developers/GitPython/pull/1879)- Replace all wildcard imports with explicit imports by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1880](https://togithub.com/gitpython-developers/GitPython/pull/1880)- Clarify how tag objects are usually tree-ish and commit-ish by[@&#8203;EliahKagan](https://togithub.com/EliahKagan) in[https://github.com/gitpython-developers/GitPython/pull/1881](https://togithub.com/gitpython-developers/GitPython/pull/1881)#### New Contributors- [@&#8203;Gaubbe](https://togithub.com/Gaubbe) made their firstcontribution in[https://github.com/gitpython-developers/GitPython/pull/1846](https://togithub.com/gitpython-developers/GitPython/pull/1846)- [@&#8203;can-taslicukur](https://togithub.com/can-taslicukur) madetheir first contribution in[https://github.com/gitpython-developers/GitPython/pull/1832](https://togithub.com/gitpython-developers/GitPython/pull/1832)- [@&#8203;jcole-crowdstrike](https://togithub.com/jcole-crowdstrike)made their first contribution in[https://github.com/gitpython-developers/GitPython/pull/1853](https://togithub.com/gitpython-developers/GitPython/pull/1853)- [@&#8203;Borda](https://togithub.com/Borda) made their firstcontribution in[https://github.com/gitpython-developers/GitPython/pull/1862](https://togithub.com/gitpython-developers/GitPython/pull/1862)**Full Changelog**:gitpython-developers/GitPython@3.1.42...3.1.43</details>---### Configuration📅 **Schedule**: Branch creation - At any time (no schedule defined),Automerge - At any time (no schedule defined).🚦 **Automerge**: Disabled by config. Please merge this manually once youare satisfied.♻ **Rebasing**: Whenever PR becomes conflicted, or you tick therebase/retry checkbox.🔕 **Ignore**: Close this PR and you won't be reminded about theseupdates again.---- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, checkthis box---This PR has been generated by [MendRenovate](https://www.mend.io/free-developer-tools/renovate/). Viewrepository job log[here](https://developer.mend.io/github/lettuce-financial/github-bot-signed-commit).<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy4yNjkuMiIsInVwZGF0ZWRJblZlciI6IjM3LjI2OS4yIiwidGFyZ2V0QnJhbmNoIjoibWFpbiJ9-->
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@ByronByronByron approved these changes

Assignees
No one assigned
Labels
📣highlight-in-changelog📣Specifically highlight this PR in the changelog after it was created
Milestone
No milestone
2 participants
@EliahKagan@Byron

[8]ページ先頭

©2009-2025 Movatter.jp