What does clip=True mean in mathutils.geometry.intersect_line_sphere()
Short Answer: Yes, it does.



Long Answer:

The source code is located in this file. It calls line_point_factor_v3 which subtracts both, the end point line_b and the intersection point isect from the start point line_a, to get the relative vectors from line_a to line_b and the intersection point isect, respectively.

It then divides the dot product of these relative vectors by the squared length from line_a to line_b.

Since both relative vectors are on the same line, the result of the dot product is negative if they point in opposite directions, else the result of the dot product is the product of the lengths of these vectors. 

So basically its 

dist(line_a, line_b) * dist(line_a, isect) / dist(line_a, line_b)²


If clip is True it checks wether this is between 0.0 and 1.0 which means the intersection point is on the line segment from line_a to line_b