'Asymptote can not create label

I am making my first steps with the vector program asymptote (https://asymptote.sourceforge.io). During my first tutorials I already encounter an error: I can't put any labels. The following code works fine:

draw((0,0) -- (2,2));

however, if I add a label:

draw((0,0) -- (2,2));
label("x", (1,1));

the following error message occurs:

asy -globalwrite -f pdf -o "test.pdf" "test.asy"
    pic.addBox(position,position,min(f),max(f));
              ^
C:\Program Files\MiKTeX/asymptote/plain_Label.asy: 321.15: runtime:

As you can see I am using a Windows (10) operating system with a MiKTeX installation. The version of Asymptote included in it is:

asy --version
miktex-asy version 2.69 [(C) 2004 Andy Hammerlindl, John C. Bowman, Tom Prince]

ENABLED OPTIONS:
WebGL    3D HTML rendering
OpenGL   3D OpenGL rendering
CURL     URL support

DISABLED OPTIONS:
GSL      GNU Scientific Library (special functions)
FFTW3    Fast Fourier transforms
XDR      external data representation (portable binary file format)
Readline interactive history and editing
Editline interactive editing (if Readline is unavailable)
Sigsegv  distinguish stack overflows from segmentation faults
GC       Boehm garbage collector

Can someone help me to fix the error? The error message is rather useless. Any help would be appreciated!



Solution 1:[1]

After some research I found out that the version of Asymptote provided by MiKTeX is not compatible with their own packages. The solution is actually quite simple: Get an official standalone from https://asymptote.sourceforge.io, then it will work.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Nobody-86