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

feat: implement mvs specific functions (buildList, Upgrade, Downgrade) #292

Merged
merged 20 commits into from
May 15, 2024

Conversation

AkashKumar7902
Copy link
Contributor

@AkashKumar7902 AkashKumar7902 commented Mar 28, 2024

Implementation of previous, upgrade, required, max from go mvs

1. Does this PR affect any open issues?(Y/N) and add issue references (e.g. "fix #123", "re #123".):

  • N
  • Y

fix #246

2. What is the scope of this PR (e.g. component or file name):

3. Provide a description of the PR(e.g. more details, effects, motivations or doc link):

  • Affects user behaviors
  • Contains syntax changes
  • Contains variable changes
  • Contains experimental features
  • Performance regression: Consumes more CPU
  • Performance regression: Consumes more Memory
  • Other

4. Are there any breaking changes?(Y/N) and describe the breaking changes(e.g. more details, motivations or doc link):

  • N
  • Y

5. Are there test cases for these changes?(Y/N) select and add more details, references or doc links:

  • Unit test
  • Integration test
  • Benchmark (add benchmark stats below)
  • Manual test (add detailed scripts or steps below)
  • Other

@AkashKumar7902 AkashKumar7902 marked this pull request as draft March 28, 2024 19:21
@Peefy
Copy link
Contributor

Peefy commented Apr 10, 2024

@zong-zhe Can you help review and provide some more professional comments and guidance? Thank you!

pkg/package/package.go Outdated Show resolved Hide resolved
pkg/mvs/mvs.go Outdated Show resolved Hide resolved
@AkashKumar7902 AkashKumar7902 requested a review from Peefy May 12, 2024 19:18
@AkashKumar7902 AkashKumar7902 marked this pull request as ready for review May 12, 2024 19:18
@AkashKumar7902 AkashKumar7902 changed the title feat: implement mvs (buildlist) feat: implement mvs specific functions (buildList, Upgrade, Downgrade) May 13, 2024
@Peefy
Copy link
Contributor

Peefy commented May 14, 2024

The PR conflict, please rebase the main branch.

Copy link
Contributor

@Peefy Peefy left a comment

Choose a reason for hiding this comment

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

LGTM

@AkashKumar7902
Copy link
Contributor Author

@Peefy I have resolved the conflict, also current lint failure is due to the code imported from go codebase, things might break if we change 3rdparty code to fix lint issue.

@AkashKumar7902
Copy link
Contributor Author

I will send another PR containing all the cmd commands.

@Peefy
Copy link
Contributor

Peefy commented May 14, 2024

@Peefy I have resolved the conflict, also current lint failure is due to the code imported from go codebase, things might break if we change 3rdparty code to fix lint issue.

OK, you can fix the unit tests firstly.

@AkashKumar7902 AkashKumar7902 force-pushed the lfx-2024 branch 2 times, most recently from 7fbf385 to 35dd736 Compare May 14, 2024 16:08
Signed-off-by: Akash Kumar <[email protected]>
@AkashKumar7902 AkashKumar7902 force-pushed the lfx-2024 branch 2 times, most recently from 6c68049 to f5b3601 Compare May 14, 2024 16:29
Signed-off-by: Akash Kumar <[email protected]>
Signed-off-by: Akash Kumar <[email protected]>
Signed-off-by: Akash Kumar <[email protected]>
@coveralls
Copy link

coveralls commented May 14, 2024

Pull Request Test Coverage Report for Build 9089374989

Details

  • 458 of 799 (57.32%) changed or added relevant lines in 11 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+1.9%) to 44.982%

Changes Missing Coverage Covered Lines Changed/Added Lines %
pkg/client/client.go 25 26 96.15%
pkg/package/toml.go 1 4 25.0%
pkg/cmd/cmd_graph.go 0 9 0.0%
pkg/oci/oci.go 0 11 0.0%
pkg/semver/semver.go 21 40 52.5%
pkg/package/modfile.go 15 36 41.67%
pkg/mvs/mvs.go 100 136 73.53%
pkg/3rdparty/mvs/errors.go 0 55 0.0%
pkg/3rdparty/mvs/mvs.go 238 294 80.95%
pkg/git/git.go 0 61 0.0%
Totals Coverage Status
Change from base Build 9044889480: 1.9%
Covered Lines: 2465
Relevant Lines: 5480

💛 - Coveralls

pkg/cmd/cmd_tidy.go Outdated Show resolved Hide resolved
@@ -235,3 +235,16 @@ func TestGetFilePath(t *testing.T) {
assert.Equal(t, mfile.GetModFilePath(), filepath.Join(testPath, MOD_FILE))
assert.Equal(t, mfile.GetModLockFilePath(), filepath.Join(testPath, MOD_LOCK_FILE))
}

func TestGenSource(t *testing.T) {
Copy link
Contributor

Choose a reason for hiding this comment

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

TestAddWithGitCommit failed on windows in CI.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Fixed it!

Signed-off-by: Akash Kumar <[email protected]>
Signed-off-by: Akash Kumar <[email protected]>
Signed-off-by: Akash Kumar <[email protected]>
@Peefy Peefy merged commit 83ebb23 into kcl-lang:main May 15, 2024
4 of 6 checks passed
@Peefy Peefy mentioned this pull request May 17, 2024
16 tasks
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.

Feature: Package Version Management for kpm Enhancement: kpm add command displaying optimization
3 participants