Making an Octagon in Python out of * : I am trying to write a simple code in Python to make an octagon out of *. Here is the code I have so far, but obviously isn't working properly:

    oct_length = int(input("What is the length of one side? "))
    for i in range(oct_length):
        print(' ' * (oct_length - i-1) + '*' * (oct_length + i*2))
    for i in range(oct_length-1):
        print('*' * ((oct_length * 2)))
    for i in range(oct_length):
        print(' ' * (i+1) + '*' * ((oct_length-i)*2))

Thanks in advance