Skip to content

Conversation

@hyabean
Copy link
Contributor

@hyabean hyabean commented Dec 27, 2021

Description

Fixes #2927

Related Issue

#2927

Motivation and Context

Invalid use of Lazy leads the fix of #2933 doesn't work properly. this.versionContext.Value will always be null. This problem was bypassed by way of early access in unit test.
if replace

        bool isCurrentCommitTagged = this.versionContext.IsValueCreated &&
            this.versionContext.Value.IsCurrentCommitTagged;

with
bool isCurrentCommitTagged = context.IsCurrentCommitTagged;,
will cause many other unit tests failed.
So I have to move the if statement into the NormalizeGitDirectory method.

How Has This Been Tested?

Tested the reproduce case in #2927.
all unit tests passed

Screenshots (if appropriate):

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

@hyabean
Copy link
Contributor Author

hyabean commented Dec 27, 2021

@asbjornu I made a mistake in #2933 and #2927. The unit tests passed, but the .exe doesn't work.
some unit test still fail. When will the next version release?

@hyabean
Copy link
Contributor Author

hyabean commented Dec 28, 2021

open an other PR

@hyabean hyabean closed this Dec 28, 2021
@hyabean hyabean deleted the main branch December 30, 2021 03:16
@hyabean hyabean restored the main branch December 30, 2021 03:18
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.

[Bug]Failed to try and guess branch to use. Move one of the branches along a commit to remove warning

1 participant