I am trying out Aqua on some packages and getting an error I cannot see to figure out.
julia> Aqua.test_all(Winding;stale_deps=true)
Test Summary: | Pass Total Time
Method ambiguity | 1 1 2.5s
Test Summary: | Pass Total Time
Unbound type parameters | 1 1 0.0s
Test Summary: | Pass Total Time
Undefined exports | 1 1 0.0s
Compare Project.toml and test/Project.toml: Test Failed at C:\Users\jakez\.julia\packages\Aqua\MCcFg\src\project_extras.jl:12
Expression: isempty(msgs)
Evaluated: isempty(["Root and test projects should be consistent for projects supporting Julia <= 1.1.", "Test dependencies not in root project (C:\\Users\\jakez\\.julia\\packages\\Winding\\NFBrz\\Project.toml):\n\tJLD2 [033835bb-8acc-5ee8-8aae-3f567f8a3819]"])
Stacktrace:
[1] macro expansion
@ C:\Users\jakez\.julia\juliaup\julia-1.11.6+0.x64.w64.mingw32\share\julia\stdlib\v1.11\Test\src\Test.jl:680 [inlined]
[2] test_project_extras(pkg::Base.PkgId; kwargs::@Kwargs{})
@ Aqua C:\Users\jakez\.julia\packages\Aqua\MCcFg\src\project_extras.jl:12
[3] test_project_extras
@ C:\Users\jakez\.julia\packages\Aqua\MCcFg\src\project_extras.jl:10 [inlined]
[4] #test_project_extras#24
@ C:\Users\jakez\.julia\packages\Aqua\MCcFg\src\project_extras.jl:23 [inlined]
[5] test_project_extras
@ C:\Users\jakez\.julia\packages\Aqua\MCcFg\src\project_extras.jl:22 [inlined]
[6] macro expansion
@ C:\Users\jakez\.julia\packages\Aqua\MCcFg\src\Aqua.jl:89 [inlined]
[7] macro expansion
@ C:\Users\jakez\.julia\juliaup\julia-1.11.6+0.x64.w64.mingw32\share\julia\stdlib\v1.11\Test\src\Test.jl:1709 [inlined]
[8] test_all(testtarget::Module; ambiguities::Bool, unbound_args::Bool, undefined_exports::Bool, project_extras::Bool, stale_deps::Bool, deps_compat::Bool, piracies::Bool, persistent_tasks::Bool, undocumented_names::Bool)
@ Aqua C:\Users\jakez\.julia\packages\Aqua\MCcFg\src\Aqua.jl:88
Test Summary: | Fail Total Time
Compare Project.toml and test/Project.toml | 1 1 0.0s
ERROR: Some tests did not pass: 0 passed, 1 failed, 0 errored, 0 broken.
On a related note, I set the Julia version compat for both teh project and teh test environment to 1.10 but when I look at the Project.toml it gives:
[compat]
StatsBase = "0.34.6"
julia = "1"
These issue may be related? In that there seems to be special handling in the Project.toml files for Julia prior to v1.2. I thought setting the Julia compat to 1.10 would eliminate that checking?
On a related note I set the Julia version compat for both the project and the test environment to 1.10, but when I look at the Project.toml file it gives
How did you set that compat if not in the Project.toml file?
In any case, that doesn’t seem direclty related, test_all docs say that project_extras = true by default. So you have to change your call to Aqua.test_all(Winding;stale_deps=true, project_extras=false) yourself, it doesn’t seem like it checks the Julia version compat bounds of the project.
Edit: When I had the test environment activated I used activate .. thinking that it would go up one level from the currently activated environment. I found out this is not the case it goes up one level from the current working directory of Julia. I will edit the original post below.
The compat confusion arose from this misunderstanding.
I did just remove the [extras] and [target] parts of the Project.toml.
And finally note that Aqua is finding a reference to Statistics even though it is not in the [deps] section of the Project.toml.
julia> Aqua.test_all(Winding;stale_deps=true, project_extras=false)
Test Summary: | Pass Total Time
Method ambiguity | 1 1 2.4s
Test Summary: | Pass Total Time
Unbound type parameters | 1 1 0.0s
Test Summary: | Pass Total Time
Undefined exports | 1 1 0.0s
Test Summary: | Pass Total Time
Stale dependencies | 1 1 0.8s
Base.PkgId(Base.UUID("49faafe7-1138-4428-b534-1ec25822d20a"), "Winding") does not declare a compat entry for the following deps:
2-element Vector{Base.PkgId}:
SmoothingSplines [102930c3-cf33-599f-b3b1-9a29a5acab30]
Statistics [10745b16-79ce-11e8-11f9-7d13ad32a3b2]
Base.PkgId(Base.UUID("49faafe7-1138-4428-b534-1ec25822d20a"), "Winding") deps: Test Failed at C:\Users\jakez\.julia\packages\Aqua\MCcFg\src\deps_compat.jl:60
Expression: isempty(result)
Evaluated: isempty(Base.PkgId[Base.PkgId(Base.UUID("102930c3-cf33-599f-b3b1-9a29a5acab30"), "SmoothingSplines"), Base.PkgId(Base.UUID("10745b16-79ce-11e8-11f9-7d13ad32a3b2"), "Statistics")])
Stacktrace:
[1] macro expansion
@ C:\Users\jakez\.julia\juliaup\julia-1.11.6+0.x64.w64.mingw32\share\julia\stdlib\v1.11\Test\src\Test.jl:680 [inlined]
[2] test_deps_compat(pkg::Base.PkgId, deps_type::String; broken::Bool, kwargs::@Kwargs{})
@ Aqua C:\Users\jakez\.julia\packages\Aqua\MCcFg\src\deps_compat.jl:60
[3] test_deps_compat
@ C:\Users\jakez\.julia\packages\Aqua\MCcFg\src\deps_compat.jl:55 [inlined]
[4] macro expansion
@ C:\Users\jakez\.julia\packages\Aqua\MCcFg\src\deps_compat.jl:41 [inlined]
[5] macro expansion
@ C:\Users\jakez\.julia\juliaup\julia-1.11.6+0.x64.w64.mingw32\share\julia\stdlib\v1.11\Test\src\Test.jl:1709 [inlined]
[6] test_deps_compat(pkg::Base.PkgId; check_julia::Bool, check_extras::Bool, check_weakdeps::Bool, kwargs::@Kwargs{})
@ Aqua C:\Users\jakez\.julia\packages\Aqua\MCcFg\src\deps_compat.jl:41
Base.PkgId(Base.UUID("49faafe7-1138-4428-b534-1ec25822d20a"), "Winding") does not declare a compat entry for the following extras:
1-element Vector{Base.PkgId}:
Test [8dfed614-e22c-5e08-85e1-65c5234f0b40]
Base.PkgId(Base.UUID("49faafe7-1138-4428-b534-1ec25822d20a"), "Winding") extras: Test Failed at C:\Users\jakez\.julia\packages\Aqua\MCcFg\src\deps_compat.jl:60
Expression: isempty(result)
Evaluated: isempty(Base.PkgId[Base.PkgId(Base.UUID("8dfed614-e22c-5e08-85e1-65c5234f0b40"), "Test")])
Stacktrace:
[1] macro expansion
@ C:\Users\jakez\.julia\juliaup\julia-1.11.6+0.x64.w64.mingw32\share\julia\stdlib\v1.11\Test\src\Test.jl:680 [inlined]
[2] test_deps_compat(pkg::Base.PkgId, deps_type::String; broken::Bool, kwargs::@Kwargs{})
@ Aqua C:\Users\jakez\.julia\packages\Aqua\MCcFg\src\deps_compat.jl:60
[3] test_deps_compat
@ C:\Users\jakez\.julia\packages\Aqua\MCcFg\src\deps_compat.jl:55 [inlined]
[4] macro expansion
@ C:\Users\jakez\.julia\packages\Aqua\MCcFg\src\deps_compat.jl:45 [inlined]
[5] macro expansion
@ C:\Users\jakez\.julia\juliaup\julia-1.11.6+0.x64.w64.mingw32\share\julia\stdlib\v1.11\Test\src\Test.jl:1709 [inlined]
[6] test_deps_compat(pkg::Base.PkgId; check_julia::Bool, check_extras::Bool, check_weakdeps::Bool, kwargs::@Kwargs{})
@ Aqua C:\Users\jakez\.julia\packages\Aqua\MCcFg\src\deps_compat.jl:45
Test Summary: | Pass Fail Total Time
Compat bounds | 2 2 4 0.0s
julia | 1 1 0.0s
Base.PkgId(Base.UUID("49faafe7-1138-4428-b534-1ec25822d20a"), "Winding") deps | 1 1 0.0s
Base.PkgId(Base.UUID("49faafe7-1138-4428-b534-1ec25822d20a"), "Winding") extras | 1 1 0.0s
Base.PkgId(Base.UUID("49faafe7-1138-4428-b534-1ec25822d20a"), "Winding") weakdeps | 1 1 0.0s
ERROR: Some tests did not pass: 2 passed, 2 failed, 0 errored, 0 broken.
So the error has changed but there are others. I did a resolve to ensure the Project and Manifest tomls are in sync