Trying to install QML.jl without success

Hello all!

I decided to try what I can do with QML but I got stuck before even getting started i.e. in the installation phase. Here’s what I tried and what happened:


PC: Razer Blade 15
OS: Win 10 (with all updates)
Julia 1.6.1

What I’ve done:
  1. Removing Julia and .julia directory (and the line in PATH env.var.) to get a clean slate

  2. Installing Julia 1.6.1 with the PATH updates

  3. Starting Julia command line and going to pkg> and giving st
    Status C:\Users\IsoPomo\.julia\environments\v1.6\Project.toml (empty project)

  4. Giving:
    add QML

Huge output ends like this:
Precompiling project…
52 dependencies successfully precompiled in 15 seconds
1 dependency errored. To see a full report either run import Pkg; Pkg.precompile() or load the package

  1. Backspacing to Julia REPL and giving:
    import Pkg; Pkg.precompile()

The output is:
Precompiling project…
0 dependencies successfully precompiled in 2 seconds (52 already precompiled)

ERROR: The following 1 direct dependency failed to precompile:

QML [2db162a6-7e43-52c3-8d84-290c1c42d82a]

ERROR: LoadError: InitError: could not load library “C:\Users\IsoPomo.julia\artifacts\65ee34acf07c8058dc5b67dbfc5f1d04c202d7e2\bin\libjlqml.dll”
The specified procedure could not be found.
[1] dlopen(s::String, flags::UInt32; throw_error::Bool)
@ Base.Libc.Libdl .\libdl.jl:114
[2] dlopen(s::String, flags::UInt32)
@ Base.Libc.Libdl .\libdl.jl:114
[3] macro expansion
@ C:\Users\IsoPomo.julia\packages\JLLWrappers\bkwIo\src\products\library_generators.jl:54 [inlined]
[4] init()
@ jlqml_jll C:\Users\IsoPomo.julia\packages\jlqml_jll\7qoIT\src\wrappers\x86_64-w64-mingw32-cxx11.jl:10
[5] _include_from_serialized(path::String, depmods::Vector{Any})
@ Base .\loading.jl:674
[6] _require_search_from_serialized(pkg::Base.PkgId, sourcepath::String)
@ Base .\loading.jl:760
[7] _require(pkg::Base.PkgId)
@ Base .\loading.jl:998
[8] require(uuidkey::Base.PkgId)
@ Base .\loading.jl:914
[9] require(into::Module, mod::Symbol)
@ Base .\loading.jl:901
[10] include
@ .\Base.jl:386 [inlined]
[11] include_package_for_output(pkg::Base.PkgId, input::String, depot_path::Vector{String}, dl_load_path::Vector{String}, load_path::Vector{String}, concrete_deps::Vector{Pair{Base.PkgId, UInt64}}, source::Nothing)
@ Base .\loading.jl:1213
[12] top-level scope
@ none:1
[13] eval
@ .\boot.jl:360 [inlined]
[14] eval(x::Expr)
@ Base.MainInclude .\client.jl:446
[15] top-level scope
@ none:1
during initialization of module jlqml_jll
in expression starting at C:\Users\IsoPomo.julia\packages\QML\eDhCS\src\QML.jl:1
[1] pkgerror(msg::String)
@ Pkg.Types C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\Types.jl:55
[2] precompile(ctx::Pkg.Types.Context; internal_call::Bool, strict::Bool, kwargs::Base.Iterators.Pairs{Union{}, Union{}, Tuple{}, NamedTuple{(), Tuple{}}})
@ Pkg.API C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\API.jl:1244
[3] precompile
@ C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\API.jl:920 [inlined]
[4] #precompile#196
@ C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\API.jl:918 [inlined]
[5] precompile()
@ Pkg.API C:\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.6\Pkg\src\API.jl:918
[6] top-level scope
@ REPL[3]:1

It seems to be the same situation like the one reported in the last post of the topic
Installing QML.jl

Now I don’t know what to do.

You could create an issue at Issues · barche/QML.jl · GitHub .

Or you could try it with Julia 1.6.0 .

I already did, I just forgot to mention that.

It turns out that the old phrase “Google is your friend” is still valid. I found out the error has been corrected in QML.jl master and that one can get on by using
pkg> add

When trying the next logical thing i.e. the line to run the QML.jl examples from the QML GitHub page

include(joinpath(dirname(pathof(QML)), “…”, “example”, “runexamples.jl”))

I get the first app to work but a crash already on the second one. Because this seems to be clearly QML.jl related I will do as ufechner7 (thanks for answering!) suggested and create an issue on this crash on GitHub


It may be that the example crashes because not all required packages are installed, I really should think of an elegant way to have the dependencies for the examples installed.

Other than that, if the basics work in the master version then maybe it’s time I did a new release :slight_smile:

1 Like

The first ex. board.jl ran (I think) OK after I did what I was told i.e.:
import Pkg; Pkg.add(“Qt5QuickControls_jll”)

The second one produced this output:
running example canvas.jl…
Qt Warning: QQmlApplicationEngine failed to load component ((null):0, (null))
Qt Warning: file:///C:/Users/IsoPomo/.julia/packages/QML/ZrlNP/example/qml/canvas.qml:3:1: plugin cannot be loaded for module “QtQuick.Controls”: Cannot protect module QtQuick.Controls 2 as it was never registered (file:///C:/Users/IsoPomo/.julia/packages/QML/ZrlNP/example/qml/canvas.qml:3, (null))
ERROR: LoadError: Failed to load QML file C:\Users\IsoPomo.julia\packages\QML\ZrlNP\example\qml\canvas.qml

I copied the directory C:\Users\IsoPomo.julia\packages\QML\ZrlNP
into my own dir. structure to be able to toggle off the read-only atrr.s
of the folders and files to be able to edit the files.

  1. Bypassing canvas.jl to be able to test the others
    After changing
    if fname != myname && endswith(fname, “.jl”) && fname ∉ excluded
    if fname != myname && fname != “canvas.jl” && endswith(fname, “.jl”) && fname ∉ excluded
    most of the ex. files start running OK (I think). Here’s some remarks.

  2. filedialog.jl

Qt Warning: file:///C:/Users/IsoPomo/.julia/artifacts/add1bde5fe01a2ffdb80a0977fc3f6505df530f3/qml/QtQuick/Dialogs/DefaultFileDialog.qml:102:33: QML Settings: Failed to initialize QSettings instance. Status code is: 1 (file:///C:/Users/IsoPomo/.julia/artifacts/add1bde5fe01a2ffdb80a0977fc3f6505df530f3/qml/QtQuick/Dialogs/DefaultFileDialog.qml:102, (null))
Qt Warning: file:///C:/Users/IsoPomo/.julia/artifacts/add1bde5fe01a2ffdb80a0977fc3f6505df530f3/qml/QtQuick/Dialogs/DefaultFileDialog.qml:102:33: QML Settings: The following application identifiers have not been set: QVector(“organizationName”, “organizationDomain”) (file:///C:/Users/IsoPomo/.julia/artifacts/add1bde5fe01a2ffdb80a0977fc3f6505df530f3/qml/QtQuick/Dialogs/DefaultFileDialog.qml:102, (null))
selected single file file:///C:/Users/IsoPomo/OMAT_VARMUUSKOPIOITAVAT/Julia/QML/error.txt
selected paths:

  1. grid.jl
    After clicking one of the emojis all emojis disappear. Minimizing/maximizing the window: no change. Refresh needed or what?

  2. gui.jl
    The counter value used in the concatenation is one smaller than I supposed it to be

  3. makie.jl
    This doesn’t work:
    running example makie.jl…
    ERROR: LoadError: MethodError: no method matching rotate_cam!(::AbstractPlotting.FigureAxisPlot, ::Float64, ::Float64, ::Float64)
    Closest candidates are:
    rotate_cam!(::Scene, ::Number…) at C:\Users\IsoPomo.julia\packages\AbstractPlotting\gE7AT\src\camera\camera3d.jl:259
    [1] render_function(screen::QML.MakieSupport.QMLScreen)
    @ Main C:\Users\IsoPomo\OMAT_VARMUUSKOPIOITAVAT\Julia\QML\ZrlNP\example\makie.jl:16
    [2] exec()
    @ QML C:\Users\IsoPomo.julia\packages\CxxWrap\OcN1Z\src\CxxWrap.jl:618
    [3] top-level scope
    @ C:\Users\IsoPomo\OMAT_VARMUUSKOPIOITAVAT\Julia\QML\ZrlNP\example\makie.jl:25
    in expression starting at C:\Users\IsoPomo\OMAT_VARMUUSKOPIOITAVAT\Julia\QML\ZrlNP\example\makie.jl:25
    ERROR: LoadError: failed process: Process('C:\Users\IsoPomo\AppData\Local\Programs\Julia-1.6.1\bin\julia.exe' -Cnative '-JC:\Users\IsoPomo\AppData\Local\Programs\Julia-1.6.1\lib\julia\sys.dll' -g1 --project makie.jl, ProcessExited(1)) [1]

[1] pipeline_error
@ .\process.jl:525 [inlined]
[2] run(::Cmd; wait::Bool)
@ Base .\process.jl:440
[3] run
@ .\process.jl:438 [inlined]
[4] (::var"#1#2")()
@ Main C:\Users\IsoPomo\OMAT_VARMUUSKOPIOITAVAT\Julia\QML\ZrlNP\example\runexamples.jl:9
[5] cd(f::var"#1#2", dir::String)
@ Base.Filesystem .\file.jl:95
[6] top-level scope
@ C:\Users\IsoPomo\OMAT_VARMUUSKOPIOITAVAT\Julia\QML\ZrlNP\example\runexamples.jl:5
[7] include(fname::String)
@ Base.MainInclude .\client.jl:444
[8] top-level scope
@ REPL[1]:1
in expression starting at C:\Users\IsoPomo\OMAT_VARMUUSKOPIOITAVAT\Julia\QML\ZrlNP\example\runexamples.jl:5

Thanks for the detailed feedback. Some comments:

  • grid.jl: can’t reproduce, maybe running only the grid example in a fresh julia session could help
  • gui.jl: the lower count is intentional :slight_smile:
  • Makie is broken, there is a PR to fix it that I still need to merge
  • Can’t get canvas to run either, I need to investigate this. Edit: this example is missing a using Qt5QuickControls2_jll