Normalize relative paths in compile_commands.json

Oftentimes the script location is different to compile_commands.json and relative paths don't make sense once the .lnt file has been generated. We can get around this by normalizing the paths as part of processing.
However, this does break the current unit tests. Specifically, since os.path is platform dependent it only works if the paths match the executing platform, so we can't easily satisfy unit tests for both Windows and Linux path styles. What do you think we should do?

@gnail  sorry for not getting back to you earlier - been a bit busy...
checking out your branch and running the test locally leads to failing tests now
Testing started at 16:49 ...
C:\_\py36\python.exe C:\jetbrains\apps\PyCharm-P\ch-0\191.7479.30\helpers\pydev\pydevd.py --multiproc --qt-support=auto --client <IP_ADDRESS> --port 51006 --file C:\jetbrains\apps\PyCharm-P\ch-0\191.7479.30\helpers\pycharm\_jb_nosetest_runner.py --path G:/_customer/xyz/pc_lint_json_db/test_lint4jsondb.py
pydev debugger: process 7424 is connecting

Connected to pydev debugger (build 191.7479.30)
Launching Nosetest with arguments C:\jetbrains\apps\PyCharm-P\ch-0\191.7479.30\helpers\pycharm\_jb_nosetest_runner.py G:/_customer/xyz/pc_lint_json_db/test_lint4jsondb.py in G:\_customer\xyz\pc_lint_json_db
......

F:/VS2017/working/mocs_compilation.cpp != F:\VS2017\working\mocs_compilation.cpp

Expected :F:\VS2017\working\mocs_compilation.cpp
Actual   :F:/VS2017/working/mocs_compilation.cpp
<Click to see difference>

Traceback (most recent call last):
  File "C:\jetbrains\apps\PyCharm-P\ch-0\191.7479.30\helpers\pycharm\teamcity\diff_tools.py", line 32, in _patched_equals
    old(self, first, second, msg)
  File "C:\_\py36\lib\unittest\case.py", line 821, in assertEqual
    assertion_func(first, second, msg=msg)
  File "C:\_\py36\lib\unittest\case.py", line 1194, in assertMultiLineEqual
    self.fail(self._formatMessage(msg, standardMsg))
  File "C:\_\py36\lib\unittest\case.py", line 666, in fail
    raise self.failureException(msg)
AssertionError: 'F:\\VS2017\\working\\mocs_compilation.cpp' != 'F:/VS2017/working/mocs_compilation.cpp'
- F:\VS2017\working\mocs_compilation.cpp
?   ^      ^       ^
+ F:/VS2017/working/mocs_compilation.cpp
?   ^      ^       ^

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "C:\_\py36\lib\unittest\case.py", line 59, in testPartExecutor
    yield
  File "C:\_\py36\lib\unittest\case.py", line 601, in run
    testMethod()
  File "G:\_customer\xyz\pc_lint_json_db\test_lint4jsondb.py", line 89, in test_03a_source_trail_style_json_db
    "F:/VS2017/working/mocs_compilation.cpp")

/home/user/code/login/LoginDialog.cpp != \home\user\code\login\LoginDialog.cpp

Expected :\home\user\code\login\LoginDialog.cpp
Actual   :/home/user/code/login/LoginDialog.cpp
<Click to see difference>

Traceback (most recent call last):
  File "C:\jetbrains\apps\PyCharm-P\ch-0\191.7479.30\helpers\pycharm\teamcity\diff_tools.py", line 32, in _patched_equals
    old(self, first, second, msg)
  File "C:\_\py36\lib\unittest\case.py", line 821, in assertEqual
    assertion_func(first, second, msg=msg)
  File "C:\_\py36\lib\unittest\case.py", line 1194, in assertMultiLineEqual
    self.fail(self._formatMessage(msg, standardMsg))
  File "C:\_\py36\lib\unittest\case.py", line 666, in fail
    raise self.failureException(msg)
AssertionError: '\\home\\user\\code\\login\\LoginDialog.cpp' != '/home/user/code/login/LoginDialog.cpp'
- \home\user\code\login\LoginDialog.cpp
? ^    ^    ^    ^     ^
+ /home/user/code/login/LoginDialog.cpp
? ^    ^    ^    ^     ^

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "C:\_\py36\lib\unittest\case.py", line 59, in testPartExecutor
    yield
  File "C:\_\py36\lib\unittest\case.py", line 601, in run
    testMethod()
  File "G:\_customer\xyz\pc_lint_json_db\test_lint4jsondb.py", line 117, in test_03b_cmake_style_json_db
    "/home/user/code/login/LoginDialog.cpp")

F

G:/qzipreader/main.cpp != G:\qzipreader\main.cpp

Expected :G:\qzipreader\main.cpp
Actual   :G:/qzipreader/main.cpp
<Click to see difference>

Traceback (most recent call last):
  File "C:\jetbrains\apps\PyCharm-P\ch-0\191.7479.30\helpers\pycharm\teamcity\diff_tools.py", line 32, in _patched_equals
    old(self, first, second, msg)
  File "C:\_\py36\lib\unittest\case.py", line 821, in assertEqual
    assertion_func(first, second, msg=msg)
  File "C:\_\py36\lib\unittest\case.py", line 1194, in assertMultiLineEqual
    self.fail(self._formatMessage(msg, standardMsg))
  File "C:\_\py36\lib\unittest\case.py", line 666, in fail
    raise self.failureException(msg)
AssertionError: 'G:\\qzipreader\\main.cpp' != 'G:/qzipreader/main.cpp'
- G:\qzipreader\main.cpp
?   ^          ^
+ G:/qzipreader/main.cpp
?   ^          ^

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "C:\_\py36\lib\unittest\case.py", line 59, in testPartExecutor
    yield
  File "C:\_\py36\lib\unittest\case.py", line 601, in run
    testMethod()
  File "G:\_customer\xyz\pc_lint_json_db\test_lint4jsondb.py", line 152, in test_03c_qbs_created_for_msvc_json_db
    "G:/qzipreader/main.cpp")

Failure
Traceback (most recent call last):
  File "C:\_\py36\lib\unittest\case.py", line 59, in testPartExecutor
    yield
  File "C:\_\py36\lib\unittest\case.py", line 601, in run
    testMethod()
  File "G:\_customer\xyz\pc_lint_json_db\test_lint4jsondb.py", line 188, in test_03d_cmake_ninja_windows_json_db
    'C:\\Qt\\Qt5.9.2\\5.9.2\\msvc2015_64\\include'
  File "C:\_\py36\lib\unittest\case.py", line 1019, in assertListEqual
    self.assertSequenceEqual(list1, list2, msg, seq_type=list)
  File "C:\_\py36\lib\unittest\case.py", line 1001, in assertSequenceEqual
    self.fail(msg)
  File "C:\_\py36\lib\unittest\case.py", line 666, in fail
    raise self.failureException(msg)
AssertionError: Lists differ: ['D:\\Code\\build_cu\\QtApplication', 'C:\\[96 chars]ets'] != ['QtApplication', 'C:\\Qt\\Qt5.9.2\\5.9.2\\[76 chars]ets']

First differing element 0:
'D:\\Code\\build_cu\\QtApplication'
'QtApplication'

- ['D:\\Code\\build_cu\\QtApplication',
+ ['QtApplication',
   'C:\\Qt\\Qt5.9.2\\5.9.2\\msvc2015_64\\include',
   'C:\\Qt\\Qt5.9.2\\5.9.2\\msvc2015_64\\include\\QtWidgets']

F.F

2 != 0

Expected :0
Actual   :2
<Click to see difference>

Traceback (most recent call last):
  File "C:\jetbrains\apps\PyCharm-P\ch-0\191.7479.30\helpers\pycharm\teamcity\diff_tools.py", line 32, in _patched_equals
    old(self, first, second, msg)
  File "C:\_\py36\lib\unittest\case.py", line 821, in assertEqual
    assertion_func(first, second, msg=msg)
  File "C:\_\py36\lib\unittest\case.py", line 814, in _baseAssertEqual
    raise self.failureException(msg)
AssertionError: 0 != 2

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "C:\_\py36\lib\unittest\case.py", line 59, in testPartExecutor
    yield
  File "C:\_\py36\lib\unittest\case.py", line 601, in run
    testMethod()
  File "G:\_customer\xyz\pc_lint_json_db\test_lint4jsondb.py", line 213, in test_05a_include_only
    self.assertEqual(len(db.items), 2)

2 != 4

Expected :4
Actual   :2
<Click to see difference>

Traceback (most recent call last):
  File "C:\jetbrains\apps\PyCharm-P\ch-0\191.7479.30\helpers\pycharm\teamcity\diff_tools.py", line 32, in _patched_equals
    old(self, first, second, msg)
  File "C:\_\py36\lib\unittest\case.py", line 821, in assertEqual
    assertion_func(first, second, msg=msg)
  File "C:\_\py36\lib\unittest\case.py", line 814, in _baseAssertEqual
    raise self.failureException(msg)
AssertionError: 4 != 2

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "C:\_\py36\lib\unittest\case.py", line 59, in testPartExecutor
    yield
  File "C:\_\py36\lib\unittest\case.py", line 601, in run
    testMethod()
  File "G:\_customer\xyz\pc_lint_json_db\test_lint4jsondb.py", line 221, in test_05b_exclude_all
    self.assertEqual(len(db.items), 2)

FF

a2.cpp != <dir>\a2.cpp

Expected :<dir>\a2.cpp
Actual   :a2.cpp
<Click to see difference>

Traceback (most recent call last):
  File "C:\jetbrains\apps\PyCharm-P\ch-0\191.7479.30\helpers\pycharm\teamcity\diff_tools.py", line 32, in _patched_equals
    old(self, first, second, msg)
  File "C:\_\py36\lib\unittest\case.py", line 821, in assertEqual
    assertion_func(first, second, msg=msg)
  File "C:\_\py36\lib\unittest\case.py", line 1194, in assertMultiLineEqual
    self.fail(self._formatMessage(msg, standardMsg))
  File "C:\_\py36\lib\unittest\case.py", line 666, in fail
    raise self.failureException(msg)
AssertionError: '<dir>\\a2.cpp' != 'a2.cpp'
- <dir>\a2.cpp
+ a2.cpp

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "C:\_\py36\lib\unittest\case.py", line 59, in testPartExecutor
    yield
  File "C:\_\py36\lib\unittest\case.py", line 601, in run
    testMethod()
  File "G:\_customer\xyz\pc_lint_json_db\test_lint4jsondb.py", line 232, in test_05c_mix_include_and_exclude
    self.assertEqual(db.items[0].file, "a2.cpp")

Assertion failed
FF.
======================================================================
FAIL: test_03a_source_trail_style_json_db (test_lint4jsondb.Lint4JsonCompilationDbUnitTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "C:\jetbrains\apps\PyCharm-P\ch-0\191.7479.30\helpers\pycharm\teamcity\diff_tools.py", line 32, in _patched_equals
    old(self, first, second, msg)
  File "C:\_\py36\lib\unittest\case.py", line 821, in assertEqual
    assertion_func(first, second, msg=msg)
  File "C:\_\py36\lib\unittest\case.py", line 1194, in assertMultiLineEqual
    self.fail(self._formatMessage(msg, standardMsg))
  File "C:\_\py36\lib\unittest\case.py", line 666, in fail
    raise self.failureException(msg)
AssertionError: 'F:\\VS2017\\working\\mocs_compilation.cpp' != 'F:/VS2017/working/mocs_compilation.cpp'
- F:\VS2017\working\mocs_compilation.cpp
?   ^      ^       ^
+ F:/VS2017/working/mocs_compilation.cpp
?   ^      ^       ^

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "G:\_customer\xyz\pc_lint_json_db\test_lint4jsondb.py", line 89, in test_03a_source_trail_style_json_db
    "F:/VS2017/working/mocs_compilation.cpp")
  File "C:\jetbrains\apps\PyCharm-P\ch-0\191.7479.30\helpers\pycharm\teamcity\diff_tools.py", line 38, in _patched_equals
    raise error
teamcity.diff_tools.EqualsAssertionError:  :: F:\VS2017\working\mocs_compilation.cpp != F:/VS2017/working/mocs_compilation.cpp

======================================================================
FAIL: test_03b_cmake_style_json_db (test_lint4jsondb.Lint4JsonCompilationDbUnitTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "C:\jetbrains\apps\PyCharm-P\ch-0\191.7479.30\helpers\pycharm\teamcity\diff_tools.py", line 32, in _patched_equals
    old(self, first, second, msg)
  File "C:\_\py36\lib\unittest\case.py", line 821, in assertEqual
    assertion_func(first, second, msg=msg)
  File "C:\_\py36\lib\unittest\case.py", line 1194, in assertMultiLineEqual
    self.fail(self._formatMessage(msg, standardMsg))
  File "C:\_\py36\lib\unittest\case.py", line 666, in fail
    raise self.failureException(msg)
AssertionError: '\\home\\user\\code\\login\\LoginDialog.cpp' != '/home/user/code/login/LoginDialog.cpp'
- \home\user\code\login\LoginDialog.cpp
? ^    ^    ^    ^     ^
+ /home/user/code/login/LoginDialog.cpp
? ^    ^    ^    ^     ^

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "G:\_customer\xyz\pc_lint_json_db\test_lint4jsondb.py", line 117, in test_03b_cmake_style_json_db
    "/home/user/code/login/LoginDialog.cpp")
  File "C:\jetbrains\apps\PyCharm-P\ch-0\191.7479.30\helpers\pycharm\teamcity\diff_tools.py", line 38, in _patched_equals
    raise error
teamcity.diff_tools.EqualsAssertionError:  :: \home\user\code\login\LoginDialog.cpp != /home/user/code/login/LoginDialog.cpp

======================================================================
FAIL: test_03c_qbs_created_for_msvc_json_db (test_lint4jsondb.Lint4JsonCompilationDbUnitTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "C:\jetbrains\apps\PyCharm-P\ch-0\191.7479.30\helpers\pycharm\teamcity\diff_tools.py", line 32, in _patched_equals
    old(self, first, second, msg)
  File "C:\_\py36\lib\unittest\case.py", line 821, in assertEqual
    assertion_func(first, second, msg=msg)
  File "C:\_\py36\lib\unittest\case.py", line 1194, in assertMultiLineEqual
    self.fail(self._formatMessage(msg, standardMsg))
  File "C:\_\py36\lib\unittest\case.py", line 666, in fail
    raise self.failureException(msg)
AssertionError: 'G:\\qzipreader\\main.cpp' != 'G:/qzipreader/main.cpp'
- G:\qzipreader\main.cpp
?   ^          ^
+ G:/qzipreader/main.cpp
?   ^          ^

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "G:\_customer\xyz\pc_lint_json_db\test_lint4jsondb.py", line 152, in test_03c_qbs_created_for_msvc_json_db
    "G:/qzipreader/main.cpp")
  File "C:\jetbrains\apps\PyCharm-P\ch-0\191.7479.30\helpers\pycharm\teamcity\diff_tools.py", line 38, in _patched_equals
    raise error
teamcity.diff_tools.EqualsAssertionError:  :: G:\qzipreader\main.cpp != G:/qzipreader/main.cpp

======================================================================
FAIL: test_03d_cmake_ninja_windows_json_db (test_lint4jsondb.Lint4JsonCompilationDbUnitTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "G:\_customer\xyz\pc_lint_json_db\test_lint4jsondb.py", line 188, in test_03d_cmake_ninja_windows_json_db
    'C:\\Qt\\Qt5.9.2\\5.9.2\\msvc2015_64\\include'
AssertionError: Lists differ: ['D:\\Code\\build_cu\\QtApplication', 'C:\\[96 chars]ets'] != ['QtApplication', 'C:\\Qt\\Qt5.9.2\\5.9.2\\[76 chars]ets']

First differing element 0:
'D:\\Code\\build_cu\\QtApplication'
'QtApplication'

- ['D:\\Code\\build_cu\\QtApplication',
+ ['QtApplication',
   'C:\\Qt\\Qt5.9.2\\5.9.2\\msvc2015_64\\include',
   'C:\\Qt\\Qt5.9.2\\5.9.2\\msvc2015_64\\include\\QtWidgets']

======================================================================
FAIL: test_05a_include_only (test_lint4jsondb.Lint4JsonCompilationDbUnitTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "C:\jetbrains\apps\PyCharm-P\ch-0\191.7479.30\helpers\pycharm\teamcity\diff_tools.py", line 32, in _patched_equals
    old(self, first, second, msg)
  File "C:\_\py36\lib\unittest\case.py", line 821, in assertEqual
    assertion_func(first, second, msg=msg)
  File "C:\_\py36\lib\unittest\case.py", line 814, in _baseAssertEqual
    raise self.failureException(msg)
AssertionError: 0 != 2

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "G:\_customer\xyz\pc_lint_json_db\test_lint4jsondb.py", line 213, in test_05a_include_only
    self.assertEqual(len(db.items), 2)
  File "C:\jetbrains\apps\PyCharm-P\ch-0\191.7479.30\helpers\pycharm\teamcity\diff_tools.py", line 38, in _patched_equals
    raise error
teamcity.diff_tools.EqualsAssertionError:  :: 0 != 2

======================================================================
FAIL: test_05b_exclude_all (test_lint4jsondb.Lint4JsonCompilationDbUnitTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "C:\jetbrains\apps\PyCharm-P\ch-0\191.7479.30\helpers\pycharm\teamcity\diff_tools.py", line 32, in _patched_equals
    old(self, first, second, msg)
  File "C:\_\py36\lib\unittest\case.py", line 821, in assertEqual
    assertion_func(first, second, msg=msg)
  File "C:\_\py36\lib\unittest\case.py", line 814, in _baseAssertEqual
    raise self.failureException(msg)
AssertionError: 4 != 2

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "G:\_customer\xyz\pc_lint_json_db\test_lint4jsondb.py", line 221, in test_05b_exclude_all
    self.assertEqual(len(db.items), 2)
  File "C:\jetbrains\apps\PyCharm-P\ch-0\191.7479.30\helpers\pycharm\teamcity\diff_tools.py", line 38, in _patched_equals
    raise error
teamcity.diff_tools.EqualsAssertionError:  :: 4 != 2

======================================================================
FAIL: test_05c_mix_include_and_exclude (test_lint4jsondb.Lint4JsonCompilationDbUnitTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "C:\jetbrains\apps\PyCharm-P\ch-0\191.7479.30\helpers\pycharm\teamcity\diff_tools.py", line 32, in _patched_equals
    old(self, first, second, msg)
  File "C:\_\py36\lib\unittest\case.py", line 821, in assertEqual
    assertion_func(first, second, msg=msg)
  File "C:\_\py36\lib\unittest\case.py", line 1194, in assertMultiLineEqual
    self.fail(self._formatMessage(msg, standardMsg))
  File "C:\_\py36\lib\unittest\case.py", line 666, in fail
    raise self.failureException(msg)
AssertionError: '<dir>\\a2.cpp' != 'a2.cpp'
- <dir>\a2.cpp
+ a2.cpp

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "G:\_customer\xyz\pc_lint_json_db\test_lint4jsondb.py", line 232, in test_05c_mix_include_and_exclude
    self.assertEqual(db.items[0].file, "a2.cpp")
  File "C:\jetbrains\apps\PyCharm-P\ch-0\191.7479.30\helpers\pycharm\teamcity\diff_tools.py", line 38, in _patched_equals
    raise error
teamcity.diff_tools.EqualsAssertionError:  :: <dir>\a2.cpp != a2.cpp

----------------------------------------------------------------------
Ran 15 tests in 0.092s

FAILED (failures=7)

Process finished with exit code 1
<MagicMock name='Popen().communicate().__getitem__().decode()' id='66165648'>

Assertion failed

Assertion failed

Yea I've talked about this in the original post. IMO the current unit tests are not sustainable as it tests both Windows & POSIX paths but os.path is platform-dependent so at least half the tests will fail. We can explicitly use PosixPath and WindowsPath from pathlib for the unit tests but it will require a fair amount of change in the unit test and would require Python 3.4+. What do you think?


Error fetching the checksums file

What happened?
Runninig a minimal playbook with the default vars of the role generates this error:
TASK [cloudalchemy.prometheus : Get checksum list] *******************************************************************
/usr/lib/python3.8/site-packages/requests/__init__.py:89: RequestsDependencyWarning: urllib3 (1.26.0) or chardet (3.0.4) doesn't match a supported version!
  warnings.warn("urllib3 ({}) or chardet ({}) doesn't match a supported "
fatal: [my.domain.name]: FAILED! => {"msg": "An unhandled exception occurred while running the lookup plugin 'url'. Error was a <class 'ansible.errors.AnsibleError'>, original message: Failed lookup url for https://github.com/prometheus/prometheus/releases/download/v2.22.0/sha256sums.txt : <urlopen error [Errno -2] Name does not resolve>"}

Did you expect to see some different?
Yes, to fetch the checksums file.
How to reproduce it (as minimally and precisely as possible):
Using a minimal playbook after downloading the role:
# monitoring.yml
---
- hosts: monitoring
  roles:
    - role: cloudalchemy.prometheus

and running it:
ansible-playbook monitoring.yml

Environment

Role version:
2.22.0

Ansible version information:
ansible 2.10.2

Variables:

all the default ones

Ansible playbook execution Logs:

PLAY [monitoring] ****************************************************************************************************

TASK [Gathering Facts] ***********************************************************************************************
ok: [my.domain.name]

TASK [cloudalchemy.prometheus : Gather variables for each operating system] ******************************************
ok: [my.domain.name] => (item=/etc/ansible/vendor_roles/cloudalchemy.prometheus/vars/debian.yml)

TASK [cloudalchemy.prometheus : Assert usage of systemd as an init system] *******************************************
ok: [my.domain.name] => {
    "changed": false,
    "msg": "All assertions passed"
}

TASK [cloudalchemy.prometheus : Get systemd version] *****************************************************************
ok: [my.domain.name]

TASK [cloudalchemy.prometheus : Set systemd version fact] ************************************************************
ok: [my.domain.name]

TASK [cloudalchemy.prometheus : Assert no duplicate config flags] ****************************************************
ok: [my.domain.name] => {
    "changed": false,
    "msg": "All assertions passed"
}

TASK [cloudalchemy.prometheus : Assert external_labels aren't configured twice] **************************************
ok: [my.domain.name] => {
    "changed": false,
    "msg": "All assertions passed"
}

TASK [cloudalchemy.prometheus : Set prometheus external metrics path] ************************************************
ok: [my.domain.name]

TASK [cloudalchemy.prometheus : Fail when prometheus_config_flags_extra duplicates parameters set by other variables] ***
skipping: [my.domain.name] => (item=storage.tsdb.retention)
skipping: [my.domain.name] => (item=storage.tsdb.path)
skipping: [my.domain.name] => (item=storage.local.retention)
skipping: [my.domain.name] => (item=storage.local.path)
skipping: [my.domain.name] => (item=config.file)
skipping: [my.domain.name] => (item=web.listen-address)
skipping: [my.domain.name] => (item=web.external-url)

TASK [cloudalchemy.prometheus : Get all file_sd files from scrape_configs] *******************************************
ok: [my.domain.name]

TASK [cloudalchemy.prometheus : Fail when file_sd targets are not defined in scrape_configs] *************************

TASK [cloudalchemy.prometheus : Alert when prometheus_alertmanager_config is empty, but prometheus_alert_rules is specified] ***
ok: [my.domain.name] => {
    "msg": "No alertmanager configuration was specified. If you want your alerts to be sent make sure to specify a prometheus_alertmanager_config in defaults/main.yml.\n"
}

TASK [cloudalchemy.prometheus : Get latest release] ******************************************************************
skipping: [my.domain.name]

TASK [cloudalchemy.prometheus : Set prometheus version to {{ _latest_release.json.tag_name[1:] }}] *******************
skipping: [my.domain.name]

TASK [cloudalchemy.prometheus : Get checksum list] *******************************************************************
/usr/lib/python3.8/site-packages/requests/__init__.py:89: RequestsDependencyWarning: urllib3 (1.26.0) or chardet (3.0.4) doesn't match a supported version!
  warnings.warn("urllib3 ({}) or chardet ({}) doesn't match a supported "
fatal: [my.domain.name]: FAILED! => {"msg": "An unhandled exception occurred while running the lookup plugin 'url'. Error was a <class 'ansible.errors.AnsibleError'>, original message: Failed lookup url for https://github.com/prometheus/prometheus/releases/download/v2.22.0/sha256sums.txt : <urlopen error [Errno -2] Name does not resolve>"}

NO MORE HOSTS LEFT ***************************************************************************************************

PLAY RECAP ***********************************************************************************************************
my.domain.name         : ok=10   changed=0    unreachable=0    failed=1    skipped=4    rescued=0    ignored=0

Anything else we need to know?:
🤷

After upgrading the requests package on the target machine, the warning disappeared but the error remains:
TASK [cloudalchemy.prometheus : Get checksum list] *******************************************************************
fatal: [my.domain.name]: FAILED! => {"msg": "An unhandled exception occurred while running the lookup plugin 'url'. Error was a <class 'ansible.errors.AnsibleError'>, original message: Failed lookup url for https://github.com/prometheus/prometheus/releases/download/v2.22.0/sha256sums.txt : <urlopen error [Errno -2] Name does not resolve>"}

My ansible controller was running alpine:edge. Changing it to alpine:3.12.1, the error disappeared. This issue helped: https://github.com/gliderlabs/docker-alpine/issues/539
Closing issue.


First link in readme is 404

Hi, easy to solve issue here:
The first link in the readme.md is unfortunately a 404.
br,
Max

Fixed. Thank you


Question: How to define a constant at compile time?

I'm wondering how to define a constant which depends on a value computed at compile time. For example, in gforth:
180e fpi f/ fconstant fdeg

I like that Pygmy Forth's constants are ordinary definitions, but I don't know how to pass a value into a definition. I see assemble() uses the data stack, and I thought I saw interpreter code using the return stack.

Simple constants can be defined as colon definitions, e.g.,
: 1  ( - 1)   1  ;
CODE words can be used to define a constant calculated at compile time, e.g.,
CODE EIGHT  ( - 8)  dpush(5 + 3)   END-CODE


AuthenticateWithToken does not work

After receiving the access_token from the sum up API, using the grant_type 'password', I try and call AuthenticateWithToken. This returns [Error: Invalid Token] without any other explanation. I am positive the affiliate key is from the account that I use to receive the access token with.

Hi Gustasl
Thank you for contacting us, could you please send an email at<EMAIL_ADDRESS>with the client_id that you are using to issue the token.
Many thanks,

@GustasI look this: https://github.com/sumup/sumup-android-sdk/issues/45#issuecomment-426957816
I had the same problem and it was resolved this way.

@Furiacs did try this solution, the token I receive with grant_type password is the one, that does not work.

@GustasI did you try this?
{
    grant_type: 'password',
    client_id: 'client id created in SumUp control panel',
    username: 'your account username',
    password: 'your account password'
}

This way really works for me...

Hi Furiacs,
The issue was different and now solved. Thank you for your contribution to this topic.
Many thanks,


Rates response can be set to empty string

Just hit an issue where rates.Rates was an empty string.  Case should be handled so the service get_rates() method does not throw an exception and instead returns an empty list

@thenewguy will this work for you?

That is exactly what I am using locally.  It fixes the problem


Where to download videos and annotations

Thank you very much for releasing the dataset.
Where can I download videos and annotations?

I found the videos at http://dl.nextcenter.org/public/vidvrd/vidvrd-videos.zip
But, still can not find the annotations

@xdshang please help with the annotation file

@gurkirt please find the annotations in the dataset page (https://lms.comp.nus.edu.sg/research/VidVRD.html).

Thanks a lot :)


spotlessJavaCheck fails in main

Description
There are spotless errors in the submodule qbft-ref-tests. Because of those errors the gradle build task fails. The pipeline does not show the error, my best guess is that it does no update the submodules before running spotlessJavaCheck.
Steps to Reproduce (Bug)

docker run --rm -it openjdk:11 bash
git clone https://github.com/hyperledger/besu.git
cd besu/
git submodule init
git submodule update
./gradlew spotlessJavaCheck

Expected behavior: spotlessJavaCheck should not fail
Actual behavior: fails with the following error:
> The following files had format violations:
      consensus/qbft/src/reference-test/resources/docker_interop/app/src/main/java/tech/pegasys/qbft/interop/DockerComposeService.java
          @@ -19,8 +19,50 @@
           import·java.util.Map;

           public·class·DockerComposeService·{
          -····private·static·final·String·BESU_COMMAND·=·"chmod·755·/scripts/run_besu.sh·&&·/scripts/run_besu.sh";
          -····private·static·final·String·GO_QUORUM_COMMAND·=·"chmod·755·/scripts/run_geth.sh·&&·/scripts/run_geth.sh";
          +··private·static·final·String·BESU_COMMAND·=
          +······"chmod·755·/scripts/run_besu.sh·&&·/scripts/run_besu.sh";
          +··private·static·final·String·GO_QUORUM_COMMAND·=
          +······"chmod·755·/scripts/run_geth.sh·&&·/scripts/run_geth.sh";
          +··private·String·serviceName;
          +··private·boolean·isBesuMode;
          +··private·String·hostname;
          +··private·int·rpcPort;
          +··private·int·p2pPort;
          +··private·String·ipAddress;
          +··private·String·privateKey;
          +··private·String·staticNodeFileName;
          +
          +··public·Map<String,·Object>·getMap()·{
          +····final·Map<String,·Object>·map·=·new·LinkedHashMap<>();
          +····map.put("hostname",·hostname);
          +····map.put("image",·isBesuMode·?·"${BESU_IMAGE}"·:·"${QUORUM_IMAGE}");
          +····map.put(
          +········"ports",
          +········List.of(
          +············p2pPort·+·":"·+·p2pPort·+·"/tcp",
          +············p2pPort·+·":"·+·p2pPort·+·"/udp",
          +············rpcPort·+·":"·+·rpcPort));
          +····map.put("entrypoint",·List.of("/bin/sh"));
          +····map.put("command",·List.of("-c",·getCommand()));
          +····map.put("networks",·Map.of("app_net",·Map.of("ipv4_address",·ipAddress)));
          +····map.put("restart",·"no");
          +····map.put("volumes",·List.of("./:/scripts"));
          +
          +····return·Map.of(serviceName,·map);
          +··}
          +
          +··private·String·getCommand()·{
          +····final·String·commandFormat·=·"%s·%s·%d·%d·%s";
          +····return·String.format(
          +········commandFormat,
          +········isBesuMode·?·BESU_COMMAND·:·GO_QUORUM_COMMAND,
          +········privateKey,
          +········p2pPort,
          +········rpcPort,
          +········staticNodeFileName);
          +··}
          +
      ... (145 more lines that didn't fit)
  Violations also present in:
      consensus/qbft/src/reference-test/resources/docker_interop/app/src/main/java/tech/pegasys/qbft/interop/DockerComposeYaml.java
      consensus/qbft/src/reference-test/resources/docker_interop/app/src/main/java/tech/pegasys/qbft/interop/QbftDockerComposeApp.java
  Run './gradlew :spotlessApply' to fix these violations.

Frequency:  100%

thanks @daniel-iobuilders! we'll look into this

I have the same problem
Steps to Reproduce (Bug)
git clone --recursive https://github.com/hyperledger/besu
cd besu
./gradlew build
Expected behavior: spotlessJavaCheck should not fail
Actual behavior: fails with the following error:
`> Task :spotlessJavaCheck FAILED
FAILURE: Build failed with an exception.

What went wrong:
Execution failed for task ':spotlessJavaCheck'.

The following files had format violations:
consensus/qbft/src/reference-test/resources/docker_interop/app/src/main/java/tech/pegasys/qbft/interop/DockerComposeService.java
@@ -19,8 +19,50 @@
import·java.util.Map;

       public·class·DockerComposeService·{
      -····private·static·final·String·BESU_COMMAND·=·"chmod·755·/scripts/run_besu.sh·&&·/scripts/run_besu.sh";
      -····private·static·final·String·GO_QUORUM_COMMAND·=·"chmod·755·/scripts/run_geth.sh·&&·/scripts/run_geth.sh";
      +··private·static·final·String·BESU_COMMAND·=
      +······"chmod·755·/scripts/run_besu.sh·&&·/scripts/run_besu.sh";
      +··private·static·final·String·GO_QUORUM_COMMAND·=
      +······"chmod·755·/scripts/run_geth.sh·&&·/scripts/run_geth.sh";
      +··private·String·serviceName;
      +··private·boolean·isBesuMode;
      +··private·String·hostname;
      +··private·int·rpcPort;
      +··private·int·p2pPort;
      +··private·String·ipAddress;
      +··private·String·privateKey;
      +··private·String·staticNodeFileName;
      +
      +··public·Map<String,·Object>·getMap()·{
      +····final·Map<String,·Object>·map·=·new·LinkedHashMap<>();
      +····map.put("hostname",·hostname);
      +····map.put("image",·isBesuMode·?·"${BESU_IMAGE}"·:·"${QUORUM_IMAGE}");
      +····map.put(
      +········"ports",
      +········List.of(
      +············p2pPort·+·":"·+·p2pPort·+·"/tcp",
      +············p2pPort·+·":"·+·p2pPort·+·"/udp",
      +············rpcPort·+·":"·+·rpcPort));
      +····map.put("entrypoint",·List.of("/bin/sh"));
      +····map.put("command",·List.of("-c",·getCommand()));
      +····map.put("networks",·Map.of("app_net",·Map.of("ipv4_address",·ipAddress)));
      +····map.put("restart",·"no");
      +····map.put("volumes",·List.of("./:/scripts"));
      +
      +····return·Map.of(serviceName,·map);
      +··}
      +
      +··private·String·getCommand()·{
      +····final·String·commandFormat·=·"%s·%s·%d·%d·%s";
      +····return·String.format(
      +········commandFormat,
      +········isBesuMode·?·BESU_COMMAND·:·GO_QUORUM_COMMAND,
      +········privateKey,
      +········p2pPort,
      +········rpcPort,
      +········staticNodeFileName);
      +··}
      +
  ... (145 more lines that didn't fit)

Violations also present in:
consensus/qbft/src/reference-test/resources/docker_interop/app/src/main/java/tech/pegasys/qbft/interop/DockerComposeYaml.java
consensus/qbft/src/reference-test/resources/docker_interop/app/src/main/java/tech/pegasys/qbft/interop/QbftDockerComposeApp.java
Run './gradlew :spotlessApply' to fix these violations.
`

This has been fixed as part of #2761 which excludes the qbft reference tests from the spotless check.
Agree that we should make that QBFT reference tests are using google code format.


feat: New Sample for Map-Js, Map Style displaying all POI

Describe your changes
I created one new sample for Maps-Js Map Style page. This sample displays all POI on the map.

:tada: This PR is included in version 1.15.0 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket:


operator aqua-operator-certified (v6.2.21321)

Adding version 6.2.21321

Hi @yossig-aquasec, would you mind taking a moment to complete this 3 question survey regarding this new certification workflow so we can improve things in the future? https://forms.gle/AEfu3i219JkY528p9 Thank you so much.


Always getting "... sshfs.sock: connect: no such file or directory" in docker 17.03-ce (swarm mode) using rpi and rasbian v8/jessie

I tried to create a volume and I got always:
sshfs.sock: connect: no such file or directory
I'm using swarm mode 17.03.0-ce build 60ccb22 with rpi under rasbian v8/jessie
connecting to a rpi using also the same debian/jessie environment.
fuse and ssh is installed on target and swarm hosts

+1 Where the socketAddress = "/run/docker/plugins/sshfs.sock" used?

@giminni @rootsongjc I'm not able to reproduce. do you still have the issue ?

The problem has been solved. Building the plugin on my Mac but running on CentOS so that the .sock doesn't created.

@rootsongjc how are you building the plugin, and why aren't you using the official one, vieux/sshfs:latest ?

@vieux yes, I build the plugin manually, and it is OK for me.

@rootsongjc not sure I understand, but looks like you're not building it correctly

see https://github.com/vieux/docker-volume-sshfs/blob/master/Dockerfile#L5 , you have to mkdir the folder

@vieux This is not a problem, I have solved it. Thank you.

I am running into this on a raspberrypi right now. Any ideas on how to fix? Rebuild on device itself?

If you build the plugin on the Raspberry Pi itself, it works fine. Here were the steps I performed (on the Raspberry Pi):
git clone https://github.com/vieux/docker-volume-sshfs.git
cd docker-volume-sshfs
make all
make enable

@ogmundur  thanks a lot, did it too and works fine.
May I ask you how did you decide to do this ? I mean what drove you to the conclusion to rebuild it on this arm machine to make it work?
again thx a lot

@ogmundur  just one basic question : how do you integrate the SSH private key when you launch the make all?
I mean, I didn't find way to add SSH private key option when I use makefile.
Thanks a lot

Very welcome. I am afraid I just stumbled on this via trial and error. I haven't tried adding a private key yet (I just used a password).

Argh Finally found the correct way to make it happen on my system (one rpi as a server, one mac hosting the remote volume), thanks to this do not have to have to share my password.
1- installing vieux/sshfs with make all (as @ogmundur recommended ON ALL MACHINES, for me : rpi (where my server is) and mac (to put my volume shared)
2- be sure to have a root keygene already done (for me : in Pi), and identify the folder where rsa are : /root/.ssh/, ensure the public key has been shared (for me with : mac), otherwise have a look at : https://www.raspberrypi.org/documentation/remote-access/ssh/passwordless.md)
3 - (for me on pi) docker plugin disable vieux/sshfs:next
4- (for me on pi) docker plugin set vieux/sshfs sshkey.source=/root/.ssh/ (see this : https://blog.raphaelpiccolo.com/post/850)
5 - (for me on pi) docker plugin enable vieux/sshfs:next
6 - (for me on pi) and this is my docker-compose.yml to be launched :
version: "3"
services:
myserver:
image: nginx:latest
ports:
- "80:80"
volumes:
- COMMONVOLUME:/usr/share/nginx/html
volumes:
COMMONVOLUME:
driver: "vieux/sshfs:next"
driver_opts:
sshcmd: @:/REMOTEPATH/WHERE/THE/FOLDER/TOBESYNCFORVOLUME/IS
allow_other: ""

If you build the plugin on the Raspberry Pi itself, it works fine. Here were the steps I performed (on the Raspberry Pi):
git clone https://github.com/vieux/docker-volume-sshfs.git
cd docker-volume-sshfs
make all
make enable

Had the same problem with rpi4 and ubuntu server. This answer solved it.

If you build the plugin on the Raspberry Pi itself, it works fine. Here were the steps I performed (on the Raspberry Pi):
git clone https://github.com/vieux/docker-volume-sshfs.git cd docker-volume-sshfs make all make enable

How can I set the sshkey.source flag when using this method?


Add a check in CI for formatting, and invoke format

Definitely something we want to have. But I’ve starting a PR that incorporates this task as well as a few others for linting, so maybe better to wait for that before merging this one, because in the larger PR the task will be grouped with others under a common task group. I should have it up for review shortly.


High Memory Use

I've been testing faster-whisper for a little while and quite like the results. Thank you for your hard work. 👍
However, I've been having problems with memory use on larger files. As an example, I have a very long audio file (5.5 hours) which I am transcribing in a container with 4 cpu cores and 16gb RAM available. I cannot share the file as it is copyrighted, but it is just speech with very little silence. Example code:
model = WhisperModel("small.en", device="cpu", cpu_threads=8, compute_type="int8")
segments, info = model.transcribe(audio_file.name, word_timestamps=True)

This tends to run for about 2hrs with the container memory utilization gradually growing from ~10% all the way to 100% at which point the container hits an OOM and is killed. It almost feels like there's some sort of memory leak.
I started with a lower memory allocation and kept increasing to 16gb, but every time I try a longer file I hit an OOM. I also tried running the same file with float32 compute type and got the same result. Am I missing something? Anything I can try to get around this?

I don't reproduce this issue. I let a transcription run for 1h using the same options as you and the memory usage is pretty constant. I don't think it will change if I let the script run longer.
Is anything else happening in your code? What are you doing with the generated segments?

Just writing the output to a text file. The whole file ends up being less than 2MB, so I doubt that the problem is there, but maybe I'm not seeing something?
More complete example (OOM on the nested for loop):
# download audio file from S3

model = WhisperModel("small.en", device="cpu", cpu_threads=8, compute_type="int8")
segments, info = model.transcribe(audio_file.name, word_timestamps=True)

 with tempfile.NamedTemporaryFile(suffix='.txt', mode='w', delete=False) as output_file:
        for segment in segments:
            for word in segment.words:
                output_file.write("%.3f,%.3f,%s\n" % (word.start, word.end, word.word))

# upload transcript file to S3

I am using version 0.5.1 btw.

Can you set the environment variable CT2_VERBOSE=1 before running the script and report the logging output here?
CT2_VERBOSE=1 python3 …

I'm running this now. The env var added a bunch of extra output on startup, but the transcription is currently running and not producing any output (same as before). The memory use is growing, though, so I'll leave it on to see if extra output is added before the OOM. I'll update the comment when it completes.
[2023-05-20 16:51:07.763] [ctranslate2] [thread 1] [info] CPU: GenuineIntel (SSE4.1=true, AVX=true, AVX2=true, AVX512=true)
[2023-05-20 16:51:07.763] [ctranslate2] [thread 1] [info]  - Selected ISA: AVX2
[2023-05-20 16:51:07.763] [ctranslate2] [thread 1] [info]  - Use Intel MKL: true
[2023-05-20 16:51:07.763] [ctranslate2] [thread 1] [info]  - SGEMM backend: MKL (packed: false)
[2023-05-20 16:51:07.763] [ctranslate2] [thread 1] [info]  - GEMM_S16 backend: MKL (packed: false)
[2023-05-20 16:51:07.763] [ctranslate2] [thread 1] [info]  - GEMM_S8 backend: MKL (packed: false, u8s8 preferred: true)
[2023-05-20 16:51:08.739] [ctranslate2] [thread 1] [info] Loaded model /root/.cache/huggingface/hub/models--guillaumekln--faster-whisper-small.en/snapshots/4e49ce629e3fa4c3da596c602b212cb026910443 on device cpu:0
[2023-05-20 16:51:08.739] [ctranslate2] [thread 1] [info]  - Binary version: 6
[2023-05-20 16:51:08.739] [ctranslate2] [thread 1] [info]  - Model specification revision: 3
[2023-05-20 16:51:08.739] [ctranslate2] [thread 1] [info]  - Selected compute type: int8

This was an issue with my specific setup.
I had 4 cpu cores (multithreaded) available to the container and 8 threads set on the model parameter. Setting the cpu threads down to 4 seemed to resolve the issue - memory remains at under 2GB use for the whole 2hrs of transcription.
The memory growing in the way that it did still seems unusual, though.

good to know...I transcribe 36 hour audiobooks daily to vtt and I set my thread count to 8 which is max my computer can handle.

I did not manage to reproduce this issue. I'm closing it since you manage to solve the problem. In general you should not set more threads than the number of CPU cores anyway.
If anyone can provide a way to consistently reproduce the issue (e.g. using a Docker container with CPU restrictions), please update this thread again.


Unable to send image data using Data track API

I am developing two ios apps with Data Tracks implemented. I am trying to send image data from one app to other. Below method is getting called correctly on receiving the data.
func remoteDataTrack(_ remoteDataTrack: TVIRemoteDataTrack, didReceive message: Data) {}
But  when i try to load the received data into an image view, only half of the image is loaded.
I could record the below error in console,
2019-05-09 15:32:08.918098+0530 PhillipsRemote[3409:803831] remoteDataTrack:didReceiveData: 65632 bytes
2019-05-09 15:32:12.510756+0530 PhillipsRemote[3409:803831] JPEGDecompressSurface : Picture decode failed: e00002d1
2019-05-09 15:32:12.522382+0530 PhillipsRemote[3409:803831] JPEGDecompressSurface : Picture decode failed: e00002d1
2019-05-09 15:32:12.541433+0530 PhillipsRemote[3409:803831] [0x10cb27200] Decoding failed with error code -1
2019-05-09 15:32:12.541468+0530 PhillipsRemote[3409:803831] [0x10cb27200] Decoding: C0 0x04650984 0x0047304A 0x22111100 0x00264003 65632
2019-05-09 15:32:12.541484+0530 PhillipsRemote[3409:803831] [0x10cb27200] Options: 1125x2436 [FFFFFFFF,FFFFFFFF] 00025060

What could be the issue here? Also, this recievedata method is getting called 2 to 3 times, even though i am sending the data only once from the other app
Update:
I found the issue, the data is being sent in chunks. How do I find if the complete data is sent or how do I receive the complete data at a stretch?

@vidhyasri2106 I apologize for responding late.
Right, the recommended maximum payload size of data sent over the DataTrack is 16KiB. The underlying webrtc sends data in chunks if you provide a larger payload. see this for more information.

@piyushtank I just ran into this size limit myself after implementing it :)
is there a recommended mode to share image files across rooms?
i was trying to share as datatrack base64

@somlaifischer Data track does not have any recommended mode. It is up to the application on how to it would send/receive data.

Closing the ticket as answered. If you have any question feel free to reopen this or open a new one.


ECR Repositories not found

I was following the terraform guide. I ran the series of commands, as stated in the guide:
npm run docker-login
npm run build
npm run ecr-create-repos
npm run build
npm run ecr-tag-repos
npm run ecr-push-repos
npm run ecr-repositories
terraform init
terraform plan

When I get to the terraform plan step I get the following repo not found error:
➜  ecs-terraform git:(master) terraform plan
Refreshing Terraform state in-memory prior to plan...
The refreshed state will be used to calculate this plan, but will not be
persisted to local or remote state storage.

data.aws_availability_zones.available: Refreshing state...
data.aws_ecr_repository.app: Refreshing state...
data.aws_ecr_repository.nginx: Refreshing state...
data.aws_iam_policy_document.ecs_task_execution_role: Refreshing state...
data.aws_iam_policy_document.ecs_auto_scale_role: Refreshing state...

Error: ECR Repository (nginx-ecs-terraform) not found

Error: ECR Repository (app) not found

Not sure what I'm doing wrong as the ECR repos for nginx-ecs-terraform and app both exist and terraform has the correct URI for each?

I didn't update the aws_region with variables.tf
variable "aws_region" {
  description = "The AWS region things are created in"
  default     = "us-west-2"
}

once updated to the correct region it worked.


⚠ Samsung has degraded performance

In df54260, Samsung (https://samsung.com) experienced degraded performance:

HTTP code: 200
Response time: 2214 ms

Resolved: Samsung performance has improved in 68d6712.


[LAB1]511558025

Description

https://github.com/SQLab/112-spring-software-testing-and-secure-programming/pull/1

[x] A clear title (name your PR "[LAB{lab_number}] {your_student_id}")
[x] A meaningful message for PR, as well as its commits
[x] From your specific branch (not main or other's branch) merging to your branch
[x] Excluding any irrelevant files, such as binaries, text files, or dot files
[x] Passing all CI (You should check it first to pass one of the validations in CI. However, you need to make sure your PR passes all CI after you submit it.)

Descrip

[x]  A clear title (name your PR "[LAB{lab_number}] {your_student_id}")
[x]  A meaningful message for PR, as well as its commits
[x]  From your specific branch (not main or other's branch) merging to your branch
[x]  Excluding any irrelevant files, such as binaries, text files, or dot files
[x]  Passing all CI (You should check it first to pass one of the validations in CI. However, you need to make sure your PR passes all CI after you submit it.)

Description

[x]  A clear title (name your PR "[LAB{lab_number}] {your_student_id}")
[x]  A meaningful message for PR, as well as its commits
[x]  From your specific branch (not main or other's branch) merging to your branch
[x]  Excluding any irrelevant files, such as binaries, text files, or dot files
[x]  Passing all CI (You should check it first to pass one of the validations in CI. However, you need to make sure your PR passes all CI after you submit it.)


Pre commit

This is a minimal variant of boto/botocore#2472 while we work out our longer term decisions on formatting. One of the suggestions from that we reviewed and seems like a solid path forward. The project is developed by one of the main pytest/tox developers and appears to have wide adoption throughout most major Python projects. We'll start this with flake8 on the main codebase (tests are omitted for the moment), and begin pulling in new features like formatting, isort, etc. as we build confidence.
Whether we wire this up to pre-commit.ci is still TBD, but this will provide a useful local option in the interim and helps us codify parts of boto/boto3#2959.

Codecov Report

Merging #205 (8d0226b) into develop (af982f8) will decrease coverage by 0.26%.
The diff coverage is 85.71%.

@@             Coverage Diff             @@
##           develop     #205      +/-   ##
===========================================
- Coverage    86.01%   85.74%   -0.27%
===========================================
  Files           16       16
  Lines         2767     2764       -3
===========================================
- Hits          2380     2370      -10
- Misses         387      394       +7

Impacted Files
Coverage Δ

s3transfer/copies.py
100.00% <ø> (ø)

s3transfer/upload.py
96.37% <0.00%> (ø)

s3transfer/__init__.py
99.67% <100.00%> (ø)

s3transfer/bandwidth.py
99.33% <100.00%> (ø)

s3transfer/compat.py
69.76% <100.00%> (-13.96%)
:arrow_down:

s3transfer/download.py
95.39% <100.00%> (ø)

s3transfer/processpool.py
99.44% <100.00%> (ø)

s3transfer/utils.py
99.42% <100.00%> (-0.01%)
:arrow_down:

s3transfer/tasks.py
95.83% <0.00%> (-0.84%)
:arrow_down:

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 6bf35ab...8d0226b. Read the comment docs.


Increase hdist

Right now, this is set to 5 in the default config, and we've been running with it set to 10 in the testnets. However, according to @tal-m, it should be closer to 200. This increases our robustness against hare attacks, since honest nodes will explicitly vote neutrally until hare has terminated or failed completely, and we need a big enough window for honest votes to accumulate and override dishonest votes against a pattern while honest nodes continued to wait for hare.

@lrettig still relevant?

Yes, this will be part of mainnet parameterization


driverAdapters early access + Cloudflare Hyperdrive: "Release called on client which has already been released to the pool"

Bug description
Hi y'all, I'm running the driverAdapters early access.
I have a Cloudflare Worker that does multiple database calls per request, connected to a Postgres database behind Cloudflare Hyperdrive.
It seems like after the first request finishes, the connection is closed and the other database requests fail with an exception. Here are my logs:
"exceptions": [
    {
      "name": "Error",
      "message": "Release called on client which has already been released to the pool.",
      "timestamp":<PHONE_NUMBER>613
    },
    {
      "name": "Error",
      "message": "The script will never generate a response.",
      "timestamp":<PHONE_NUMBER>613
    }
  ],

How to reproduce

Follow the Hyperdrive getting started tutorial https://developers.cloudflare.com/hyperdrive/get-started/
Follow the Prisma + Cloudflare driverAdapters early access pg instructions

// e.g. src/index.js
import { PrismaClient } from '@prisma/client'
import { PrismaPg } from '@prisma/adapter-pg'
import { Pool } from 'pg'

export default {
  async fetch(request, env, ctx) {
    const pool = new Pool({ connectionString:  env.HYPERDRIVE.connectionString })
    const adapter = new PrismaPg(pool)
    const prisma = new PrismaClient({ adapter })

    const promises = [prisma.user.findMany(), prisma.user.findFirst(), prisma.user.findMany()] // multiple requests here
    const results = await Promise.all(promises)
    const result = JSON.stringify(users)
    return new Response(result);
  }
}

Make multiple database requests in one worker call
Deploy your worker in production
Go to your worker settings and start streaming logs
Open the worker url and observe errors in log stream

Expected behavior
I can run multiple driverAdapter database requests using Cloudflare workers Hyperdrive in 1 go.
Environment & setup

OS: WSL
Database: Postgres
Node.js v21

Versions
Prisma: v5.11.0-dev.5
Wrangler: v3.30.1

Internal note: we have a test for Hyperdrive since last week here https://github.com/prisma/ecosystem-tests/pull/4610

@Jolg42 let me know if you want me to test something on my setup.I found this bug on my production site. It's using Hyperdrive going to a DigitalOcean database.
It fires off multiple parallel database queries that finish at different times, but the bug only happened after I deployed it to Cloudflare, locally everything worked fine.

@vladinator1000 I could not reproduce, though here are some thoughts.
The script will never generate a response. error is from Cloudflare Worker, because of the previous error from pg.
@SevInf found the error message Release called on client which has already been released to the pool. in pg code in pg-pool https://github.com/brianc/node-postgres/blob/b4bfd63f6337018b312bf5a9a70887660954cbfa/packages/pg-pool/index.js#L27
Which would be triggered by a release, but given your queries const promises = [prisma.user.findMany(), prisma.user.findFirst(), prisma.user.findMany()], no implicit transaction (created by Prisma) is expected so release() must be called from pg internals. (For context we call release() in the adapter after a commit or rollback https://github.com/prisma/prisma/blob/4aee1423da37c3974515740950c45effed8f8b2b/packages/adapter-pg/src/pg.ts#L113-L126)
Pool is what we require for the pg adapter (Client is not an option here because of how transactions needs to be handled.)
So now, could you try changing one line in your code? and add max: 1 (the default is 10)
-  const pool = new Pool({ connectionString:  env.HYPERDRIVE.connectionString })
+ const client = new Pool({ connectionString: env.HYPERDRIVE.connectionString, max: 1 })

Because with Hyperdrive, there is no need of a connection pool, it's already managed by Hyperdrive.

There are other options, that could be interesting to try later, if this doesn't improve things, like allowExitOnIdle: true.
See https://node-postgres.com/apis/pool
type Config = {
  // all valid client config options are also valid here
  // in addition here are the pool specific configuration parameters:

  // number of milliseconds to wait before timing out when connecting a new client
  // by default this is 0 which means no timeout
  connectionTimeoutMillis?: number

  // number of milliseconds a client must sit idle in the pool and not be checked out
  // before it is disconnected from the backend and discarded
  // default is 10000 (10 seconds) - set to 0 to disable auto-disconnection of idle clients
  idleTimeoutMillis?: number

  // maximum number of clients the pool should contain
  // by default this is set to 10.
  max?: number

  // Default behavior is the pool will keep clients open & connected to the backend
  // until idleTimeoutMillis expire for each client and node will maintain a ref
  // to the socket on the client, keeping the event loop alive until all clients are closed
  // after being idle or the pool is manually shutdown with `pool.end()`.
  //
  // Setting `allowExitOnIdle: true` in the config will allow the node event loop to exit
  // as soon as all clients in the pool are idle, even if their socket is still open
  // to the postgres server.  This can be handy in scripts & tests
  // where you don't want to wait for your clients to go idle before your process exits.
  allowExitOnIdle?: boolean
}

@vladinator1000 Did you have a chance to try this since? Because I could not reproduce on my side, I'm curious to know if it helped you or not 👀

@Jolg42 just tried it, adding max: 1 to the pool options worked! 🥳

Let's keep the issue open as we want to fully understand why this happens.

I really could not reproduce, I tried with Hyperdrive caching default and also disabled by sending a lot of queries with autocannon.

But all requests were successful.
If this happens again to you, please let us know what's your Hyperdrive settings, and the best would be to have a minimal reproduction repository.
If this happens to someone else: please open a new issue 🙏🏼
Here is my attempt to reproduce as a repo: https://github.com/Jolg42/prisma-repro-23367

@vladinator1000 You previously mentioned that adding max: 1 to the pool options worked but then got stuck on https://github.com/prisma/prisma/issues/23457 which got resolved with 5.11.0.
My question now is: is everything working for you?
We want to know if you can still reproduce this issue with the latest version of Prisma (without max: 1)?
If so, what are your settings on Hyperdrive, and if you can find out how to get to a minimal reproduction (see my previous message for a minimal reproduction repo, where I could not reproduce).
Let us know if that's something you could try on your side or if we should close this issue instead.

Hey, we had the same problem. Unfortunately, Max connections didn't help us. I noticed that the Cloudflare docs say that you should use the pooled connection with Neon. Neon itself doesn't say anything about this. Maybe it could have something to do with that? Perhaps the problem occurs with pooled connections strings in Hyperdrive?
Another possibility is the CPU limits for Cloudflare Workers. If you set them low, could that also lead to the errors?


Settings: push notification toggle should be linked to the ios settings

We should turn on automatically push in vector when the user toggled from off to on in ios settings (and conversely).
Interestingly Whatsapp doesn't do it automatically but does force the question on opening the app if you have toggled from off to on in ios settings

We check now whether the user allowed or denied remote notification in iOS setting.
(see https://github.com/matrix-org/matrix-ios-kit/blob/master/MatrixKit/Models/Account/MXKAccountManager.m#L291)
Here are some use cases which describe the current behaviour:
1- When user does not allow notifications at first launch, we turn on automatically push in vector when he changes later this option in iOS settings.
2 - When the remote notifications are allowed in vector settings, the state of the toggle button in vector settings follows the state of the "Allow Notifications" toggle button in iOS settings.
3 - If the user turns off the toggle button in vector settings, then it is not automatically turned on when user switches from off to on the "Allow Notifications" toggle button in iOS settings.


Add Gene Info cards to Gene Expression

Gene Info cards has been a very helpful feature in Explorer, with about 20% of users continuing to utilize it. With the launch of Find Marker Genes, we want to bring this functionality into Gene Expression as well.
Design
Prototype
https://images.zenhubusercontent.com/228681195/50226199-93f9-4957-8011-74dc454a77ee/gene_info_card_interactions_1.mov
https://images.zenhubusercontent.com/228681195/a8969e59-241b-4071-9c4e-2df6a88e33d7/gene_info_card_interactions_2.mov
cc @signechambers1 for product, @karenliang0 for design

Posting figma for gene info cards for my reference https://www.figma.com/file/blyEMZDsi7EMopyyIX4XAg/Q1-2023-Gene-Expression-Improvements?node-id=96%3A351323&t=sGgBfXR4809qDtyM-1

Progress so far
https://images.zenhubusercontent.com/228681195/d101eced-9b9e-4175-897c-f4f6effda09a/gene_info_progress_1.mov

Progress so far
https://images.zenhubusercontent.com/228681195/d49c9d72-a23b-4fb4-9f95-7d2fb19f4b62/gene_info_progress_1.mov
One thing to note that it can take some time to load the gene summary, so I think there should be some decision made to determine what the loading state would look like. In the recording I had a simple "Loading..." text while it's retrieving the data

@atarashansky when the show_warning_banner is true, what should be shown instead of the NCBI URL? Do we just omit the link entirely?

It's just that it may not be an exact hit.

Demo!
https://user-images.githubusercontent.com/109984998/227580819-953ab2ab-6397-47b9-803f-596e3ebfce3c.mov


make scheduler metrics visible

It would be nice if we could see the time used in scheduling for each plugin.

[ ] Aggregate the time used for each plugin.

It can be achieved in the same way as scheduling results. We can aggregate it in simulatorPlugin and send used time to resultStore.
EDIT: Not need to aggregate the time on simulator. We can use plugin_execution_duration_seconds to see each plugins time. Potentially other metrics can also be utilized.

[ ] [optional] show them on WebUI in table or graph..? should be something nice.
[ ] update doc. (include https://github.com/kubernetes-sigs/kube-scheduler-simulator/blob/master/docs/how-it-works.md)

/assign
/kind feature

Hi @sanposhiho
Is there any progress on this? Are you looking for a worker?

I haven't worked on this. So, feel free to pick this issue.
But, I think we should work on the following issue before this feature.
https://github.com/kubernetes-sigs/kube-scheduler-simulator/issues/125

Hi @196Ikuchil @sanposhiho , I am planning to work on this feature, additionally, my thoughts are to do something similar to Kube-Scheduler, where these performance metrics are emitted in prometheus metrics format. Something like this ? WDYT ?

EDIT: turns out it is already implemented here. Maybe we could implement a metrics endpoint for the simulator server ?

Oh, yes. You are right. I misunderstood about the metrics plugin_execution_duration_seconds 😓
Change this issue to make scheduler metrics visible.
/retitle make scheduler metrics visible

One problem is pluginMetricsSamplePercent is const and we cannot change the value. Ideally, I would like to see metrics recorded for all pod schedules. 🤔
I will make a feature request issue to k/k later. We will not know if the request will be approved until discussing it, but consider a work-around or another way if it is not approved.

https://github.com/kubernetes/kubernetes/issues/108903

Regarding the metrics available, should we add a metric handler to the simulator server ? WDYT about having our own frontend charts to show these metrics like dashboard (probably need to investigate some of the frontend charts) or using prometheus to show them ?

@matthewygf
Sorry, I missed your comment.

having our own frontend charts to show these metrics like dashboard (probably need to investigate some of the frontend charts) or using prometheus to show them ?

Yeah, hmm, I prefer the former. But, charts in frontend.. It could be a very tough road because at least I'm not very familiar with frontend... 😓 It would be so much easier if there were a public component or a public library to show charts from data in the form of grafana.

@matthewygf
Sorry, I missed your comment.

having our own frontend charts to show these metrics like dashboard (probably need to investigate some of the frontend charts) or using prometheus to show them ?

Yeah, hmm, I prefer the former. But, charts in frontend.. It could be a very tough road because at least I'm not very familiar with frontend... 😓 It would be so much easier if there were a public component or a public library to show charts from data in the form of grafana.

No problem @sanposhiho , I will have a look at it ~

One approach is to process the grafana data on the simulator api into a form that is easy to display on the front end, and then display it on the front end using some library or component.
It seems vuetify has the component to write a simple graph. (But, not sure whether the component is sufficiently expressive)
https://vuetifyjs.com/en/components/sparklines/

/triage accepted
Not to mark as stale.

/area simulator

/remove-lifecycle rotten
/lifecycle frozen

/triage accepted
@ordovicia @utam0k FYI. This could be useful to evaluate the scheduler from another pov.


User experience issues

Testing from a beginner perspective

Unity package needed to import, unable to find
Needed to drag and drop omnica-main folder into unity which isn't helpful for beginners

Not applicable when using from github, only applicable when using from asset store.


arch:lib_atomic: remove and fix gcc warning declaration-mismatch

Remove GCC ignored warning and fix
Signed-off-by: zhuyanlin<EMAIL_ADDRESS>Summary
Impact
Testing

 Error: machine/arch_atomic.c:37:8: error: conflicting types for built-in function '__atomic_store_1'; expected 'void(volatile void *, unsigned char,  int)' [-Werror=builtin-declaration-mismatch]
   37 |   void __atomic_store_ ## n (type *ptr,                   \
      |        ^~~~~~~~~~~~~~~
machine/arch_atomic.c:185:1: note: in expansion of macro 'STORE'
  185 | STORE(1, uint8_t)
      | ^~~~~

Seems like GCC is expecting void __atomic_store_n (void *ptr, type val, int memorder) despite documentation states void __atomic_store_n (type *ptr, type val, int memorder);.

 Error: machine/arch_atomic.c:37:8: error: conflicting types for built-in function '__atomic_store_1'; expected 'void(volatile void *, unsigned char,  int)' [-Werror=builtin-declaration-mismatch]
   37 |   void __atomic_store_ ## n (type *ptr,                   \
      |        ^~~~~~~~~~~~~~~
machine/arch_atomic.c:185:1: note: in expansion of macro 'STORE'
  185 | STORE(1, uint8_t)
      | ^~~~~

Seems like GCC is expecting void __atomic_store_n (void *ptr, type val, int memorder) despite documentation states void __atomic_store_n (type *ptr, type val, int memorder);.

It seems that the newer GCC versions have changed the prototype.
I've just tested esp32c3-devkit:nsh with riscv64-unknown-elf-gcc version 10.2 and it also reported the same warning.

@pkarashchenko @gustavonihei
Yes, the prototype have changed in new gcc version.
I update the atomic prototype with new gcc version.
Please review again.


Image caption support

Checklist

[x] I have read the contributing guidelines.
[x] There are no similar request on existing issues (including closed ones).
[x] I have read the project progress and know the current progress of the project.
[x] I was in the master branch of the latest code.

Is your feature request related to a problem? Please describe

I am just converting my wordpress blog to GHP + this template, which is great so far, thanks for doing it! After a lot of automated conversion I arrived to image captions.
My side dump contains image miniatures, which are links to the full size images with caption. It looks like this:
[caption id="attachment\_428" align="aligncenter" width="300" caption="caption text"][![]({{ site.baseurl }}/assets/images/2011/03/IMGP7194-300x200.jpg "IMGP7194")]({{ site.baseurl }}/assets/images/2011/03/IMGP7194.jpg)[/caption]

I learned here that Jekyll supports caption generation. So if I change the above snippet to this:
[![]({{ site.baseurl }}/assets/images/2011/03/IMGP7194-300x200.jpg "IMGP7194")]({{ site.baseurl }}/assets/images/2011/03/IMGP7194.jpg)
*caption text*

It generates an <em> tag under the <a> in the same <p>.
Now the problem is that the caption text is in the same line as the image, while I would expect to be below the image.
Describe the solution you'd like

With the pattern above, I was able to add a custom css like this to cover both links and pure images:
img + em, a + em { display: block; text-align: center; }

Describe alternatives you've considered

Additional context

I am not a frontend guy so I could easily miss some other alternatives which are already supported.

looks cool, I will take the time to research this solution

Hi @libesz,
The style for common  (no hyperlink) image caption has been added, but for now it does not fit the style of the hyperlink image. Because it will be forced to give up the underline effect of the text link, otherwise, a horizontal line will be displayed under the hyperlink picture.
Once the :has() selector is online, I'll add support for the missing part.

Thanks. I will check what I can do until then with my content...

After some thought, waiting for the CSS standard to be updated and for major browsers to support new features was a long way off, so I solved this problem with JS.

Thank you for the solution. Seems works fine with my content!


Hologram issue

Everytime i create a Shop there is  an R for Buy an Sell, i dont know why.. Can you help me pls?

What version do you use?

Server is on 1.8.8 Spigot and i use the newest version 1.12.3 of ShopChest

Maybe it's a typo in the hologram format or in the economy plugin's currency format.

Yes, in the Vault Hook was an issue ... Now i program my own EcoSys and i get new Errors :D
Maybe you can help me again ^^
Here´s the Debug.txt, the Console Error and the Hook Code which is written in the console error but i dont see the issue, maybe i´m blind xD Sorry for my bad english ._.
debug.txt

Some possibilities:
1.) getManager() does return null
2.) getConfig() does return null because there is no config file loaded
3.) getString doesn't return a value because there is no "Currency Format" (shouldn't it be currency-format or something like that in yaml?)
4.) arg0 is passed as null, therefore a NPE occurs
Try to separate line 150 into some lines so you can see where the NPE occurs.
BTW: This is no error by ShopChest, it is caused by your own Plugin vault_hook.
I bet you are not an experianced programer? Try to find out what the NPE causes to fix it 😄

Uhh yes, arg0 was the problem, so i turn it to amount and it works :)
Thank all for your help 👍


Portainer Agent on Docker Swarm Errors

Before you start please confirm the following.

[X] Yes, I've searched similar issues on GitHub.
[X] Yes, I've checked whether this issue is covered in the Portainer documentation or knowledge base.

Problem Description
This problem is intermittent. I have 5 manager nodes. All of them run portainer agent and in the same stack a have a portainer application itself float between the first 3 nodes. Every now and again when doing a reboot to my proxmox, for something like a kernel update the portainer web application throws this error.
Unable to find an agent on any manager node
I have the replication set to global for manager nodes for portainer agent. All the services show they are up but the error still happens.
The only way i can fix it is to do a reboot and hope they work or do a docker service update -f for the service portainer_agent.
Expected Behavior
When portainer and agents start there should be no errors and i can view and edit the swarm.
Actual Behavior
When this happens the portainer web gui works but i can not see any information from any node in the swarm. no volumes, images, containers. Nothing I must reboot or force the agent service to update.
Steps to Reproduce
Just start all the manager nodes. Sometimes the error happens sometimes it doesn't.
Portainer logs or screenshots
No response
Portainer version
2.19.5
Portainer Edition
Community Edition (CE)
Platform and Version
Docker Swarm
OS and Architecture
Debian Bookworm
Browser
Firefox
What command did you use to deploy Portainer?
docker stack deploy

Additional Information
I monitor 40 stacks. I know its alot but it works instantly sometimes and instantly if i do a docker service update -f

This is a known (and quite old) issue with Portainer and Swarm: #8256


[PT] Update content/pt/docs/concepts/architecture/control-plane-node-communication.md

Related to WG naming.
Changes:

Rename to content/pt/docs/concepts/architecture/control-plane-node-communication.md
Update terminology to use "Control Plane"
Update content

Thanks!
/label tide/merge-method-squash
/lgtm


[WIP] Lighter unique Host#domain lookup for in MiqProvisionVirtWorkflow

Makes use of Host.all_unique_downcased_domains (new method) in the MiqProvisionVirtWorkflow#allowed_domains method to return only a list of the domain objects, pre-formatted and reduced to unique entries in SQL, reducing object allocations by reducing what is returned from the DB, the number of unneeded rows that needed to be type casted in ruby, and the temp objects generated to build the domain string in ruby.
The includes option of that method is also taken advantage of if the option[:platform] is set, though, to me it seems to not make sense since it seems like you could have multiple hosts on the same "domain", but have different platforms for each, so this might return different results when filtered on depending on the order and records in the DB (seems like a bug).
About Host.all_unique_downcased_domains
This query is meant to be a query does the work of Host#domain in the query it self, and return it as a column, along with the id column as well.
The advantage of this is it is a much faster way of collecting the domains for a given host, and doesn't require nearly as many attributes to be returned from the DB, creating object allocations we just don't use (hosts has over 30+ columns on it).
It also handles filtering uniq domains in the DB by using SELECT DISTINCT ON (domain) ... in the query, but this has a disadvantage in which it DISTINCT ON doesn't
play nicely with ActiveRecord#select (hence the gsubing).
Metrics
Benchmarks were taken by monitoring the UI requests using the manageiq_performance gem.  The route monitored was selecting the "Lifecycle" -> "Publish this VM to a Template" menu button from a VM show page.  The metrics shown are against database with a fairly large EMS, with about 600 hosts, and are 3 subsequent requests against that route.
Note the change in row counts:
Before

ms
queries
query (ms)
rows

18613
2062
1463.7
70017

17695
2062
1475.5
70017

17774
2062
1578.4
70017

After

ms
queries
query (ms)
rows

19377
2062
1401.6
66781

17789
2062
1450.4
66781

17874
2062
1615.5
66781

Note:  The benchmarks for this change do NOT include the changes from other PRs (https://github.com/ManageIQ/manageiq/pull/17354 for example).  Benchmarks of all changes can be found here.
Links

Partially addresses https://bugzilla.redhat.com/show_bug.cgi?id=1569626
Full collection of proposed changes: git compare
Document keeping track of overall improvements for this effort:  gist
Related PRs:

https://github.com/ManageIQ/manageiq/pull/17354
https://github.com/ManageIQ/manageiq/pull/17355
https://github.com/ManageIQ/manageiq/pull/17357
https://github.com/ManageIQ/manageiq/pull/17358
https://github.com/ManageIQ/manageiq/pull/17359
https://github.com/ManageIQ/manageiq/pull/17381
https://github.com/ManageIQ/manageiq/pull/17402

@miq-bot assign @gmcculloug
@gmcculloug I realized you have been farming these out to some of the members of the automate team, but this comment in particular has me concerned, and I think you possibly had a hand in writing the original code.  Fine if you want to pass this off, but would like your input on if my thoughts on the FIXME were correct or misguided by something I am not accounting for.  Thanks.


Change implementation of sextractor dual mode

Instead of passing multiple images, add a key to the header of the image
https://github.com/winter-telescope/winterdrp/blob/924dc18960d969521d6c18434995fa956b68f5d3/winterdrp/processors/astromatic/sextractor/sextractor.py#L70

Resolved


[Win32 Combobox] UIA backend cannot select by index OR value

When working with a native Win32 ComboBox (i.e. a COMBOBOX control with CBS_DROPDOWNLIST and no other special flags), attempting to select an entry by index or by value results in an error.
Test case:
from pywinauto.application import Application
app = Application(backend="uia").start('C:\\Windows\\notepad.exe')
window = app.top_window()
window.menu_select('Format -> Font')
font = window.Font
font.ScriptComboBox.select(2) # fails with NoPatternInterfaceError() thrown from uia_defs.get_elem_interface(elem, "SelectionItem")
font.ScriptComboBox.select(3) # fails with IndexError("item not found")
font.ScriptComboBox.select('Greek') # fails with IndexError("item not found")
print font.ScriptComboBox.expand().children() # returns [<uia_controls.ListViewWrapper - '[u'Western']', ListBox, ...>, <uiawrapper.UIAWrapper - 'Script:', Static, ...>, <uia_controls.ButtonWrapper - 'Close', Button, ...>]

The problem appears to be that ComboBoxWrapper.children() isn't returning the contents - instead, it's returning the ListBox (if expanded), the static Label for the combobox, and the "Open/Close" button to expand/collapse it.
Currently, the only way I can select an item is to manually .expand() the combobox, get its first child window (the ListBox), find the appropriate index (by iterating across its .texts() ), select it using .get_item(x).select(), .collapse() the combobox, and finally press Up+Down (or vice-versa) in order to ensure that CBN_SELENDOK and CBN_SELCHANGE notifications get generated.
Observed with pywinauto 0.6.5 for Python 2.7 on Windows 7, Windows 8.1, and Windows 10 build 1803.
Using the "win32" backend is not an option for me, because the application I am attempting to automate uses a WTL Ribbon control which only the UIA backend is capable of properly parsing.

Hi @quietust I see this combo box has child button "Open" in Inspect.exe. I think this code should work for you:
font.ScriptComboBox.OpenButton.invoke()
font.ScriptComboBox.ScriptList.select('Greek')

I can add this workaround into the code later. Please confirm it works with both Notepad and the WTL app. I haven't tested it yet. Just had a short look with Inspect.exe.

font.ScriptComboBox.ScriptList.select('Greek') doesn't work (errors with TypeError: select() takes exactly 1 argument (2 given)), but font.ScriptComboBox.ScriptList.Greek.select() does work (in both Notepad and the WTL app), at least on Windows 7.
However, it still isn't triggering CBN_SELENDOK / CBN_SELCHANGE notifications, which is a problem because the WTL app uses them to enable/disable other controls based on the selection; I can still use the Up+Down (or Down+Up) workaround, though I'll have to query the .selected_item_index() to decide which direction to choose first.
Note that when I was testing my original workaround on Windows 8.1 and Windows 10, .select()ing a specific item was not collapsing the combobox as it did on Windows 7, so I suspect it might also be necessary with your workaround.  I've been developing my tests primarily on Windows 7, and my 8.1/10 test systems aren't available at the moment.

It's worth saying it's possible to check if drop down list is still open with method .exists() which returns True/False instead of raising exception (as it usually happens for non-existing controls or by using .wait('exists')).
P.S. Not sure I'll have a chance to tackle all these issues this or next week.


feat: Run puppeteer test for PR and let the selenium fail for PR

Close #300

Run puppeteer test for PR and let the selenium fail for PR
Change Travis matrix to jobs

👍

👍

👍


Protobufs changes

Closes #202
Incomplete

https://github.com/faddat/archlinux-docker/runs/6502790449?check_suite_focus=true
docker image with buf done

@nghuyenthevinh2000 sir, can you please lmk if you think this is now a happy-branch, maybe formally review the total set of changes?

@faddat
I just add proto-gen to makefile so that it will be easier for generating proto. The proto generation is fine.
I think the branch is happy :)))

@nghuyenthevinh2000 hey great catch!
the .history file is an unintentional artifact created by my work on #207
can you please remove from this PR, everything except what you think is needed for the protobufs changes?
thanks!

@nghuyenthevinh2000
Do you think that you may be able to solve this issue?
https://github.com/cosmos/cosmos-sdk/issues/12150
I think that you may be most suited to it

I think that this is great to get in before a next-release.

thanks so much this looks amazing @faddat @nghuyenthevinh2000 @the-frey @giansalex


fix(configure): ignore invalid userToken

Summary
This PR fixes configure widget to ignore invalid userToken.
Although we have fixed nullish user token issues in insights middleware, if users still put null into configure widget, it was passing the null as a string to search api.


Remove reduntant “?” from type definitions in bang accessors!

This PR removes redundant nilable ? symbol from getter/setter/accessor! type declarations throughout the code since they're added in macro definition already.

Good catch @Sija, thanks!

Would it be possible or advisable to add this as a special-case formatter rule? Especially as they're macros not syntax.

@RX14 The formatter has no notion of semantic, and one could redefine property! inside another type

@asterite that's what I was thinking, I wasn't sure if the formatter would be able to tell if it was the stdlib property! or not.

But the property! macro could raise a compilation error if the type is nilable. 💡

another option could be IMHO to make compiler disallow double ? modifier.

@Sija that would be a check in a syntax level that incomplete. Trying to do it at a semantic level would be to disallow unions with more than one Nil, but there are path where you can get unions with two nillables, or build across macros invocation. Hard or imposible to differentiate.
Given that a property! could be called from other macro it might block the user if the generated code plays with Nil and wraps types on the go. I think there is nothing else to do for the time being.


In generating simulate, return nothing, for Enzyme compatibility

Enzyme expects these functions to return nothing to be autodiffable. Is this ok?

You're right. The return type here shouldn't matter. I'll merge this if tests pass and docs build.

It looks like the allocations test failed, but that's okay because it's fragile.
An old test was relying on that output, but that should be updated.
We'll update those tests on our end and merge.


Using the MQTT protocol directly to Device and multiple Modules

This document is not up to date related to the Module identities. Today, we can create under each device identity up to 20 module identities - https://docs.microsoft.com/en-us/azure/iot-hub/iot-hub-devguide-module-twins
As that document stated, each module identity has own independent connection to the IoT Hub. In other words, for example, if the Device1 has two modules such as ModuleA and ModuleB, we have 3 connections to the IoT Hub such as Device1, Device1/ModuleA and Device1/ModuleB, haven't?
Notice, that all of them has own identity, security, primary key, etc. and of course a connection string.
So, I have taken for test purpose a MQTT.fx -1.7.1 client to test a connectivity, direct method, twins, etc. for all 3 identities.
After some time I have figured out how to connect module to the Azure IoT Hub using a MQTT protocol directly.
Broker Address: {iothubhostname}
Broker Port: 8883
Client ID: {deviceId}/{moduleId}
enable ssl/tls, CA signed server certificate
username: {iothubhostname}/{deviceId}/{moduleId}/?api-version=2018-06-30
password: {sastoken}
Everything is working like is described in the document about the device identity, in other words, when is connected only one of them.  Notice, that there are 3 difference clientIDs such as Device1, Device1/ModuleA and last one Device1/ModuleB.
The behavior of these 3 identities are like they have the same clientID on the IoT Hub (probably  only Device1), because only one connection can be created and stayed active for the same clientID, what is typically for MQTT protocol.
There are missing any information in the documents related for connection of modules using the MQTT protocol directly.
In my test, I have successfully using the clientID =  {deviceId}/{moduleId}, but it looks like the Azure IoT Hub somewhere internally doesn't accept a separator '/' in the clientID, isn't?
Anyway, my fundamental question is:
Can we open and keep all MQTT connections active to the Azure IoT Hub for device identity and its modules?
Am I missing something?
Thanks
Roman

Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

ID: bcf2a86a-1de0-2786-db87-58279ceffb22
Version Independent ID: 7e43624f-a87d-1c4d-94e6-e38c1d42686f
Content: Understand Azure IoT Hub MQTT support
Content Source: articles/iot-hub/iot-hub-mqtt-support.md
Service: iot-hub
GitHub Login: @rezasherafat
Microsoft Alias: rezas

@romankiss we will publish some changes to the doc soon to address how to connect a module using MQTT Protocol Directly.
As for your other questions: "Can we open and keep all MQTT connections active to the Azure IoT Hub for device identity and its modules?"

You should, though we found an issue in the service side that will disconnect your modules whenever another MQTT client is already connected with its parent device identity. The two clients will go through a connect/disconnect loop each disconnecting the other indefinitely.

We will take some time fixing it, though as soon as the doc has the updates can you please confirm if it is properly documented? I or @rezasherafat will then come back to this thread whenever the concurrency issue is fixed.
Thanks!

Thanks Antonio,
That's great, the issue has been found and it is going to fix it. I have figured out this issue during an updating my Azure IoT Hub Tester. I will wait for its publishing when the doc and service have been fixed.
Please, have a look at also the other reported issue such as https://github.com/MicrosoftDocs/azure-docs/issues/23805#issuecomment-459104095, it is related to Module Stream and it looks like the problem is also on the service side.
Thanks again.
Roman

@romankiss, for the time being I have updated the docs with the workings of modules via an MQTT client. I will keep you posted on the issue of module vs. device concurrent connection. Thanks.

@rezasherafat, thanks for updated document how to connect a module using the MQTT protocol directly. It looks OK. I do recommend to update also other parts of this document such as Sending device-to-cloud messages and Receiving cloud-to-device messages related to the module. Maybe adding new paragraphs with a name Sending module-to-cloud messages and Receiving cloud-to-module messages will be more clear.
I would like to notice, that the other document such as the Invoke direct methods on a device should be updated for a module identity, also.
Beside that, there are missing a document for current preview related to the device streams, something similar to the document for invoking direct methods with a name like Invoking direct streaming on a device (module). IMO, the concept of the device/module streaming is based on the invoking direct method pattern on device/module, where the both sides (invoker and device/module) received an url and auth metadata of the common streaming bridge endpoint.
Thanks
Roman

Hi Antonio & Reza,
Any progress on the issue of the concurrency for active multiple modules within the device?
Thanks
Roman

Hi Antonio & Reza,
Thanks for fixing this issue of the concurrency for active multiple modules within the device. It looks like this problem has been resolved.
Thanks again
Roman

@romankiss, this issue should now be resolved. Please let me know if you still have any issue regarding module/device connections. Thanks!

@rezasherafat, I have tested (included also for new streams feature) and it works with device and multiple modules.
Thanks
Roman


[WIP] New Arch: SFU node

Description
the sfu node is a core sfu service in the new arch, which support 1:N broadcasting and high performance
Motivation
We changed ion's arch, which split ion to biz (focus on biz and signal layer) and sfu (focus on rtc layer)
Make biz and sfu both support autoscale :)
Reference issue
Fixes #37

merged to #38


Add instructions for Edge

Closes https://github.com/sindresorhus/refined-github/issues/1914

We can’t guarantee that it works on Edge, so unless actual instructions are needed, I wouldn’t say anything. I guess Edge users will know to just use the Chrome version.


update api sundials32

Preliminary PR to move the API to the new binary and enable SuperLUMT. I will start working on it by pieces, the PR is to keep track.

Clang.jl is under revamp. It's highly recommended to update the script to use Clang.jl master. Feel free to ping me if you have any questions.


Question, are you no longer doing library management?

I'm concerned that the update frequency is unreasonable.

Hey @jihoon8730 I'll direct you to a previous comment I made about maintaining this lib here
Status is mostly unchanged since then. I try to pick this up and work on it from time to time but I still just don't have the bandwidth these days


Automatically create a Nixpkgs PR when a new release is published

When an automated release happens using the release.yml workflow, it would be really neat if it also created a PR against Nixpkgs to update its pinned version.
The automated update PR workflow can be used as a reference for how to do that.
It will be tricky to test this though.

It currently takes about 10 minutes to run this action (not critical because it's not run in PRs), but it would be better to avoid that. I opened https://github.com/peter-evans/create-pull-request/issues/2847 for this


Add kubernetes-version flag to images subcommands

What this PR does / why we need it:
If the cluster the user wants to get images for is not available
at the time (preparing images ahead of time, for a coworker, etc)
then the user needs a way to specify the version rather than relying
on the autodetection.
This change also causes the images from sonobuoy images to be printed
in a sorted order for consistency.
Which issue(s) this PR fixes
Fixes #1082
Special notes for your reviewer:
Release note:
Adds a kubernetes-version flag to the images subcommands to allow manual specification instead of auto-detection of cluster version.

Thanks for taking this on :+1:


Is there a way to rename a engine/domain?

I am able to rename directories and engine is started using new name, but when I do GET /domains I still see the old one. Is there some reference on DB ?

There is only one engine on a given port. If you ask for "/domains" on this port, you're getting it's content. Suppose you have an engine named EngineA containing domains Europarl and MultiUN. Renaming this engine to EngineB won't change the fact that it's domains are still Europarl and MultiUN.

Hi @rptl
just like @EtienneAb3d said, renaming an engine does just that: renames the engine. It doesn't rename any of the domains, nor it changes the ports the engine runs on.
Not quite sure what you want to do, so here's some tips:

If you want to run an engine on different ports, or you want to run multiple engines on the same machine, this is how you can do that: How to - run multiple engines on the same machine
If you want to just rename an engine, so that it changes its name in the mmt start,  mmt stop, mmt status and so on, you can (1)  stop the engine and (2) rename the folder inside MMT/engines.
If you want to rename a single domain (i.e. "Europarl" into "European Parliament") unfortunately this is not available right now, but if you find it useful we can implement such feature.

If I could not understand what is your actual need, or if you have any doubts about the translation process and/or the architecture, please don't hesitate to ask it here.
Thanks!

Hey @davidecaroselli, thanks.
My ask was about how to rename a single domain. To be honest, I don't think it will be used often, I just wanted to adjust a typo on my current domain name.

@rptl got it!
I will work on this API in the next days; I'm going to push the code in the master branch asap.
Thanks for your patience.

Hi @rptl
the new API and command is available in the latest commit () of master branch. You can update your distribution rebuilding it from source, here's the instructions: Installing from source code.
You can now use the mmt rename command like this:
./mmt rename "europarl" "NewName"

Or you can use directly the API Update Domain like this:
curl -X PUT http://localhost:8045/domains/1?name=NewName | python -mjson.tool

{
    "data": {
        "id": 1,
        "name": "NewName"
    },
    "status": 200
}

Thanks for your support, we are closing the issue right now but if you have any other questions please don't hesitate to re-open it!

Thank you so much to take your time to create it. Really appreciated.
On Aug 30, 2017 07:49, "Davide Caroselli"<EMAIL_ADDRESS>wrote:

Closed #269 https://github.com/ModernMT/MMT/issues/269 via 3dbccc4
https://github.com/ModernMT/MMT/commit/3dbccc4ef8e8b4647d37f6bc53907bb749c85a49
.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/ModernMT/MMT/issues/269#event-1227362911, or mute
the thread
https://github.com/notifications/unsubscribe-auth/AEQOBddXi9v-qk30iLvOroLGdK-ztRZfks5sdT5IgaJpZM4PFMJK
.


Create benchmark test

First we need to define some minimal SensorThings benchmark test.
. Define Pre test requests (setup the database + initial filling)
. Define  test requests
. Define benchmark statistics (like request per second)
ideally also define hardware for server (could be added later on)

minimal test scenario:
. Pre test: Create 1 datastream + 1 observation
. Test request: Retrieve observation (like http://localhost/v1.0/Observations(0))
. Statistics: Measure RPS

another test:
. send a batch of http post to Observations

Maybe useful for stress-test, my JMeter-Docker: https://github.com/justb4/docker-jmeter

todo for future milestone


[Bug]: Query method with IN predicate returns empty results

What happened?
I try build query with IN predicate but return empty results.
Repro steps
Build a List String with the values to be filtered.
Pass a List with join(",") to get concatenated values as a single string.
Build a predicate with IN using query method and pass as parameter list
Version
realm 0.8.0+rc -> flutter  3.3.10
What Realm SDK flavor are you using?
Local Database only
What type of application is this?
Flutter Application
Client OS and version
Windows 11
Code snippets
Model:

Implementation:

Alternative (that works):

Stacktrace of the exception/crash you're getting
No response
Relevant log output
No response

Hi @M4UTR0NI1C , I would try building the query string outside of the realm.query in the implementation example that does not work.

@M4UTR0NI1C This is related to: https://github.com/realm/realm-dart/issues/755. As you noticed it works if you flatten all arguments into the query.
Actually you only need to flatten the first list argument, so:
final fullPredicate = 'estatus IN {$inPredicate} AND producto.rol == $0 AND cuenta.historica == $1 SORT(fechaCreacion DESC)';
realm.query(fullPredicate, [userRole, false]);

should work as well.
This is a bug/missing feature in the SDK and will be fixed, it should be possbile to write:
final fullPredicate = 'estatus IN $0 AND producto.rol == $1 AND cuenta.historica == $2 SORT(fechaCreacion DESC)';
realm.query(fullPredicate, [estatus, userRole, false]);

but alas we are not quite there yet

@nielsenko thank you for your answer, I proceed to close this issue. Regards.

I'll keep this open until it is fixed

Query list arguments and IN-operator are now supported in Realm SDK 1.4.0


Update the sample code for supervisord

Proposed changes

According to documentation in http://supervisord.org/configuration.html Supervisord doesn't look at /etc/supervisor/conf.d/supervisord.conf therefore I proposed to change the sample code as this code can throw error.
Unreleased project version (optional)

Related issues (optional)

Deploy preview for docsdocker ready!
Built with commit 8b49bb452868b3f759dbeb4d57cb4cf0dfe6843c
https://deploy-preview-9551--docsdocker.netlify.com


Kafka 10629 - TopologyTestDriver should not require a Properties argument

KIP-680: TopologyTestDriver should not require a Properties argument.
https://cwiki.apache.org/confluence/display/KAFKA/KIP-680%3A+TopologyTestDriver+should+not+require+a+Properties+argument
Jira for the KIP:
https://issues.apache.org/jira/browse/KAFKA-10629

Committer Checklist (excluded from commit message)

[ ] Verify design and implementation
[ ] Verify test coverage and CI build status
[ ] Verify documentation (including upgrade notes)

Thanks for the KIP and PR @rohitrmd!

@rohitrmd Seems we forgot to update the docs with this PR, in particular streams/upgarde_guide.html and maybe also the section about testing? Would you like to do a follow up PR to close this gap?

@rohitrmd Seems we forgot to update the docs with this PR, in particular streams/upgarde_guide.html and maybe also the section about testing? Would you like to do a follow up PR to close this gap?

Follow up PR to update the docs: https://github.com/apache/kafka/pull/10048


[FLOC-1934] First (untested) attempt at giving a no-pull option

Fixes https://clusterhq.atlassian.net/browse/FLOC-1934

♥


common parent latrunculin  terms

sensitive to latrunculin A (FYPO:0000107) [single locus genotypes] [details]
sensitive to latrunculin B (FYPO:0002526) [single locus genotypes]
could we add
sensitive to latrunculin as a parent since there is overlap  in the profiles.

Hmm, there isn't a plain "latrunculin" in ChEBI. The name refers to being isolated from "the Red Sea sponge Latrunculia magnifica" rather than to any aspect of the chemistry. So I guess it's OK for search friendliness, but I'll mark it as not for direct annotation and it won't have a logical def.

Oh wow. Another option might be to group as "cytoskeleton damaging agents" (similar to the DNA damaging agents term)

ChEBI has a "role" class for "actin polymerisation inhibitor" -- want one based on that?
https://www.ebi.ac.uk/chebi/chebiOntology.do?chebiId=70728

That'll do it!

sensitive to actin polymerization inhibitor FYPO:0007868


Regex language

This PR adds a Regex language based on the JavaScript Regex syntax.
Edit: It now supports most of the regex syntax of C# and Java.
This is based on #1468 with a few improvements.
Also, I'm thinking about editing the themes to show the results.

Thank you so much for this. I believe Prism is the only mainstream syntax highlighter with regex highlighting.

Also, I'm thinking about editing the themes to show the results.

I'm assuming you didn't get around to doing this yet. Meanwhile, I'm using a stylesheet I wrote with colours lifted from RegExr for anyone looking for that.

I'm assuming you didn't get around to doing this yet.

Thanks for reminding me. I completely forgot about this.
However, I won't change the themes for this as there are quite a few to change. I'll add a few aliases to given them reasonable highlighting which hopefully will look reasonably good in all themes.


Allow multiple file uploads in art gallery

How to check if it's working:

Log in as admin (/admin-panel url)
Click on edit button on any existing street code
Scroll down to Art gallery
Click + button -> modal with file provider will open
Select multiple files and click OK
ALL this files will appear in art gallery
When you click "зберегти як чернетку" page will reload and you will see your uploaded images in art gallery block.

If you can not select multiple file in modal notify me please

Does not work. Did you tested in a proper way?

Add one art:

Add group of arts per ones:

Result:

deleting is broken.

Thanks, I will fix it