Friends, I am surprised noone mentioned the "Zero Energy State" rule. Whenever one is going to work on process equipment, it must always be put in a ZES. In addition to removing power source, one must relieve all potential energy in the system. Had that been done, there would have been zero pressure in the hydraulic line. Furthermore, the "heavy grinding wheel" should have been propped or tethered so that it could not change position.
So, there at least TWO safety violations involved in the work -- not to mention the absence of a lookout who could provide assistance when "stuff" happened.
When I was a student apprentice at English-Electric's Kidsgrove works, I was working in the computing lab. next to the partition separating it from the control systems lab. I heard a commotion on the other side of the partition, looked over and saw one of the engineers slumped by some 3-phase 440V bus bars. He'd somehow got his hands across two of the phases. Someone pressed the emergency stop button, it didn't work and the motor-generator down in the basement had to be switched off manually.
Luckily, Iain wasn't killed, he just had badly burnt hands, and was back at work a couple of days later, heavily bandaged.
At one employer, the first thing that I would do after switching off the disconnect and locking it off was to wire a direct short circuit across all 3 phases, so that it could not be powered while I worked on it.
I wonder if there was a diagnostic command set to allow manually operating the valve, or a pilot light to indicate that the coils was energized. Those are two of my startup and service tools. Also, I wonder what you thought could be accomplished by disconnecting the valve. That would be the very last thing to try. Sometimes I was able to determine if the valve was powered by holding a screwdriver near the solenoid coil, and feeling the pull. Of course, as an EE designing control systems, I did study hydraulics on my own in order to know what was happening.
Reminds me of a time working on an old open-construction 2000HP synchronous motor (with the easy-to-reach rotor and windings) and control circuit. Everyone's tired and we have a manager hovering over us demanding we speed things up. We sped things up alright by untagging the power too early and accidentally starting the damn motor while guys were still working on the circuit! Could have easily killed someone. One poor guy had to run to another building just to trip the main breaker. Be careful out there indeed! Don't EVER let someone - even your boss - make you do something unsafe.
You are lucky - this could have been much worse. My wife works in an operating room in Baltimore and several times a year sees patients with severe "hydraulic" injuries - high pressure oil can break right through your skin and thoroughly infiltrate your tissue, getting into your blood stream - a real toxic mess not to mention the direct damage done to the tissue itself. Be careful out there!