Cutout.prepare() no reponse

Code
When running the standard pattern for creating an ERA5 cutout (https://atlite.readthedocs.io/en/latest/examples/plotting_with_atlite.html)
import geopandas as gpd
import cartopy.io.shapereader as shpreader
import atlite
import logging

logging.basicConfig(level=logging.INFO)
shpfilename = shpreader.natural_earth(resolution='10m',
                                      category='cultural',
                                      name='admin_0_countries')
reader = shpreader.Reader(shpfilename)
UkIr = gpd.GeoSeries({r.attributes['NAME_EN']: r.geometry
                      for r in reader.records()},
                     crs={'init': 'epsg:4326'}
                     ).reindex(['United Kingdom', 'Ireland'])

# Define the cutout; this will not yet trigger any major operations
cutout = atlite.Cutout(name="uk-2011-01",
                       cutout_dir="./",
                       module="era5",
                       bounds=UkIr.unary_union.bounds,
                       years=slice(2011,2011),
                       months=slice(1,1))

# This is where all the work happens.
cutout.prepare()

Error
I got the following message when I run the code in Spyder:

> C:\Users\Yiping\Miniconda3\lib\site-packages\pyproj\crs\crs.py:55: FutureWarning: '+init=<authority>:<code>' syntax is deprecated. '<authority>:<code>' is the preferred initialization method. When making the change, be mindful of axis order changes: https://pyproj4.github.io/pyproj/stable/gotchas.html#axis-order-changes-in-proj-6
>   return _prepare_from_string(" ".join(pjargs))
> INFO:atlite.cutout:Cutout uk-2011-01 not found in directory ./, building new one
> INFO:cdsapi:Sending request to https://cds.climate.copernicus.eu/api/v2/resources/reanalysis-era5-single-levels
> INFO:cdsapi:Request is completed
> INFO:atlite.datasets.era5:Downloading request for 9 variables to C:\Users\Yiping\AppData\Local\Temp\tmpqrvzeks3.nc
> INFO:cdsapi:Downloading http://<IP_ADDRESS>/cache-compute-0006/cache/data7/adaptor.mars.internal-1583414461.1578808-27797-3-b18c0f99-b457-440f-990b-0daa709defa9.nc to C:\Users\Yiping\AppData\Local\Temp\tmpqrvzeks3.nc (126.6K)
> INFO:cdsapi:Download rate 846.1K/s
> INFO:atlite.preparation:Starting preparation of cutout 'uk-2011-01'
> INFO:atlite.preparation:1 tasks have been collected. Starting running them on all processors.

It seems to be working, but the problem is:
my computer CPU keeps running with full speed but without any output for 2 hours.
Then, I run the code in the command line and get the following error. It seems it is the problem of the Initialization of Cutout with "months = slice(1,1)". But it is exactly the same as the given example (see examples/create_cutout.py). Can anyone help with this? Thanks a lot!**
> C:\Users\Yiping\Miniconda3\lib\site-packages\pyproj\crs.py:77: FutureWarning: '+init=<authority>:<code>' syntax is deprecated. '<authority>:<code>' is the preferred initialization method.
>   return _prepare_from_string(" ".join(pjargs))
> C:\Users\Yiping\Miniconda3\lib\site-packages\pyproj\crs.py:77: FutureWarning: '+init=<authority>:<code>' syntax is deprecated. '<authority>:<code>' is the preferred initialization method.
>   return _prepare_from_string(" ".join(pjargs))
> C:\Users\Yiping\Miniconda3\lib\site-packages\pyproj\crs.py:77: FutureWarning: '+init=<authority>:<code>' syntax is deprecated. '<authority>:<code>' is the preferred initialization method.
>   return _prepare_from_string(" ".join(pjargs))
> C:\Users\Yiping\Miniconda3\lib\site-packages\pyproj\crs.py:77: FutureWarning: '+init=<authority>:<code>' syntax is deprecated. '<authority>:<code>' is the preferred initialization method.
>   return _prepare_from_string(" ".join(pjargs))
> C:\Users\Yiping\Miniconda3\lib\site-packages\pyproj\crs.py:77: FutureWarning: '+init=<authority>:<code>' syntax is deprecated. '<authority>:<code>' is the preferred initialization method.
>   return _prepare_from_string(" ".join(pjargs))
> C:\Users\Yiping\Miniconda3\lib\site-packages\pyproj\crs.py:77: FutureWarning: '+init=<authority>:<code>' syntax is deprecated. '<authority>:<code>' is the preferred initialization method.
>   return _prepare_from_string(" ".join(pjargs))
> C:\Users\Yiping\Miniconda3\lib\site-packages\pyproj\crs.py:77: FutureWarning: '+init=<authority>:<code>' syntax is deprecated. '<authority>:<code>' is the preferred initialization method.
>   return _prepare_from_string(" ".join(pjargs))
> C:\Users\Yiping\Miniconda3\lib\site-packages\pyproj\crs.py:77: FutureWarning: '+init=<authority>:<code>' syntax is deprecated. '<authority>:<code>' is the preferred initialization method.
>   return _prepare_from_string(" ".join(pjargs))
> C:\Users\Yiping\Miniconda3\lib\site-packages\pyproj\crs.py:77: FutureWarning: '+init=<authority>:<code>' syntax is deprecated. '<authority>:<code>' is the preferred initialization method.
>   return _prepare_from_string(" ".join(pjargs))
> C:\Users\Yiping\Miniconda3\lib\site-packages\pyproj\crs.py:77: FutureWarning: '+init=<authority>:<code>' syntax is deprecated. '<authority>:<code>' is the preferred initialization method.
>   return _prepare_from_string(" ".join(pjargs))
> C:\Users\Yiping\Miniconda3\lib\site-packages\pyproj\crs.py:77: FutureWarning: '+init=<authority>:<code>' syntax is deprecated. '<authority>:<code>' is the preferred initialization method.
>   return _prepare_from_string(" ".join(pjargs))
> C:\Users\Yiping\Miniconda3\lib\site-packages\pyproj\crs.py:77: FutureWarning: '+init=<authority>:<code>' syntax is deprecated. '<authority>:<code>' is the preferred initialization method.
>   return _prepare_from_string(" ".join(pjargs))
> Traceback (most recent call last):
>   File "<string>", line 1, in <module>
>   File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 105, in spawn_main
>     exitcode = _main(fd)
>   File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 114, in _main
>     prepare(preparation_data)
>   File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 225, in prepare
> Traceback (most recent call last):
>   File "<string>", line 1, in <module>
>     _fixup_main_from_path(data['init_main_from_path'])
>   File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 105, in spawn_main
>   File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 277, in _fixup_main_from_path
>         exitcode = _main(fd)run_name="__mp_main__")
>
>   File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 114, in _main
>   File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 263, in run_path
>         prepare(preparation_data)
>   File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 225, in prepare
> pkg_name=pkg_name, script_name=fname)
>   File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 96, in _run_module_code
>         _fixup_main_from_path(data['init_main_from_path'])mod_name, mod_spec, pkg_name, script_name)
>   File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 277, in _fixup_main_from_path
>
>   File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 85, in _run_code
>         exec(code, run_globals)run_name="__mp_main__")
>   File "C:\Users\Yiping\Documents\Python Workspace\REUTE\climate\atlite_example.py", line 29, in <module>
>
> months=slice(1,1))  File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 263, in run_path
>
>   File "C:\Users\Yiping\Miniconda3\lib\site-packages\atlite\cutout.py", line 60, in __init__
>     pkg_name=pkg_name, script_name=fname)    assert False
> AssertionError
>
>   File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 96, in _run_module_code
>     Traceback (most recent call last):
>   File "<string>", line 1, in <module>
> mod_name, mod_spec, pkg_name, script_name)  File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 105, in spawn_main
>
>   File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 85, in _run_code
>     exitcode = _main(fd)
>       File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 114, in _main
> exec(code, run_globals)
> Traceback (most recent call last):
>   File "C:\Users\Yiping\Documents\Python Workspace\REUTE\climate\atlite_example.py", line 29, in <module>
>       File "<string>", line 1, in <module>
> prepare(preparation_data)      File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 105, in spawn_main
>
>   File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 225, in prepare
> months=slice(1,1))
>   File "C:\Users\Yiping\Miniconda3\lib\site-packages\atlite\cutout.py", line 60, in __init__
> exitcode = _main(fd)    Traceback (most recent call last):
> _fixup_main_from_path(data['init_main_from_path'])
>
> Traceback (most recent call last):
>       File "<string>", line 1, in <module>
> Traceback (most recent call last):
>   File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 114, in _main
>   File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 277, in _fixup_main_from_path
>   File "<string>", line 1, in <module>
> assert False  File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 105, in spawn_main
>   File "<string>", line 1, in <module>
>         Traceback (most recent call last):
>   File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 105, in spawn_main
>
>     prepare(preparation_data)  File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 105, in spawn_main
>
>   File "<string>", line 1, in <module>
> AssertionErrorexitcode = _main(fd)run_name="__mp_main__")      File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 225, in prepare
>
> exitcode = _main(fd)  File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 105, in spawn_main
>
> exitcode = _main(fd)Traceback (most recent call last):
>
>
>       File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 263, in run_path
>
>       File "<string>", line 1, in <module>
> exitcode = _main(fd)  File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 114, in _main
> _fixup_main_from_path(data['init_main_from_path'])  File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 114, in _main
>       File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 114, in _main
> Traceback (most recent call last):
>
>   File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 105, in spawn_main
>
>     pkg_name=pkg_name, script_name=fname)      File "<string>", line 1, in <module>
> prepare(preparation_data)      File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 114, in _main
>   File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 277, in _fixup_main_from_path
>     prepare(preparation_data)
> Traceback (most recent call last):
>   File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 105, in spawn_main
>
> prepare(preparation_data)    exitcode = _main(fd)
>   File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 96, in _run_module_code
>       File "<string>", line 1, in <module>
>   File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 225, in prepare
>
> exitcode = _main(fd)
>   File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 225, in prepare
>     run_name="__mp_main__")  File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 105, in spawn_main
> prepare(preparation_data)  File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 225, in prepare
>
> _fixup_main_from_path(data['init_main_from_path'])    mod_name, mod_spec, pkg_name, script_name)
>
>       File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 114, in _main
>   File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 114, in _main
>
> _fixup_main_from_path(data['init_main_from_path'])
>   File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 263, in run_path
>   File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 225, in prepare
> exitcode = _main(fd)Traceback (most recent call last):
>     _fixup_main_from_path(data['init_main_from_path'])  File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 277, in _fixup_main_from_path
>
>   File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 85, in _run_code
>
> pkg_name=pkg_name, script_name=fname)    prepare(preparation_data)
>
>   File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 277, in _fixup_main_from_path
>           File "<string>", line 1, in <module>
>
>   File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 114, in _main
> _fixup_main_from_path(data['init_main_from_path'])prepare(preparation_data)
>
> run_name="__mp_main__")exec(code, run_globals)  File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 105, in spawn_main
>   File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 96, in _run_module_code
>       File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 277, in _fixup_main_from_path
>   File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 225, in prepare
>   File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 277, in _fixup_main_from_path
>       File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 225, in prepare
>
>
>         run_name="__mp_main__")        prepare(preparation_data)      File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 263, in run_path
>       File "C:\Users\Yiping\Documents\Python Workspace\REUTE\climate\atlite_example.py", line 29, in <module>
> mod_name, mod_spec, pkg_name, script_name)exitcode = _main(fd)
>
> _fixup_main_from_path(data['init_main_from_path'])
> run_name="__mp_main__")    _fixup_main_from_path(data['init_main_from_path'])
> run_name="__mp_main__")  File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 263, in run_path
>
>
>   File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 225, in prepare
>
> pkg_name=pkg_name, script_name=fname)
> months=slice(1,1))  File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 85, in _run_code
>   File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 114, in _main
>       File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 263, in run_path
>   File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 277, in _fixup_main_from_path
>   File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 263, in run_path
>
>       File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 277, in _fixup_main_from_path
>
>     pkg_name=pkg_name, script_name=fname)
>           File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 96, in _run_module_code
> _fixup_main_from_path(data['init_main_from_path'])  File "C:\Users\Yiping\Miniconda3\lib\site-packages\atlite\cutout.py", line 60, in __init__
>     exec(code, run_globals)    prepare(preparation_data)  File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 96, in _run_module_code
> run_name="__mp_main__")pkg_name=pkg_name, script_name=fname)
>
>     run_name="__mp_main__")
> pkg_name=pkg_name, script_name=fname)
>
>
>   File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 263, in run_path
>   File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 277, in _fixup_main_from_path
> assert False
>   File "C:\Users\Yiping\Documents\Python Workspace\REUTE\climate\atlite_example.py", line 29, in <module>
>       File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 225, in prepare
>   File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 96, in _run_module_code
> mod_name, mod_spec, pkg_name, script_name)  File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 96, in _run_module_code
>
> pkg_name=pkg_name, script_name=fname)        mod_name, mod_spec, pkg_name, script_name)months=slice(1,1))
>       File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 263, in run_path
> AssertionError
> run_name="__mp_main__")
>
> _fixup_main_from_path(data['init_main_from_path'])  File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 85, in _run_code
> mod_name, mod_spec, pkg_name, script_name)
> pkg_name=pkg_name, script_name=fname)
> mod_name, mod_spec, pkg_name, script_name)  File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 263, in run_path
>   File "C:\Users\Yiping\Miniconda3\lib\site-packages\atlite\cutout.py", line 60, in __init__
>
>
>   File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 96, in _run_module_code
>
>   File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 85, in _run_code
>
>           File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 277, in _fixup_main_from_path
> exec(code, run_globals)  File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 85, in _run_code
>       File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 96, in _run_module_code
> mod_name, mod_spec, pkg_name, script_name)  File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 85, in _run_code
> pkg_name=pkg_name, script_name=fname)assert False
>
>
> exec(code, run_globals)  File "C:\Users\Yiping\Documents\Python Workspace\REUTE\climate\atlite_example.py", line 29, in <module>
> exec(code, run_globals)exec(code, run_globals)
> mod_name, mod_spec, pkg_name, script_name)  File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 85, in _run_code
>
>   File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 96, in _run_module_code
>
>     run_name="__mp_main__")  File "C:\Users\Yiping\Documents\Python Workspace\REUTE\climate\atlite_example.py", line 29, in <module>
>
>
> AssertionError          File "C:\Users\Yiping\Documents\Python Workspace\REUTE\climate\atlite_example.py", line 29, in <module>
> months=slice(1,1))
>
>   File "C:\Users\Yiping\Documents\Python Workspace\REUTE\climate\atlite_example.py", line 29, in <module>
>   File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 85, in _run_code
>
> exec(code, run_globals)mod_name, mod_spec, pkg_name, script_name)          File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 263, in run_path
>   File "C:\Users\Yiping\Miniconda3\lib\site-packages\atlite\cutout.py", line 60, in __init__
>
> months=slice(1,1))months=slice(1,1))
> months=slice(1,1))exec(code, run_globals)assert False  File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 85, in _run_code
>
>
> pkg_name=pkg_name, script_name=fname)  File "C:\Users\Yiping\Documents\Python Workspace\REUTE\climate\atlite_example.py", line 29, in <module>
>
>
>       File "C:\Users\Yiping\Miniconda3\lib\site-packages\atlite\cutout.py", line 60, in __init__
>   File "C:\Users\Yiping\Miniconda3\lib\site-packages\atlite\cutout.py", line 60, in __init__
>
>
>   File "C:\Users\Yiping\Miniconda3\lib\site-packages\atlite\cutout.py", line 60, in __init__
> months=slice(1,1))AssertionErrorexec(code, run_globals)          File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 96, in _run_module_code
>   File "C:\Users\Yiping\Documents\Python Workspace\REUTE\climate\atlite_example.py", line 29, in <module>
>
>
>
> assert Falseassert False          File "C:\Users\Yiping\Miniconda3\lib\site-packages\atlite\cutout.py", line 60, in __init__
> assert False  File "C:\Users\Yiping\Documents\Python Workspace\REUTE\climate\atlite_example.py", line 29, in <module>
>
>
> mod_name, mod_spec, pkg_name, script_name)months=slice(1,1))
>     AssertionErrorAssertionError
>
> assert FalseAssertionErrormonths=slice(1,1))
>
>   File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 85, in _run_code
>   File "C:\Users\Yiping\Miniconda3\lib\site-packages\atlite\cutout.py", line 60, in __init__
>
>
>
> AssertionErrorassert False  File "C:\Users\Yiping\Miniconda3\lib\site-packages\atlite\cutout.py", line 60, in __init__
> exec(code, run_globals)
>
>
> assert False  File "C:\Users\Yiping\Documents\Python Workspace\REUTE\climate\atlite_example.py", line 29, in <module>
> AssertionError
>
>     AssertionErrormonths=slice(1,1))
>
>   File "C:\Users\Yiping\Miniconda3\lib\site-packages\atlite\cutout.py", line 60, in __init__
>     assert False
> AssertionError

[edit by @euronion : Formatting. Surronding your output with ``` ... ``` preserves the error message formatting and makes it easier to read.]

The documentation on https://atlite.readthedocs.io is for the upcoming version of atlite which we have yet to finish in the next weeks. You seem to be running on another version. Which version do you have installed?
Preparing the cutout does take rather long and uses all CPU ressources it can get its hands on. This will get better with the new version.
The code you posted seems incomplete. Is this the same code that produces the error when you run the script from your command line?

@euronion Thank you for the comment!

Thanks for the information. I am using version 0.0.2.
I have updated the original problem description with the complete code and error log. Yes, there is no error reported when I run it in Spyder, but the problem is that it keeps runs for at least 2hrs without any response/output.
I run the same code in the command line, and it firstly shows the same message ( "...Starting running them on all processors") and then keeps printing repeatedly the error I reported. Sorry for the formatting.

Hi @fang1103 ,
Thanks for the code update.  Your output contains DEBUG output from the logging package, which is only configured for INFO in your code above.
I tried reproducing the problem on windows and on linux. On both plattforms the code above runs without problems and finishes within a minute or so on my laptop.
INFO:atlite.preparation:Starting preparation of cutout 'ukie-2011-01'
INFO:atlite.preparation:1 tasks have been collected. Starting running them on all processors.
INFO:atlite.preparation:Merging variables into monthly compound files
DEBUG:atlite.preparation:Completed file 201101.nc
INFO:atlite.preparation:Cutout 'ukie-2011-01' has been successfully prepared

Unfortunatley it is not clear to me, how your error above comes to be.

Hi @euronion
Sorry for the original misleading post, the output containing DEBUG output was when I used the following code
import warnings
import logging

warnings.simplefilter('default', DeprecationWarning)
logging.captureWarnings(True)
logging.basicConfig(level=logging.INFO)

I updated the message log after suppressing the DEBUG output in my original post.
But the problem is the same, my computer keeps running for hours without any output after
INFO:atlite.preparation:1 tasks have been collected. Starting running them on all processors.  with Spyder, and it keeps reporting the error repeatedly with the command line.
It is not normal, right? I've tested the CDSAPI with the following code, and it works perfectly with a download rate 4.7M/s. I've also removed and reinstalled atlite, but didn't help...I will try to run it on Linux to see what happens.
import cdsapi
c = cdsapi.Client()
c.retrieve("reanalysis-era5-single-levels",
{
"variable": "runoff",
"product_type": "reanalysis",
"year": "2008",
"month": "01",
"day": "01",
"time": "12:00",
"format": "netcdf"
},
"runoff.nc")

@euronion Hi, I come back to you after I set nprocesses=1 in cutout.prepare(), which can help to see more clearly the error bug:
The following message keeps showing repeatedly when I am running the code in the command line:
C:\Users\Yiping\Miniconda3\lib\site-packages\pyproj\crs\crs.py:55: FutureWarning: '+init=<authority>:<code>' syntax is deprecated. '<authority>:<code>' is the preferred initialization method. When making the change, be mindful of axis order changes: https://pyproj4.github.io/pyproj/stable/gotchas.html#axis-order-changes-in-proj-6
  return _prepare_from_string(" ".join(pjargs))
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 105, in spawn_main
    exitcode = _main(fd)
  File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 114, in _main
    prepare(preparation_data)
  File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 225, in prepare
    _fixup_main_from_path(data['init_main_from_path'])
  File "C:\Users\Yiping\Miniconda3\lib\multiprocessing\spawn.py", line 277, in _fixup_main_from_path
    run_name="__mp_main__")
  File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 263, in run_path
    pkg_name=pkg_name, script_name=fname)
  File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 96, in _run_module_code
    mod_name, mod_spec, pkg_name, script_name)
  File "C:\Users\Yiping\Miniconda3\lib\runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "C:\Users\Yiping\Documents\Python Workspace\REUTE\climate\atlite_example.py", line 30, in <module>
    months=slice(1,1))
  File "C:\Users\Yiping\Miniconda3\lib\site-packages\atlite\cutout.py", line 60, in __init__
    assert False
AssertionError

Thanks for the updates.
The code modifications were not significant, but sometimes it can happen that one accidentally uses different code than the one that is posted - just making sure that's not the case :)
Setting nprocesses=1 really helped making things more clear.
You are running into these lines
https://github.com/PyPSA/atlite/blob/7d60f68e9043cecd7f65c77b7e0f480c1f22d4b0/atlite/cutout.py#L57-L60
Can you check whether the directory $cutout_dir/uk-2011-01 for storing the cutout files exists?
If it does, delete or rename it, including all contents, and try again.

@euronion Thanks for the quick message! I've tracked to this part, but still haven't figured out what's the problem.
The directory $cutout_dir/uk-2011-01 does not exist when I was running the code and having the above-reported message, then I have this directory created by the code after I interrupted its running with Ctrl+C (since it keeps reporting the AssertionError continuously)
If the directory $cutout_dir/uk-2011-01 exists, I got the following error and the code stops runing:
C:\Users\Yiping\Miniconda3\lib\site-packages\pyproj\crs\crs.py:55: FutureWarning: '+init=<authority>:<code>' syntax is deprecated. '<authority>:<code>' is the preferred initialization method. When making the change, be mindful of axis order changes: https://pyproj4.github.io/pyproj/stable/gotchas.html#axis-order-changes-in-proj-6
  return _prepare_from_string(" ".join(pjargs))
Traceback (most recent call last):
  File "C:\Users\Yiping\Documents\Python Workspace\REUTE\climate\atlite_example.py", line 29, in <module>
    months=slice(1,1))
  File "C:\Users\Yiping\Miniconda3\lib\site-packages\atlite\cutout.py", line 60, in __init__
    assert False
AssertionError

That's weird, it should stop at this point if the directories it wants to write only partially exist.
From which source are you installing? PyPI, conda-forge or GitHub?
Could you retry with a fresh conda environment based on the environment.yaml file + conda install -c conda-forge cartopy atlite cdsapi ?

@euronion I installed atlite from the conda-forge using conda install atlite with:
> channels:
>   - conda-forge
>   - defaults
> channel_priority: flexible

Following your suggestion, I created a fresh conda environment using the environment.yaml file by
conda env create -f environment.yaml
and installed all the packages
conda install -c conda-forge cartopy atlite cdsapi
and run the code there, unfortunately it is the same result, very weird...

Ok, so it doesn't seem to be a package / dependency-specific issue.
Let's wait and see what your results from testing it on linux are.

Hi @euronion, it works when I set up the conda environment and run the code in the VM Virtualbox-based Ubuntu system. I had the cutout successfully.
Then, I re-install the anaconda and re-setup all the things in my windows but still has the same problem, it just doesn't work...very weird
Which setting are you using in your windows?

hi @fang1103, in a sense you are right that it is multiprocessing causing the problem here and it would be interesting to compare how each of you start their code.
How multiprocessing in windows works is that it starts a new python interpreter and makes it load the same module/script again. Up to now, I always thought, it would only use the module from which one sets up the multiprocessing pool but in your case the stacktrace shows clearly that multiprocessing starts your script again. So to fix your problem, move your logic into a main function. I would wagger that @euronion runs your code from within an ipykernel either through ipython or jupyter in which case multiprocessing will not re-run the script in the newly spawned python engines, so it goes through fine. On linux you don't have the problem since you can just fork instead of start a new python interpreter. Multiprocessing is weird. Let's get v0.2 out and get rid of that bit of code!
import geopandas as gpd
import cartopy.io.shapereader as shpreader
import atlite
import logging

def main():
    shpfilename = shpreader.natural_earth(resolution='10m',
                                        category='cultural',
                                        name='admin_0_countries')
    reader = shpreader.Reader(shpfilename)
    UkIr = gpd.GeoSeries({r.attributes['NAME_EN']: r.geometry
                        for r in reader.records()},
                        crs={'init': 'epsg:4326'}
                        ).reindex(['United Kingdom', 'Ireland'])

    # Define the cutout; this will not yet trigger any major operations
    cutout = atlite.Cutout(name="uk-2011-01",
                        cutout_dir="./",
                        module="era5",
                        bounds=UkIr.unary_union.bounds,
                        years=slice(2011,2011),
                        months=slice(1,1))

    # This is where all the work happens.
    cutout.prepare()

if __name__ == "__main__":
    logging.basicConfig(level=logging.INFO)
    main()

@coroa Thank you very much for the clear explanation!! Now it works, seems we need to always protect the multiprocessing code.

Hi, Jonas
Does Atlite (the current version V0.0.2 or the upcoming V0.2) work with the
Cordex data?
I am a bit lost in creating a cutout from the Cordex dataset, can you
provide a simple example, or just tell the general procedures of doing it?
Thanks!
Kind regards,
Yiping
On Mon, 9 Mar 2020 at 18:06, Jonas Hörsch<EMAIL_ADDRESS>wrote:

Closed #56 https://github.com/PyPSA/atlite/issues/56.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/PyPSA/atlite/issues/56?email_source=notifications&email_token=AFUQPVEKDXZYQYHV5TYKF4DRGUOZNA5CNFSM4LCM4WT2YY3PNVWWK3TUL52HS4DFWZEXG43VMVCXMZLOORHG65DJMZUWGYLUNFXW5KTDN5WW2ZLOORPWSZGOXF3NXHI#event-3111574429,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AFUQPVA6AOZOJTPA34GPIDTRGUOZNANCNFSM4LCM4WTQ
.

[...] I would wagger that @euronion runs your code from within an ipykernel either through ipython or jupyter [...]

Correct, I was testing it in jupyter lab.
Thanks for the help @coroa !


v0.0.8

Codecov Report

Merging #28 into master will not change coverage.
The diff coverage is n/a.

@@          Coverage Diff           @@
##           master     #28   +/-   ##
======================================
  Coverage    6.81%   6.81%
======================================
  Files           2       2
  Lines         220     220
======================================
  Hits           15      15
  Misses        204     204
  Partials        1       1

Continue to review full report at Codecov.

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


Add jira_component

Dynamic Instrumentation team uses DEBUG JIRA project, where Component field is mandatory for new card creation. Because of that Agent release QA cards generation was failing.
This PR adds the missing field.

/merge


Hvg

The whole PR is pretty awesome already! I wrote some comments...
Can you also add the function to the docs, cross reference the deprecated and the new function in the Notes section and add it to the release notes?

Yes, i will.

Thank you!

I'm merging this now, as we're slowly running in danger of getting conflicts with other people working on this. Please move forward with the remaining issues in a new PR. Thank you!


Address-to-Symbol Resolution

Is it possible to get some information on how to resolve an address in a DLL to a function name, the same way Visual Studio does with Windows DLLs while debugging? I once tried writing a small program that uses the Windows dbghelp.dll APIs to do this, but those APIs are so buggy as to be unusable. It would be even better if there is documentation that makes an implementation of a tool like atos(1) for Windows possible. Thanks!

I once tried writing a small program that uses the Windows dbghelp.dll APIs to do this, but those APIs are so buggy as to be unusable.

It's works as expected for me in Vld

To capture callstack use CaptureStackBackTrace

You can refer to DIA2Dump sample code shipped in DIA SDK in Visual Studio.  "dia2dump.exe -sym  " will output the symbol for the given address.


Update quickstart-custom-container.md

Fixed minor edits.

@pallabiwrites : Thanks for your contribution! The author(s) have been notified to review your proposed change.

Looks good; thanks @pallabiwrites.


v6 toolbar background color issue

Since v6, the bottom toolbar -s dark background is white and the buttons are invisible, however when I open settings menu, then there the toolbar -s background is dark again, so theme is correct:
Screenshots added.

What is your device and android version?

What is your device and android version?

Xperia X, stock Oreo 8.0.
BTW, is this normal, that after v5 > v6 upgrade, Yuzu didn't use find custom theme and used default theme and user must import and select custom theme again?

BTW, is this normal, that after v5 > v6 upgrade, Yuzu didn't use find custom theme and used default theme and user must import and select custom theme again?

Yes, you need to import custom theme due to scoped storage limitations (android 10 or higher). Of course it doesn't affect older versions of android, but I changed it for consistency.

Tested more, made new, dark based custom theme, copied all settings/colors from old light to the new dark theme. When I compared old and new theme settings (to find out what causes the toolbar background color issue) turned out, that settings are now identical:
{
"lightTheme": "true",
"showTabDivider": "true",
"pullToRefreshDark": "true",
"toolbarBackgroundColor": "0xffffffff",
"toolbarTextColor": "0xff080808",
"toolbarImageColor": "0xff3069c4",
"qcItemBackgroundColorNormal": "0xf4c57373",
"qcItemBackgroundColorSelect": "0xffef8881",
"statusBarDarkIcon": "true"
}
But Yuzu is showing them differently and also Yuzu Browser Theme Creator -s theme preview doesn't match the Yuzu layout.

So seems that browser and editor are not compatible and Yuzu ignores some custom theme settings.
When I select built in light theme, the toolbar is grey:

And after using built in light or dark theme and then selecting custom theme, Yuzu crashes and looses all browser settings and uses default layout:

Thanks for the detailed debugging!


return list rather than dict_values from registry.all()

To support indexing and slicing

@alex-hh wanna fix this up or close as you like?


Support get asset id by name in pallet_assets.

Support get asset id by name in pallet_assets as issue #10732 described.

@bkchr Not sure I'd call this trivial.
For one it changes the fungibles API and requires downstream changes for implementers of InspectMetadata. Wouldn't merge this without approval from @shawntabrizi
(Or maybe you both disagree with me.)

@bkchr Not sure I'd call this trivial. For one it changes the fungibles API and requires downstream changes for implementers of InspectMetadata. Wouldn't merge this without approval from @shawntabrizi (Or maybe you both disagree with me.)

I did not merge it.
I did request a review from @shawntabrizi.
trivial is about if that requires an audit and this doesn't require an audit.

The actual use here is that we must use the name when using the asset, and then query the corresponding assetId. Of course, in our use case, the name is unique (it may be the address of a contract on other chains). Because there is already a name field in assetmetadata, if substrate provide a way to reverse query assetId by name, we can save some storage on the chain without store the mapping relationship between assetid and name on chain.
Other people may have similar requirements when using substrate, they may use other elements to query assetid (such as symbol, etc.).  If it is allowed to add a trait, we can query assetId through name and symbol in this trait?


ScriptClass: implement ScriptReadonlyProperty

This feature enables users to expose readonly data from a scriptclass
This PR contains:

[x] Changelog
[ ] Documentation
[x] Tests

Though I must admit I'm struggling a bit to come up with a good use case for this, do you have an example?

I need this for exposing constants in JS.
<CameraView ux:Name="Camera">
	<JavaScript>
		Camera.SetCaptureMode(Camera.CAPTURE_MODE_PHOTO);
		Camera.SetFlashMode(Camera.FLASH_MODE_AUTO);
	</JavaScript>
</CameraView>

Ah right, nice one :)


Enhancement: MIDI User Event

As AudioKit is the most powerful and most easy to use CoreMIDI-Wrapper available, I'd love to see it even more versatile. Followup of #1393
Now: AKMIDIStatus-Messages can be added dynamically to a AKMusicTrack
New: AKMIDIStatus-Message can contain user event as in CoreMIDI::MusicEventUserData and AKMIDIListener has a Default implementation with AKLog

Thanks for the kind words. We'd really like to make a second pass at doing MIDI right in a very modern Swifty way.

This is not really very actionable, and I'm trying to pare down the issues, so instead I've added it to our projects: https://github.com/AudioKit/AudioKit/projects/3 and when we do a bit of MIDI overhaul (coming soon) we'll be referring to that.


[WIP]KIALI-170 Jaeger UI, search Traces

First iteration of integration of Jager UI
This need SWSCORE-121
You can search like Jaeger UI less custom date(To do). Sort is implemented too.
To Do

[ ] Let custom Date( Now disabled)
[ ] Trace View
[ ] Check Style CSS

cc @abonas @theute

Highlevel comment - can you make the lefthand menu item "Traces" instead of "Jaeger". Thanks.

The changlog looks huge, is that a fork ?

@theute  I was talking with @abonas about this...I agree with her that this will be difficult to maintain but I don't know another way right now, the code is not typescript and sintax is different in jaeger, I had to rewrite part of the code and change some functions, I tried to add jaeger-ui like Library (@jotak told me about this possibility) but I got the same errors.  I need to talk with @mtho11 to see alternatives.
Anyway this is a first iteration to have jaeger search in Kiali.

Let's continue as research, but we shouldn't merge a fork.
If we need a "fork", we'll likely have a quite different UI designed by a specialized team.
As commented in the JIRA, for now we can just link to the Jaeger UI KIALI-242 and keep on researching options to integrate without forking.
Does it really need to be using Typescript for us to embed a React component ?

it looks great :cake: , but indeed all my and @theute concerns still stand, so lets explore a bit more alternatives before merging this.

If I understand correctly the problem is that jaeger-ui [1] is not published on npm, so we cannot use it as a dependency, is that correct?
We could consider

Ask Jaeger team if they could publish jaeger-ui on npm
Or pull jaeger-ui from github as part of our build process

@jotak I just solve that
"jaeger-ui"<EMAIL_ADDRESS>
Now I am learnign about babel to let insert the Jaeger code and avoid warnings.
After that I think that We won't have problems in add components, only we'll need to configure proxy
 "proxy": {
    "/api": {
      "target": <JAEGER-QUERY> or <PROXY SWSCORE>,
      "logLevel": "silent",
      "secure": false,
      "changeOrigin": true,
      "ws": true,
      "xfwd": true
    }
}

Research time @abonas @theute

Can one of the admins verify this patch?


[REQUEST]: Add API methods for executing LuaU

Roblox has recently announced their new api to execute Luau headlessly, which is very useful in running certain scripts to obtain data.
Here is the documentation for all the new endpoints:
https://create.roblox.com/docs/cloud/reference/LuauExecutionSessionTask
https://create.roblox.com/docs/cloud/reference/LuauExecutionSessionTaskLog

Executing Luau has now been added in v1.0.52.


add target users doc

closes #160
This PR adds a "Target Users" doc to the repo to help define a set of target users that can be used to direct future architecture and feature decisions about the SDK (and overall CodeFlare Stack)
This is a draft, so please add your comments. :)

I feel like there should be codeflare-sdk developer targeting users who wants to contribute to the sdk source code and need a  mini codeflare-stack (on their laptop).

@tedhtchang I think that a  target codeflare-sdk developer doc should exist somewhere in the contributor docs, but not sure we need it here.


python  trap divide error

Environment info
Operating System:CentOS 7
GCC version:4.8.5
Cuda Toolkit:7.5
Cuda compiler driver:6.5
Built with GPU
What have you tried?
I run /usr/lib/python2.7/site-packages/tensorflow/models/image/mnist/convolutional.py will print:Floating point exception
I tensorflow/stream_executor/dso_loader.cc:105] successfully opened CUDA library libcublas.so locally
I tensorflow/stream_executor/dso_loader.cc:105] successfully opened CUDA library libcudnn.so locally
I tensorflow/stream_executor/dso_loader.cc:105] successfully opened CUDA library libcufft.so locally
I tensorflow/stream_executor/dso_loader.cc:105] successfully opened CUDA library libcuda.so.1 locally
I tensorflow/stream_executor/dso_loader.cc:105] successfully opened CUDA library libcurand.so locally
Successfully downloaded train-images-idx3-ubyte.gz 9912422 bytes.
Successfully downloaded train-labels-idx1-ubyte.gz 28881 bytes.
Successfully downloaded t10k-images-idx3-ubyte.gz 1648877 bytes.
Successfully downloaded t10k-labels-idx1-ubyte.gz 4542 bytes.
Extracting data/train-images-idx3-ubyte.gz
Extracting data/train-labels-idx1-ubyte.gz
Extracting data/t10k-images-idx3-ubyte.gz
Extracting data/t10k-labels-idx1-ubyte.gz
I tensorflow/core/common_runtime/gpu/gpu_init.cc:102] Found device 0 with properties:
name: Tesla K40m
major: 3 minor: 5 memoryClockRate (GHz) 0.745
pciBusID 0000:04:00.0
Total memory: 11.25GiB
Free memory: 3.08GiB
I tensorflow/core/common_runtime/gpu/gpu_init.cc:126] DMA: 0
I tensorflow/core/common_runtime/gpu/gpu_init.cc:136] 0:   Y
I tensorflow/core/common_runtime/gpu/gpu_device.cc:755] Creating TensorFlow device (/gpu:0) -> (device: 0, name: Tesla K40m, pci bus id: 0000:04:00.0)
Failed to get the number of CUDA devices: CUDA driver version is insufficient for CUDA runtime version
Floating point exception
I view the system message:
Apr 20 10:53:43 milan kernel: traps: python[66624] trap divide error ip:7fc0113304d2 sp:7fbf74ff0170 error:0 in _pywrap_tensorflow.so[7fc00f573000+a38a000]

"Failed to get the number of CUDA devices: CUDA driver version is insufficient for CUDA runtime version" from your logs sounds like a problem -- try to upgrade your cuda driver?

(Or consider compiling from sources if you want to use an earlier CUDA runtime)


Add easy overload to compile sourceBuffers and remove main if version SDC_Library is set

This doesn't looks like it is in shape to be merged. First, I don't think having a version for compiling SDC as a library does any good. main is in its own module, so that shouldn't be a problem to not get it in without messing up with versions. Second a lot of formatting is off, interface poorly thought out (The string needs to be 0-terminated! The terminator needs to be included in bufferLength!)

this is because the lexer uses '\0' as a sentinel...
the main reason to pass in raw buffers is speed!
so I will not concat the '\0' onto the end and reallocate everything

plus c-strings are almost always \0 terminated...
so it should not be hard to  fulfil that requirement

Ok this is stale. Closing.


Run sample error on windows

$ go run main.go
panic: Failed to initialize gl: glGetBufferParameteri64v
goroutine 1 [running, locked to thread]:
github.com/google/gxui/drivers/gl.CreateViewport(0xc08200a380, 0x320, 0x258, 0x7
537d0, 0x5, 0xc082023e88)
C:/Go/src/github.com/google/gxui/drivers/gl/viewport.go:68 +0x2ab
github.com/google/gxui/drivers/gl.func路016()
C:/Go/src/github.com/google/gxui/drivers/gl/driver.go:142 +0x68
github.com/google/gxui/drivers/gl.func路011()
C:/Go/src/github.com/google/gxui/drivers/gl/driver.go:57 +0x36
github.com/google/gxui/drivers/gl.(*Driver).run(0xc08200a380)
C:/Go/src/github.com/google/gxui/drivers/gl/driver.go:85 +0x7c
github.com/google/gxui/drivers/gl.StartDriver(0x8fc090)
C:/Go/src/github.com/google/gxui/drivers/gl/driver.go:47 +0x1ec
main.main()
E:/golang/app/UI/main.go:164 +0x31
goroutine 17 [syscall, locked to thread]:
runtime.goexit()
c:/go/src/runtime/asm_amd64.s:2232 +0x1
goroutine 5 [chan receive]:
github.com/google/gxui/drivers/gl.(*Driver).syncDriver(0xc08200a380, 0xc08218cd2
0)
C:/Go/src/github.com/google/gxui/drivers/gl/driver.go:58 +0x137
github.com/google/gxui/drivers/gl.(*Driver).CreateViewport(0xc08200a380, 0x320,
0x258, 0x7537d0, 0x5, 0x0, 0x0)
C:/Go/src/github.com/google/gxui/drivers/gl/driver.go:147 +0x1e1
github.com/google/gxui/mixins.(*Window).Init(0xc08201b8c0, 0x3694f0, 0xc08201b8c
0, 0x361fd8, 0xc08200a380, 0x320, 0x258, 0x7537d0, 0x5)
C:/Go/src/github.com/google/gxui/mixins/window.go:71 +0x326
github.com/google/gxui/themes/dark.CreateWindow(0xc08219e000, 0x320, 0x258, 0x75
37d0, 0x5, 0x0, 0x0)
C:/Go/src/github.com/google/gxui/themes/dark/window.go:19 +0x119
github.com/google/gxui/themes/dark.(*Theme).CreateWindow(0xc08219e000, 0x320, 0x
258, 0x7537d0, 0x5, 0x0, 0x0)
C:/Go/src/github.com/google/gxui/themes/dark/theme.go:169 +0x69
main.appMain(0x361fd8, 0xc08200a380)
E:/golang/app/UI/main.go:155 +0x1de
created by github.com/google/gxui/drivers/gl.StartDriver
C:/Go/src/github.com/google/gxui/drivers/gl/driver.go:46 +0x1dc
exit status 2

What graphics card / drivers do you have installed?

Intel(R) HD Graphics 3000
drivers come for Intel and version is <IP_ADDRESS>17

why gxui use opengl 3.2？the card just support 3.1

same problem.
how to solve it ?

Same problem here, with a Intel Core i3 Sandy Bridge and integrated graphics card.
I think the problem is due to the fact our hardware supports OpenGL up to 3.1 while gxui requires OpenGL 3.2.

btw,#version 150 should add to glsl code, if we use use the future of opengl3.2/glsl1.5. or opgl3.1/glsl1.4

I've dropped the GL version down to 2.1.
Hopefully this is enough for your drivers / cards.

it's working now.


Auto login redirect when application starts

Library

[ ]<EMAIL_ADDRESS>or<EMAIL_ADDRESS>[ ]<EMAIL_ADDRESS>[ ]<EMAIL_ADDRESS>[ ]<EMAIL_ADDRESS>[x]<EMAIL_ADDRESS>
Description
Hello, how is it going?
I'm working with an AngularJS application that uses Azure authentication, and I'm wondering if there is way to redirect to the login page before the application "starts", or shows any content. This is something to enhance user experience, since the browser shows the interface of the app before the user has a change to login. I could create a login page to show before the app's real content, or some other work around, but my point is: is there a way to do this only using the msal-angularjs library?
I downloaded this sample: https://github.com/AzureAD/microsoft-authentication-library-for-js/tree/dev-angular-1.0/samples/angular7-sample-app
And tried something like this:
import { Component, OnInit } from '@angular/core';
import { BroadcastService, MsalService } from '@azure/msal-angular';
import { Logger, CryptoUtils } from 'msal';

@Component({
  selector: 'app-root',
  templateUrl: './app.component.html',
  styleUrls: ['./app.component.css']
})
export class AppComponent implements OnInit {
  title = 'MSAL - Angular 7 Sample App';
  isIframe = false;
  loggedIn = false;

  constructor(private broadcastService: BroadcastService, private authService: MsalService) { }

  ngOnInit() {
    this.isIframe = window !== window.parent && !window.opener;

    this.checkoutAccount();

    this.broadcastService.subscribe('msal:loginSuccess', () => {
      this.checkoutAccount();
    });

    this.authService.handleRedirectCallback((authError, response) => {
      if (authError) {
        console.error('Redirect Error: ', authError.errorMessage);
        return;
      }

      console.log('Redirect Success: ', response.accessToken);
    });

    this.authService.setLogger(new Logger((logLevel, message, piiEnabled) => {
      console.log('MSAL Logging: ', message);
    }, {
      correlationId: CryptoUtils.createNewGuid(),
      piiLoggingEnabled: false
    }));

    if (!this.loggedIn) {
      this.login();
    }

  }

  checkoutAccount() {
    this.loggedIn = !!this.authService.getAccount();
  }

  login() {
    const isIE = window.navigator.userAgent.indexOf('MSIE ') > -1 || window.navigator.userAgent.indexOf('Trident/') > -1;

    // if (isIE) {
    //   this.authService.loginRedirect();
    // } else {
    //   this.authService.loginPopup();
    // }

    this.authService.loginRedirect();
  }

  logout() {
    this.authService.logout();
  }
}

However, the app still loads its content before the redirect.
I'm new to this version of Angular, so I'm sorry if there's already a silly solution for this.
Thanks in advance for the support!

@soares-fernando To clarify, are you using Angular or AngularJS? The sample you link to is for Angular, not AngularJS.
Since MSAL is a client-side library, your application will have to load client-side initially in some way before redirecting to the login page. As you mention, you could create a page in your app dedicated to making this check, but that is work you would need to do, and is outside the scope of the library. If you want your application to be able to make that determination before loading anything client-side, you should use one of the server-side side MSAL libraries.

@jasonnutter I'm so sorry. I'm using Angular, not AngularJS. Force of habit to call it AngularJS. That said, thanks for your answer. I'm definitely look into this two options, building a login page, or use a server-side MSAL library.  Since the project is for a client I'll have to consider it with them. But anyways, thanks.


Support phrases replacement

In fcitx5-mcbopomofo, phrases replacement is enabled if phrases-replacement.txt exists in the user's data path, usually $HOME/.local/share/fcitx5/mcbopomofo/phrases-replacement.txt, and it's disabled if the file does not exist or is removed.
fcitx5-mcbopomofo does not populate the file with a template; this is different from the behavior of the macOS version.
This feature is introduced to be in sync with the macOS version. It's also motivated by https://github.com/openvanilla/McBopomofo/issues/458, which can be solved by phrases replacement.

Thanks!

BTW, I remember that we have a shortcut in the input menu that helps the users to edit the user phrases. I guess we can also such a menu item for phrase replacement,

Sounds good. Let me look into, as a follow-up to this, adding a menu item when phrases replacement is enabled.


Scraper scrapes the wrong genre

DSESS scraper suddenly gives my games the wrong genre, I have Resident Evil suddenly becoming RPG whereas it should be horror and shooter. Plus there are many games getting genres that were never meant for them.

The genre editor for item is available in the latest version.


Perception: PaddlePaddle models

Add PaddlePaddle models for perception camera object detection, lane line detection, lidar object detection.

Please check the build.

@KaWaiTsoiBaidu Please do the rebase instead of merge.


NativeAppEventEmitter.addListener('healthKit:Workout:new', cb) automatically triggers callback -- each time we open the app

Describe the bug
NativeAppEventEmitter.addListener('healthKit:Workout:new', cb) automatically triggers callback - Each time we open the app these listeners triggers which calls the http request all the time which is not ideal.
It should be called only once if there is any new data received.
Anyone faced that too?
Expected behavior
Listeners should only be called if there is any new data
Code
useEffect(() => {
   async function handleAppleHealthNativeEvents() {
     let appleHealthTracking = await AsyncStorage.getItem(
       'appleHealthTracking',
     );
     if (JSON.parse(appleHealthTracking)) {
       NativeAppEventEmitter.addListener(
         'healthKit:Workout:setup:success',
         () => {},
       );
       NativeAppEventEmitter.addListener(
         'healthKit:Workout:setup:failure',
         () => console.log('Setup failure -->'),
       );
       NativeAppEventEmitter.addListener('healthKit:Workout:failure', () =>
         console.log('failure -->'),
       );
       NativeAppEventEmitter.addListener(
         'healthKit:Workout:new',
         appleHealthNewDataCallback,
       );
     }
   }
   if (Platform.OS === 'ios') {
     handleAppleHealthNativeEvents();
   }
 }, []);

Smartphone (please complete the following information):

Device:  iPhone13 Pro Max

Getting the same. v1.10.0

Same here on v.1.10.0.   Believe it doesn't work at all in later releases (awaiting fix in 1.14.0) - also the intent raise is causing my app to crash - but unsure why at present! (it runs the same code as if it was polling in the foreground and that never crashes at all!)

Hey!
The listeners are built wrapping over HealthKit's Observer Queries, which have this same behaviour, so this is actually caused by HealthKit itself, there isn't much we can do here.
Here you can find a similar discussion:
https://stackoverflow.com/questions/33139181/health-kit-observer-query-always-called-when-the-app-becomes-active
I recommend checking if you have new data before doing anything else in the listener callback block.
I will close this issue but feel free to open a thread on the Discussion page if you want help or if you have a suggestion about this topic.


Libusbgx conversion v2

Switch gadgetd to using the maintained libusbgx library rather than libusbg.

@kopasiak ok, that makes sense.  Thanks for the feedback! :)
I'll create a new pull req with an update.


Cannot destructure property 'name' of 'signal' as it is null

======= 2021-02-26 09:42:46: F.install('module', '') ---> TypeError: Cannot destructure property 'name' of 'signal' as it is null. TypeError: Cannot destructure property 'name' of 'signal' as it is null.

Yeah was getting this after updating to the new version of open-wa, the temp fix I have applied is

Goto human-signals/build/src/main.js
Comment out line 31-34
`// const signalsA=Array.from({length},(value,number)=>
// getSignalByNumber(number,signals));

// return Object.assign({},...signalsA);`

That will fix the error and allow your instance to start

@impozzible any permanent fix? how can I make this fix in docker?


NTR: Research > Survey

AMR-GRDI Specification - New Term Request (NTR)
May request multiple terms in a single issue - delete the fields irrelevant to your request.
Picklist Item(s)
Associated Field(s): purpose_of_sampling
Label: Research > Survey
Definition/Description: Survey study conducted for research purposes outside of a mandated requirement.
Definition Source:
Synonyms or alternative labels:
Additional Comments (not an annotation):

Contributor Attribution: Andrew Scott (AAFC)

Hi Andrew - thanks for trying out the new term request system!
For this term, when you say "survey study", do you mean the same kind of thing as the Surveillance terms we already have (baseline or targeted) but it's for for research rather than for operational purposes (like as opposed to public health surveillance or monitoring of sentinel sites)?

Yes, for research instead of the types of surveys that PHAC and CFIA do... an example of the type we do...
Distribution and diversity of Escherichia coli populations in the South Nation River drainage basin, eastern Ontario, Canada.
Lyautey E, Lu Z, Lapen DR, Wilkes G, Scott A, Berkers T, Edge TA, Topp E. Appl Environ Microbiol. 2010 Mar;76(5):1486-96. doi: 10.1128/AEM.02288-09. Epub 2009 Dec 28. PMID: 20038693

We've added "Survey study" under Research in the "purpose of sampling" field.
How does that sound?


Completely new to re-frame; don't understand the README

I'm trying to follow along in the README, and was trying to create a subscription handler for :name-query.
(defn name-query [db [sid]]
  (assert (= sid :customer-query))
  (reaction (get-in @db [:name])))

(re-frame.core/register-sub :name-query name-query)

(defn app-root []
  (let [name-ratom (subscribe [:name-query])]
    (fn []
      [view @name-ratom])))

At this point, I get a warning that register-sub is deprecated and I should use reg-sub-raw.
(defn name-query [db [sid]]
  (assert (= sid :customer-query))
  (reaction (get-in @db [:name])))

(re-frame.core/reg-sub-raw :name-query name-query)

(defn app-root []
  (let [name-ratom (subscribe [:name-query])]
    (fn []
      [view @name-ratom])))

And now I'm getting all sorts of weird errors.  Here's one:
console.error: "reframe: no ", ":event", " handler registered for" ", {"ns":null,"name":"name-query","fqn":"name-query","_hash":"780334378,"cljs$lang$protocol_mask$partition0$":2153775105,"cljs$lang$protocol_mask$partition1$":4096}

I am utterly lost at this point, and I would appreciate it if you could point me in the right direction.  Am I going completely insane, or has the code changed such that the README is confusing?
Also, is there anywhere I can read up on "app-db"?  If I ask for app-db in the repl, I get nil back, but your README states that it exists for me in the background?  Any info on this would be appreciated as well.

You might look into the new docs section ... there's also a FAQ dealing with how to inspect app-db.

Thank you very much, that helps a lot.

Sorry about that:  version 0.8.0 introduced reg-sub and the docs haven't yet caught up.  To understand reg-sub look at the todomvc example:
https://github.com/Day8/re-frame/blob/master/examples/todomvc/src/todomvc/subs.cljs


Update Dockerfile

No longer builds with 2.0:
The current .NET SDK does not support targeting .NET Core 2.1.  Either target .NET Core 2.0 or lower, or use a version of the .NET SDK that supports .NET Core 2.1.

haha my bad


increase 'base' dependency

i tried setting up a circleci test on base-4.9 if we want to support it -- I didn't make it. We could add back the import to Data.Monoid but the simplest is probably to drop these versions.

circleci did run it.. but it didn't want to build on base-4.9. had to pull in tons of extra-deps in the stack.yaml because of our other dependencies (servant, megaparsec). i'm pretty sure it's possible but in the end it was just a headache.

@emmanueltouzery Sounds good like this then, thanks!


Issue Unchecked runtime.lastError: Cannot find menu item with id webext-domain-permission-toggle:add-permission

After installing the chrome extension and after a few minutes I get the following error in the service worker:
Unchecked runtime.lastError: Cannot find menu item with id webext-domain-permission-toggle:add-permission
Then the button Enable ${manifest.name} on this domain disappears from the context menu (right click the extension icon).
I'm trying to debug in the library, but so far I don't have success. This happens in the latest version 4.1.0. The extension is running on Manifest v3.
Any suggestions how to fix it are welcome. Thanks!

I added support for MV3 only recently so it's possible that it's incomplete, but there is a test extension in the repo and it worked fine there. Make sure you have the required setup in the manifest.

Use v5, it's been published as a "next" version under a new name. I forgot to publish it completely.

Ok, I figured it out. It was because of my code in the extension. I had chrome.contextMenus.removeAll(); and completely forgot about it. I used it for other context menu items.
I'll continue with the v4.1.0
Sorry for the trouble.


Bull Board UI stuck on "Loading"

Hi, we have been looking for something to monitor our Bull Queues for quite some time. and I use Bull Board for monitor queues,
I'm using Fastift rather than Express, and I have been stuck on Loading... This happened only on production, but on development all going well.

Reproduce:
export const setupBullBoard = (app: NestFastifyApplication) => {
  const bullServerAdapter = new BullFastifyAdapter();
  bullServerAdapter.setBasePath('/queues/ui');

  const queues = Object.values(QUEUES).map(
    (queue) => new BullAdapter(new Queue(queue)),
  );

  createBullBoard({
    queues,
    serverAdapter: bullServerAdapter,
  });

  app.register(bullServerAdapter.registerPlugin(), {
    prefix: '/queues/ui',
    basePath: '',
  });
};

"bull": "^4.2.1"
"@nestjs/core": "^8.2.5"
"@bull-board/fastify": "^3.9.0"

I'm not able to reproduce.
I've used the with-fastify example, and change to you prefixes.
All works.
If it works on dev but not on prod, it is probably a problem of mounting point, can you share the prefix that you have on prod?

Pay attention that you get 504, gateway time out, it is for sure related to your prod setup

yes, on my production server always loading, is my prefix that must use versioning (v1)? but, in development server is going well

can you share you url path (without the domain) of the bull ui & the API requests it made?

endpoint for bull UI is : URL/queues/ui
but I don't understand what API Request you mean
did you mean this?
swagger: /v1/docs/static/index.html
bull ui: /queues/ui
sample: v1/public/...

can you open the console, and check where the UI makes it's api requests?

So routes look OK.
you have probably an issue with reverse-proxy on your prod env.
Do you have one? (a reverse proxy)

No I don't have, and I try to direct using IP and port, it same

It. Is not related to IP.
You don't have nginx or something similar?

finally, I found the thing that makes why it always loads, on my dev, running locally without docker. then I tried to run in my dev workspace using docker. the result is the same as in production, I use Docker in production.
Heres is my docker setup:
version: '2'
services:
  app:
    build: .
    container_name: app-api
    depends_on:
      - db
      - redis
    volumes:
      - ./src:/app/src
      - .env:/app/.env
    ports:
      - 8080:8080

  db:
    image: postgres:12
    container_name: app-db
    restart: always
    environment:
      POSTGRES_USER: root
      POSTGRES_DB: just_pay
      POSTGRES_PASSWORD: P@ssw0rd
    ports:
      - 5432:5432
    volumes:
      - postgresdata:/var/lib/postgresql

  redis:
    image: redis:5
    container_name: app-redis
    restart: always
    ports:
      - 6379:6379

volumes:
  postgresdata:

Hi,
I have the same issue with bullboard + fastify on queues that have a large size job payload.

Hi,
I have the same issue with bullboard + fastify on queues that have a large size job payload.

It is not related to the this issue.
Can you open a new issue with details (job for example)?

I have found the same issue, and it seemed like there was a job with null and that was causing an issue for me, so I checked that node-modules/bull-board/routes/getDataForQeues.js
In the getDataForQeues function, if we use flatMap instead of map.
And in the formatJob function, if we use if (!job) return [];, then I think this case could be handled, let me know, if this helps.
@felixmosh Can you please do these changes to resolve this issue at least maybe.

Hi @jyotirmoy-bst, looks like you are using a really old version of bull-board, can you update to latest and check if it solves your problem?

@whydnxx can we close this issue?

why this is closed?

This issue was stale for 90 days...
What is the error that you get?

Make sense, but I am getting the same error. The same Redis instance on local is working, the deployed version on AWS gives me 504 after some time of loading, this is the only error that I get, nothing on server logs 😢

Can we debug it somehow?
will you share you screen on Discord?

Unfortunately, I cannot share the code, but let's try to debug it together. My discord username is defalt#7298

@fr1sk Did you ever figure this out? I am having the same problem.

@fr1sk Did you ever figure this out? I am having the same problem.

What do you get?

Also have the same problem with this one on an AWS instance, works fine locally with default Redis configs. We are getting 504 when requesting BASE_URL/BASE_BULL_PATH/api/queues?page=1&jobsPerPage=10.
At first i thought this is related to the reverse proxy issue mentioned earlier by @felixmosh but it is unlikely because a similar route works, i.e: I am able to add a job via BASE_URL/BASE_BULL_PATH/add?name=PROCESS_SYNC_JOB

While using nestjs
import { BullModule } from '@nestjs/bull';
import { ConfigModule, ConfigService } from '@nestjs/config';

BullModule.forRootAsync({
      imports: [ConfigModule],
      inject: [ConfigService],
      useFactory: async (config: ConfigService) => {
        return {
          redis: {
            host: 'your-redis-host',
            port: 'your-redis-port',
            password: 'your-redis-password-if-any',
          },
        };
      },
    }),

Make use of host, port and/or password
host: 'your-redis-host',
port: 'your-redis-port',
password: 'your-redis-password-if-any',

don't use url
url: `your-redis-url`

Why is this closed? Having the same issue with AWS deployment that uses Elasticache instance.

Interesting, I'll investigate it, it should fallback to en automatically... But probably there is some issue.
Can you open a new issue for that?


Support for Universal Apps

The universal apps won't show up, is it possible to make them searchable  ?

Already mentioned here:
https://github.com/hainproject/hain/issues/18


Wait for loadingFinished before requesting response body

See: https://github.com/Everettss/puppeteer-har/issues/19

Seems like this project is not maintained, I have used your fork directly and I can confirm that the generated har does contain responses.
@jonapgar Thanks for providing a solution to this issue, I have used your github fork directly, are you be considering mainting it or even creating a separate package on npm?

Hey there! Since this functionality is important for us we've started maintaining this package over at https://github.com/auteon/puppeteer-har. The API has changed slightly and the whole thing is written in TypeScript now.


Add packaging for debian based linux distributions

Hey friends!
Been a while!
I finally got around to finishing the debian packaging work.
I added a package directory with documentation and scripts on auto-generating the deb file.
We can attach the generated deb files to the releases tab in github for users to download and then they can just run dpkg on the deb file or use their favorite gui package manager.
Let me know what you think!

Hey Alec, super great to hear from you! Thanks a ton for doing this! Looks good to me! I have given you contributor access, so you can git ship this PR!

Or, for simplicity sake, I have merged it in. From now on you can work off our repo directly!

Thanks! Great to hear from you too!
I agree with all of your comments. Do you want me to implement those changes in a separate PR?

I've added a backwards release for v0.10.0 (since my scripts will only work for future releases where a package directory exists) to the releases page on github until I can sort out the mess that is debian software source servers

Ah, I forgot there are comments on this PR. Yes, please do them in a separate one, haha.


Cannot get ghost to send mail from Google Cloud Platform

Welcome to Ghost's GitHub repo! 👋🎉
Do you need help or have a question? Please come chat in Slack: https://ghost.org/slack 👫.
See https://github.com/TryGhost/Ghost/issues/6968 for why I'm not asking in slack.
Issue Summary
Tested sending email using SMTP from ssh and verified that I can relay to mailgun using postfix and got test email. Mailgun also shows the mail on the log.
However, when sending a test notification from the lab tab, sometimes the button spins and nothing happens or a toastr with [object object] shows up.
confirmed in mailgun logs that nothing was submitted.
Steps to Reproduce

Installed ghost from bitnami to google cloud platform.
signed up for mailgun and then followed google's guide to setup postfix and was able to test send an email from ssh.
Modified the ghost config to send using localhost so postfix will relay to mailgun, restart ghost
Go to lab tab and send a test email

Any other info e.g. Why do you consider this to be a bug? What did you expect to happen instead?
Technical details:

Ghost Version: 0.8.0
Browser/OS: Google Compute Engine/Bitnami

    production: {
        url: 'http://<IP_ADDRESS>:80',
        mail: {
            transport: 'SMTP',
            options: {
                port: 2525,
                host: 'localhost',
            }
        },
        database: {
            client: 'sqlite3',
            connection: {
                filename: path.join(__dirname, '/content/data/ghost.db')
            },
            debug: false
        },
        server: {
            host: '<IP_ADDRESS>',
            port: '2368'
        }
    },

also tried
    production: {
        url: 'http://<IP_ADDRESS>:80',
        mail: {
            transport: 'SMTP',
            options: {
                service: 'Mailgun',
                port: 2525,
                auth: {
                    user: 'mailgunusername',
                    pass: 'guid',
                },
            }
        },
        database: {
            client: 'sqlite3',
            connection: {
                filename: path.join(__dirname, '/content/data/ghost.db')
            },
            debug: false
        },
        server: {
            host: '<IP_ADDRESS>',
            port: '2368'
        }
    },

I realize this isn't much information to go off of, I'd troubleshoot it myself but I'm not sure where the logs are, if any. I tried googling for ghost blog logs and while I've found that prd has less logs than dev, it didn't say where the logs are recorded to.

See #6968 for why I'm not asking in slack.

Please see the reply on that issue for what to do! This is our bug tracker, it's not for getting support with custom installations 😉
Ghost's mail config is passed straight through to nodemailer 0.7.

@ErisDS  Okay. Can you tell me how you guys troubleshoot emails in production when there is a bug? If I'm reading the nodemailer docs you linked correctly, it logs errors into the console rather than to disk. The current version allows me to attach a bunyan logger, but looking at the nodemail repo for version 0.7, the property doesn't exist on the options object.

"Google Compute Engine does not allow outbound connections on ports 25, 465, and 587. By default, these outbound SMTP ports are blocked because of the large amount of abuse these ports are susceptible to." - https://cloud.google.com/compute/docs/tutorials/sending-mail/
I hit this when troubleshooting.  Putting it just for reference.

As you may know, Google Cloud Platform doesn't allow outbound connection to ports 25, 465 and 587
So you just change port of MailGun to 2525
       mail: {
              transport: 'SMTP',
              options: {
                  service: 'Mailgun',
                  host: 'smtp.mailgun.org',
                  port: 2525,
                  auth: {
                      user: '',
                      pass: ''
                  }
              }
       },

It works for me.

I encountered the same problem while setting up Ghost on Google cloud platform. Tried Sparkpost, Zoho and also Mailgun with not success. Changing port from 587 to 2525 saved the day. This should be mentioned in documentation.

Our documentation has a "suggest edits" button - I don't have enough context to know what to change or where 😊

Yes, I clicked it! It required me to register. As I have spent already way too much time on this, I didn't register. Left it here so hopefully, people can find it through google.

@ernests It took me two days to figure out. You could have saved people's time by editing the documentation.

Oh wow! This is still a thing :) @BirkhoffLee thank you for editing

@ErisDS I've made a edit on docs be sure to check

I still seem to be having this issue unfortunately. I've tried to put as much information below. Any help would be great.
Ghost Version: v2.1.4
OS: Ubuntu, v18.04
Node Version: v8.12.0
Ghost-CLI Version: 1.9.4
Environment: production
after running ghost doctor I get the following output.
✔ Checking system Node.js version
✔ Checking logged in user
✔ Ensuring user is not logged in as ghost user
✔ Checking if logged in user is directory owner
✔ Checking current folder permissions
✔ Checking operating system compatibility
+ sudo systemctl is-active ghost_mine
ℹ Validating config [skipped]
✔ Checking folder permissions
✔ Checking file permissions
✔ Checking content folder ownership
✔ Checking memory availability

I've followed the steps required by Google for sending mail via relaying with postfix. I get "success" response from the command line and after checking Mailgun, I can see that the message was delegated to be sent.
I've updated the config of my ghost install to include the mail snippet below:
  "mail": {
    "transport": "SMTP",
    "options": {
      "service": "Mailgun",
      "port": 2525,
      "auth": {
        "user"<EMAIL_ADDRESS>        "pass": "XXXX"
      }
    }
  },

When I go through the Forgot Password flow or try to send a test email, it fails with a gateway timeout. I do not see the intended email on Mailgun either. I'm not sure how to debug this at the moment. It seems that there is some disconnect between Ghost and sending email.

@vernak2539 I have also setup my Ghost Blog on GCP and it is working fine. If you are using the free mailgun sandbox, you will have to add your own email on mailgun and get it verified so as to send the emails.

Sorry for the huge post, it was a long day yesterday and I didn't realise I duplicated the mail object in my config. It all works now after using the mailgun docs on google and having 1 mail object in my config

Okay, so I was dealing with this today, and nothing would work till I added the host value, as below.
"mail": {
    "transport": "SMTP",
    "options": {
        "service": "Mailgun",
        "host": "smtp.mailgun.org",
        "port": 2525,
        "auth": {
            "user": "yourname",
            "pass": "passcode"
        }
    }
},

Just for anyone else who might be experiencing this.


Return result data when modal close

I'm submitting a ...  (check one with "x")
[ ] bug report => search github for a similar issue or PR before submitting
[x] feature request
[ ] support request => Please do not submit support request here, post on Stackoverflow or Gitter

Current behavior
I think I can pass data to modal, but could not find a way to get the data back when dismiss.
Expected behavior
Like the modal in ionic framework, you can pass data to modal, and get the data back when dismissed.
Reproduction of the problem

put ngx-smart-modal directive in a child component
after doing some calculation on the modal, need to take the result back to parent component.
But no approach for me to get the result data when the modal close.

Hi @Thomas0921!
This modal is clearly related to #168 and will be implemented in next versions. I guess what you're asking for is chaining the modal methods. E.g. this.modalService.close().getData(); This way you can chain actions.
But at the moment, it's possible to get data on dismiss as you want. You can refer to the Handle events readme section, and subscribe / listen to onDismiss event. Here's a quick example in your case, with documentation example:
export class AppComponent implements AfterViewInit {
  ...
  constructor(public ngxSmartModalService: NgxSmartModalService) {
  }

  ngAfterViewInit() {
    this.ngxSmartModalService.getModal('videoModal').onDismiss.subscribe((modal: NgxSmartModalComponent) => {
      // modal is the dismissed modal, so do what you want with it
      console.log('Modal data', modal.getData());
    });
  }
}

Let me know if it works for you!
Cheers! 🖖

Hi, thanks for the detailed reply, I manage to achieve the effect I want by using angular core's event emitter. So that I will not need to listen for changes, just fire once when modal close :). I haven't tested it out, but I will use your approach if I still face any error here :) Thanks again


More fine-grained transaction API with savepoints?

try {
  const trx = await db.begin().isolationLevel('serializable').execute()
  await trx.insertInto(...).execute()

  await trx.savepoint('foobar')
  try {
    await trx.updateTable(...).execute()
    await trx.updateTable(...).execute()
  } catch (err) {
    await trx.rollbackToSavepoint('foobar')
  }

  await trx.commit()
} catch (err) {
  await trx.rollback()
}

Great idea! 💡

I personally prefer .startTransaction() over .begin(), clearer intent. The first is usually aliased by the latter in documentations.

We should probably also support .releaseSavepoint(name).

It's weird that some of the methods fire immediately without .execute(). Let's allow compiling and executing these with the usual methods?

Excellent points!
So here's the revised API:
try {
  const trx = await db.startTransaction().setIsolationLevel('serializable').execute()
  await trx.insertInto(...).execute()

  await trx.savepoint('foobar').execute()
  try {
    await trx.updateTable(...).execute()
    await trx.updateTable(...).execute()
    await trx.releaseSavepoint('foobar').execute()
  } catch (err) {
    await trx.rollbackToSavepoint('foobar').execute()
  }

  await trx.commit().execute()
} catch (err) {
  await trx.rollback().execute()
}

Does this replace current API,
We could still provide the old API as a convenience. Most of the time people would probably still want to use that one.

Another good thing about this, is that it allows compiling transactions, e.g. for display in the browser.
We had someone ask about this a while back on discord..

Actually that's not the case 🤔 We have this API in the driver
  /**
   * Commits a transaction.
   */
  commitTransaction(connection: DatabaseConnection): Promise<void>

  /**
   * Rolls back a transaction.
   */
  rollbackTransaction(connection: DatabaseConnection): Promise<void>

  /**
   * Releases a connection back to the pool.
   */
  releaseConnection(connection: DatabaseConnection): Promise<void>

Dialects have the ability to start transactions however they want. For example the kysely-data-api does a "start transaction" HTTP request instead of running a BEGIN SQL command. Same for commit and rollback.
We can't allow those to be compiled since some dialects in fact don't compile anything.

I see, yep that wouldn't work for such dialects..
Can't we make the new API fully compilable, not requesting directly from the driver? So dialects that actually perform a sql query to begin a transaction can enjoy this..

I don't see how? What would compile return for dialects that just call a method and don't execute any SQL?

Not sure, maybe dummy response such as { sql: '', parameters: [], query: { kind: 'StartTransactionNode' }}?

Could we make these driver methods optional?

If they are not implemented (which should be the case for all 3 built-in dialects), beginning a transaction (the old API) defaults to creating a StartTransactionNode, compiling and executing.
If they are implemented, compilation will just return some dummy response.

If this makes sense, a rename that describes this "non-sql begin transaction method" situation would make sense.

Optional driver methods could make sense. But on the other hand, jumping through too many loops to allow the user to compile things that will always be the string commit or rollback doesn't seem too important.

Yeah this is not really worth it, for just 1-2 sql statements that are very predictable. Our consumers could simply prepend them manually if they want to display them. 👍

JS is set to get explicit resource management:
https://github.com/tc39/proposal-explicit-resource-management (reached stage 3).
There is also an async Version in the planning:
https://github.com/tc39/proposal-async-explicit-resource-management
I think transactions could really benefit from this. They are also listed as a use case:
async function transfer(account1, account2) {
  using await tx = transactionManager.startTransaction(account1, account2);
  await account1.debit(amount);
  await account2.credit(amount);

  // mark transaction success if we reach this point
  tx.succeeded = true;
} // await transaction commit or rollback

Maybe this is something you'd consider in the design of a transaction API in the future. Since the sync version of the proposal was accepted, chances are that we'll also get an async version. :)

JS is set to get explicit resource management: tc39/proposal-explicit-resource-management (reached stage 3).
There is also an async version in planning: tc39/proposal-async-explicit-resource-management
I think transactions could really benefit from this. They are also listed as a use case:
async function transfer(account1, account2) {
  using await tx = transactionManager.startTransaction(account1, account2);
  await account1.debit(amount);
  await account2.credit(amount);

  // mark transaction success if we reach this point
  tx.succeeded = true;
} // await transaction commit or rollback

Maybe this is something what would be interesting for the design of a transaction API in the future. Since the sync version of the proposal was accepted, chances are that we'll also get an async version. :)

This feature is great for javascript, but redundant in Kysely, since the current transaction API already abstracts away commit & rollback so consumers can focus on content.
This issue's purpose is to provide consumers with a more fine-grained control over transactions. The demographic for this feature wants to call .commit() and .rollback() themselves.

  tx.succeeded = true;

This is such a footgun. Hate it.

This would also be handy for parallelizing automated tests (each in their own transaction) that talk to the database without having them commit the data. Currently, I truncate tables so the tests have to run single order. With finer grained controls over rollbacking back I can rollback after each test.

Is there any update regarding this?
In our application we would like to use transactions but we would like to perform every query as they come into our streaming system.
The current API would only allow us to batch a list of queries and then perform them all at once by way of
kyselyClient.transaction()
    .execute(async (trx) => {
        queries.map((query) => trx.execute(query))
    });

However, we would prefer to be able to use the connection for the transaction to perform each query as it comes in.
This way we can validate the query is not invalid, by trying to execute it on the connection, and only need to perform the commit when we reach the threshold or a predefined time.
Some pseudocode would be:
class TransactionBatcher {
    addQuery(query: Query) {
        if (!this.transactionHasBegun) {
            this.kyselyClient.beginTransaction();
            this.transactionHasBegun = true;
        }

        try {
             this.kyselyClient.execute(query);
        } catch (e) {
             logger(`Found an error in query: ${query}`);
        }
    }

    commitQueries() {
         try {
             this.kyselyClient.commitTransaction();
         } catch (e) {
             logger('Could not commit query');
             this.kyselyClient.rollbackTransaction();
         }
    }
}

hope this is implemented soon

You can achieve the same thing using the current API with a little bit of hacking.
function begin(db: Kysely<DB>) {
  const connection = new Deferred<Transaction<DB>>()
  const result = new Deferred<any>()

  db.transaction().execute(trx => {
    connection.resolve(trx)
    await result.promise;
  })

  const trx = await connection.promise;

  return {
    trx,
    commit() {
      result.resolve(null)
    },
    rollback() {
      result.reject(new Error('rollback'))
    }
  }
}

export class Deferred<T> {
  readonly #promise: Promise<T>

  #resolve?: (value: T | PromiseLike<T>) => void
  #reject?: (reason?: any) => void

  constructor() {
    this.#promise = new Promise<T>((resolve, reject) => {
      this.#reject = reject
      this.#resolve = resolve
    })
  }

  get promise(): Promise<T> {
    return this.#promise
  }

  resolve = (value: T | PromiseLike<T>): void => {
    if (this.#resolve) {
      this.#resolve(value)
    }
  }

  reject = (reason?: any): void => {
    if (this.#reject) {
      this.#reject(reason)
    }
  }
}

@koskimas Is there a way to achieve individual test cases running in transactions? This would have to support nested transactions in case the business logic that's being tested has transactions itself, probably in the form of savepoints.

crude but works in sqlite
export function createSavePoint(db: Kysely<any>, name?: string) {
  const _name = name || `sp_${new Date().getTime()}`
  return {
    save: async () => {
      await sql`savepoint ${sql.raw(_name)}`.execute(db)
    },
    release: async () => {
      await sql`release savepoint ${sql.raw(_name)}`.execute(db)
    },
    rollback: async () => {
      await sql`rollback to savepoint ${sql.raw(_name)}`.execute(db)
    },
  }
}

await db.transaction().execute(async (trx) => {
  const s1 = createSavePoint(trx)

  await s1.save()
  await trx.insertInto('test').values({ person: `test ${Date.now()}` }).execute()

  const s2 = createSavePoint(trx)

  try {
    await s2.save()
    await trx.insertInto('test').values({ person: `test ${Date.now()}` }).execute()
    await s2.rollback()
    // throw new Error('test error')
    s1.release()
  } catch (error) {
    s1.rollback()
  }
})

Is there a way to achieve individual test cases running in transactions? This would have to support nested transactions in case the business logic that's being tested has transactions itself, probably in the form of savepoints.

I think this is a very important perspective. When testing functions that use transactions by utilizing transaction rollback, it is ideal to support nested transactions so as not to interfere with the internal transactions of the function. Therefore, supporting nested transactions, such as in the form of savepoints, seems ideal to me.

function doSomethingUsingTransaction() {
  db.transaction().execute(tx => {
    ...
  })
}

// test code
export const testTrx = async <T>(fn: (tx: Transaction<DB>) => Promise<T>) => {
  let result: T;
  try {
    await db.transaction().execute(async (tx) => {
      result = await fn(tx);
      throw new TestTrxRollback();
    });
  } catch (e) {
    if (!(e instanceof TestTrxRollback)) throw e;
  }
  return result!;
};

describe('check something', () => {
  it('should rollback', () => {
    testTrx(async (tx) => {
      doSomethingUsingTransaction(tx);
    });
  });
});

@igalklebanov  @koskimas
Do you have any updates or feedback?

@shirakawayohane #962

@shirakawayohane #962

Curious:  are nested transactions going to be possible with that pr? Specifically for my use case I have been testing a server that has itself transactions,  but passing in a transaction into my createServer function to act as the parent db connection doesn't work since nested transactions are not allowed. I get "calling the transaction method for a Transaction is not supported." I want to do this so that I can just rollback any changes done while working with integration tests, both mutations performed by the test itself and mutations performed by the server being tested, some of which are themselves transactions. I'd like to just rollback everything after each test, or if the test fails. Is that something this PR will enable?  Right now Im manually clearing whatever data is mutated by the tested server.  Thx.

@jeffreypeoples
Yes, in the form of savepoints.

@igalklebanov
While it is true that with Savepoint, we can use a transaction during testing, but roll back all the data under test at the end, savepoint perceives that it is in a transaction, which makes it difficult to abstract the process.
Do you have any answers or initiatives regarding this problem awareness?

I see https://github.com/kysely-org/kysely/pull/962 is merged.
Can we please have a new release?

Can the new API be extended to support vendor extensions like sqlite3's IMMEDIATE?

Can the new API be extended to support vendor extensions like sqlite3's IMMEDIATE?

Different issue. Probably.

I'm looking forward to a new release now that #962 is merged.


Browser extension destroy Ant Design website style

Version: 0.3.7
Browser: MicroSoft Edge 112.0.1722.68
When visiting the antd website https://ant.design/docs/react/introduce-cn, the style will be messed up.

It appears that the order of the style sheet has been altered upon enabling the Huntly extension, and I have no idea how it occurred.


Find a way to improve error messages for errors in yaml

(<unknown>): did not find expected key while parsing a block mapping at line 19 column 9

Related to linting: https://github.com/flant/werf/issues/2204
Related to golang yaml library: https://github.com/go-yaml/yaml/releases

outdated


Change environment to * for Fabric

Flywheel has classes that are referenced from code which is loaded on both sides such as LightListener. The environment of Flywheel Fabric is currently set to client which means it will not be loaded on the dedicated server, which causes ClassNotFoundException's.

About a week ago it was decided that some refactors would be done to change these interfaces so that they would not be needed server-side instead of making the mod common. The first part of this refactor that removed the FlywheelRendered interface was done in commit eb8dc6b. LightListener will be dealt with soon.


Remove todo comments in code samples

The documentation will not display the Java tab if it cannot find the associated text for the code sample. I would rather no tab being displayed rather than a // todo
WDYT?

I think you are right, better nothing than //todo but anyway we can submit it to the doc before they are all complete. Otherwise, it will throw an error on the script in the documentation no?

@curquiza,
Also there is some: //Not yet implemented. Did we remove then too or maybe exchange for Not existing ?


[PDI-18086] Transformation Executor - Passing variables using Row Gro…

…uping

Build Completed
:fire: This pull request has some issues. It would be preferable to fix them in order for it to be just perfect. See below for more details. Some links are also available below for further assistance in addressing those issues.
Build Commands
mvn -B -f 'pom.xml' -pl 'engine' -P '!assemblies' -Dsurefire.runOrder=alphabetical -Daudit -amd clean install

Cleanup Commands
mvn -B -f 'pom.xml' -pl 'engine' -P '!assemblies' -amd build-helper:remove-project-artifact

Changed files
  engine/src/main/java/org/pentaho/di/trans/steps/transexecutor/TransExecutor.java
  engine/src/test/java/org/pentaho/di/trans/steps/transexecutor/TransExecutorUnitTest.java

Unit Test Coverage
These statistics help you identify how your changes have affected the coverage of the following files. If a file is not in this list, then its coverage was not affected by your changes. To get some help interpreting these metrics, please refer to Jacoco's documentation.

:warning: Coverage Changes (click to expand)
org.pentaho.di.trans.steps.checksum.CheckSumMeta

Instruction Change: -0.2% :small_red_triangle_down:

org.pentaho.di.job.Job

Branch Change: -0.4% :small_red_triangle_down:
Complexity Change: -0.4% :small_red_triangle_down:
Instruction Change: -0.3% :small_red_triangle_down:
Line Change: -0.4% :small_red_triangle_down:

org.pentaho.di.trans.steps.constant.ConstantMeta

Instruction Change: -0.1% :small_red_triangle_down:

org.pentaho.di.trans.steps.ifnull.IfNullMeta

Branch Change: -2% :small_red_triangle_down:
Complexity Change: -1.9% :small_red_triangle_down:
Instruction Change: -0.2% :small_red_triangle_down:

org.pentaho.di.trans.steps.ldapoutput.LDAPOutputMeta

Instruction Change: -0.1% :small_red_triangle_down:

org.pentaho.di.trans.steps.memgroupby.MemoryGroupByMeta

Branch Change: -1.1% :small_red_triangle_down:
Complexity Change: -1.3% :small_red_triangle_down:

org.pentaho.di.trans.steps.singlethreader.SingleThreaderMeta

Instruction Change: -0.1% :small_red_triangle_down:

org.pentaho.di.trans.steps.textfileinput.TextFileInputMeta

Branch Change: -0.5% :small_red_triangle_down:

org.pentaho.di.trans.steps.transexecutor.TransExecutor

Branch Change: -0.9% :small_red_triangle_down:
Complexity Change: -2.5% :small_red_triangle_down:

org.pentaho.di.trans.steps.uniquerows.UniqueRowsMeta

Instruction Change: -0.1% :small_red_triangle_down:


shared with me: metadata of file, child count of folder is always empty and size of file is always zero.

I was using postman rest api client to get the list of all the sharedWithMe files and folder using the one drive for business api.

Get request was made.
Request url: {serviceEndpointUri}/drive/sharedWithMe.
Added "bearer " in the header and made the request.
The shared files are getting listed but the meta data of each file and child count for folder(even for those that has sub files and folders) is always zero is always empty and the size of files is zero everytime. Other details like id, name of file, createdDateTime, lastModifiedDateTime etc are received correctly. What could be the possible issue?
Also cTag and eTag are missing for all the shared files. Is that expected?

@katahir any update on this

Currently, we don't return the actual createdDateTime of the item. It is a known limitation, but something that should be fixed in the coming months. Same for etag/ctag.

Sorry about this very old issue going stale. If this is still reproducing, could you please provide updated request & response information to help us investigate further? Thanks.


Refactor the statusMessageChan update stuff

The statusMessageChan is a channel that transports updates from
a the docker runtime's health to the runner.
As we move towards multiple containers, we are going to need
to get updates for different containers, any of which can oom, die,
etc.
This refactor prepares the statusMessageChan machinery for multiple
containers, particularly away the closing of the channel as a method
to trigger titusdriver.Lost (should never happen).

Factoring out this change, related to https://github.com/Netflix/titus-executor/pull/692, to make it easier to have a discussion about, or hopefully make it less controversial.

Whoa, that last commit started to fail the TestShutdown.
That is pretty strange. I'm investigating...

Oh disregard, I introduced a real bug in the last commit. Yay tests.


[AKS] fix az aks browse if dashboard isn't prefixed by "pods/"

Makes finding the k8s dashboard pod more robust by returning the last string segment following a / character, if there is one.
Closes Azure/AKS#159

View a preview at https://prompt.ws/r/Azure/azure-cli/5462
This is an experimental preview for @microsoft users.

Add to release notes in HISTORY.rst?

@derekbekoe, done. (This is just a bug fix for an edge case, so I wasn't sure if it needed to go into the changelog.)


Add Animation on Page Carousel when Navigating Pages

Bug Description
There is a missing animation when navigating between pages on the page thumbnail carousel with the blue indicator at the top.
@samitron7 to add animation demo
Expected Behaviour
There should be an animation that looks like a slider effect.
Steps to Reproduce

Go to a story with multiple pages
Change the page

Screenshots

Do not alter or remove anything below. The following sections will be managed by moderators only.
Acceptance Criteria
QA Instructions

Closing ticket since the focus state has changed in new design language.


Implement direct-to-hub gaia hub storage client

Storage communication will be directly between apps & Gaia Hubs without passing through an intermediary local Blockstock Core daemon.
Related issues:
Bearer token generation code: https://github.com/blockstack/blockstack.js/issues/310
Pass gaia hub root url in authentication response token: https://github.com/blockstack/blockstack.js/issues/309

Am I correct in assuming this will solve https://github.com/blockstack/blockstack-core/issues/690?
Also if needed, I can help test this out in a live environment once a PR is brought in.

This has been merged and released as 0.14.0 on npm


An right click menu

Description of the new feature/enhancement
An right click menu that allow you to select whether to paste, cut, copy. Here is a screenshot of what I mean: . It would solve the problem of accidently copying and pasting things into the terminals which occur really often

Proposed technical implementation details (optional)

Thanks for the suggestion! This is actually already being tracked by another issue on our repo - please refer to #3337 for more discussion.
/dup #3337


Update datepart-function.md

Docs Build status updates of commit b75cf22:
:clock10: Pending: waiting for processors (5 builds ahead of you)
:warning: Docs Build is busy, currently there are 5 builds ahead of this one, for more information you can view the Build queue graph on the Docs Portal.

Docs Build status updates of commit b75cf22:
:x: Validation status: errors
Please follow instructions here which may help to resolve issue.

File
Status
Preview URL
Details

:x:Error

Details

[Error]

Cannot sync git repo to specified commit because branch lindalu-MSFT-Patch-1 has been deleted or has been force pushed: fatal: Couldn't find remote ref refs/heads/lindalu-MSFT-Patch-1

For more details, please refer to the build report.
Note: If you changed an existing file name or deleted a file, broken links in other files to the deleted or renamed file are listed only in the full build report.