Test behaviour of Asset Manager clients when redirecting to S3

We want to test the behaviour on the Asset Manager clients of redirecting to assets on S3. This will help give us confidence that it's OK to deploy these changes to staging and production.
Dependencies

[x] Making S3 bucket publicly readable as per PR #101
[x] Deploying the branch in PR #120 to integration

Client apps of Asset Manager

Specialist Publisher

Assets are attached to Documents

Manuals Publisher

Assets are attached to Sections
Example of a section containing a linked and embedded attachment - https://www.gov.uk/guidance/the-highway-code/vehicle-markings

Service Manual

Assets are uploaded by dragging and dropping them into the text area of a "page"

Travel Advice Publisher

A single map attachment can be uploaded to a location
A single PDF attachment can be uploaded to a location

Publisher

Assets can be uploaded to Campaigns (which is a retired format)
Assets can be uploaded to Videos (which is a retired format)

@chrislo and I have tested the behaviour of redirecting assets to S3 in integration. We did this by deploying the branch from PR #120 and creating one of each of a Manual, Specialist Publisher document, Service Manual guide and updating a country within the Travel Advice Publisher:
This is what we did in each case:

Specialist Publisher

Create an AAIB report
Attach a PDF and an image to the AAIB report
Embed the image in the body of the report
Add a link to the PDF in the body of the AAIB report

Manuals Publisher

Create a manual with a single section
Attach a PDF and an image to the section
Embed the image in the body of the section
Add a link to the PDF in the body of the section

Service Manual

Create a Guide
Upload an image attachment to the body of the Guide

Travel Advice Publisher

Edit "Afghanistan"
Replace the map image with an alternative map image
Replace the map PDF with an alternative map PDF

In all cases, the HTML generated remains the same, i.e. the URLs have the form https://assets-origin.integration.publishing.service.gov.uk/media/598c4840ed915d0375d9405f/the-highway-code-vehicle-markings.pdf.
Embedded images

HTML remains the same.
The browser follows the redirect in order to render the image in the page.
User only sees new URL if they follow a link to the image directly (e.g. right click and "Open image in new tab") and they're redirected to the new URL.
Responding with 307 tells machines to continue using the Asset Manager URL to request the image.

Linked PDFs

HTML remains the same.
User sees the URL in the browser when they follow the link to the PDF (see screenshot below).
Responding with 307 tells machines to continue using the Asset Manager URL to request the image.

Based on @chrisroos' last comment, I've checked the remaining box in the PR description and I'm going to close this issue. @chrisroos: Please re-open if you think we've missed anything.


🐛 [flutterfire_ui] User is not redirected out of the login page after email link authentication

Bug report
I have copied the example in the flutterfire_ui documentation about authentication state and then registered an Email Link Provider following the documentation about passwordless authentication.
When the user clicks on sign in with magic link it open a new screen where the user can enter its email and click send magic link. He then receive a link in its mailbox and after clicking it, he is successfully redirected in the app and registred/logged in.
The problem is that he is redirected on the login page again and there is no automatic logic to take the user out of this screen once the authentication has been established. It is necessary to close and the re-open the app to navigate away from the login screen. It would be better if the login screen was automatically closed (popped of the navigator).
Steps to reproduce
Steps to reproduce the behavior:

Follow the tutorial on the flutterfire_ui documentation.
Click sign in with magic link
Enter you email and click send magic link
Go to your mailbox and click on the received link
You should be redirected on the page where you are supposed to enter you email.

Expected behavior
After clicking the link received via email, the user should be redirected on a loading screen while the dynamic link is processed, and then the user should be automatically redirected in the app being authenticated.
Sample project
The resulting code
class MyApp extends StatelessWidget {
  const MyApp({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Passwordless Authentication Example',
      theme: ThemeData(primarySwatch: Colors.blue),
      home: const AuthGate(),
    );
  }
}

class AuthGate extends StatelessWidget {
  const AuthGate({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    final actionCodeSettings = ActionCodeSettings(
      dynamicLinkDomain: "xxx.page.link",
      url: 'https://xxx.page.link/finish-sign-up',
      androidPackageName: "com.example.passwordless",
      androidInstallApp: true,
      handleCodeInApp: true,
    );

    return StreamBuilder<User?>(
      stream: FirebaseAuth.instance.userChanges(),
      builder: (context, snapshot) {
        if (!snapshot.hasData) {
          return SignInScreen(
            providerConfigs: [EmailLinkProviderConfiguration(actionCodeSettings: actionCodeSettings)],
          );
        }

        return ProfileScreen(
          providerConfigs: [EmailLinkProviderConfiguration(actionCodeSettings: actionCodeSettings)],
          avatarSize: 24,
        );
      },
    );
  }
}

Flutter doctor
Run flutter doctor and paste the output below:
Click To Expand
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, 2.8.1, on Ubuntu 20.04.3 LTS 5.4.0-91-generic, locale en_US.UTF-8)
[!] Android toolchain - develop for Android devices (Android SDK version 29.0.3)
    ✗ cmdline-tools component is missing
      Run `path/to/sdkmanager --install "cmdline-tools;latest"`
      See https://developer.android.com/studio/command-line for more details.
    ✗ Android license status unknown.
      Run `flutter doctor --android-licenses` to accept the SDK licenses.
      See https://flutter.dev/docs/get-started/install/linux#android-setup for more details.
[✓] Chrome - develop for the web
[✓] Linux toolchain - develop for Linux desktop
[✓] Android Studio (version 4.1)
[✓] Android Studio
[✓] IntelliJ IDEA Community Edition (version 2019.3)
[✓] VS Code (version 1.63.2)
[✓] Connected device (3 available)

! Doctor found issues in 1 category.

Flutter dependencies
Run flutter pub deps -- --style=compact and paste the output below:
Click To Expand
Dart SDK 2.15.1
Flutter SDK 2.8.1
xxxx 1.0.0+1

dependencies:
- cupertino_icons 1.0.4
- firebase_analytics 9.0.4 [firebase_analytics_platform_interface firebase_analytics_web firebase_core firebase_core_platform_interface flutter]
- firebase_auth 3.3.4 [firebase_auth_platform_interface firebase_auth_web firebase_core firebase_core_platform_interface flutter meta]
- firebase_core 1.10.6 [firebase_core_platform_interface firebase_core_web flutter meta]
- flutter 0.0.0 [characters collection meta typed_data vector_math sky_engine]
- flutterfire_ui 0.3.0 [cloud_firestore collection crypto desktop_webview_auth firebase_auth firebase_core firebase_database firebase_dynamic_links flutter flutter_facebook_auth flutter_localizations flutter_svg google_sign_in sign_in_with_apple twitter_login]
- get_it 7.2.0 [async collection]
- grpc_web 0.0.1 [protobuf oxidized]
- oxidized 5.1.0 [equatable]

dev dependencies:
- flutter_lints 1.0.4 [lints]
- flutter_test 0.0.0 [flutter test_api path fake_async clock stack_trace vector_math async boolean_selector characters charcode collection matcher meta source_span stream_channel string_scanner term_glyph typed_data]

transitive dependencies:
- async 2.8.2 [collection meta]
- boolean_selector 2.1.0 [source_span string_scanner]
- characters 1.2.0
- charcode 1.3.1
- clock 1.1.0
- cloud_firestore 3.1.5 [cloud_firestore_platform_interface cloud_firestore_web collection firebase_core firebase_core_platform_interface flutter meta]
- cloud_firestore_platform_interface 5.4.10 [collection firebase_core flutter meta plugin_platform_interface]
- cloud_firestore_web 2.6.5 [cloud_firestore_platform_interface collection firebase_core firebase_core_web flutter flutter_web_plugins js]
- collection 1.15.0
- crypto 3.0.1 [collection typed_data]
- desktop_webview_auth 0.0.2 [crypto flutter http]
- equatable 2.0.3 [collection meta]
- fake_async 1.2.0 [clock collection]
- firebase_analytics_platform_interface 3.0.3 [firebase_core flutter meta plugin_platform_interface]
- firebase_analytics_web 0.4.0+4 [firebase_analytics_platform_interface firebase_core firebase_core_web flutter flutter_web_plugins js]
- firebase_auth_platform_interface 6.1.9 [firebase_core flutter meta plugin_platform_interface]
- firebase_auth_web 3.3.5 [firebase_auth_platform_interface firebase_core firebase_core_web flutter flutter_web_plugins http_parser intl js meta]
- firebase_core_platform_interface 4.2.3 [collection flutter meta plugin_platform_interface]
- firebase_core_web 1.5.3 [firebase_core_platform_interface flutter flutter_web_plugins js meta]
- firebase_database 9.0.4 [firebase_core firebase_core_platform_interface firebase_database_platform_interface firebase_database_web flutter]
- firebase_database_platform_interface 0.2.0+3 [collection firebase_core flutter meta plugin_platform_interface]
- firebase_database_web 0.2.0+3 [firebase_core firebase_core_web firebase_database_platform_interface flutter flutter_web_plugins js]
- firebase_dynamic_links 4.0.3 [firebase_core firebase_core_platform_interface firebase_dynamic_links_platform_interface flutter meta plugin_platform_interface]
- firebase_dynamic_links_platform_interface 0.2.0+3 [firebase_core flutter meta plugin_platform_interface]
- fixnum 1.0.0
- flutter_facebook_auth 3.5.7 [flutter flutter_facebook_auth_platform_interface flutter_facebook_auth_web]
- flutter_facebook_auth_platform_interface 2.7.1 [flutter plugin_platform_interface]
- flutter_facebook_auth_web 2.6.0+2 [flutter flutter_web_plugins js flutter_facebook_auth_platform_interface]
- flutter_localizations 0.0.0 [flutter intl characters clock collection meta path typed_data vector_math]
- flutter_svg 1.0.0 [flutter meta path_drawing vector_math xml]
- flutter_web_plugins 0.0.0 [flutter js characters collection meta typed_data vector_math]
- google_sign_in 5.2.1 [flutter google_sign_in_platform_interface google_sign_in_web meta]
- google_sign_in_platform_interface 2.1.0 [flutter meta quiver]
- google_sign_in_web 0.10.0+3 [flutter flutter_web_plugins google_sign_in_platform_interface js meta]
- http 0.13.4 [async http_parser meta path]
- http_parser 4.0.0 [charcode collection source_span string_scanner typed_data]
- intl 0.17.0 [clock path]
- js 0.6.3
- lints 1.0.1
- matcher 0.12.11 [stack_trace]
- meta 1.7.0
- path 1.8.0
- path_drawing 1.0.0 [vector_math meta path_parsing flutter]
- path_parsing 1.0.0 [vector_math meta]
- petitparser 4.4.0 [meta]
- plugin_platform_interface 2.0.2 [meta]
- protobuf 2.0.1 [fixnum collection]
- quiver 3.0.1+1 [matcher]
- sign_in_with_apple 3.3.0 [flutter meta sign_in_with_apple_platform_interface sign_in_with_apple_web]
- sign_in_with_apple_platform_interface 1.0.0 [flutter plugin_platform_interface meta]
- sign_in_with_apple_web 1.0.1 [flutter flutter_web_plugins sign_in_with_apple_platform_interface js]
- sky_engine 0.0.99
- source_span 1.8.1 [collection path term_glyph]
- stack_trace 1.10.0 [path]
- stream_channel 2.1.0 [async]
- string_scanner 1.1.0 [charcode source_span]
- term_glyph 1.2.0
- test_api 0.4.3 [async boolean_selector collection meta source_span stack_trace stream_channel string_scanner term_glyph matcher]
- twitter_login 4.0.1 [flutter crypto http]
- typed_data 1.3.0 [collection]
- vector_math 2.1.1
- xml 5.3.1 [collection meta petitparser]

@fribeau the example in the docs shows that you need to listen to FirebaseAuth.instance.authStateChanges(), so when the user is signed in, the top-level widget gets rebuilt and LoginScreen is no longer shown.
An alternative solution would be passing actions down to SignInScreen as shown here
Example:
SignInScreen(
  actions: [
    AuthStateChangeAction<SignedIn>((context, _) {
      Navigator.of(context).pushReplacementNamed('/profile');
    }),
  ],
  // ...
)

Let us know if this helps

im having this issue on my android device, but not on my apple device

@fribeau the example in the docs shows that you need to listen to FirebaseAuth.instance.authStateChanges(), so when the user is signed in, the top-level widget gets rebuilt and LoginScreen is no longer shown.
An alternative solution would be passing actions down to SignInScreen as shown here
Example:
SignInScreen(
  actions: [
    AuthStateChangeAction<SignedIn>((context, _) {
      Navigator.of(context).pushReplacementNamed('/profile');
    }),
  ],
  // ...
)

Let us know if this helps

Perfect !! This is exactly what I was trying to do. I thought the SignInScreen widget would take care of it automatically but this solution works perfectly for me.
I had missed this part in the documentation sorry.
Thanks


RequestError with ERR_INVALID_ARG_TYPE

Hello,
I have (in a production environment only) this kind of error that happens randomly when I try call some methods of the library (using the 1.1.2 version) like the following:
      const mandate = await client.mandates.find(mandateId);

      const { account_number_ending: bankAccountNumberEnding } = await client.customerBankAccounts.find(
        mandate.links.customer_bank_account,
      );

OR
      const { url } = await client.mandatePdfs.create(
        {
          links: {
            mandate: mandateId,
          },
        },
        '',
        {
          'Accept-Language': language || 'en',
        },
      );

The error:
"extensions": {
  "name": "RequestError",
  "code": "GOCARDLESS_ERROR",
  "exception": {
    "name": "RequestError",
    "code": "ERR_INVALID_ARG_TYPE"
  }
}

GOCARDLESS_ERROR is an internal error name, but RequestError and ERR_INVALID_ARG_TYPE are returned by GoCardless.
Do you know where this could come from? It sometimes works like a charm, but then I will have this error.

Hey @RomainCscnLF, apologies for getting back so late.
I've attempted to replicate this behaviour, but no luck. I've got a few follow-up questions to help me get further with this:
Just to be clear, does this only happens in the production environment?
Does this happen on all endpoints and method types, or only some?

My guess at this point is that it's something related to the logic you're using when populating the request parameters, and the way we then handle these invalid requests.
For example, in the mandatePdfs.create call, the language value in the Accept-Language header might, on occasion, get set incorrectly. Then, rather than return a helpful error message telling you what went wrong, we might just return a generic INVALID_ARG_TYPE one.
I can't replicate this behaviour on my end, but have you explored this possibility?

Just to be clear, does this only happens in the production environment?
Does this happen on all endpoints and method types, or only some?

I tested to replicate this in my dev environment but could not. So I can confirm it is only in my production environment.
It happens on all endpoints (not only mandatePdfs.create). So I don't think it could come from the Accept-Language header.
So even with this simple call const mandate = await client.mandates.find(mandateId); where I'm sure that there is a mandateId, it sometimes happened.

Hmm, are there any key differences between your production and staging environment?
We recently had an issue where an integrator had a similar issue with their integration working fine locally, but not in production.
I'm wondering if something similar is happening in your case.

I don't know enough about the key differences between production and dev environment. I'll check with some of my colleagues.
That probably is something similar.

Hi again @tallosan ,
Could it be that some headers are missing from the call depending on the environment?

I traced down the error by adding some logs, our config looks good.
I'm now sure that I'm getting the error when I'm calling this method:
const mandate = await client.mandates.find(mandateId);

I assured myself that mandateId is a string by logging is type before with this:
logger.info({ mandateIdType: typeof mandateId }, 'MANDATE ID type');

And that returns string. I don't really know what to do next.

Hi again @tallosan ,
Could it be that some headers are missing from the call depending on the environment?

The missing headers should give you a different error, so I think it's unlikely. I'll look into it though.
Just to be clear, are you saying that the error only happens on this particular method (mandates.find)?
I'll see what I can do, but this kind of issue is quite difficult to resolve given the lack of visibility (and rightly so) that we have into your setup. Narrowing this down to one method should help, but unless I'm able to replicate this behaviour I'll still be a bit in the dark.

Just to be clear, are you saying that the error only happens on this particular method (mandates.find)?

Unfortunately, it doesn't seem related to this method in particular. The issue also happens on mandatePdfs.create and mandates.create.
It looks like an error isn't caught properly. I looked at the code, could it come from the method request? It's the only place where there is a try/catch. And there is an error code so I'm thinking that it is caught but there is nothing more?

Hello again @tallosan.
I rewrote the queries we had using http calls directly, and we're not facing errors anymore. So it looks like it definitely is something on the gocardless-nodejs lib.
FYI, we're using AWS on our prod env.

Hey @RomainCscnLF, I'm following up on @tallosan's investigation.
Apparently, the RequestError error is coming from Got, the HTTP client we're using under the hood to interact with our API. As for ERR_INVALID_ARG_TYPE, it's a Node.js error code.
In other words, I think the original error is thrown by one of the Node.js APIs and is wrapped by Got in a custom RequestError. Later on, we catch this error in our request method (as you rightfully pointed out in your previous comment) and re-throw it here.
To move forward, we'd need to have more information on the original error. A stack trace could be very helpful in that regard.
You should be able to recover a stack trace using the stack property of the error object:
try {
  await client.mandates.find(mandateId)
} catch (e) {
  console.log(e.stack)
}

Could you communicate that back to us?
In addition, could you please share:

The version of Node.js you're using in production?
The version of Got that was installed alongside our client library? (You should be able to retrieve this information with npm list got.)


Code Quality: Method has overload with cancellation support

Description
Many methods in the code base supports cancellation and are nothing using the CancellationToken.
Concerned code
<platforms><Files.App>\Services\UpdateService.cs (1 issue)
<platforms><Files.App>\Utils\Storage\Search\FolderSearch.cs (3 issues)
<platforms><Files.App>\Utils\Archives\CompressArchiveModel.cs (1 issue)
<platforms><Files.App>\Services\SideloadUpdateService.cs (1 issue)
<platforms><Files.App>\Utils\Storage\StorageItems\VirtualStorageFile.cs (2 issues)
<platforms><Files.App>\Utils\Storage\StorageItems\NativeStorageFile.cs (7 issues)
<platforms><Files.App>\Utils\Storage\StorageItems\FtpStorageFolder.cs (5 issues)
<platforms><Files.App>\Utils\Storage\Operations\FilesystemOperations.cs (29 issues)
<platforms><Files.App>\Utils\Storage\StorageItems\SystemStorageFile.cs (8 issues)
<platforms><Files.App>\Utils\Storage\StorageItems\ZipStorageFolder.cs (8 issues)
<platforms><Files.App>\Utils\Storage\StorageItems\ZipStorageFile.cs (4 issues)
<platforms><Files.App>\Utils\Storage\StorageBaseItems\BaseStorageFolder.cs (6 issues)
<platforms><Files.App>\Utils\Storage\Operations\FileOperationsHelpers.cs (3 issues)
<platforms><Files.App>\Data\Models\ItemViewModel.cs (5 issues)
<platforms><Files.App>\Utils\Storage\StorageItems\FtpStorageFile.cs (1 issue)
<platforms><Files.App>\Data\Factories\ShellContextFlyoutHelper.cs (1 issue)
<platforms><Files.App>\Helpers\Win32\Win32Helper.Storage.cs (2 issues)
<platforms><Files.App>\Utils\Git\GitHelpers.cs (3 issues)
<platforms><Files.App>\Utils\Storage\StorageItems\StreamWithContentType.cs (2 issues)
<platforms><Files.App>\ViewModels\Properties\Items\FolderProperties.cs (1 issue)
<platforms><Files.App>\ViewModels\Properties\Items\LibraryProperties.cs (1 issue)
Gains

Reliability, if the user cancels an operation, the operation will respond faster because of the CancellationToken

Requirements

Passing the CancellationToken  in the methods specified by the analyzer

Comments
No response

Beaches this is what I’ve also been thinking, I can fix some of them.


increase default RAM

from 3G to 4G / core. save ppl from segfaults

This was surfacing many times, for example here: https://github.com/bcbio/bcbio-nextgen/issues/3337

Thank you, good idea!


Function parameter parentheses don't print well with binary operators

Here are some issues on current master.

Expression-wrapped parentheses around function parameters on the left side of a binary operator are broken:
type X = (x: (() => void) | b) => void

type X = ((() -> void)) | b -> void

Which should be:
type X = ((() -> void) | b) -> void

Additionally, function parameters on the left side of a binary operator need clarifying parentheses:
Ignore this one, wrong operator precedence.
type X = (x: () => void | a) => void

type X = (() -> void | a) -> void

Which should be:
type X = ((() -> void) | a) -> void

Likewise, functions on the right side of a binary operator need clarifying parentheses too:
type X = (x: a | () => void) => void

type X = a | () -> void -> void

Which should be:
type X = (a | () -> void) -> void

:exploding_head:

A helpful suggestion I received: May be worth looking at Haskell's implementation of showsPrec.

Ideas:

Build up a LIFO stack of "context" in state. A lambda for example knows itself it needs parentheses if its parent context is the left side of a binary operator.
Change the return type of our RWS from Text so (Text, TokenType). A binary operator knows its left expression needs parentheses if its a lambda.

Should be a lot better now: https://github.com/samhh/tshm/commit/208224237b7950277deb29664fde51c81ea5c56e#diff-058ced9768d50230db89d9b1d7aeb9683832a9511d475b48b3caa8afbced46faR192


Update mp client in bff

Description
Updated Metering Point client packages wherein Reading Occurrence is changed from a string to an enum.
References

#0000

Don't you just love it when bots do most of the work?

Don't you just love it when bots do most of the work?

It's perfect! :)


[BUG] unable to parse string (password)

Hello found a bug in your code, when a new player registered on my server.
His password has a leading 0 and when he tried to login I get an error about being upable to parse 0 as a string in the console.

here is the exact error

actually this bug has nothing to do with the password, the error, it appears, is when the user's password in the database is empty(as it is because my website requires email account activation). as a temporary fix I've set the default value for the password field to "null" instead of empty.


Problem with version torch 2.3.1

macos (M1): sonoma 14.0
(omni) andrejmatienko@MacBook-Pro-Andrej-5 mini-omni % pip install -r requirements.txt
ERROR: Could not find a version that satisfies the requirement torch==2.3.1 (from versions: 1.11.0, 1.12.0, 1.12.1, 1.13.0, 1.13.1, 2.0.0, 2.0.1, 2.1.0, 2.1.1, 2.1.2, 2.2.0, 2.2.1, 2.2.2)
ERROR: No matching distribution found for torch==2.3.1

hi, I aslo test it will work with
torch==2.2.0
torchvision==0.17.0
torchaudio==2.2.0

you can test with these versions.


[BUG] - Connection to ssh over mobile not possible anymore

The release from yesterday on android 11:
I cannot connect too a ssh server which locates in my home network anymore.
BTW: Why isn't it possible to add dns0.eu as the 3. entry in dns settings? It worked in the release before this.

Solved: One problem was, that the app ran twice: The last release candidate and the last release. I uninstalled the rc in android settings -> apps.
(Is it possible to prevent this?)


feat: support guzzle 6

Laravel Vite works just fine with Guzzle 6. I'd like it to be allowed as my company is stuck with Guzzle 6 because of some other unmaintaned library.

Apparently that changes breaks the style CI. Any idea why?

/usr/bin/git -c protocol.version=2 fetch --no-tags --prune --progress --no-recurse-submodules --depth=1 origin +refs/heads/guzzle-6*:refs/remotes/origin/guzzle-6* +refs/tags/guzzle-6*:refs/tags/guzzle-6*

Seems it's an issue with PRs coming from forks:

https://github.com/WeblateOrg/weblate/issues/6240#issuecomment-869715886
https://github.com/innocenzi/laravel-vite/blob/6c72ca08dfecc950f29a096f9fbe281c3be5511f/.github/workflows/php-cs-fixer.yml#L12-L13


Shared Tooltip goes invisible when changing the Usercontrol

I hope the GIF explains what i mean.
When not just write me on gitter.

Its some sort of a timing problem.
When i do it slow it works like normal.
But if you do it fast the Tooltip goes invisible.

Previous commit fixes this, I have to say that I am not 100% convinced about this solution but it works, and I don't see how it could fail
Thanks for reporting again!


Typescript types definition missing for es5 build

The current type definition did only work if pdfjs is directly imported, but not if the es5 build is used (when used with node).
I had to add a d.ts file to make it work. But I think this should be directly included in the release.
declare module "pdfjs-dist/es5/build/pdf.js" {
  export * from "pdfjs-dist";
}

/cc @tamuratak @ineiti Could one of you perhaps comment here on how this works? I believe the existing types that you added/improved should be generally available if I'm not mistaken, but I'm not sure how to test this.

/cc @tamuratak @ineiti Could one of you perhaps comment here on how this works? I believe the existing types that you added/improved should be generally available if I'm not mistaken, but I'm not sure how to test this.

I think it is an easy solution to tell users write the following:
const pdfjsLib: typeof import('pdfjs-dist') = require('pdfjs-dist/es5/build/pdf.js');

See doc for typeof import.
If we want an out-of-the-box solution, it is not easy. TypeScript finds a type file types/pdf.d.ts for build/pdf.js based on the properties main and types of pdfjs-dist/package.json.
  "license": "Apache-2.0",
  "main": "build/pdf.js",
  "name": "pdfjs-dist",
  "repository": {
    "type": "git",
    "url": "git+https://github.com/mozilla/pdfjs-dist.git"
  },
  "types": "types/pdf.d.ts",
  "version": "2.6.347"

Therefore, TypeScript cannot find the type file types/pdf.d.ts for pdfjs-dist/es5/build/pdf.js now. Because we cannot put multiple files to the main property, microsoft/TypeScript/issues/21423, we have no way to tell TypeScript the location of the type file for pdfjs-dist/es5/build/pdf.js.
The only solution we can have is putting a pdf.d.ts file in the same directory as pdfjs-dist/es5/build/pdf.js. The content of the pdf.d.ts file should be:
export * from 'pdfjs-dist'

I think it is an easy solution to tell users write the following:
const pdfjsLib: typeof import('pdfjs-dist') = require('pdfjs-dist/es5/build/pdf.js');

See doc for typeof import.
If we want an out-of-the-box solution, it is not easy. TypeScript finds a type file types/pdf.d.ts for build/pdf.js based on the properties main and types of pdfjs-dist/package.json.
  "license": "Apache-2.0",
  "main": "build/pdf.js",
  "name": "pdfjs-dist",
  "repository": {
    "type": "git",
    "url": "git+https://github.com/mozilla/pdfjs-dist.git"
  },
  "types": "types/pdf.d.ts",
  "version": "2.6.347"

Therefore, TypeScript cannot find the type file types/pdf.d.ts for pdfjs-dist/es5/build/pdf.js now. Because we cannot put multiple files to the main property, microsoft/TypeScript/issues/21423, we have no way to tell TypeScript the location of the type file for pdfjs-dist/es5/build/pdf.js.
The only solution we can have is putting a pdf.d.ts file in the same directory as pdfjs-dist/es5/build/pdf.js. The content of the pdf.d.ts file should be:
export * from 'pdfjs-dist'

I think the first approach can not work when ES Modules are used cause require is not allowed there.
My guess is that the second approach would be far better.
Tanks for looking into this!

I think the first approach can not work when ES Modules are used cause require is not allowed there.
My guess is that the second approach would be far better.
Tanks for looking into this!

Given that this particular issue seem to be mostly related to building/packaging the PDF.js library, rather than TypeScript as such, I've submitted a small patch following the suggestion in https://github.com/mozilla/pdf.js/issues/12827#issuecomment-756471707. @tamuratak Thanks for your help!

@lanwin Please keep in mind that the PDF.js library is still a JavaScript project; hence it's generally speaking going up to the TypeScript users themselves to help maintain/improve the definitions where necessary :-)

Given that this particular issue seem to be mostly related to building/packaging the PDF.js library, rather than TypeScript as such, I've submitted a small patch following the suggestion in https://github.com/mozilla/pdf.js/issues/12827#issuecomment-756471707. @tamuratak Thanks for your help!

@lanwin Please keep in mind that the PDF.js library is still a JavaScript project; hence it's generally speaking going up to the TypeScript users themselves to help maintain/improve the definitions where necessary :-)


quickly exit on error returns

"Guesstimate" for fixing #165
Is it possible that errors raised but not immediately acted up (stopping any further execution) can trigger follow-on problems in openssl?

@levitte: May I pick your brain and ask the question above to you: If "ERR_raise" is not followed by stopping execution immediately (as only now done via this PR), could mayhem such as reported in #165 ensue? Why then didn't this manifest earlier & on other platforms?
The more I think about it, it looks like I really misunderstood ERR_raise when writing the original code:
I was under the assumption that (ID) registration errors are no reasons to terminate initialization, as no problem would occur if those algorithms (not successfully registered) would never be used. And if they were used (and failed), the error queue entry generated (by the original code) would "point the way".
In other words: Is merging this PR essential for correct operation of oqsprovider?

Your assumption about ERR_raise are correct as far as I understand you.  All they do is record an error record into the error queue.  Period.  What happens in #165 is something different, as you can see from my answer there.

Thanks, @levitte for the feedback. So we could leave the logic as-is.
So, asking @dstebila @bhess @mouse07410 for their opinion: Should oqsprovider fail quickly when any object registration error is reported by openssl (as per this PR) or keep running until openssl encounters a "real"/operational error (as is the case with the current "main" branch)?
I personally now tend to the former, given we have issues where openssl crashes before reporting errors, so setting this "Ready for Review".

Thanks, @levitte for the feedback. So we could leave the logic as-is.
So, asking @dstebila @bhess @mouse07410 for their opinion: Should oqsprovider fail quickly when any object registration error is reported by openssl (as per this PR) or keep running until openssl encounters a "real"/operational error (as is the case with the current "main" branch)?
I personally now tend to the former, given we have issues where openssl crashes before reporting errors, so setting this "Ready for Review".

I don't know enough about this situation to have an informed opinion.


Reading password from stdin does not work

It looks like in #12 support was added for reading pw from stdin, but this isn't working for me.
$ echo 12345678 | minisign -G -s my-key.key -p my-key.pub
Please enter a password to protect the secret key.

Password:
Password (one more time): get_password()

It then exits, and no keys are saved on the disk.

@beep-beep-beep-boop I cannot reproduce this.
» echo 12345678 | minisign -G -s my-key.key -p my-key.pub
Deriving a key from the password in order to encrypt the secret key... done

The secret key was saved as my-key.key - Keep it secret!
The public key was saved as my-key.pub - That one can be public.

Files signed using this key pair can be verified with the following command:

minisign -Vm <file> -P RWRhmi/k8vRcsGBkeg8hYWh7+0JAC6HzsuHSIhoWZozOHQ3DJGKKrj/Q
» cat my-key.pub
untrusted comment: minisign public key: B05CF4F2E42F9A61
RWRhmi/k8vRcsGBkeg8hYWh7+0JAC6HzsuHSIhoWZozOHQ3DJGKKrj/Q

» cat my-key.key
untrusted comment: minisign encrypted secret key
RWRTY0IymwhdxsG+nfaUBmiPqP3adwMfszI+k2JkKuYEbM8xNlIAAAACAAAAAAAAAEAAAAAAd8zmq3roqJg86kyH3NLcX5FXZaQ1ZfE5BhD4/9wWFuIJm37cyvfCYsL2hnKkjqbXKuXua2zcbT46ILI/fG/xckFL0mb/e8v7rIjMmNLmfNxSt7f5brdcQ668sZTjs67wrHOMuGOkWNQ=


Populate slug field for existing hunts

Adds a data migration for existing hunts that creates a slug based on
the hunt's primary key, which is already guaranteed to be unique.
This migration ensures that existing dbs aren't broken by #201.

Thank you!!


TLS Authentication

Hello there,
This is primarily a follow-up on #127, which resolved concerns regarding SASL_SSL but not for instances that require TLS.
When connecting to my Kafka instance, I have to provide a CA location, Certification Location, and Key Location.
When utilizing a kcat, this would typically look like the following:
kcat -b example.com:9093 -t topic_name \
  -X security.protocol=ssl \
  -X ssl.ca.location=/some/location/kafka.crt \
  -X ssl.certificate.location=/some/location/client.crt \
  -X ssl.key.location=/some/location/client.key \
  -X ssl.endpoint.identification.algorithm=none

The documentation includes instructions for utilizing username/password, but not the above setup.
While username and password authentication via SSL is appreciated, improved security via TLS/certificate and key provisioning would help support more instances of Kafka.

Hey @corsair :wave:
have you tried specifying your config using the withOption or withOptions methods?
$consumer = \Junges\Kafka\Facades\Kafka::consumer()
    ->withOptions([
        'ssl.ca.location' => '/some/location/kafka.crt',
        'ssl.certificate.location' => '/some/location/client.crt',
        'ssl.key.location' => '/some/location/client.key',
        'ssl.endpoint.identification.algorithm' => 'none'
    ]);

Closing this now. Feel free to open another issue if your problem persists.

Hey @mateusjunges, thank you dearly for the response, and I apologize for responding so late; it appears that said configuration/options aren't working or are being bypassed in some capacity.
With the following code, I cannot connect to the server, however is successful when connecting via kcat/other tools. I have also tried without the ->withSecurityProtocol('SSL') line, which had no impact.
$consumer = Kafka::consumer()
    ->withSecurityProtocol('SSL')
    ->withOptions([
        'ssl.ca.location' => storage_path('certs/kafka.crt'),
        'ssl.certificate.location' => storage_path('certs/client.crt'),
        'ssl.key.location' => storage_path('certs/client.key'),
        'ssl.endpoint.identification.algorithm' => 'none',
        //'debug' => 'security,broker,protocol',
        //'log_level' => (string) LOG_DEBUG, // Enable debug logging
    ])
    ->subscribe('example')
    ->withHandler(function (ConsumerMessage $message) {
        ProcessKafkaVehicleMessage::dispatch($message);
    })
    ->build();

try {
        $consumer->consume();
    } catch (Exception $e) {
        Log::error('Kafka error.', [$e]);
    } catch (ConsumerException $e) {
        Log::error('Kafka consumer error.', [$e]);
    }

My environmental values are as so:
KAFKA_BROKERS=kafka.example.com:9093
KAFKA_SECURITY_PROTOCOL=SSL
KAFKA_MECHANISMS=SSL

Here are my rdkafka and broker versions:
// Client

rdkafka support => enabled
version => 6.0.3
build date => Jul  2 2022 13:15:21
librdkafka version (runtime) => 2.5.3
librdkafka version (build) => <IP_ADDRESS>

// Server (Broker)

Kafka version: 3.8.0

Here are the logs I've gotten.
%6|1729083027.316|FAIL|rdkafka#producer-2| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Disconnected while requesting ApiVersion: might be caused by incorrect security.protocol configuration (connecting to a SSL listener?) or broker version is < 0.10 (see api.version.request) (after 48ms in state APIVERSION_QUERY)
%3|1729083027.316|ERROR|rdkafka#producer-2| [thrd:kafka.example.com:9093/bootstrap]: 1/1 brokers are down
%6|1729083027.316|FAIL|rdkafka#consumer-1| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Disconnected while requesting ApiVersion: might be caused by incorrect security.protocol configuration (connecting to a SSL listener?) or broker version is < 0.10 (see api.version.request) (after 48ms in state APIVERSION_QUERY)
%3|1729083027.316|ERROR|rdkafka#consumer-1| [thrd:kafka.example.com:9093/bootstrap]: 1/1 brokers are down
%3|1729083027.316|ERROR|rdkafka#consumer-1| [thrd:app]: rdkafka#consumer-1: kafka.example.com:9093/bootstrap: Disconnected while requesting ApiVersion: might be caused by incorrect security.protocol configuration (connecting to a SSL listener?) or broker version is < 0.10 (see api.version.request) (after 48ms in state APIVERSION_QUERY)
%6|1729083027.572|FAIL|rdkafka#producer-2| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Disconnected while requesting ApiVersion: might be caused by incorrect security.protocol configuration (connecting to a SSL listener?) or broker version is < 0.10 (see api.version.request) (after 46ms in state APIVERSION_QUERY, 1 identical error(s) suppressed)
%6|1729083027.714|FAIL|rdkafka#consumer-1| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Disconnected while requesting ApiVersion: might be caused by incorrect security.protocol configuration (connecting to a SSL listener?) or broker version is < 0.10 (see api.version.request) (after 46ms in state APIVERSION_QUERY, 1 identical error(s) suppressed)
%3|1729083027.714|ERROR|rdkafka#consumer-1| [thrd:app]: rdkafka#consumer-1: kafka.example.com:9093/bootstrap: Disconnected while requesting ApiVersion: might be caused by incorrect security.protocol configuration (connecting to a SSL listener?) or broker version is < 0.10 (see api.version.request) (after 46ms in state APIVERSION_QUERY, 1 identical error(s) suppressed)
^C%3|1729083029.183|ERROR|rdkafka#producer-2| [thrd:app]: rdkafka#producer-2: kafka.example.com:9093/bootstrap: Disconnected while requesting ApiVersion: might be caused by incorrect security.protocol configuration (connecting to a SSL listener?) or broker version is < 0.10 (see api.version.request) (after 48ms in state APIVERSION_QUERY)
%3|1729083029.183|ERROR|rdkafka#producer-2| [thrd:app]: rdkafka#producer-2: kafka.example.com:9093/bootstrap: Disconnected while requesting ApiVersion: might be caused by incorrect security.protocol configuration (connecting to a SSL listener?) or broker version is < 0.10 (see api.version.request) (after 46ms in state APIVERSION_QUERY, 1 identical error(s) suppressed)

If I enable additional debugging, I get the following:
%7|1729082762.672|BROKER|rdkafka#consumer-1| [thrd:app]: GroupCoordinator: Added new broker with NodeId -1
%7|1729082762.672|BRKMAIN|rdkafka#consumer-1| [thrd:GroupCoordinator]: GroupCoordinator: Enter main broker thread
%7|1729082762.672|BRKMAIN|rdkafka#consumer-1| [thrd::0/internal]: :0/internal: Enter main broker thread
%7|1729082762.672|BROKER|rdkafka#consumer-1| [thrd:app]: kafka.example.com:9093/bootstrap: Added new broker with NodeId -1
%7|1729082762.672|BRKMAIN|rdkafka#consumer-1| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Enter main broker thread
%7|1729082762.672|CONNECT|rdkafka#consumer-1| [thrd:main]: kafka.example.com:9093/bootstrap: Selected for cluster connection: coordinator query (broker has 0 connection attempt(s))
%7|1729082762.672|INIT|rdkafka#consumer-1| [thrd:app]: librdkafka v2.5.3 (0x20503ff) rdkafka#consumer-1 initialized (builtin.features gzip,snappy,ssl,sasl,regex,lz4,sasl_gssapi,sasl_plain,sasl_scram,plugins,zstd,sasl_oauthbearer,http,oidc, CC CXX PKGCONFIG OSXLD LIBDL PLUGINS ZLIB SSL SASL_CYRUS ZSTD CURL HDRHISTOGRAM LZ4_EXT SYSLOG SNAPPY SOCKEM SASL_SCRAM SASL_OAUTHBEARER OAUTHBEARER_OIDC, debug 0x282)
%7|1729082762.672|CONNECT|rdkafka#consumer-1| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Received CONNECT op
%7|1729082762.672|STATE|rdkafka#consumer-1| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Broker changed state INIT -> TRY_CONNECT
%7|1729082762.672|CONNECT|rdkafka#consumer-1| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: broker in state TRY_CONNECT connecting
%7|1729082762.672|STATE|rdkafka#consumer-1| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Broker changed state TRY_CONNECT -> CONNECT
%7|1729082762.672|BRKMAIN|rdkafka#producer-2| [thrd::0/internal]: :0/internal: Enter main broker thread
%7|1729082762.672|BROKER|rdkafka#producer-2| [thrd:app]: kafka.example.com:9093/bootstrap: Added new broker with NodeId -1
%7|1729082762.672|BRKMAIN|rdkafka#producer-2| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Enter main broker thread
%7|1729082762.672|CONNECT|rdkafka#producer-2| [thrd:app]: kafka.example.com:9093/bootstrap: Selected for cluster connection: bootstrap servers added (broker has 0 connection attempt(s))
%7|1729082762.672|INIT|rdkafka#producer-2| [thrd:app]: librdkafka v2.5.3 (0x20503ff) rdkafka#producer-2 initialized (builtin.features gzip,snappy,ssl,sasl,regex,lz4,sasl_gssapi,sasl_plain,sasl_scram,plugins,zstd,sasl_oauthbearer,http,oidc, CC CXX PKGCONFIG OSXLD LIBDL PLUGINS ZLIB SSL SASL_CYRUS ZSTD CURL HDRHISTOGRAM LZ4_EXT SYSLOG SNAPPY SOCKEM SASL_SCRAM SASL_OAUTHBEARER OAUTHBEARER_OIDC, debug 0x282)
%7|1729082762.672|CONNECT|rdkafka#producer-2| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Received CONNECT op
%7|1729082762.672|STATE|rdkafka#producer-2| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Broker changed state INIT -> TRY_CONNECT
%7|1729082762.672|CONNECT|rdkafka#producer-2| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: broker in state TRY_CONNECT connecting
%7|1729082762.672|STATE|rdkafka#producer-2| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Broker changed state TRY_CONNECT -> CONNECT
%7|1729082762.672|CONNECT|rdkafka#consumer-1| [thrd:main]: Not selecting any broker for cluster connection: still suppressed for 49ms: coordinator query
%7|1729082762.699|CONNECT|rdkafka#producer-2| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Connecting to ipv4#<IP_ADDRESS>:9093 (plaintext) with socket 20
%7|1729082762.699|CONNECT|rdkafka#consumer-1| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Connecting to ipv4#<IP_ADDRESS>:9093 (plaintext) with socket 21
%7|1729082762.742|CONNECT|rdkafka#producer-2| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Connected to ipv4#<IP_ADDRESS>:9093
%7|1729082762.742|CONNECTED|rdkafka#producer-2| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Connected (#1)
%7|1729082762.742|FEATURE|rdkafka#producer-2| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Updated enabled protocol features +ApiVersion to ApiVersion
%7|1729082762.742|STATE|rdkafka#producer-2| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Broker changed state CONNECT -> APIVERSION_QUERY
%7|1729082762.742|SEND|rdkafka#producer-2| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Sent ApiVersionRequest (v3, 40 bytes @ 0, CorrId 1)
%7|1729082762.745|CONNECT|rdkafka#consumer-1| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Connected to ipv4#<IP_ADDRESS>:9093
%7|1729082762.745|CONNECTED|rdkafka#consumer-1| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Connected (#1)
%7|1729082762.745|FEATURE|rdkafka#consumer-1| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Updated enabled protocol features +ApiVersion to ApiVersion
%7|1729082762.745|STATE|rdkafka#consumer-1| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Broker changed state CONNECT -> APIVERSION_QUERY
%7|1729082762.745|SEND|rdkafka#consumer-1| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Sent ApiVersionRequest (v3, 40 bytes @ 0, CorrId 1)
%7|1729082762.786|FAIL|rdkafka#producer-2| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Disconnected while requesting ApiVersion: might be caused by incorrect security.protocol configuration (connecting to a SSL listener?) or broker version is < 0.10 (see api.version.request) (after 44ms in state APIVERSION_QUERY) (_TRANSPORT)
%6|1729082762.786|FAIL|rdkafka#producer-2| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Disconnected while requesting ApiVersion: might be caused by incorrect security.protocol configuration (connecting to a SSL listener?) or broker version is < 0.10 (see api.version.request) (after 44ms in state APIVERSION_QUERY)
%7|1729082762.786|FEATURE|rdkafka#producer-2| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Updated enabled protocol features -ApiVersion to
%7|1729082762.786|STATE|rdkafka#producer-2| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Broker changed state APIVERSION_QUERY -> DOWN
%3|1729082762.786|ERROR|rdkafka#producer-2| [thrd:kafka.example.com:9093/bootstrap]: 1/1 brokers are down
%7|1729082762.786|STATE|rdkafka#producer-2| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Broker changed state DOWN -> INIT
%7|1729082762.786|STATE|rdkafka#producer-2| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Broker changed state INIT -> TRY_CONNECT
%7|1729082762.786|RECONNECT|rdkafka#producer-2| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Delaying next reconnect by 208ms
%7|1729082762.791|FAIL|rdkafka#consumer-1| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Disconnected while requesting ApiVersion: might be caused by incorrect security.protocol configuration (connecting to a SSL listener?) or broker version is < 0.10 (see api.version.request) (after 46ms in state APIVERSION_QUERY) (_TRANSPORT)
%6|1729082762.791|FAIL|rdkafka#consumer-1| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Disconnected while requesting ApiVersion: might be caused by incorrect security.protocol configuration (connecting to a SSL listener?) or broker version is < 0.10 (see api.version.request) (after 46ms in state APIVERSION_QUERY)
%7|1729082762.791|FEATURE|rdkafka#consumer-1| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Updated enabled protocol features -ApiVersion to
%7|1729082762.791|STATE|rdkafka#consumer-1| [thrd:kafka.example.com:9093/bootstrap]: kafka.example.com:9093/bootstrap: Broker changed state APIVERSION_QUERY -> DOWN
%3|1729082762.791|ERROR|rdkafka#consumer-1| [thrd:kafka.example.com:9093/bootstrap]: 1/1 brokers are down
%7|1729082762.791|CONNECT|rdkafka#consumer-1| [thrd:kafka.example.com:9093/bootstrap]: Cluster connection already in progress: broker down

I greatly appreciate your prior response and any advice you might have.

alright, thanks for letting me know, I'll see if I can take a look later today. And thanks for sponsoring me too 😃

@corsair I managed to get it working and I put together a simple docker compose file for you to try it out. I can connect to the cluster either via CLI or using this package. Here's the repo with some basic documentation in the README

Just published a blog post on how to setup SSL for your local kafka cluster. You can read it here https://laravelkafka.com/articles/setting-up-a-kafka-cluster-with-ssl-tls-a-step-by-step-guide


after upgrading to the latest ios build I get major cpu leak

I've been using 2014 build of webrtc for ios since half a year and the cpu consumption was about 70-80% during webrtc operation. But this week I've upgraded to the latest webrtc ios build and during webrtc operation cpu usage currently starts at 70-80% and begins to rise to 120-140%. This causes major lag on the video renderer until the connection is dropped.
This seems to be because of the growing network consumption rising as high as 2.5mb/s which is much more than needed.
have u had a similar issue? the traces are here -> https://drive.google.com/file/d/0B3QWaH_ugXTzMzBwclZCVnpBOUk/view?usp=sharing

Additional info: we are using Kurento media server on the back-end

Additional info:
here are the logs from startup to a successfull webrtc connection and then to a sudden crash.
All with webrtc built in debug mode with 150% cpu load(only in debug)
glober webrtc log.txt


Configurable max body size and 10m default.

Some users in a klondike cluster may not want to be limited to 1mb requests
which is the nginx default.

👍


Split ModelConfig into ModelVersionConsumerConfig and ModelVersionProducerConfig

Describe changes
I split ModelConfig into 2 entities for better readability/usability. New objects either act as a producer of a new model version or as a consumer of an existing one. Argument lists fo both objects are reduced to show only relevant parameters to users.
[Breaking change]: from zenml.model import ModelConfig no longer works users need to migrate to
from zenml.model import ModelVersionConsumerConfig, ModelVersionProducerConfig according to their needs
Some snippets of new interfaces:
from zenml import pipeline
from zenml.enums import ModelStages
from zenml.model import ModelVersionConsumerConfig

@pipeline(
    model_config=ModelVersionConsumerConfig(
        name="my_model", version=1, save_models_to_registry=True
    )
)
def consume_version_by_number():
    ...

@pipeline(model_config=ModelVersionConsumerConfig(name="my_model"))
def consume_latest_version():
    ...

@pipeline(
    model_config=ModelVersionConsumerConfig(
        name="my_model", version="my_version"
    )
)
def consume_version_by_name():
    ...

@pipeline(
    model_config=ModelVersionConsumerConfig(
        name="my_model", version=ModelStages.PRODUCTION
    )
)
def consume_version_by_stage():
    ...

from zenml import pipeline
from zenml.enums import ModelStages
from zenml.model import ModelVersionProducerConfig

@pipeline(
    model_config=ModelVersionProducerConfig(
        name="my_model",..., version="my_version"
    )
)
def produce_version_with_given_name():
    ...

@pipeline(model_config=ModelVersionProducerConfig(name="my_model"))
def produce_version_without_explicit_name():
    ...

@pipeline(
    model_config=ModelVersionProducerConfig(
        name="my_model", delete_new_version_on_failure=False
    )
)
def produce_version_with_recovery_option_on_failure():
    ...

Pre-requisites
Please ensure you have done the following:

[x] I have read the CONTRIBUTING.md document.
[ ] If my change requires a change to docs, I have updated the documentation accordingly.
[ ] If I have added an integration, I have updated the integrations table and the corresponding website section.
[x] I have added tests to cover my changes.
[x] I have based my new branch on develop and the open PR is targeting develop. If your branch wasn't based on develop read Contribution guide on rebasing branch to develop.

Types of changes

[ ] Bug fix (non-breaking change which fixes an issue)
[x] New feature (non-breaking change which adds functionality)
[x] Breaking change (fix or feature that would cause existing functionality to change)
[ ] Other (add details above)

I canceled CI for now - it would need adjustments on the template side first to pass.


Support ConditionallySelectable for types that are not Copy

This is a feature request to support the trait ConditionallySelectable for types that are not Copy.
Motivation
I have large types (e.g. polynomials of high degree) that I'd like to be conditionally selectable.

It's unclear to me what the rationale for the Copy bound even is.
Looking at how subtle uses it, AFAICT it's only used by conditional_swap. Questions of breaking changes aside, it looks like the bound could potentially be moved to that method only.

Copy can also appear in conditional_select, like in this code that implements ConditionallySelectable for all fixed-size arrays.
If I understand correctly, Henry's stated reasoning is that allowing Clone types gives people too much leeway in their impls, allowing them to possibly do a clone() whose timing leaks bits about the data.
I'm not opposed to this reasoning. I just wonder if there's an escape hatch we could make that allows you to do this if you're very careful.

Copy can also appear in conditional_select, like in this code that implements ConditionallySelectable for all fixed-size arrays.

The Copy bound could potentially be moved to that impl, e.g.
impl<T, const N: usize> ConditionallySelectable for [T; N]
where T: ConditionallySelectable + Copy

If I understand correctly, Henry's https://github.com/dalek-cryptography/subtle/issues/56 is that allowing Clone types gives people too much leeway in their impls, allowing them to possibly do a clone() whose timing leaks bits about the data.

That is a reasonable concern. Copy should always be constant-time, whereas Clone admits a sharp edge.
However, I do also sympathize with the concern that it may be unwise to impl Copy on very large types. Personally I tend to use the size of an x86 cache line (64-bytes) as my personal rule of thumb for a boundary after which one should consider if types are too large to impl Copy.

Agreed. A not-great idea: make a trait SafeConditionallySelectable: Copy and then make trait ConditionallySelectable unconstrainted. That way people can still write generics relying on ConditionallySelectable. And it'd be the case that SafeConditionallySelectable is always ConditionallySelectable. Downsides: this changes the meanings of pre-existing terms, doesn't remove the footgun, and requires a major version release.

Another option besides splitting the ConditionallySelectable trait would be adding a marker trait like:
pub trait CtClone: Clone {}

impl<T: Copy> CtClone for T {}

...and then changing ConditionallySelectable to be bound on CtClone.
CtClone would be a marker trait which means "I assert my Clone impl is constant-time".

Oh, that's pretty nice. I'd be fine with that.

I think a similar argument applies to CtOption::map (and and_then, or_else).
The code has a comment:
    /// This operates in constant time, because the provided closure
    /// is always called.

which is obviously only true if the called closure runs in constant-time but there is nothing enforcing that.

A big drawback of the Copy bound is it makes it impossible to implement ConditionallySelectable for heap allocated types, e.g. a heap-backed big integer.

However, changing it seems like a breaking change due to removing the supertrait bound on Copy.
Currently anything that's ConditionallySelectable can be assumed to be Copy via that supertrait bound. Removing it might require changing bounds in existing code to ConditionallySelectable + Copy.
It's the kind of thing that makes me wish we had something like Crater to see if it would break any real-world code. I think there's a real chance it might.

It seems like the only way to support non-copy types would be to define a new trait and use a blanket impl for backwards compatibility. Something like:
pub trait ConstantTimeClone: Clone {}

impl<T: Copy> ConstantTimeClone for T {}

pub trait ConstantTimeSelect: ConstantTimeClone {
    fn ct_select(a: &Self, b: &Self, choice: Choice) -> Self;

    [...]
}

impl<T: ConditionallySelectable> ConstantTimeSelect for T {
    [...]
}

...then ConditionallySelectable could potentially be deprecated.

I've been attempting to make use of subtle with heap-allocated BoxedInteger/BoxedResidue types, with the goal of using those to implement the rsa and dsa crates.
I can attest the Copy bound becomes a major impediment in these cases, because without ConditionallySelectable the CtOption combinators don't work, which IMO is one of subtle's best features for writing constant-time code.
I can try to open a PR with what I've outlined above, which in theory should be a backwards compatible change as current ConditionallySelectable users can leverage the new trait via the blanket impl (though it should likely be deprecated).
CtOption will need to be changed to use the new trait, which again shouldn't be breaking due to the blanket impl. #63 will also likely need to be addressed for my use cases to work, as we need to ensure fixed-but-dynamic precisions are consistent throughout, and Default will return a value with a number of limbs smaller than e.g. an RSA modulus.

I went ahead and impl'd my aforementioned ConstantTimeSelect trait idea here:
https://github.com/dalek-cryptography/subtle/pull/118


Make casting negative numbers more predictable.

Brief Description
Casting between different signed types can have unintuitive (incorrect?) results. Some examples of how to do this correctly would be welcomed.
Observed Behaviour
When casting negative Q1.14 values to Q3.12, the results are very unexpected. The fractional bit of the number seems to be within ~1 of the true value, but the integer part can be quite a bit off. What should be -1 ends up being 3. Or positive 2 instead of -2.
Expected Behaviour
Casting a fixed point number from one format to another should maintain a roughly equivalent value.
Source Code
#include <FixedPoints.h>

void setup() {
	Serial.begin(115200);

	SFixed<1,14> a = -0.05;
	SFixed<3, 12> b = static_cast<SFixed<3, 12>>(a);
	SFixed<3, 12> c = -0.05;
	Serial.print("Initial Q1.14 value: "); Serial.println((float)a);
	Serial.print("Value cast to Q3.12: "); Serial.println((float)b);

	Serial.println();

	Serial.print("Internal representation of Q1.14: "); Serial.println(a.getInternal(), BIN);
	Serial.print("Expected representation of Q3.12: "); Serial.println(c.getInternal(), BIN);
	Serial.print("Actual representation of Q3.12: "); Serial.println(b.getInternal(), BIN);

	Serial.println();

	Serial.print("Q1.14 integer bit: "); Serial.println(a.getInteger());
	Serial.print("Q1.14 fraction bit: "); Serial.println(a.getFraction());
	Serial.print("Wonky Q3.12 integer bit: "); Serial.println(b.getInteger());
	Serial.print("Wonky Q3.12 fraction bit: "); Serial.println(b.getFraction());
	Serial.print("Correct Q3.12 integer bit: "); Serial.println(c.getInteger());
	Serial.print("Correct Q3.12 fraction bit: "); Serial.println(c.getFraction());
}

void loop() {}

Output:
Initial Q1.14 value: -0.05
Value cast to Q3.12: 3.95

Internal representation of Q1.14:<PHONE_NUMBER>1111111111110011001101
Expected representation of Q3.12:<PHONE_NUMBER>1111111111111100110100
Actual representation of Q3.12:<PHONE_NUMBER>0011

Q1.14 integer bit: -1
Q1.14 fraction bit: 15565
Wonky Q3.12 integer bit: 3
Wonky Q3.12 fraction bit: 3891
Correct Q3.12 integer bit: -1
Correct Q3.12 fraction bit: 3892

Extra Information

Target Board: Arduino Uno (R3?)
Compiler Version: avr-g++ 7.3.0
Arduino IDE Version: 1.8.10
OS:  Debian Sid

To cut a long story short, it's because internally the conversion is using unsigned shift operations (i.e. 'logical' shifting is being forced rather than 'arithmetic' shifting).
I can't remember whether this was intentional or not, but it quite possibly was because technically signed right shift is 'implementation defined' prior to C++20, whilst unsigned shifting is well defined.
The fix would be fairly simple, it would just be a matter of removing a few casts and consequently some unneeded local type aliases.
However, even with that the result won't be quite perfect because of the inherant loss of precision involved.

A reminder for myself:
https://gist.github.com/Pharap/04e6fff6fe754641048faabe3ecb4af5


where flag

my team solved thsi already but idk where the falg is i want to solve pls help?
10 solves Large Numbers - 70
Algorithms - Solved
3 solves Tetraodontidae - 70
Forensics/Cryptography - Solved
8 solves Tic Tac Toe - 75
Exploitation - Solved
7 solves TT - 75
Forensics - Solved
4 solves Not SVN - 75
Forensics - Unsolved
Solve
Hint
Review

I found this zip file, and the flag is supposed to be in it... but where is it?
File
10 solves Easy Reverse Engineering - 75
Reverse Engineering - Solved
9 solves Snake - 77
Forensics - Solved
5 solves Login Attempts - 80
Exploitation - Unsolved
Solve
Hint
Review

Attempt to log in!
The computer has been opened to the internet at stuyctf.me:22345
5 solves Totally Not Morse - 85
Cryptography - Solved
4 solves Inversion - 90
Algorithms/Cryptography - Unsolved
Solve
Hint
Review

You intercepted a package.
The note inside seems to be about the encryption, but the radius is smeared!
However, you can still make out that the radius is a two digit number, but what could that mean?
7 solves Format Overflow - 90
Exploitation - Solved
1 solve What Cipher - 95
Cryptography - Unsolved
Solve
Hint
Review

Help! My friend gave me this file and he told me the encryption method and password so I could read it when I got home, but I forgot them both! I still remember that the password was unusually short, two lowercase letters to be exact, but I can't recall which. Could you recover the message for me?
3 solves Mystery File - 100
Algorithms/Cryptography - Unsolved
Solve
Hint
Review

Your friend sent you these files and said that the key is<PHONE_NUMBER>14...
What could that mean?
This package is yours!
4 solves Impossible - 100
Reverse Engineering - Unsolved
Solve
Hint
Review

This is impossible.
Binary
Source Code
1 solve Get Me In - 110
Exploitation - Unsolved
Solve
Hint
Review

We found this secret site, but we can't seem to get in to get the flag! The creator has set up some barriers to prevent us from hacking it. Surely you're better than him!
7 solves Rock Paper Scissors - 120
Algorithms/Reverse Engineering - Solved
2 solves Large Inputs - 140

lable


Can't collect Dubbo calls in pinpoint agent

Prerequisites
Please check the FAQ, and search existing issues for similar questions before creating a new issue.YOU MAY DELETE THIS PREREQUISITES SECTION.

[x] I have checked the FAQ, and issues and found no answer.

What version of pinpoint are you using?
v1.7.1
Describe your problem**
I can see normal http calls for example /a/b, however dubbo calls aren't displayed in pinpoint web, it looks dubbo calls data isn't collected
What have you done?
Steps you have taken to trigger the problem, for example:

I updated the configuration in pinpoint.config, set below properties, and also updated sampling rate as 1, and updated collector ip.
profiler.applicationservertype=DUBBO_PROVIDER
profiler.dubbo.bootstrap.main=org.apache.dubbo.container.Main

Screenshots
Logs
Thre's no any exception in logs
Additional context
Add any other context about the problem here, such as affected library for agents, how your collector/web/hbase is set up if applicable.
dubbo version is 2.7

@linxu163
I made a sample for testing the dubbo plugin.
In pinpoint-2.3.0-SNAPSHOT version, it works normally.
Please check how it works in pinpoint-1.7.1 version.

@linxu163
I made a sample for testing the dubbo plugin. Dubbo Plugin Test Web
In pinpoint-2.3.0-SNAPSHOT version, it works normally.
Please check how it works in pinpoint-1.7.1 version.

Thank you so much @jaehong-kim! I installed pinpoint 2.2.2, it works well now. I have another question, is there any way to see more details about the gap time in below screenshot. I want to see the deeper call tree from "invoke" to "Apache Dubbo Provider Process", and I'm wondering why it costs 64ms, for most requests, the gap is much less.


Fix failing quantityAvailable calculations for warehouse withous shipping zones

The standard warehouses (with disabled c&c option) shouldn't be taken into consideration during quanatityAvailable calculation.
Port of #10662

Impact

[ ] New migrations
[ ] New/Updated API fields or mutations
[ ] Deprecated API fields or mutations
[ ] Removed API types, fields, or mutations
[ ] Documentation needs to be updated

Pull Request Checklist

[ ] Privileged queries and mutations are guarded by proper permission checks
[ ] Database queries are optimized and the number of queries is constant
[ ] Database migration files are up to date
[ ] The changes are tested
[ ] GraphQL schema and type definitions are up to date
[ ] Changes are mentioned in the changelog

Task linked: SALEOR-8033 Not cc warehouse without shipping zone raise an error during quantity available check for variant


Postgis Plugin error when deleting an analysis with a Pop-Up enabled

@xavijam, can you advise if this is by design?
Context
Error message when deleting an analysis from a layer that has POP-UP enabled.
Steps to Reproduce

Create a map and run any analysis
Enable a click or hover pop-up column for the same layer (Do not use any analysis result columns)
Delete the analysis...

 For example:
Nearest Food to Metro: Postgis Plugin: ERROR: column "cuisine" does not existLINE 1: ...cator",0.001),0.001,true),3) AS geom,"cartodb_id","cuisine",... ^in executeQuery Full sql was: 'SELECT ST_AsTWKB(ST_Simplify(ST_RemoveRepeatedPoints("the_geom_webmercator",0.001),0.001,true),3) AS geom,"cartodb_id","cuisine","name" FROM (SELECT * FROM lineas_metro_madrid_3) as cdbq WHERE "the_geom_webmercator" && ST_SetSRID('BOX3D(-20037508.3 20037508.29613578,-20037508.29613578 20037508.3)'::box3d, 3857)

Workaround: If I change the POP-UP to NONE, the error goes away.
Expected result
Perhaps there is a way to avoid seeing such an error, or at least soften the message? Or is this by design?
Browser and version
Chrome, Version 58.0.3029.110 (64-bit)

@csobier can you share the .carto of that map to test it?

There should be an error included with this .carto file: SF Trees Import (on 2017-11-02 at 12.35.30).carto.zip

This is an error that happens also if you apply a CartoCSS code using one of the columns generated by the analysis. If you remove it, the map fails. That's something not easy to fix, and it needs to think how to proceed, aka not for response team.

Good to know. Another one to the bucket.


Route http.Handler on specific HTTP method?

Hey,
I love chi and how it works with regular the regular http.HandlerFunc function signature, however I'd love to be able to return error from my HTTP handlers.
Since the Get/Post/... methods on the router require the rather limiting http.HandlerFunc function and the generic Handle method (which does accept the http.Handler interface)  only binds to all HTTP methods, I can't seem to figure out how to do this though.
Maybe I'm overseeing something, but wouldn't chi be a whole lot more flexible if the HTTP-method routing methods accepted a http.Handler interface instead, just like the middleware?
// HTTP-method routing along `pattern`
Connect(pattern string, h http.Handler)
Delete(pattern string, h http.Handler)
...

Here's what I'm trying to achieve, basically the same as described here.
type Handler func(w http.ResponseWriter, r *http.Request) error

func (h Handler) ServeHTTP(w http.ResponseWriter, r *http.Request) {
	if err := h(w, r); err != nil {
		// handle returned error here.
	}
}

func main() {
   r := chi.NewRouter()
   r.Get("/foo", Handler(fooHandler))
}

After  searching through the issue list I see this is brought up more often, so this is probably a duplicate of #79 and #94.

To answer my own question, with chi's current interface it seems that we can do this.
type Handler func(w http.ResponseWriter, r *http.Request) error

func (h Handler) ServeHTTP(w http.ResponseWriter, r *http.Request) {
	if err := h(w, r); err != nil {
		// handle returned error here.
	}
}

func main() {
   r := chi.NewRouter()
   r.Get("/foo", http.HandlerFunc(Handler(fooHandler).ServeHTTP))
}

I'd like to echo the sentiments in the other two issues about this though, it would make a lot of sense to use an interface instead of func in the router method signatures. Fingers crossed that will make it into a future version of chi! :crossed_fingers:

hey @dannyvankooten I really appreciate your gentle suggestions, and I finally see the point everyone is requesting. I'll see what I can come up with the support the pattern you described above.

That is great news @pkieltyka! I've slightly edited my initial message in this issue as I mixed up "function" and "interface" a few times.

solved by v3 release 02e6bbdfd14640d8c1beb15ec3a38140400fb5c2 - specifically, check out the new r.Method() and r.MethodFunc() routing methods
See complete CHANGELOG for v3: https://github.com/go-chi/chi/blob/master/CHANGELOG.md


Method will fail on L2

calls to Election#getCurrentValidatorSigners must be replaced with  EpochManager#getElectedSigners
used in fetchValidators.ts

relates to https://github.com/celo-org/developer-tooling/issues/458

@aaronmgdr Rather than invest time making updates here, I'm inclined to instead block off the Stake, Govern, and Exchange pages (exchange is broken already since the Mento migration).

sounds good to me


Add listPrices rpc

What kind of PR is this?:

/kind feature
What this PR does / why we need it:
Add listPrices rpc
Which issue(s) does this PR fixes?:

Fixes part of #202
Additional comments?:

@jingyi2811 conflicts


remove ppc64le build and update action versions

@superbobry
when is this be merged?
this can save me a lot of build time (after this upload to pypi)
thanks


Having problems on training the model on Mac

I could run the txt2img successfully on my MacBook with M1 chip.
However, when I ran main.py I met problems like this:
RuntimeError: Placeholder storage has not been allocated on MPS device!
Also, I met a message like this: [W NNPACK.cpp:53] Could not initialize NNPACK! Reason: Unsupported hardware.
There seems to be no instructions on model training on Mac.I wonder if there is a good solution.Thank you!

I wonder how did manage to run this repo on mac? Would you mind to share step by step instruction please?


Add support for localized route paths

Description
The framework should let users easily configure localized routes. There are two types of localized routes to consider:

localized routes whose paths are translated (eg. /cars and /voitures)
localized routes whose paths are translated and that are prefixed by the current locale (eg. /en/cars and /fr/voitures)

In order to let users define such routes, let's add the ability to leverage a #localized block when defining routes. For example:
Marten.routes.draw do
  localized(prefix: true) do
    path "routes.article_list", ArticleListHandler, name: "article_list"
    path "routes.article_detail", ArticleDetailHandler, name: "article_detail"
    path "routes.my_app", MyApp::ROUTES, name: "my_app"
  end
end

This method should accept the following arguments:

prefix - whether or not a locale prefix (eg. /en/ or /fr/ depending on the activated locales) should be used for the generated routes (should default to false)
prefix_default_locale - whether or not the default locale should be prefixed when prefix: true is used

Using #localized would instruct the routing map that the wrapped path must be localized and that their actual "paths" must be treated as localization paths. For example, the associated translations could look like this:
en:
  routes:
    article_list: /articles
    article_detail: /articles/<pk:int>
    my_app: /my-app

When generating the full URL of localized routes, the associated translations should be used in order to generate the localized URL and (optionally) prefix it with the current locale.

@ellmetha I've started some work on this. I needed a few clarifications.

Accept-Language vs localized route - when Accept-Language is fr but localized route is /de/post/1, what will the content be translated into? My guess is to follow the de but just in case my assumptions are wrong.

@kates Thanks for looking into that! To answer your question, the language extracted from the route path should always have precedence.


Delete not cascading as expected when some navigation properties are null

Thank you for a very useful library!
I think there is a bug in the CascadeWalker on line 77 and 98 - should it perhaps be continue instead of return when there is no relationship? This way the other navigations are cascaded/walked through, even though one of the navigation values are null.
The principalNavs are returned in alphabetical order, and if the entity you're soft deleting (cascading) has a null value in some navigation property alphabetically prior to another that is in use (and should be soft deleted), the walker will prematurely be returned and the related entity with a value will not be soft deleted.

Hi @lena-osterhus,
That sounds bad and I 'll have a look at it.
I assume you found it when using the library in an application and it didn't delete one of the relationships - correct? It would be useful if you add the entity classes that are linked together that failed. If it too complex or confidential, then simplified version of the classes would be useful.

That is correct. Here are simplified versions of the classes:
public class Company : ICascadeSoftDelete
{
    public Company(string name)
    {
        Name = name;
    }
    public int Id { get; set; }
    public string Name { get; set; }
    public ICollection<Address>? Addresses { get; set; }
    public ICollection<ExternalId>? ExternalIds { get; set; }
    public byte SoftDeleteLevel { get; set; }
}

public class Address : ICascadeSoftDelete
{
    public int Id { get; set; }
    public string? Street { get; init; }
    public string? City { get; init; }
    public int? CompanyId { get; set; }
    public Company? Company { get; init; }
    public byte SoftDeleteLevel { get; set; }
}

public class ExternalId : ICascadeSoftDelete
{
    public ExternalId(string context, string value)
    {
        Context = context;
        Value = value;
    }
    public int Id { get; set; }
    public string Context { get; init; } // The system the value relates to
    public string Value { get; set; }
    public int? CompanyId { get; set; }
    public Company? Company { get; init; }
    public byte SoftDeleteLevel { get; set; }
}

OnModelCreating contains this configuration:
        modelBuilder.Entity<Address>()
            .HasOne(a => a.Company)
            .WithMany(c => c.Addresses)
            .HasForeignKey(a => a.CompanyId)
            .OnDelete(DeleteBehavior.ClientCascade)
            .HasConstraintName("FK_Addresses_Companies");

        modelBuilder.Entity<ExternalId>()
            .HasOne(e => e.Company)
            .WithMany(c => c.ExternalIds)
            .HasForeignKey(e => e.CompanyId)
            .OnDelete(DeleteBehavior.ClientCascade)
            .HasConstraintName("FK_ExternalId_Company");

In my case I wrote a test where I add a Company to the database with no Address and one ExternalId, and then try to cascade soft delete the Company. I expected both Company and the ExternalId to be soft deleted, but only the Company was.

Hi @lena-osterhus,
Sorry for the delay on looking at this but I was working on something. Anyway I have created a test and it worked correctly, i.e. the cascade delete set the Company.SoftDeleteLevel to 1 and the ExternalId.SoftDeleteLevel to 2.
I did look at line 77 and 98 which suggested be changed, but they are looking for further navigational entities from the current entity.

Thank you for taking a look, @JonPSmith!
You are of course right, it works correctly with the classes I supplied you with. It seems I lost the essence of the problem in the simplification. I see now that the problem does not present when the first navigation is a collection. If, however, it is a "NavigationSingleton" the CascadeWalker will return without walking to the next navigation.
Could you please try your test with the following changes to the Company class:
        public class Company : ICascadeSoftDelete
        {
            public int Id { get; set; }
            public string Name { get; set; }
            public Address? Address { get; set; }
            public ICollection<ExternalId>? ExternalIds { get; set; }
            public byte SoftDeleteLevel { get; set; }
        }

And OnModelCreating:
            protected override void OnModelCreating(ModelBuilder modelBuilder)
            {
                modelBuilder.Entity<Address>()
                    .HasOne(c => c.Company)
                    .WithOne(p => p.Address)
                    .HasForeignKey<Address>(a => a.CompanyId)
                    .OnDelete(DeleteBehavior.ClientCascade)
                    .HasConstraintName("FK_Addresses_Companies");

                modelBuilder.Entity<ExternalId>()
                    .HasOne(e => e.Company)
                    .WithMany(c => c.ExternalIds)
                    .HasForeignKey(e => e.CompanyId)
                    .OnDelete(DeleteBehavior.ClientCascade)
                    .HasConstraintName("FK_ExternalId_Company");
            }

Ah, that makes more sense. I will have a look at that.

Version 2.0.1 contains a fix for the cascade soft delete problem reported in this issue.
Thanks @lena-osterhus for reporting this.


structure

Subject
All of members
Proposal Detail
I think in hashicorp's memberlist struct Memberlist do too much things, so I think it is better to separate responsibility. My suggestion is.. I want to separate receiving message part and sending message part. So the structure is

Spaceship (this is Memberlist in hashicorp, and temporarily named it :), and network as galaxy..)

MessageTransmitter
MessageReceiver
...

@junbeomlee @leesd556 @hihiboss


style: naming examples

There was a warning in compiling a contract when adding pop api dependency. This should resolve it.
I also updated the naming, which we can use to move forward with the examples.
This is just naming things, examples need a lot more work.

pop-api is included in the path, so having it in the contract names seems redundant. Simpler to just remove the pop_api_ prefixes imo.

Closed by #86


Build Error on Ubuntu 18.04

Problem

Build Error on Ubuntu 18.04
I think this  commit( 5ca7308145faf5100592627024c30c93d0d7498a)) cause of Build Error
When I roll back before the commit, I have checked build successful.

Build Error Log is below
Proposed Solution
ninja -C out/debug ninja: Entering directory out/debug'
[21/73] c++ obj/third_party/connectedhomeip/src/platform/Linux/bluez/libDeviceLayer.MainLoop.cpp.o
FAILED: obj/third_party/connectedhomeip/src/platform/Linux/bluez/libDeviceLayer.MainLoop.cpp.o
g++ -MMD -MF obj/third_party/connectedhomeip/src/platform/Linux/bluez/libDeviceLayer.MainLoop.cpp.o.d -Wconversion -O0 -g2 -fno-common -ffunction-sections -fdata-sections -fno-exceptions -fno-unwind-tables -fno-asynchronous-unwind-tables -fPIC -Wall -Wextra -Wshadow -Wunreachable-code -Werror -Wno-deprecated-declarations -Wno-unknown-warning-option -Wno-missing-field-initializers -Wno-unused-parameter -Wno-psabi -Wno-cast-function-type -fdiagnostics-color -fno-strict-aliasing -D_REENTRANT -isystem../../third_party/connectedhomeip/third_party/ot-br-posix/repo/src -isystem../../third_party/connectedhomeip/third_party/ot-br-posix/repo/include -I/usr/include/dbus-1.0 -I/usr/lib/x86_64-linux-gnu/dbus-1.0/include -I/usr/include/gio-unix-2.0/ -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include -std=gnu++14 -fno-rtti -Wnon-virtual-dtor -DCHIP_HAVE_CONFIG_H=1 -DCHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE=true -DLWIP_IPV4=1 -DLWIP_IPV6=1 -DLWIP_API=1 -DLWIP_ETHERNET=1 -DLWIP_SLIP=0 -DLWIP_6LOWPAN=1 -DLWIP_PPP=1 -I../../third_party/connectedhomeip/src/include -I../../third_party/connectedhomeip/src -Igen/include -I../../third_party/connectedhomeip/config/standalone -I../../third_party/connectedhomeip/src/lib -I../../third_party/connectedhomeip/third_party/nlassert/repo/include -I../../third_party/connectedhomeip/third_party/nlio/repo/include -I../../third_party/connectedhomeip/src/lwip/standalone -I../../third_party/connectedhomeip/third_party/lwip/repo/lwip/src/include -I../../third_party/connectedhomeip/src/lwip/include -I../../third_party/connectedhomeip/src/setup_payload -Igen -Igen -I../../third_party/connectedhomeip/third_party/inipp/repo/inipp -c ../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.cpp -o obj/third_party/connectedhomeip/src/platform/Linux/bluez/libDeviceLayer.MainLoop.cpp.o
In file included from ../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.cpp:17:0:
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.h: In instantiation of ‘bool chip::DeviceLayer::Internal::MainLoop::Schedule(int ()(T), T*) [with T = chip::DeviceLayer::Internal::{anonymous}::CallbackIndirection]’:
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.cpp:171:63:   required from here
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.h:56:46: error: ‘G_SOURCE_FUNC’ was not declared in this scope
return RunOnBluezThread(G_SOURCE_FUNC(callback), value);
~~~~~^~
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.h:56:46: note: suggested alternative: ‘G_STRFUNC’
return RunOnBluezThread(G_SOURCE_FUNC(callback), value);
~~~~~^~
G_STRFUNC
cc1plus: error: unrecognized command line option ‘-Wno-cast-function-type’ [-Werror]
cc1plus: error: unrecognized command line option ‘-Wno-unknown-warning-option’ [-Werror]
cc1plus: all warnings being treated as errors
[23/73] c++ obj/third_party/connectedhomeip/src/platform/Linux/bluez/libDeviceLayer.Helper.cpp.o
FAILED: obj/third_party/connectedhomeip/src/platform/Linux/bluez/libDeviceLayer.Helper.cpp.o
g++ -MMD -MF obj/third_party/connectedhomeip/src/platform/Linux/bluez/libDeviceLayer.Helper.cpp.o.d -Wconversion -O0 -g2 -fno-common -ffunction-sections -fdata-sections -fno-exceptions -fno-unwind-tables -fno-asynchronous-unwind-tables -fPIC -Wall -Wextra -Wshadow -Wunreachable-code -Werror -Wno-deprecated-declarations -Wno-unknown-warning-option -Wno-missing-field-initializers -Wno-unused-parameter -Wno-psabi -Wno-cast-function-type -fdiagnostics-color -fno-strict-aliasing -D_REENTRANT -isystem../../third_party/connectedhomeip/third_party/ot-br-posix/repo/src -isystem../../third_party/connectedhomeip/third_party/ot-br-posix/repo/include -I/usr/include/dbus-1.0 -I/usr/lib/x86_64-linux-gnu/dbus-1.0/include -I/usr/include/gio-unix-2.0/ -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include -std=gnu++14 -fno-rtti -Wnon-virtual-dtor -DCHIP_HAVE_CONFIG_H=1 -DCHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE=true -DLWIP_IPV4=1 -DLWIP_IPV6=1 -DLWIP_API=1 -DLWIP_ETHERNET=1 -DLWIP_SLIP=0 -DLWIP_6LOWPAN=1 -DLWIP_PPP=1 -I../../third_party/connectedhomeip/src/include -I../../third_party/connectedhomeip/src -Igen/include -I../../third_party/connectedhomeip/config/standalone -I../../third_party/connectedhomeip/src/lib -I../../third_party/connectedhomeip/third_party/nlassert/repo/include -I../../third_party/connectedhomeip/third_party/nlio/repo/include -I../../third_party/connectedhomeip/src/lwip/standalone -I../../third_party/connectedhomeip/third_party/lwip/repo/lwip/src/include -I../../third_party/connectedhomeip/src/lwip/include -I../../third_party/connectedhomeip/src/setup_payload -Igen -Igen -I../../third_party/connectedhomeip/third_party/inipp/repo/inipp -c ../../third_party/connectedhomeip/src/platform/Linux/bluez/Helper.cpp -o obj/third_party/connectedhomeip/src/platform/Linux/bluez/libDeviceLayer.Helper.cpp.o
In file included from ../../third_party/connectedhomeip/src/platform/Linux/bluez/Helper.cpp:76:0:
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.h: In instantiation of ‘bool chip::DeviceLayer::Internal::MainLoop::SetCleanupFunction(int ()(T), T*) [with T = chip::DeviceLayer::Internal::BluezEndpoint]’:
../../third_party/connectedhomeip/src/platform/Linux/bluez/Helper.cpp:1347:79:   required from here
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.h:83:41: error: ‘G_SOURCE_FUNC’ was not declared in this scope
mCleanup         = G_SOURCE_FUNC(callback);
~~~~~^~
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.h:83:41: note: suggested alternative: ‘G_STRFUNC’
mCleanup         = G_SOURCE_FUNC(callback);
~~~~~^~
G_STRFUNC
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.h: In instantiation of ‘bool chip::DeviceLayer::Internal::MainLoop::Schedule(int ()(T), T*) [with T = chip::DeviceLayer::Internal::ConnectionDataBundle]’:
../../third_party/connectedhomeip/src/platform/Linux/bluez/Helper.cpp:1420:101:   required from here
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.h:56:46: error: ‘G_SOURCE_FUNC’ was not declared in this scope
return RunOnBluezThread(G_SOURCE_FUNC(callback), value);
~~~~~^~
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.h:56:46: note: suggested alternative: ‘G_STRFUNC’
return RunOnBluezThread(G_SOURCE_FUNC(callback), value);
~~~~~^~
G_STRFUNC
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.h: In instantiation of ‘bool chip::DeviceLayer::Internal::MainLoop::Schedule(int ()(T), T*) [with T = chip::DeviceLayer::Internal::BluezEndpoint]’:
../../third_party/connectedhomeip/src/platform/Linux/bluez/Helper.cpp:1460:65:   required from here
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.h:56:46: error: ‘G_SOURCE_FUNC’ was not declared in this scope
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.h:56:46: note: suggested alternative: ‘G_STRFUNC’
return RunOnBluezThread(G_SOURCE_FUNC(callback), value);
~~~~~^~
G_STRFUNC
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.h: In instantiation of ‘bool chip::DeviceLayer::Internal::MainLoop::ScheduleAndWait(int ()(T), T*) [with T = chip::DeviceLayer::Internal::BluezEndpoint]’:
../../third_party/connectedhomeip/src/platform/Linux/bluez/Helper.cpp:1554:80:   required from here
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.h:63:53: error: ‘G_SOURCE_FUNC’ was not declared in this scope
return RunOnBluezThreadAndWait(G_SOURCE_FUNC(callback), value);
~~~~~^~
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.h:63:53: note: suggested alternative: ‘G_STRFUNC’
return RunOnBluezThreadAndWait(G_SOURCE_FUNC(callback), value);
~~~~~^~
G_STRFUNC
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.h: In instantiation of ‘bool chip::DeviceLayer::Internal::MainLoop::Schedule(int ()(T), T*) [with T = chip::DeviceLayer::Internal::BluezConnection]’:
../../third_party/connectedhomeip/src/platform/Linux/bluez/Helper.cpp:1672:109:   required from here
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.h:56:46: error: ‘G_SOURCE_FUNC’ was not declared in this scope
return RunOnBluezThread(G_SOURCE_FUNC(callback), value);
~~~~~^~
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.h:56:46: note: suggested alternative: ‘G_STRFUNC’
return RunOnBluezThread(G_SOURCE_FUNC(callback), value);
~~~~~^~
G_STRFUNC
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.h: In instantiation of ‘bool chip::DeviceLayer::Internal::MainLoop::Schedule(int ()(T), T*) [with T = _BluezDevice1]’:
../../third_party/connectedhomeip/src/platform/Linux/bluez/Helper.cpp:1742:67:   required from here
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.h:56:46: error: ‘G_SOURCE_FUNC’ was not declared in this scope
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.h:56:46: note: suggested alternative: ‘G_STRFUNC’
return RunOnBluezThread(G_SOURCE_FUNC(callback), value);
~~~~~^~
G_STRFUNC
cc1plus: error: unrecognized command line option ‘-Wno-cast-function-type’ [-Werror]
cc1plus: error: unrecognized command line option ‘-Wno-unknown-warning-option’ [-Werror]
cc1plus: all warnings being treated as errors
[24/73] c++ obj/third_party/connectedhomeip/src/platform/Linux/bluez/libDeviceLayer.ChipDeviceScanner.cpp.o
FAILED: obj/third_party/connectedhomeip/src/platform/Linux/bluez/libDeviceLayer.ChipDeviceScanner.cpp.o
g++ -MMD -MF obj/third_party/connectedhomeip/src/platform/Linux/bluez/libDeviceLayer.ChipDeviceScanner.cpp.o.d -Wconversion -O0 -g2 -fno-common -ffunction-sections -fdata-sections -fno-exceptions -fno-unwind-tables -fno-asynchronous-unwind-tables -fPIC -Wall -Wextra -Wshadow -Wunreachable-code -Werror -Wno-deprecated-declarations -Wno-unknown-warning-option -Wno-missing-field-initializers -Wno-unused-parameter -Wno-psabi -Wno-cast-function-type -fdiagnostics-color -fno-strict-aliasing -D_REENTRANT -isystem../../third_party/connectedhomeip/third_party/ot-br-posix/repo/src -isystem../../third_party/connectedhomeip/third_party/ot-br-posix/repo/include -I/usr/include/dbus-1.0 -I/usr/lib/x86_64-linux-gnu/dbus-1.0/include -I/usr/include/gio-unix-2.0/ -I/usr/include/glib-2.0 -I/usr/lib/x86_64-linux-gnu/glib-2.0/include -std=gnu++14 -fno-rtti -Wnon-virtual-dtor -DCHIP_HAVE_CONFIG_H=1 -DCHIP_DEVICE_CONFIG_ENABLE_CHIPOBLE=true -DLWIP_IPV4=1 -DLWIP_IPV6=1 -DLWIP_API=1 -DLWIP_ETHERNET=1 -DLWIP_SLIP=0 -DLWIP_6LOWPAN=1 -DLWIP_PPP=1 -I../../third_party/connectedhomeip/src/include -I../../third_party/connectedhomeip/src -Igen/include -I../../third_party/connectedhomeip/config/standalone -I../../third_party/connectedhomeip/src/lib -I../../third_party/connectedhomeip/third_party/nlassert/repo/include -I../../third_party/connectedhomeip/third_party/nlio/repo/include -I../../third_party/connectedhomeip/src/lwip/standalone -I../../third_party/connectedhomeip/third_party/lwip/repo/lwip/src/include -I../../third_party/connectedhomeip/src/lwip/include -I../../third_party/connectedhomeip/src/setup_payload -Igen -Igen -I../../third_party/connectedhomeip/third_party/inipp/repo/inipp -c ../../third_party/connectedhomeip/src/platform/Linux/bluez/ChipDeviceScanner.cpp -o obj/third_party/connectedhomeip/src/platform/Linux/bluez/libDeviceLayer.ChipDeviceScanner.cpp.o
In file included from ../../third_party/connectedhomeip/src/platform/Linux/bluez/ChipDeviceScanner.cpp:23:0:
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.h: In instantiation of ‘bool chip::DeviceLayer::Internal::MainLoop::Schedule(int ()(T), T*) [with T = chip::DeviceLayer::Internal::ChipDeviceScanner]’:
../../third_party/connectedhomeip/src/platform/Linux/bluez/ChipDeviceScanner.cpp:128:63:   required from here
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.h:56:46: error: ‘G_SOURCE_FUNC’ was not declared in this scope
return RunOnBluezThread(G_SOURCE_FUNC(callback), value);
~~~~~^~
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.h:56:46: note: suggested alternative: ‘G_STRFUNC’
return RunOnBluezThread(G_SOURCE_FUNC(callback), value);
~~~~~^~
G_STRFUNC
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.h: In instantiation of ‘bool chip::DeviceLayer::Internal::MainLoop::ScheduleAndWait(int ()(T), T*) [with T = chip::DeviceLayer::Internal::ChipDeviceScanner]’:
../../third_party/connectedhomeip/src/platform/Linux/bluez/ChipDeviceScanner.cpp:171:69:   required from here
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.h:63:53: error: ‘G_SOURCE_FUNC’ was not declared in this scope
return RunOnBluezThreadAndWait(G_SOURCE_FUNC(callback), value);
~~~~~^~
../../third_party/connectedhomeip/src/platform/Linux/bluez/MainLoop.h:63:53: note: suggested alternative: ‘G_STRFUNC’
return RunOnBluezThreadAndWait(G_SOURCE_FUNC(callback), value);
~~~~~^~
G_STRFUNC
cc1plus: error: unrecognized command line option ‘-Wno-cast-function-type’ [-Werror]
cc1plus: error: unrecognized command line option ‘-Wno-unknown-warning-option’ [-Werror]
cc1plus: all warnings being treated as errors
[30/73] c++ obj/third_party/connectedhomeip/src/transport/libTransportLayer.NetworkProvisioning.cpp.o
ninja: build stopped: subcommand failed.`

To support 'G_SOURCE_FUNC', Ubuntu glib version must be since version 2.58 but 18.04 has glib version 2.56.4.
To fix this issue, You must be upgrade ubuntu 20.04 upper or upgrade glib but many feedback don't recommend upgrade glib version. because glib is strong coupling with OS.

I have checked build success on Ubuntu 20.04


Support extra contents in  tag

Add a template to includes/ to let users override it and add custom tags such as meta, link, script, and so on.

4733da931210e827f687018f81c86b1f057b8c49


Higher concurrency limit for gunicorn

Gunicorn returns 503 instead of 429 when concurrency exceeds the limit, before adding rate limiting just increase the concurrency and see if that's good enough

is there any downside to increasing concurrency by such a large amount?

process might OOM, but there's an easy fix, just increase memory

is there any downside to increasing concurrency by such a large amount?

process might OOM, but there's an easy fix, just increase memory

okay sounds good, approved!


feat(deps): upgrade compiler dependencies

Upgrades project dependencies. See details in workflow run.

Automatically created by projen via the "upgrade-compiler-dependencies-2.x" workflow

⚪ Backport skipped
The pull request was not backported as there were no branches to backport to. If this is a mistake, please apply the desired version labels or run the backport tool manually.
Manual backport
To create the backport manually run:
backport --pr 1484

Questions ?
Please refer to the Backport tool documentation


feat: support for postman-collection conversion to asyncapi

Description
Completed the support for conversion of postman collection to asyncapi
Related issue(s)
Fixes #1516

asyncapi/converter-js#284 needs to be merged

/update

/rtm

/bounty

@asyncapi/bounty_team


eventing.knative.dev/scope: namespace does not work with distributed kafka channel

Describe the bug
In the previous version eventing.knative.dev/scope: namespace would allow me to connect to different Kafka clusters at least at the namespace level.
Expected behavior
The ability to connect to more than one kafka cluster with knative.
To Reproduce
Add the eventing.knative.dev/scope: namespace to a kafka channel (distributed) and nothing happens.
Knative release version
nightly
Additional context
We don't absolutely need eventing.knative.dev/scope: namespace to work, we just need a way to connect to multiple kafka clusters, like maybe even specifying it at the KafkaChannel level similar to how it is in KafkaSource.

Related to https://github.com/knative-sandbox/eventing-kafka/issues/157.
@AceHack assuming https://github.com/knative-sandbox/eventing-kafka/issues/157 gets resolved by allowing specifying the config at the KafkaChannel level, are you ok if we deprecate eventing.knative.dev/scope ?

Any update?

No progress I'm afraid. We are having discussion in https://github.com/knative-sandbox/eventing-kafka/issues/157 but nothing concrete yet.

/remove-lifecycle stale

Any updates on this?

/cc @travis-minke-sap

Yeah, I hadn't seen this one in a long while ; ).    Definitely something that we should support, and I don't see why the distributed implementation couldn't be made to work similar to consolidated version.  My time is going to be focused elsewhere for awhile (#588, #613, etc...) but I've added to my personal internal tracking list of things that Eric and I can look at.

/remove-lifecycle stale


feat: install zsh on unbuntu for developing

@zhongwencool missing get-zsh.sh script

But if you install zsh package, may be you don't need that script in the Dockerfile?

But if you install zsh package, may be you don't need that script in the Dockerfile?

The current bash is too basic, it's inconvenient to develop within it
I want to install ohmyzsh's plugins to make terminal experience delightful. :)
https://github.com/deluan/zsh-in-docker/blob/master/README.md

But if you install zsh package, may be you don't need that script in the Dockerfile?

The current bash is too basic, it's inconvenient to develop within it I want to install ohmyzsh's plugins to make terminal experience delightful. :) https://github.com/deluan/zsh-in-docker/blob/master/README.md

What I meant is since you install zsh package in Ubuntu already, why would you need get-zsh.sh script.
But now I see that get-zsh.sh actually installs oh-my-zsh, not zsh itself.

To summarize my comments: I don't think you need to change any distro-specific Dockerfiles.
get-zsh.sh will install zsh in the final image for all distros + oh-my-zsh, and you can just add ENV ERL_AFLAGS="-kernel shell_history enabled" there.

https://github.com/deluan/zsh-in-docker/pull/26

I've noticed that this repo is rarely updated. Why don't we just copy that script directly into get-zsh.sh and maintain it ourselves?
It's MIT license.

I'm testing this now https://github.com/emqx/emqx-builder/pull/112.
If it works, we can just switch to our fork.


SNOW-1314326 Add GitHub workflow/script to check PRs

Please answer these questions before submitting your pull requests. Thanks!

What GitHub issue is this PR addressing? Make sure that there is an accompanying issue to your PR.
Fixes #1314326

Fill out the following pre-review checklist:

[ ] I am adding a new automated test(s) to verify correctness of my new code
[ ] I am adding new logging messages
[ ] I am adding a new telemetry message
[ ] I am adding new credentials
[ ] I am adding a new dependency

Please describe how your code solves the related issue.
Porting over this script. It should check whether a PR is too long, has too many comments, and if it has been open for too long.

I have read the CLA Document and I hereby sign the CLA

recheck

Where's the output of the workflow being sent? Is this purely informational?

I am pretty sure it's purely informational, I don't think it actually blocks anything. @sfc-gh-azhan can correct me if I am wrong.

@sfc-gh-joshi @sfc-gh-vbudati yes, that is just daily job that checks all prs that is out to see if it violates any of our principle, manual check of outpput is required


[PUI] Test modals

Adds tests for general PUI modals (AboutInstance, License Info, About org, QR modal) and fixes a key error in the license modal.

@SchrodingersGat this adds a bit better coverage on modals