Sui.

Post

Share your knowledge.

HaGiang.
Jul 26, 2025
Expert Q&A

Do I have to upgrade my package too?

I am getting version error as one of the dependency has upgraded their version, how to resolve this error ?? Do I have to upgrade my package too?

  • Sui
  • SDKs and Developer Tools
0
6
Share
Comments
.

Answers

6
Arnold.
Arnold3036
Jul 29 2025, 14:58

Yes, upgrade your package to match the dependency's version or lock it to a compatible version.

# Check outdated deps (Node.js example)
npm outdated  

# Upgrade all (or specific) deps  
npm update  
# OR lock a version in package.json  
"your-dep": "1.2.x"  

Key Fixes:

  1. Update your package: npm update / cargo update (Rust).
  2. Pin versions: Manually set a compatible version.
  3. Check changelog: Avoid breaking changes.

For Go (Sui):

go get -u github.com/your-dep@latest  

Fix conflicts in go.mod/package.json.

4
Comments
.
Evgeniy CRYPTOCOIN.
Jul 30 2025, 08:54

Yes, you likely need to upgrade your package to match the dependency’s new version.

Steps to Fix:

  1. Update Move.toml – Bump your package version and align dependency versions.
  2. Resolve Breaking Changes – Check the dependency’s changelog for required updates in your code.
  3. Test Thoroughly – Run sui move test to catch compatibility issues.

Pro Tip: Use sui move upgrade (if available) to automate version syncs.

(Mismatched versions cause "incompatible dependency" errors—always keep dependencies in sync.)

4
Comments
.
Alya.
Alya-14
Jul 31 2025, 14:34

Yes, if a dependency upgraded, you may need to recompile and upgrade your package to resolve version mismatches. Run sui move build, then sui client publish (or upgrade) with proper dependencies. Always pin correct versions in Move.toml.

4
Comments
.
lucid-obsidian.
Aug 11 2025, 06:58

Yes, if one of your dependencies has upgraded its version and you’re getting a version mismatch or incompatibility error, you’ll likely need to upgrade your package to match that dependency’s new version. In the Sui Move framework (and similar dependency-managed environments), every package and module version is tightly coupled by object IDs and build metadata. If your package depends on an outdated version, the compiler will throw a version error because it can't resolve or link to the new dependency state.

2
Comments
.
shamueely.
Jul 26 2025, 17:55

Yes, if one of your dependencies has upgraded its version and you’re getting a version mismatch or incompatibility error, you’ll likely need to upgrade your package to match that dependency’s new version. In the Sui Move framework (and similar dependency-managed environments), every package and module version is tightly coupled by object IDs and build metadata. If your package depends on an outdated version, the compiler will throw a version error because it can't resolve or link to the new dependency state.

Here’s how to resolve it:

  • Open your Move.toml and check the [dependencies] section. Update the dependency reference—whether it's a local path, Git commit, or version tag—to match the latest one.

  • If you're using a local dependency like sui-framework, pull or clone the updated version and point your path to it:

    [dependencies]
    sui = { local = "../sui-framework" }
    
  • Update your [addresses] block to reflect any new module addresses (e.g., if std = "0x1" or sui = "0x2" changed).

  • Run sui move build again. If there are still version-related errors, you may need to check the modules that changed and adjust your imports or types accordingly.

Yes, you do have to upgrade your package if it depends on a module that changed in structure, ABI, or address format. Not doing so leads to version conflicts and broken builds.

For full guidance on managing dependencies in Sui Move, read: https://docs.sui.io/build/move/manage-dependencies

1
Comments
.
290697tz.
Jul 27 2025, 06:52

If a dependency has upgraded and your current version is incompatible, you may need to upgrade your package. Check the version constraints in your package.json or Move.toml. Run npm update or manually update the version if using JavaScript/TypeScript. For Move, ensure compatibility with the new version and recompile. Always test after upgrading to avoid breaking changes.

1
Comments
.

Do you know the answer?

Please log in and share it.