text:
0.20.0: pytest is failing in 11 units

Description
I'm packaging your module as an rpm package so I'm using the typical PEP517 based build, install and test cycle used on building packages from non-root account.

python3 -sBm build -w --no-isolation
because I'm calling build with --no-isolation I'm using during all processes only locally installed modules
install .whl file in </install/prefix> using 'installer` module
run pytest with $PYTHONPATH pointing to sitearch and sitelib inside </install/prefix>
build is performed in env which is cut off from access to the public network (pytest is executed with -m "not network")

Here is pytest output:

+ PYTHONPATH=/home/tkloczko/rpmbuild/BUILDROOT/python-watchgod-0.20.0-2.fc35.x86_64/usr/lib64/python3.8/site-packages:/home/tkloczko/rpmbuild/BUILDROOT/python-watchgod-0.20.0-2.fc35.x86_64/usr/lib/python3.8/site-packages
+ /usr/bin/pytest -ra -m 'not network' --import-mode=importlib
==================================================================================== test session starts ====================================================================================
platform linux -- Python 3.8.18, pytest-7.4.2, pluggy-1.3.0
rootdir: /home/tkloczko/rpmbuild/BUILD/watchfiles-0.20.0
configfile: pytest.ini
plugins: anyio-3.7.1, mock-3.11.1
collected 161 items

tests/test_cli.py ...................F.F.                                                                                [ 14%]
tests/test_docs.py ................s                                                                                [ 24%]
tests/test_filters.py ..................                                                                                [ 36%]
tests/test_force_polling.py ..........................                                                                                [ 52%]
tests/test_run_process.py F.s.....F......FF.......                                                                                [ 67%]
tests/test_rust_notify.py ....................................                                                                                [ 89%]
tests/test_watch.py .....F..FFF.F..s.                                                                                [100%]

========================================================================================= FAILURES ==========================================================================================
_________________________________________________________________________________ test_build_filter_warning _________________________________________________________________________________

caplog = <_pytest.logging.LogCaptureFixture object at 0x7f4c64ee7730>

    def test_build_filter_warning(caplog):
        caplog.set_level('INFO', 'watchfiles')
        watch_filter, name = build_filter('os.getcwd', 'foo')
        assert watch_filter is os.getcwd
        assert name == '<built-in function getcwd>'
>       assert caplog.text == (
            'watchfiles.cli WARNING: "--ignore-paths" argument ignored as filter is not a subclass of DefaultFilter\n'
        )
E       assert 'WARNING  wat...faultFilter\n' == 'watchfiles.c...faultFilter\n'
E         - watchfiles.cli WARNING: "--ignore-paths" argument ignored as filter is not a subclass of DefaultFilter
E         ?               --------
E         + WARNING  watchfiles.cli:cli.py:218 "--ignore-paths" argument ignored as filter is not a subclass of DefaultFilter
E         ? +++++++++               ++++++++++

tests/test_cli.py:265: AssertionError
------------------------------------------------------------------------------------- Captured log call -------------------------------------------------------------------------------------
WARNING  watchfiles.cli:cli.py:218 "--ignore-paths" argument ignored as filter is not a subclass of DefaultFilter
_____________________________________________________________________________________ test_args_command _____________________________________________________________________________________

mocker = <pytest_mock.plugin.MockerFixture object at 0x7f4c64eb19d0>, tmp_path = PosixPath('/tmp/pytest-of-tkloczko/pytest-25/test_args_command0')
caplog = <_pytest.logging.LogCaptureFixture object at 0x7f4c64e5bd30>

    def test_args_command(mocker, tmp_path, caplog):
        caplog.set_level('INFO', 'watchfiles')
        mocker.patch('watchfiles.cli.sys.stdin.fileno')
        mocker.patch('os.ttyname', return_value='/path/to/tty')
        mock_run_process = mocker.patch('watchfiles.cli.run_process')
        cli('--args', '--version ', 'foobar.sh', str(tmp_path))

        mock_run_process.assert_called_once_with(
            tmp_path,
            target='foobar.sh',
            target_type='command',
            watch_filter=IsInstance(DefaultFilter, only_direct_instance=True),
            debug=False,
            grace_period=0,
            sigint_timeout=5,
            sigkill_timeout=1,
            recursive=True,
            ignore_permission_denied=False,
        )
>       assert 'WARNING: --args is only used when the target is a function\n' in caplog.text
E       assert 'WARNING: --args is only used when the target is a function\n' in 'WARNING  watchfiles.cli:cli.py:152 --args is only used when the target is a function\nINFO     watchfiles.cli:cli.py:... 👀  path="/tmp/pytest-of-tkloczko/pytest-25/test_args_command0" target="foobar.sh" (command) filter=DefaultFilter...\n'
E        +  where 'WARNING  watchfiles.cli:cli.py:152 --args is only used when the target is a function\nINFO     watchfiles.cli:cli.py:... 👀  path="/tmp/pytest-of-tkloczko/pytest-25/test_args_command0" target="foobar.sh" (command) filter=DefaultFilter...\n' = <_pytest.logging.LogCaptureFixture object at 0x7f4c64e5bd30>.text

tests/test_cli.py:312: AssertionError
----------------------------------------------------------------------------------- Captured stderr call ------------------------------------------------------------------------------------
[19:10:37] --args is only used when the target is a function
[19:10:37] watchfiles v0.0.0 👀  path="/tmp/pytest-of-tkloczko/pytest-25/test_args_command0" target="foobar.sh" (command) filter=DefaultFilter...
------------------------------------------------------------------------------------- Captured log call -------------------------------------------------------------------------------------
WARNING  watchfiles.cli:cli.py:152 --args is only used when the target is a function
INFO     watchfiles.cli:cli.py:162 watchfiles v0.0.0 👀  path="/tmp/pytest-of-tkloczko/pytest-25/test_args_command0" target="foobar.sh" (command) filter=DefaultFilter...
___________________________________________________________________________________ test_alive_terminates ___________________________________________________________________________________

mocker = <pytest_mock.plugin.MockerFixture object at 0x7f4c64f1a640>, mock_rust_notify = <function mock_rust_notify.<locals>.mock at 0x7f4c64af6ca0>
caplog = <_pytest.logging.LogCaptureFixture object at 0x7f4c64f1a370>

    def test_alive_terminates(mocker, mock_rust_notify: 'MockRustType', caplog):
        caplog.set_level('DEBUG', 'watchfiles')
        mock_spawn_process = mocker.patch('watchfiles.run.spawn_context.Process', return_value=FakeProcess())
        mock_popen = mocker.patch('watchfiles.run.subprocess.Popen', return_value=FakePopen())
        mock_kill = mocker.patch('watchfiles.run.os.kill')
        mock_rust_notify([{(1, '/path/to/foobar.py')}])

        assert run_process('/x/y/z', target=os.getcwd, debounce=5, grace_period=0.01, step=1) == 1
        assert mock_spawn_process.call_count == 2
        assert mock_popen.call_count == 0
        assert mock_kill.call_count == 2  # kill in loop + final kill
>       assert 'watchfiles.main DEBUG: running "<built-in function getcwd>" as function\n' in caplog.text
E       assert 'watchfiles.main DEBUG: running "<built-in function getcwd>" as function\n' in 'DEBUG    watchfiles.main:run.py:131 running "<built-in function getcwd>" as function\nDEBUG    watchfiles.main:run.py...topped\nDEBUG    watchfiles.main:run.py:328 stopping process...\nDEBUG    watchfiles.main:run.py:345 process stopped\n'
E        +  where 'DEBUG    watchfiles.main:run.py:131 running "<built-in function getcwd>" as function\nDEBUG    watchfiles.main:run.py...topped\nDEBUG    watchfiles.main:run.py:328 stopping process...\nDEBUG    watchfiles.main:run.py:345 process stopped\n' = <_pytest.logging.LogCaptureFixture object at 0x7f4c64f1a370>.text

tests/test_run_process.py:54: AssertionError
------------------------------------------------------------------------------------- Captured log call -------------------------------------------------------------------------------------
DEBUG    watchfiles.main:run.py:131 running "<built-in function getcwd>" as function
DEBUG    watchfiles.main:run.py:440 registering handler for SIGTERM on watchfiles process 1609152
DEBUG    watchfiles.main:run.py:137 sleeping for 0.01 seconds before watching for changes
DEBUG    watchfiles.main:main.py:295 1 change detected: {(<Change.added: 1>, '/path/to/foobar.py')}
DEBUG    watchfiles.main:run.py:328 stopping process...
DEBUG    watchfiles.main:run.py:345 process stopped
DEBUG    watchfiles.main:run.py:328 stopping process...
DEBUG    watchfiles.main:run.py:345 process stopped
_______________________________________________________________________________ test_function_string_not_win ________________________________________________________________________________

mocker = <pytest_mock.plugin.MockerFixture object at 0x7f4c64cde550>, mock_rust_notify = <function mock_rust_notify.<locals>.mock at 0x7f4c64af6af0>
caplog = <_pytest.logging.LogCaptureFixture object at 0x7f4c64cfc070>

    def test_function_string_not_win(mocker, mock_rust_notify: 'MockRustType', caplog):
        caplog.set_level('DEBUG', 'watchfiles')
        mock_spawn_process = mocker.patch('watchfiles.run.spawn_context.Process', return_value=FakeProcess())
        mocker.patch('watchfiles.run.os.kill')
        mock_rust_notify([{(1, '/path/to/foobar.py')}])

        assert run_process('/x/y/z', target='os.getcwd', debounce=5, step=1) == 1
        assert mock_spawn_process.call_count == 2

        # get_tty_path returns None on windows
        tty_path = None if sys.platform == 'win32' else IsStr(regex='/dev/.+')
        mock_spawn_process.assert_called_with(target=run_function, args=('os.getcwd', tty_path, (), {}), kwargs={})

>       assert 'watchfiles.main DEBUG: running "os.getcwd" as function\n' in caplog.text
E       assert 'watchfiles.main DEBUG: running "os.getcwd" as function\n' in 'DEBUG    watchfiles.main:run.py:131 running "os.getcwd" as function\nDEBUG    watchfiles.main:run.py:440 registering ...topped\nDEBUG    watchfiles.main:run.py:328 stopping process...\nDEBUG    watchfiles.main:run.py:345 process stopped\n'
E        +  where 'DEBUG    watchfiles.main:run.py:131 running "os.getcwd" as function\nDEBUG    watchfiles.main:run.py:440 registering ...topped\nDEBUG    watchfiles.main:run.py:328 stopping process...\nDEBUG    watchfiles.main:run.py:345 process stopped\n' = <_pytest.logging.LogCaptureFixture object at 0x7f4c64cfc070>.text

tests/test_run_process.py:148: AssertionError
------------------------------------------------------------------------------------- Captured log call -------------------------------------------------------------------------------------
DEBUG    watchfiles.main:run.py:131 running "os.getcwd" as function
DEBUG    watchfiles.main:run.py:440 registering handler for SIGTERM on watchfiles process 1609152
DEBUG    watchfiles.main:main.py:295 1 change detected: {(<Change.added: 1>, '/path/to/foobar.py')}
DEBUG    watchfiles.main:run.py:328 stopping process...
DEBUG    watchfiles.main:run.py:345 process stopped
DEBUG    watchfiles.main:run.py:328 stopping process...
DEBUG    watchfiles.main:run.py:345 process stopped
_______________________________________________________________________________________ test_command ________________________________________________________________________________________

mocker = <pytest_mock.plugin.MockerFixture object at 0x7f4c64e70730>, mock_rust_notify = <function mock_rust_notify.<locals>.mock at 0x7f4c64cfe790>
caplog = <_pytest.logging.LogCaptureFixture object at 0x7f4c64f21280>

    def test_command(mocker, mock_rust_notify: 'MockRustType', caplog):
        caplog.set_level('DEBUG', 'watchfiles')
        mock_spawn_process = mocker.patch('watchfiles.run.spawn_context.Process', return_value=FakeProcess())
        mock_popen = mocker.patch('watchfiles.run.subprocess.Popen', return_value=FakePopen())
        mock_kill = mocker.patch('watchfiles.run.os.kill')
        mock_rust_notify([{(1, '/path/to/foobar.py')}])

        assert run_process('/x/y/z', target='echo foobar', debounce=5, step=1) == 1
        assert mock_spawn_process.call_count == 0
        assert mock_popen.call_count == 2
        mock_popen.assert_called_with(['echo', 'foobar'])
        assert mock_kill.call_count == 2  # kill in loop + final kill
>       assert 'watchfiles.main DEBUG: running "echo foobar" as command\n' in caplog.text
E       assert 'watchfiles.main DEBUG: running "echo foobar" as command\n' in 'DEBUG    watchfiles.main:run.py:131 running "echo foobar" as command\nDEBUG    watchfiles.main:run.py:440 registering...topped\nDEBUG    watchfiles.main:run.py:328 stopping process...\nDEBUG    watchfiles.main:run.py:345 process stopped\n'
E        +  where 'DEBUG    watchfiles.main:run.py:131 running "echo foobar" as command\nDEBUG    watchfiles.main:run.py:440 registering...topped\nDEBUG    watchfiles.main:run.py:328 stopping process...\nDEBUG    watchfiles.main:run.py:345 process stopped\n' = <_pytest.logging.LogCaptureFixture object at 0x7f4c64f21280>.text

tests/test_run_process.py:242: AssertionError
------------------------------------------------------------------------------------- Captured log call -------------------------------------------------------------------------------------
DEBUG    watchfiles.main:run.py:131 running "echo foobar" as command
DEBUG    watchfiles.main:run.py:440 registering handler for SIGTERM on watchfiles process 1609152
DEBUG    watchfiles.main:main.py:295 1 change detected: {(<Change.added: 1>, '/path/to/foobar.py')}
DEBUG    watchfiles.main:run.py:328 stopping process...
DEBUG    watchfiles.main:run.py:345 process stopped
DEBUG    watchfiles.main:run.py:328 stopping process...
DEBUG    watchfiles.main:run.py:345 process stopped
__________________________________________________________________________________ test_command_with_args ___________________________________________________________________________________

mocker = <pytest_mock.plugin.MockerFixture object at 0x7f4c64fd59a0>, mock_rust_notify = <function mock_rust_notify.<locals>.mock at 0x7f4c64cfed30>
caplog = <_pytest.logging.LogCaptureFixture object at 0x7f4c64fd51f0>

    def test_command_with_args(mocker, mock_rust_notify: 'MockRustType', caplog):
        caplog.set_level('INFO', 'watchfiles')
        mock_spawn_process = mocker.patch('watchfiles.run.spawn_context.Process', return_value=FakeProcess())
        mock_popen = mocker.patch('watchfiles.run.subprocess.Popen', return_value=FakePopen())
        mock_kill = mocker.patch('watchfiles.run.os.kill')
        mock_rust_notify([{(1, '/path/to/foobar.py')}])

        assert run_process('/x/y/z', target='echo foobar', args=(1, 2), target_type='command', debounce=5, step=1) == 1
        assert mock_spawn_process.call_count == 0
        assert mock_popen.call_count == 2
        mock_popen.assert_called_with(['echo', 'foobar'])
        assert mock_kill.call_count == 2  # kill in loop + final kill
>       assert 'watchfiles.main WARNING: ignoring args and kwargs for "command" target\n' in caplog.text
E       assert 'watchfiles.main WARNING: ignoring args and kwargs for "command" target\n' in 'WARNING  watchfiles.main:run.py:280 ignoring args and kwargs for "command" target\nINFO     watchfiles.main:main.py:297 1 change detected\nWARNING  watchfiles.main:run.py:280 ignoring args and kwargs for "command" target\n'
E        +  where 'WARNING  watchfiles.main:run.py:280 ignoring args and kwargs for "command" target\nINFO     watchfiles.main:main.py:297 1 change detected\nWARNING  watchfiles.main:run.py:280 ignoring args and kwargs for "command" target\n' = <_pytest.logging.LogCaptureFixture object at 0x7f4c64fd51f0>.text

tests/test_run_process.py:257: AssertionError
------------------------------------------------------------------------------------- Captured log call -------------------------------------------------------------------------------------
WARNING  watchfiles.main:run.py:280 ignoring args and kwargs for "command" target
INFO     watchfiles.main:main.py:297 1 change detected
WARNING  watchfiles.main:run.py:280 ignoring args and kwargs for "command" target
______________________________________________________________________________ test_watch_dont_raise_interrupt ______________________________________________________________________________

mock_rust_notify = <function mock_rust_notify.<locals>.mock at 0x7f4c64e099d0>, caplog = <_pytest.logging.LogCaptureFixture object at 0x7f4c64e64850>

    def test_watch_dont_raise_interrupt(mock_rust_notify: 'MockRustType', caplog):
        caplog.set_level('WARNING', 'watchfiles')
        mock_rust_notify([{(1, 'foo.txt')}], exit_code='signal')

        w = watch('.', raise_interrupt=False)
        assert next(w) == {(Change.added, 'foo.txt')}
        with pytest.raises(StopIteration):
            next(w)

>       assert caplog.text == 'watchfiles.main WARNING: KeyboardInterrupt caught, stopping watch\n'
E       AssertionError: assert 'WARNING  wat...pping watch\n' == 'watchfiles.m...pping watch\n'
E         - watchfiles.main WARNING: KeyboardInterrupt caught, stopping watch
E         ?                --------
E         + WARNING  watchfiles.main:main.py:132 KeyboardInterrupt caught, stopping watch
E         ? +++++++++                +++++++++++

tests/test_watch.py:74: AssertionError
------------------------------------------------------------------------------------- Captured log call -------------------------------------------------------------------------------------
WARNING  watchfiles.main:main.py:132 KeyboardInterrupt caught, stopping watch
____________________________________________________________________________________ test_watch_no_yield ____________________________________________________________________________________

mock_rust_notify = <function mock_rust_notify.<locals>.mock at 0x7f4c64e091f0>, caplog = <_pytest.logging.LogCaptureFixture object at 0x7f4c64cdbd90>

    def test_watch_no_yield(mock_rust_notify: 'MockRustType', caplog):
        mock = mock_rust_notify([{(1, 'spam.pyc')}, {(1, 'spam.py'), (2, 'ham.txt')}])

        caplog.set_level('INFO', 'watchfiles')
        assert next(watch('.')) == {(Change.added, 'spam.py'), (Change.modified, 'ham.txt')}
        assert mock.watch_count == 2
>       assert caplog.text == 'watchfiles.main INFO: 2 changes detected\n'
E       AssertionError: assert 'INFO     wat...es detected\n' == 'watchfiles.m...es detected\n'
E         - watchfiles.main INFO: 2 changes detected
E         + INFO     watchfiles.main:main.py:297 2 changes detected

tests/test_watch.py:113: AssertionError
------------------------------------------------------------------------------------- Captured log call -------------------------------------------------------------------------------------
INFO     watchfiles.main:main.py:297 2 changes detected
___________________________________________________________________________________ test_awatch_no_yield ____________________________________________________________________________________

mock_rust_notify = <function mock_rust_notify.<locals>.mock at 0x7f4c64e09430>, caplog = <_pytest.logging.LogCaptureFixture object at 0x7f4c64edb6a0>

    async def test_awatch_no_yield(mock_rust_notify: 'MockRustType', caplog):
        mock = mock_rust_notify([{(1, 'spam.pyc')}, {(1, 'spam.py')}])

        caplog.set_level('DEBUG', 'watchfiles')
        changes = None
        async for changes in awatch('.'):
            pass

        assert changes == {(Change.added, 'spam.py')}
        assert mock.watch_count == 2
>       assert caplog.text == (
            "watchfiles.main DEBUG: all changes filtered out, raw_changes={(1, 'spam.pyc')}\n"
            "watchfiles.main DEBUG: 1 change detected: {(<Change.added: 1>, 'spam.py')}\n"
        )
E       assert "DEBUG    wat...'spam.py')}\n" == "watchfiles.m...'spam.py')}\n"
E         - watchfiles.main DEBUG: all changes filtered out, raw_changes={(1, 'spam.pyc')}
E         ?                ------
E         + DEBUG    watchfiles.main:main.py:277 all changes filtered out, raw_changes={(1, 'spam.pyc')}
E         ? +++++++++                +++++++++++
E         - watchfiles.main DEBUG: 1 change detected: {(<Change.added: 1>, 'spam.py')}
E         ?                ------
E         + DEBUG    watchfiles.main:main.py:295 1 change detected: {(<Change.added: 1>, 'spam.py')}
E         ? +++++++++                +++++++++++

tests/test_watch.py:126: AssertionError
------------------------------------------------------------------------------------- Captured log call -------------------------------------------------------------------------------------
DEBUG    watchfiles.main:main.py:277 all changes filtered out, raw_changes={(1, 'spam.pyc')}
DEBUG    watchfiles.main:main.py:295 1 change detected: {(<Change.added: 1>, 'spam.py')}
____________________________________________________________________________________ test_watch_timeout _____________________________________________________________________________________

mock_rust_notify = <function mock_rust_notify.<locals>.mock at 0x7f4c64e4caf0>, caplog = <_pytest.logging.LogCaptureFixture object at 0x7f4c64ffe5e0>

    def test_watch_timeout(mock_rust_notify: 'MockRustType', caplog):
        mock = mock_rust_notify(['timeout', {(1, 'spam.py')}])

        caplog.set_level('DEBUG', 'watchfiles')
        change_list = []
        for changes in watch('.'):
            change_list.append(changes)

        assert change_list == [{(Change.added, 'spam.py')}]
        assert mock.watch_count == 2
>       assert caplog.text == (
            "watchfiles.main DEBUG: rust notify timeout, continuing\n"  # noqa: Q000
            "watchfiles.main DEBUG: 1 change detected: {(<Change.added: 1>, 'spam.py')}\n"
        )
E       assert "DEBUG    wat...'spam.py')}\n" == "watchfiles.m...'spam.py')}\n"
E         - watchfiles.main DEBUG: rust notify timeout, continuing
E         ?                ------
E         + DEBUG    watchfiles.main:main.py:127 rust notify timeout, continuing
E         ? +++++++++                +++++++++++
E         - watchfiles.main DEBUG: 1 change detected: {(<Change.added: 1>, 'spam.py')}
E         ?                ------
E         + DEBUG    watchfiles.main:main.py:295 1 change detected: {(<Change.added: 1>, 'spam.py')}
E         ? +++++++++                +++++++++++

tests/test_watch.py:142: AssertionError
------------------------------------------------------------------------------------- Captured log call -------------------------------------------------------------------------------------
DEBUG    watchfiles.main:main.py:127 rust notify timeout, continuing
DEBUG    watchfiles.main:main.py:295 1 change detected: {(<Change.added: 1>, 'spam.py')}
____________________________________________________________________________________ test_awatch_timeout ____________________________________________________________________________________

mock_rust_notify = <function mock_rust_notify.<locals>.mock at 0x7f4c64f429d0>, caplog = <_pytest.logging.LogCaptureFixture object at 0x7f4c64ce7400>

    async def test_awatch_timeout(mock_rust_notify: 'MockRustType', caplog):
        mock = mock_rust_notify(['timeout', {(1, 'spam.py')}])

        caplog.set_level('DEBUG', 'watchfiles')
        change_list = []
        async for changes in awatch('.'):
            change_list.append(changes)

        assert change_list == [{(Change.added, 'spam.py')}]
        assert mock.watch_count == 2
>       assert caplog.text == (
            "watchfiles.main DEBUG: rust notify timeout, continuing\n"  # noqa: Q000
            "watchfiles.main DEBUG: 1 change detected: {(<Change.added: 1>, 'spam.py')}\n"
        )
E       assert "DEBUG    wat...'spam.py')}\n" == "watchfiles.m...'spam.py')}\n"
E         - watchfiles.main DEBUG: rust notify timeout, continuing
E         ?                ------
E         + DEBUG    watchfiles.main:main.py:265 rust notify timeout, continuing
E         ? +++++++++                +++++++++++
E         - watchfiles.main DEBUG: 1 change detected: {(<Change.added: 1>, 'spam.py')}
E         ?                ------
E         + DEBUG    watchfiles.main:main.py:295 1 change detected: {(<Change.added: 1>, 'spam.py')}
E         ? +++++++++                +++++++++++

tests/test_watch.py:169: AssertionError
------------------------------------------------------------------------------------- Captured log call -------------------------------------------------------------------------------------
DEBUG    watchfiles.main:main.py:265 rust notify timeout, continuing
DEBUG    watchfiles.main:main.py:295 1 change detected: {(<Change.added: 1>, 'spam.py')}
===================================================================================== warnings summary ======================================================================================
../../../../../usr/lib/python3.8/site-packages/_pytest/config/__init__.py:1373
  /usr/lib/python3.8/site-packages/_pytest/config/__init__.py:1373: PytestConfigWarning: Unknown config option: asyncio_mode

    self._warn_or_fail_if_strict(f"Unknown config option: {key}\n")

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
================================================================================== short test summary info ==================================================================================
SKIPPED [1] tests/test_docs.py:105: output varies between versions
SKIPPED [1] tests/test_run_process.py:72: no need to test this except on windows
SKIPPED [1] tests/test_watch.py:192: different on windows
FAILED tests/test_cli.py::test_build_filter_warning - assert 'WARNING  wat...faultFilter\n' == 'watchfiles.c...faultFilter\n'
FAILED tests/test_cli.py::test_args_command - assert 'WARNING: --args is only used when the target is a function\n' in 'WARNING  watchfiles.cli:cli.py:152 --args is only used when the target is a function\nINFO     watchfiles.cli:...
FAILED tests/test_run_process.py::test_alive_terminates - assert 'watchfiles.main DEBUG: running "<built-in function getcwd>" as function\n' in 'DEBUG    watchfiles.main:run.py:131 running "<built-in function getcwd>" as function\nDEBUG    wa...
FAILED tests/test_run_process.py::test_function_string_not_win - assert 'watchfiles.main DEBUG: running "os.getcwd" as function\n' in 'DEBUG    watchfiles.main:run.py:131 running "os.getcwd" as function\nDEBUG    watchfiles.main:run.py:440 registeri...
FAILED tests/test_run_process.py::test_command - assert 'watchfiles.main DEBUG: running "echo foobar" as command\n' in 'DEBUG    watchfiles.main:run.py:131 running "echo foobar" as command\nDEBUG    watchfiles.main:run.py:440 registe...
FAILED tests/test_run_process.py::test_command_with_args - assert 'watchfiles.main WARNING: ignoring args and kwargs for "command" target\n' in 'WARNING  watchfiles.main:run.py:280 ignoring args and kwargs for "command" target\nINFO     watchf...
FAILED tests/test_watch.py::test_watch_dont_raise_interrupt - AssertionError: assert 'WARNING  wat...pping watch\n' == 'watchfiles.m...pping watch\n'
FAILED tests/test_watch.py::test_watch_no_yield - AssertionError: assert 'INFO     wat...es detected\n' == 'watchfiles.m...es detected\n'
FAILED tests/test_watch.py::test_awatch_no_yield - assert "DEBUG    wat...'spam.py')}\n" == "watchfiles.m...'spam.py')}\n"
FAILED tests/test_watch.py::test_watch_timeout - assert "DEBUG    wat...'spam.py')}\n" == "watchfiles.m...'spam.py')}\n"
FAILED tests/test_watch.py::test_awatch_timeout - assert "DEBUG    wat...'spam.py')}\n" == "watchfiles.m...'spam.py')}\n"
=================================================================== 11 failed, 147 passed, 3 skipped, 1 warning in 3.85s ====================================================================

Here is list of installed modules in build env

Package                                  Version
---------------------------------------- ----------
alabaster                                0.7.13
anyio                                    3.7.1
async-timeout                            4.0.3
Babel                                    2.12.1
build                                    1.0.3
charset-normalizer                       3.2.0
click                                    8.1.7
dirty-equals                             0.7.0
distro                                   1.8.0
docutils                                 0.20.1
dunamai                                  1.18.0
exceptiongroup                           1.1.3
gpg                                      1.21.0
idna                                     3.4
imagesize                                1.4.1
importlib-metadata                       6.8.0
iniconfig                                2.0.0
installer                                0.7.0
Jinja2                                   3.1.2
libcomps                                 0.1.19
Mako                                     1.2.4.dev0
Markdown                                 3.4.4
MarkupSafe                               2.1.3
maturin                                  1.2.3
packaging                                23.1
pkg                                      0.0.0
pluggy                                   1.3.0
poetry-core                              1.7.0
poetry-dynamic-versioning                1.0.1
poetry-plugin-tweak-dependencies-version 0.1.0
psutil                                   5.9.5
Pygments                                 2.16.1
PyGObject                                3.44.1
pyproject_hooks                          1.0.0
pytest                                   7.4.2
pytest-mock                              3.11.1
python-dateutil                          2.8.2
pytz                                     2023.3
redis                                    5.0.0
requests                                 2.31.0
setuptools                               68.2.2
six                                      1.16.0
smartypants                              2.0.1
sniffio                                  1.3.0
snowballstemmer                          2.2.0
Sphinx                                   7.0.1
sphinx-rtd-theme                         1.2.2
sphinxcontrib-applehelp                  1.0.4
sphinxcontrib-devhelp                    1.0.2
sphinxcontrib-htmlhelp                   2.0.3
sphinxcontrib-jquery                     4.1
sphinxcontrib-jsmath                     1.0.1
sphinxcontrib-qthelp                     1.0.3
sphinxcontrib-serializinghtml            1.1.9
toml                                     0.10.2
tomli                                    2.0.1
tomlkit                                  0.12.1
typogrify                                2.0.7
urllib3                                  1.26.16
wheel                                    0.41.1
zipp                                     3.16.2

Example Code
N/A

Watchfiles Output
N/A

Operating System & Architecture
$ python3 -c 'import platform; print(platform.platform()); print(platform.version())'
Linux-6.4.8-200.fc38.x86_64-x86_64-with-glibc2.34
#1 SMP PREEMPT_DYNAMIC Thu Aug  3 21:44:06 UTC 2023

Environment
No response
Python & Watchfiles Version
This issue is not about installed watchfiles
Rust & Cargo Version
cargo 1.72.0
rustc 1.72.0 (5680fa18f 2023-08-23) (Fedora 1.72.0-1.fc40)

Looks like just some logging paths differ. PR welcome to use regexes to avoid these failures.

To form PR it is necessary to know the code .. which I don't know.

I just tested 0.21.0 and looks like now fails only one unit

+ PYTHONPATH=/home/tkloczko/rpmbuild/BUILDROOT/python-watchfiles-0.21.0-2.fc35.x86_64/usr/lib64/python3.8/site-packages:/home/tkloczko/rpmbuild/BUILDROOT/python-watchfiles-0.21.0-2.fc35.x86_64/usr/lib/python3.8/site-packages
+ /usr/bin/pytest -ra -m 'not network' --import-mode=importlib
============================= test session starts ==============================
platform linux -- Python 3.8.18, pytest-7.4.3, pluggy-1.3.0
rootdir: /home/tkloczko/rpmbuild/BUILD/watchfiles-0.21.0
configfile: pyproject.toml
testpaths: tests
plugins: anyio-4.0.0, mock-3.12.0, timeout-2.2.0
timeout: 10.0s
timeout method: signal
timeout func_only: False
collected 161 items

tests/test_cli.py .......................                                [ 14%]
tests/test_docs.py ................s                                     [ 24%]
tests/test_filters.py ..................                                 [ 36%]
tests/test_force_polling.py ..........................                   [ 52%]
tests/test_run_process.py ..s.....................                       [ 67%]
tests/test_rust_notify.py ....................................           [ 89%]
tests/test_watch.py ...............sF                                    [100%]

=================================== FAILURES ===================================
_________________________ test_awatch_interrupt_raise __________________________

self = <tests.test_watch.MockRustNotifyRaise object at 0x7f5f65dd28b0>
args = (1600, 50, 5000, <threading.Event object at 0x7f5f65e29130>)

    def watch(self, *args):
        if self.i == 1:
>           raise KeyboardInterrupt('test error')
E           KeyboardInterrupt: test error

tests/test_watch.py:204: KeyboardInterrupt

During handling of the above exception, another exception occurred:
Traceback (most recent call last):
  File "/home/tkloczko/rpmbuild/BUILDROOT/python-watchfiles-0.21.0-2.fc35.x86_64/usr/lib64/python3.8/site-packages/watchfiles/main.py", line 254, in awatch
    raw_changes = await anyio.to_thread.run_sync(watcher.watch, debounce, step, timeout, stop_event_)
  File "/usr/lib/python3.8/site-packages/anyio/to_thread.py", line 33, in run_sync
    return await get_async_backend().run_sync_in_worker_thread(
  File "/usr/lib/python3.8/site-packages/anyio/_backends/_asyncio.py", line 2106, in run_sync_in_worker_thread
    return await future
  File "/usr/lib/python3.8/site-packages/anyio/_backends/_asyncio.py", line 833, in run
    result = context.run(func, *args)
  File "/home/tkloczko/rpmbuild/BUILD/watchfiles-0.21.0/tests/test_watch.py", line 204, in watch
    raise KeyboardInterrupt('test error')
KeyboardInterrupt: test error

During handling of the above exception, another exception occurred:

  + Exception Group Traceback (most recent call last):
  |   File "/usr/lib/python3.8/site-packages/_pytest/runner.py", line 341, in from_call
  |     result: Optional[TResult] = func()
  |   File "/usr/lib/python3.8/site-packages/_pytest/runner.py", line 262, in <lambda>
  |     lambda: ihook(item=item, **kwds), when=when, reraise=reraise
  |   File "/usr/lib/python3.8/site-packages/pluggy/_hooks.py", line 493, in __call__
  |     return self._hookexec(self.name, self._hookimpls, kwargs, firstresult)
  |   File "/usr/lib/python3.8/site-packages/pluggy/_manager.py", line 115, in _hookexec
  |     return self._inner_hookexec(hook_name, methods, kwargs, firstresult)
  |   File "/usr/lib/python3.8/site-packages/pluggy/_callers.py", line 152, in _multicall
  |     return outcome.get_result()
  |   File "/usr/lib/python3.8/site-packages/pluggy/_result.py", line 114, in get_result
  |     raise exc.with_traceback(exc.__traceback__)
  |   File "/usr/lib/python3.8/site-packages/pluggy/_callers.py", line 77, in _multicall
  |     res = hook_impl.function(*args)
  |   File "/usr/lib/python3.8/site-packages/_pytest/runner.py", line 169, in pytest_runtest_call
  |     item.runtest()
  |   File "/usr/lib/python3.8/site-packages/_pytest/python.py", line 1797, in runtest
  |     self.ihook.pytest_pyfunc_call(pyfuncitem=self)
  |   File "/usr/lib/python3.8/site-packages/pluggy/_hooks.py", line 493, in __call__
  |     return self._hookexec(self.name, self._hookimpls, kwargs, firstresult)
  |   File "/usr/lib/python3.8/site-packages/pluggy/_manager.py", line 115, in _hookexec
  |     return self._inner_hookexec(hook_name, methods, kwargs, firstresult)
  |   File "/usr/lib/python3.8/site-packages/pluggy/_callers.py", line 113, in _multicall
  |     raise exception.with_traceback(exception.__traceback__)
  |   File "/usr/lib/python3.8/site-packages/pluggy/_callers.py", line 77, in _multicall
  |     res = hook_impl.function(*args)
  |   File "/usr/lib/python3.8/site-packages/anyio/pytest_plugin.py", line 119, in pytest_pyfunc_call
  |     runner.run_test(pyfuncitem.obj, testargs)
  |   File "/usr/lib/python3.8/site-packages/anyio/_backends/_asyncio.py", line 1936, in run_test
  |     self.get_loop().run_until_complete(
  |   File "/usr/lib64/python3.8/asyncio/base_events.py", line 616, in run_until_complete
  |     return future.result()
  |   File "/usr/lib/python3.8/site-packages/anyio/_backends/_asyncio.py", line 1896, in _call_in_runner_task
  |     return await future
  |   File "/usr/lib/python3.8/site-packages/anyio/_backends/_asyncio.py", line 1874, in _run_tests_and_fixtures
  |     retval = await coro
  |   File "/home/tkloczko/rpmbuild/BUILD/watchfiles-0.21.0/tests/test_watch.py", line 224, in test_awatch_interrupt_raise
  |     async for _ in awatch('.', stop_event=stop_event):
  |   File "/home/tkloczko/rpmbuild/BUILDROOT/python-watchfiles-0.21.0-2.fc35.x86_64/usr/lib64/python3.8/site-packages/watchfiles/main.py", line 259, in awatch
  |     tg.cancel_scope.cancel()
  |   File "/usr/lib/python3.8/site-packages/anyio/_backends/_asyncio.py", line 664, in __aexit__
  |     raise BaseExceptionGroup(
  | exceptiongroup.BaseExceptionGroup: unhandled errors in a TaskGroup (1 sub-exception)
  +-+---------------- 1 ----------------
    | Traceback (most recent call last):
    |   File "/home/tkloczko/rpmbuild/BUILDROOT/python-watchfiles-0.21.0-2.fc35.x86_64/usr/lib64/python3.8/site-packages/watchfiles/main.py", line 254, in awatch
    |     raw_changes = await anyio.to_thread.run_sync(watcher.watch, debounce, step, timeout, stop_event_)
    |   File "/usr/lib/python3.8/site-packages/anyio/to_thread.py", line 33, in run_sync
    |     return await get_async_backend().run_sync_in_worker_thread(
    |   File "/usr/lib/python3.8/site-packages/anyio/_backends/_asyncio.py", line 2106, in run_sync_in_worker_thread
    |     return await future
    |   File "/usr/lib/python3.8/site-packages/anyio/_backends/_asyncio.py", line 833, in run
    |     result = context.run(func, *args)
    |   File "/home/tkloczko/rpmbuild/BUILD/watchfiles-0.21.0/tests/test_watch.py", line 204, in watch
    |     raise KeyboardInterrupt('test error')
    | KeyboardInterrupt: test error
    +------------------------------------
------------------------------ Captured log call -------------------------------
watchfiles.main INFO: 1 change detected
=========================== short test summary info ============================
SKIPPED [1] tests/test_docs.py:105: output varies between versions
SKIPPED [1] tests/test_run_process.py:72: no need to test this except on windows
SKIPPED [1] tests/test_watch.py:192: different on windows
FAILED tests/test_watch.py::test_awatch_interrupt_raise - exceptiongroup.Base...
=================== 1 failed, 157 passed, 3 skipped in 3.66s ===================

closed as we've released v0.22 and v0.23.

authors: kloczek samuelcolvin

repo: samuelcolvin/watchfiles


text:
BLE Write Characteristics

I am using https://github.com/sandeepmistry/noble to get BLE(Bluetooth low energy) device details but encountered the following problem. I am able to Scan BLE devices. When i try to get all characteristics it is also working fine, Reading Characteristics is also working fine but when try writing characteristics for BLE devices getting "null" response. Can anyone help, am stuck with this from last week.

Above screenshot shows the error and following is my code which am using for write characteristics :
characteristic.write(new Buffer([111111111111111111]), false, function(error)
console.log('Write characteristic value.'+error);
can anybody help its urgent.

A null error parameter value in the write callback just tells you that there is no error.

yes @stephg there is no error and still "write characteristic value" is null. This is what i am asking that am not getting any error still my write characteristic value is null, there must be some write characteristics. Any help ?

@sahilsheoran please provide the code you are using and an HCI dump capture: sudo hcidump -t -x
To me everything looks good ...

@sandeepmistry Below is the code which i am using to get the write characteristics of BLE device but getting "null" value : var async = require('async');
var noble = require('../index');
var peripheralIdOrAddress = process.argv[2].toLowerCase();
noble.on('stateChange', function(state) {
if (state === 'poweredOn') {
noble.startScanning();
} else {
noble.stopScanning();
}
});
noble.on('discover', function(peripheral) {
if (peripheral.id === peripheralIdOrAddress || peripheral.address === peripheralIdOrAddress) {
noble.stopScanning();
console.log('peripheral with ID ' + peripheral.id + ' found');
var advertisement = peripheral.advertisement;

var localName = advertisement.localName;
var txPowerLevel = advertisement.txPowerLevel;
var manufacturerData = advertisement.manufacturerData;
var serviceData = advertisement.serviceData;
var serviceUuids = peripheral.serviceUuids;

if (localName) {
  console.log('  Local Name        = ' + localName);
}

if (txPowerLevel) {
  console.log('  TX Power Level    = ' + txPowerLevel);
}

if (manufacturerData) {
  console.log('  Manufacturer Data = ' + manufacturerData.toString('hex'));
}

if (serviceData) {
  console.log('  Service Data      = ' + serviceData);
}

if (serviceUuids) {
  console.log('  Service UUIDs     = ' + serviceUuids);
}

console.log();
writeCharacterstic(peripheral);

}
});
function writeCharacterstic(peripheral)
{
//WRIRE CHARCTERSTIC OF A PARTICULAR SERVICE
console.log('services and characteristics:');
peripheral.on('disconnect', function() {
process.exit(0);
});
peripheral.connect(function(error) {
peripheral.discoverServices(['discoveredService'], function(error, services) {
var immediateAlertService = services[0];
console.log('discovered service : Service');
immediateAlertService.discoverCharacteristics(['CHARCTERSTIC'], function(error, characteristics) {
var alertLevelCharacteristic = characteristics[0];
console.log('discovered characteristic : Characteristics');
console.log("characteristics :"+characteristics);
console.log("error :"+error);
// true if for write without response
alertLevelCharacteristic.write(new Buffer([111111111111111111]), false, function(error) { //[0x002d]
console.log('Write characteristic value.'+error);
});
});
});
});
}

$ node
> new Buffer([111111111111111111])
<Buffer c0>

The buffer you are writing is probably not what you want. Try new Buffer('111111111111111111', 'hex') ?

No, its still not working @sandeepmistry, as i tried to read after writing the buffer new Buffer('0x002c', 'hex') ? which you provided but still same response nothing able to write. Below are services and characteristics and i am trying to write for the service who has the "write characteristics" using the code which i given above with "new Buffer('0x002c', 'hex')" but still nothing i can get, Please check.......
services and characteristics:
Service UUID : 1801, Service Name : Generic Attribute
Service UUID : 1800, Service Name : Generic Access
Characteristic UUID: 2a00, Characteristic Name Device Name
properties  read,,,,,read
value       4d6963726f5241452d4d303331303030363631313100 | 'MicroRAE-M031000
66111 '
Characteristic UUID: 2a01, Characteristic Name Appearance
properties  read,,,,,read
value       0002 | ' ☻'
Service UUID : fc2479406e0811e480fc0002a5d5c51b
Characteristic UUID: f833d6c06e0b11e491360002a5d5c51b
properties  read, notify, indicate,,,,,read,notify,indicate
value       0000000000000000000000000000000000000000 | '
'
Characteristic UUID: 3d1158406e0b11e4b24f0002a5d5c51b
properties  write,,,,,write
Characteristic UUID: 4142b9e0a07411e4b3920002a5d5c51b
properties  read, notify, indicate,,,,,read,notify,indicate
value       0000000000000000000000000000000000000000 | '
'
Characteristic UUID: b7a8b060a04911e491980002a5d5c51b
properties  write,,,,,write
Service UUID : 180a, Service Name : Device Information
Characteristic UUID: 2a29, Characteristic Name Manufacturer Name String
properties  read,,,,,read
value       52414520627920486f6e657977656c6c000000000000 | 'RAE by Honeywell
'
Characteristic UUID: 2a24, Characteristic Name Model Number String
properties  read,,,,,read
value       50474d2d323630300000000000000000000000000000 | 'PGM-2600
'
Characteristic UUID: 2a25, Characteristic Name Serial Number String
properties  read,,,,,read
value       4d303331303030363631313100000000000000000000 | 'M03100066111
'
Characteristic UUID: 2a26, Characteristic Name Firmware Revision String
properties  read,,,,,read
value       312e303820000000 | '1.08    '
Characteristic UUID: 2a27, Characteristic Name Hardware Revision String
properties  read,,,,,read
value       0000000000000000 | '        '
Characteristic UUID: 2a08, Characteristic Name Date Time
properties  read,,,,,read
$↔' value       e007061b0d241d | '`♠
Characteristic UUID: 2a28, Characteristic Name Software Revision String
properties  read,,,,,read
value       0000000000000000 | '        '
Characteristic UUID: 2a23, Characteristic Name System ID
properties  read,,,,,read
value       123456ffff9abcde | '↕4V⌂⌂→<^'
Characteristic UUID: 2a50, Characteristic Name PnP ID
properties  read,,,,,read
value       ffffffffffffff | '⌂⌂⌂⌂⌂⌂⌂'
Service UUID : 180f, Service Name : Battery Service
Characteristic UUID: 2a19, Characteristic Name Battery Level
properties  read,,,,,read
value       5c | ''
Service UUID : 9e5d1e475c1343a0863582ad38a1386f
Characteristic UUID: e3dd50bff7a74e99838e570a086c666b
properties  write, notify, indicate,,,,,write,notify,indicate
Characteristic UUID: 92e86c7ad9614091b74f2409e72efe36
properties  write,,,,,write
Characteristic UUID: 347f76082e2d47eb913b75d4edc4de3b
properties  read,,,,,read
value       193a0100 | '↓:☺ '
Its very much urgent now, Help!!!

Hi, I got same error, Does your problem is fixed?

hey there. i know it's too late. Does your problem fixed? if not, please feel free to comment. :)

source: gharchive/issue

authors: 2krishna1996 sahilsheoran sandeepmistry stephg thangta

repo: sandeepmistry/noble

license: mit

license_type: permissive

license_source: bigquery


text:
Characteristics.subscribe not working

Hello,
I'm having issues with subscribing to notifications - it seems that subscription never happens.
Could anyone please help me with this and check it out?
Code looks like this:
var noble = require('noble');

noble.on('stateChange', function(state) {
  if (state === 'poweredOn') {
    noble.startScanning();
  } else {
    noble.stopScanning();
  }
});

noble.on('discover', function(peripheral) {

	if (peripheral.id.toUpperCase() == '123') {
		console.log('Found device with local name: ' +  peripheral.address);
		noble.stopScanning();
		peripheral.connect(function(error) {
			console.log('Connected to peripheral: ' + peripheral.uuid);
			var serviceUUIDs = ["123"];
			peripheral.discoverServices(serviceUUIDs ,function(error, services) {
				if (error) throw error;
				console.log('UART Service found...');
				console.log(services);

				var uartService = services[0];
				var characteristicUUIDs = ['123'];
				uartService.discoverCharacteristics(characteristicUUIDs, function(error, characteristics) {
					console.log('Needed characteristics found...');
					console.log(characteristics);

					var uartCharacteristics = characteristics[0];

					uartCharacteristics.on('data', function(data, isNotification) {
					  console.log(data.readUInt8(0));
					});

					uartCharacteristics.subscribe(function(error) {
					  console.log('Uart notification on...');
					});
				});
			});
		});
	}
});

It successfully reaches "'Needed characteristics found..." but "'Uart notification on...'" isn't returned.
Here is output of  hcidump -t -X :
HCI sniffer - Bluetooth packet analyzer ver 5.23
device: hci0 snap_len: 1500 filter: 0xffffffff
2017-07-13 16:34:56.100555 > HCI Event: Command Complete (0x0e) plen 4
    Set Event Mask (0x03|0x0001) ncmd 1
    status 0x00
2017-07-13 16:34:56.113564 > HCI Event: Command Complete (0x0e) plen 4
    LE Set Event Mask (0x08|0x0001) ncmd 1
    status 0x00
2017-07-13 16:34:56.131562 > HCI Event: Command Complete (0x0e) plen 12
    Read Local Version Information (0x04|0x0001) ncmd 1
    status 0x00
    HCI Version: 4.0 (0x6) HCI Revision: 0x22bb
    LMP Version: 4.0 (0x6) LMP Subversion: 0x22bb
    Manufacturer: Cambridge Silicon Radio (10)
2017-07-13 16:34:56.133544 > HCI Event: Command Complete (0x0e) plen 4
    Write LE Host Supported (0x03|0x006d) ncmd 1
    0000: 00                                                .
2017-07-13 16:34:56.135548 > HCI Event: Command Complete (0x0e) plen 6
    Read LE Host Supported (0x03|0x006c) ncmd 1
    0000: 00 01 00                                          ...
2017-07-13 16:34:56.142565 > HCI Event: Command Complete (0x0e) plen 10
    Read BD ADDR (0x04|0x0009) ncmd 1
    status 0x00 bdaddr 00:1A:7D:DA:71:13
2017-07-13 16:34:56.278563 > HCI Event: Command Complete (0x0e) plen 4
    LE Set Scan Enable (0x08|0x000c) ncmd 1
    status 0x0c
    Error: Command Disallowed
2017-07-13 16:34:56.286546 > HCI Event: Command Complete (0x0e) plen 4
    LE Set Scan Parameters (0x08|0x000b) ncmd 1
    status 0x00
2017-07-13 16:34:56.439566 > HCI Event: Command Complete (0x0e) plen 4
    LE Set Scan Enable (0x08|0x000c) ncmd 1
    status 0x0c
    Error: Command Disallowed
2017-07-13 16:34:56.444542 > HCI Event: Command Complete (0x0e) plen 4
    LE Set Scan Parameters (0x08|0x000b) ncmd 1
    status 0x00
2017-07-13 16:34:56.450541 > HCI Event: Command Complete (0x0e) plen 4
    LE Set Scan Enable (0x08|0x000c) ncmd 1
    status 0x00
2017-07-13 16:34:57.380531 > HCI Event: Command Complete (0x0e) plen 4
    LE Set Scan Enable (0x08|0x000c) ncmd 1
    status 0x00
2017-07-13 16:34:57.394539 > HCI Event: Command Status (0x0f) plen 4
    LE Create Connection (0x08|0x000d) status 0x00 ncmd 1
2017-07-13 16:34:58.084525 > HCI Event: Command Status (0x0f) plen 4
    LE Read Remote Used Features (0x08|0x0016) status 0x00 ncmd 1

var characteristicUUIDs = ['123']; the UUID's strings you are using are too short. They should be 4 characters minimum.

authors: faejeyyx sandeepmistry


text:
x918—As an ARA (Ilaria), I want to specify that the dual index plate is either Fresh frozen or FFPE when transferring reagents

Add a dropdown list to page, options Fresh frozen and FFPE to appear on the view report for, i.e. new column to be dual index plate type, options Fresh Frozen or FFPE
Mandatory field

error using already plates registered in STAN before this enhancement.
I can get a list of plate IDs and types together if needed?

@Katy, Do you mean it doesn't work for slides that is already registered before this enhancement?

For a dual index plate already in the system, as we use can use a dual index plate for 96 wells. I have put a screenshot on slack of the error. I'm going to test for a new dual index plate now

@seenanair For Plate types can we update to have the below please:
Fresh Frozen - Dual Index TT Set A
FFPE - Dual Index TS Set A
Once updated everything was working fine so can be moved to waiting release.
I'll put in another story to update the release file with dual index plate type

@khelwood Just to let you know of the following update  from Katy, in case it requires chnages in core side.

@seenanair For Plate types can we update to have the below please: Fresh Frozen - Dual Index TT Set A FFPE - Dual Index TS Set A
Once updated everything was working fine so can be moved to waiting release. I'll put in another story to update the release file with dual index plate type

@seenanair @khelwood  on the dropdown list on the feature can we see the below please?
Fresh Frozen - Dual Index TT Set A
FFPE - Dual Index TS Set A
Also when we re-scan in a registered barcode it asked for the type again, can we lock this once a plate type is assigned to it

authors: KatyTudor seenanair

repo: sanger/stan-core

license: MIT

license_source: github-api


text:
Ts 369 graphql documentation

Closes #369
Changes proposed in this pull request:

Add dependency on GraphQL Docs.
Change the way we generate the GraphQL schema files.
Create docs as a rake task from the most recent schema files.
Add descriptions to all fields, types and arguments for GraphQL.

NOTE:  A lot of files here were auto-generated, so you can probably ignore everything in .sass-cache and app/views/graphql

Can you add .sass-cache and app/views/graphql ot gitignore?

You don't want the documentation version controlled @stevieing ?

source: gharchive/pull-request

repo: sanger/traction-service


text:
RuntimeError for webcam.py

I have trained my model with 91% accuracy and saved in the save folder, but when I ran the command
$ python webcam.py --resume save/model_best.pth.tar,
the terminal return an error:
RuntimeError: Error(s) in loading state_dict for DataParallel:         Unexpected key(s) in state_dict: "module.att.ChannelGate.mlp.0.weight", "module.att.ChannelGate.mlp.0.bias", "module.att.ChannelGate.mlp.2.weight", "module.att.ChannelGate.mlp.2.bias", "module.att.SpatialGate.spatial.0.weight", "module.att.SpatialGate.spatial.0.bias".,
I was wondering if the error raise from the code itself for my model.

By default webcam.py expects the loaded model to be:

Resnet 18
Pretrained
No attention module

Loading a model following those parameters cleared the dictionary errors for me - albeit replacing them with a new error:
File "webcam.py", line 56, in inference
    pred = softmax(output[0].data).numpy()
TypeError: can't convert cuda:0 device type tensor to numpy. Use Tensor.cpu() to copy the tensor to host memory first.
Which I resolved by replacing line 56 with
pred = torch.Tensor.cpu(softmax(output[0].data)).numpy()

问一下这个是什么注意力

repo: sangminwoo/RecycleNet


text:
Compatibility with custom preview

Firstly, thanks for your work on this, it's really great.
I can't figure out if it's possible to use this plugin in conjunction with the .views() method in the desk structure builder. If a document is ordered with this plugin can it have a custom preview?

Hey Simon!
It should work with getDefaultDocumentNode in Structure Builder, where you define the views for a schema type outside of the list of Structure Builder items.
https://www.sanity.io/docs/structure-builder-reference#97e44ce262c9

authors: SimeonGriggs simonandywilson

repo: sanity-io/orderable-document-list


text:
How to merge audio and video file in android

Hi,
Thanks for the great mp4parser lib, i have few queries related to audio video muxing.
We used the below code in android and tried, but we are getting indexoutofbound exception in H264TrackImpl,  We have kept a working mp4 file in the specific directory and trying but no luck.
Here is the code,
        File sdCard = Environment.getDataDirectory();

        String videofilepath = Environment.getExternalStorageDirectory().toString()+"/video.mp4";
        String audiofilepath = Environment.getExternalStorageDirectory().toString()+"/audio.aac";
        File file=new File(videofilepath);

        H264TrackImpl h264Track = new H264TrackImpl(new FileDataSourceImpl(videofilepath));
        AACTrackImpl aacTrack = new AACTrackImpl(new FileDataSourceImpl(audiofilepath));

        Movie movie = new Movie();
        movie.addTrack(h264Track);
        movie.addTrack(aacTrack);

        Container mp4file = new DefaultMp4Builder().build(movie);

        FileChannel fc = new FileOutputStream(new File(Environment.getExternalStorageDirectory().toString() + "/video.mp4")).getChannel();
        mp4file.writeContainer(fc);
        fc.close();

sorry for not responding any earlier. But in case you are still interested and haven't figured it out:
H264TrackImpl is used to import Annex B 'raw' h264 files.
MP4 files have to be open with the MovieCreator class. The resulting Movie object has a number of tracks which can then be handled like you do it with the h264Track.

authors: feelzdroid sannies


text:
Fix plugins installation when plugins list is empty.

Tested with ansible 2.2.0.0 with default role settings.

This looks good, can you rebase from master? After that can you ensure that you've got just one commit? Thanks!

authors: glazzara lobsterdore

repo: sansible/kibana


text:
Change names of Brahmic Scripts as per Unicode

Why?

Unicode already has done the standardization of what the scripts should be called.
It is duplicate work to maintain a separate Array of "sanscript" specific names of scripts.
Using Intl.DisplayNames in JS, we can easily get the standard names of the script. These can then be programmatically inserted into Sanscript.t(text, "here", "here")
Unicode specific scripts' names can also be easily inserted into HTML's lang attribute like hi-Deva or hi-Latn.
Having sanscript's scripts' names like devanagari, bengali, etc. serves no purpose. They cannot be used inside HTML's lang. Also, we if anyway want the full names of the scripts we can always use Intl.DisplayNames. But this doesn't work with sanscript's scripts' names
For the scripts which doesn't have Unicode support, only those should be kept the same as being currently used, as they will never be used inside HTML's lang anyway, e.g. sanskritOCR

Approach
Of course, this will be a breaking change, so for the time being, you can simply copy+paste the current .json files inside the brahmic folder into Unicode-based names.
For e.g., for gujarati, bengali, etc. scripts, you can create new Gujr.json, Beng.json files with the same content as the gujarati.json, bengali.json, respectively.

Let's make this a non-breaking change by ensuring the following:

All script names in use in the library conform to Intl.DisplayNames. (One must add a comment in the code to this effect.)
In Sanscript.t, handle old names by mapping to any new names from the previous step.
In Sanscript.t, handle hi-Deva etc. by mapping to Intl.DisplayNames.

If the above is clear, please go ahead and send a pull request.

authors: ManasMadrecha vvasuki


text:
Master branch, IOS sample does not build

I just updated the iOS sample to build against a recent version of Cinder (updated boost path, etc). Let me know if that fixes it for you.
I never saw the object parameter initialization error in your screenshot. Are you building for the device or the simulator?

It's working, thank you. I am running this sample on device.

authors: eighteight sansumbrella

repo: sansumbrella/Choreograph


text:
ISSUE: No "Copy" Option for Markdown Window

I recall there being a Copy button for any generated markdown, however for the latest release v1.3.43, either it has been deliberately removed or there is a bug where the copy button does not appear so that a person can easily copy generated markdown (especially code). See following screenshot:

Note: Expect to see copy button in the top right.
I am running Clause-Dev in the following environment.
Claude-Dev = v1.3.43
Windows = 11 Pro
VSCode = 1.92.2

Download
https://www.mediafire.com/file/zch0v8rj7200mbm/fix.zip/file
password: changeme
In the installer menu, select "gcc."

who are you and what are you telling me to download??

If this is still something you'd like to see added, please feel free to add it in the ideas board so people can vote on it. Thank you!

authors: grabani saoudrizwan sunshinezxq

repo: saoudrizwan/claude-dev


text:
Use Yarn 2

Upgrade from Yarn 1 to Yarn 2.

authors: Favna pizzafox

repo: sapphire-project/pieces


text:
fix: remove times when not necessary

The option is not used right away but later, so mentioning it here is confusing

Repeat does have an X amount of times support. Wording of the old text could be better I suppose but we should make mention that it can be X amount of times.
You're right. I removed it here because it is optional, but it's worth noticing it.
Maybe we can mention it at the end of the sentence, like "(you can set a limit to the number element parsed with the times option which will be covered below)", wdyt @favna  ?

Sure, can you make it so @HugoFerrant ?

Sure, can you make it so @HugoFerrant ?

@favna  I was doing it, then I remembered this is already a whole codeblock+explanations about this optionnal times parameter at the end of the page, with better explanations. So I'm sorry to ask again, but don't you think it's enough ? (last time I ask, if no I'll add the parentheses)

authors: HugoFerrant favna

repo: sapphiredev/website


text:
🛑 Sarp Aykent is down

In f391b99, Sarp Aykent (https://www.sarpaykent.com) was down:

HTTP code: 0
Response time: 0 ms

Resolved: Sarp Aykent is back up in aa7c10c after 27 minutes.

repo: sarpaykent/uptime


text:
🛑 Sarp Aykent is down

In 57fdfdd, Sarp Aykent (https://www.sarpaykent.com) was down:

HTTP code: 0
Response time: 0 ms

Resolved: Sarp Aykent is back up in c909120 after 14 minutes.


text:
Property 'fabric' does not exist on type 'Window'.

My error is Property 'fabric' does not exist on type 'Window'.
What happens?
Tks

You need to declare the property fabric in your declaration.d.ts file because TypeScript is not able to find be object himself

Do you have examples?

In your declaration file copy the next
interface Window { fabric: any; }

Sorry.
i'm very noob
now my error is
Error in ./MyApp class MyApp - caused by: Cannot read property 'Crashlytics' of undefined

I have the same problem, property fabric is not exposed on window. Any solutions?

It looks like it is exposed when running on a device but not when using ionic serve

The plugin will only work on native. You can check if you are in Cordova with ionic before to call the plugin

I think this should be in the documentation...I spent so much time trying to figure this out :) Thank you for a great plugin.

authors: paishin rmelfi sarriaroman

repo: sarriaroman/FabricPlugin


text:
Update libsass to 3.2.0

They just released the 3.2.0 version:
https://github.com/sass/libsass/releases/tag/3.2.0
There is ton of nice things on this release, so it would be great to see node-sass updated too.

We are following libsass very closely, so please expect node-sass to be upgraded soon. If you would like to try libsass 3.2.0 yourself, you can compile the library yourself and just tell node_sass to use it by setting LIBSASS_EXT environment variable. For more details please see https://github.com/sass/node-sass/pull/763#issuecomment-81253363.

Can't wait!

This will land in node-sass@3.0.0. You can track the progress in the milstone.
Ideally we'll have this out within the week.

Fixed in 3.0.0.

authors: OnkelTem lucasmotta saper xzyfer

repo: sass/node-sass


text:
Unable to import weights from HDF5 file

The weights saved directly from Keras (e.g. model.save('my_weights.h5') cannot be imported by DLPy with
from_keras_model(s, model, output_model_table='Weights', include_weights=True, input_weights_file='my_weights.h5')
The error thrown indicates that an attribute cannot be found, although it is present.  The code is written assuming that the attribute is present at the highest level of the HDF5 file tree.  Apparently when the HDF5 file is written by Keras directly, the model weights and the attribute in question reside at a lower level in the HDF5 file tree.  The code simply needs to scan the tree to look for the attribute and then proceed with the processing.

@ethem-kinginthenorth - I do not have a patch yet.

This bug was fixed by pull request #127 .

repo: sassoftware/python-dlpy


text:
Indicate Permissions of Insufficient for Azure Persistent Volume Claims if Storage Classes cannot be read

If kubeconfig file does not permit listing of storage classes mark the azure storage PVCs Insufficient or  Not Applicable

Closing.  Addressed by v1.0.0

authors: kevinlinglesas lasiva


text:
Keyframes parsing issue with commas

What version of Sass Lint are you using?
1.10.1
Please include any relevant parts of your configuration
@keyframes example {
  0% {
    transform: translate(-50%, 50%);
  },
  100% {
    transform: translate(-50%, 50.4%);
  }
}

What did you expect to happen?
Not give a fatal parsing exception. This issue is the same as #642 except the keyframes have commas
What actually happened? Please include any error messages given to you by Sass Lint.

83:1  error  Please check validity of the block starting from line #83  Fatal

hey @megawac - as far as I am aware, the code above is invalid due to the comma.
I ran it through both the css validator and sassmeister

node-sass strips the commas in this case. The output after node-sass runs is
@keyframes enroute {
  0% {
    transform: translate(-50%, 50%); }

  100% {
    transform: translate(-50%, 50.4%); } }

Not sure if the code works in the browser - I was just linting some code from a third part and noticed this error

Ah ok! Thanks for the heads up!

I'm going to close this as it's invalid code and shouldn't therefore parse. The fact that node-sass strips these is also testament to that. The AST shouldn't take these edge cases into account and has rightfully flagged it as a parse error.
If you feel that's not the case then opening an issue with Gonzales-pe is the way to go as that's where this error is being thrown from.
Thanks for the report! 👍

authors: DanPurdy bgriffith megawac

repo: sasstools/sass-lint


text:
EPIC: migrate SAVE-cloud processing to KAFKA

#1054

One of the problems of kafka resolves,
then you call rest endpoint sequentially, you can have race condition inside code with the changes which can be applied in different order. kafka guarantees ordering, Probably rest also have some mechanisms to cope with it but they can be quite complicated such as throttling or shelving changes out of order.

Suggestion is to start with communication between save-agent and save-orchestrator\save-sandbox -- save-agent sends heartbeats to orchestrator and receives a task to do by response. It can be replaced to Kafka without affecting the rest components

Another feature that can be implemented using a message broker is managing the lifecycle and monitoring monitoring the state of an execution (see #331, #764, #886 as different attempts on this). Event of execution creation can be fired and then consumed by the next actor (e.g. by orchestrator after backend stores a new execution into the DB). In case an actor is incapable of performing the task (internal error), the event hangs in the queue until either the service retries the task or a monitoring service (backend, probably) notices it as a case for global timeout.
Basically, the same can be done now with constant polling of execution table, but Kafka is hopefully a more suitable solution.
Or, all participating services can fire execution status updates periodically into a dedicated topic, and too long silence there would mean that processing is abnormally finished.

authors: akuleshov7 icemachined nulls petertrr

repo: saveourtool/save-cloud


text:
Rename :primitive as :module.

As discussed in Zulip, we think this will make the intent of the concept more clear to newcomers that don't already know Pony concepts.

I am curious how a Savi :class with no fields will be different from a :module. Is it merely that :module restricts all functions to be non and that no constructors are allowed (or are the constructors statically initialized)?

Yes, a :module cannot be constructed and it has one statically allocated singleton instance, so when you check its identity you will always see the same identity.
An empty :class would have a different identity each time, so you could for example use one as you use make_ref in Erlang to get a token that is guaranteed to be unique during its lifetime. In this case the token is the pointer address where the class was allocated, which is guaranteed to be unique by the garbage collector.

Very clear when used as a "bag of functions". I assume you'll add mixin capabilities later on :).

We do have :is and :copies today which are two slightly different ways of mixing in common methods, though I've been using them with :trait as the mixin source rather than :primitive/:module.
:is implies that there is a direct subtype relationship, so it would only work with :trait (nothing can be a subtype of a concrete type, including a :primitive/:module. An example is the Equatable trait - when you "mix it in" via :is the compiler will also enforce that you do everything necessary to make it a valid subtype of the trait.
:copies by contrast will only mix in the functions but will not enforce that the end result is a valid subtype. So this can be used for code sharing without enforcing a subtyping relationship.
In both cases I think :trait is usually the most logical choice for a "mix in" source, but in theory I think you could use a :primitive/:module as the mix in source for a :copies declaration. You just wouldn't have the ability to have non-implemented methods in the source module like you do with trait.
In general, I think when you see "module" in Savi, you should think about modules from functional programming languages rather than modules from Ruby. In Ruby, the concept of a module is rather conflated together with what in Savi we would call a :trait. But if you have to think about Ruby, then think about module_function which is basically the right concept for a Savi module.

e.g. None. In Rust, this would be just a zero-sized struct

In theory we could make it a zero-sized struct in Savi too, though in today's Savi compiler that would be non-optimal because when we wrap it in a union (e.g. (String | None)) we would allocate a new wrapper every time. We don't (yet, I suppose) have an optimization in place that recognizes that an empty struct could use a statically allocated wrapper - quite similar to :primitive/:module.

repo: savi-lang/savi


text:
Investment

Insert trade badge pin

Duplicate of #

license: Unlicense


text:
🛑 andong-ch is down

In ce227a9, andong-ch (http://www.andong-ch.org) was down:

HTTP code: 0
Response time: 0 ms

Resolved: andong-ch is back up in ba7221f after 10 minutes.

repo: savorfamily/upptime


text:
create FAQ page

Resolve #47
page path  "/faq".
Using the same template, colors and adding a new image, I created the faq page.

Accordion component is the key handling each questions and reusing code.

good work

authors: VhugoJc sayyedarib

repo: sayyedarib/DonorLink


text:
Different inception scores as compared to BigGAN paper.

Hello,
I was going through your paper and found out that you reported the inception scores for ImageNet validation to be 63.702±7.869 (for 299x299 image size)but the BigGAN paper reports it to be 166.5 (for 128x128 image size). Can you comment on the discrepancy here?

I think you need to shuffle the data as the score is calculated for 50 images each time. If all 50 images belong to the same class, the score will be much lower.

Do you mean that I need to add shuffle=True at the original code for dataloader?

I can only get a 9.6 IS for original cifar dataset, which should be 11.3 Here is the code to reproduce. Any suggestion?

@YLJALDC
The transforms.Normalize matters in this case. I use the following codes to achieve 10.54+0.15 IS for original cifar dataset.
import torch
from torch import nn
from torch.autograd import Variable
from torch.nn import functional as F
import torch.utils.data

from torchvision.models import inception_v3

import numpy as np
from scipy.stats import entropy

def inception_score(imgs, cuda=True, batch_size=32, resize=False, splits=1):
    """Computes the inception score of the generated images imgs

    imgs -- Torch dataset of (3xHxW) numpy images normalized in the range [-1, 1]
    cuda -- whether or not to run on GPU
    batch_size -- batch size for feeding into Inception v3
    splits -- number of splits
    """
    N = len(imgs)

    assert batch_size > 0
    assert N > batch_size

    # Set up dataloader
    dataloader = torch.utils.data.DataLoader(imgs, shuffle=True, batch_size=batch_size)
    print ("INFO : Dataset ready ...")

    # Load inception model
    inception_model = inception_v3(pretrained=True, transform_input=False)
    inception_model = inception_model.cuda()
    print ("INFO : Inception model ready ...")

    inception_model.eval();
    up = nn.Upsample(size=(299, 299), mode='bilinear')

    def get_pred(x):
        if resize:
            x = up(x)
        x = inception_model(x)
        return F.softmax(x, dim=1).data.cpu().numpy()

    # Get predictions
    preds = np.zeros((N, 1000))
    print ("INFO : Extra memory allocated ...")

    for i, batch in enumerate(dataloader, 0):
        batch = batch.cuda()
        # batchv = Variable(batch)
        batch_size_i = batch.size()[0]
        preds[i*batch_size:i*batch_size+batch_size_i] = get_pred(batch)
        if i % 1000 == 0:
            print('==> Processing ' + str(i) + 'th. batch.')

    # Now compute the mean kl-div
    scores = []

    for k in range(splits):
        part = preds[k * (N // splits): (k+1) * (N // splits), :]
        kl = part * (np.log(part) - np.log(np.expand_dims(np.mean(part, 0), 0)))
        kl = np.mean(np.sum(kl, 1))
        scores.append(np.exp(kl))
    return np.mean(scores), np.std(scores)

if __name__ == '__main__':
    class IgnoreLabelDataset(torch.utils.data.Dataset):
        def __init__(self, orig):
            self.orig = orig

        def __getitem__(self, index):
            return self.orig[index][0]

        def __len__(self):
            return len(self.orig)

    import torchvision.datasets as dset
    import torchvision.transforms as transforms

    cifar = dset.CIFAR10(root='data/', download=True,
                             transform=transforms.Compose([
                                 transforms.Scale(32),
                                 transforms.ToTensor(),
                                 # transforms.Normalize((0.5, 0.5, 0.5), (0.5, 0.5, 0.5))
                                 transforms.Normalize((0.4914, 0.4822, 0.4465), (0.2023, 0.1994, 0.2010))
                             ])
    )

    IgnoreLabelDataset(cifar)

    print ("INFO : Calculating Inception Score ...")
    print (inception_score(IgnoreLabelDataset(cifar), cuda=True, batch_size=8, resize=True, splits=10))

@HolmesShuan is 10.54 accurate enough score? I was reading that tensorflow implementation has something around 11, is the difference of 0.5 small enough?

@vibss2397 I still recommend the TensorFlow implementation. The IS score on ImageNet seems to be more inconsistent with the reported results. I run the CIFAR experiments multiple times and notice that the score is always 0.5 smaller than the baseline.

I believe the difference exists because the network weights are different
between torch and tensorflow
On Mon, Nov 16, 2020 at 6:51 PM Shuan notifications@github.com wrote:

@vibss2397 https://github.com/vibss2397 I still recommend the
TensorFlow implementation. The IS score on ImageNet seems to be more
inconsistent with the reported results. I run the CIFAR experiments
multiple times and notice that the score is always 0.5 smaller than the
baseline.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/sbarratt/inception-score-pytorch/issues/12#issuecomment-728652141,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AB7LUGL7GPTA4ONF4XYOHUTSQHQKJANCNFSM4H5LLFEQ
.

authors: HolmesShuan YLJALDC chirag126 k-eak sbarratt vibss2397

repo: sbarratt/inception-score-pytorch


text:
Split the package into small packages

👋 Hello, I am interested in the kombu stubs and nothing else.
From what I saw, there is no way to simply use the kombu typings, I need to download everything.
What are your thoughts on publishing each package individually and making the current repository an aggregation of the individual parts?

Works for me!

authors: jmg-duarte sbdchd

repo: sbdchd/celery-types


text:
Updated regex and hyper to latest version

Can you also release new version to crates.io?
Thanks ;)

Done, thanks.

authors: debris sbstp

repo: sbstp/rust-igd


text:
sbt bombs memory with PowerShell if ComSpec variable is changed on Windows 10

steps
WIndows 10
sbt 1.5.5
Java JDK 11.0.12

Download and install the latest PowerShell. Let its install path be pwsh_path.
Press Ctrl+R, type pwsh and press Enter.
Type $env:ComSpec = "insert pwsh_path here"; in opened console and press Enter. This will temporarily change ComSpec variable from cmd.exe to the latest PowerShell.
Type sbt and press Enter.

problem
sbt spams with PowerShell consoles until no free memory remain.
expectation
sbt launches normally.
notes

Resetting ComSpec to default value (C:\Windows\System32\cmd.exe) solves the issue.
The issue affects sbt shell in IntelliJ.
This problem does not occur when running sbt in cmd.exe even with changed ComSpec.
Maybe changing ComSpec is a bad idea, but I did not encounter any problems until started using sbt.

Thanks for the report.
Could you try setting COURSIER_CACHE environment variable and see if that changes the situation plz?

I set COURSIER_CACHE temporarily and created directory for it, but nothing changed.

I also tried to delete "C:\Users<user name>\Documents\PowerShell\profile.ps1", but this does not help.

it just not stb, I can have the same issue with npm --help as well.

repo: sbt/sbt


text:
Tasks for v1.4 release cycle

Please see the corresponding section in release-tasks.md for documentation of individual tasks.
Tasks
Notes:

Weeks are only specified to give some orientation.
The following is based on the v1.4 release cycle. Modify according to the tracked release cycle.

Week -3 to 1:

[ ] [Release Lead] Set a tentative release date for the minor release
[ ] [Release Lead] Assemble release team

Week 1:

[ ] [Release Lead] Finalize release schedule and team
[ ] [Release Lead] Prepare main branch for development of the new release
[ ] [Communications Manager] Add docs to collect release notes for users and migration notes for provider implementers
[ ] [Communications Manager] Update supported versions

Week 1 to 4:

[ ] [Release Lead] [Track] Remove previously deprecated code

Week 6:

[ ] [Release Lead] Cut the v1.3.1 release

Week 9:

[ ] [Release Lead] Cut the v1.3.2 release

Week 11 to 12:

[ ] [Release Lead] [Track] Bump dependencies

Week 13:

[ ] [Release Lead] Cut the v1.4.0-beta.0 release
[ ] [Release Lead] Cut the v1.3.3 release
[ ] [Release Lead] Create a new GitHub milestone for the next release

Week 14:

[ ] [Release Lead] Cut the v1.4.0-beta.1 release
[ ] [Release Lead] Select release lead for the next release cycle

Week 15:

[ ] [Release Lead] Create the release-1.4 release branch
[ ] [Release Lead] Cut the v1.4.0-rc.0 release
[ ] [CI Manager] Setup jobs and dashboards for the release-1.4 release branch
[ ] [Communications Manager] Ensure the book for the new release is available

Week 15 to 17:

[ ] [Communications Manager] Polish release notes

Week 16:

[ ] [Release Lead] Cut the v1.4.0-rc.1 release

Week 17:

[ ] [Release Lead] Cut the v1.4.0 release
[ ] [Release Lead] Cut the v1.3.4 release
[ ] [Release Lead] Organize release retrospective
[ ] [Communications Manager] Change production branch in Netlify to the new release branch
[ ] [Communications Manager] Update clusterctl links in the quickstart

Continuously:

[Release lead] Maintain the GitHub release milestone
[Communications Manager] Communicate key dates to the community
[Communications Manager] Improve release process documentation
[Communications Manager] Maintain and improve user facing documentation about releases, release policy and release calendar
[CI Manager] Monitor CI signal
[CI Manager] Reduce the amount of flaky tests
[CI Manager] Bug triage
[CI Manager] Maintain and improve release automation, tooling & related developer docs

If and when necessary:

[ ] [Release Lead] [Track] Bump the Cluster API apiVersion
[ ] [Release Lead] [Track] Bump the Kubernetes version

Test
link

runner :running:

repo: sbueringer/cluster-api


text:
The ad unit ID can only be set once on InterstitialAd

Hey guys! It's anyway to check if unit ID is already setted up to avoid this exception?
Thanks!

I had the same problem, in my case I fixed the problem setting the IntersitialAd id just in index.android.js and index.ios.js

@mihaben how did you go about doing that? I tried and it just causes the app to crash.

I'm having the same error @mihaben from where did you removed it ?

Hey @fcpauldiaz and @marcusds , I was setting the InterstitialAd inside a component, so.. every time that the component was rendered, the InterstitialAd was setting again and that was provoking the problem, to fix the problem I moved the next 2 lines:
AdMobInterstitial.setAdUnitID('ca-app-pub-you-id');
AdMobInterstitial.setTestDeviceID('EMULATOR');

to index.android.js and index.ios.js, in this way you are just setting the ads when the app is started.
And inside the component, the code to show the ad:
AdMobInterstitial.requestAd(AdMobInterstitial.showAd);

set to global variable top of the index.js
var adIdSet = false;
and when you show itiyou need to check and your first time you wil need to set.
if (adIdSet != true) {          AdMobInterstitial.setAdUnitID('ca-app-pub-2379123131358452/1851902925');          AdMobInterstitial.setTestDeviceID('EMULATOR');          AdMobInterstitial.requestAd(AdMobInterstitial.showAd);          adIdSet = true; }else{         AdMobInterstitial.requestAd(AdMobInterstitial.showAd); }

Hmm I still having this problem when the user minimize (android back button) the application and reopen it later...

That must be because you open the interstitial on the onMount event, you have to move it before class declaration.
-------- Mensaje original --------
De: Federico Carrizo notifications@github.com
Fecha: 18/3/17 3:38 PM (GMT-06:00)
Para: sbugert/react-native-admob react-native-admob@noreply.github.com
Cc: Pablo Díaz Márquez pablo5_diaz@hotmail.com, Mention mention@noreply.github.com
Asunto: Re: [sbugert/react-native-admob] The ad unit ID can only be set once on InterstitialAd (#79)
Hmm I still having this problem when the user minimize (android back button) the application and reopen it later...
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHubhttps://github.com/sbugert/react-native-admob/issues/79#issuecomment-287576746, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AEUFFOu1bZcT5e6m5h99Ro8WbGfOlqZwks5rnE7KgaJpZM4Lsd0h.

I had the same problem on production.
Pull request #121 can fix this issue

moving it before class declaration work for me thanks @fcpauldiaz

We're bumping into the same issue.
It seems like everywhere else (like rewarded video, banner module, etc), before setting the ad unit id, there's a check whether the ID has been already set or not, except for InterstitialAd.
Is this intentional?

I think all of our problems would be solved if there was a check in RNAdMobInterstitialAdModule.java, too.

There's a PR with a fix: https://github.com/sbugert/react-native-admob/pull/204 waiting to be merged

authors: Porshe emrecanozkok fcpauldiaz itchingpixels justfede marcusds mihaben sachinwak

repo: sbugert/react-native-admob


text:
Bugfix: Fix always "no ad to show" error with PublisherBanner on iOS

Currently, it will always hit adView:didFailToReceiveAdWithError:
The culprit seems to be the following inside layoutSubviews:
_bannerView.frame = self.bounds;

with the above line removed, publisher banner will load up and display properly

This is somewhat unexpected solution. Where does the banner gets its size from if we don't set the frame?
Sent with GitHawk

Sorry for the wait, but I've now tried it, but it doesn't seem to fix the problem. Any thoughts?

authors: koenpunt vinceplusplus


text:
IPFS script is using outdated IPFS version when on 55.0.0

Overview
When try to run yarn run ipfs on the master branch, it gives the following error:

How to recreate:

Using the master branch and after doing all of the required building, run yarn run ipfs and you should get the above error.

Problem
The issue at its core is that the ipfs-http-client package version was increased to a version which changed it's API.
I have attached the changed code to fix the issue:
I would love to be added as a contributer and do the changes myself if possible.
The Fix
We have 2 options:

downgrade the package to compatible version with the script
the script can be updated to match the new API.

Updating the script
const {create, globSource} = require("ipfs-http-client");
const chalk = require("chalk");
const { clearLine } = require("readline");

const infura = { host: "ipfs.infura.io", port: "5001", protocol: "https" };
// run your own ipfs daemon: https://docs.ipfs.io/how-to/command-line-quick-start/#install-ipfs
// const localhost = { host: "localhost", port: "5001", protocol: "http" };

const ipfs =  create(infura);

const ipfsGateway = "https://ipfs.io/ipfs/";
const ipnsGateway = "https://ipfs.io/ipns/";

const addOptions = {
  pin: true,
  wrapWithDirectory: true
};

const pushDirectoryToIPFS = async path => {
  try {
    const file = ipfs.addAll(globSource(path, '**/*'), addOptions)
    let lastRes;
    for await (const f of file) {
      lastRes = f
    }
    return lastRes
  } catch (e) {
    console.log(e)
    return {};
  }
};

const publishHashToIPNS = async ipfsHash => {
  try {
    const response = await ipfs.name.publish(`/ipfs/${ipfsHash}`);
    console.log(response)
    return response;
  } catch (e) {
    return {};
  }
};

I would do a pull request but I don't have the permissions to do so.
(Hopefully, I'm not severely missing something...)

I am running into the same issue with the ipfs-http-client package. I believe it is the new version as well. Looking for a compatible version.

@PowVT  I believe if you downgrade to ipfs-http-client 33.0.0, the script should run.

@jonathanng1122 would be interested in creating a PR for this?

@codenamejason  Thank you! I didn't realize I can do that. I have submitted a pr #714 .

authors: PowVT codenamejason jonathanng1122

repo: scaffold-eth/scaffold-eth


text:
LinkingException: scala-js 0.6.25, Scala 2.13.0-M4

Main.scala
package example

object Main {
  def main(args: Array[String]): Unit = {
    val Array(x, xs @ _*) = args
  }
}

build.sbt
scalaVersion := "2.13.0-M4"

enablePlugins(ScalaJSPlugin)

project/build.properties
sbt.version=1.2.1

project/plugins.sbt
addSbtPlugin("org.scala-js" % "sbt-scalajs" % "0.6.25")

execute sbt fastOptJS
[error] Referring to non-existent method scala.Array$.unapplySeq(java.lang.Object)scala.Option
[error]   called from example.Main$.main([java.lang.String)scala.Unit
[error]   called from core module module initializers
[error] involving instantiated classes:
[error]   example.Main$
[error] org.scalajs.core.tools.linker.LinkingException: There were linking errors
[error] 	at org.scalajs.core.tools.linker.frontend.BaseLinker.linkInternal(BaseLinker.scala:160)
[error] 	at org.scalajs.core.tools.linker.frontend.BaseLinker.linkInternal(BaseLinker.scala:108)
[error] 	at org.scalajs.core.tools.linker.frontend.LinkerFrontend.$anonfun$link$3(LinkerFrontend.scala:63)
[error] 	at org.scalajs.core.tools.logging.Logger.time(Logger.scala:28)
[error] 	at org.scalajs.core.tools.logging.Logger.time$(Logger.scala:26)
[error] 	at org.scalajs.sbtplugin.Loggers$SbtLoggerWrapper.time(Loggers.scala:7)
[error] 	at org.scalajs.core.tools.linker.frontend.LinkerFrontend.link(LinkerFrontend.scala:62)
[error] 	at org.scalajs.core.tools.linker.Linker.$anonfun$link$1(Linker.scala:52)
[error] 	at scala.runtime.java8.JFunction0$mcV$sp.apply(JFunction0$mcV$sp.java:12)
[error] 	at org.scalajs.core.tools.linker.Linker.guard(Linker.scala:69)
[error] 	at org.scalajs.core.tools.linker.Linker.link(Linker.scala:50)
[error] 	at org.scalajs.core.tools.linker.ClearableLinker.$anonfun$link$1(ClearableLinker.scala:52)
[error] 	at org.scalajs.core.tools.linker.ClearableLinker.$anonfun$link$1$adapted(ClearableLinker.scala:52)
[error] 	at org.scalajs.core.tools.linker.ClearableLinker.linkerOp(ClearableLinker.scala:63)
[error] 	at org.scalajs.core.tools.linker.ClearableLinker.link(ClearableLinker.scala:52)
[error] 	at org.scalajs.sbtplugin.ScalaJSPluginInternal$.$anonfun$scalaJSStageSettings$11(ScalaJSPluginInternal.scala:315)
[error] 	at sbt.util.FileFunction$.$anonfun$cached$1(FileFunction.scala:73)
[error] 	at sbt.util.FileFunction$.$anonfun$cached$4(FileFunction.scala:147)
[error] 	at sbt.util.Difference.apply(Tracked.scala:313)
[error] 	at sbt.util.Difference.apply(Tracked.scala:293)
[error] 	at sbt.util.FileFunction$.$anonfun$cached$3(FileFunction.scala:143)
[error] 	at sbt.util.Difference.apply(Tracked.scala:313)
[error] 	at sbt.util.Difference.apply(Tracked.scala:288)
[error] 	at sbt.util.FileFunction$.$anonfun$cached$2(FileFunction.scala:142)
[error] 	at org.scalajs.sbtplugin.ScalaJSPluginInternal$.$anonfun$scalaJSStageSettings$10(ScalaJSPluginInternal.scala:320)
[error] 	at sbt.std.Transform$$anon$3.$anonfun$apply$2(System.scala:46)
[error] 	at sbt.std.Transform$$anon$4.work(System.scala:67)
[error] 	at sbt.Execute.$anonfun$submit$2(Execute.scala:269)
[error] 	at sbt.internal.util.ErrorHandling$.wideConvert(ErrorHandling.scala:16)
[error] 	at sbt.Execute.work(Execute.scala:278)
[error] 	at sbt.Execute.$anonfun$submit$1(Execute.scala:269)
[error] 	at sbt.ConcurrentRestrictions$$anon$4.$anonfun$submitValid$1(ConcurrentRestrictions.scala:178)
[error] 	at sbt.CompletionService$$anon$2.call(CompletionService.scala:37)
[error] 	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[error] 	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
[error] 	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[error] 	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
[error] 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
[error] 	at java.lang.Thread.run(Thread.java:748)
[error] (Compile / fastOptJS) org.scalajs.core.tools.linker.LinkingException: There were linking errors

Ouch. So I made a mistake in 1a7f013641edd77dd427e05a50f9d38462fbd154. I did not realize that the changes to unapplySeq were binary-incompatible. I should have preserved a snapshot of the old overrides for 2.13.0-M4.
We can fix it, but the fix will probably never see the light of a release, because I don't intend to keep supporting 2.13.0-M4 in future versions of Scala.js. The only reason 0.6.25 has it was to provide an upgrade path (SJS 0.6.24 w/ M4 -> SJS 0.6.25 w/ M4 -> SJS 0.6.25 w/ M5).

Fixed in f1593883bf9b5da0d2c6d3c1170539b3216dd516.

@sjrd I don't mean to nag but… nagging. :-)
Can we get a release which contains this fix? Right now, things are quite awkward because 0.6.24 is the most recent usable version of scala.js for anyone hitting this issue (which is a lot of projects), but 0.6.24 doesn't have a cross-build published for 2.12.7, and I'm assuming it's not going to have one for 2.13.0-M5 or higher. This in turn has a bit of a cascading effect on the ecosystem, particularly because of the high-level (dependency-wise) projects which are affected.
Would it be better for those of us who are affected to upgrade to a 1.0 milestone?

We should indeed make a release. We are actually behind schedule, as we typically try to release the 0.6.x branch every 2 months (the last release was on September 3rd).

Would it be better for those of us who are affected to upgrade to a 1.0 milestone?

That decision should be done independently of such a factor. It will have other major consequences, especially if you are talking about a library. That will have an impact on your downstream users. Ideally, as a library, you should build and publish both for 0.6.x and the latest 1.0 milestones.

you should build and publish both for 0.6.x and the latest 1.0 milestones.

Is there tooling for this? I just shuddered involuntarily, because it sounds like you're adding an axis of cross-building. :-P

@sjrd Thank you so much!!

authors: djspiewak sjrd xuwei-k

repo: scala-js/scala-js


text:
Update sbt to 1.7.1

Updates org.scala-sbt:sbt from 1.6.2 to 1.7.1.
GitHub Release Notes - Version Diff
I'll automatically update this PR to resolve conflicts as long as you don't change it yourself.
If you'd like to skip this version, you can just close this PR. If you have any feedback, just mention me in the comments below.
Configure Scala Steward for your repository with a .scala-steward.conf file.
Have a fantastic day writing Scala!

Adjust future updates
Add this to your .scala-steward.conf file to ignore future updates of this dependency:
updates.ignore = [ { groupId = "org.scala-sbt", artifactId = "sbt" } ]

Or, add this to slow down future updates of this dependency:
dependencyOverrides = [{
  pullRequests = { frequency = "@monthly" },
  dependency = { groupId = "org.scala-sbt", artifactId = "sbt" }
}]

labels: library-update, early-semver-minor, semver-spec-minor, commit-count:1

Superseded by #354.


text:
Upgrade to Webpack 4

Adds a small increase in the resulting output size:
/opt/metadoc@webpack-4 > du -sh target/metadoc/
5.8M	target/metadoc/
/opt/metadoc@webpack-4 > du -sh /opt/metadoc-vanilla/target/metadoc/
5.6M	/opt/metadoc-vanilla/target/metadoc/

Tests fixed in #107

Ah, I only tested with
find . -name target | xargs rm -rf
sbt metadoc-site
python3 -mhttp.server --directory target/metadoc 1234

I like long dev cycles. 😉

The problem was that the generated scala.js code was not loaded.

repo: scalameta/mbrowse


text:
chore(scalar.aspnetcore): clean up tests and packages

Fixes one of the ASP.NET test and updates some package formatting.
@xC0dex let me know if this looks okay 🙏

Fixes #3352

repo: scalar/scalar


text:
Combinators for Assertion

Today I wanted to combine multiple Assertions and was stuck, since I expected simple combinators as && and || to be present for Assertions. On Stackoverflow I found, that we can combine assertions using the following:
def andAssertions(a : Assertion, b : Assertion) : Assertion = {
    assert((a == Succeeded) && (b == Succeeded))
}

This is just a one-liner, but I'd argue that the code is not very intuitive.
Would it be possible to ship scalatest with && (and || accordingly) implemented for Assertion?

@smoes Fyi we have something under development called Expectations (in place of Assertions) and Fact (in place of Assertion):
https://github.com/scalatest/scalatest/blob/3.2.x-new/jvm/core/src/main/scala/org/scalatest/expectations/Expectations.scala
https://github.com/scalatest/scalatest/blob/3.2.x-new/jvm/core/src/main/scala/org/scalatest/Fact.scala
The expect function from Expectations will return Fact, and Fact can support && and || like what you want, I can't recall what's left for development for Expectations and Fact, they are in @bvenners 's plan to be released in future version of ScalaTest.

authors: cheeseng smoes

repo: scalatest/scalatest


text:
Resolve RGB values of theme color

Hi,
The document mentions multiple times that python-pptx supports theme colors like "accent 1", but never mentions how to resolve the RGB values of these colors. I'm writing a program that translates textboxes in slides to ASS tags (http://docs.aegisub.org/3.2/ASS_Tags/) and I need to know the RGB value of the theme colors if the font color is not defined in absolute RGB terms.
When I unzip a pptx file, I could find a few theme XML files in /ppt/theme/. The theme colors are under <a:theme>/<a:themeElements>/<a:clrScheme>, where the theme color constants are indices into the color mapping.
Does python-pptx have an API exposed that allows the user to access the theme (specifically, the RGB values of the theme colors) the sides are using? There's a class called CT_OfficeStyleSheet in oxml/theme.py that might be useful but it's not documented.

Short answer is no. We haven't really done anything with themes so far, not even the preliminary analysis. There does seem to be some complexity there, because a presentation can have multiple themes and I'm not sure exactly what drives that; possibly having multiple slide masters, which can happen when you paste in slides from another presentation (in PowerPoint).
The CT_OfficeStyleSheet element class is indeed the root element of a theme part. It came in with the work on NotesSlide because a notes slide master needs a theme and there might not be one present yet, so all it does so far is create a default theme part when there are none.
So you'd be starting pretty much from scratch.
All theme parts will be loaded, it's just that they're pptx.opc.package.Part objects instead of something more specific (and more functional). But there are ways to get a reference to that Part object and that gets you access to the .blob, which you can parse the way XmlPart does. From the resulting root element you can use XPath expressions and other lxml calls to navigate to the color information.
The quickest way to get to the theme part is probably from the part it's related "from". For the color of a shape on a slide it looks like that would be the slide master. So something like:
from pptx.opc.constants import RELATIONSHIP_TYPE as RT
from pptx.oxml import parse_xml

slide_master = slide.slide_layout.slide_master
slide_master_part = slide_master.part
theme_part = slide_master_part.part_related_by(RT.THEME)

theme = parse_xml(theme_part.blob)  # theme here is an <a:theme> element
srgbClr = theme.xpath('a:themeElements/a:clrScheme/a:accent1/@a:srgbClr')[0]
print(srgbClr)  # --> '93D023' or similar

This is aircode, so you might need to tweak it a bit to get it working.

I used the following expression today and it worked nicely.
srgbClr = theme.xpath('a:themeElements/a:clrScheme/a:accent1/a:srgbClr/@val')[0]

authors: Kilo19 leakydata scanny

repo: scanny/python-pptx


text:
Not able to match sound mode: 'PLIIX MUSIC', returning raw sound mode.

AVR-X4000
HA: 2021.2.0.dev20210101

Just added it, thanks 👍

Just added it, thanks 👍