Steps to Reproduce Issue
I can reproduce a regression where sui move build no longer emits compiler warnings in Sui 1.72.1. The same package emits warnings in Sui 1.71.1.
Minimal package:
tmp=$(mktemp -d)
mkdir -p "$tmp/sources"
cat > "$tmp/Move.toml" <<'TOML'
[package]
name = "warnprobe"
edition = "2024"
[dependencies]
TOML
cat > "$tmp/sources/m.move" <<'MOVE'
module warnprobe::m;
use std::option::Option;
use std::vector;
public fun f(x: Option<u64>): Option<u64> { x }
MOVE
sui move build -p "$tmp" --force
I tested the same package with these binaries:
sui 1.71.1-2f5992f189cd
sui 1.72.1-94ad8ccd0ed6
Expected Result
Sui 1.72.1 should report the same warnings as 1.71.1. For the package above, Sui 1.71.1 emits diagnostics such as:
warning[W02021]: duplicate alias
./sources/m.move:2:18
Unnecessary alias 'Option' for module member 'std::option::Option'. This alias is provided by default
warning[W02021]: duplicate alias
./sources/m.move:3:10
Unnecessary alias 'vector' for module 'std::vector'. This alias is provided by default
warning[W09001]: unused alias
./sources/m.move:3:10
Unused 'use' of alias 'vector'. Consider removing it
Actual Result
With Sui 1.71.1, sui move build -p "$tmp" --force exits with status 0 and emits the W02021 and W09001 warnings above.
With Sui 1.72.1, the same command exits with status 0 but prints no warnings:
INCLUDING DEPENDENCY MoveStdlib
INCLUDING DEPENDENCY Sui
BUILDING warnprobe
This is not specifically about --warnings-are-errors. That flag only makes the regression easier to catch in CI: in 1.71.1, adding --warnings-are-errors turns the warnings into errors and exits non-zero, while in 1.72.1 the warnings are still not emitted.
I also observed the same class of issue through the language server path: sui analyzer / move-analyzer from 1.72 does not publish the duplicate_alias diagnostics for source files where the 1.71 move-analyzer does.
This looks like a regression between 1.71 and 1.72 rather than an intentional removal of the diagnostic: DuplicateAlias still appears to be a warning code, and compiler snapshot tests still appear to expect duplicate alias warnings. The warning filtering rewrite in #26282 may be related, but I have not confirmed the exact root cause.
System Information
- OS: Ubuntu Linux x86_64, kernel
6.8.0-111-generic
- Compiler affected:
sui 1.72.1-94ad8ccd0ed6
- Compiler comparison:
sui 1.71.1-2f5992f189cd
Steps to Reproduce Issue
I can reproduce a regression where
sui move buildno longer emits compiler warnings in Sui 1.72.1. The same package emits warnings in Sui 1.71.1.Minimal package:
I tested the same package with these binaries:
Expected Result
Sui 1.72.1 should report the same warnings as 1.71.1. For the package above, Sui 1.71.1 emits diagnostics such as:
Actual Result
With Sui 1.71.1,
sui move build -p "$tmp" --forceexits with status 0 and emits theW02021andW09001warnings above.With Sui 1.72.1, the same command exits with status 0 but prints no warnings:
This is not specifically about
--warnings-are-errors. That flag only makes the regression easier to catch in CI: in 1.71.1, adding--warnings-are-errorsturns the warnings into errors and exits non-zero, while in 1.72.1 the warnings are still not emitted.I also observed the same class of issue through the language server path:
sui analyzer/move-analyzerfrom 1.72 does not publish theduplicate_aliasdiagnostics for source files where the 1.71move-analyzerdoes.This looks like a regression between 1.71 and 1.72 rather than an intentional removal of the diagnostic:
DuplicateAliasstill appears to be a warning code, and compiler snapshot tests still appear to expect duplicate alias warnings. The warning filtering rewrite in #26282 may be related, but I have not confirmed the exact root cause.System Information
6.8.0-111-genericsui 1.72.1-94ad8ccd0ed6sui 1.71.1-2f5992f189cd