MTK Installation Error

When running

pip3 install -r requirements.txt

I Get

`Building wheels for collected packages: scrypt
  Building wheel for scrypt (pyproject.toml) ... error
  error: subprocess-exited-with-error

  × Building wheel for scrypt (pyproject.toml) did not run successfully.
  │ exit code: 1
  ╰─> [17 lines of output]
      running bdist_wheel
      running build
      running build_py
      creating build\lib.win-amd64-cpython-313\scrypt
      copying scrypt\scrypt.py -> build\lib.win-amd64-cpython-313\scrypt
      copying scrypt\__init__.py -> build\lib.win-amd64-cpython-313\scrypt
      creating build\lib.win-amd64-cpython-313\scrypt\tests
      copying scrypt\tests\test_scrypt.py -> build\lib.win-amd64-cpython-313\scrypt\tests
      copying scrypt\tests\test_scrypt_c_module.py -> build\lib.win-amd64-cpython-313\scrypt\tests
      copying scrypt\tests\test_scrypt_py3x.py -> build\lib.win-amd64-cpython-313\scrypt\tests
      copying scrypt\tests\__init__.py -> build\lib.win-amd64-cpython-313\scrypt\tests
      copying scrypt\tests\ciphertexts.csv -> build\lib.win-amd64-cpython-313\scrypt\tests
      copying scrypt\tests\hashvectors.csv -> build\lib.win-amd64-cpython-313\scrypt\tests
      running build_ext
      building '_scrypt' extension
      b'*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00\r\x00\n\x00*\x00*\x00 \x00V\x00i\x00s\x00u\x00a\x00l\x00 \x00S\x00t\x00u\x00d\x00i\x00o\x00 \x002\x000\x002\x002\x00 \x00D\x00e\x00v\x00e\x00l\x00o\x00p\x00e\x00r\x00 \x00C\x00o\x00m\x00m\x00a\x00n\x00d\x00 \x00P\x00r\x00o\x00m\x00p\x00t\x00 \x00v\x001\x007\x00.\x001\x002\x00.\x003\x00\r\x00\n\x00*\x00*\x00 \x00C\x00o\x00p\x00y\x00r\x00i\x00g\x00h\x00t\x00 \x00(\x00c\x00)\x00 \x002\x000\x002\x002\x00 \x00M\x00i\x00c\x00r\x00o\x00s\x00o\x00f\x00t\x00 \x00C\x00o\x00r\x00p\x00o\x00r\x00a\x00t\x00i\x00o\x00n\x00\r\x00\n\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00*\x00\r\x00\n\x00"\x00 \x00(\x00 \x00w\x00a\x00s\x00 \x00u\x00n\x00e\x00x\x00p\x00e\x00c\x00t\x00e\x00d\x00 \x00a\x00t\x00 \x00t\x00h\x00i\x00s\x00 \x00t\x00i\x00m\x00e\x00.\x00\r\x00\n\x00'
      error: Error executing cmd /u /c "C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Auxiliary\Build\vcvarsall.bat" x86_amd64 && set
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
  ERROR: Failed building wheel for scrypt
Failed to build scrypt
ERROR: ERROR: Failed to build installable wheels for some pyproject.toml based projects (scrypt)`

I Have Visual Studio installer and all the required dependencies installed

1 Like

Sometimes it can’t build cryptodine, sometimes coloroma, sometimes other stuff.
Depends on each computer.

You can still check if it works by running python mtk.py -h (not from path. Cd to the main folder)

It usually works even though some wheels aren’t built. Honestly, mtkclient is for linux… So they don’t really care about the windows version, and it sucks.

thanks i got it running on my Windows Subsystem for Linux, if anyone would like directions reply and maybe ill put together a guide

Yeah, but does it work? WSL doesn’t really connect with the drivers…

I’m not Shure if successfully attached it. I’ve created a virtual environment and used this method to mount the device when i try running a script (e.x. mtk e metadata,userdata,md_udc ) it fails to register the device even thought the cmd lbdevices lists it as attached
this could be because of

  1. You are right
  2. i cant figure out how to boot my device (F22 Pro) Into Brom mode, anyone know how ?
    any other suggestions would be helpful (a Linux VM?) would be appreciated as i don’t have acsess to a Linux laptop

@Lamden613

Use the mtkclient LiveDVD on a bootable USB:

for mtkclient - unlocking bootloader - you can use this:

instructions ?

Download, unzip, run the desired batch file, plug in your phone powerd off holding down the two top buttons

1 Like

I had the same problem…
Installing an older version of python seemed to have solved the issue for me…
(I don’t remember exactly which version but I think version 9.0 worked…)