From 10a1a16220e651972281fe647c405e9ebe938d6c Mon Sep 17 00:00:00 2001 From: Lea Anthony Date: Sun, 14 Jun 2026 10:29:10 +1000 Subject: [PATCH 1/4] fix(v3/ci): quote pipe in 'wails3 tool has gcc|clang' Taskfile command The shell in Task's `sh:` var interprets the bare `|` as a pipe, running `wails3 tool has gcc` and piping its output to `clang`. clang exits 1 with "no input files", failing all Linux template builds. Fix: wrap the argument in shell double-quotes so the pipe is passed literally to the Go program, which splits on `|` to check each tool. Regressed in #5533 (0464978ce). --- v3/internal/commands/build_assets/linux/Taskfile.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/v3/internal/commands/build_assets/linux/Taskfile.yml b/v3/internal/commands/build_assets/linux/Taskfile.yml index d46271f7888..db3bf3ac074 100644 --- a/v3/internal/commands/build_assets/linux/Taskfile.yml +++ b/v3/internal/commands/build_assets/linux/Taskfile.yml @@ -36,7 +36,7 @@ tasks: TARGET_ARCH: '{{.ARCH | default ARCH}}' # Check if a C compiler is available (gcc or clang) — cross-platform via wails3 tool HAS_CC: - sh: 'wails3 tool has gcc|clang' + sh: 'wails3 tool has "gcc|clang"' build:native: summary: Builds the application natively on Linux From 47d5b423033a009ae7864d008ac9bd28780bc646 Mon Sep 17 00:00:00 2001 From: Lea Anthony Date: Sun, 14 Jun 2026 11:17:40 +1000 Subject: [PATCH 2/4] fix(v3/generator): disable workspace mode when loading packages for binding generation Go 1.25 changed behaviour for modules nested inside a Go workspace but not listed as workspace members: packages.Load returns the package with errors, leaving TypesInfo.Instances empty. The binding generator then finds zero services, produces no output, and the frontend vite build fails with 'Cannot find module ../bindings/'. Fix: set GOWORK=off in the packages.Config.Env for both ResolvePatterns and LoadPackages. The binding generator analyses source code in isolation and never needs workspace-level module routing; the module's own go.mod replace directives are still honoured when GOWORK=off. Fixes all Test Templates CI failures on ubuntu/macos/windows. --- v3/internal/generator/load.go | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/v3/internal/generator/load.go b/v3/internal/generator/load.go index da09ff76fb1..5bfe2c547a1 100644 --- a/v3/internal/generator/load.go +++ b/v3/internal/generator/load.go @@ -4,6 +4,7 @@ import ( "go/ast" "go/parser" "go/token" + "os" "github.com/wailsapp/wails/v3/internal/generator/config" "golang.org/x/tools/go/packages" @@ -67,6 +68,7 @@ func ResolvePatterns(buildFlags []string, patterns ...string) (paths []string, e pkgs, err := packages.Load(&packages.Config{ Mode: packages.NeedName, BuildFlags: buildFlags, + Env: append(os.Environ(), "GOWORK=off"), }, rewrittenPatterns...) for _, pkg := range pkgs { @@ -105,6 +107,10 @@ func LoadPackages(buildFlags []string, patterns ...string) (pkgs []*packages.Pac Mode: packages.LoadAllSyntax, BuildFlags: buildFlags, Fset: fset, + // Disable workspace mode: if the project lives inside a Go workspace but is + // not listed as a workspace module, Go 1.25 emits package errors that leave + // TypesInfo incomplete, causing the generator to find zero services. + Env: append(os.Environ(), "GOWORK=off"), ParseFile: func(fset *token.FileSet, filename string, src []byte) (file *ast.File, err error) { file, err = parser.ParseFile(fset, filename, src, parser.ParseComments|parser.SkipObjectResolution) return From 9e645826da791ccd924e73e3b9d2428354325fb2 Mon Sep 17 00:00:00 2001 From: Lea Anthony Date: Sun, 14 Jun 2026 11:35:43 +1000 Subject: [PATCH 3/4] fix(v3/ci): register generated template project in workspace before build MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Go 1.25 rejects packages in a module that is nested under the workspace root but not listed in go.work — packages.Load returns errors that leave TypesInfo.Instances empty, causing the bindings generator to find zero services and produce no frontend/bindings/ output. The template test step creates a new project inside the repo tree (which is a Go workspace), so the project module is nested but unlisted. Fix by running 'go work use .' in the generated project directory before 'wails3 build'. This registers the project as a proper workspace member so Go 1.25 loads its packages correctly and bindings are generated. Revert the earlier GOWORK=off approach in load.go — disabling workspace mode in the generator would break local development workflows where go.work ties v3 and webview2 changes together. --- .github/workflows/build-and-test-v3.yml | 3 +++ v3/internal/generator/load.go | 6 ------ 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/.github/workflows/build-and-test-v3.yml b/.github/workflows/build-and-test-v3.yml index 1a0c617d724..e0f6f205f57 100644 --- a/.github/workflows/build-and-test-v3.yml +++ b/.github/workflows/build-and-test-v3.yml @@ -284,6 +284,9 @@ jobs: # Replace @wailsio/runtime version with local tarball npm pkg set dependencies.@wailsio/runtime="file://$RUNTIME_TGZ" cd .. + # Register the generated project in the workspace so Go 1.25 workspace + # mode does not reject packages in a module not listed in go.work. + go work use . wails3 build # GTK3 legacy template builds are covered by the Go example compilation tests above. diff --git a/v3/internal/generator/load.go b/v3/internal/generator/load.go index 5bfe2c547a1..da09ff76fb1 100644 --- a/v3/internal/generator/load.go +++ b/v3/internal/generator/load.go @@ -4,7 +4,6 @@ import ( "go/ast" "go/parser" "go/token" - "os" "github.com/wailsapp/wails/v3/internal/generator/config" "golang.org/x/tools/go/packages" @@ -68,7 +67,6 @@ func ResolvePatterns(buildFlags []string, patterns ...string) (paths []string, e pkgs, err := packages.Load(&packages.Config{ Mode: packages.NeedName, BuildFlags: buildFlags, - Env: append(os.Environ(), "GOWORK=off"), }, rewrittenPatterns...) for _, pkg := range pkgs { @@ -107,10 +105,6 @@ func LoadPackages(buildFlags []string, patterns ...string) (pkgs []*packages.Pac Mode: packages.LoadAllSyntax, BuildFlags: buildFlags, Fset: fset, - // Disable workspace mode: if the project lives inside a Go workspace but is - // not listed as a workspace module, Go 1.25 emits package errors that leave - // TypesInfo incomplete, causing the generator to find zero services. - Env: append(os.Environ(), "GOWORK=off"), ParseFile: func(fset *token.FileSet, filename string, src []byte) (file *ast.File, err error) { file, err = parser.ParseFile(fset, filename, src, parser.ParseComments|parser.SkipObjectResolution) return From 26af4a0f9c9b5940b5dd953c72501be4c7d3a3f1 Mon Sep 17 00:00:00 2001 From: Lea Anthony Date: Sun, 14 Jun 2026 11:46:02 +1000 Subject: [PATCH 4/4] ci: re-trigger CI run (artifact unavailable after re-run)