while(True) loop breaks SSH script
===

I'm using an automated SSH script to copy/run/log hardware tests to a few computers via SSH, and everything works fine except one thing. The test file is supposed to run indefintely every 30 minutes and collect data, then write it to a file until killed. For lack of a better example:

file.py:

    #!/usr/bin/env python
    import os

    while(True):
        sar | grep kb
        (blah blah print to file stuff)

automatic-ssh.sh:

    #!/bin/bash

    autossh uname password ip command
    

Without fail it gets stuck on running the command. I've tried 'command &' as well as putting an ampersand at the end of the entire line of code. Anyone out there have some advice?