If it is Pyo, I would spay. There are risks, the vet should run a blood panel which should tell them if it is safe to put her under. The after effects of a spay are not that huge, although perhaps it's a little more taxing on an older dog, but you said she was active and lively before so I'd say she'd do pretty well.
If it is cancer I don't think I would do chemo myself, but that's just me, I'd wait until quality of life declined and would put her down.