Cutting a fused shape shows only edges

When trying the code below to cutout a fused circle with text it only show the edges of the fused shape instead of it being cut.
const main = (r) => {
       function center(drawing) {
            const boundingBox = drawing.boundingBox;
            drawing = drawing.translate(-boundingBox.center[0], -boundingBox.center[1]);

            return drawing;
        }

        let plate = drawRectangle(5, 5).cut(
            drawCircle(0.5)
                .fuse(center(drawText('test', { fontSize: 2 })).translate(0, 0.8).rotate(90))
        );

        return plate.sketchOnPlane('XY').extrude(0.2);
};

This also happens when only using a to be cutout when using this code:
const main = (r) => {
       function center(drawing) {
            const boundingBox = drawing.boundingBox;
            drawing = drawing.translate(-boundingBox.center[0], -boundingBox.center[1]);

            return drawing;
        }

        let text = drawText( 'text');
        text = text
            .stretch(1 / (text.boundingBox.width / 7.5), [0, 1], text.boundingBox.center)
            .stretch(1 / (text.boundingBox.height / 2), [1, 0], text.boundingBox.center);

        let plate = drawRectangle(10, 20).cut(
          center(text)
        );

        return plate.sketchOnPlane('XY').extrude(0.2);
};

A simple workaround is not to expect the drawing to understand which parts should be kept and which should be deleted.
const {draw, drawRectangle, drawCircle, drawText} = replicad

const main = (r) => {
       function center(drawing) {
            const boundingBox = drawing.boundingBox;
            drawing = drawing.translate(-boundingBox.center[0], -boundingBox.center[1]);

            return drawing;
        }

        let plate = drawRectangle(5, 5).sketchOnPlane("XY").extrude(0.2)
        let cutter = drawCircle(0.5).fuse(center(drawText('test', { fontSize: 2 })).translate(0, 0.8).rotate(90))
        cutter = cutter.sketchOnPlane("XY").extrude(1.0);
        plate = plate.cut(cutter)

        return plate;
};

Thank you for your response. I've explored the option of cutting after extrusion for this particular scenario, and while it may not be the optimal solution for my project, it serves as a viable workaround for the time being. Your assistance is greatly appreciated.

I confirm the whole issue - and I have been working on a better solution for 2D booleans (which can be faster) - but nothing that I would recommend yet unfortunately.


Multi-language overrides in workspace settings don't override user settings correctly

In my user settings
  "[jsonc]": {
    "editor.defaultFormatter": "vscode.json-language-features"
  },

In the vscode-copilot workspace settings
"[json][jsonc][yaml][markdown]": {
    "editor.defaultFormatter": "esbenp.prettier-vscode",
    "editor.formatOnSave": true
  },

When I save in a jsonc file in vscode-copilot, it uses vscode.json-language-features from my user settings.
If I remove the other languages from the workspace settings config so it only says "[jsonc]", then it works as expected

Looks like a duplicate of #184643

/duplicate
https://github.com/microsoft/vscode/issues/168411

Thanks for creating this issue! We figured it's covering the same as another one we already have. Thus, we closed this one as a duplicate. You can search for similar existing issues. See also our issue reporting guidelines.
Happy Coding!


Update katello rpm-pipeline to include 4.4

@ekohl done

Added a note to include it in the procedure: https://github.com/theforeman/tool_belt/pull/428#discussion_r811210184

Thanks!


FindUsages and Go To Definition don't work for enums

Error sets are probably also broken.

This isn't readily reproducible. It's possible that these issues were the result of the plugin crashing for other reasons.


Optimize diff view startup

GsDiffCommand either creates a new diff view, or it finds a suitable one
already open and then just focuses it. In both cases we want to make sure
that the view eventually shows the most recent diff.
The previous implementation had the following problems:

git diff did run on the main thread (#1092)
Reusing a diff view called git diff twice

We now generally rely on the on_activated_async event to update the view
lazy. The init command either creates or focuses a view but it never calls
for a 'refresh' imperatively.
Note that most of the time we actually want a blocking, sync update (to keep
the view and the repo state in sync) so we add a switch to the refresh command.
Fixes #1092

Current dev
Creating a view  (M=Main thread; D=Worker)
 (M) [125ms] $ git diff --stat --patch --no-color -- .\common\util\debug.py
 (D) [ 78ms] $ git status --porcelain -z -b
 (D) [ 94ms] $ git status --porcelain -z -b

Reusing a view
 (M) [109ms] $ git diff --stat --patch --no-color -- .\common\util\debug.py
 (M) [ 94ms] $ git diff --stat --patch --no-color -- .\common\util\debug.py
 (D) [ 94ms] $ git status --porcelain -z -b

PR
Creating
 (D) [109ms] $ git status --porcelain -z -b
 (D) [109ms] $ git diff --stat --patch --no-color -- .\core\commands\diff.py
 (D) [109ms] $ git status --porcelain -z -b

Reusing
 (D) [ 84ms] $ git diff --stat --patch --no-color -- .\common\util\debug.py
 (D) [ 94ms] $ git status --porcelain -z -b

Aside: When creating, you can nicely see the status bar overcalls on new which means the implemented throttler is not good enough.


feat: add GitHub code scanning alerts to CVE metric

I know this is a draft pr, but just a written note to update and add tests for the new functionality.

Next time I'll use the add to batch feature for the suggestion. Missed that chance here


matplotlib dependency

matplotlib 1.3.1 requires nose, which is not installed.
matplotlib 1.3.1 requires tornado, which is not installed.

Refers to an old version.
Close


Add another variable which might house the public cert

If this code was used on the service which houses the jwt key we might not have the setting ANSIBLE_BASE_JWT_KEY but instead we could have the setting jwt_public_key.

Hate to say this, but I would like some references of more explanation. Like, would this mean that the ANSIBLE_BASE_JWT_PUBLIC_KEY setting would become valid? The conversion involving lowercase+prefix is non-obvious to me.


[facebook] Regression: ExtractorError when parsing MPD manifest

Checklist

[X] I'm reporting a broken site
[X] I've verified that I'm running yt-dlp version 2021.12.27. (update instructions)
[X] I've checked that all provided URLs are alive and playable in a browser
[X] I've checked that all URLs and arguments with special characters are properly quoted or escaped
[X] I've searched the bugtracker for similar issues including closed ones. DO NOT post duplicates
[X] I've read the guidelines for opening an issue
[ ] I've read about sharing account credentials and I'm willing to share it if required

Region
worldwide
Description
Accessing a facebook video errors out with an exception. This appears to be due to an error parsing the MPD manifest.
This seems to be introduced in b8e976a44515b7a64f4f6d904025dffe742e21fa, where parsing of DASH manifests was added. From the page dump, it looks like the parsed manifest is not actually a manifest. If I put the parsing inside a try:/except, it obviously works again, but perhaps the code is incorrect as is.
Verbose log
[19:57:10 barsnick@moonlight yt-dlp]$ python -m yt_dlp -Uv 'https://www.facebook.com/watch/?v=480624596831510'
[debug] Command-line config: ['-Uv', 'https://www.facebook.com/watch/?v=480624596831510']
[debug] Encodings: locale UTF-8, fs utf-8, out utf-8, err utf-8, pref UTF-8
[debug] yt-dlp version 2021.12.27 [6223f67a8] (source)
[debug] Lazy loading extractors is disabled
[debug] Plugins: ['SamplePluginIE', 'SamplePluginPP']
[debug] Git HEAD: b8eeced28
[debug] Python version 3.10.1 (CPython 64bit) - Linux-5.15.12-200.fc35.x86_64-x86_64-with-glibc2.34
[debug] exe versions: ffmpeg 4.4.1 (setts), ffprobe 4.4.1
[debug] Optional libraries: Cryptodome, mutagen, sqlite, websockets
[debug] Proxy map: {}
Latest version: 2021.12.27, Current version: 2021.12.27
yt-dlp is up to date (2021.12.27)
[debug] [facebook] Extracting URL: https://www.facebook.com/watch/?v=480624596831510
[facebook]<PHONE_NUMBER>31510: Downloading webpage
[facebook]<PHONE_NUMBER>31510: Downloading MPD manifest
ERROR: [facebook]<PHONE_NUMBER>31510:<PHONE_NUMBER>31510: Failed to parse XML  (caused by ParseError('not well-formed (invalid token): line 3, column 1519')); please report this issue on  https://github.com/yt-dlp/yt-dlp . Make sure you are using the latest version; see  https://github.com/yt-dlp/yt-dlp  on how to update. Be sure to call yt-dlp with the --verbose flag and include its complete output. (caused by ParseError('not well-formed (invalid token): line 3, column 1519')); please report this issue on  https://github.com/yt-dlp/yt-dlp . Make sure you are using the latest version; see  https://github.com/yt-dlp/yt-dlp  on how to update. Be sure to call yt-dlp with the --verbose flag and include its complete output.
  File "/home/barsnick/Development/yt-dlp/yt_dlp/extractor/common.py", line 599, in extract
    ie_result = self._real_extract(url)
  File "/home/barsnick/Development/yt-dlp/yt_dlp/extractor/facebook.py", line 726, in _real_extract
    return self._extract_from_url(real_url, video_id)
  File "/home/barsnick/Development/yt-dlp/yt_dlp/extractor/facebook.py", line 582, in _extract_from_url
    parse_attachment(attachment)
  File "/home/barsnick/Development/yt-dlp/yt_dlp/extractor/facebook.py", line 552, in parse_attachment
    return parse_graphql_video(media)
  File "/home/barsnick/Development/yt-dlp/yt_dlp/extractor/facebook.py", line 520, in parse_graphql_video
    formats.extend(self._extract_mpd_formats(playable_url, video_id))
  File "/home/barsnick/Development/yt-dlp/yt_dlp/extractor/common.py", line 2608, in _extract_mpd_formats
    fmts, subs = self._extract_mpd_formats_and_subtitles(*args, **kwargs)
  File "/home/barsnick/Development/yt-dlp/yt_dlp/extractor/common.py", line 2616, in _extract_mpd_formats_and_subtitles
    res = self._download_xml_handle(
  File "/home/barsnick/Development/yt-dlp/yt_dlp/extractor/common.py", line 915, in _download_xml_handle
    return self._parse_xml(
  File "/home/barsnick/Development/yt-dlp/yt_dlp/extractor/common.py", line 944, in _parse_xml
    raise ExtractorError(errmsg, cause=ve)

Turns out, issue was same as #2187


Perform pre-check before running nightly

Purpose: check that it is worth running another instance of nightly build

Thanks for doing that


Parameters for Training with 48k Dataset

Hello,
I would like to train the Universe++ model with a 48k dataset. Are there any model parameters in universepp_24k.yaml that need to be modified for this purpose, or can I train the model using the current parameters as is?
I will wait for your response. Thank you!

Hi @Dahee96, the rule of thumb used was to downsample the signal to 100 Hz at the center of the UNet and use 2 channels per kHz. In addition, the number of mel spec filters used as input to the condition model should be modified to make sure to cover every frequencies.
So we had the following parameters for the 16 and 24 kHz models.
# 16 kHz model (config/model/default.yaml)
score_model:
  rate_factors: [2, 4, 4, 5]
  n_channels: 32
condition_model:
  n_mels: 80

# 24 kHz model (config/model/universepp_24k.yaml)
score_model:
  rate_factors: [2, 3, 5, 8]
  n_channels: 48
condition_model:
  n_mels: 128

So for a 48 kHz model, you could use
score_model:
  rate_factors: [3, 4, 5, 8]
  n_channels: 96
condition_model:
  n_mels: 128 (?)

And I'm not too sure about the exact number of mels required to cover everything up to 48 kHz, so please check it.

Thank you so much for your detailed and kind response :) I will make sure to try both 128 and 160 for n_mels.
I truly appreciate your help!


Got "Unable to open object (bad symbol table node signature)" error  when running "video analyzer" example

Hello,
I'm hitting below error when running "video analyzer" examples:
D:\Dev\Install\Python\packages\AI_learn\imageai\examples>python video_analysis_per_frame.py
Using TensorFlow backend.
2018-12-28 08:52:46.075376: I tensorflow/core/platform/cpu_feature_guard.cc:141] Your CPU supports instructions that this TensorFlow binary was not compiled to use: AVX2
Traceback (most recent call last):
File "video_analysis_per_frame.py", line 52, in
video_detector.loadModel()
File "D:\py36\lib\site-packages\imageai\Detection_init_.py", line 1024, in loadModel
model.load_weights(self.modelPath)
File "D:\py36\lib\site-packages\keras\engine\network.py", line 1166, in load_weights
f, self.layers, reshape=reshape)
File "D:\py36\lib\site-packages\keras\engine\saving.py", line 1021, in load_weights_from_hdf5_group
g = f[name]
File "h5py_objects.pyx", line 54, in h5py._objects.with_phil.wrapper
File "h5py_objects.pyx", line 55, in h5py._objects.with_phil.wrapper
File "D:\py36\lib\site-packages\h5py_hl\group.py", line 262, in getitem
oid = h5o.open(self.id, self._e(name), lapl=self._lapl)
File "h5py_objects.pyx", line 54, in h5py._objects.with_phil.wrapper
File "h5py_objects.pyx", line 55, in h5py._objects.with_phil.wrapper
File "h5py\h5o.pyx", line 190, in h5py.h5o.open
KeyError: 'Unable to open object (bad symbol table node signature)'
Same error throws when running another example "video_analyzer_per_second.py".
Does this error mean the model file 'yolo.h5' is corrupt and need to download again ?
If this is the case, I suggest that  you can provide checksum values(sha256,sha128,md5,,,etc)
on the web page for these model files so that users can compare it.
Thanks !

The issue had been fixed.
Reason:  model file is corrupt,  I used "aria2c" to dowload the model file but it looks like the download had been not finished yet, reexecuted "aria2c" and finished downloading.
BTW:  md5 of "yolo.h5":
bb28869448aeac2b53ce6f0f43c34d42
sha256 of "yolo.h5":
bcfda0f438f0a3db74a5e99ad9c6cd62e4773efdd6beee5ef13b5ad7cfb994f0


Stops after 90 Tag deletions on gitlab.com

First of all about the note in the README.md:
This script uses v4 of the GitLab API. It is tested against a self-hosted GitLab instance and it is unknown if these same commands work on projects hosted on gitlab.com.
I can confirm, script works mostly fine on commercial gitlab.com. I just ran it to clean up 1200 old tags but noticed that it stops after 90 deletions with the success message "Cleanup Complete.  Please run ...etc". But it also shows a warning at the beginning of the cleanup process:
./clean-registry.sh: line 118: [: x-next-page:2: integer expression expected
When I re-run the script it just continues to delete the next 90 tags before it stops again.  I can only assume that it has something to do with how gitlab.com responses to the page requests as opposed to self-hosted gitlab.
Anyway, the script is a life saver - thank you so much!
Greets
-act

First of all about the note in the README.md:
This script uses v4 of the GitLab API. It is tested against a self-hosted GitLab instance and it is unknown if these same commands work on projects hosted on gitlab.com.
I can confirm, script works mostly fine on commercial gitlab.com. I just ran it to clean up 1200 old tags but noticed that it stops after 90 deletions with the success message "Cleanup Complete. Please run ...etc". But it also shows a warning at the beginning of the cleanup process:
./clean-registry.sh: line 118: [: x-next-page:2: integer expression expected
When I re-run the script it just continues to delete the next 90 tags before it stops again. I can only assume that it has something to do with how gitlab.com responses to the page requests as opposed to self-hosted gitlab.
Anyway, the script is a life saver - thank you so much!
Greets
-act

Hi, I've the exact same problem with a self-hosted GitLab instance!

@actraiser or @TheWiresharkGuy - I don't know that I have a registry with enough old tags at the moment to easily test a fix for this.  If I had a potential fix, could either of you test it for me?


RuntimeError: memory format option is only supported by strided tensors

When I applied the model to my own task, the following error occurred. But I have strided tensors for each one, and I still get the following error. Does anyone know why that is
Traceback (most recent call last):   File "/mnt/c/Users/caica/Desktop/swin/classes/fc4/train.py", line 283, in <module>     main(opt)   File "/mnt/c/Users/caica/Desktop/swin/classes/fc4/train.py", line 105, in main     loss = model.optimize(img, label)   File "/mnt/c/Users/caica/Desktop/swin/classes/fc4/Model_FC4.py", line 40, in optimize     pred = self.predict(img)   File "/mnt/c/Users/caica/Desktop/swin/classes/fc4/Model_FC4.py", line 32, in predict     pred, rgb, confidence = self._network(img)   File "/home/liujunyi/anaconda3/envs/vmamba2/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1511, in _wrapped_call_impl     return self._call_impl(*args, **kwargs)   File "/home/liujunyi/anaconda3/envs/vmamba2/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1520, in _call_impl     return forward_call(*args, **kwargs)   File "/mnt/c/Users/caica/Desktop/swin/classes/fc4/FC_4.py", line 69, in forward     x = self.backbone(x)   File "/home/liujunyi/anaconda3/envs/vmamba2/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1511, in _wrapped_call_impl     return self._call_impl(*args, **kwargs)   File "/home/liujunyi/anaconda3/envs/vmamba2/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1520, in _call_impl     return forward_call(*args, **kwargs)   File "/mnt/c/Users/caica/Desktop/swin/classes/fc4/VMamba_main/classification/models/vmamba.py", line 1514, in forward     o, x = layer_forward(layer, x) # (B, H, W, C)   File "/mnt/c/Users/caica/Desktop/swin/classes/fc4/VMamba_main/classification/models/vmamba.py", line 1507, in layer_forward     x = l.blocks(x)   File "/home/liujunyi/anaconda3/envs/vmamba2/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1511, in _wrapped_call_impl     return self._call_impl(*args, **kwargs)   File "/home/liujunyi/anaconda3/envs/vmamba2/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1520, in _call_impl     return forward_call(*args, **kwargs)   File "/home/liujunyi/anaconda3/envs/vmamba2/lib/python3.10/site-packages/torch/nn/modules/container.py", line 217, in forward     input = module(input)   File "/home/liujunyi/anaconda3/envs/vmamba2/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1511, in _wrapped_call_impl     return self._call_impl(*args, **kwargs)   File "/home/liujunyi/anaconda3/envs/vmamba2/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1520, in _call_impl     return forward_call(*args, **kwargs)   File "/mnt/c/Users/caica/Desktop/swin/classes/fc4/VMamba_main/classification/models/vmamba.py", line 1161, in forward     return self._forward(input)   File "/mnt/c/Users/caica/Desktop/swin/classes/fc4/VMamba_main/classification/models/vmamba.py", line 1149, in _forward     x = x + self.drop_path(self.op(self.norm(x)))   File "/home/liujunyi/anaconda3/envs/vmamba2/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1511, in _wrapped_call_impl     return self._call_impl(*args, **kwargs)   File "/home/liujunyi/anaconda3/envs/vmamba2/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1520, in _call_impl     return forward_call(*args, **kwargs)   File "/mnt/c/Users/caica/Desktop/swin/classes/fc4/VMamba_main/classification/models/vmamba.py", line 745, in forwardv2     y = self.forward_core(x)   File "/mnt/c/Users/caica/Desktop/swin/classes/fc4/VMamba_main/classification/models/vmamba.py", line 706, in forward_corev2     ys: torch.Tensor = selective_scan(   File "/mnt/c/Users/caica/Desktop/swin/classes/fc4/VMamba_main/classification/models/vmamba.py", line 598, in selective_scan     return SelectiveScan.apply(u, delta, A, B, C, D, delta_bias, delta_softplus, nrows, backnrows, ssoflex)   File "/home/liujunyi/anaconda3/envs/vmamba2/lib/python3.10/site-packages/torch/autograd/function.py", line 553, in apply     return super().apply(*args, **kwargs)  # type: ignore[misc]   File "/home/liujunyi/anaconda3/envs/vmamba2/lib/python3.10/site-packages/torch/cuda/amp/autocast_mode.py", line 115, in decorate_fwd     return fwd(*args, **kwargs)   File "/mnt/c/Users/caica/Desktop/swin/classes/fc4/VMamba_main/classification/models/csms6s.py", line 267, in forward     out, x, *rest = selective_scan_cuda_core.fwd(u, delta, A, B, C, D, delta_bias, delta_softplus, 1) RuntimeError: memory format option is only supported by strided tensors

Hello!!!
I also encountered the same problem, can you solve it please?
QAQ  ^^

Do all data (u, delta, A, B, C, D, delta_bias) contiguous in your application?

Hello!!! I also encountered the same problem, can you solve it please? QAQ ^^

I updated the version of pytorch and I solved this problem.becauseI I found that I did not install the selective_scan package properly

Hello!!! I also encountered the same problem, can you solve it please? QAQ ^^

I updated the version of pytorch and I solved this problem.becauseI I found that I did not install the selective_scan package properly

Hello, can you send me the details of how you did it?

Hello!!! I also encountered the same problem, can you solve it please? QAQ ^^

I updated the version of pytorch and I solved this problem.becauseI I found that I did not install the selective_scan package properly

can you tell me your pytorch version?

Hello!!! I also encountered the same problem, can you solve it please? QAQ ^^

I updated the version of pytorch and I solved this problem.becauseI I found that I did not install the selective_scan package properly

can you tell me your pytorch version?

2.1.1+cu121 cuda version=12.3


remove endpoint url uniqueness validation

Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1658207

@agrare @jrafanie Please review.

@AlexanderZagaynov Can you describe why we can remove this?
This was added in https://github.com/ManageIQ/manageiq/pull/12068 for https://bugzilla.redhat.com/show_bug.cgi?id=1382627
Would allow_nil on the validation fix the problem you're trying to solve?

cc @bdunne

@jrafanie as that BZ days, it's impossible to add two or more ems providers with the same proxy URI. However, such option can make sense, if you want to have AWS for some US region, and another one with same proxy for some EU for example.
Even more, it's not a discussion should we have that abilitiy or not. There is blocker BZ with states clearly that we should.

P.S. I see that your BZ should also be considered. So, we need to find a way to satisfy both. Any ideas?

@jrafanie as my BZ says, it's impossible to add two or more ems providers with the same proxy URI. However, such option can make sense, if you want to have AWS for some US region, and another one with same proxy for some EU for example.
Even more, it's not a discussion should we have that abilitiy or not. That is a blocker BZ which states clearly that we should.

yeah, it's unclear if a nil URL is the only case your BZ needs to be fixed.  If yes, allow_nil should resolve it.  If not, then we have to be careful not to "break" what @bdunne's BZ was fixing (https://bugzilla.redhat.com/show_bug.cgi?id=1382627)

@jrafanie sorry, looks like I missed a point in my BZ, that it's not about two endpoints with the same value, but about empty field values. Hovewer, there was already a condition for that validation if: :uri, and that problem didn't arise before, considering that previous change was made quite a lot time ago, and AWS proxy feature was added somewhere in this summer. So, I should ask current BZ author about details.

@AlexanderZagaynov the bz states that the url was left empty:

Probably Endpoint URL is now unique? I left that field empty for both providers.

I just tried this and can confirm leaving the url blank and trying to add two regions fails with that error.  I tried adding allow_nil and I was able to validate credentials but was not able to save the provider.  Assuming this was fixed though this doesn't help if someone actually wants to use a different endpoint url (either a proxy or a custom region) and add multiple regions.
I've always struggled with preventing people from adding the same provider multiple times, just checking for the same hostname doesn't cover the case where the user wants to add the same provider with different credentials.  I've always thought it'd be easier to just warn the user in case they didn't intend to add the same provider again but there's not really any way of really preventing the same provider being added multiple times (can be added multiple times with different IP addresses, dns names, etc... anyway).
I don't think its possible to successfully prevent the same endpoint being added twice in some cases while also allowing it in others.

@agrare I believe we should not prevent adding same provider multiple times, I showed example above with two regions. Even more, I have had such setup in my dev env not so long ago. And I've added two AWSes without any problem at that moment. Maybe something was changed recently.
And about different checks for different provider types - it can be easily made with if: :some_checking_method.

I've found possible reason why that problem did arise. Probably previously empty url field was saved with a nil value, and condition if: :url was working. But now I see that it saves with an empty string in that field, and that condition doesn't apply. I've added allow_blank: true to make it work in both cases, and disabled it for cloud managers.
@jrafanie @agrare please review again

@miq-bot add_label blocker

@AlexanderZagaynov if this will be able to be backported, can you add the hammer/yes label.

@miq-bot add_label hammer/yes

One specific reason we had prevented people from adding the same provider multiple times was in places where we "resurrect" archived VMs.  For example, in VMware, if a VM moves from one provider to another, we find it in the archived list and reattach it to the new provider (e.g. the user is migrating from one physical vSphere to another, and transfers the underlying disks to a different storage and then attaches it to the new provider).  If we didn't have the uniqueness in place, then this mechanism causes the VM to jump back and forth between the systems.  Now, one can argue that we shouldn't have this feature in place, and I'd be ok with discussing removal of that, but the reality at the moment is that this feature exists.

@Fryguy we speak about endpoints here, not about same providers

we speak about endpoints here, not about same providers

Provider uniqueness is handled by the endpoints since ext_management_system doesn't actually have a hostname/url it delegates that to the default endpoint.

in that case we have bad design I guess. but let's stay with simple workarounds for now :)

in that case we have bad design I guess. but let's stay with simple workarounds for now :)

I blame @juliancheal since he did the endpoint stuff :laughing:
Seriously though multiple endpoints for a provider is a big improvement over how it used to be, and uniquely identifying a provider is a genuinely hard problem that even hostname checks can't accomplish 100% (see my comment here https://github.com/ManageIQ/manageiq/pull/18298#issuecomment-448040280) and not every provider has a "uuid" like a vSphere vCenter does which would allow us to do the unique check properly.

I blame @juliancheal since he did the endpoint stuff 😆

I tried to avoid this PR, but thanks @agrare 😂
I'm not totally caught up on this PR, but let me know if you need any help 🎩

If we didn't have the uniqueness in place, then this mechanism causes the VM to jump back and forth between the systems

We'd actually be okay here since when reconnecting we look for vms with the same ems_id or nil so an active vm on another provider won't be found (https://github.com/ManageIQ/manageiq/blob/master/app/models/ems_refresh/save_inventory.rb#L102)

Hammer backport details:
$ git log -1
commit 11c820248cb09df93f3d7b4d66e43eac6bbd1006
Author: Adam Grare<EMAIL_ADDRESS>Date:   Thu Dec 20 12:29:13 2018 -0500

    Merge pull request #18298 from AlexanderZagaynov/BZ-1658207

    fix endpoint url uniqueness validation, and disable it for cloud providers

    (cherry picked from commit b8927b0e9ff881f55152967a870a98df22a59c58)

    Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1658207

@agrare Ah yeah, I edited my comment but too late :smile:


Move Metamodel Content from Part 2 to Part 1

Move Clause 11.4 (Value-Only and idShortPath) and Clause 12.5 (Metadata Objects) from Part 2, V3.0 to Part 1.
See also https://github.com/admin-shell-io/aas-specs/issues/325

Done, see https://github.com/admin-shell-io/aas-specs/pull/326 and https://github.com/admin-shell-io/aas-specs-api/pull/213


NAK errors

It looks like this is partially working but I'm getting some NAK Errors and the program crashes when the analyzer starts to capture data.
Using Python 3.5.0

saleae.demo()
Running Saleae connection demo.

Saleae connected.
Press Enter to continue...
Set performance to full.
Press Enter to continue...
Connected devices:
<saleae.ConnectedDevice #1 LOGIC_PRO_8_DEVICE Logic Pro 8 (ffcda53224bbb23a) ACTIVE>
Only one Saleae device. Skipping device selection
Press Enter to continue...
Setting active channels (digital=[0, 1, 2, 3, 4], analog=[0, 1])
Press Enter to continue...
Reading back active channels:
digital=[0, 1, 2, 3, 4]
analog=[0, 1]
Press Enter to continue...
Setting to capture 2e6 samples
Press Enter to continue...
Setting to sample rate to at least digitial 4 MS/s, analog 100 S/s
Set to (100000000, 100)
Press Enter to continue...
Starting a capture
Traceback (most recent call last):
File "", line 1, in
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/saleae/saleae.py", line 546, in demo
while not s.is_processing_complete():
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/saleae/saleae.py", line 360, in is_processing_complete
resp = self._cmd('IS_PROCESSING_COMPLETE')
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/saleae/saleae.py", line 116, in _cmd
ret = self._recv()
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/saleae/saleae.py", line 107, in _recv
raise self.CommandNAKedError
saleae.saleae.CommandNAKedError

s = saleae.Saleae()
s.capture_to_file('~/Desktop/test.logicdata')
Traceback (most recent call last):
File "", line 1, in
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/saleae/saleae.py", line 354, in capture_to_file
self._cmd('CAPTURE_TO_FILE, ' + file_path_on_target_machine)
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/saleae/saleae.py", line 116, in _cmd
ret = self._recv()
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/saleae/saleae.py", line 107, in _recv
raise self.CommandNAKedError
saleae.saleae.CommandNAKedError

It looks like it is failing when it tries to open the file to save to:
s.capture_to_file('~/Desktop/test.logicdata')
Does that path exist on the machine that the Logic software is running on
and does Logic have permission to write that file? The ~ path likely won't
work on a Windows machine.
There's no good way for the script to do platform detection of the remote
machine. It could be modified to prompt / ask though.
On Fri, Oct 30, 2015 at 14:26 AnalogIO<EMAIL_ADDRESS>wrote:

It looks like this is partially working but I'm getting some NAK Errors
and the program crashes when the analyzer starts to capture data.
Using Python 3.5.0
saleae.demo()
Running Saleae connection demo.
Saleae connected.
Press Enter to continue...
Set performance to full.
Press Enter to continue...
Connected devices:
Only one Saleae device. Skipping device selection
Press Enter to continue...
Setting active channels (digital=[0, 1, 2, 3, 4], analog=[0, 1])
Press Enter to continue...
Reading back active channels:
digital=[0, 1, 2, 3, 4]
analog=[0, 1]
Press Enter to continue...
Setting to capture 2e6 samples
Press Enter to continue...
Setting to sample rate to at least digitial 4 MS/s, analog 100 S/s
Set to (100000000, 100)
Press Enter to continue...
Starting a capture
Traceback (most recent call last):
File "", line 1, in
File
"/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/saleae/saleae.py",
line 546, in demo
while not s.is_processing_complete():
File
"/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/saleae/saleae.py",
line 360, in is_processing_complete
resp = self._cmd('IS_PROCESSING_COMPLETE')
File
"/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/saleae/saleae.py",
line 116, in _cmd
ret = self._recv()
File
"/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/saleae/saleae.py",
line 107, in _recv
raise self.CommandNAKedError
saleae.saleae.CommandNAKedError
s = saleae.Saleae()
s.capture_to_file('~/Desktop/test.logicdata')
Traceback (most recent call last):
File "", line 1, in
File
"/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/saleae/saleae.py",
line 354, in capture_to_file
self._cmd('CAPTURE_TO_FILE, ' + file_path_on_target_machine)
File
"/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/saleae/saleae.py",
line 116, in _cmd
ret = self._recv()
File
"/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/saleae/saleae.py",
line 107, in _recv
raise self.CommandNAKedError
saleae.saleae.CommandNAKedError
—
Reply to this email directly or view it on GitHub
https://github.com/ppannuto/python-saleae/issues/7.

I'm testing on a Mac so the '~/Desktop/' folder does exist.  I don't have a file already called test.logicdata at this path but I assume that is ok.

I'm testing this some more, here is the latest output
Setting to sample rate to at least digitial 4 MS/s, analog 100 S/s
Set to (100000000, 100)
Press Enter to continue...
Starting a capture
Traceback (most recent call last):
File "", line 1, in
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/saleae/saleae.py", line 546, in demo
while not s.is_processing_complete():
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/saleae/saleae.py", line 360, in is_processing_complete
resp = self._cmd('IS_PROCESSING_COMPLETE')
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/saleae/saleae.py", line 116, in _cmd
ret = self._recv()
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/saleae/saleae.py", line 107, in _recv
raise self.CommandNAKedError
saleae.saleae.CommandNAKedError
It looks to me like the 'IS_PROCESSING_COMPLETE' cmd is resulting in a NAK error.  Is it possible that if processing is not complete it returns a NAK?

Internally, the Saleae software has some (previously not documented) requirements:
The path needs to be absolute.
The target directory needs to exist.
I've just updated the documentation, which you can find here:
https://github.com/saleae/SaleaeSocketApi/tree/master/Doc
We've moved the Saleae examples and documentation to GitHub when we released 1.2.5:
https://github.com/saleae/SaleaeSocketApi
The IS_PROCESSING_COMPLETE command is supposed to NAK when capture processing is not complete, this is in the documentation too. Generally you should wait in a loop until the function returns ACK.

ok so now I am able to start captures via python but I am unable to export the data as csv.
I am using the following code:
import saleae
s = saleae.Saleae()
s.capture_start_and_wait_until_finished()
s.export_data('/Users/lgbeno/Documents/logic_captures/test.csv')

The logic captures folder does exist, test.csv does not.  The commands execute just fine but no file can be found after execution.

Pipe the output of the Logic binary to a file when you launch it, and then run the script. After the script completes, post a copy of the log file. That might contain useful information about the export process. Make sure you're using 1.2.5, it prints out much more detailed debug data when socket based export commands are not properly formed.
Also, the data export command is crazy complicated. I created a new command, EXPORT_DATA2, which formally covers all possible export combinations, where the original EXPORT_DATA command didn't actually handle all possible export options properly.
Here is the C# source for the export_data2 wrapper:
https://github.com/saleae/SaleaeSocketApi/blob/master/SaleaeSocketApi/SocketApi.cs#L389
Here are the tests we scripted to test all significant export option variants:
https://github.com/saleae/SaleaeSocketApi/blob/master/SaleaeSocketApiUnitTests/ExportUnitTests.cs
The API is a 1 to 1 direct mapping to the internal settings struct that is configured with the normal socket GUI. unfortunately it's not possible to use the GUI to create a socket command, but at least you can see what settings need to be set from the GUI based on your capture settings, and then try to replicated then in the API.
The socket export command is very sensitive to the type of data you captured. Like this:
Even if you're just exporting digital, it still matters if you capture analog or not.
If you tell me what analog and digital channels you had active, and what kind of file you want (CSV, just digital, etc) I can help form the correct command.
You can also use the examples from the ExportUnitTests.cs file to find an export mode that closest matches your situation.

So I've been trying to pipe out that data, this is what I put into the terminal to launch but not having any luck:
'''
open ./Logic.app/ > ~/Desktop/logic_log_dump.txt
'''

I've never tried this using open before. Here is how I normally capture the log on OSX:
cd /
./Applications/Logic.app/Contents/MacOS/Logic > ~/log.txt

That worked much better...
'''exe File path is /Applications/Logic.app/Contents/MacOS/Logic  [ /Users/build/ob_logic/Source/Environment.cpp; Environment; 260 ]
exe folder path is /Applications/Logic.app/Contents/MacOS  [ /Users/build/ob_logic/Source/Environment.cpp; Environment; 261 ]
Release Mode; analyzer path is /Applications/Logic.app/Contents/Resources/Analyzers  [ /Users/build/ob_logic/Source/Environment.cpp; Environment; 283 ]
Release Mode; exe path is /Applications/Logic.app/Contents/MacOS; user path is /Users/lgbeno  [ /Users/build/ob_logic/Source/Environment.cpp; Environment; 318 ]
Found log directory at Library//Logs//DiagnosticReports  [ /Users/build/ob_logic/Source/Environment.cpp; Environment; 327 ]
[ /Users/build/ob_logic/Source/OsxDevicesManager.cpp; InitializeUsbDevices; 73 ]
First device connected. Creating Primary Display.  [ /Users/build/ob_logic/Source/LogicWindow_Devices.cpp; AttachedDevicesChangedSlot; 70 ]
GeneratePixmapEllipses: 1.302356 seconds  [ /Users/build/ob_logic/Source/AnalogDisplayEngine.cpp; AnalogDisplayEngine; 38 ]
device change has triggered sprucing up the empty capture tab.  [ /Users/build/ob_logic/Source/LogicWindow_Controller.cpp; ActiveDeviceChanged; 454 ]
setting PrimaryDisplay's Session to NULL.  [ /Users/build/ob_logic/Source/PrimaryDisplay.cpp; SetSession; 562 ]
New Socket Connection, port: 10429  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; NewConnectionSlot; 61 ]
Received command on port 10429: CAPTURE  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketReadyReadSlot; 129 ]
changing active tab to: 0  [ /Users/build/ob_logic/Source/LogicWindow_Controller.cpp; ActiveTabChangedSlot; 58 ]
Setting API Session to 0. Previous id: 0  [ /Users/build/ob_logic/Source/ApiServer.cpp; SetActiveSession; 685 ]
setting PrimaryDisplay's Session to NULL.  [ /Users/build/ob_logic/Source/PrimaryDisplay.cpp; SetSession; 562 ]
Starting capture with device ID:<PHONE_NUMBER>, Type: 4  [ /Users/build/ob_logic/Source/LogicWindow_Collection.cpp; startSlot; 52 ]
Creating and Starting API capture session 1  [ /Users/build/ob_logic/Source/ApiServer.cpp; CreateNewCaptureSession; 506 ]
Starting capture. LCM: 12000000, Digital:12000000, Analog:6000000, Digital Multiplier:1, Analog Multipler:2, Device Type:4  [ /Users/build/ob_logic/Source/DataFacade.cpp; StartCollection; 260 ]
Received command on port 10429: IS_PROCESSING_COMPLETE  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketReadyReadSlot; 129 ]
Could not understand command  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketReply; 3902 ]
Successfull collection complete with id: 1  [ /Users/build/ob_logic/Source/LogicWindow_Collection.cpp; CollectionCompleteSlot; 427 ]
setting PrimaryDisplay's Session to a valid session, 1  [ /Users/build/ob_logic/Source/PrimaryDisplay.cpp; SetSession; 564 ]
Success  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketReply; 3904 ]
Received command on port 10429: IS_PROCESSING_COMPLETE  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketReadyReadSlot; 129 ]
Success  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketReply; 3904 ]
Received command on port 10429: IS_PROCESSING_COMPLETE  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketReadyReadSlot; 129 ]
Success  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketReply; 3904 ]
Received command on port 10429: IS_PROCESSING_COMPLETE  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketReadyReadSlot; 129 ]
Success  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketReply; 3904 ]
Received command on port 10429: EXPORT_DATA, /Users/lgbeno/Doc  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketReadyReadSlot; 129 ]
Exporting data  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketExportData; 1508 ]
export command error: save directory does not exist  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketExportData; 1559 ]
Could not understand command  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketReply; 3902 ]
Received command on port 10429: IS_PROCESSING_COMPLETE  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketReadyReadSlot; 129 ]
Success  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketReply; 3904 ]
Received command on port 10429: IS_PROCESSING_COMPLETE  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketReadyReadSlot; 129 ]
Success  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketReply; 3904 ]
Received command on port 10429: EXPORT_DATA, /Users/lgbeno/Doc  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketReadyReadSlot; 129 ]
Exporting data  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketExportData; 1508 ]
export command error: save directory does not exist  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketExportData; 1559 ]
Could not understand command  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketReply; 3902 ]
Received command on port 10429: IS_PROCESSING_COMPLETE  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketReadyReadSlot; 129 ]
Success  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketReply; 3904 ]
Received command on port 10429: IS_PROCESSING_COMPLETE  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketReadyReadSlot; 129 ]
Success  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketReply; 3904 ]
Received command on port 10429: EXPORT_DATA, /Users/lgbeno/Doc  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketReadyReadSlot; 129 ]
Exporting data  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketExportData; 1508 ]
Could not understand command  [ /Users/build/ob_logic/Source/LogicWindow_Automation.cpp; SocketReply; 3902 ]
'''

Thanks for the log. Unfortunately, it looks like there isn't any more information about the cause of the issue here.
What would really help is a copy of the text string that the python code sent to the Logic application. It looks like the python code is already logging it. Right before the message is sent to the socket, this is called:
log.debug("Send >{}<".format(s))
from the _send function. If you can grab that string from the log file, and tell me exactly which channels you had active in your capture, I can reproduce the issue over here.
Also, from your log, I can see that you captured both digital and analog channels, but only selected digital channels for export. There are special requirements for this, and I think it's one of the edge cases that caused us to write EXPORT_DATA2 to replace EXPORT_DATA, which this python wrapper is currently using.
As soon as I have the log from the python script and which channels were active in the capture, I can figure out what's going wrong.

Here's the latest log: https://gist.github.com/analog-io/bd1a52474cd68fddb371
I was not able to grab the log from python but I did step debug the code in pyCharm and extracted this string that was constructed from:
import saleae
s = saleae.Saleae()
s.capture_start()
s.export_data('/Users/lgbeno/Desktop/test.csv',[4,5,6,7])

'EXPORT_DATA, /Users/lgbeno/Desktop/test.csv, digital_channels, 4, 5, 6, 7, all_time, csv, headers, comma, time_stamp, combined, row_per_change, hex'

For the future, the library uses the standard Python logging facility. Before calling saleae.demo()
import logging, saleae
logging.basicConfig(level=logging.DEBUG)
saleae.demo()

I can also add something to pick up a DEBUG environment variable.

@analog-io, which analog and digital channels were enabled when the capture was taken? I'll need that to reproduce your capture settings correctly, as that information is not in the software output.

Thanks, just those channels were open in Logic.

@Marcus10110 has there been an update on this?

Sorry for the long delay on this! I did find a bug in the Logic software - the EXPORT_DATA function only checks for the "ROW_PER_CHANGE"/"ROW_PER_SAMPLE" parameter if "SEPARATE" is specified instead of "COMBINED".
Then, also incorrectly, the software still requires the display radix, even if "SEPARATE" is specified.
Basically, the correct behavior is that the display radix parameter (hex/dec/bin/etc) should only be required if "COMBINED" is specified.
However, the conditionals are messed up in the code, and instead what it actually does is the density parameter ("ROW_PER_CHANGE"/"ROW_PER_SAMPLE") is only parsed if the "SEPARATE" parameter is specified, which is of course unrelated.
The good news is that when the density parameter  ("ROW_PER_CHANGE"/"ROW_PER_SAMPLE")  is not parsed, it uses the previously specified value, so you can set this manually once in the export settings in the GUI, and then it should get preserved. Plus ROW_PER_CHANGE is the default mode in the software.
The command that works:
"EXPORT_DATA, C:\QuickShare\test_py_support.csv, digital_channels, 4, 5, 6, 7, all_time, csv, headers, comma, time_stamp, combined, hex"
(I changed the save path because I'm on windows)
Because we've deprecated the EXPORT_DATA command, I'm not sure if I should fix it in the Saleae software.
The good news is that this is not broken in EXPORT_DATA2, which replaced EXPORT_DATA. Unfortunately, EXPORT_DATA2 hasn't been ported from our C# example application to this Python library, and I won't have the time to take care of this.
The ideal solution would be to update this library to no longer use the EXPORT_DATA function, and use the new one, but unfortunately I don't have the time right now to do that. A short term solution would be to work around this my supporting the bug above.

Thanks for the update and looking into this.  Really appreciate it and understand theres a million things to do.  Knowing this issue I'll either hack my local code to work or attempt to port the C# version to Python and do a pull request.  Thanks again!

Yes thanks @Marcus10110 that's very helpful for the EXPORT_DATA command. Hopefully someone will find time to get EXPORT_DATA2 ported soon.
Unfortunately I'm also seeing an NAK error when running the demo(). This doesn't ever call export_data() as far as I can tell.
I'm getting the following failure:
Traceback (most recent call last):
  File "saleae.py", line 640, in <module>
    demo()
  File "saleae.py", line 630, in demo
    while not s.is_processing_complete():
  File "saleae.py", line 417, in is_processing_complete
    resp = self._cmd('IS_PROCESSING_COMPLETE')
  File "saleae.py", line 126, in _cmd
    ret = self._recv()
  File "saleae.py", line 117, in _recv
    raise self.CommandNAKedError
__main__.CommandNAKedError

So it seems there is some problem with "IS_PROCESSING_COMPLETE"?
Additionally, one of my colleagues is getting the error below when calling capture_to_file() which also doesn't call EXPORT_DATA as far as I can tell.
s = saleae.Saleae()
s.capture_to_file("<user_path>\saleae.logicdata")
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "build\bdist.win-amd64\egg\saleae\saleae.py", line 411, in capture_to_file
  File "build\bdist.win-amd64\egg\saleae\saleae.py", line 126, in _cmd
  File "build\bdist.win-amd64\egg\saleae\saleae.py", line 117, in _recv
saleae.saleae.CommandNAKedError

Has the API for CAPTURE_TO_FILE changed as well?

First "IS_PROCESSING_COMPLETE"
I think this is a race condition in the Logic software. Try adding a 100 ms wait after the capture command, before calling IS_PROCESSING_COMPLETE.
Basically, the capture command ACKs right after the capture is complete, but the software is still running some housekeeping to get the capture data to the screen and the UI state updated.
"IS_PROCESSING_COMPLETE" checks the UI state to make sure that the capture tab is active and has data, but this won't happen until a split second after the capture completes.
Alternatively, instead of adding the wait statement, the first NAK exception could just be ignored.
About the second issue "CAPTURE_TO_FILE": does the capture still start in the software? It will NAK if there is a problem with the command, or if a capture error occurred and no data was recorded.
Also, is the <user_path> path mentioned here absolute? It can't start with ~, our software doesn't support that. I really should fix that.
I've gone through the source and added console print statements for the different conditions that cause NAKs in several of the common commands. 1.2.6 comes out this Friday, and when it does, we can check the console output for more information.

cc: @Marcus10110 from Saleae
These race conditions / CommandNAKedErrors are widespread throughout python-saleae and/or the Saleae Logic software.
For example, if I repeatedly run get_active_channels(), I get errors the first several times, and then it happens to succeed on the 4th or 5th try. Here's an example:

sal.get_active_channels()
Traceback (most recent call last):
File "", line 1, in
File "<...>/saleae.py", line 368, in get_active_channels
channels = self._cmd('GET_ACTIVE_CHANNELS')
File "<...>/saleae.py", line 131, in _cmd
ret = self._recv()
File "<...>/saleae.py", line 122, in _recv
raise self.CommandNAKedError
CommandNAKedError
sal.get_active_channels()
Traceback (most recent call last):
File "", line 1, in
File "<...>/saleae.py", line 370, in get_active_channels
assert msg.pop(0) == 'digital_channels'
AssertionError
sal.get_active_channels()
Traceback (most recent call last):
File "", line 1, in
File "<...>/saleae.py", line 370, in get_active_channels
assert msg.pop(0) == 'digital_channels'
AssertionError
sal.get_active_channels()
Traceback (most recent call last):
File "", line 1, in
File "<...>/saleae.py", line 370, in get_active_channels
assert msg.pop(0) == 'digital_channels'
AssertionError
sal.get_active_channels()
([7], [])

SUDDENLY IT WORKS! Maybe I just got lucky and the race condition didn't occur the 5th time!
I've worked around this in the capture and data-export by replacing occurrences of is_processing_complete() with the following:
'''python
def wait_for_processing_complete(self, timeout=5):
"""Wraps self.is_processing_complete with more lenient waiting.
	There is some race condition in the Saleae software!

	Args:
		timeout: (int) seconds before timeout
	Raises:
		IOError: if timed out
	"""
	tic = time.time()
	time.sleep(0.2)
	done = False
	while not done:
		try:
			# Check for timeout in outer loop
			if time.time() - tic > timeout:
				self.capture_stop()
				raise IOError('Saleae timeout {} reached.'.format(timeout))

			while not self.is_processing_complete():
				# Check for timeout in inner loop
				if time.time() - tic > timeout:
					self.capture_stop()
					raise IOError('Saleae timeout = {}sec reached!'.format(timeout))
				time.sleep(0.2)
			done = True
		except self.CommandNAKedError:
			# This exception is raised if processing of capture is not complete on the
			# side of the analyzer. This is expected for the first few calls, so we
			# simply ignore it until is_processing_complete returns true
			pass

'''
And for file export, I use 'os' to poll for the output file existing and having the same size in two successive samples, using a similar timeout scheme.
It would be nice if sal.is_processing_complete() actually worked, and someone cleaned up what I'm assuming are race conditions / bugs in the Saleae backend. I contacted Saleae support about the issue and they suggested I cc @Marcus10110 from Saleae on this report.

A similar workaround seems to work for _recv(...):

	def _recv(self, timeout=1):
		tic = time.time()
		done = False
		while not done:
			try:
				if time.time() - tic > timeout:
					raise IOError('Saleae timeout = {}sec reached.'.format(timeout))

				while 'ACK' not in self._rxbuf:
					if time.time() - tic > timeout:
						raise IOError('Saleae timeout = {}sec reached.'.format(timeout))

					self._rxbuf += self._s.recv(1024).decode('UTF-8')
					log.debug("Recv >{}<".format(self._rxbuf))
					if 'NAK' == self._rxbuf[0:3]:
						self._rxbuf = self._rxbuf[3:]
						raise self.CommandNAKedError
				ret, self._rxbuf = self._rxbuf.split('ACK', 1)
				done = True
			except self.CommandNAKedError:
				pass
		return ret

get_active_channels NAKs for 2 reasons:

Logic (original unit) is the active device. This is the only device that does not support any channel configuration changes.
The active channels list contains no elements. We seem to have special case code to handle this case, which would lead me to believe that at some point we had a problem with it. The software is designed to make it impossible to have no channels selected. My guess is that there are intermediate states where this could be the case. I know that the vector is initialized empty, so it's possible that the list is empty after starting the software and waiting for the attached device to initialize.

@analog-io Were you able to hack your local code? Do you have any partial solution at least?

@Marcus10110 Could you be more specific on how we are supposed to change the parameters in the GUI to make it work? Thanks


Use wrong tsconfig when exists multiple tsconfig files

I'm using it in an nx mono repo containing many tsconfig files.
When running storybook, I saw vite-tsconfig-paths scanned all config files but used the wrong one, which excluded *.stories.tsx files.
Is there a way to specify which tsconfig file to use?

tsconfig for storybook

{
  "extends": "../tsconfig.json",
  "compilerOptions": {
    "emitDecoratorMetadata": true,
    "outDir": ""
  },
  "files": [
<EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS>  ],
  "exclude": [
    "../**/*.spec.ts",
    "../**/*.spec.js",
    "../**/*.spec.tsx",
    "../**/*.spec.jsx"
  ],
  "include": [
    "../src/**/*.stories.ts",
    "../src/**/*.stories.js",
    "../src/**/*.stories.jsx",
    "../src/**/*.stories.tsx",
    "../src/**/*.stories.mdx",
    "*.js",
    "preview.jsx"
  ]
}

tsconfig.lib.json, used for bundling, generated by nx

{
  "extends": "./tsconfig.json",
  "compilerOptions": {
    "outDir": "../../dist/out-tsc",
    "types": ["node", "vite/client"]
  },
  "files": [
<EMAIL_ADDRESS><EMAIL_ADDRESS>  ],
  "exclude": [
    "**/*.spec.ts",
    "**/*.test.ts",
    "**/*.spec.tsx",
    "**/*.test.tsx",
    "**/*.spec.js",
    "**/*.test.js",
    "**/*.spec.jsx",
    "**/*.test.jsx",
    "**/*.stories.ts",
    "**/*.stories.js",
    "**/*.stories.jsx",
    "**/*.stories.tsx"
  ],
  "include": ["**/*.js", "**/*.jsx", "**/*.ts", "**/*.tsx"]
}

Are you not in control of vite-tsconfig-paths options in your NX project?

Same issue.
projects option doesn't help.
I haven't browsed the code in this pkg, but if the comment left in code is how it works, then the extends is buggy:

The extends property is supported.

Please include debug logs and a reproduction in your bug report.
DEBUG=vite-tsconfig-paths vite

Thank you for the reply.
I think the use of a plugin could be completely replaced w/ a function below, it works for my needs:
export const getResolveConfig = (tsconfig: TsConfigJson) => {
  const resolveConfig = {
    alias: []
  }

  const paths = tsconfig.compilerOptions?.paths;
  if (!paths) return resolveConfig;

  const tsconfigAliasPaths = Object.keys(paths).map((key): Alias => {
    const value = paths[key][0];
    return {
      find: key.replace('/*', ''),
      replacement: resolve(value.replace('/*', '')),
    };
  });
  resolveConfig.alias = [...resolveConfig.alias, ...tsconfigAliasPaths];

  return resolveConfig;
};

There was a similar comment from @matthew-dean in #116. My response can be seen here: https://github.com/aleclarson/vite-tsconfig-paths/issues/116#issuecomment-1571068640
If you could repost your function in that thread, it wouldn't be off-topic. 👍

Are you not in control of vite-tsconfig-paths options in your NX project?
You could try setting the projects option if you are.

Thanks for your reply. projects is looking for a package.json, not working for my case. Resolved by overwriting vite config alias


Initialise CircleCI: Part 1

I'm going to merge this PR anyway since seemingly there should be .circleci/config.yml in the master brunch to properly setup CircieCI.


Update to .Net 6

just some updates for .net 6.0 and other changes including start of gui. fixed icon and directory selction

just some updates for .net 6.0 and other changes including start of gui. fixed icon and directory selction

Thank you  🙏🏻

Please commit changes @bruhov <3


Fix constraints and update yarn lock at the end of release process

Add a new step at the end of release process to fix constraints and update yarn lock

@kanthesha yes for the test failing in the testing configuration I need to add a constraints file, currently working on it.
For the intentionally skip, yes the ticket doesn't update changelog there's another ticket for updating changelog for bumbed packages. The scope of this ticket is to fix constraints and update lock only.

Also can we update the PR description to describe the problem that we are solving here and how the changes solve that problem instead of just describing the changes? That would help us understand the context behind this PR in the future.

Also can we update the PR description to describe the problem that we are solving here and how the changes solve that problem instead of just describing the changes? That would help us understand the context behind this PR in the future.

I updated the description

Just repeating my comment above about adding a functional test here. I think the problem that running yarn was intended to solve was so that the release PR wouldn't fail CI. CI runs yarn --immutable and then it runs yarn constraints as a part of the lint step, so it seems like we ought to have a test that runs the tool, then runs yarn --immutable, then yarn constraints and expects both of these commands to return an exit code of 0. This way we can be sure that we've solved the original problem. Is this possible to add?


view-enhancement branch goal and ready-ness

I'm ready to start implementing terminating nodes (switches and lights) into the view and I was wondering whether it would be appropriate to continue this branch or start a separate one.
If you recommend implementing those in their own branch, should we merge these changes to main first (If this branch is considered complete by it's author)?
I'd also like to use additions from branch beginning-and-ending-nodes so we should keep that in mind.

I believe it to be ready for continuation. You could either merge the now updated main into the branch or merge this into main then rebase main onto this branch. Both options have the same result, but the first option is less steps so I'd go with that.


Client Lags When Loading New Chunks On A Large Sized World.

So, My Server's Survival World Will Lag When I Am Loading New Chunks, Does Not Bring TPS Down, Only Brings FPS Down To Like 1fps. I Want This Resolved As Soon As Possible. This Really Effects The Performance Of My Base Building, Also I Am The Only One On The Survival World.
How To Recreate: (At Least For Me)

Get A World Of The Size Of 24.2 MBs Or Actual Size 43 MBs
Load New Chunks

This Is A Very Odd Bug, I Do Not Know What Is Causing This Lag.

New chunk loading has always been known to cause a lot of lag, you can pre-generate chunk generator https://www.spigotmc.org/resources/chunky.81534/ and latest papermc to mitigate this.

Also next time, please follow the issue template.


Account restriction - outgoing operation restriction

I had initiated the operation restriction (outgoing) under address restriction , transaction is confirmed , then i tried to transfer aount XEM to another account, my understanding is that account restriction for outgoing for this address need to be restricted..in that case here the transfer transaction is working . is my understanding correct ? kindly review

@surekabpm you blocked here Outgoing transactions with type Account address restrictions.
It's not about all outgoing transactions but transaction with restrictions for Account address
Because of the above, I'm closing as not a bug.


运行superglue 中的convert_to_onnx.py 报错如下，不懂怎么解决，求助

Loaded SuperGlue model ("indoor" weights)
/home/xh/.local/lib/python3.6/site-packages/torch/onnx/utils.py:363: UserWarning: Skipping _decide_input_format
-1
warnings.warn("Skipping _decide_input_format\n {}".format(e.args[0]))
Traceback (most recent call last):
File "convert_to_onnx.py", line 71, in
main()
File "convert_to_onnx.py", line 55, in main
"matching_scores1": {0: "batch_size", 1: "num_keypoints1"},
File "/home/xh/.local/lib/python3.6/site-packages/torch/onnx/init.py", line 320, in export
custom_opsets, enable_onnx_checker, use_external_data_format)
File "/home/xh/.local/lib/python3.6/site-packages/torch/onnx/utils.py", line 111, in export
custom_opsets=custom_opsets, use_external_data_format=use_external_data_format)
File "/home/xh/.local/lib/python3.6/site-packages/torch/onnx/utils.py", line 729, in _export
dynamic_axes=dynamic_axes)
File "/home/xh/.local/lib/python3.6/site-packages/torch/onnx/utils.py", line 493, in _model_to_graph
graph, params, torch_out, module = _create_jit_graph(model, args)
File "/home/xh/.local/lib/python3.6/site-packages/torch/onnx/utils.py", line 437, in _create_jit_graph
graph, torch_out = _trace_and_get_graph_from_model(model, args)
File "/home/xh/.local/lib/python3.6/site-packages/torch/onnx/utils.py", line 388, in _trace_and_get_graph_from_model
torch.jit._get_trace_graph(model, args, strict=False, _force_outplace=False, _return_inputs_states=True)
File "/home/xh/.local/lib/python3.6/site-packages/torch/jit/_trace.py", line 1166, in _get_trace_graph
outs = ONNXTracedModule(f, strict, _force_outplace, return_inputs, _return_inputs_states)(*args, **kwargs)
File "/home/xh/.local/lib/python3.6/site-packages/torch/nn/modules/module.py", line 1102, in _call_impl
return forward_call(*input, **kwargs)
File "/home/xh/.local/lib/python3.6/site-packages/torch/jit/_trace.py", line 132, in forward
self._force_outplace,
File "/home/xh/.local/lib/python3.6/site-packages/torch/jit/_trace.py", line 118, in wrapper
outs.append(self.inner(*trace_inputs))
File "/home/xh/.local/lib/python3.6/site-packages/torch/nn/modules/module.py", line 1102, in _call_impl
return forward_call(*input, **kwargs)
File "/home/xh/.local/lib/python3.6/site-packages/torch/nn/modules/module.py", line 1090, in _slow_forward
result = self.forward(*input, **kwargs)
TypeError: forward() missing 7 required positional arguments: 'scores0', 'keypoints0', 'descriptors0', 'image1_shape', 'scores1', 'keypoints1', and 'descriptors1'

@XuHao9166 Can you describe the steps you did in English please?


0082 - Remove Duplicates from Sorted List II

Description of the Problem
Given a sorted linked list, delete all nodes that have duplicate numbers, leaving only distinct numbers from the original list.
Return the linked list sorted as well.
Example
Input: 1->2->3->3->4->4->5
Output: 1->2->5

Code
# Definition for singly-linked list.
#class ListNode:
#    def __init__(self, val=0, next=None):
#        self.val = val
#        self.next = next
class Solution:
    def deleteDuplicates(self, head: ListNode) -> ListNode:

Link To The LeetCode Problem
LeetCode

Please assign the issue to me. Thanks

please assign this task to me

please assign the issue to me i would like to work on this! thank you


thanks for Multus-service

I have not tried multus-service yet. But my requirement as follows
I have a dedicated server setup with dual nic (1Gbits and 10Gbits)
use 10Gbit for all my pods
Why I need 10Gbit?
a) I want CEPH-ROOK to have faster connection
b) I want mariadb galera to communicate faster in replication
I found that, it is not possible to use 10Gbit as my primary interface in pods other than have it as secondary interface unless I know a lot about CNI
ROOK-CEPH provided an option to use multus network and it make use of it. So requirement A solved
Now, I want to solve B, unless I found a way to use secondary network as primary this cannot be solved, then I am looking for some thing which helps me to use my secondary NIC for service and I found multus-service
now my requirements are met, please believe that, this will help many users to solve complex issue, so please contribute it. If possible add donation link to show support.

Thank you for your feedback to multus-service and happy that multus-service fits your requirements!
Currently this repository is still in prototype to get feedback and gather requirements because several challenge is still in this area:

integration with load-balancer
needs to change (or somehow to avoid) Kubernetes implementation (some Kubernetes code of course expects that only one interface in Pod/container and no additional interfaces)

We, network plumbing working group, continue to work on that and find a way for that. Keep in touch!


Add a test for each paragraph in the Headers exercise

A student couldn't figure out what was wrong with their code in their solutions for the Headers exercise. Part of the problem was that the tests are not comprehensive. Their code  was missing a period in the
 and the first paragraph which should've been
English: Hello World
:

The test result reports the period error, but doesn't state that there's an expected
English: Hello World
. Can we add a test to cover each paragraph?

There is no expected
English: Hello World
 on this exercise. This exercise only has two tests:
  it "has an h1 tag" do
    expect(index).to have_tag('h1')
  end

  it "has 'Hello World Translations' within an h1 tag" do
    expect(index).to have_tag('h1', text: 'Hello World Translations')
  end

All the student needs to pass this exercise is correct
 text

Weird, I could've sworn I tested that. I double-checked and you are correct. Sorry about the false alarm.


Add CMake

For my personal needs, I've added CMake to the Dockerfile. I thought I could share it, in case my work may be interesting for others.
Is it proper etiquette to open a PR directly, or is it preferable that I open an issue beforehand? I really like this project and I want to contribute back, but I don't want to come across as insisting.

Regarding the code itself, there's a small detail I'd like to specify:
There are two ways to configure CMake before building: with another build of CMake, or with a bootstrap script. The bootstrap script doesn't support cross-compilation, so I had to install CMake with apt to cross-compile CMake to Windows. I could also compile CMake from source locally, using the downloaded source code and the bootstrap script, then use that build to cross-compile CMake afterwards. It would be cleaner, but it would increase the build time. If this PR sounds interesting, which option would be preferable?

Thanks for sharing your change, Semphriss. I'm excited you were able to
leverage w64devkit for your own purposes, and this is exactly one of the
use cases I had in mind. Hopefully other people will find this useful.
Opening a PR like this is perfectly fine. The potential issue would be
that the project doesn't want the feature/fix/etc. and you've wasted a lot
of your time developing it, which could have been avoided with a bit of
advance discussion. However, these changes are already personally useful
to you, and so nothing is wasted. You're just sharing something already
useful.
That being said, I'm uninterested in distributing CMake in w64devkit. The
kit is my curation of essentials for effective software development on and
for Windows, and I personally consider CMake use a mistake. There are much
simpler ways to solve the problems it's intended to solve, and it's not so
great at solving those problems anyway. Due to poor defaults — no compiler
warnings, -g instead of -g3, no sanitizers, etc. — it's not even good for
beginners, and I see beginners repeat the same rudimentary mistakes again
and again when using CMake. (Yes, if you can find the knobs then you can
turn these things on, but it's difficult and far from default.)
On the positive side, the CMake project itself provides a decent "zip"
distribution that works well with w64devkit. Put its bin/ in your PATH,
probably via your .profile, and it fits in naturally. I've used it this
way to build projects using CMake.
My feedback if I were interested in accepting these changes:
It should be fine to leverage Debian CMake for the cross-compile. I don't
use Debian Mingw-w64 because when I had tried the resulting toolchain was
contaminated. Bootstrapping GCC through a matching toolchain has better
results. I don't expect this to matter for CMake. To check, build it both
ways and then look for differences.
I sort SHA256SUMS, mainly because I keep all the source tarballs in a
directory and on upgrades I update it with a brute force recompute:
sha256sum * >../src/SHA256SUMS

Thanks for the feedback! Indeed, I'm currently using a combination of cmake, git, gpg, and w64devkit, all xcopy'ed together in a single root. But I thought it would be cool to compile as much as possible from source :)
I checked if compiling a host CMake from source would make a difference with using Debian's default one, but they give the exact same output executable, so indeed it would be simpler and faster to just use the Debian build.
I'll close this PR, but it'll be there if someone is interested in adding CMake to their builds.


Incorrect Confirmed numbers reflecting on Portal

On 2nd Jun'20, till 6:05 PM IST
Total Confirmed Case - 1544
Active - 1293
Recovered - 244
Desceased - 7
When person found to be infected with Covid-19 on X day, then count of person added in active and confirm case on X day itself but when same person recovered or deceased on Y day then that numbers too are adding in Y day confirmed numbers. So in this case for a person there is 2 entry - one in active and other one in recovered/deceased.
Due to which it getting confusion that today 1544 found to be confirm cases who have covid-19 but this figure include recovered and deceased too.
So to correct this, only active count should reflect in daily confirmed count field which is highlighted in yellow because person either recovered or deceased is already present in confirmed count.
It's simple that if person recovered/deceased would be from Confirmed numbers only

I would say it is not an issue.
Total new cases in your image is 1544.
And today 244 people recovered and 7 lost their lives.
So total increase in active cases is 1544-244-7(new cases which came today - number of people whose outcome came)

At least FARIDABAD-HARYANA references are not being picked up correctely since atleast last 3 days.
perhaps nhmharyana is publishing 2reports and total sum is to be taken of both reports - also aymptomatics counting or not is not clear as that is also a large number - Govt authorities are trying to fudge data - if you lift daya from TWITTER HANDLE OF @DC_Faridabad- HUGE diff. with NHMharyana for last 3days data

@pankajtau 244 were recovered and 7 deceased but this total 251 counts was earlier added in Confirmed when they found covid-19. So it's required to add again this number in today's confirmed counts

There is no need to add Recovered and death count in confirmed counts. As earlier these case was in Active status after it they transferred to recovered or deceased status. You can add-subtract active/recovered/death count.

@ashishgujrathi You are probably misreading the numbers. The total new cases today were 1544(probably you are thinking there are just 1293). Now Active cases number shows how many cases are active today(i.e. their outcome is yet to come).
So the active cases should have increased by 1544 today had there been no new recovered cases. But since few people recovered they are no more active that is why we are removing them from active cases.

@Manbendra Iwant to say suppose if today I'm found to be affected from covid-19 then I will be count in today's active and confirmed number. Now if I'm recovered tomorrow then again I would be count in confirmed counts too.

@manbendra @ashish gujarati - i am trying to locate from where data
mismatch started and cheking other cities / state data also but I am not a
softer guy so what will be outcome dont know- but faridabad is a SURE
MISMATCH as in state data as well as in district compilation too.
[image: image.png]
On Tue, Jun 2, 2020 at 10:10 PM Ashish Gujrathi<EMAIL_ADDRESS>wrote:

@Manbendra https://github.com/Manbendra Iwant to say suppose if today
I'm found to be affected from covid-19 then I will be count in today's
active and confirmed number. Now if I'm recovered tomorrow then again I
would be count in confirmed counts too.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/covid19india/covid19india-react/issues/2025#issuecomment-637671533,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/APRKLHC27LE7YKPLMITADMTRUUTOXANCNFSM4NQXWG6Q
.

@manbendra @ashish gujarati - i am trying to locate from where data mismatch started and cheking other cities / state data also but I am not a softer guy so what will be outcome dont know- but faridabad is a SURE MISMATCH as in state data as well as in district compilation too. shortfall of 73no. in cases -
am already worried about how authorities fudging HOMEQUARINTINE & Asympto datas but this mismatch is to be corrected.

@pankajtau Also we've to look into below figure and need to assign this case to states from unassigned due to which we don't know the exact figures of each states.

@pankajtau Also we've to look into below figure and need to assign this case to states from unassigned due to which we don't know the exact figures of each states.

What's the significance of this in this conversation?

@Manbendra Iwant to say suppose if today I'm found to be affected from covid-19 then I will be count in today's active and confirmed number. Now if I'm recovered tomorrow then again I would be count in confirmed counts too.

Wrong understanding. The active "Delta" is the total number of new requirements that have come up today. This is the logic followed elsewhere to calculate the delta active. Now consider on a day you have "X" new cases, "Y" recoveries and "Z" deaths. In that case, for that day you'll free up "Y + Z" number of beds. Or in other terms, your load on medical system will go down by "Y + Z" number. Now on the same day the load on the system goes up by "X" number. Hence the active cases that get added on that day is "X - Y - Z". This is a per day calculation. A case added today does not contribute again to some other day.

At least FARIDABAD-HARYANA references are not being picked up correctely since atleast last 3 days.
perhaps nhmharyana is publishing 2reports and total sum is to be taken of both reports - also aymptomatics counting or not is not clear as that is also a large number - Govt authorities are trying to fudge data - if you lift daya from TWITTER HANDLE OF @DC_Faridabad- HUGE diff. with NHMharyana for last 3days data

not tallying with DC FBD -Media Bulleitin 01-06-2020 Evening.pdf

Lets not mix up multiple things in one issue. We follow state bulletins for these numbers. Please refer to the state bulletins for understanding the discrepancy

ashish, you r very right here that unassigned cases r to be adjusted, but
that is mostly in SOUTH ESTATES i.e. AP, TN, KL etc .
here the point is that Decalred figures on local level must match with our
lifted data of the day.
On Wed, Jun 3, 2020 at 1:29 PM Ashish Gujrathi<EMAIL_ADDRESS>wrote:

@pankajtau https://github.com/pankajtau Also we've to look into below
figure and need to assign this case to states from unassigned due to which
we don't know the exact figures of each states.
[image: image]
https://user-images.githubusercontent.com/13534446/83610995-f1005200-a59d-11ea-9936-1f94035a6d95.png
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/covid19india/covid19india-react/issues/2025#issuecomment-638030344,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/APRKLHEL6IVBSBJVPBXMZ33RUX7F5ANCNFSM4NQXWG6Q
.

@pankajtau, Actually it's not only for SOUTH states. Same thing for delhi too where from last month numbers are getting added in Unknown district.

i agree with you on this.
but our main issue of mismatch particular data still there
On Wed, Jun 3, 2020, 17:29 Ashish Gujrathi<EMAIL_ADDRESS>wrote:

@pankajtau https://github.com/pankajtau, Actually it's not only for
SOUTH states. Same thing for delhi too where from last month numbers
are getting added in Unknown district.
[image: image]
https://user-images.githubusercontent.com/13534446/83634084-91b33980-a5bf-11ea-88ca-d3870b23491a.png
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/covid19india/covid19india-react/issues/2025#issuecomment-638150557,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/APRKLHCEP3KXRXSCPYCXZVDRUY3LBANCNFSM4NQXWG6Q
.


'class sbe:: ...' has virtual functions and accessible non-virtual destructor

Hello,
I am using gcc version 4.4.7 20120313 (Red Hat 4.4.7-11) (GCC) and I try to compile the code, and I found the compiler give a warning. It seems that the warning is right. All the classes in the otf_api does have virtual functions but does not have accessible non-virtual destructor.
Can anybody take a look a it? Thanks.
/otf/include/otf_api/Ir.h:135: warning:  'class sbe::on_the_fly::Ir::Callback' has virtual functions and accessible non-virtual destructor

/otf/include/otf_api/OnNext.h:29: warning:  'class sbe::on_the_fly::OnNext' has virtual functions and accessible non-virtual destructor

/otf/include/otf_api/OnError.h:45: warning:  'class sbe::on_the_fly::OnError' has virtual functions and accessible non-virtual destructor

/otf/include/otf_api/OnCompleted.h:26: warning:  'class sbe::on_the_fly::OnCompleted' has virtual functions and accessible non-virtual destructor

/otf/include/otf_api/Listener.h:96: warning:  'class sbe::on_the_fly::Listener' has virtual functions and accessible non-virtual destructor

Should be addressed now. Also notice that gcc 4.4 is not supported.


Add a None check before trying to use strftime

I ran into this error while testing the python3 branch:
2018-10-04 00:26:02,079 integration ERROR    [external.py:196] 'NoneType' object has no attribute 'strftime'
Traceback (most recent call last):
  File "/root/project/testing/tools/integration/external.py", line 172, in save_logs_to_file
    time=sd.start_time.strftime('%Y%m%d_%H%M%S.%f'))
AttributeError: 'NoneType' object has no attribute 'strftime'

It arises when a test exits after a sender was created, but before it was started.
This can happen to workers and sinks as well, so I applied the check to all of the places where strftime  is used in the log-capture function.

Thanks @pzel! I DRY'd it up. Mind giving it another look?

I like it!


align chroma vectorstore get with chromadb to enable where filtering

allows for where filtering on collection via get

Description: aligns langchain chroma vectorstore get with underlying chromadb collection get allowing for where filtering, etc.
Issue: NA
Dependencies: none
Tag maintainer: @rlancemartin, @eyurtsev
Twitter handle: @pappanaka

thanks!

You bet.  I just fixed the chromadb typing imports that were causing linting errors.

Also, please run make format to resolve Lint error. LMK if problems, and I can help w/ that.

@rlancemartin Done.  Let me know if you want me to squash these commits.

Both make format and poetry run ruff . now pass without issues.


Pepper_bringup and navigation

Compilation for:

Pepper_bringup (includes rgbd perception)
Navigation

Fixed in 51982c5
Atom tabs were not correctly configured ;)
I also changed the INSTALL_DIR to not be hidden, as comment is Readme.md suggested

@fmrico thanks! I don't know why the comment about .ros-root got added to README.md, though I prefer to keep that change separate in another pull request. I can revert the change to keep it as .ros-root and push it or if you prefer to do it yourself, I'm ok either way.

No problem, I changed it back to .ros-root (hidden) in dde4d91
Thanks!!!

@fmrico I've merged #5 , can you rebase this to fix the conflicts? Thanks!

Incorporated Tom's changes in ceee17a

@fmrico thanks for rebasing the changes. Let me know if you need help addressing the other comments.

@esteve I think I have resolved all the issues related to your comments: fixed tabs, ros-root is hidden, and all consistent with Tom's work. All compiled and tested in Pepper. Do you think I have to resolved anything else to apply this PR?

@fmrico there's still a few comments in https://github.com/esteve/ros2_pepper/pull/4#pullrequestreview-94078693, and a comment about duplicated code in build_ros1_dependencies.sh that is now hidden because of the rebase

@fmrico I've set the keyserver to the hkps pool (https://github.com/esteve/ros2_pepper/commit/4bdd40285ef5c2ce3d3fb291097f2642b46771a4) and added the paths to the compiler tools as environment variables in the docker files (https://github.com/esteve/ros2_pepper/commit/7a33187f3590f3621cbe13a42c3557a45f4eea18) so there's no need to set them for each crosscompiled project. The latter should simplify the scripts a bit.


PEAR-1202: Fix for Biospecimen tree disappears when bioId provided does not exist

Description
Checklist

[ ] Added proper unit tests
[ ] Left proper TODO messages for any remaining tasks
[ ] Scanned for web accessibility with aXe, and mitigated or documented
flagged issues

Screenshots/Screen Recordings (if Appropriate)

works for me 👍


Add support for nodejs16.x.x lambda runtime

Vote on this issue by adding a 👍 reaction
If you want to implement this feature, comment to let us know (we'll work with you on design, scheduling, etc.)

Issue details
AWS recently added node js 16 to it's list of supported Lambda runtimes but the pulumi aws provider only supports up to nodejs14.x
Affected area/feature
@pulumi/aws

Thank you for reporting this @JonNode28
Can you clarify a little bit which is the case:

you cannot provision a Lambda with a nodejs 16 runtime because the Pulumi AWS SDK does not give you API to do that, or fails to accept it

you are trying to actually run some Pulumi code inside a lambda and that code does not support nodejs 16 runtime

I've assumed it's the former and transferred the issue to pulumi-aws repository where we can fix it, but please correct me if it is something more involved.

Confirming that there is a need for this version bump to allow nodejs 16 to work as a runtime.

I am still having issues using nodejs16.x with @pulumi/aws at v5.5.0. Getting the following error:
aws:lambda/function:Function resource 'function' has a problem: expected runtime to be one of [nodejs nodejs4.3 nodejs6.10 nodejs8.10 nodejs10.x nodejs12.x nodejs14.x java8 java8.al2 java11 python2.7 python3.6 python3.7 python3.8 python3.9 dotnetcore1.0 dotnetcore2.0 dotnetcore2.1 dotnetcore3.1 dotnet6 nodejs4.3-edge go1.x ruby2.5 ruby2.7 provided provided.al2], got nodejs16.x. Examine values at 'Function.Runtime'.

Unclear to me if this problem exists in the underlying terraform provider.

I have the same issue. Symbol aws.lambda.Runtime.NodeJS16dX doesn't exist and I get the same runtime error when "nodejs16.x" value is used.

I'm on v5.6.0 and still not seeing aws.lambda.Runtime.NodeJS16dX

@pbredenberg symbol is missing, but value nodejs16.x works.

@rarous is correct - there is no enum value for nodejs16 - we will get that added

Thank you!


renaming of file teensy_loader_cli

https://github.com/NixOS/nixpkgs/blame/44733514b72e732bd49f5511bd0203dea9b9a434/pkgs/development/embedded/teensy-loader-cli/default.nix#L32
ran in to a problem with tinygo expecting teensy_loader_cli not teensy-loader-cli, not sure why this package renaming the program.

Unfortunately, that package doesn't list any maintainers; a fix might take a while. Consider making a PR if you want a faster fix.
(One note: technically, the fix is a breaking change.)


Test: Fix helpers.WithTimeout function

If the first function blocks the WithTimeout the timeout will never
work. With this change the first execution of the body function will
happen into the select.
Fix #5163
Signed-off-by: Eloy Coto<EMAIL_ADDRESS>

This change is

test-me-please

@aanm
package main

import (
	"fmt"
	"time"

	"github.com/cilium/cilium/test/helpers"
	"github.com/sirupsen/logrus"
)

func main() {
	logger := logrus.WithField("test", "test")
	kubectl := helpers.CreateKubectl(helpers.K8s1VMName(), logger)
	start := time.Now()
	body := func() bool {
		fmt.Println("Here you are")
		kubectl.Exec("sleep 20")
		return false
	}
	err := helpers.WithTimeout(body, "fail",
		&helpers.TimeoutConfig{Timeout: 3})
	fmt.Println(err)
	fmt.Println(time.Since(start))
}

@aanm

breo.acalustra.com ➜  test git:(HelpersTimeoutFix) ✗ cat run.go
package main

import (
        "fmt"
        "time"

        "github.com/cilium/cilium/test/helpers"
        "github.com/sirupsen/logrus"
)

func main() {
        logger := logrus.WithField("test", "test")
        kubectl := helpers.CreateKubectl(helpers.K8s1VMName(), logger)
        start := time.Now()
        body := func() bool {
                fmt.Println("Here you are")
                kubectl.Exec("sleep 20")
                return false
        }
        err := helpers.WithTimeout(body, "fail",
                &helpers.TimeoutConfig{Timeout: 3})
        fmt.Println(err)
        fmt.Println(time.Since(start))
}
breo.acalustra.com ➜  test git:(HelpersTimeoutFix) ✗ go run run.go
level=info msg="Vagrant: running command 'vagrant ssh-config k8s1-1.11'"
Timeout reached: fail
3.000195297s
breo.acalustra.com ➜  test git:(HelpersTimeoutFix) ✗

@eloycoto body() was not even executed in your example.

We don't want to abort the execution André, if we abort we'll lost what function or why it's block. That help us to gather information in the AfterFailed.

test-me-please

Hi @aanm,
About your proposal and my changes that you don't understand:
1- Start channel
On time.Picker only happens by default every 5 seconds but does not mean that it's executed on start, so each time that the WithTimeout is used, the function is on hold for 5 seconds.
Before we call the body first, but that does not work with the timeout, with this change we allow that in the second 0 the body function will be called and each test will win 5 seconds. (That helped us to save around 12min in the test a few weeks back)
2- Lock
Ginkgo runs synchronously, so the bool that it's unsafe I can't figure it out if you can share with me an example where is not safe It'll be great.
About the use of sync.Mutex.Lock I would like to use that, but this is a test helper and my experience said that we should avoid that, is always the same problem, if we add logic in the test, who test the logic of the test?
Adding a Lock in the test will make things hard to debug, and debugging CI should be a super simple synchronous script that it's super easy to debug the flow. This example is why I always emphasise to make test super small and do one thing per test.
3- Logic
As I saw in your code, the function will have a switch base on a string, this is the same thing as before, why we should add a switch method in a helper. If we add logic in the test, who test the test logic?
I always emphasise this one, but one day, in my former job, someone made a change in the logic of a test helper, we ended with something that was not tested, and a few dozens of pounds were lost.
So, If I can avoid: if,switch, long loops in tests I would do, tests should be easy to read and with the minimum logic in there.
4- About the config.Ticker and duration
Yes, that it's something that I would like to change as well. That it's from my early days in Golang, the main problem with that, we need to change a lot of callers functions to change that. This PR will be backported, so I will change that one in the future releases.
5- Abort Body()
Yes, I understand what you trying to achieve, but if something gets a timeout is a Fail on a test, so we don't want to abort at all. I understand that we want to have all the data, threads,etc.. in the bug tool information, that it's super important to keep, so it helps us to debug what it's going on.
I can't see any benefit of using a context in the helper function in any test, but if you can explain a good use case I'll make the change.
Saying this, if you still that your code suits better for this function I'm happy to close this PR or use your code.
Best regards,
Eloy

Hi @aanm,
About your proposal and my changes that you don't understand:
1- Start channel
On time.Picker only happens by default every 5 seconds but does not mean that it's executed on start, so each time that the WithTimeout is used, the function is on hold for 5 seconds.
Before we call the body first, but that does not work with the timeout, with this change we allow that in the second 0 the body function will be called and each test will win 5 seconds. (That helped us to save around 12min in the test a few weeks back)

How do you guarantee that?! There's no guarantees what so ever. Let's look at your current proposal:
assuming start<-true is executed before the first "Tick"
(read in-code comments)
	// Send the first execution of the body func
	go func() { start <- true }()  // gets executed. we can even remove the go call here to make it simpler

	// If the function take more than the config.Ticker the function will be
	// not executed.
	bodyLock := false
	WithLock := func(body func() bool) {
		if bodyLock == true {
			return
		}
		bodyLock = true
		defer func() { bodyLock = false }()
		status <- body()
	}

	for {
		select {
		case res := <-status:
			if res {
				return nil
			}
		case <-start:       // 1st for loop iteration: channel is read, so the for loop will be executed again.
		case <-ticker.C:  // 2nd loop iteration, the ticker.C will be received on after 5 seconds the ticker was created.
			go WithLock(body) // This go function will only be executed 5 seconds after the ticker was created no matter the existence of a "start" channel.
		case <-done:
			return fmt.Errorf("Timeout reached: %s", msg)
		}
	}

2- Lock
Ginkgo runs synchronously, so the bool that it's unsafe I can't figure it out if you can share with me an example where is not safe It'll be great.
About the use of sync.Mutex.Lock I would like to use that, but this is a test helper and my experience said that we should avoid that, is always the same problem, if we add logic in the test, who test the logic of the test?

Looking again at the current implementation:
(read in-code comments)
	bodyLock := false
	WithLock := func(body func() bool) {
		// bodyLock is read in multiple go routines on second 10, 15, n+5...
		if bodyLock == true {
			return
		}
		bodyLock = true
		// bodyLock is written in multiple times on second 10 + timeOf(body() execution)
		defer func() { bodyLock = false }()
		status <- body()
	}

	for {
		select {
		case res := <-status:
			if res {
				return nil
			}
		case <-start:
		case <-ticker.C:
			// 1st loop: WithLock is executed after 5 seconds.
			// 2nd loop: WithLock is executed after 10 seconds with no guarantees the previous go routine is done.
			// 3rd loop: WithLock is executed after 15 seconds with no guarantees the previous go routines are done.
			go WithLock(body)

Adding a Lock in the test will make things hard to debug, and debugging CI should be a super simple synchronous script that it's super easy to debug the flow. This example is why I always emphasise to make test super small and do one thing per test.
3- Logic
As I saw in your code, the function will have a switch base on a string, this is the same thing as before, why we should add a switch method in a helper. If we add logic in the test, who test the test logic?

That can be solved by writing unit test for helpers.

I always emphasise this one, but one day, in my former job, someone made a change in the logic of a test helper, we ended with something that was not tested, and a few dozens of pounds were lost.
So, If I can avoid: if,switch, long loops in tests I would do, tests should be easy to read and with the minimum logic in there.
4- About the config.Ticker and duration
Yes, that it's something that I would like to change as well. That it's from my early days in Golang, the main problem with that, we need to change a lot of callers functions to change that. This PR will be backported, so I will change that one in the future releases.
5- Abort Body()
Yes, I understand what you trying to achieve, but if something gets a timeout is a Fail on a test, so we don't want to abort at all. I understand that we want to have all the data, threads,etc.. in the bug tool information, that it's super important to keep, so it helps us to debug what it's going on.
I can't see any benefit of using a context in the helper function in any test, but if you can explain a good use case I'll make the change.
Saying this, if you still that your code suits better for this function I'm happy to close this PR or use your code.

Your PR description is the following:
If the first function blocks the WithTimeout the timeout will never
work. With this change the first execution of the body function will
happen into the select.

If the first function blocks the WithTimeout the timeout will never
work.

Neither my changes nor your changes fix this issue without a context.Context to abort the body execution from running. If body() blocks forever, the timeout is never reached.

With this change the first execution of the body function will
happen into the select.

This still doesn't fix the issue described, if you remove "first" from "first function" in "If the first function blocks the WithTimeout the timeout will never work." we continue to have the same problem.

Best regards,
Eloy

I didn't add the unittest for the helper.WithTimeout, please confirm that it's what you want and I'll do the unittest.

test-me-please

@aanm is correct here, the most critical statement in his analysis above is:

Neither my changes nor your changes fix this issue without a context.Context to abort the body execution from running. If body() blocks forever, the timeout is never reached.

We do not want body() blocking forever. This will cause the entire build to timeout. The current situation we are in right now is if body() blocks forever, we don't get any logs at all, which is the worst possible scenario for debugging. The documentation for WithTimeout would lead me to believe that we should abort body() if it doesn't finish within the specified timeout:
// WithTimeout executes body using the time interval specified in config until
// the timeout in config is reached. Returns an error if the timeout is
// exceeded for body to execute successfully.

it's better to abort after some reasonable time so at least we can see what was blocking in test_results/test-output.log. This would result in WithTimeout guaranteeing that we will never have body() hang. If a function keeps timing out, and we are unable to debug it, we can dump more information to stdout using By, or log and check test_results/test-output.log.

@eloycoto this has needs-backports tags but has not had any active work for 2+weeks. If its not important enough to work on its probably not needed to backport? Can you either remove the tags or let me know what the status is. Thanks.

test-me-please

test-me-please

test-me-please

test-me-please

@eloycoto I am removing the 'needs-backport' tags, as this PR has been open for some time and is rotting. Feel free to add them once you resume work on this PR.

@ianvernon André already fixed this one in othe PR, I'm closing this one.