FMCorz / mdk

Moodle Development Kit. A collection of tools meant to make developers' lives easier.
GNU General Public License v3.0
84 stars 47 forks source link

NameError in mdk init #194

Closed adpe closed 4 years ago

adpe commented 4 years ago

Hi @FMCorz

I'm encountering a problem after installing mdk on a Debian (WSL2) or CentOS (VirtualBox VM) that after running mdk init and inserting my username or let it default it quits the setup:

[<username>@moodle-dev-39 opt]# mdk init
What user are you initialising MDK for? [<username>]
  <username>
NameError: name '<username>' is not defined

[<username>@moodle-dev-39 opt]# mdk init
What user are you initialising MDK for? [<username>]

SyntaxError: unexpected EOF while parsing (<string>, line 0)

What can lead to this problem? I'm using these python and gcc verson:

[<username>@moodle-dev-39 opt]# python
Python 2.7.5 (default, Apr  2 2020, 13:16:51)
[GCC 4.8.5 20150623 (Red Hat 4.8.5-39)] on linux2

HTH, Adrian

FMCorz commented 4 years ago

Hi @adpe,

The latest version of MDK no longer supports Python 2. If you cannot switch to Python 3, you should be able to use the version 1.7.6.

Please let us know if the problem persists with Python 3.

Thanks, Fred