shiavm006 opened a new pull request, #598:
URL: https://github.com/apache/mahout/pull/598

   ## Problem
   Users could call gate operations before initializing a circuit, causing 
cryptic `AttributeError: 'NoneType'` crashes deep in backend code.
   
   Example:
   ```python
   qumat = QuMat(config)
   qumat.apply_hadamard_gate(0)  # Crash!
   # AttributeError: 'NoneType' object has no attribute 'h'
   ```
   
   ## Solution
   - Added `_ensure_circuit_initialized()` helper method
   - Validates circuit exists before all gate operations (18 methods covered)
   - Raises clear `RuntimeError` with actionable message:
     
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to