Skip to content

chore(deps): replace mitchellh/mapstructure with go-viper/mapstructure/v2#176

Merged
mathieu-benoit merged 1 commit intoscore-spec:mainfrom
Abhishek9639:fix/replace-mapstructure
Apr 7, 2026
Merged

chore(deps): replace mitchellh/mapstructure with go-viper/mapstructure/v2#176
mathieu-benoit merged 1 commit intoscore-spec:mainfrom
Abhishek9639:fix/replace-mapstructure

Conversation

@Abhishek9639
Copy link
Copy Markdown
Contributor

Description

Replace the archived mitchellh/mapstructure dependency with the actively maintained go-viper/mapstructure/v2 fork.

Changes:

  • Updated the import in loader/loader.go from github.com/mitchellh/mapstructure to github.com/go-viper/mapstructure/v2.
  • Updated go.mod to use github.com/go-viper/mapstructure/v2 v2.5.0.
  • Ran go mod tidy to update go.sum.

What does this PR do?

mitchellh/mapstructure was archived by the author and is no longer maintained, which means no future bug fixes or security patches. This PR swaps it out for go-viper/mapstructure/v2, which is the maintained fork with the same API.

This is part of the effort tracked in score-spec/score-compose#443.

Types of changes

  • New chore (expected functionality to be implemented)

Checklist:

  • I've signed off with an email address that matches the commit author.

mitchellh/mapstructure is archived and no longer maintained. Replace it with the actively maintained fork go-viper/mapstructure/v2, which is a drop-in replacement with the same API.

Signed-off-by: Abhishek <abhishekup082@gmail.com>
@Abhishek9639
Copy link
Copy Markdown
Contributor Author

Hi @mathieu-benoit,
Just opened the PR for step 1 over at the score-go repo. Let me know if everything looks good there or if any changes are needed before we move to the next step.
Thanks!

Copy link
Copy Markdown
Contributor

@mathieu-benoit mathieu-benoit left a comment

Choose a reason for hiding this comment

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

LGTM, thanks for detailed explanation and the implementation, @Abhishek9639!

@mathieu-benoit mathieu-benoit merged commit 15ab585 into score-spec:main Apr 7, 2026
6 checks passed
@Abhishek9639
Copy link
Copy Markdown
Contributor Author

Awesome, thanks. I'll move on to step 2 (score-implementation-sample). Should I wait for a new release of score-go to be cut first so I can bump the dependency, or just point it to the main branch for now?

@mathieu-benoit
Copy link
Copy Markdown
Contributor

mathieu-benoit commented Apr 7, 2026

Hi @Abhishek9639, FYI I just updated this ticket there score-spec/score-compose#443 (comment). tl,dr: score-go already released and successfully integrated in score-implementation-sample (Dependabot did the job). You are now good to go to integrate the new score-go version in score-compose 😃

@Abhishek9639
Copy link
Copy Markdown
Contributor Author

Got it, thanks for the update. I’ll proceed with integrating the new score-go version into score-compose.

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.

2 participants