0

I have a script say test1.py that returns a value called uptime, I need to call the script test1.py in another python script and use the value uptime to store it into a sqlite db. How can I do this? I used this but it didn't work as expected:

    import time
    import random
    import sqlite3

    import test1.py
    print(uptime)

Obviously missing something here.

nlp
  • 109
  • 1
  • 4
  • 19

0 Answers0