>>> import g4
>>> g4.systs()
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
AttributeError: 'module' object has no attribute 'systs'

Why is that ?
The code works ok from shell
>>> import time
>>> def systs(): return str(time.localtime()[5])
>>> systs()
'18'
g4.py
-------

import os
import sys
import time 
def systs(): return str(time.localtime()[5])

Write the script to file and save it in same directory as g4. Run the file and it works by double clicking in file manager (add line input('Ready') to see output from program) or F5 in IDLE, but it is only for simple testing.

Sorry, solved
The above works OK

I just was editing the wrong .py file

Write the script to file and save it in same directory as g4. Run the file and it works by double clicking in file manager (add line input('Ready') to see output from program) or F5 in IDLE, but it is only for simple testing.

Thanks for the suggestion, but IDLE is not working yet for me under AOS.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.