Exception: DesignManagement::Version::CouldNotCreateVersion

Inherits:
StandardError
  • Object
show all
Defined in:
app/models/design_management/version.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(sha, issue_id, actions) ⇒ CouldNotCreateVersion

Returns a new instance of CouldNotCreateVersion.


16
17
18
# File 'app/models/design_management/version.rb', line 16

def initialize(sha, issue_id, actions)
  @sha, @issue_id, @actions = sha, issue_id, actions
end

Instance Attribute Details

#actionsObject (readonly)

Returns the value of attribute actions


14
15
16
# File 'app/models/design_management/version.rb', line 14

def actions
  @actions
end

#issue_idObject (readonly)

Returns the value of attribute issue_id


14
15
16
# File 'app/models/design_management/version.rb', line 14

def issue_id
  @issue_id
end

#shaObject (readonly)

Returns the value of attribute sha


14
15
16
# File 'app/models/design_management/version.rb', line 14

def sha
  @sha
end

Instance Method Details

#messageObject


20
21
22
# File 'app/models/design_management/version.rb', line 20

def message
  "could not create version from commit: #{sha}"
end

#sentry_extra_dataObject


24
25
26
27
28
29
30
# File 'app/models/design_management/version.rb', line 24

def sentry_extra_data
  {
    sha: sha,
    issue_id: issue_id,
    design_ids: actions.map { |a| a.design.id }
  }
end