0
0
mirror of https://github.com/Make-Magazine/PirateRadio synced 2025-10-05 16:02:52 +02:00

Merge pull request #21 from Make-Magazine/unstable

Added support for handling both python 2.x and 3.x
This commit is contained in:
Nick Normal
2014-12-30 10:38:33 -05:00

View File

@@ -2,15 +2,19 @@
# Pirate Radio
# Author: Wynter Woods (Make Magazine)
import os
import sys
import subprocess
import configparser
import re
import random
import threading
import time
try: # the following tests for a python3.x module
import configparser
except: # if the module isn't found, we're likely running python2.x and will just trick it into working
import ConfigParser as configparser
finally:
import re
import re
import random
import sys
import os
import threading
import time
import subprocess
fm_process = None
on_off = ["off", "on"]