cpee 2.1.98 → 2.1.100

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 5380db38e15ecc1a9e3d52fa912f498c6a07e071e685370402719257154dc768
4
- data.tar.gz: 228deb7bd244630dfb4dc47618fc628cc23630e95822f7bf6a517824a6c2f9b4
3
+ metadata.gz: 143c4d716cd14f4f7c309470f1e9fe0f8dea633da3533135e122a105a05137af
4
+ data.tar.gz: 52524d9062b8c54f1d0d26b5d09301765be4246cc5439b238805eaa86a9de5e8
5
5
  SHA512:
6
- metadata.gz: 856b90b8753e9984e4c7cbdcea0914873987c6ecf68297afca3309b8dda9e8ca1e72a68be0b85e9147b5378bc2f734b3c0c8b9da08827670a8b853acde7a2681
7
- data.tar.gz: ba100bf2a332013b03c005493cadae226b85407e7e9846f5e24cd694b73095a8a1041c569c4455ceede9dd33cf6e4f6fabb3b97b96aa4ab36397e2930428e560
6
+ metadata.gz: 1760d39d1fe15bed9a548fec3deb386d5752497a6ebc2591efda7b861f5cf810a193a8e8086ccf02f659e9148b0719136b3f9eb9b32bb011bed7fdef53af472c
7
+ data.tar.gz: '0619d08bf29f3a46c522860eadc6e118b474fcf49a369c36cf9f05df36aaaffa53de3481f00322d98cbafd1a24e4c21364fa4f90ddebac20d1250e30ddfe4c95'
@@ -120,6 +120,13 @@ function cockpit() { //{{{
120
120
  $('#dat_details').empty();
121
121
  e.stopImmediatePropagation();
122
122
  });
123
+ document.addEventListener('uidash:activate_tab', function (e) {
124
+ if (!$('#tabdetails').hasClass('inactive')) {
125
+ if (save['graph_adaptor']) {
126
+ save['graph_adaptor'].redraw();
127
+ }
128
+ }
129
+ });
123
130
 
124
131
  $.ajax({
125
132
  url: $('body').attr('current-templates'),
@@ -59,13 +59,7 @@ function WfAdaptor(theme_base,doit) { // Controller {{{
59
59
  illustrator.set_label_container(container);
60
60
  } // }}}
61
61
 
62
- // initialize
63
- this.illustrator = illustrator = new WfIllustrator(this);
64
- this.description = description = new WfDescription(this, this.illustrator);
65
-
66
- this.update = function(doit){ doit(self); };
67
-
68
- $.getScript(theme_base, function() { //{{{
62
+ function loadTheme(doit) { //{{{
69
63
  manifestation = new WFAdaptorManifestation(self);
70
64
  illustrator.compact = manifestation.compact == true ? true : false;
71
65
  illustrator.rotated_labels = manifestation.rotated_labels == true ? true : false;
@@ -191,8 +185,29 @@ function WfAdaptor(theme_base,doit) { // Controller {{{
191
185
  }
192
186
  $.when.apply($, deferreds).then(function(x) {
193
187
  doit(self);
188
+ })
189
+ } //}}}
190
+
191
+ // initialize
192
+ this.illustrator = illustrator = new WfIllustrator(this);
193
+ this.description = description = new WfDescription(this, this.illustrator);
194
+
195
+ this.update = function(doit){ doit(self); };
196
+
197
+ this.redraw = function(){
198
+ description.redraw();
199
+ }
200
+
201
+ $.getScript(self.theme_base).done(function() {
202
+ loadTheme(doit);
203
+ }).fail(function(){
204
+ // default theme
205
+ self.theme_base = 'themes/preset/theme.js';
206
+ self.theme_dir = self.theme_base.replace(/theme.js/,'');
207
+ $.getScript(self.theme_base,function() {
208
+ loadTheme(doit);
194
209
  });
195
- }); //}}}
210
+ });
196
211
  } // }}}
197
212
 
198
213
  // WfIllustrator:
@@ -912,6 +927,16 @@ function WfDescription(wf_adaptor, wf_illustrator) { // Model {{{
912
927
  illustrator.set_duration(start);
913
928
  doit(self);
914
929
  }
930
+ var redraw = this.redraw = function(){
931
+ id_counter = {};
932
+ labels = [];
933
+ let start = performance.now();
934
+ illustrator.clear();
935
+ var graph = parse(description.children('description').get(0), {'row':0,'col':0,final:false,wide:false});
936
+ illustrator.set_svg(graph);
937
+ self.set_labels(graph);
938
+ illustrator.set_duration(start);
939
+ }
915
940
  var update = this.update = function(svgid) { // {{{
916
941
  id_counter = {};
917
942
  if(update_illustrator){
@@ -222,8 +222,9 @@
222
222
  <label id="llmlabel" for="llms">Choose LLM:</label>
223
223
  <select name="llms" id="llms">
224
224
  <option value="gemini-2.0-flash" selected>gemini 2 Flash</option>
225
- <option value="gemini-2.5-flash-preview-05-20">gemini 2.5 Flash</option>
226
- <option value="gemini-2.5-pro-preview-05-06">gemini 2.5 Pro</option>
225
+ <option value="gemini-2.5-flash-lite">gemini 2.5 Flash Lite</option>
226
+ <option value="gemini-2.5-flash">gemini 2.5 Flash</option>
227
+ <option value="gemini-2.5-pro">gemini 2.5 Pro</option>
227
228
  <option value="gpt-4">gpt 4</option>
228
229
  <option value="gpt-4o">gpt 4o</option>
229
230
  <option value="gpt-4o-mini">gpt 4o mini</option>
data/cpee.gemspec CHANGED
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = "cpee"
3
- s.version = "2.1.98"
3
+ s.version = "2.1.100"
4
4
  s.platform = Gem::Platform::RUBY
5
5
  s.license = "LGPL-3.0-or-later"
6
6
  s.summary = "The cloud process execution engine (cpee.org). If you just need workflow execution, without a rest service exposing it, then use WEEL."
@@ -22,7 +22,7 @@ Gem::Specification.new do |s|
22
22
  s.homepage = 'http://cpee.org/'
23
23
 
24
24
  s.add_runtime_dependency 'riddl', '~> 1.0'
25
- s.add_runtime_dependency 'weel', '~> 1.99', '>= 1.99.126'
25
+ s.add_runtime_dependency 'weel', '~> 1.99', '>= 1.99.146'
26
26
  s.add_runtime_dependency 'highline', '~> 2.0'
27
27
  s.add_runtime_dependency 'redis', '~> 5.0'
28
28
  s.add_runtime_dependency 'rubyzip', '~>2'
@@ -117,7 +117,7 @@ module CPEE
117
117
  Dir[File.join(opts[:global_executionhandlers],'*','execution.rb')].each do |h|
118
118
  require h
119
119
  end unless opts[:global_executionhandlers].nil? || opts[:global_executionhandlers].strip == ''
120
- Dir[File.join(opts[:executionhandlers],'**','execution.rb')].each do |h|
120
+ Dir[File.join(opts[:executionhandlers],'*','execution.rb')].each do |h|
121
121
  require h
122
122
  end unless opts[:executionhandlers].nil? || opts[:executionhandlers].strip == ''
123
123
  CPEE::Message::set_workers(opts[:workers])
@@ -69,8 +69,6 @@ class ConnectionWrapper < WEEL::ConnectionWrapperBase
69
69
  @handler_continue = continue
70
70
  @handler_position = position
71
71
  @handler_passthrough = nil
72
- @handler_returnValue = nil
73
- @handler_returnOptions = nil
74
72
  @handler_activity_uuid = Digest::MD5.hexdigest(Kernel::rand().to_s)
75
73
  @label = ''
76
74
  @guard_files = []
@@ -236,13 +234,6 @@ class ConnectionWrapper < WEEL::ConnectionWrapperBase
236
234
  @controller.notify("activity/annotation", :ecid => Thread.current.__id__, :'activity-uuid' => @handler_activity_uuid, :label => @label, :activity => @handler_position, :annotations => @anno)
237
235
  end #}}}
238
236
 
239
- def activity_result_value # {{{
240
- @handler_returnValue
241
- end # }}}
242
- def activity_result_options # {{{
243
- @handler_returnOptions
244
- end # }}}
245
-
246
237
  def activity_stop # {{{
247
238
  unless @handler_passthrough.nil?
248
239
  @controller.cancel_callback(@handler_passthrough)
@@ -307,24 +298,24 @@ class ConnectionWrapper < WEEL::ConnectionWrapperBase
307
298
  end
308
299
 
309
300
  if options['CPEE_STATUS'] || options['CPEE_EVENT']
310
- @handler_returnValue = nil
311
- @handler_returnOptions = nil
301
+ returnValue = nil
302
+ returnOptions = nil
312
303
  else
313
- @handler_returnValue = recv
314
- @handler_returnOptions = options
304
+ returnValue = recv
305
+ returnOptions = options
315
306
  end
316
307
 
317
308
  if options['CPEE_UPDATE']
318
- @handler_continue.continue WEEL::Signal::UpdateAgain
309
+ @handler_continue.continue WEEL::Signal::UpdateAgain, returnValue, returnOptions
319
310
  else
320
311
  @controller.cancel_callback(@handler_passthrough)
321
312
  @handler_passthrough = nil
322
313
  if options['CPEE_SALVAGE']
323
- @handler_continue.continue WEEL::Signal::Salvage
314
+ @handler_continue.continue WEEL::Signal::Salvage, returnValue, returnOptions
324
315
  elsif options['CPEE_STOP']
325
- @handler_continue.continue WEEL::Signal::Stop
316
+ @handler_continue.continue WEEL::Signal::Stop, returnValue, returnOptions
326
317
  else
327
- @handler_continue.continue
318
+ @handler_continue.continue WEEL::Signal::Proceed, returnValue, returnOptions
328
319
  end
329
320
  end
330
321
  end #}}}
@@ -215,7 +215,7 @@
215
215
  </xsl:otherwise>
216
216
  </xsl:choose>
217
217
  </xsl:if>
218
- <xsl:for-each select="@*[not(name()='language' or name()='mode' or name()='condition' or name()='svg-label')]">
218
+ <xsl:for-each select="@*[not(name()='language' or name()='mode' or (local-name()='alt_id' and namespace-uri()='http://cpee.org/ns/annotation/1.0') or name()='condition' or name()='svg-label')]">
219
219
  <xsl:text>, :</xsl:text>
220
220
  <xsl:value-of select="name(.)"/>
221
221
  <xsl:text> => "</xsl:text>
@@ -69,8 +69,6 @@ class ConnectionWrapper < WEEL::ConnectionWrapperBase
69
69
  @handler_continue = continue
70
70
  @handler_position = position
71
71
  @handler_passthrough = nil
72
- @handler_returnValue = nil
73
- @handler_returnOptions = nil
74
72
  @handler_activity_uuid = Digest::MD5.hexdigest(Kernel::rand().to_s)
75
73
  @label = ''
76
74
  @guard_files = []
@@ -236,13 +234,6 @@ class ConnectionWrapper < WEEL::ConnectionWrapperBase
236
234
  @controller.notify("activity/annotation", :ecid => Thread.current.__id__, :'activity-uuid' => @handler_activity_uuid, :label => @label, :activity => @handler_position, :annotations => @anno)
237
235
  end #}}}
238
236
 
239
- def activity_result_value # {{{
240
- @handler_returnValue
241
- end # }}}
242
- def activity_result_options # {{{
243
- @handler_returnOptions
244
- end # }}}
245
-
246
237
  def activity_stop # {{{
247
238
  unless @handler_passthrough.nil?
248
239
  @controller.cancel_callback(@handler_passthrough)
@@ -314,24 +305,24 @@ class ConnectionWrapper < WEEL::ConnectionWrapperBase
314
305
  end
315
306
 
316
307
  if options['CPEE_STATUS'] || options['CPEE_EVENT']
317
- @handler_returnValue = nil
318
- @handler_returnOptions = nil
308
+ returnValue = nil
309
+ returnOptions = nil
319
310
  else
320
- @handler_returnValue = recv
321
- @handler_returnOptions = options
311
+ returnValue = recv
312
+ returnOptions = options
322
313
  end
323
314
 
324
315
  if options['CPEE_UPDATE']
325
- @handler_continue.continue WEEL::Signal::UpdateAgain
316
+ @handler_continue.continue WEEL::Signal::UpdateAgain, returnValue, returnOptions
326
317
  else
327
318
  @controller.cancel_callback(@handler_passthrough)
328
319
  @handler_passthrough = nil
329
320
  if options['CPEE_SALVAGE']
330
- @handler_continue.continue WEEL::Signal::Salvage
321
+ @handler_continue.continue WEEL::Signal::Salvage, returnValue, returnOptions
331
322
  elsif options['CPEE_STOP']
332
- @handler_continue.continue WEEL::Signal::Stop
323
+ @handler_continue.continue WEEL::Signal::Stop, returnValue, returnOptions
333
324
  else
334
- @handler_continue.continue
325
+ @handler_continue.continue WEEL::Signal::Proceed, returnValue, returnOptions
335
326
  end
336
327
  end
337
328
  end #}}}
@@ -215,7 +215,7 @@
215
215
  </xsl:otherwise>
216
216
  </xsl:choose>
217
217
  </xsl:if>
218
- <xsl:for-each select="@*[not(name()='language' or name()='mode' or name()='condition' or name()='svg-label')]">
218
+ <xsl:for-each select="@*[not(name()='language' or (local-name()='alt_id' and namespace-uri()='http://cpee.org/ns/annotation/1.0') or name()='mode' or name()='condition' or name()='svg-label')]">
219
219
  <xsl:text>, :</xsl:text>
220
220
  <xsl:value-of select="name(.)"/>
221
221
  <xsl:text> => "</xsl:text>
@@ -468,7 +468,21 @@
468
468
  <xsl:text>end</xsl:text>
469
469
  <xsl:call-template name="print-newline"/>
470
470
  </xsl:template>
471
+ <xsl:template name="genPath">
472
+ <xsl:param name="prevPath"/>
473
+ <xsl:variable name="currPath" select="concat('/',name(),'[',
474
+ count(preceding-sibling::*[name() = name(current())])+1,']',$prevPath)"/>
475
+ <xsl:for-each select="parent::*">
476
+ <xsl:call-template name="genPath">
477
+ <xsl:with-param name="prevPath" select="$currPath"/>
478
+ </xsl:call-template>
479
+ </xsl:for-each>
480
+ <xsl:if test="not(parent::*)">
481
+ <xsl:value-of select="$currPath"/>
482
+ </xsl:if>
483
+ </xsl:template>
471
484
  <xsl:template match="d:parameters">
485
+ <!--xsl:text>:path =&gt; "</xsl:text><xsl:call-template name="genPath"/><xsl:text>", </xsl:text-->
472
486
  <xsl:apply-templates select="d:label" mode="parameter"/>
473
487
  <xsl:apply-templates select="d:*[not(name()='label') and not(name()='color')]" mode="parameter"/>
474
488
  <xsl:if test="count(*) &gt; 0">, </xsl:if>
@@ -1 +1 @@
1
- 2372948
1
+ 2332765
@@ -1 +1 @@
1
- 2372966
1
+ 2332784
@@ -1 +1 @@
1
- 2372972
1
+ 2332790
@@ -1 +1 @@
1
- 2372978
1
+ 2332796
@@ -1 +1 @@
1
- 2372984
1
+ 2332802
@@ -1 +1 @@
1
- 2372990
1
+ 2332808
@@ -1 +1 @@
1
- 2372996
1
+ 2332814
@@ -1 +1 @@
1
- 2373002
1
+ 2332820
@@ -1 +1 @@
1
- 2372960
1
+ 2332778
@@ -1 +1 @@
1
- 2372954
1
+ 2332771
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cpee
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.98
4
+ version: 2.1.100
5
5
  platform: ruby
6
6
  authors:
7
7
  - Juergen eTM Mangler
@@ -34,7 +34,7 @@ dependencies:
34
34
  version: '1.99'
35
35
  - - ">="
36
36
  - !ruby/object:Gem::Version
37
- version: 1.99.126
37
+ version: 1.99.146
38
38
  type: :runtime
39
39
  prerelease: false
40
40
  version_requirements: !ruby/object:Gem::Requirement
@@ -44,7 +44,7 @@ dependencies:
44
44
  version: '1.99'
45
45
  - - ">="
46
46
  - !ruby/object:Gem::Version
47
- version: 1.99.126
47
+ version: 1.99.146
48
48
  - !ruby/object:Gem::Dependency
49
49
  name: highline
50
50
  requirement: !ruby/object:Gem::Requirement