hamstring problems

i have recurring hamstring problems in both sides. my flexibility is pretty good and i would say my strength around the hamstring is reasonable too. i have recently started squatting quite heavy though and i’m not sure if this is compressing the vertebrae causing muscular and neural tightness around the limbar spine which is referring to the hamstring. would these be plausible? my current problem i think is just a severe cramp as i felt it on thursday but could jog after no problem and could do gentle strides yesterday. today it feels significantly better. my range of motion has not been affected and i can stretch without discomfort. yesterday i was planning on doing weights, but doing a warm up set on hang cleans was a bit uncomfortable in the hamstring. any thoughts, opinions or advice would be appreciated.