Al-HUWAITI Shell
Al-huwaiti


Server : LiteSpeed
System : Linux in-mum-web1333.main-hosting.eu 4.18.0-553.37.1.lve.el8.x86_64 #1 SMP Mon Feb 10 22:45:17 UTC 2025 x86_64
User : u141265441 ( 141265441)
PHP Version : 8.4.3
Disable Function : system, exec, shell_exec, passthru, mysql_list_dbs, ini_alter, dl, symlink, link, chgrp, leak, popen, apache_child_terminate, virtual, mb_send_mail
Directory :  /proc/self/root/opt/golang/1.22.0/src/cmd/go/testdata/script/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : //proc/self/root/opt/golang/1.22.0/src/cmd/go/testdata/script/goline_order.txt
# Check that go lines are always >= go lines of dependencies.

# Using too old a release cannot even complete module load.
env TESTGO_VERSION=go1.21.1
env TESTGO_VERSION_SWITCH=switch
cp go.mod go.mod.orig

# If the offending module is not imported, it's not detected.
go list
cmp go.mod go.mod.orig

# Adding the import produces the error.
# Maybe this should auto-switch, but it requires more plumbing to get this error through,
# and it's a misconfigured system that should not arise in practice, so not switching is fine.
! go list -deps -tags usem1
cmp go.mod go.mod.orig
stderr '^go: module ./m1 requires go >= 1.21.2 \(running go 1.21.1\)$'

# go get go@1.21.2 fixes the error.
cp go.mod.orig go.mod
go get go@1.21.2
go list -deps -tags usem1

# go get -tags usem1 fixes the error.
cp go.mod.orig go.mod
go get -tags usem1
go list -deps -tags usem1

# go get fixes the error.
cp go.mod.orig go.mod
go get
go list -deps -tags usem1

# Using a new enough release reports the error after module load and suggests 'go mod tidy'
env TESTGO_VERSION=go1.21.2
cp go.mod.orig go.mod
! go list -deps -tags usem1
stderr 'updates to go.mod needed'
stderr 'go mod tidy'
go mod tidy
go list -deps -tags usem1

# go get also works
cp go.mod.orig go.mod
! go list -deps -tags usem1
stderr 'updates to go.mod needed'
stderr 'go mod tidy'
go get go@1.21.2
go list -deps -tags usem1


-- go.mod --
module m
go 1.21.1

require m1 v0.0.1

replace m1 => ./m1

-- m1/go.mod --
go 1.21.2

-- p.go --
//go:build usem1

package p

import _ "m1"

-- p1.go --
package p

-- m1/p.go --
package p

Al-HUWAITI Shell