You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/sdk-and-tools/sdk-py/installing-mxpy.md
+10-90Lines changed: 10 additions & 90 deletions
Original file line number
Diff line number
Diff line change
@@ -7,7 +7,7 @@ title: Installing mxpy
7
7
8
8
How to install mxpy
9
9
10
-
This page describes how to install **mxpy** (the CLI tool). The recommended way to install **mxpy** is by using the `mxpy-up`facility.
10
+
This page describes how to install **mxpy** (the CLI tool). The recommended way to install **mxpy** is by using the `mxpy-up`script.
11
11
12
12
**mxpy** is currently supported on Linux and MacOS. Some of its features might work on Windows as well, although using **mxpy** on Windows is neither recommended, nor supported at this time.
13
13
@@ -19,110 +19,30 @@ Before installing **mxpy**, please make sure you have a working **Python 3** env
19
19
20
20
-**3.8** or later on Linux and MacOS
21
21
22
-
Smart contracts written in C require the ncurses library routines for compiling. Install them using the following:
23
-
24
-
For Linux:
25
-
26
-
```
27
-
sudo apt install libncurses5
28
-
```
29
-
30
-
For MacOS:
31
-
32
-
```
33
-
brew install ncurses
34
-
```
35
-
36
22
[comment]: #(mx-context-auto)
37
23
38
-
## **Install using mxpy-up (recommended)**
24
+
## **Install using mxpy-up**
39
25
40
-
In order to install **mxpy** using the `mxpy-up`installation script, run the following commands in a terminal:
26
+
In order to install **mxpy** using the `mxpy-up` script, run the following commands:
This will create a light Python virtual environment (based on `venv`) in `~/multiversx-sdk/mxpy-venv `. Since `mxpy v6.0.0` we do not alter the **`$PATH`** variable.
48
-
You'll need to manually include `~/multiversx-sdk` in your **`$PATH`** variable (by editing the appropriate `.profile` file) as done bellow:
49
-
```
50
-
export PATH="$HOME/multiversx-sdk:$PATH"
51
-
```
52
-
53
-
[comment]: #(mx-context-auto)
54
-
55
-
### **Troubleshooting and other notes**
33
+
This will create a Python virtual environment in `~/multiversx-sdk/mxpy-venv`.
56
34
57
-
On Ubuntu 20.04, if you receive the error: `invalid command 'bdist_wheel'` - run the following command, then retry mxpy-up:
35
+
## Make mxpy available in your shell
58
36
59
-
```
60
-
pip3 install wheel
61
-
python3 mxpy-up.py
62
-
```
63
-
64
-
On MacOS, you can switch to Python 3.8 as follows:
37
+
In order to have the command **mxpy** available in your shell after install, you'll need to manually include `~/multiversx-sdk` in your **`$PATH`** environment variable by editing the appropriate shell profile file: `~/.bashrc` (for Bash) or `~/.zshrc` (for Zsh). For example:
If you encounter encoding-related issues at installation time, such as: `UnicodeDecodeError: 'ascii' codec can't decode byte`, then please set `PYTHONIOENCODING` before running the installation command:
44
+
Then, open a new shell and run the following command to verify that **mxpy** is installed correctly:
0 commit comments