che icon indicating copy to clipboard operation
che copied to clipboard

Dashboard clears `controller.devfile.io/debug-start` annotation when starting a workspace

Open amisevsk opened this issue 2 years ago • 2 comments

Describe the bug

It looks like the dashboard is clearing the controller.devfile.io/debug-start annotation from DevWorkspace CRs when starting a workspace. This makes it slightly more difficult to follow a workspace debugging flow where the annotation controller.devfile.io/debug-start: 'true' is added to a DevWorkspace to prevent removal of objects when a failure condition occurs.

Che version

7.75@latest

Steps to reproduce

  1. Add controller.devfile.io/debug-start: 'true' to a DevWorkspace
  2. Start DevWorkspace through dashboard
  3. Reload DevWorkspace object and note annotation has been removed

Workaround: Start the workspace by setting .spec.started = true on the DevWorkspace object (i.e. start it without dashboard)

Expected behavior

I'd like the annotation to be left in place if added by the user, as this makes debugging slightly more confusing.

Runtime

OpenShift

Screenshots

N/A

Installation method

OperatorHub

Environment

Linux

Eclipse Che Logs

No response

Additional context

If distinguishing between the annotation being set by dashboard vs the user is an issue, perhaps .metadata.managedFields may be of use. If I set the annotation via my browser, for example, I see

    - apiVersion: workspace.devfile.io/v1alpha2
      fieldsType: FieldsV1
      fieldsV1:
        'f:metadata':
          'f:annotations':
            'f:controller.devfile.io/debug-start': {}
      manager: Mozilla
      operation: Update
      time: '2023-10-13T20:14:58Z'

amisevsk avatar Oct 13 '23 20:10 amisevsk

Issues go stale after 180 days of inactivity. lifecycle/stale issues rot after an additional 7 days of inactivity and eventually close.

Mark the issue as fresh with /remove-lifecycle stale in a new comment.

If this issue is safe to close now please do so.

Moderators: Add lifecycle/frozen label to avoid stale mode.

che-bot avatar Apr 12 '24 08:04 che-bot

/remove-lifecycle stale

akurinnoy avatar Apr 15 '24 07:04 akurinnoy