There is a Python Oracle library cx_Oracle. You have to download the library and copy it to your Python install to have the modules recognized. Once you, do then you can make connections like and use code like this:
con = cx_Oracle.connect('username/password@hostname:port/DBname')
cur = con.cursor()
Open a file:
f = open(r'path to file, 'w')
Iterate the results set:
for row in cur:
f.write("%s\n" % str(row))
For a simple example, to get you started. Then you could use ShapeFile library to take it a step further and write out to a Shapefile. But if I were you, first I'd test just making the connection, write out to a .txt file, get that working and then, I'd use Shapefile to write out to a Shapefile.
Here's an example on how to do that:
import shapefile as shp
w = shp.Writer(filename,shp.POINT)
w.autoBalance = 1
And you'd use this instead of using the file write out example from above.