'Cannot find reference 'GUI' in '__init__.py'

I'm trying to get into project-based learning and started following this tutorial as my first try on a project: https://www.youtube.com/watch?v=NZMTWBpLUa4&t=586s

I ran into 2 problems and I have no idea how to solve 1 one of them as a complete beginner. The first one was that "import simplegui" wouldn't work but rather I would have to change it to "import simpleguitk" even though I just copy and pasted this chunk of code:

import simplegui
g = simplegui.GUI()
def buttoncallback():
    g.status("Button klicked!")
g.button("Klick me!", buttoncallback)
g.button("Klick me too!", buttoncallback)
def listboxcallback(text):
     g.status("listbox select: '{0}'".format(text))
g.listbox(["one", "two", "three"], listboxcallback)
g.listbox(["A", "B", "C"], listboxcallback)
def scalecallback(text):
    g.status("scale value: '{0}'".format(text))
g.scale("Scale me!", scalecallback)
g.run()

The second and more relevant problem that I ran into was Pycharm giving me this error:

Cannot find reference 'gui' in '__init__.py'

As I said, I simply copied and pasted the chunk of code from https://pypi.org/project/simplegui/ but I don't really understand whats going on here or how to fix it.



Sources

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

Source: Stack Overflow

Solution Source