[edit] thanks to Александр Рахмаев
Since version 3.3.3, the shading=flat (in pcolormesh by default)
approach will give an error for the current data. I am using
shanding=closest. Then there will be no error. Example:
plt.pcolormesh(th, r, z, shading='nearest') See this also
I think you inadvertently mixed up radius, zenith and azimuth :)
This plots what I think you want:
import matplotlib.pyplot as plt
from mpl_toolkits.mplot3d import Axes3D
import numpy as np
fig = plt.figure()
ax = Axes3D(fig)
rad = np.linspace(0, 5, 100)
azm = np.linspace(0, 2 * np.pi, 100)
r, th = np.meshgrid(rad, azm)
z = (r ** 2.0) / 4.0
plt.subplot(projection="polar")
plt.pcolormesh(th, r, z)
#plt.pcolormesh(th, z, r)
plt.plot(azm, r, color='k', ls='none')
plt.grid()
plt.show()

If you want ray grid lines, you can add them every Theta as follows:
plt.thetagrids([theta * 15 for theta in range(360//15)])

and more radial grids like this:
plt.rgrids([.3 * _ for _ in range(1, 17)])

PS: numpy and pyplot will keep your namespace tidy...