Assessment tool stops at 70%

Has anyone had any issues with the assessment tool not processing beyond a certain percentage of sites?  I have tried to run the assessment tool twice on my environment and both times it stopped at 70%, and never proceeded beyond that even after letting run for a couple of weeks.  Are there any logs I could take a look at?  Any suggestions as to how I can get it to run all the way through?

Hi @mrivera4 , you can inspect if the assessment is still running via checking the log files. If not there's an option to pause it and restart. If for some reason pausing isn't working you can always terminate all the microsoft365-assessment.exe processes and then restart the assessment you were running, it should then continue with the remaining site collections. See https://pnp.github.io/pnpassessment/using-the-assessment-tool/assess-operations.html#im-scanning-a-huge-number-of-site-collections-and-the-assessment-seems-to-be-stuck-what-should-i-do for more documentation on how to that.

@mrivera4 : I'm closing this issue per no response, if this still is a problem for you then please re-open or create a new issue.


train_gnmt.py met memory runing issue

Hello, thanks for sharing.
I run the script for google neural translation machine training.
Here is command:
python train_gnmt.py --src_lang en --tgt_lang vi --batch_size 128 --optimizer adam --lr 0.001 --lr_update_factor 0.5 --beam_size 10 --bucket_scheme exp  --num_hidden 512 --save_dir gnmt_en_vi_l2_h512_beam10 --epochs 12 --gpu 0
Here is error-log:

Namespace(batch_size=128, beam_size=10, bucket_ratio=0.0, bucket_scheme='exp', clip=5.0, dataset='IWSLT2015', dropout=0.2, epochs=12, gpu=0, log_interval=100, lp_alpha=1.0, lp_k=5, lr=0.001, lr_update_factor=0.5, num_bi_layers=1, num_buckets=5, num_hidden=512, num_layers=2, optimizer='adam', save_dir='gnmt_en_vi_l2_h512_beam10', src_lang='en', src_max_len=50, test_batch_size=32, tgt_lang='vi', tgt_max_len=50)
All Logs will be saved to gnmt_en_vi_l2_h512_beam10/train_gnmt.log
Loading dataset...
Loading dataset...
Loading dataset...
[10:06:50] src/storage/storage.cc:135: Using GPUPooledRoundedStorageManager.
2019-05-05 10:06:50,663 - root - NMTModel(
(tgt_embed): HybridSequential(
(0): Embedding(7709 -> 512, float32)
(1): Dropout(p = 0.0, axes=())
)
(decoder): GNMTDecoder(
(rnn_cells): HybridSequential(
(0): LSTMCell(None -> 2048)
(1): LSTMCell(None -> 2048)
)
(dropout_layer): Dropout(p = 0.2, axes=())
(attention_cell): DotProductAttentionCell(
(_dropout_layer): Dropout(p = 0.0, axes=())
(_proj_query): Dense(None -> 512, linear)
)
)
(tgt_proj): Dense(None -> 7709, linear)
(src_embed): HybridSequential(
(0): Embedding(17191 -> 512, float32)
(1): Dropout(p = 0.0, axes=())
)
(encoder): GNMTEncoder(
(rnn_cells): HybridSequential(
(0): BidirectionalCell(forward=LSTMCell(None -> 2048), backward=LSTMCell(None -> 2048))
(1): LSTMCell(None -> 2048)
)
(dropout_layer): Dropout(p = 0.2, axes=())
)
)
2019-05-05 10:06:50,664 - root - Use beam_size=10, alpha=1.0, K=5
2019-05-05 10:06:50,964 - root - Train Batch Sampler:
FixedBucketSampler:
sample_num=133166, batch_num=1043
key=[(9, 10), (16, 17), (26, 27), (37, 38), (51, 52)]
cnt=[11414, 34897, 37760, 23480, 25615]
batch_size=[128, 128, 128, 128, 128]
2019-05-05 10:06:51,120 - root - Valid Batch Sampler:
FixedBucketSampler:
sample_num=1553, batch_num=51
key=[20, 39, 63, 91, 124]
cnt=[755, 608, 164, 19, 7]
batch_size=[32, 32, 32, 32, 32]
2019-05-05 10:06:51,279 - root - Test Batch Sampler:
FixedBucketSampler:
sample_num=1268, batch_num=42
key=[20, 40, 63, 91, 125]
cnt=[482, 535, 188, 53, 10]
batch_size=[32, 32, 32, 32, 32]
Traceback (most recent call last):
File "train_gnmt.py", line 280, in
train()
File "train_gnmt.py", line 219, in train
gnorm = gluon.utils.clip_global_norm(grads, args.clip)
File "/usr/local/lib/python3.5/dist-packages/mxnet/gluon/utils.py", line 148, in clip_global_norm
if not np.isfinite(total_norm.asscalar()):
File "/usr/local/lib/python3.5/dist-packages/mxnet/ndarray/ndarray.py", line 1998, in asscalar
return self.asnumpy()[0]
File "/usr/local/lib/python3.5/dist-packages/mxnet/ndarray/ndarray.py", line 1980, in asnumpy
ctypes.c_size_t(data.size)))
File "/usr/local/lib/python3.5/dist-packages/mxnet/base.py", line 252, in check_call
raise MXNetError(py_str(_LIB.MXGetLastError()))
mxnet.base.MXNetError: [10:06:51] src/storage/./pooled_storage_manager.h:299: cudaMalloc failed: out of memory
Stack trace returned 10 entries:
[bt] (0) /usr/local/lib/python3.5/dist-packages/mxnet/libmxnet.so(+0x40123a) [0x7fa98ba2423a]
[bt] (1) /usr/local/lib/python3.5/dist-packages/mxnet/libmxnet.so(+0x401851) [0x7fa98ba24851]
[bt] (2) /usr/local/lib/python3.5/dist-packages/mxnet/libmxnet.so(+0x340d25b) [0x7fa98ea3025b]
[bt] (3) /usr/local/lib/python3.5/dist-packages/mxnet/libmxnet.so(+0x341390e) [0x7fa98ea3690e]
[bt] (4) /usr/local/lib/python3.5/dist-packages/mxnet/libmxnet.so(mxnet::NDArray::CheckAndAlloc() const+0x24b) [0x7fa98ba73c2b]
[bt] (5) /usr/local/lib/python3.5/dist-packages/mxnet/libmxnet.so(+0x2d561ad) [0x7fa98e3791ad]
[bt] (6) /usr/local/lib/python3.5/dist-packages/mxnet/libmxnet.so(mxnet::imperative::PushFCompute(std::function<void (nnvm::NodeAttrs const&, mxnet::OpContext const&, std::vector<mxnet::TBlob, std::allocatormxnet::TBlob > const&, std::vector<mxnet::OpReqType, std::allocatormxnet::OpReqType > const&, std::vector<mxnet::TBlob, std::allocatormxnet::TBlob > const&)> const&, nnvm::Op const*, nnvm::NodeAttrs const&, mxnet::Context const&, std::vector<mxnet::engine::Var*, std::allocatormxnet::engine::Var* > const&, std::vector<mxnet::engine::Var*, std::allocatormxnet::engine::Var* > const&, std::vector<mxnet::Resource, std::allocatormxnet::Resource > const&, std::vector<mxnet::NDArray*, std::allocatormxnet::NDArray* > const&, std::vector<mxnet::NDArray*, std::allocatormxnet::NDArray* > const&, std::vector<unsigned int, std::allocator > const&, std::vector<mxnet::OpReqType, std::allocatormxnet::OpReqType > const&)::{lambda(mxnet::RunContext)#1}::operator()(mxnet::RunContext) const+0x213) [0x7fa98e379683]
[bt] (7) /usr/local/lib/python3.5/dist-packages/mxnet/libmxnet.so(+0x2ca7ab7) [0x7fa98e2caab7]
[bt] (8) /usr/local/lib/python3.5/dist-packages/mxnet/libmxnet.so(+0x2ca7ab7) [0x7fa98e2caab7]
[bt] (9) /usr/local/lib/python3.5/dist-packages/mxnet/libmxnet.so(+0x2ca7ab7) [0x7fa98e2caab7]

Only one GPU:

How can I fix the python command to adapt my hardware system?
Thanks & Regards!
Momo1986

Hi @momo1986. Thanks for reporting the issue. What version of mxnet are you using? (you can find by using pip show $package_name)

Hi @momo1986. Thanks for reporting the issue. What version of mxnet are you using? (you can find by using pip show $package_name)

Hello, @szha ， I use MXNET 1.4.0.post0.
Thanks for your concern!
Regards!

@momo1986 there have been some improvements in memory management and dropout state sharing that may be helpful to you. You can try it out by installing the version 1.5.0b20190411 to try it out. If it still doesn't fit, you may need to reduce the batch size or use gradient accumulation to simulate large batch size. (an example can be found in the train_transformer.py)

@momo1986 there have been some improvements in memory management and dropout state sharing that may be helpful to you. You can try it out by installing the version 1.5.0b20190411 to try it out. If it still doesn't fit, you may need to reduce the batch size or use gradient accumulation to simulate large batch size. (an example can be found in the train_transformer.py)

Hello, @szha .
I try to build with mxnet1.5.
However, the problem is reported:
OSError: libcudart.so.9.2: cannot open shared object file: No such file or directory
I roll back to 1.4.
I tried with the command:
 python train_transformer.py --dataset WMT2014BPE                        --src_lang en --tgt_lang de --batch_size 128                      --optimizer adam --num_accumulated 16 --lr 0.01 --warmup_steps 4000                        --save_dir transformer_en_de_u512 --epochs 250 --gpus 0 --scaled                        --average_start 5 --num_buckets 20 --bucket_scheme exp --bleu 13a --log_interval 10  --num_accumulated 1
However, it failed with such stacks:

All Logs will be saved to transformer_en_de_u512/train_transformer.log
2019-05-05 15:39:53,193 - root - Namespace(average_checkpoint=False, average_start=5, batch_size=128, beam_size=4, bleu='13a', bucket_ratio=0.0, bucket_scheme='exp', dataset='WMT2014BPE', dropout=0.1, epochs=250, epsilon=0.1, full=False, gpus='0', hidden_size=2048, log_interval=10, lp_alpha=0.6, lp_k=5, lr=0.01, magnitude=3.0, num_accumulated=1, num_averages=5, num_buckets=20, num_heads=8, num_layers=6, num_units=512, optimizer='adam', save_dir='transformer_en_de_u512', scaled=True, src_lang='en', src_max_len=-1, test_batch_size=256, tgt_lang='de', tgt_max_len=-1, warmup_steps=4000.0)
Loading dataset...
Loading dataset...
Loading dataset...
terminate called after throwing an instance of 'dmlc::Error'
what():  [15:40:35] /home/travis/build/dmlc/mxnet-distro/mxnet-build/3rdparty/mshadow/mshadow/./stream_gpu-inl.h:182: Check failed: e == cudaSuccess CUDA: out of memory
Stack trace returned 10 entries:
[bt] (0) /usr/local/lib/python3.5/dist-packages/mxnet/libmxnet.so(+0x40123a) [0x7f8e1307123a]
[bt] (1) /usr/local/lib/python3.5/dist-packages/mxnet/libmxnet.so(+0x401851) [0x7f8e13071851]
[bt] (2) /usr/local/lib/python3.5/dist-packages/mxnet/libmxnet.so(+0x2c9f8d1) [0x7f8e1590f8d1]
[bt] (3) /usr/local/lib/python3.5/dist-packages/mxnet/libmxnet.so(+0x2ca0325) [0x7f8e15910325]
[bt] (4) /usr/local/lib/python3.5/dist-packages/mxnet/libmxnet.so(+0x2cb84e7) [0x7f8e159284e7]
[bt] (5) /usr/local/lib/python3.5/dist-packages/mxnet/libmxnet.so(+0x2cb8786) [0x7f8e15928786]
[bt] (6) /usr/local/lib/python3.5/dist-packages/mxnet/libmxnet.so(+0x2cb1bc4) [0x7f8e15921bc4]
[bt] (7) /usr/lib/x86_64-linux-gnu/libstdc++.so.6(+0xb8c80) [0x7f8e63863c80]
[bt] (8) /lib/x86_64-linux-gnu/libpthread.so.0(+0x76ba) [0x7f8e6876c6ba]
[bt] (9) /lib/x86_64-linux-gnu/libc.so.6(clone+0x6d) [0x7f8e684a241d]
Aborted (core dumped)

Thanks & regards!

Set both MXNET_GPU_MEM_POOL_TYPE=Round and MXNET_GPU_MEM_POOL_RESERVE=10

@momo1986

OSError: libcudart.so.9.2: cannot open shared object file: No such file or directory

This means the library didn't find cuda 9.2 in your path. Are you using cuda 9.2?

Hello, @szh
I affirm that my CUDA version is 9.0.
However, problem exists both for mxnet-cu92 and mxnet-cu90.

Traceback (most recent call last):
File "train_transformer.py", line 44, in
import mxnet as mx
File "/usr/local/lib/python3.5/dist-packages/mxnet/init.py", line 24, in
from .context import Context, current_context, cpu, gpu, cpu_pinned
File "/usr/local/lib/python3.5/dist-packages/mxnet/context.py", line 24, in
from .base import classproperty, with_metaclass, _MXClassPropertyMetaClass
File "/usr/local/lib/python3.5/dist-packages/mxnet/base.py", line 214, in
_LIB = _load_lib()
File "/usr/local/lib/python3.5/dist-packages/mxnet/base.py", line 205, in _load_lib
lib = ctypes.CDLL(lib_path[0], ctypes.RTLD_LOCAL)
File "/usr/lib/python3.5/ctypes/init.py", line 347, in init
self._handle = _dlopen(self._name, mode)
OSError: libnvrtc.so.9.0: cannot open shared object file: No such file or directory

@momo1986 the missing shared object file libnvrtc.so.9.0 is for NVRTC, which should be part of cuda 9.0 as shown in the doc. Also, mxnet-cu90 only works with cuda 9.0 and mxnet-cu92 only with cuda 9.2, so let's try not to mix them on the same system.
I know installing cuda can be tricky on some systems, and personally I find installing from the local runfile to be most reliable. Given that the symptom points to a problem in cuda installation, I'd recommend the following:

If possible, use CUDA 9.2 and mxnet-cu92.
If you don't have sudo access, make sure you work with you system admin on setting the right LD_LIBRARY_PATH. If you're sure the right path is included and it's still not working, notify the admin of the missing NVRTC problem to fix the CUDA installation.
If you have sudo access to the system, you can choose to reinstall CUDA. The CUDA 9.2 installation files can be found here
In case you follow the suggestion to use a local runfile, you will have the chance to specify the installation path. Be sure to note it down. Once you finish installation, you need to make sure that the lib64 directory in your installation path is specified in LD_LIBRARY_PATH variable.

Hope it helps. Feel free to let us know if you need more help. You can also join our slack channel (registration link) so that you may request help there..

@momo1986 did you get a chance to try out the above?

Closing due to lack of activity, feel free to reopen if you have more questions


Gstreamer 1.0 for gst_video?

Hi,
is there any particular restriction in baresip that requires gstreamer 0.10 for gst_video? What would be needed to port it to gstreamer 1.0?
Many thanks,
Thomas

Feel free to file a pull request with your update to gst 1.0.

we can upgrade modules gst.so and gst_video.so to Gstreamer 1.0
if that is someone we want/need.
Porting guide:
http://cgit.freedesktop.org/gstreamer/gstreamer/plain/docs/random/porting-to-1.0.txt
for porting to 1.0 I think we have 3 options:

upgrade to 1.0 and drop 0.10 support
upgrade to 1.0 and keep 0.10 support (compile-time switch)
do nothing (i.e. keep only 0.10 support).

What does people think ?

I made a small attempt here:
https://github.com/alfredh/baresip/tree/gstreamer-1.0
so far gst.so fails with "Internal data flow error."
if people are willing to work on this and provide patches, I shall gladly accept them!

Alfred E. Heggestad writes:

for porting to 1.0 I think we have 3 options:

upgrade to 1.0 and drop 0.10 support
upgrade to 1.0 and keep 0.10 support (compile-time switch)
do nothing (i.e. keep only 0.10 support).

What does people think ?

would be fine with me.

-- juha

I would prefer upgrading to 1.0 and keeping 0.10. It would be probably served best by renaming current gst module to "gst-0.10" and adding new "gst-1.0" module. I guess project's resources are limited, so I would probably suggest to leave gst-0.10 to rot and have it removed once someone notices that it doesn't build any more.

this is also possible :)

Voting for @czarkoff's option. 0.10 is ancient, and still I had a platform that required it not so long ago - the platform was also ancient, though.
The 1.0 module could be named just "gst"; otherwise we'll get stuck with the 1.0 name. For instance, GStreamer itself is at version 1.4 now, and still the packages everywhere have the confusing suffix "1.0".

does anyone have time to help out with porting the module gst.so and gst_video.so
to 1.0 ? I can take care of the final testing and merging into baresip tree.

I started porting the gst_video module to gst 1.0, but I haven't finished it, yet. It is hard for me to predict when I'll be done, but it might take a while.
A question that I have in that respect is whether there is a way to use DMABUF for passing the data from the camera to the encoder? I could build a gst encoding pipeline that reads from the camera device directly, but then so far I don't know how that would interfere with the other functionality of baresip. Any thoughts?

I think the first step should be to get something working, and then we can tune and optimize
after that.
Feel free to share your work-in-progress patch either here or on the re-devel
mailinglist :)

thanks to Thomas for the initial patch :)
after some trimming and tuning I managed to get the gst_video working with 1.0
https://github.com/alfredh/baresip/commit/1bde01b6cad76a558d06f702078a33e878b21ee7
some open issues:

is it necessary to have all these mutexes and conditionals to sync between the 2 threads?

the encode/pipeline_push function should not block, i.e. it should not call cond_wait.
the whole libre/baresip execution model is based on async I/O with small functions
running very fast and not blocking. If the GST encoder is very busy and the buffer
is full, I guess the only thing we can do is to drop raw frames from the camera ?

@alfredh, thank you very much for your efforts to port gst_video to 1.0!
My thoughts about the issues:

Looking at the interface to video codecs in general, as defined in "struct vidcodec", it seems as the async I/O is on the calling side of the interface. From my quick look into the other modules I thought that 'encupdh' and 'ench' are called asynchronously and 'fmtp_ench' and '	fmtp_cmph' are called synchronously from within 'ench'? So I just wonder why there should be another asynchronous coupling when calling into the gst_video module. You know the source better than me, so please correct me if I'm wrong. :) So if introducing another layer of asynchronous coupling, then I'm wondering about the calling of fmtp_ench/fmtp_cmph, that is for sending out the data after they left the encoder?

An interesting question about the async I/O system is, I guess, how the pipeline is managed, that is how information, e.g., for setting the framerate, is propagating upwards and downwards to the processing stages.
For example, I wonder whether it would be better to dynamically reduce or adapt the framerate when the encoder or sending stage can't keep up. Especially, the gst pipeline seems to assume a fixed framerate anyway, and I'm unsure how the pipeline is affected by simply not feeding enough data into it. The question how to manage the pipeline somehow relates back to the question how asynchronous or synchronous the pipeline is designed, and led me to step-lock 'ench' and gst so to not introduce a hidden, loose coupling within gst_video.

this commit should add the 2 new module gst1.so and gst_video1.so
you can build gst_video1.so by installing the correct gstreamer-dev header files,
or enable it explicitly:
$ make USE_GST_VIDEO1
Testing and feedback it welcome :)


Replace js.Value comparisons deprecated in Go 1.14

Replace js.Undefined() and js.Null() comparisons with IsUndefined() and
IsNull().
Description
Directly comparing js.Value instances to js.Undefined() and js.Null() was deprecated in Go 1.14. See: https://golang.org/doc/go1.14#wasm

@slugalisk Would you mind putting this behind Go versions? We can't break support for older versions of Go (yet)
thank you so much for the contribution :)

@Sean-Der Is this alright? Should Travis CI tests with 1.14 be added?

:fire:
@slugalisk I will merge, and update our testers later! I don't anticipate this being a huge pain point if it works for you locally, really appreciate the change :)

Opend a PR to upgrade Go versions on CI: https://github.com/pion/.goassets/pull/15


Debug Node: TypeError: Cannot read property 'name' of undefined

There is a case where the debug node will throw TypeError: Cannot read property 'name' of undefined
A test case involves the httpInMultipart node:
[
{
"id": "499fe21f.f66814",
"type": "httpInMultipart",
"z": "c8dc8a91.74103",
"name": "OTA Firmware",
"url": "/esp8266-ota/upload",
"method": "post",
"fields": "[{ "name": "firmware"}]",
"swaggerDoc": "",
"x": 155.5,
"y": 811,
"wires": [
[
"eeb8fd90.56a408",
"ff8b5370.8bcc78"
]
]
},
{
"id": "ff8b5370.8bcc78",
"type": "debug",
"z": "c8dc8a91.74103",
"name": "files",
"active": true,
"console": "true",
"complete": "req.files",
"x": 735.5,
"y": 800,
"wires": []
}
]
The debug node is set to display msg.req.files which is an array of objects containing the files received.
In debug.js, the error is thrown at:
function sendDebug(msg) {
....
msg.format = msg.msg.constructor.name || "Object";
msg.msg is the output, in this case msg.req.files (Note: the name msg refers to different objects)
msg.req.files.constructor is 'undefined' and therefore does not have a property 'name' - javascript throws an exception rather than return 'undefined' like it would for a defined object.

Fix:
        try {
            msg.format = msg.msg.constructor.name;
        } catch (e) {
            msg.format = "Object";
        }


fix: 4337 issues

What it solves
Resolves https://github.com/safe-global/safe-core-sdk/issues/903

paymasterAndData issues solved as well here https://github.com/safe-global/safe-eth-py/pull/1210

Pull Request Test Coverage Report for Build<PHONE_NUMBER>
Details

3 of 4 (75.0%)  changed or added relevant lines in 2 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage increased (+0.2%) to 74.631%

Changes Missing Coverage
Covered Lines
Changed/Added Lines
%

packages/relay-kit/src/packs/safe-4337/Safe4337Pack.ts
1
2
50.0%

Totals

Change from base Build<PHONE_NUMBER>:
0.2%

Covered Lines:
789

Relevant Lines:
987

💛  - Coveralls


Fetch libzcash dependencies from zcash

STEPS TO REPRODUCE

Look inside the Cargo.toml file.
Look for the following lines

zcash_client_backend = {git = "https://github.com/gmale/librustzcash", branch = "autoshield-poc-daa-taddr3"}
zcash_client_sqlite = {git = "https://github.com/gmale/librustzcash", branch = "autoshield-poc-daa-taddr3"}
zcash_primitives = {git = "https://github.com/gmale/librustzcash", branch = "autoshield-poc-daa-taddr3"}
zcash_proofs = {git = "https://github.com/gmale/librustzcash", branch = "autoshield-poc-daa-taddr3"}

RESULTS
Expected
The dependencies should probably be fetched from the repo https://github.com/zcash/librustzcash.git.
Actual
Dependencies are being fetched from a fork of the zcash repo.

This is the branch it should point to
zcash_client_backend = {git = "https://github.com/nuttycom/librustzcash", branch = "autoshield-poc-daa" }
until this is merged https://github.com/zcash/librustzcash/pull/341

see https://github.com/zcash/zcash-android-wallet-sdk/issues/363


How to show button fold code (-) and (+) by default?

Hi, please check this image :)
http://i.imgur.com/AeAPvv3.png

Not sure what the question is, please clarify. You can enable/disable folding with the "editor.folding" setting.

@chrmarti, I think that @ttn10 has in mind: show [-] and [+] buttons always without mouse Hover.

Yes, i want to always  show [-], current [-] show only via hover
default, [+] always show when user click to [-]

fyi @aeschli

duplicate of #3911


How to Convert  modin.pandas.DataFrame to pandas.DataFrame

How to Convert  modin.pandas.DataFrame to pandas.DataFrame

This is not part of the API as pandas.DataFrame, naturally, does not posses such a method.
You can use the private method DataFrame._to_pandas() to do this conversion.
If you would like to do this through the official API you can always save the Modin DataFrame to storage (csv, hdf, sql, ect) and then read it back using Pandas. This will probably be the safer way when working big DataFrames, to avoid out of memory issues.

Thanks!

how about reading a data frame into a modin data frame ?

@Vaderv if you have a pandas.DataFrame object, you can call Modin DataFrame constructor and it will be handled for you:
import pandas
import modin.pandas as pd

# have a pandas.DataFrame object called `pandas_df`
modin_df = pd.DataFrame(pandas_df)

It is as easy as that 😄

@devin-petersohn actually when I do what you suggest I get a "(<class 'AttributeError'>, AttributeError("module 'modin' has no attribute 'DataFrame'"), <traceback object at 0x7fd3f3560100>)", is it deprecated ?

Ummm, @devin-petersohn, aren't you answering the opposite question?
I guess it is not part of the pandas API. Very weird. . . . The logical df2 = pandas.DataFrame(df1) doesn't work as would be expected (copy constructor pattern). (I understand that .copy() can be used)
I just wanted to simply test if the following is also broken in pandas. Maybe it is, since that is supposed to be the fallback.
(I guess I'll have to do something like pandas.read_csv(. . . nrows=9), to test)
In [437]: type(df2)
Out[437]: modin.pandas.dataframe.DataFrame
In [438]: category_hdrs[:9]
Out[438]: ['A1_1', 'A1_2', 'A1_3', 'A1_4', 'A1_5', 'A2b', 'A3', 'A3b', 'B2b']
# a proper subset of all columns
In [439]: df2.dtypes[:9]
Out[439]:
StartDatetime    datetime64[ns]
EndDatetime      datetime64[ns]
A1_1                    float64
A1_2                    float64
A1_3                    float64
A1_4                    float64
A1_5                    float64
A2                      float64
A2b                     float64
dtype: object
In [440]: df2[category_hdrs] = df2[category_hdrs].astype('category')
UserWarning: DataFrame.setitem_unhashable_key defaulting to pandas implementation.
UserWarning: Distributing <class 'pandas.core.frame.DataFrame'> object. This may take some time.
In [441]: df2.dtypes[:9]
Out[441]:
StartDatetime    datetime64[ns]
EndDatetime      datetime64[ns]
A1_1                    float64
A1_2                    float64
A1_3                    float64
A1_4                    float64
A1_5                    float64
A2                      float64
A2b                     float64
dtype: object

Maybe modin is using an older pandas version?
In [444]: modin.version
Out[444]: '0.9.1'
In [445]: pandas.version
Out[445]: '1.2.3'
Anyway, .apply(lambda . . . ) also is not apparently implemented, either. So . . . simple basic things . . . not possible.

@bdklahn Please review our code of conduct and make sure any future messages follow it: https://github.com/modin-project/modin/blob/master/CODE_OF_CONDUCT.md. Comments should be respectful and constructive.
The comment by @eavidan above answers the question. If you follow the entire thread, my comment is answering a follow-up question.
If you are running into an issue, please open a new issue. It more helpful to others looking for answers to questions to create another issue. apply is implemented, so please open a new issue if you have run into some problem. We also accept external contributions, and I'm happy to point you to the code where you can contribute a fix.

@devin-petersohn , Sorry about that. I edited my comment accordingly.
I agree with the practice of opening a new issue, and I probably should have done that. Sorry about that, too. I also should have more carefully read the comment by @Vaderv, to note it should be a treated as separate issue.
It's probably best not to actively encourage that by answering questions about an unrelated issue, in this issue's thread. It can be confusing for people, and make it hard to track everything which needs to be addressed relative to a repo.
Here's to hoping you will be "Gracefully accepting constructive criticism". :-)
https://github.com/modin-project/modin/blob/master/CODE_OF_CONDUCT.md


the breakpoint dose't work  in the debugging of c++

Issue Type: Bug
the breakpoint dose't work  in the debugging of c++.
my launch.json is as follow.
{
    "version": "0.2.0",
    "configurations": [
        {
            "name": "(gdb) Launch",
            "type": "cppdbg",
            "request": "launch",
            "program": "${workspaceFolder}/bin/${fileBasenameNoExtension}.out",
            "args": [],
            "stopAtEntry": true,
            "cwd": "${workspaceFolder}",
            "environment": [],
            "externalConsole": false,
            "MIMode": "gdb",
            "preLaunchTask": "build",
            "setupCommands": [
                {
                    "description": "Enable pretty-printing for gdb",
                    "text": "-enable-pretty-printing",
                    "ignoreFailures": false
                }
            ]
        }
    ]
}

my tasks.json
{
    // See https://go.microsoft.com/fwlink/?LinkId=733558
    // for the documentation about the tasks.json format
    "version": "2.0.0",
    "tasks": [
        {
            "label": "build",
            "type": "shell",
            "command": "",
            "args": [
                "g++","-g", "${relativeFile}", "-o","${workspaceFolder}/bin/${fileBasenameNoExtension}.out", "&&", "clear"],

           // "args": ["g++","-g", "${relativeFile}", "-o","${workspaceFolder}/bin/${fileBasenameNoExtension}.out"],
            "group": {
                "kind": "build",
                "isDefault": true
            },
            "problemMatcher": {
                "owner": "cpp",
                "fileLocation": ["relative", "${workspaceRoot}"],
                "pattern": {
                    "regexp": "^(.*):(\\d+):(\\d+):\\s+(warning|error):\\s+(.*)$",
                    "file": 1,
                    "line": 2,
                    "column": 3,
                    "severity": 4,
                    "message": 5
                }

            }
        }
    ]
}

I can only click the pause button when i was debugging.  I think that maybe my configurations have a litter question,but i can't  address it by myself. I searched it in the Internet but I have not found a effective solution.
VS Code version: Code 1.29.0 (5f24c93878bd4bc645a4a17c620e2487b11005f9, 2018-11-12T07:42:27.562Z)
OS version: Linux x64 4.15.0-29deepin-generic

System Info

Item
Value

CPUs
Intel(R) Core(TM) i5-3210M CPU @ 2.50GHz (4 x 2893)

GPU Status
2d_canvas: enabledchecker_imaging: disabled_offflash_3d: enabledflash_stage3d: enabledflash_stage3d_baseline: enabledgpu_compositing: enabledmultiple_raster_threads: enabled_onnative_gpu_memory_buffers: disabled_softwarerasterization: disabled_softwarevideo_decode: unavailable_softwarevideo_encode: unavailable_softwarewebgl: enabledwebgl2: enabled

Load (avg)
2, 2, 1

Memory (System)
7.67GB (0.76GB free)

Process Argv
--unity-launch

Screen Reader
no

VM
0%

Extensions (3)

Extension
Author (truncated)
Version

code-runner
for
0.9.5

vscode-language-pack-zh-hans
MS-
1.30.2

cpptools
ms-
0.20.1

(1 theme extensions excluded)

@Sologala please report the issue against the cpptools extension.


cmd/go: clarify the impact of the -tags flag on test/build caching

What version of Go are you using (go version)?

$ go version
go version devel +4b3f04c

Does this issue reproduce with the latest release?
Yes.
What operating system and processor architecture are you using (go env)?
go env Output
$ go env
GOARCH="amd64"
GOBIN=""
GOCACHE="~/.cache/go-build"
GOEXE=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOOS="linux"
GOPATH="~"
GOPROXY=""
GORACE=""
GOROOT="~/go"
GOTMPDIR=""
GOTOOLDIR="~/go/pkg/tool/linux_amd64"
GCCGO="gccgo"
CC="gcc"
CXX="g++"
CGO_ENABLED="1"
GOMOD=""
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="pkg-config"
GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build224479533=/tmp/go-build -gno-record-gcc-switches"

What did you do?
Read the documentation for build/test caching from go help test. Then
$ go test -tags noasm gonum.org/v1/gonum/mat
ok  	gonum.org/v1/gonum/mat	44.695s
$ go test -tags noasm gonum.org/v1/gonum/mat
ok  	gonum.org/v1/gonum/mat	(cached)

From this it's clear that -tags is not counted in test flags (and this is reasonably given the wording).

What did you expect to see?
No caching.
What did you see instead?
Happily, caching.
While the wording is consistent with the apparent intended meaning, it could be made clearer that build flags do not impact on caching for tests (if this is true - I could find no mention of caching in go help build or go help install or mention of which flags prevent caching (other than -a in  go help cache)).

If no one is working on this, I can take a go updating the ‘go help build’ and ‘go help install’ documentation.  Please let me know if it makes sense to update any other help commands output.

@christopherdiehl, you're welcome to take this if you like.
The paragraph about test caching and uncacheable flags is here, and probably the fix is to clarify that all build flags are cacheable.


How to get JSON/POJO from the KustoResultSetTable

I want to get JSON object or array of JSON POJO objects on the query returning multiple rows. I am not comfortable with iterating each row one by one and creating those manually.

Either way you will have to create the objects - the rows we get from the server are arrays, and someone has to merge them with the columns.
We don't have anything like this built in, but you can use getData() to easily do it yourself -
KustoOperationResult completeResult= queryClient.execute(<databaseName>, <your query>);
KustoResultSetTable mainTableResult = completeResult.getPrimaryResults();
List<Map<String, Object>> resultMap = mainTableResult.getData()
        .stream().map(row ->
                IntStream.range(0, row.size()).
                        mapToObj(ir -> new AbstractMap.SimpleEntry<>(mainTableResult.getColumns()[ir].getColumnName(), row.get(ir)))
                        .collect(Collectors.toMap(Map.Entry::getKey, Map.Entry::getValue)))
                        .collect(Collectors.toList());

JSONArray jsonArray = new JSONArray(resultMap);

Hi @saumilsdk,
We implemented executeToJsonResult() to bypass the conversion to KustoResultSetTable in the first place. It returns the json as a String, intended for specific performance scenarios.
That said, our service returns results in this KustoResultSetTable format, so the json will still need to be parsed to obtain the POJO components of it.
I want to understand your issue better, though. What do you mean by, "I am not comfortable with iterating each row one by one and creating those manually"? What exactly is the concern with working with a KustoResultSetTable object? Note that we have examples of working with results.


Add copy, clone, and debug derives to cubic spline structs

Objective
Fixes #13190

Whoops, didn't think I'd need to run the lints...


son-gtksrv is not pointing to new catalogues url

We have this configuration:
CATALOGUES_URL: http://{{ public_ip }}:4002/catalogues

We need to change it for this:
CATALOGUES_URL: http://{{ public_ip }}:4002/catalogues/api/v2

grep -rl '4002/catalogues' | xargs sed -i 's/4002/catalogues/4002/catalogues/api/v2/g'


Pass kwargs into shouldSendCallback() as param

In the shouldSendCallback function, we need the args in order to determine whether we want to send to sentry based on the current data. This is exactly how things work for the JavaScript client version of raven.

Whoops, good catch, thanks!

Awesome. Can you publish a new version of the library to npm?

@jeffwhelpley published in 1.1.2, sorry for the delay!


NEO Hub, Engineering Site Provisioning Failed

Describe the issue
Engineering site provisioning failed, though the hub and Sales were successful.
"Your request to provision"New Employee Onboarding Hub"template failed!Please report the issue here providing the following provisioning action correlation ID: cdd60cab-a043-4359-aa54-8362dae6b232 !"
Expected behavior
Hub and both Sales and Engineering sites would provision successfully.
Screenshots
N/A
Details (please complete the following information):

PnP Correlation ID: cdd60cab-a043-4359-aa54-8362dae6b232
Reference Template: https://lookbook.microsoft.com/details/75e60a32-9849-4ed4-b83e-b2b08983ad19
Primary language of the target tenant: English
Are you using a Tenant Global Admin account to provision the template: Yes

Additional context
First template I've tried to provision.

Hi,
Thanks for using the Look Book site. Based on the event log, you provisioned the same template, targeting the same site URL at the same time, and the service does not support concurrent provisioning of the same template with the same URL. Please try again, avoiding concurrent provisionings.

Hi,
Thanks for using the Look Book site. Based on the event log, you provisioned the same template, targeting the same site URL at the same time, and the service does not support concurrent provisioning of the same template with the same URL. Please try again, avoiding concurrent provisionings.

Hello Paolo,
Hmm, I wonder how that happened.  I remember going to the provisioning
screen, looking at options and going to other screens and coming back, but
I thought I only provisioned once.
Thank you for the response!
-Steve
On Tue, Jan 26, 2021 at 11:55 AM Paolo Pialorsi<EMAIL_ADDRESS>wrote:

Hi,
Thanks for using the Look Book site. Based on the event log, you
provisioned the same template, targeting the same site URL at the same
time, and the service does not support concurrent provisioning of the same
template with the same URL. Please try again, avoiding concurrent
provisionings.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/SharePoint/sp-provisioning-service/issues/385#issuecomment-767679908,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AFMYDIRK53WFR6DVNW2PEX3S33XYZANCNFSM4WTWLNAA
.

Hello Paolo,
Hmm, I wonder how that happened.  I remember going to the provisioning
screen, looking at options and going to other screens and coming back, but
I thought I only provisioned once.
Thank you for the response!
-Steve
On Tue, Jan 26, 2021 at 11:55 AM Paolo Pialorsi<EMAIL_ADDRESS>wrote:

Hi,
Thanks for using the Look Book site. Based on the event log, you
provisioned the same template, targeting the same site URL at the same
time, and the service does not support concurrent provisioning of the same
template with the same URL. Please try again, avoiding concurrent
provisionings.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/SharePoint/sp-provisioning-service/issues/385#issuecomment-767679908,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AFMYDIRK53WFR6DVNW2PEX3S33XYZANCNFSM4WTWLNAA
.


Query in getIfExists mode should return null/undefined when requested object does not exist

Expected Behaviour
Using a QueryDef in getIfExists mode should return null/undefined when requested object is not found.
Actual Behaviour
Currently returns {}

Sample code
const queryDef = {
"@schema": "nms:extAccount",
"@operation": "getIfExists",
"select": {
"node": [
{ "@expr": "@id" },
{ "@expr": "@name" }
]
},
"where": {
"condition": [
{ "@expr": "@name='not_found'" }
]
}
};
const query = NLWS.xtkQueryDef.create(queryDef);
const extAccounts = await query.executeQuery();
console.log(extAccounts);

Fixed in https://github.com/adobe/acc-js-sdk/commit/b48e22f5ab93c17210ec07b74c77e30b0b1b39db (version 0.1.3)


AWSBatch Generic Configuration Profile

This adds a generic AWSBatch configuration profile that allows the users to specify required parameters

Job Queue
AWS Region

Additionally, I implemented a small check next to the UPPMAX sanity checking to check for the existence of these mandatory parameters when running on the "awsbatch" profile, so users get a warning to set these params on AWSBatch properly.
Let me know if that makes sense - happy to polish this further if someone has suggestions!

Really nice stuff 😁 🎉

Looking great! Now it just needs some documentation 😉
Fine if you make an issue for that and do it separately though.

I added some notes on the command lines at least - will publish a proper blog post on detailed steps to get AWSBatch running (including all steps from zero - running) in the next days with my master student. Plus, I guess we can document the general approach in cookiecutter and also make sure that all pipelines benefit from that documentation?

Will furthermore add a PR to cookiecutter later today...


Document key values

Is your feature request related to a problem? Please describe.
I had to read the source code to figure out what values I could pass in for the key.
Describe the solution you'd like
I would like the documentation to link to https://developer.mozilla.org/en-US/docs/Web/API/UI_Events/Keyboard_event_key_values This lists all possible key values.
Describe alternatives you've considered
n/a
Additional context
n/a

There is a link to [https://developer.mozilla.org/en-US/docs/Web/API/UI_Events/Keyboard_event_key_values](that MDN page) under the section [https://github.com/RobertWHurst/Keystrokes#binding-keys-and-key-combos](Binding Keys and Key Combos) in the readme. Perhaps I'll make this more prominent in the readme.

I've updated the readme to better highlight the link to the MDN page.


Reportback item status params update

Fixes #5653
What's this PR do?
This PR provides a level of data security based on user permissions. Prior to this PR, all (or some) status types for Reportback Items could be requested by passing a URL parameter ?status=pending,flagged,excluded,promoted,approved by an anonymous GET request.
This PR updates the API so that if an anonymous user is requested restricted statuses of pending, flagged or excluded, those types get filtered out and the request responds with no items and an error response or just providing promoted and/or approved items (depending if those were also requested). Now only admin users have access to request those status types.
This PR also updates the default status value to be both promoted and approved.
Where should the reviewer start?
The main logic happens in dosomething_reportback_item.query.inc
How should this be manually tested?
If you want, pull down the branch and then hit the /reportback_items endpoint and pass some restricted statuses in query URL parameters while in incognito browser mode and see if any results show up that shouldn't.

@aaronschachter
cc: @angaither @jonuy

Looks ok to me :elephant: :+1: :iphone:


Debugger does not stop for uncaught Python exceptions raised from native code

From @zneak on August 3, 2017 0:9
Environment data
VS Code version:  Version 1.14.2 (1.14.2)
Python Extension version:  0.6.9
Python Version:   Python 2.7.10
OS and version:    macOS Sierra 10.12.4
Actual behavior
The debugger does not stop when an uncaught exception is raised from native code, even if the breakpoint on "uncaught exceptions" is set.
Expected  behavior
The debugger should probably stop wherever looks the most appropriate (probably on the most recent Python stack frame).
Steps to reproduce:

Install Cython
Create an "ext.pyx" file that only contains raise KeyError("oopsie")
Build extension with Cython, then copy the shared object to a place that you can easily import it from (like the source folder)
From VS Code, create and run a Python script that imports said extension

Logs
Output from Python output panel: (traceback ...)
Output from Console window (Help->Developer Tools menu): (empty)
Copied from original issue: DonJayamanne/pythonVSCode#1137

From @zneak on August 3, 2017 0:15
Looks like the debugging support comes from IPython. Let me know if I should see help there instead.

This may or may not be related, but the debugger seems to get detached when I make it to the except statement.
Version 1.19.0
Commit 816be6780ca8bd0ab80314e11478c48c70d09383
Date 2017-12-14T12:06:43.492Z
Shell 1.7.9
Renderer 58.0.3029.110
Node 7.9.0
Architecture x64
Python extension version: 0.91
Python Version 3.6.0

@zneak
I've got some great news for you. We've been actively working on a new debugger for the python extension and believe this feature works in that experimental debugger.
Please ensure you have the latest version of the python extension and

Test this using the Experimental debugger.
Or just change the setting "type":"python" in launch.json to "type":"pythonExperimental"

Do let us know how this goes.


Automatic Semantic Versioning

Part of release management - should give us more confidence in our deployments and compatibility with the app and the portal.

This would be solved as part of the work for adding the change log, probably two days combined.

Closed in favour of #264


Deprecate sub par registries, stores and caches

We learned that some implementations do not scale in a kubernetes cluster. We should mark them as deprecated and log a warning? when they are configured. Preferably, before the ocis 5 release.

why not deprecate all except the ones we know that are reliably working / are proven to be scalable?
I know following to work as of oCIS 4:

registry: etcd
cache: redis
store: redis

For oCIS 5 I don't have these information yet.

I would leave:

registry:

memory, for testing
nats, because it is the only built in registrd that works with the cli
etcd, because it works
get rid of consul (unused) and kubernetes (too slow)

store/cache:

memory, for testing
noop, used - actually we should rip out the code where we use noop, eg the gateway registry, but that is a different issue
redis, because it works
redis-sentinel, needed for scaling redis
nats-js, for a build in implementation
get rid of ocmem (unused? or move to micro?)

so ... we can only really deprecate the consul and kubernetes registries and ocmem store?

nats, because it is the only built in registrd that works with the cli

you mean natsjs right?

noop

I didn't think about this as a actual cache / store implementation, but obviously it is :laughing: We're actually using it for PROD purposes in the Helm Chart like you said

redis, because it works

how do you know that? I though we've always used redis-sentinel

redis-sentinel, needed for scaling redis

actually it's only HA (failover) not scaling

I propose:

registry (MICRO_REGISTRY): ~nats~, ~kubernetes~, ~etcd~, ~consul~, ~memory~, natsjs (default)
cache / store (OCIS_CACHE_STORE): memory, ~ocmem~, ~etcd~, ~redis~, redis-sentinel, nats-js (default), ~noop~

ahhh I don't know if we can really get rid of noop...

on question to ask if we really should keep memory or ocmem. Isnt  ocmem` the more advanced implementation (max number of keys limit, TTL, ...)?

@butonic @wkloucek @micbar one thing open to discuss: Do we want to keep supporting etcd?

As a sidenote: using the graph api as a provisioning api requires setting the services registry to something non-external, eg memory.
The same applies when you plan to run the webfinger service standalone (without oCIS proxy)

@tbsbdr @dragotin @micbar
Can I ask for a product decision on that? We have a Training next week and don't want to mention unsupported components. :THX:

we still support a lot of registry implementations:
	rRegistry "github.com/cs3org/reva/v2/pkg/registry"
	consulr "github.com/go-micro/plugins/v4/registry/consul"
	etcdr "github.com/go-micro/plugins/v4/registry/etcd"
	kubernetesr "github.com/go-micro/plugins/v4/registry/kubernetes"
	mdnsr "github.com/go-micro/plugins/v4/registry/mdns"
	memr "github.com/go-micro/plugins/v4/registry/memory"
	natsr "github.com/go-micro/plugins/v4/registry/nats"
	"github.com/owncloud/ocis/v2/ocis-pkg/natsjsregistry"

The default now is nats-js-kv
the available cache implementations are defined in reva/pkg/store:
	// TypeMemory represents memory stores
	TypeMemory = "memory"
	// TypeNoop represents noop stores
	TypeNoop = "noop"
	// TypeEtcd represents etcd stores
	TypeEtcd = "etcd"
	// TypeRedis represents redis stores
	TypeRedis = "redis"
	// TypeRedisSentinel represents redis-sentinel stores
	TypeRedisSentinel = "redis-sentinel"
	// TypeOCMem represents ocmem stores
	TypeOCMem = "ocmem"
	// TypeNatsJS represents nats-js stores
	TypeNatsJS = "nats-js"
	// TypeNatsJSKV represents nats-js-kv stores
	TypeNatsJSKV = "nats-js-kv"

@butonic i think we decided that we only keep nats-js-kv and memory as registries.
and redis-sentinel and nats-js-kv and noop as a cache store.

Docs have been done with 5.0.0 Release.


Hyper-parameters for loss

Hi,
Thank you for your paper and your code.
I see you use:

ans_lambda = 1
type_lambda = 1
para_lambda = 1
sent_lambda = 5
ent_lambda = 1

Would you mind to share your motivations/reasons for why do you choose these numbers? Or you obtain it via experiments?
Thank you for your support.

Sorry for the late response. The motivation behind this is that these can be hyper-parameters to tune, but in our experiments we simply search sent_lambda {1, 3, 5} as supporting facts is the required task and this loss converge to small value quickly. For others, we just use 1 and haven't tuned on that.

Oh, thank you for your response.


Update tut-plugin to 0.6.12

Updates org.tpolecat:tut-plugin from 0.6.11 to 0.6.12.
I'll automatically update this PR to resolve conflicts as long as you don't change it yourself.
If you'd like to skip this version, you can just close this PR. If you have any feedback, just mention @scala-steward in the comments below.
Have a nice day!

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

labels: semver-patch

What fresh hell caused this breakage, hmm...

Some compiler bullcrap:
[error] (run-main-0) java.lang.VerifyError: class scala.tools.nsc.Global overrides final method isDeveloper.()Z
[error] java.lang.VerifyError: class scala.tools.nsc.Global overrides final method isDeveloper.()Z

Restarted the workflow.

Yeah it's because of sbt-1.3.0-RC1. Somehow this binary issue with tut always comes back. I reported it here: https://github.com/tpolecat/tut/issues/252


⚠ Spryr has degraded performance

In 44c8dfe, Spryr (https://spryr.com) experienced degraded performance:

HTTP code: 200
Response time: 3693 ms

Resolved: Spryr performance has improved in a76bc28 after 7 minutes.


Unable to dismiss the keyboard using CardField

Describe the bug
There is no way to dismiss the keyboard (by pressing "Done", or taping away) using the CardField component from what I can tell. This is the same behavior in the example project as well.
To Reproduce
Steps to reproduce the behavior:

Use the CardField component on a screen
Tap into the field to open the keyboard

Expected behavior
A user can easily dismiss the keyboard.

Hi, thanks for flagging.
Yeah it is because internal react-native behaviors work only with build-in TextInput component https://github.com/facebook/react-native/blob/174753600778675c8b0e7d341b6044192af68d00/Libraries/Components/ScrollView/ScrollView.js#L1380
In this case we have to handle it manually, so we need to track screen interactions and dismiss the keyboard if needed. To achieve this I propose to that stripe sdk will expose extra UI component which will take care of it. To use it you will have to wrap your entire screen where is the CardInput with our component.
cc @thorsten-stripe

Can anyone provide more information as how we dismiss the keyboard, because I am searching for it, is there any property or method we need to call in order to dismiss keyboard.

you have to wrap your screen with <StripeContainer /> component

If I understand properly, you mean to say

First I have to import StripeContainer component like this import { StripeContainer } from "@stripe/stripe-react-native"
Then wrap screen with  like below

<StripeContainer>
	<SafeAreaView>
		<ScrollView>
			<View>
				<CardField
					postalCodeEnabled={false}
					placeholder={{
						number: "4242 4242 4242 4242",
					}}
					cardStyle={{
						backgroundColor: "#FFFFFF",
						textColor: "#000000",
					}}
					style={{
						width: "100%",
						height: 50,
						marginVertical: 30,
						borderWidth: 1,
						borderColor: "#000",
					}}
					onCardChange={(cardDetails) => {
						setCard(cardDetails);
					}}
					onFocus={(focusedField) => {
						console.info("focusField", focusedField);
					}}
				/>
			</View>
		</ScrollView>
	</SafeAreaView>
</StripeContainer>

But above code is not working and I am also not able to get StripeContainer from @stripe/stripe-react-native like below.
import { StripeContainer } from "@stripe/stripe-react-native"
Version "@stripe/stripe-react-native": "^0.1.2"

@smeetagrawal StripeContainer has been added here (https://github.com/stripe/stripe-react-native/pull/260) and will be available starting v0.1.3. If you need it earlier, you can clone down the master branch and build and install the library locally: https://github.com/stripe/stripe-react-native/blob/master/CONTRIBUTING.md#install-library-as-local-repository

Is there any way to call endEditing on ios manually? Our use case involves custom bottom sheet (where CardField is rendered and we want to close the keyboard when bottom sheet is dismissed.

Does anyone have any ideas on how to dismiss the keyboard without the press triggering something else?
We have the CardField in a scrollview containing other payment methods (things like loyalty points), and if you click off to dismiss the keyboard it is very easy to accidentally swap the payment method for something else.
The best I can come up with so far is to track when the field is in use and disable the all of the other elements on screen

@cinnabarcaracal thanks for outlining your workaround. I've copied this to the onBlur issue.

Hi everyone! I'm still not able to resolve this, I've a modal with a TextInput from react-native and a  coming from @stripe/stripe-react-native v0.1.4. When you focus the   and then press somewhere else, the keyboard dismisses correctly. but this doesn't happen with the . Is there any way to resolve this? I tried wrapping the view with a < StripeContainer /> but that didn't work.
Thanks so much everyone!
https://user-images.githubusercontent.com/35921850/133979529-75ea9742-a096-4293-9dc8-fa8b1ddfb6ee.mov

Having the same issue. I'm unable to hide the keyboard. Not with Keyboard.dismiss(), not with StripeContainer .. not with anything.

@johanjq You need to add keyboardShouldPersistTaps="never" to <StripeContainer /> in order for the keyboard to get dismissed.
It defaults to always, which is wrong in my opinion.

am also not able to get StripeContainer from @stripe/stripe-react-native like below. import { StripeContainer } from "@stripe/stripe-react-native"
Version "@stripe/stripe-react-native": "^0.1.2"
It will be good, If you can send any reference for dismissing keyboard when click outside of CardField, Because I am not able to get any working example yet.

It's just boolean
<StripeContainer keyboardShouldPersistTaps={false}>

For bottomsheetmodal
Use the CardForm ref to control keyboard dismiss.
`
const cardRef = useRef<CardFormView.Methods>(null)
const [cardFocus, setCardFocus] = useState(false);
<Pressable
onPress={() => {
if (cardFocus) {
cardRef.current?.blur()
setCardFocus(false);
}
}}

....other view components
<Pressable onPress={() => {
if (!cardFocus) {
cardRef.current?.focus()
setCardFocus(true)
}
}}>

`


Adds noDraw atlas function

Handles empty scene shadowing using shadow atlas

It's not clear why we need to do something when we dont draw, could you have a look plz, maybe it's not needed ?

documented how/what/why empty scene are handled that way
added case of empty scene
renamed few method for clarity
removed useless uniform change in the no scene case


Enhancement for digital product inventory

This is the PR I talked about in #97
Note that this includes what's been done in #96.
Merging this should wait until that is in, or if that will not be pulled some code in this should change, namely the migrations for ProductPartRecord

I removed the "dependency" on #96 by rebasing on the master branch, so this does not require the part that's been done to convert all prices to decimal

Can you also resolve conflicts? I can't merge it as it is. Thanks!

It should be fine now

Thanks!


Help improve Syntax Highlight for Monaco-Editor

Hello.
I try add good support for editor - Monaco-editor (this is part of VS for example)
https://github.com/microsoft/monaco-editor/issues/4309
can anyone help improve support or I think - official support for editor like Monaco - true way

Sorry, this isn't something we have resources available for.


Breakpoints don't pick up noSwiping

Hello,
Great library! Thanks so much!
I have a carousel that displays differently using the breakpoints object. However, the noSwiping: bool within the breakpoints objects is not being picked up. noSwiping will only register if it is placed at the root of the object.
Works (though noSwiping is set for all breakpoints):
const config = {
  centeredSlides: true,
  noSwiping: true,
  rebuildOnUpdate: true,
  slidesPerView: 1.2,
  spaceBetween: 16,
  breakpoints: {
    [breakpoints[0]]: {
      slidesPerView: 1.5,
      spacebetween: 16
    },
    [breakpoints[1]]: {
      slidesPerView: 3,
      spaceBetween: 26,
      centeredSlides: false
    }
  }
}

Doesn't work (for any breakpoints):
const config = {
  centeredSlides: true,
  rebuildOnUpdate: true,
  slidesPerView: 1.2,
  spaceBetween: 16,
  breakpoints: {
    [breakpoints[0]]: {
      slidesPerView: 1.5,
      spacebetween: 16,
      noSwiping: false,
    },
    [breakpoints[1]]: {
      slidesPerView: 3,
      spaceBetween: 26,
      centeredSlides: false,
      noSwiping: true
    }
  }
}

Is this a known issue or is there any way around it?

I just realized that I was dealing with inheritance from breakpoints, my bad!

Why is this issue closed? I have the same problem...


Review accessibility of images and icons used in Halstack components

Should we use alt if the image goes together with a label?
Should we ask for the alt attribute as a component prop?

This issue continues here: https://github.com/dxc-technology/halstack-react/issues/1449.


Network error when setting new password

Steps to reproduce:

Docker install Rancher (master-head, commit 7738b256d):
2021/07/27 19:48:00 [INFO] Rancher version 7738b256d (7738b256d) is starting
Visit the UI and provide the initial password
On the following page, provide new passwords
Agree to the Terms and Conditions, check the box
Click Continue

Actual Results:
A message saying "Network Error" is displayed.

This one is proving difficult to reproduce with the steps I described above. Therefore I must conclude that I did something additional to induce the condition. I'll spend some time to see if I can recreate the original conditions. If not, I'll close the issue :-/

After giving it a strong try, the problem no longer seems reproducible ever since I killed and restarted the container. Going to close this issue, but it can be reopened in the future if it becomes reproducible.


De-structuring arguments array generates invalid ES5 code

TypeScript Version:  2.9.0-dev.20180323, 2.7.2

Search Terms: arguments.slice destructuring allowJs
Code
test.js:
function f() {
        const [first, ...rest] = arguments;
}

$ mkdir out
$ tsc test.js --allowJs --outDir out/

Expected behavior:
ES5 code is generated where arguments is converted to an array, then sliced.
Actual behavior:
No errors or warnings.
out/test.js:
function f() {
    var first = arguments[0], rest = arguments.slice(1);
}

Problem: slice is not a method on arguments.
Playground Link:
http://www.typescriptlang.org/play/#src=function f() {
    const [first%2C ...rest] %3D arguments%3B
}
Related Issues:
https://github.com/Microsoft/TypeScript/issues/3219

That's a compile error though - Type 'IArguments' is not an array type.

That's a compile error though

Note however that this is compiled with the allowJs option, and that the input is valid javascript.

That's true, but we don't guarantee that transpilation will always work in the presence of compile errors. Similarly, for (const key of new Map([["1", "2"]]).keys()) { console.log(key); } will output nothing when transpiled, because you get a compile error Type 'IterableIterator<string>' is not an array type or a string type..

That's true, but we don't guarantee that transpilation will always work in the presence of compile errors.

I find that a little troubling if there are no warnings generated for js code.
Thanks for your response nonetheless – I'll close given that this is apparently acceptable behaviour.


DS-970: Add Magic Nix Cache and other workflow changes

An assortment of GitHub Workflow changes, potentially including:

Enable DeterminateSystems/magic-nix-cache-action@main
Reference all DeterminateSystems actions via @main
Make update.yaml consistent across repos
Remove unnecessary github-token: from nix-installer-action
Update actions/checkout@v2 to actions/checkout@v3

@Hoverbear Thanks for the feedback :+1: I've removed the magic Nix cache.


When using asyncio.Lock(), RuntimeError occurred: got Future  attached to a different loop

Describe the bug
[2018-10-31 16:19:05] [97760] [ERROR] Traceback (most recent call last):
  File "/Users/admin/pyenv/lib/python3.6/site-packages/sanic/app.py", line 603, in handle_request
    response = await response
  File "/usr/local/Cellar/python/3.6.5_1/Frameworks/Python.framework/Versions/3.6/lib/python3.6/asyncio/coroutines.py", line 129, in throw
    return self.gen.throw(type, value, traceback)
  File "server.py", line 18, in foo2
    async with lock:
  File "/usr/local/Cellar/python/3.6.5_1/Frameworks/Python.framework/Versions/3.6/lib/python3.6/asyncio/locks.py", line 79, in __aenter__
    yield from self.acquire()
  File "/usr/local/Cellar/python/3.6.5_1/Frameworks/Python.framework/Versions/3.6/lib/python3.6/asyncio/locks.py", line 181, in acquire
    yield from fut
RuntimeError: Task <Task pending coro=<Sanic.handle_request() running at /Users/admin/pyenv/lib/python3.6/site-packages/sanic/app.py:603> created at /Users/admin/pyenv/lib/python3.6/site-packages/sanic/server.py:295> got Future <Future pending> attached to a different loop

[2018-10-31 16:19:05] [97760] [ERROR] Exception occurred while handling uri: "http://<IP_ADDRESS>:1234/2"
Traceback (most recent call last):
  File "/Users/admin/pyenv/lib/python3.6/site-packages/sanic/app.py", line 603, in handle_request
    response = await response
  File "/usr/local/Cellar/python/3.6.5_1/Frameworks/Python.framework/Versions/3.6/lib/python3.6/asyncio/coroutines.py", line 129, in throw
    return self.gen.throw(type, value, traceback)
  File "server.py", line 18, in foo2
    async with lock:
  File "/usr/local/Cellar/python/3.6.5_1/Frameworks/Python.framework/Versions/3.6/lib/python3.6/asyncio/locks.py", line 79, in __aenter__
    yield from self.acquire()
  File "/usr/local/Cellar/python/3.6.5_1/Frameworks/Python.framework/Versions/3.6/lib/python3.6/asyncio/locks.py", line 181, in acquire
    yield from fut
RuntimeError: Task <Task pending coro=<Sanic.handle_request() running at /Users/admin/pyenv/lib/python3.6/site-packages/sanic/app.py:603> created at /Users/admin/pyenv/lib/python3.6/site-packages/sanic/server.py:295> got Future <Future pending> attached to a different loop

[2018-10-31 16:19:05] - (sanic.access)[INFO][<IP_ADDRESS>:61823]: GET http://<IP_ADDRESS>:1234/2  500 3588
[2018-10-31 16:19:08] - (sanic.access)[INFO][<IP_ADDRESS>:61822]: GET http://<IP_ADDRESS>:1234/1  200 15

Code snippet
Below is a self-contained executable code of the server. Run it with python server.py. Accessing the routes simultaneously throws the above exception. E.g. try opening <IP_ADDRESS>:1234/1, <IP_ADDRESS>:1234/2, <IP_ADDRESS>:1234/3, <IP_ADDRESS>:1234/4 together.
from sanic import Sanic, response
import asyncio

loop = asyncio.get_event_loop()
lock = asyncio.Lock(loop=loop)

if __name__ == '__main__':
    app = Sanic(__name__)

    @app.route('/1')
    async def foo1(request):
        async with lock:
            await asyncio.sleep(3)
            return response.text('Welcome to foo1')

    @app.route('/2')
    async def foo2(request):
        async with lock:
            await asyncio.sleep(3)
            return response.text('Welcome to foo2.')

    @app.route('/3')
    async def foo3(request):
        async with lock:
            await asyncio.sleep(3)
            return response.text('Welcome to foo3.')

    @app.route('/4')
    async def foo4(request):
        async with lock:
            await asyncio.sleep(3)
            return response.text('Welcome to foo4.')

    app.go_fast(debug=True, host='<IP_ADDRESS>', port=1234, loop=loop, workers=1)

Expected behavior
I expected the code to successfully lock the route access. Since I passed the same event loop to both Sanic and asyncio.Lock, I did not expect an "attached to a different loop" error, and I am out of my depth trying to debug this. I need to use a lock because parts of some routes have to access a shared resource. Therefore I would like to put a lock on its access.
Environment (please complete the following information):

OS: macOS High Sierra 10.13.6
Python 3.6.5
Sanic 0.8.3

Additional context
Below is a toy implementation of asyncio.Lock that one might tryout in Jupyter.
import asyncio
import time
loop = asyncio.get_event_loop()
lock = asyncio.Lock(loop=loop)

async def foo(i):
    print('foo()', i, time.time() - start_time)
    async with lock:
        await asyncio.sleep(3)
        print('foo()', i, time.time() - start_time)

async def bar(i):
    print('bar()', i, time.time() - start_time)
    await asyncio.sleep(3)
    print('bar()', i, time.time() - start_time)

With Lock:
start_time = time.time()
asyncio.run_coroutine_threadsafe(asyncio.wait([foo(i+1) for i in range(4)]), loop)

Output:
<Future at 0x10896f128 state=pending>
foo() 2 0.00603795051574707
foo() 3 0.006173849105834961
foo() 1 0.006215810775756836
foo() 4 0.006256818771362305
foo() 2 3.008753776550293
foo() 3 6.01404595375061
foo() 1 9.015261888504028
foo() 4 12.016465902328491

Without Lock:
start_time = time.time()
asyncio.run_coroutine_threadsafe(asyncio.wait([bar(i+1) for i in range(4)]), loop)

Output:
<Future at 0x10896f160 state=pending>
bar() 2 0.005133867263793945
bar() 1 0.005623817443847656
bar() 4 0.005692005157470703
bar() 3 0.0061037540435791016
bar() 2 3.007520914077759
bar() 1 3.0076818466186523
bar() 4 3.00774884223938
bar() 3 3.0078117847442627

Not sure what's up here. I was not able to duplicate the errors when testing your code locally, however I have not been able to test on a mac yet.
This is on F28 (kernel 4.18.14-200) w/ python 3.6.6 and sanic 0.8.3
CLI:
[user@localhost|git: none| test-sanic]$ curl localhost:1234/1
Welcome to foo1[user@localhost|git: none| test-sanic]$ curl localhost:1234/1
Welcome to foo1[user@localhost|git: none| test-sanic]$ curl localhost:1234/2
Welcome to foo2.[user@localhost|git: none| test-sanic]$ curl localhost:1234/3
Welcome to foo3.[user@localhost|git: none| test-sanic]$ curl localhost:1234/4

server logs:
[2018-10-31 07:03:43 -0500] [16552] [INFO] Goin' Fast @ http://<IP_ADDRESS>:1234
[2018-10-31 07:03:43 -0500] [16561] [INFO] Starting worker [16561]
[2018-10-31 07:03:55 -0500] - (sanic.access)[INFO][<IP_ADDRESS>:47266]: GET http://localhost:1234/1  200 15
[2018-10-31 07:04:01 -0500] - (sanic.access)[INFO][<IP_ADDRESS>:47270]: GET http://localhost:1234/2  200 16
[2018-10-31 07:04:14 -0500] - (sanic.access)[INFO][<IP_ADDRESS>:47278]: GET http://localhost:1234/3  200 16
[2018-10-31 07:04:19 -0500] - (sanic.access)[INFO][<IP_ADDRESS>:47282]: GET http://localhost:1234/4  200 16

I was just able to run this with no issues on OSX Sierra (10.12.6) and python 3.6.4 with no issues, other than async with lock is insanely slow on both platforms.

@csis0247 The explanation is in the documentation that basically says that if you need to create your own loop, you need to use app.create_server instead of app.run (app.go_fast is an alias of app.run).
Change
    app.go_fast(debug=True, host='<IP_ADDRESS>', port=1234, loop=loop, workers=1)

To:
    server = app.create_server(host="<IP_ADDRESS>", port=1234)
    loop = asyncio.get_event_loop()
    task = asyncio.ensure_future(server)
    loop.run_forever()

Then you should be able to operate as expected without errors.
As an FYI, passing loop=loop into app.run does not do anything. It ignores that loop. It probably should throw an exception to the user so they know not to do it. I am closing this issue for now and will open a separate one. If you have anything further, please feel free to reopen.

@ahopkins no need to reopen, but I copied the provided code exactly and ran in to no issues - so if nothing else I'd like to understand the depgraph here so we can isolate the issue. @csis0247 if you're running in a virtualenv can you do a pip freeze > requirements.txt and provide that?

It's actually not recommended to reference loop explicitly, especially in multiprocess mode before os.fork. And in most async frameworks, they are close current event loop and spawn a new one for using. and gunicorn also does the same thing


fix: Map button overlap (#16301)

Pre-Submission Checklist

[x] Your pull request targets the staging branch of freeCodeCamp.
[x] Branch starts with either fix/, feature/, or translate/ (e.g. fix/signin-issue)
[x] You have only one commit (if not, squash them into one commit).
[x] All new and existing tests pass the command npm test. Use git commit --amend to amend any fixes.

Type of Change

[x] Small bug fix (non-breaking change which fixes an issue)
[ ] New feature (non-breaking change which adds new functionality)
[ ] Breaking change (fix or feature that would change existing functionality)
[ ] Add new translation (feature adding new translations)

Checklist:

[x] Tested changes locally.
[x] Addressed currently open issue (replace XXXXX with an issue no in next line)

Closes #16301
Description

Added 10px of margin to the right of the navbar-header (between the search bar and "Map" button). This assures that the map button does not overlap the search bar on hover.

@ncaron Awesome! This fixes the issue. Thanks for fixing this, and congratulations on your first contribution to the freeCodeCamp repo! 💯


Automatically fetch a fallback TLE if official TLE isn't avaliable

To my understanding we've been automatically updating the OreSat0 TLE but we can't auto-update the OreSat0.5 TLE because it hasn't been giving an official name yet. We've been updating manually using the provisional designator but can we do this automatically? As in provide the official name (ORESAT0.5) and an optional fallback (98867 possibly?) and if the official name fails pull from the fallback.
It's taken a while for us to get the official designator for OreSat0.5 and updating by hand is an easy task to get dropped.

Completed in e55657


Allow resource kwargs with iter_bucket api

After this commit clients can pass resource kwargs to the iter_bucket
api.
Fix #346

Hi @indrajeet307, I've identified the issue this PR is solving (#346) as a duplicate of an older issue (#259). I'm closing this PR in favor of #372, because that is a more active PR.
Thank you for your effort, I hope you continue to contribute to smart_open!


burger not toggling drawer

This framework is awesome, it should be the default for ionic! However, the drawer is not toggled by default by the burger. After doing some debugging, the drawer show/hide functions are getting called, but somehow nlDrawer.openned is set too fast. One quick fix i found for this is adding a timeout for nlDrawer.openned= true/false in nlDrawer.show/hide. Is there any other solution?
  setTimeout( function(){
    nlDrawer.openned = false;
  }, $nlConfig.options.speed);

Hi aspacardin, in browser or on mobile?
I can't reproduce this (haven't came across this issue) but it could be related to device performance.
Have you tried different devices?
Bacause nlDrawer.openned only tells the nlDrawer.toggle() function if toggle the drawer on or off (and is called before the openned value is set by hide() or show() function) so this should be working properly.

I think it was working in browser, but not on mobile. The device i'm using is a Sony Z3, so it's pretty performant. I'm using cordova 5.3, ionic and crosswalk. Actually my final solution was to remove the timeout I mentioned in my previous post, and manually toggle the drawer with an . It's working great now. Also, I didn't get the point of the nlDrawer.openned = true; in move(), so I removed that line and I added some event firing when the drawer is open/closed (it might be good to include those custom events as default).

Yes, the onOpen and onClose events are going to be in next update, with custom callbacks and some other small adjustments. I'm just trying ionic with crosswalk on Nexus 4 and some china Note 3 clone and the drawer works better (drawer toggles every time) on the china model, so that's weird. I'll take a look at that.
And You are right, there is no need for the nlDrawer.openned = true; in move(), I've probably overlooked that, thank You for mentioning.

Hello.
I'm using your plugin.
This plugin is wonderful.
However,  I have a small problem about nlDrawer.
My application's nlDrawer has many items, but some items are not appearing on the screen.
I added following code, but it doesn't work properly.
#nlDrawer .nav {
overflow-y: scroll;
}
I guess the problem is the timing of touch start/end event.
Can you help me?

gabskojima:
could you try the full-height branch? for me it solved the scrolling.
Sorry for the mess, I had wrong indenting.
Please let me know :)

vincurekf
Thank you for your reply.
I tried the full-height branch.
It worked properly.
Thank you!


Blocker: LocalForage applies unknown filters

Exception message:
Filter named 'search' not found, did you add it to filterValues of the model?
Exception Stack trace:
{code}Error: Filter named 'search' not found, did you add it to filterValues of the model?
at Filterable. /modules/039146fe.components.js:53:27448)
at /portal/modules/039146fe.components.js:17:29864
at Function.m.each.m.forEach /portal/modules/039146fe.components.js:17:30767)
at Filterable.setFilters /portal/modules/039146fe.components.js:53:27182)
at MwListCollection. /portal/modules/039146fe.components.js:48:15861)
at processQueue /portal/modules/039146fe.components.js:11:14871)
at /portal/modules/039146fe.components.js:11:15163
at Scope.$eval /portal/modules/039146fe.components.js:11:27484)
at Scope.$digest /portal/modules/039146fe.components.js:11:25127)
at Scope.$apply /portal/modules/039146fe.components.js:11:27919){code}
User message:
No description was added by the user
Happened on page:
/#/apps?qAttr=search&q=XYZ

fix it


Should HTTP end point URL contain local/remote address (for LIP-1 and beyond) ?

HTTP end point in LIP-1 specifies that HTTP urls has the following format:
https://<hostname>:<port>/<protocol_version>/<LocalVASPAddress>/<RemoteVASPAddress>/command

It has been causing some confusion of what LocalVASPAddress and RemoteVASPAddress means and it is sort of easy to mix them up. As this URL will also be used in other off chain related LIPs, it's worth discussing whether we want to keep them in the URL.
Pros:

easier (VASPs/DDs) for users to do load balancing: users  can forward the request to right tiers according to from address and/or to address. Without this, users need to parse the JWS message to get these info.

Cons:

easy to mistake one with the other
makes the URL longer

I also think it's worthwhile discussing whether we put protocol_version in the front or rear (i.e. after command). Because as we add protocols in the future, more keywords will be introduced (e.g. pay in Libra ID). Logically we want them each to have a version (easier for iterating).
cc @kphfb , @gdanezis , @xli , @sunmilee , @andll , @bmaurer

To be honest I don't by point 1 - I don't understand how would VASP/DD do load balancing based on to/from and why would they do that
Additionally, I am not sure why do we need LocalVASPAddress - don't VASP know who they are?
I think for the version general guideline should be having it as early as possible (ideally first part of the path part of the URL)
Reason for this is quite simple - maybe in some future version we will decide to change this Local/remote/command part, so it would be easier to reason about if version goes first.

I agree with removing it also.  Version early also makes sense.  Let's make it happen

Closing this as we agreed to remove addresses in url and placing version early.


Add AggregateFilter controller

We currently have the Filter class which acts as a convenience around creating and manipulating filters in the search interface. There is currently nothing that does the same for Facets (filters created from aggregates). Bellow is the source of a custom CountAggegrateFilter and DateAggregateFilter I built for a project, would be nice to have a series of these in the SDK for the different aggregate types (count, date) as well as a generic one.
/*
 * CountAggregateFilter
 */
export class CountAggregateFilter extends Filter {
  _field = "";
  _counts = [];
  _multi = false;

  constructor(field, pipeline, multi = false, type = "~") {
    super({}, [], multi);

    this._field = field;
    this._multi = multi;

    pipeline.listen(responseUpdatedEvent, response => {
      const current = this.get();
      const aggregates = response.getAggregates();

      this._counts = this._getCounts(aggregates);
      this._clearFilterOptions(current);
      this.setOptions(this._genFilterOptions(current, type));
    });
  }

  _getCounts(aggregates) {
    if (isEmpty(aggregates, this._field)) return [];

    const counts = aggregates[`count.${this._field}`]["count"]["counts"];
    return Object.keys(counts)
      .map(key => {
        return { name: key, count: counts[key] };
      })
      .filter(x => x.name !== "")
      .sort(({ count: a }, { count: b }) => b - a);
  }

  _genFilterOptions(current, type = "~") {
    return this._counts.reduce((opts, { name, count }) => {
      if (!current.includes(name)) {
        opts[name] = `${this._field}${type}"${name}"`;
      }
      return opts;
    }, {});
  }

  _clearFilterOptions(current) {
    const clear = Object.keys(this.getOptions()).reduce((opts, key) => {
      if (!current.includes(key)) {
        opts[key] = undefined;
      }
      return opts;
    }, {});
    this.setOptions(clear);
  }
}

const isEmpty = (aggregates, field) =>
  !aggregates ||
  !aggregates[`count.${field}`] ||
  !aggregates[`count.${field}`]["count"] ||
  !aggregates[`count.${field}`]["count"]["counts"];

/*
 * DateAggregateFilter
 */
export class DateAggregateFilter extends Filter {
  _field = "";
  _counts = [];
  _multi = false;
  _range = [0, 0];
  _filter = "";
  _current = "";

  constructor(field, pipeline, multi = false, type = "~") {
    super({}, [], multi);

    this._field = field;
    this._multi = multi;

    pipeline.listen(responseUpdatedEvent, response => {
      const aggregates = response.getAggregates();
      if (isEmpty(aggregates, this._field)) return;

      this._counts = this._getCounts(aggregates);
      this._range = [
        this._counts[0],
        this._counts[this._counts.length - 1]
      ].map(({ name }) => parseInt(name, 10));

      this._emitOptionsUpdated();
    });
  }

  range = () => this._range;
  counts = () => this._counts;
  filter = () => this._filter;

  get = () => (this._current === "" ? [] : [this._current]);

  set = (from, to) => {
    const fromTimestamp = (new Date(`${from}.01.01`).getTime() / 1000).toFixed(
      0
    );
    const toTimestamp = (new Date(`${to}.12.31`).getTime() / 1000).toFixed(0);

    if (!isNaN(fromTimestamp) && !isNaN(toTimestamp)) {
      this._filter = `(${this._field} >= ${fromTimestamp} AND ${
        this._field
      } <= ${toTimestamp})`;

      this._current = `${from} - ${to}`;
    }

    this._emitSelectionUpdated();
  };

  clear = () => {
    this._filter = "";
    this._current = "";
    this._emitSelectionUpdated();
  };

  _getCounts(aggregates) {
    const counts = aggregates[`date.${this._field}`]["date"]["dates"];
    return Object.keys(counts)
      .map(key => {
        return { name: key, count: counts[key] };
      })
      .filter(x => x.name !== "")
      .sort(({ name: a }, { name: b }) => a - b);
  }
}

const isEmpty = (aggregates, field) =>
  !aggregates ||
  !aggregates[`date.${field}`] ||
  !aggregates[`date.${field}`]["date"] ||
  !aggregates[`date.${field}`]["date"]["dates"];

Hey @benhinchley, I just have few questions for the tickets:

Is the path like [date.${field}]["date"]["dates"] stable or unpredictable?
Is there any piece of UI behind DateAggregateFilter to look at? I don't really understand what the code do.
Since the sample codes of CountAggregateFilter & DateAggregateFilter look different, what do you expect for output of a generic?

Hey @zlatanpham for the this path [date.${field}]["date"]["dates"] I am actually unsure if that is stable, so maybe just work on the count variant for the moment, while I check in with @dhowden.

I'll try find the UI code the the DateAggregate stuff and post here or in a gist depending on its size.
And yes good point, I am not 100% sure at the moment what the generic controller would look like. We can probably discuss this a at a later point

Hey @benhinchley, just finish the CountAggregateFilter. Basically, it was just a transformation of your code into ts. Hope you can give some feedback.

@zlatanpham this looks good.
Been thinking about this for a bit and not sure if it is worth doing, but it is very easy to forget to add the "count": "<field_name>" to the values object when using a Count aggregate. I'm wondering if it is worth adding the values object as an argument to the constructor, and then subscribing to the EVENT_VALUES_UPDATED event, and on change add the "count": "<field_name>" to the values object.

@benhinchley like this?
const fieldNameFilter = new CountAggregateFilter('field_name');
const values = new Values({
  fields: '',
  count: 'field_name',
});

If so, I also think it makes sense to force passing values object to the filter.

@zlatanpham yep that is exactly what you would have to do now.
So yeah I think it makes sense to change the constructor to be
let fieldNameAggregate = CountAggregateFilter("field_name", pipeline, values);

@benhinchley, please help me review the update.

@zlatanpham this looks okay, can you make a PR against this repo so I can review more easily


Add missing commitOffset in type definitions, fix fetchOffset return type and other small things

That was quick, thanks! 👍

Published as 3.2.5, thanks!


Add a compactness option in user preferences

This would allow users to choose among a set of predetermined compactness options (ie: compact, regular, comfortable) that would control default padding and margin values.

This has been implemented with the Spacing user setting.


Listen for changes from the file system

Ideally if a file is changed on disk, the editor should show those changes.
I think chokidar is a popular package for listening for these kinds of changes.

I think it's fine to table this for now. Let us assume that VZCode is the only editor touching this part of the file system, and ignore changes made by other programs, for now.

A valiant first attempt was made here: https://github.com/vizhub-core/vzcode/pull/94


Update concepts-connectivity-architecture.md

@code-sidd
Can you review the proposed changes?
When the changes are ready for publication, add a #sign-off comment to signal that the PR is ready for the review team to merge.
#label:"aq-pr-triaged"
@MicrosoftDocs/public-repo-pr-review-team

@code-sidd
Thanks for approving the PR. For future PRs, please note that a #sign-off comment is the best way to signal to the review team that a PR is ready to merge.


Enum Support

From<EMAIL_ADDRESS>on November 06, 2013 12:05:38
Add Enum support to FOAM.
Original issue: http://code.google.com/p/foam-framework/issues/detail?id=62

We have foam.core.types.EnumProperty and friends, and constants on models now, so I'm closing this as "implemented".

EnumProperty isn't sufficient for generating Enums for languages like Java and doesn't provide sufficient reuse.


PR: Migrate FileSwitcher functionality to Switcher

Description of Changes

[x] Wrote at least one-line docstrings (for any new functions)
[x] Added unit test(s) covering the changes (if testable)

[x] Included a screenshot or animation (if affecting the UI, see Licecap)

TODO

[x] Create instance of Switcher instead of FileSwitcher
[x] Handle file change (Editor)
[x] Handle symbol mode (Editor)
[x] Handle line mode (Editor)
[x] Handle Switcher instance for New Editor windows
[x] Fix tests

A preview:
Windows

Linux

Issue(s) Resolved

Fixes #
Affirmation
By submitting this Pull Request or typing my (user)name below,
I affirm the Developer Certificate of Origin
with respect to all commits and content included in this PR,
and understand I am releasing the same under Spyder's MIT (Expat) license.

I certify the above statement is true and correct: dalthviz

Hello @dalthviz! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found:

In the file spyder/plugins/editor/widgets/editor.py:

Line 490:13: E128 continuation line under-indented for visual indent

This is looking pretty good, thanks @dalthviz!!
I have a quick comment: could you decrease the amount of vertical space between rows in the new switcher to the minimal possible? I say it because in the screenshot you posted above there's too much space now, and I'd like to see it reduced as much as possible.

This is looking great @dalthviz :-)

Moving forward @dalthviz do you see the need to make some convenience method on the switcher, or perhaps encapsulate all the methods needed in a separtae clasee for the editor?

@goanpeca yep I was thinking that probably I should create a mixin with all the logic for the Editor to not duplicate code between the plugin and the widget of the Editor (which is basically the same)

Yes a switcher manager could work ;-)

@dalthviz left a few comments. Found a couple of issues.
1.) I see the editor text in blue for all the items. I think the idea was to have a single "header" per block. (on your animation looks different)

2.) When in LINE_MODE, I can use up and down arrows which is a bit weird

3.) Also when in line mode if I type lets say
:12 and press Escape the document the cursor should return to the original position it had before changig (since escape effectively cancelled that move)

@dalthviz left a few comments. Found a couple of issues.

@goanpeca from the images you show it seems you did the tests with the master version of Spyder or a different branch from the one on this PR (there is a info icon that is not present in the new Switcher) could be that the case and the reason you experienced such behaviors?

@dalthviz yes you are absolutely right! I was on master 🤦♂
Just checked again!
All seems in order ignore the last comments!

@dalthviz, I forgot to mention: if the old fileswitcher is not used anymore, please remove it as part of this PR too.

@ccordoba12 @goanpeca a preview with the latest changes:

It looks amazing!! Thanks a lot @dalthviz for your hard work on this one!
I think this is ready. @goanpeca, do you have some final words to say?

I think this is ready. @goanpeca, do you have some final words to say?

It looks really good @dalthviz ! :-)
My only comment is regarding the size of the Switcher.
Should it update based on which configuration?
For instance, let's assume I have a lot of zoom on the editor because...
Or if I set the appearance of the fonts to be larger

Then we get this:

So I think we should use perhaps the settings from the appearance? Thoughts @ccordoba12, @dalthviz ?


How to retrieve Secret key-values in yaml if we don't know their key names in advance ?

Hello,
In an Azure DevOps Pipeline, to get key-values from an App Configuration to use them in a yaml template, I use this yaml task :
    - task: AzureAppConfiguration.azure-app-configuration-task.custom-build-release-task.AzureAppConfiguration@5
      inputs:
        azureSubscription: 'ServiceConnectionName'
        AppConfigurationEndpoint: 'https://ressourcename.azconfig.io'
        KeyFilter: '${{ parameters.appConfigurationKeyFilter }}*'

References to Azure Key Vault in App Configuration will be resolved and set as secret variables. In Azure pipelines, secret variables are hidden in the log. They are not passed to tasks as environment variables and instead must be passed as entries.
So, how to pass secret as entries in a YAML task when we don't know the key name of secret in advance ? Each application has different secret names.
For example, I use this PowerShell task to use key-values retrieved from an App Configuration :
    - task: PowerShell@2
      env:
        APPICATIONNAME-CONNECTEDAPP-SECRET: $(ApplicationName-ConnectedApp-Secret)
        APPICATIONNAME-ENVIRONMENT-SECRET: $(ApplicationName-Environment-Secret)
       APPICATIONNAME-VARIABLENAME: $(ApplicationName-VariableName)
      inputs:
        targetType: 'inline'
        script: |

            # Get all key-values without secret
            $keyValues = Get-ChildItem env: | where name -like '${{ parameters.appConfigurationKeyFilter }}*'

           $Secret1 = "$(ApplicationName-ConnectedApp-Secret)"
           $Secret2 = "$(ApplicationName-Environment-Secret)"
           $Secret3 = "$(ApplicationName-VariableName)"

Name of Env variables must to be known in advance to be hard coded. How to do when we don't know key names in advance ?

Might you be referring to the key name of the secret, that is set when creating a key vault reference in App configuration?

Yes, I talk about keys in an App Configuration which contain a reference to a secret in an Azure Key Vault.
How to get them when we don't know key names in advance ?
I need to all export them to a resource without knowing key names in advance.

I don't think there is a way to get them without knowing their names prior.

This is a problem! We are retrieving a group of key-values from an App Configuration to pass them to an App Service. We can't and we don't need to know the key names of each secret.
Unfortunately, with your solution, we have to hard coded all the secrets for each application, and therefore know every secret in every application! This is not acceptable! Our CICD pipeline can't be generic because of this and has to be changed every time a secret changes (add, modify, delete)!
On top of that, all the key names we get back are converted to uppercase, it's unbearable!
You have to propose a more flexible solution, which keeps the case of the key names and which does not require to know the names of the recovered keys.
Thanks.

The pulled key names can either be accessed in uppercase or normal case.
echo "Variable = $(KEY_NAME_IN_UPPERCASE)"
echo "Variable = $(key_in_normal_case)"

Am afraid that is not possible since the task is designed to pull key values from a configuration store and set them as environment variables. To get a key-value you'll have to know the name of the key-value. Please see Use key-values in subsequent tasks for more information. Please reach out in case you encounter any issues.


Adding placeholder GitHub CI unit tests to this repo

This is just a starting point, so we can hook unit tests into the Continuous Integration tools provided by GitHub.
I also made the (arbitrary) choice to add a tox.ini to make running CI easier to do the same locally as on CI. This is mandatory, if you hate it.
Notice I only added one silly unit test.  Eventually, we can flush out this system with more CI tools:

Adding more unit tests

The biggest hurdle I found here was many files did import openmc, which we will have to build into the CI workflow.

Adding the ruff linter to the CI

Which I can open another CI for, that will look like this.

You'll also notice that now the "checks" for this CI show up on the bottom of every PR.


Null-safety support

It would be great to have Null-safety to upgrade our project

Sounds good, I'll give it a shot this weekend

Version 0.0.2 was just published to pub with support for sounds null saftey: https://pub.dev/packages/sim_data/versions


Clean bindings core error

Fixes https://github.com/iotaledger/iota-sdk/issues/198

Presumably the removed error types are handled elsewhere now?


update erlcinfo on disk if source file removed

This fixes an issue where while during the run the digraph would have an edge removed for a removed source file this update what not written to disk.
Fixes https://github.com/rebar/rebar3/issues/714

+1


Generated LookupSubjectsRequest missing optional_concrete_limit in v0.5.0

LookupSubjectsRequest in the v1 api schema describes the field optional_concrete_limit that was not included in the generated java classes when v0.5.0 was published.
Interestingly, the similarly named optional_limit field in the LookupResourcesRequest counterpart was included in the respective generated code.
I've attached PermissionService.zip with the generated code in case it helps.

Understood, thanks the quick response! Feel free to either close this issue or keep it open until the feature is released so others know this is a known issue.

https://github.com/authzed/api/issues/71


Add ListView.Props.onSelect

This allows ListView components to handle selection of items. Example TableModal component was refined to demo the new property.

Codecov Report

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

@@           Coverage Diff           @@
##           master      #40   +/-   ##
=======================================
  Coverage   95.23%   95.23%
=======================================
  Files           5        5
  Lines         336      336
=======================================
  Hits          320      320
  Misses         16       16

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 ca91125...fd3e3a2. Read the comment docs.


feat: comment on i18n failure

Checklist:

[X] I have read and followed the contribution guidelines.
[X] I have read and followed the how to open a pull request guide.
[X] My pull request targets the main branch of freeCodeCamp.
[X] I have tested these changes either locally on my machine, or GitPod.

Related #49698

Okay, this has been tested and is ready to go.
The logic here is that if the localisation tests fail, but the English tests pass, that's a potential indicator that we need to do a sync (not always, tests can be flaky, but it'll let the contributor know to reach out to us).

I am sad dev-team members do not get a nice message 🙃

That is borrowed from the no translation PR, because when we're intentionally breaking things we don't want to get spammed by the bot (:


[vshare] extractor rewritten

Before submitting a pull request make sure you have:

[X] At least skimmed through adding new extractor tutorial and youtube-dl coding conventions sections
[X] Searched the bugtracker for similar pull requests
[X] Checked the code with flake8

In order to be accepted and merged into youtube-dl each piece of code must be in public domain or released under Unlicense. Check one of the following options:

[x] I am the original author of this code and I am willing to release it under Unlicense
[ ] I am not the original author of this code but it is in public domain or released under Unlicense (provide reliable evidence)

What is the purpose of your pull request?

[x] Bug fix
[ ] Improvement
[ ] New extractor
[ ] New feature

Description of your pull request and other information
The VShare extractor is broken, I've rewritten it to depack the code in the page and get the video url from there.
I've also added the _extract_urls method.
This should close issue #14473.

@dstftw Can I do something to improve this PR?

@dstftw thanks for the feedback (and sorry for the print).
It should be ok now.
Timendum


Skip kubeadm coredns installation

What this PR does / why we need it
Checklist

[ ] Update changelog in CHANGELOG.md.

Trigger e2e tests

/test create
/test upgrade

/test create
/test upgrade


Add support for NetworkLinkControl updates

I'm porting an application from GE to Cesium; it relies on NetworkLinkControl updates heavily, and I think this would be a useful feature for most people.  Is there any roadmap for such a feature?

Hello @wulfgarpro,  we do have a note to add this in our KML roadmap issue.  I'm not sure when we'll be able to get to it though.
I'm going to close this issue and make a comment on #873 so we can keep track of how many people have asked for this.  Thanks!


fix(flow): undefined in tagged template literal with flow-bin 0.92.1

What I did

upgrade flow-bin to v0.92.1
fix undefined in tagged template literal type error:

Thanks @evenchange4! Good ol' flow...


No remote feed on FireFox

Your environment.

Version: Commit 490837a9ff7e570e430958691317dd86fc9c7595 (latest)
Browser: FireFox 76.0.1 (Mac) and FireFox 76.0.1 (Windows 10)

What did you do?
I updated the code base on my Linux server in DigitalOcean and manually rebuilt all the Docker images locally from source.
Next, I restarted the Docker VM's with the new code and tried to start sessions involving the two types of FireFox browsers.
What did you expect?
I expected to see both the local and remote video and audio tracks for the session.
What happened?
On. FireFox, I only saw the local video.  On Chrome for the second participant, I saw messages related to a new stream appearing but never saw the FireFox browser stream.
The behavior is the same whether the Chrome browser starts the session or the FireFox browser.
When using only FireFox browsers, only local streams appear on each.

Firefox support was just added and there are still a few kinks to work out. What codecs were you using from both sides. Also can you see if there were any abnormal log lines from sfu?

Currently VP9 seems to be the best supported between the two.


MINOR: Fix failing metrics tests due to KafkaServer rename

Test cases in kafka.metrics.MetricsTest were failing because of the name change from KafkaServer to KafkaBroker. This patch introduces an alternate registration path for these metrics.
Committer Checklist (excluded from commit message)

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

LGTM