feat(userspace/outputs_http): Add option for mTLS

What type of PR is this?
/kind feature

Any specific area of the project related to this PR?
/area engine

What this PR does / why we need it: Currently there is no mTLS option for the HTTP output, it would be more secure to have this feature.
Which issue(s) this PR fixes:

Fixes https://github.com/falcosecurity/falco/issues/2632
Special notes for your reviewer:
Does this PR introduce a user-facing change?:

new(falco/config): add new configurations for http_output that allow mTLS

[APPROVALNOTIFIER] This PR is NOT APPROVED
This pull-request has been approved by: annadorottya
Once this PR has been reviewed and has the lgtm label, please assign leogr for approval. For more information see the Kubernetes Code Review Process.
The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

OWNERS

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Welcome @annadorottya! It looks like this is your first PR to falcosecurity/falco 🎉

cc @alacuku

This seems very useful, are we on track to allocate time for review and feature finalization? Thank you! @leogr?

This seems very useful, are we on track to allocate time for review and feature finalization? Thank you! @leogr?

I agree this is useful. I believe we are still in time. Let's try to merge this for Falco 0.36.
cc @Andreagit97 @FedeDP

I've tested it and it works, thank you for this! Could you rebase please @annadorottya?

LGTM label has been added.  Git tree hash: 7903895bbe2dce8dbb042516d8f705665a24e562

[APPROVALNOTIFIER] This PR is APPROVED
This pull-request has been approved by: annadorottya, leogr
The full list of commands accepted by this bot can be found here.
The pull request process is described here

Needs approval from an approver in each of these files:

OWNERS [leogr]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

New changes are detected. LGTM label has been removed.

Thanks for your pull request. Before we can look at it, you'll need to add a 'DCO signoff' to your commits.
:memo: Please follow instructions in the contributing guide to update your commits with the DCO
Full details of the Developer Certificate of Origin can be found at developercertificate.org.
The list of commits missing DCO signoff:

172699f Merge branch 'falcosecurity:master' into add-mtls

Instructions for interacting with me using PR comments are available here.  If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

Adding label do-not-merge/contains-merge-commits because PR contains merge commits, which are not allowed in this repository.
Use git rebase to reapply your commits on top of the target branch. Detailed instructions for doing so can be found here.

Instructions for interacting with me using PR comments are available here.  If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

[APPROVALNOTIFIER] This PR is NOT APPROVED
This pull-request has been approved by: annadorottya
Once this PR has been reviewed and has the lgtm label, please ask for approval from leogr. For more information see the Kubernetes Code Review Process.
The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

OWNERS

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

[APPROVALNOTIFIER] This PR is NOT APPROVED
This pull-request has been approved by: annadorottya
Once this PR has been reviewed and has the lgtm label, please ask for approval from leogr. For more information see the Kubernetes Code Review Process.
The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

OWNERS

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Sorry I accidentally merged the master branch into my branch, which removed the lgtm and approved labels, can you approve again @leogr ? 🙇

No worries even with a direct rebase all previous approvals are removed. Leo and Andrea will approve tomorrow Europe time.

LGTM label has been added.  Git tree hash: bfbf0dcf5fb2b62eb67aabb9dbd79efde8304ef3

[APPROVALNOTIFIER] This PR is APPROVED
This pull-request has been approved by: Andreagit97, annadorottya
The full list of commands accepted by this bot can be found here.
The pull request process is described here

Needs approval from an approver in each of these files:

OWNERS [Andreagit97]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment


Make it ready to Drupal 10

From what I could acknowledge there're no major differences between D9 and D10 themes so Kiso should work well on D10 sites but it has to, at least, allow D10 at kiso.info.yml
Please double check.

Some functions were Deprecated in Drupal 9 and removed in Drupal 10.
I replaced these functions.

I just made a patch and saw this issue.
kiso-68_d10-readiness.patch
Almost the same.
FYI, D8.8 minimum version is required, but I doubt we will still have such old sites.


Provide secrets for ./mach upload-nightly

Also remove s3cmd related code,
as we now use boto3 for uploads.
Goes along with servo/servo#16565.

This change is

cc @larsbergstrom @metajack

@bors-servo r+

:pushpin: Commit c95de05 has been approved by jdm

:hourglass: Testing commit c95de051cc34366d3c30679a563cf30b6e4b6c34 with merge d20c76c403856912cbc674ab03bab289d8474076...

:sunny: Test successful - status-travis
Approved by: jdm
Pushing d20c76c403856912cbc674ab03bab289d8474076 to master...


Created Kadane’s_Algorithm  program in python .

Added Kadane’s_Algorithm. #134

Please Assign me to Hacktoberfest 2022


[WIP] 621 ci farm test

closes #621
Messes w ops stuff, the code itself is the same so no risk of backwards incompatibilities.
Big change: payment bot is built into a proper docker image now. During CD, everything's built & then pushed to docker hub & labelled with the git commit hash. Then, during later CD steps, these node + bot images are pulled & used to test w/out needing to rebuild/reinstall anything.
Still TODO:

use the upgraded feature-branch CD process in staging & master CD workflows too
fix the push images step of staging/master workflows & ensure current version of images gets pushed w/out rebuilding everything

Checklist:

[x] I am making this PR against staging, not master
[x] My code follows the code style of this project.
[x] I have described any backwards-incompatibility implications above.
[ ] I have highlighted which parts of the code should be reviewed most carefully.
[x] If my change requires a change to the documentation, I have updated it accordingly.

Closed in favour of PR #663


Fix README.md, change manual install openscad to official docker image

Parametr options moved from action upload-artifact (it's my mistake) to openscad action
Changed manual install openscad to official image (faster build in actions)

@vlegio Hello!
I would like to merge "try change manual install openscad to offical image" commit.
Could you create new pull request ? This current pull request has commits that have been merged into main. I would like you to

Create new branch from main
Run git cherry-pick 3cdd3e4
Create new pull request

Thanks you for your grateful works!


convert SuperPoint from onnx to engine

i tried to convert SperPoint onnx model to tensorrt engine by FP16, and i met trouble:
i used SuperPoint_FP16.engine to extract features and LightGlue_FP16.engine to match them, but the results was bad and could not perform as well as onnx model both of them. did you meet the same problem? and how to solve it?

Hi @midskymid, thank you for your interest in LightGlue-ONNX.
If I recall correctly, I do think I've encountered a similar problem during my own experimentation. Depending on how you convert it to half-precision, it can happen that the values go outside the tolerable floating point range, leading to a drastic fall in # of keypoints detected, or even none detected. I don't think there's an easy solution to this other than fine-tuning (?) the model to be 'half-precision-aware' (sort of like mixed-precision training).


WebSocket optimization:

Currently the frame header is read in using 1 or 2 system calls, followed by another system call for the frame payload. The number of system calls could be reduced considerably by issuing a call to read_some or async_read_some with a decent buffer size. This can have a big effect on performance.

This could use the buffer in the buffered read stream

Before making any changes there needs to be a benchmarking framework set up to evaluate the difference.

This turned out to be VERY fruitful, reads are 3x faster now and the dynamic buffer allocation is eliminated!


About the specific_attack

Two problems:

in "api.txt" there's written "attack_specific" instead of "specific_attack"
in "api.lua" line 1068 where there is the condition about the specific_attack it doesn't consider the possibility of a monster attacking other monsters. This could be a funny addition!

I'll look into monsters vs monsters (godzilla vs mothra :), would be funny but the attack detection would need to be re-written for that.


Hello,why the option iconId is not work?

var icon = new SVGMorpheus('#icon',{iconId:'#3d_rotation'});
It still show last icon! Why?

@alexk111

@df257 Thank you for finding this out! I've fixed it. The upcoming version will have the bugfix. Cheers!


Allow configuration of SA1311:StaticReadonlyFieldsMustBeginWithUpperCaseLetter

I always switch this rule off when using StyleCop, but it seems it is not currently configurable by StyleCop.json.

Since StyleCop Analyzers ties directly in with the new compiler, we use the compiler's built-in mechanism (ruleset files) for all enabling/disabling of rules. You can find a link to more information about these files in the project readme file.

Ahhhh, yes of course. Ruleset files. I keep forgetting that Roslyn analyzers tie in with them. Thanks.


Fix the exit status for incorrect flag

Signed-off-by: Arindam Nayak<EMAIL_ADDRESS>

Some comments.

I have added the changes you suggested.


SoapyAirspy Status

Apologies as I was offered hardware to complete this module last year but they've not responded to me since.
If anyone would like to have a go at the Airspy module be my guest as I don't know when I'll have a chance to look at this.

AirSpy Mini from the second batch has been ordered; should hopefully let me get this wrapped up in the next month so closing this up for now.


No Render

Hi
the IncrementCount inside online JupyterLab myBinder doesn't work and currentCount remains 0 when I press the famus Counter button.

Hi @osaaso3 ,
The blazor kernel should work in binders hosted on mybinder.org. Make sure you have the correct NuGet.config file. You can try with the one found here https://github.com/dotnet/interactive
Currently this package only renders the HTML generated from the razor components (blazor code). In addition, it adds a reference the components so that they can be used in other code cells.
I’ll open another issue to research how to host a blazor application in an interactive notebook.
To help clarify the current state of this project I’ve added a diagram of the sequence of commands and events to the README.md

Thanks


Calculate the count is very slow

RLMResults *result = [Filter_model objectsWhere:@"XXX"];
NSInteger count = result.count

The model storage 2000 line data, Ten times slower than the sqlite！！！！

Can you please share the definition of the model class that you're filtering, and the predicate string you're filtering on? They're both important aspects in understanding the performance of the code you have provided.

Filter_model
@interface Filter_model : RLMObject
@property (nonatomic, assign) NSInteger id;
@property (nonatomic, copy) NSString *target_lsku;
@property (nonatomic, copy) NSString *target_output;
@property (nonatomic, copy) NSString *target_ssd_id;
@property (nonatomic, copy) NSString *target_type;
@end
Realm Count
RLMResults *result = [RealmRequest_filter objectsWhere:[NSString stringWithFormat:@"target_lsku == '%@'",target_lsku]];
 count = result.count;

FMDB Count
NSString *sql = [NSString stringWithFormat:@"SELECT count(*) as request_count FROM requests_filtered_view WHERE target_lsku IN (%@)",
                     target_lsku];
FMResultSet *rs = [db executeQuery:sql withArgumentsInArray:args];
while (rs.next) {
        count = [rs intForColumn:@"request_count"];
}

I need found the count, but result ten times slower than the sqlite.
why!
what is the problem with my code?

Can you please also share the schema definition of the requests_filtered_view table used in your SQLite example for sake of comparison?

A few more questions after experimenting with this myself:

What do the values in target_lsku typically look like?
How many matches do you expect the query to produce?
How long is the query taking in Realm? How long with SQLite?

In my experiment I used the model as you provided above. I then populated the Realm with 50,000  instances of Filter_model, with the target_lsku property of each object set to 1400 bytes of random data. I then measured the time taken to evaluate [Filter_model objectsWhere:@"target_lsku == %@", needle].count, where needle was a string taken from the target_lsku property on one of the objects. On an iPhone 6 Plus, computing the number of matching objects takes < 50ms. If I add an index on the target_lsku property:
@implementation Filter_model
+ (NSArray *)indexedProperties { return @[ @"target_lsku" ]; }
@end

the time taken to count the matching objects drops to ~2ms.

Thank for your answer

'target_lsku' was a string
maybe one or zero
Realm about 32s, SQLite about 3s
Here are many query requests
I have tryed add 'indexedProperties', but still as before.

Are you able to share the exact code and Realm file you're testing with? 32 seconds is an incredibly long time for any query so I'm very curious what you're doing that takes so long.

target_lsku was a string.

What is the typical length of the values stored in this property? Are the values similar between objects (the same except for a small number of characters), or do they vary significantly from object to object?

'target_lsku' about 15 characters in length.
'target_lsku' values are very similar such as 'P160607002' and 'P160607003'
Take so long, beacause query about Sixty thousand.

As I mentioned, my test with 50,000 objects with much larger strings showed the matching and counting taking < 50ms. Updating it to use strings of the same size as your examples makes it take < 10ms. If you're seeing the same operation take 32 seconds, something else is going on. You'll need to share more information for us to be able to help understand why it's taking so long. Can you share the code you're using to measure the performance and the Realm file you're querying? Can you share an Instruments trace covering the time spent performing the query? Can you share which Realm version you're using?

but when write like this, become very soon.
__block NSInteger number = count;
dispatch_async(dispatch_get_main_queue(), ^{
    number = [RealmRequest_filter objectsWhere:[NSString stringWithFormat:@"target_lsku == '%@'",target_lsku]].count;
});
return number;

The screenshot only shows a small subset of the stack trace. Can you share the full Instruments trace? If you'd like to keep it private you can share it via email to<EMAIL_ADDRESS>

The part of the stack trace that is visible does show that the time is being spent in opening the Realm, not evaluating the query. That makes a little more sense. Will need to see the full trace in order to understand why it's taking so long as opening a Realm is typically very quick.

@skarctop, I really want to help you, but if you're not willing to share the information I've asked for it's simply not possible to.
As I mentioned previously, a screenshot of a small part of the Instruments trace isn't sufficient for us to understand what's causing opening the Realm to take as long as it is. We need to see the full Instruments trace. If you don't want to share it publicly you can email it to us privately at<EMAIL_ADDRESS>We'll be more than happy to investigate the problem once you've shared the Instruments trace.

One
RLMRealmConfiguration *config = [RLMRealmConfiguration defaultConfiguration];
config.readOnly = YES;
RLMRealm *realm = [RLMRealm realmWithConfiguration:config error:nil];
return [RealmRequest_filter objectsInRealm:realm where:[NSString stringWithFormat:@"target_lsku == '%@'",target_lsku]].count;

Two
RLMRealm *realm = [RLMRealm defaultRealm];
return [RealmRequest_filter objectsInRealm:realm where:[NSString stringWithFormat:@"target_lsku == '%@'",target_lsku]].count;

One about 10s but Two spend 30s

Query operation is carried out within the thread3, as if the reason for the thread

@skarctop very curious as to why you closed this? Did you determine the cause of the long open time? The generic screenshot of Instruments you posted doesn't show much, other than you have a busy GCD worker thread. Doesn't even show anything Realm related.

I'm looking for this. Is realm has method to query only count of data like sql "SELECT count(*) as request_count FROM table WHERE name = xx"?

@weiminghuaa [table objectsWhere:@"name = 'xx'" ].count

@Kirow I know. Is this way cause  query slow. In sqlite, it's not need query all data from db.

@weiminghuaa, In my app I have 90k+ records in main table & ~2k in linked tables, not simple query by text like "object.field1 CONTAINS[c] %@ OR name CONTAINS[c] %@ OR ANY objectArray.name = %@". On my iphone5s it takes 0.279722s to process query & 0.000121s to get count. In this test sample I used "ap" input and got 5746 records in result (if this matters).
So I can not say that it is slow.

@weiminghuaa [table objectsWhere:@"name = 'xx'" ].count is an optimized operation to get just the number of objects matching the query. It's generally a faster operation than accessing resulting objects from that query.


Container was removed when change port mapping in Kitematic

Expected behavior
Container should remain with new port mapping.
Actual behavior
Old container gone and replace with clean new container....
Information about the Issue
Steps to reproduce the behavior

Create new container, for example, ubuntu. Go into it shell and create only 1 new empty file.
Back to Kitematic. Go to Settings -> Hostname/Ports, and change port mapping. Click "save"
Kitematic running this container, Go into it by clicking exec. Previously created file is gone.

It's currently not possible to dynamically update a container's port.
When you update the ports in Kitematic, we delete the container and re-create it with the proper configuration.
Containers are stateless, which means that you should not be writing to them. You can keep some of the data if you mount a volume where you expect the data to be kept.


hybrid loss of AnatomyNet

Only Dice loss can be seen in the AnatomyNet. Where is Focal loss?  Dose it mean AnatomyNet is fine-tuned  from 'baselineSERes18Conc' by using  Dice loss only?

I just add the focal loss in https://github.com/wentaozhu/AnatomyNet-for-anatomical-segmentation/commit/fa736bf017d9ba2c12cecb76ccb7d873194c2ad0
It can be easily obtained from cross entropy loss.


Bug: Some of the sides disappear randomly

Happens on its own randomly

My guess is that this might be an upstream issue in the tui crate, which we use for stuff like drawing the borders and layout and so on.  It might be worth seeing if you can reproduce this with any of their examples.

Hmm. I have used TUI before and this has never happened.


Network prefabs are not registered for objects spawned within injected tiles

Prefabs that are supposed to be network-spawned from SpawnSyncedObject instances are not found when they are contained by a tile that is injected through DungeonFlow.TileInjectionRules, due to the fact that DungeonFlow.GetTiles() doesn't check for the tiles contained by those injection rules.
A custom apparatus spawned in the Tomb interior is not registered as network prefab and fails to spawn for other clients.

It should be possible to work around this by adding any custom items spawned within injected tiles as registered ExtendedItems.


bashblog: init at unstable-2022-03-26

Description of changes

Originally it uses Markdown.pl, but the package perlPackages.TextMarkdown is failing, as stated here. Other packages using it (like shocco) are also having the same issue. So I am using pandoc instead, which is supported.
Things done

Built on platform(s)

[x] x86_64-linux
[ ] aarch64-linux
[ ] x86_64-darwin
[ ] aarch64-darwin

[ ] For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
[ ] Tested, as applicable:

NixOS test(s) (look inside nixos/tests)
and/or package tests
or, for functions and "core" functionality, tests in lib/tests or pkgs/test
made sure NixOS tests are linked to the relevant packages

[ ] Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
[x] Tested basic functionality of all binary files (usually in ./result/bin/)
22.05 Release Notes (or backporting 21.11 Release notes)

[ ] (Package updates) Added a release notes entry if the change is major or breaking
[ ] (Module updates) Added a release notes entry if the change is significant
[ ] (Module addition) Added a release notes entry if adding a new NixOS module
[ ] (Release notes changes) Ran nixos/doc/manual/md-to-db.sh to update generated release notes

[x] Fits CONTRIBUTING.md.

This pull request has been mentioned on NixOS Discourse. There might be relevant details there:
https://discourse.nixos.org/t/prs-ready-for-review/3032/841


Any plans to Update for 6.15 and 6.18?

Please Update! <3

I took over the work on this plugin. An update has already been done with fixed Context Menus etc.: Version 1.13.
Also a pull request for update on the official repo has been created, but sadly the person who need to final review hasn't time to merge it yet. (Final review because I'm a new dev at Dalamug plugins) :/
See here: https://github.com/goatcorp/DalamudPlugins/pull/2666


Report more detail about hot reload/restart failures to analytics

The tool sometimes fails to send analytics when there is an exception during hot reload, like here:
https://github.com/flutter/flutter/blob/e76160703f0a027c90d2c71ebfcb829306edccd2/packages/flutter_tools/lib/src/run_hot.dart#L774
Also, the tool could send more information on a rejection notice from the VM. Currently these messages are dropped here:
https://github.com/flutter/flutter/blob/e76160703f0a027c90d2c71ebfcb829306edccd2/packages/flutter_tools/lib/src/run_hot.dart#L507
These messages come from a few different places in the VM, and a rejection notice could in theory contain several messages, so a component of this issue may be asking for a summary message from the VM, or reporting only the first message in the notice to analytics.
Search term in the VM code: 'ReasonForCancelling' like
https://github.com/dart-lang/sdk/blob/90ff37e0115c301cb742f894f64f4e3c78879df7/runtime/vm/isolate_reload.cc#L266
and
https://github.com/dart-lang/sdk/blob/90ff37e0115c301cb742f894f64f4e3c78879df7/runtime/vm/object_reload.cc#L562

(triage) @zanderso  Can you please assign this bug to somebody who is working on it or remove it from the march milestone. All bugs in milestones with a month should be assigned to people actively working on it.


Target suffix loading: use of contains may pick multiple targets

Issue description
Current behavior

The current implementation of target suffix loading involves the use of the contains() string method to capture target files as shown in the below lines:
https://github.com/ivadomed/ivadomed/blob/76b36a0a0f7141feb2d5b00b33e4c3a06865fc2c/ivadomed/loader/bids_dataframe.py#L125-L128
This means that

if your derivatives contains multiple filenames with overlap (e.g. _lesion-manual.nii.gz and _lesion-manual2.nii.gz) and
if  you use a "target_suffix" containing the overlap (e.g. _lesion-manual),

then the current loading process picks all of the filenames with the given overlap as potential targets.
This is problematic because the user might (reasonably) think that only _lesion-manual.nii.gz will be used as the ground-truth when the "target_suffix" is specified as _lesion-manual, whereas in reality both _lesion-manual.nii.gz and _lesion-manual2.nii.gz are used.
I didn't go deeper in the codebase yet to see what happens when multiple targets are picked during the loading process, but I can confirm that the GT that ends up being used changes from run to run based on my experiments with ivadomed --test.
Expected behavior

I would expect the "target_suffix" to exactly match the target filename. Two options we have are:

Changing line 128 as shown above with something like
& df_next['filename'].str.split(os.extsep).apply(lambda x: x[0]).str.endswith('|'.join(self.target_suffix)))]

which enforces an exact match of target suffix.

In case the use of contains() is justified in some scenarios and its implemented that way for a specific reason, the user can instead give a full "target_suffix" including the file extension such as _lesion-manual.nii.gz. I have tested this and can confirm it solves the problem.

The latter option is notably a lot easier to implement as it doesn't require a change in the codebase. However, I think this is an issue many people might face without knowing it in the future.
Steps to reproduce

Download the basel-mp2rage dataset as shown here.
Run preprocessing on the data as shown here.
Insert print(bids_df.get_deriv_fnames()) after line 370 in ivadomed/main.py which initializes the BIDS data frame.
Run the following config file with ivadomed --train.
Take a look at the output of the print statement from step 3.

However, this is specific to one dataset and it is understandable that not everybody will be willing to run preprocessing etc. on this particular dataset. In this case, I would like to point out that this issue is reproducible with any dataset which has multiple annotations per subject where the string target suffix for these annotations have an overlap.

Thank you @uzaymacar for reporting this issue!
I don't see any specific cases where contains() is beneficial, I agree with you that it should look for an exact match to avoid the "silent" issue you ran into.
I would be in favor of option 1 as it prevents such "silent" issue.
Option 2 would work as well but not all derivatives files have an nii.gz extension (for MRI it could be .nii as well, and for microscopy .png and .tif)

Thanks for your input and insights @mariehbourget! I will bring this up in our next internal meeting, but two things I would like to think more are:

there might be previous config files that rely on the contains() implementation similar to what is shown here.
my suggestion above with endswith() instead of contains() is still not an exact match as technically manual could be used to match lesion-manual

there might be previous config files that rely on the contains() implementation similar to what is shown here

I'm not sure to understand and may be missing some context.
So you would have several GT with the name _seg-* (ex: _seg-01, _seg-02, _seg-03) and put _seg in the config file.
Then either one of those GT would be paired with the image for training?
I think right now the loader will associate only 1 GT (ex: _seg-01) to 1 given image. But I'm not sure if you re-run the training, if it will always take _seg-01 or would take another one ( ex: _seg-02) depending on the order of the file indexing?
Isn't that something we would want to avoid like in your issue https://github.com/ivadomed/model_seg_ms_mp2rage/issues/41?

my suggestion above with endswith() instead of contains() is still not an exact match as technically manual could be used to match lesion-manual

In that case, maybe we could split the filename after the modality_suffix (T1w, SEM, etc) which is the column suffix in the bids_dataframe, remove the extension and look for an exact match (instead of endswith())?
Those are very interesting questions, I'll think about it!

I'm not sure to understand and may be missing some context.

The first point of mine simply says that people might have used, for example, _seg in their config file to load _seg-XX as the GT. This might even be the case for datasets with a single GT. As a result of the PR that will address this issue, their config files will no longer work (as we want exact match).

But I'm not sure if you re-run the training, if it will always take _seg-01 or would take another one ( ex: _seg-02) depending on the order of the file indexing?

Indeed! This is what I have observed: it takes another one and which one changes from run to run (observed with ivadomed --test). And yes, the goal of this issue is to avoid this.

maybe we could split the filename after the modality_suffix

This is definitely the next best idea I was looking for 🙂.

While debugging for another issue #1096 from an external user, I came across this exact problem.
In this case, we have the following target_suffix (coming from the segmentation in ADS):
_seg-axon
_seg-axonmyelin
_seg-myelin
With _seg-axon in the config file, both _seg-axon and _seg-axonmyelin are picked up which is not good at all.
I'll inform the user for now and tag this issue as high priority.

Hi @uzaymacar, did you already started working on this issue?
I would like to put it in priority but don't want us to work in parallel and duplicate our efforts.

Feel free to take it on @mariehbourget! I only created a branch so it's OK.

maybe we could split the filename after the modality_suffix

This is definitely the next best idea I was looking for 🙂.

Unfortunately, my previous idea is not working, because the filename entities, including the modality suffix are not indexed in the dataframe for derivatives.


How do I enable this plugin?

This is my LSP.sublime-settings that I use to enable lsp-clangd plugin
// Settings in here override those in "LSP/LSP.sublime-settings"
{
  "inhibit_snippet_completions": true,
  "show_view_status": false,
  "clients": {
    "clangd": {
      "enabled": true,
      "command": [
        "clangd", // you may use an absolute path for this clangd executable
        "-function-arg-placeholders=0",
        "-header-insertion-decorators=1",
        "-background-index",
        "-j=3",
      ],
      "scopes": ["source.c", "source.c++", "source.objc", "source.objc++"],
      "syntaxes": [
        "Packages/C++/C.sublime-syntax",
        "Packages/C++/C++.sublime-syntax",
        "Packages/Objective-C/Objective-C.sublime-syntax",
        "Packages/Objective-C/Objective-C++.sublime-syntax",
      ],
      "languageId": "cpp",
    }
  }
}

it just work. it sounds like yoi didnt install this plugin.

To be clear, I actually recommend let LSP/lsp-utils/LSP-* manage everything they need so that there is no enviroment differences among users. Fwiw, your bash-completion-server won't be used unless you deliberately modified the settings.
The first thing you can do is to run the troubleshooting and post the text result here.

I had to install shellcheck for the linting to get enabled. @jfcherng

Hmm... actually, I think we can have LSP-bash handled this but currently it's not.


Fix assumption in README

Connects to #48.
Turns out that the library, as far as I can tell, doesn't assume spherical mercator, TMS, or normal tile numbering. So it can probably be used in other projections as well.
Updated README to reflect new available options and make it clear that the library does no projection.
@rmarianski could you review, please?

Coverage remained the same at 93.131% when pulling f6b15870ad8af3b9d77abf72431fec61546ddb5c on 48-fix-assumption-in-readme into 773dbfdc38e75ab08f572f6a1c5fc321007dc252 on master.

:+1:


Support createBulk C8Y JSON topics

Issue description
A customer wants to send bulk measurements via thin-edge, each measurement has different timestamps. The current thin-edge JSON format can include timestamp only on the top level. But C8Y JSON supports createBulk.
Then I found that thin-edge dosen't support createBulk topics out-of-the-box.
Workaround
User can still use createBulk topics by:

Add the topic into c8y-bridge.conf, for example: topic measurement/measurements/createBulk out 2 c8y/ ""
Restart mosquitto service: systemctl restart mosquitto.service
Then thin-edge can forward the measurements to the platform. But thin-edge will lose this custom config after reconnecting tedge.

Expecting  solution
It would be great if thin-edge can support createBulk topics natively. According to C8Y documentation, C8Y supports:
 event/events/createBulk
 alarm/alarms/createBulk
 measurement/measurements/createBulk

Note: During development each of the added endpoints should be checked if they do work as intended (e.g. if they do create the telemetry data in Cumulocity). There is the possibility that the Cumulocity docs are not 100% correct, as there is some doubt on the functionality behind the alarm/alarms/createBulk and event/events/createBulk topics.

I can confirm that all 3 createBulk topics function as documented. The topics were tested by manually modifying the c8y-bridge.conf mosquitto bridge configuration and using the following commands:
event/events/createBulk
tedge mqtt pub c8y/event/events/createBulk "{
    \"events\": [
        {\"text\":\"bulk event 1\",\"type\":\"type1\",\"time\":\"$(date -Iseconds)\"},
        {\"text\":\"bulk event 2\",\"type\":\"type2\",\"time\":\"$(date -Iseconds)\"}
    ]
}"

child device
tedge mqtt pub c8y/event/events/createBulk "{
    \"events\": [
        {\"text\":\"bulk event 1\",\"type\":\"type1\",\"time\":\"$(date -Iseconds)\",\"externalSource\":{\"externalId\":\"issue3234:device:child01\",\"type\":\"c8y_Serial\"}},
        {\"text\":\"bulk event 2\",\"type\":\"type2\",\"time\":\"$(date -Iseconds)\",\"externalSource\":{\"externalId\":\"issue3234:device:child01\",\"type\":\"c8y_Serial\"}}
    ]
}"

tedge mqtt pub c8y/event/events/createBulk "{
    \"events\": [
        {\"text\":\"bulk event 1\",\"type\":\"example\",\"time\":\"2024-12-01T02:00:00Z\",\"externalSource\":{\"externalId\":\"issue3234:device:child01\",\"type\":\"c8y_Serial\"}},
        {\"text\":\"bulk event 2\",\"type\":\"example\",\"time\":\"2024-12-01T02:01:00Z\",\"externalSource\":{\"externalId\":\"issue3234:device:child01\",\"type\":\"c8y_Serial\"}}
    ]
}"

alarm/alarms/createBulk
tedge mqtt pub c8y/alarm/alarms/createBulk "{
    \"alarms\": [
        {\"text\":\"bulk alarm 1\",\"type\":\"type1\",\"severity\":\"MAJOR\",\"time\":\"$(date -Iseconds)\"},
        {\"text\":\"bulk alarm 2\",\"type\":\"type2\",\"severity\":\"MAJOR\",\"time\":\"$(date -Iseconds)\"}
    ]
}"

child device
tedge mqtt pub c8y/alarm/alarms/createBulk "{
    \"alarms\": [
        {\"text\":\"bulk alarm 1\",\"type\":\"type1\",\"severity\":\"MAJOR\",\"time\":\"$(date -Iseconds)\",\"externalSource\":{\"externalId\":\"issue3234:device:child01\",\"type\":\"c8y_Serial\"}},
        {\"text\":\"bulk alarm 2\",\"type\":\"type2\",\"severity\":\"MAJOR\",\"time\":\"$(date -Iseconds)\",\"externalSource\":{\"externalId\":\"issue3234:device:child01\",\"type\":\"c8y_Serial\"}}
    ]
}"

measurement/measurements/createBulk
tedge mqtt pub c8y/measurement/measurements/createBulk "{
    \"measurements\": [
        {\"env\":{\"temperature\":{\"value\":20.3,\"unit\":\"degC\"}},\"time\":\"$(date -Iseconds)\",\"type\":\"10_min\"},
        {\"env\":{\"temperature\":{\"value\":20.3,\"unit\":\"degC\"}},\"time\":\"$(date -Iseconds)\",\"type\":\"10_min\"}
    ]
}"

child device
tedge mqtt pub c8y/measurement/measurements/createBulk "{
    \"measurements\": [
        {\"env\":{\"temperature\":{\"value\":20.3,\"unit\":\"degC\"}},\"time\":\"$(date -Iseconds)\",\"type\":\"10_min\",\"externalSource\":{\"externalId\":\"issue3234:device:child01\",\"type\":\"c8y_Serial\"}},
        {\"env\":{\"temperature\":{\"value\":20.3,\"unit\":\"degC\"}},\"time\":\"$(date -Iseconds)\",\"type\":\"10_min\",\"externalSource\":{\"externalId\":\"issue3234:device:child01\",\"type\":\"c8y_Serial\"}}
    ]
}"

It's been merged and will be included in the next release 1.4.0.
But if you want to try it out now, you can install thin-edge.io from the main channel, e.g.
wget -O - thin-edge.io/install.sh | sh -s -- --channel main


Enable SSG with Cloudinary for Image Optimization

I don't need to have SSR for my blog, and would prefer to deploy it as a static site to AWS S3 for cost savings and fast load times. Currently, when running next export post build, an error is thrown due to next/image's default image loader:
Error: Image Optimization using Next.js' default loader is not compatible with next export.

Ideally, a user could toggle between building a SSR site vs a SSG site. If building a SSG site, it would work with Cloudinary for static export image optimization like described here: https://nextjs.org/docs/pages/building-your-application/deploying/static-exports

Also, related, are there any other modifications needed to export the build as a static site? I've noticed that 'Subscribe to newsletter' and 'Comments' don't seem to work I'm guessing that there are other things breaking that I don't realize? Here's a demo deployment of the tailwind-nextjs-starter-blog as a static site in S3 (the only modification is this https://github.com/timlrx/tailwind-nextjs-starter-blog/issues/231#issuecomment-915277585): https://d1xs66xjoxwam2.cloudfront.net/

Other than the line specified in https://github.com/timlrx/tailwind-nextjs-starter-blog/issues/231#issuecomment-915277585, you would need to delete the pages/api section as well as all Newsletter components since that relies on the internal api.  Comments should work fine since it relies on external services.

I am in the midst of updating the template to use the new app directory setup. Would try to include a guide on how to create a static build after it.

If there are any items you'd like community help for please let me know!

@timlrx I'm wondering if there's any update on building this template as a static site with the release of v2.0?

Yes, check out the guide over here under the static hosting services section: https://github.com/timlrx/tailwind-nextjs-starter-blog#deploy

@timlrx in the new documentation you recommend adding output: 'export' in next.config.js, however when running yarn build I get an error thrown due to custom headers:  https://nextjs.org/docs/messages/export-no-custom-routes
Would you also recommend removing these security headers in next.config.js? Do they even work without a server?

Yes, you are right. We have to remove the headers section in next.config.js as well. They don't work with a static build. I have updated the docs to reflect that.


dataman: Prevent database corruption

The size in g_per_item_size[item] is the real struct size

DM_SECTOR_HDR_SIZE bytes of header and the backend functions were
not taking in care it. So a call to dm_write() with more bytes than
the real struct is allowed, causing corruption in the header of the
next item.

Kudos to jeonghwan-lee for finding it. https://github.com/PX4/Firmware/issues/7927

Thanks!

Thanks zehortigoza and LorenzMeier


Just a "little script", An ETL Tale

Draft: https://docs.google.com/document/d/1sVMTNc3J3AWL6EJitZroYyum8EISLSmG3RdcPoBcFEw/edit?usp=sharing


Drag n Drop for files

LGTM just remove the semicolons :)

LGTM just remove the semicolons :)

I knew, KNEW, I was gunna forget them lol I think I got all of them


Bluetooth LE connectable unidirected advertisements' long intervals unreliable

Values greater than approx. 100 ms are unreliable for connectable unidirected advertisements, ex. 150 ms equals more likely to 800 ms, 1280 ms - 6500 ms (with high variations). Non-connectable unidirected advertisements' intervals are reliable. BTstack it is not the root of the problem. It is the same with or without it - just HCI commands written by cyw43 driver. To reproduce, just use some BTstack example, like hog_mouse_demo.c:
// setup advertisements
uint16_t adv_int_min = 0x0030;
uint16_t adv_int_max = 0x0030;
uint8_t adv_type = 0;

adv_int_min and adv_int_max are values of intervals in number of time slots (0,625 ms). Min value is 32 (0x20), max 16384 (0x4000). adv_type of 3 will switch it to non-connectable unidirected. It seems to be more likely firmware or CYW43439 ROM for Bluetooth.

What is unreliable, is interval value between advertisements, when the value is set to "high" number of milliseconds. To be honest, it won't be a real world issue, maybe there is something wrong with Bluetooth firmware, I don't know. Spec allows broad range of values and just high ones doesn't seem to do what they are told to do. I see it a problem, when Pico W would be told specifically to advertise in wide intervals for whatever reason. So very edge case. Since radio is on for a short amount of time to TX and comparing to Pico W current draw, there won't be great power savings.


[Common]: Add window size configuration in manifest.

We proposed to add recommended width and height for w3c manifest (see https://github.com/w3c/manifest/issues/310).
This is to implement it for crosswalk common which allows user to set window original size at launch time.
Next to do:
1, add min-width and min-height to set minimum size for application window.
2, add application storage to store the window size in local disk, so that at next launch time the application can restore the previous window size.

@kenchris @baleboy Please take a review.

@pozdnyakov and @kenchris I've updated the patch according to your feedback. Please take a review thanks.

lgtm

@kenchris I am planing to add the min-width / min-height and max-width / max-height in the next step, this is addressed in the commit log. Would you please merge this patch firstly?

well, I've updated the patch by adding the minimum / maximum size and I also have basic tests to ensure it's working expected. Please take a review and merge if it's Okay for you. @kenchris @pozdnyakov

@kenchris I have updated the changes according to your comments. Please take a look, thanks.


Consider using gofpdf

Note that github.com/jung-kurt/gofpdf is no longer being maintained, whereas github.com/go-pdf/fpdf is a drop-in replacement (I have done so on my local copy), that is being actively maintained and has performance enhancements.

A PR from @dcu has accomplished this. Thanks!