openc3 5.5.2.pre.beta0 → 5.5.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 9afdd0579f3b0663d3cd0d378483b372c2f3c34faa5856d1c5ef5b4a1e582af3
4
- data.tar.gz: 9224b37cda9d56d8e867a0ead73d815b3140979355a85d408824377e628fec10
3
+ metadata.gz: 6ff99b8c3ca332659e787d054c96ed43f617a4e53ba3aea706c4ed799d024f9d
4
+ data.tar.gz: 72b7fe317faf9e6902a797de6ebfbd8069b51967c0adb54e9367f13ed74b4f15
5
5
  SHA512:
6
- metadata.gz: 2c3e6009efea9ee0b7669634ba9dd0c45dd81fa9f47405ddd44ec375993e7d85b8f4b51547cb943c3229e2bfd7e5aa5ddfc5ad1de8963a6d05e8220c029e3baf
7
- data.tar.gz: 4cbe48f762771ad19429e19102f5fe427607814b1eb2149a06ed713a972d807481b767b023031fe21c21465a67108e39ceb0fef003d0ffea533b3db223960764
6
+ metadata.gz: 73ca222afa29f68ad9c3dcdbe697a90eebb9d656db43e5f69dcc3e0fb7e5bb6f5dd0e774a80c4282a26a623a9d63ee0d8a8b8ad6f743e9bc6cad5cca876bc395
7
+ data.tar.gz: a33e0239e3c688968587154945b426a5f3f2f6f73d9ea0270868235b8ccef74c19f4a823ea2d9665c07f15a3441de577da79b46ac8c4fc0877959a0d4552ee02
@@ -1316,11 +1316,9 @@ Interactive Widgets:
1316
1316
  The api.tlm() function returns a Promise which is resolved with then()
1317
1317
  at which point we send the command with the telemetry value we received.
1318
1318
 
1319
- Scripts can be launched from a BUTTON using the `runScript()` method.
1320
- # warning:
1321
- # If your button logic gets complex it's recommended to require a separate
1322
- # script and pass the screen to the script using self,
1323
- # e.g. require utility.rb; utility_method(self).
1319
+ Scripts can be launched from a BUTTON using the `runScript()` method. `runScript()` takes three parameters,
1320
+ the name of the script, whether to open the script in the foreground of Script Runner (default = true), and a hash of
1321
+ environment variables. For example: `runScript('INST/procedures/script.rb', false, {'VAR': 'VALUE'})`
1324
1322
  parameters:
1325
1323
  - name: Button Text
1326
1324
  required: true
@@ -1332,7 +1330,14 @@ Interactive Widgets:
1332
1330
  values: .+
1333
1331
  example: |
1334
1332
  BUTTON 'Start Collect' 'api.cmd("INST COLLECT with TYPE NORMAL, DURATION 5")'
1335
- BUTTON 'Run Script' 'runScript("INST/procedures/script.rb")'
1333
+ BUTTON 'Run Checks' 'runScript("INST/procedures/checks.rb")'
1334
+ # More complex example with background checkbox and env vars
1335
+ NAMED_WIDGET SCRIPTNAME COMBOBOX collect.rb checks.rb
1336
+ NAMED_WIDGET BG CHECKBUTTON 'Background'
1337
+ BUTTON 'Run Script' "var script=screen.getNamedWidget('SCRIPTNAME').text();" \
1338
+ # Set an environment variable to be used by the script as ENV['TYPE']
1339
+ "var env = {}; env['TYPE'] = 'TEST';" \
1340
+ "runScript('INST/procedures/'+script, !screen.getNamedWidget('BG').checked(), env)"
1336
1341
  CHECKBUTTON:
1337
1342
  summary: Displays a check box
1338
1343
  description:
@@ -0,0 +1,11 @@
1
+ require 'httpclient'
2
+
3
+ class HTTPClient
4
+ alias original_initialize initialize
5
+
6
+ def initialize(*args, &block)
7
+ original_initialize(*args, &block)
8
+ # Force use of the default system CA certs (instead of the 6 year old bundled ones)
9
+ @session_manager&.ssl_config&.set_default_paths
10
+ end
11
+ end
@@ -17,12 +17,13 @@
17
17
  # All changes Copyright 2022, OpenC3, Inc.
18
18
  # All Rights Reserved
19
19
  #
20
- # This file may also be used under the terms of a commercial license
20
+ # This file may also be used under the terms of a commercial license
21
21
  # if purchased from OpenC3, Inc.
22
22
 
23
23
  require 'openc3/core_ext/array'
24
24
  require 'openc3/core_ext/binding'
25
25
  require 'openc3/core_ext/class'
26
+ require 'openc3/core_ext/httpclient'
26
27
  require 'openc3/core_ext/openc3_io'
27
28
  require 'openc3/core_ext/exception'
28
29
  require 'openc3/core_ext/file'
@@ -17,7 +17,7 @@
17
17
  # All changes Copyright 2022, OpenC3, Inc.
18
18
  # All Rights Reserved
19
19
  #
20
- # This file may also be used under the terms of a commercial license
20
+ # This file may also be used under the terms of a commercial license
21
21
  # if purchased from OpenC3, Inc.
22
22
 
23
23
  require 'thread'
@@ -144,7 +144,8 @@ module OpenC3
144
144
 
145
145
  # Make the post request to keycloak
146
146
  def _make_request(headers, data)
147
- uri = URI("#{@url}/realms/openc3/protocol/openid-connect/token")
147
+ realm = ENV['OPENC3_KEYCLOAK_REALM'] || 'openc3'
148
+ uri = URI("#{@url}/realms/#{realm}/protocol/openid-connect/token")
148
149
  @log[0] = "request uri: #{uri.to_s} header: #{headers.to_s} body: #{data.to_s}"
149
150
  STDOUT.puts @log[0] if JsonDRb.debug?
150
151
  saved_verbose = $VERBOSE; $VERBOSE = nil
@@ -1,14 +1,14 @@
1
1
  # encoding: ascii-8bit
2
2
 
3
- OPENC3_VERSION = '5.5.2-beta0'
3
+ OPENC3_VERSION = '5.5.2'
4
4
  module OpenC3
5
5
  module Version
6
6
  MAJOR = '5'
7
7
  MINOR = '5'
8
8
  PATCH = '2'
9
- OTHER = 'pre.beta0'
10
- BUILD = '417d0e4ab762ecc0ada17fd8e230b394721f9cd4'
9
+ OTHER = ''
10
+ BUILD = '9c73d9c7c86512a01e0373b12b3058d3ae6b5adf'
11
11
  end
12
- VERSION = '5.5.2-beta0'
13
- GEM_VERSION = '5.5.2.pre.beta0'
12
+ VERSION = '5.5.2'
13
+ GEM_VERSION = '5.5.2'
14
14
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: openc3
3
3
  version: !ruby/object:Gem::Version
4
- version: 5.5.2.pre.beta0
4
+ version: 5.5.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ryan Melton
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2023-03-15 00:00:00.000000000 Z
12
+ date: 2023-03-16 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: bundler
@@ -798,6 +798,7 @@ files:
798
798
  - lib/openc3/core_ext/exception.rb
799
799
  - lib/openc3/core_ext/file.rb
800
800
  - lib/openc3/core_ext/hash.rb
801
+ - lib/openc3/core_ext/httpclient.rb
801
802
  - lib/openc3/core_ext/io.rb
802
803
  - lib/openc3/core_ext/kernel.rb
803
804
  - lib/openc3/core_ext/math.rb
@@ -1048,9 +1049,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
1048
1049
  version: '2.7'
1049
1050
  required_rubygems_version: !ruby/object:Gem::Requirement
1050
1051
  requirements:
1051
- - - ">"
1052
+ - - ">="
1052
1053
  - !ruby/object:Gem::Version
1053
- version: 1.3.1
1054
+ version: '0'
1054
1055
  requirements: []
1055
1056
  rubygems_version: 3.3.14
1056
1057
  signing_key: