gitlab-triage 1.47.0 → 1.48.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/lefthook.yml +1 -3
- data/lib/gitlab/triage/entity_builders/issue_builder.rb +5 -1
- data/lib/gitlab/triage/entity_builders/summary_builder.rb +10 -3
- data/lib/gitlab/triage/policies/summary_policy.rb +2 -2
- data/lib/gitlab/triage/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: dac5a3a6e2e88bb70fb33933f18755460da5d7e3cdee8965c262d6770f0f9de8
|
|
4
|
+
data.tar.gz: 4fd13c1a11196d09b2b2b1413f8c6a0eeed89a9c3178b7460a5df1d6678f9737
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: dde7d3bdf9efa243e118cc325a68ed0cf0384e1fce17d03611929cd4728543db6e0071914c55c100030ab7fff934cf95f09b6f4bc549cc847600aaf40334a9cd
|
|
7
|
+
data.tar.gz: 2c6f6d82ad58c8f9aa056cd7bf8b2d8cc2314f504cf358b5109c0d914483cacec88725b8ef5719623c8e6d3036f0693505e2f48e857897c8c24f5a135274eef1
|
data/Gemfile.lock
CHANGED
data/lefthook.yml
CHANGED
|
@@ -36,15 +36,22 @@ module Gitlab
|
|
|
36
36
|
end
|
|
37
37
|
|
|
38
38
|
def valid?
|
|
39
|
-
|
|
39
|
+
title_present? && content_available?
|
|
40
40
|
end
|
|
41
41
|
|
|
42
|
-
|
|
43
|
-
|
|
42
|
+
# Check if this summary has content to include in a parent summary.
|
|
43
|
+
# Custom type summaries generate content from templates (external data),
|
|
44
|
+
# while regular summaries need GitLab resources to generate content.
|
|
45
|
+
def content_available?
|
|
46
|
+
@is_custom || @resources.any?
|
|
44
47
|
end
|
|
45
48
|
|
|
46
49
|
private
|
|
47
50
|
|
|
51
|
+
def title_present?
|
|
52
|
+
/\S+/.match?(title) || false
|
|
53
|
+
end
|
|
54
|
+
|
|
48
55
|
def title_resource
|
|
49
56
|
{ type: @type }
|
|
50
57
|
end
|
|
@@ -10,7 +10,7 @@ module Gitlab
|
|
|
10
10
|
# Build a summary from several rules policies
|
|
11
11
|
def build_summary
|
|
12
12
|
action = actions[:summarize]
|
|
13
|
-
|
|
13
|
+
child_summaries = resources.map do |inner_policy_spec, inner_resources|
|
|
14
14
|
Policies::RulePolicy.new(
|
|
15
15
|
type, inner_policy_spec, inner_resources, network)
|
|
16
16
|
.build_summary
|
|
@@ -19,7 +19,7 @@ module Gitlab
|
|
|
19
19
|
EntityBuilders::SummaryBuilder.new(
|
|
20
20
|
type: type,
|
|
21
21
|
action: action,
|
|
22
|
-
resources:
|
|
22
|
+
resources: child_summaries.select(&:content_available?),
|
|
23
23
|
network: network,
|
|
24
24
|
separator: "\n\n")
|
|
25
25
|
end
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: gitlab-triage
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.
|
|
4
|
+
version: 1.48.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- GitLab
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2026-02-
|
|
11
|
+
date: 2026-02-06 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: activesupport
|