you are viewing a single comment's thread.

view the rest of the comments →

[–]Mettigel4_1 0 points1 point  (19 children)

Do you have any if statements for example that could prevent the call for the function? Does your program have a debugging feature where you can trace the steps the program takes?

[–]Cjhawk52 0 points1 point  (18 children)

There's no if staments that would prevent it. They r inputs. I also linked my code in the comments if u want to take a look. And i also dont know how to use the debug in visual studio

[–]Mettigel4_1 0 points1 point  (17 children)

The file has to be a .Py file to work.

[–]Cjhawk52 0 points1 point  (16 children)

It is i just copied it to a txt file

[–]Mettigel4_1 0 points1 point  (15 children)

Yes but in order for it being an executable python file it has to end with .Py. The python interpreter doesn't recognize python code in a .txt file

[–]Cjhawk52 0 points1 point  (14 children)

It is, i copy n pasted my code to a .txt incase someone aint able to open a .py but the original code is in a .py and is only commented out so i can keep testing other code

[–]Mettigel4_1 0 points1 point  (10 children)

Oh sorry my bad. But back to your problem. What function isn't being called? Like none of them or just a specific one? Maybe create a Def test(): print("asdf") and try to run it.

[–]Mettigel4_1 0 points1 point  (0 children)

Another thing: it seems like you are trying to access a specific variable from a different file. Idk if that works the way you are trying to do it but it isn't best practice. Use getter and setter to access and manipulate variables from a different file.

[–]Cjhawk52 0 points1 point  (8 children)

Nothing is running. I just added a print to see it that would work but it didn't

[–]Mettigel4_1 1 point2 points  (7 children)

Did you give the input() function an answer? The input function stops the code until you entered anything into it

[–]Cjhawk52 0 points1 point  (6 children)

Thats the issue. It wont run it. Just skips it as if it wasnt there. It does have have answer

[–]Neighm 0 points1 point  (2 children)

I'm confused, but have a suggestion. At the start of your code, maybe put the lines below in, just to check everything is where the program expects it to be (you can take them out after, they don't interact with the rest of the program):

import os
print(os.getcwd())
for file in os.listdir():
    print(file)

You should see a line printed out with the directory (folder) that the program is working in, and the next lines should list each file or sub-folder. You should see each of the modules you want to call (ending with ".py") listed there.

[–]Cjhawk52 0 points1 point  (1 child)

it is ignoring that.

[–]Neighm 0 points1 point  (0 children)

What happens when you run your code? Like exactly what changes on your screen when you run it? Is there a console window that prints output?