aerospaceresearch / orbitdeterminator

determination of satellite orbits and more
MIT License
185 stars 113 forks source link

Handled infinite while loop in automated.py #147

Closed vidhanarya closed 5 years ago

vidhanarya commented 5 years ago

Commit e2574255507aba631ba62b1bc2b53f819efaab72 fixed the problem stated in issue #146, in the example below timeout time has been set to 20 seconds for short length of GIF but it can be set to any value

PR_issue_orbitdeterminator

For issue #148: For this part of code in automated.py-

def stage(processed):

    for file in processed:
        print("staging")
        run(
            "cd %s;git add %s" % (SOURCE_ABSOLUTE, file),
            stdout=PIPE, stderr=PIPE,
            universal_newlines=True,
            shell=True
        )
        print("File %s has been staged." % (file))

code which is effectively running in bash for file "Test File.csv" is: git add Test Case.csv which will do nothing as for special characters bash (ubuntu) needs code like this: git add Test\ Case.csv

It can be handeled if we pass '%s' instead of %s since in src folder git add 'Test File.csv' will work perfectly fine, new code will be like this-

run(
            "cd %s;git add '%s'" % (SOURCE_ABSOLUTE, file),
            stdout=PIPE, stderr=PIPE,
            universal_newlines=True,
            shell=True
        )
vidhanarya commented 5 years ago

Closing this PR as opened a new PR with base master