NoMethodError: undefined method `fire_state_event' for nil:NilClass
https://sentry.gitlab.net/gitlab/gitlabcom/issues/562765/ ``` NoMethodError: undefined method `fire_state_event' for nil:NilClass build_success_worker.rb:34:in `stop_environment' build.persisted_environment.fire_state_event(:stop) build_success_worker.rb:13:in `block in perform' stop_environment(build) if build.stops_environment? active_support/core_ext/object/try.rb:74:in `try!' yield self active_support/core_ext/object/try.rb:63:in `try' try!(*a, &b) if a.empty? || respond_to?(a.first) build_success_worker.rb:11:in `perform' Ci::Build.find_by(id: build_id).try do |build| ... (38 additional frame(s) were not displayed) undefined method `fire_state_event' for nil:NilClass ```
issue