Implement i18n with IStringLocalizer

Feature request type
Enhance component
Component name
No response
Is your feature request related to a problem?
As far as I know, localization/i18n is not supported. For example in DataGrid/FilterOperator.cs, there are string constants:
    public static class FilterOperator
    {
        public static class String
        {
            public const string Contains = "contains";
            public const string NotContains = "not contains";
            public const string Equal = "equals";
            public const string NotEqual = "not equals";
            public const string StartsWith = "starts with";
            public const string EndsWith = "ends with";
            public const string Empty = "is empty";
            public const string NotEmpty = "is not empty";

            internal static string[] Values = GetFields(typeof(String));
        }

Describe the solution you'd like
Maybe use IStringLocalizer: ASP.NET Core Blazor globalization and localization
Have you seen this feature anywhere else?

Localization with Blazorise
Radzen Internalization
https://github.com/ant-design-blazor/ant-design-blazor/issues/1052

Describe alternatives you've considered

JSON-based Blazor localization

Pull Request

[ ] I would like to do a Pull Request

Code of Conduct

[X] I agree to follow this project's Code of Conduct

The example you mention, the class FilterOperator, represents a list of operators, and should not be directly translated (they must remain constant), because they are used to build filter expression evaluated locally or sent to server, so interpreted by other systems. Anyway, a localized version of them should be used for i18n.
As a general consideration, a great part of components in MudBlazor is language agnostic, so there is no need of i18n direct support. At the other side, some of the most recent components absolutely needs localization support, and I think the first is Data Grid.

Hey Folks.
Would you be interested in me jumping in here and try to integrate my little package here, TypealizR? I´m currently searching for actual projects that might benefit from using it, especially the new and shiny code-first approach.

Hi @earloc, my apologies for the delayed response.
I find the library intriguing, but we typically adhere to a policy of avoiding the inclusion of third-party libraries in our core codebase.
However, as I am not the project owner, I would defer to @henon to either confirm or refute this statement.

We have long been planning to add some kind of localization support but we never had a driving force behind the idea, i.e. someone who wants to work on it for the benefit of their own project.
@ScarletKuro Is correct in that we want to avoid dependencies if possible. But that doesn't mean that we can't integrate IStringLocalizer (suggested by @huanlin) or TypealizR (suggested by @earloc). The best way forward is to create extension packages, i.e. MudBlazor.Localization.StringLocalizer and/or MudBlazor.Localization.TypealizR (supported an maintained by the community, meaning one of you) and see what kind of interface is necessary on MudBlazor's side to allow integration of third party localization solutions.
Ideas are welcome and if somebody will step up to make such an extension I'll guide and review the process on the MudBlazor side.

@henon, I believe the issue at hand is related to localization and the challenge lies in whether it is feasible or even possible to extract this specific part into an external component. Allow me to explain further. In our codebase, we have a hardcoded string as shown in this example:
https://github.com/MudBlazor/MudBlazor/blob/9027f08c1dd868e7a35307304519198462c47a2d/src/MudBlazor/Components/DataGrid/HeaderCell.razor#L108
Based on my experience with localization, there are typically 3 to 4 approaches to address this.

Creating a ResX file and utilizing it directly without leveraging IStringLocalizer or other similar methods. This can be achieved using the Resource namespace, for instance:

<MudMenuItem OnClick="<EMAIL_ADDRESS>

Creating a static class with strings that users can override, although this approach may be less flexible. Here's an example:

public static class DataGridLocalization
{
    public static string UngroupString = "Ungroup";
}

<MudMenuItem OnClick="<EMAIL_ADDRESS>

Implementing a custom solution where you can read strings from a JSON file, INI file, RESX file, or any other format, and provide your own interface for working with it. However, I personally find this approach unnecessary in this case.

Utilizing third-party libraries such as Microsoft.Extensions.Localization and using their localization features instead, such as <MudMenuItem OnClick="@UngroupColumn">@localize["Ungroup"]</MudMenuItem> or @localize.Ungroup() if using TypealizR.

I hope this clarifies the situation.

Creating a static class with strings that users can override, [...]

Right, something like that, i.e. a class holding all strings for all components that can be passed down via cascading parameter is what I had in mind for the MudBlazor part. A static class or a service would be an easy default solution which will be sufficient for most users with the cascading parameter allowing us to be able to demonstrate different languages in a doc example for the same components.
The extensions could then adapt to our interface and provide the users their localization experience of choice without introducing 17 dependencies in our library.

Creating a static class with strings that users can override, [...]

Right, something like that, i.e. a class holding all strings for all components that can be passed down via cascading parameter is what I had in mind for the MudBlazor part. A static class or a service would be an easy default solution which will be sufficient for most users with the cascading parameter being able to override that and thus allowing us to be able to demonstrate different languages in a doc example for the same components.

The challenge with this approach is that it doesn't easily accommodate multi-language support. In such cases, you would need to manually handle language changes and override the static class strings (or do so within a service if one is in use) everytime. Alternatively, our implementation would need to provide built-in support for a dictionary structure that maps language names to keys.
This leads to the second problem: what if you want to outsource the translation process? You would need to manually extract all the string keys from our code/guide, prepare them for the third-party translator, and then manually copy-paste their translations back into the codebase. This process can be quite tedious and maintaining this is hard. I can see people will complain that some feature is missing in our implementation.
This is why IStringLocalizer is so powerful. It's just an interface where the default implementation reads from ResX files. However, you can easily replace it with other implementations using dependency injection. For example, you could use a standardized format that can be provided to translators, allowing them to work on the translations independently. Once the translations are completed, you simply upload the resource folder, and everything seamlessly works. Additionally, IStringLocalizer provides features like caching and integration with data annotations etc.

Hey @henon @ScarletKuro.
My package isn't a classic dependency, as it only contains a source-generator that aims to statically type access resources obtained through IStringLocalizer - by generating Code which geht's compiled along all the other stuff. So this is more of a Dev-dependenc, in NPM-terminology. So if you decide to use IStringLocalizer as an i18n-mechanism here, this might be a good fit / addition.
However, I have a feeling that the topics discussed here also contain some kind of customizability for such strings for users of MudBlazor.
As stated correct, IStringLocalizer is an abstraction over discrete sources of such resources, with good built-in support for using ResX-files via default implementations, which usually get registered through ordinary dependency-injection.
But I don't think using this as a mechanism to let people switch translations - by letting them replace those Implementations with custom one - might be a good idea. Especially as this would force users to also use such a custom implementation, when they might utilize IStringLocalizer in there own projects - at least chances may be high, that this is the case most of the time.
So for internal i18n-support: go for IStringLocalizer (and maybe use TypealizR) . And yeah, here I could jump in and do my part.
For letting users change the defaults: There might be the need for something else (despite that I believe this may be done via good old satelite-assemblies. Not sure, though).
Thinking about this, this may be done through code-first i18n, but support for this is in it's very early stage without the ability for a full translation-roundtrip.
Nevertheless, this seems to be an interesting field, I may have a look into somewhen in the future. But don't count on it.

I think everyone agrees on using IStringLocalizer, so is anyone needing this desparately enough to start working on a PR?

@henon This limitation is blocking me in a project I'm currently working on and I was about to fork and simply change the constants when I stumbled upon this issue.
I'd  be willing to work on initial IStringLocalizer integration for the DataGrid instead, but would need some pointers how you'd like it. Especially where to put localization (json so we can avoid resx?) files etc.
As it stands I'm pressed for time (this single localization issue turned up very late, because the desired switch from English to German was raised only in a late QA stage and we are supposed to ship in a month - don't ask...) so the ability to switch languages is not high up on my priorities list and quality wise I can't guarantee more than a POC to be honest.
Let me know if you'd like me to go for it anyway and if yes who I can contact to get me started.

FYI this issue is being worked on by Meduris in PR #7024


Add documentation for extensions in the backend

(Backend) extensions provide a specific structure that has to be used.
We should describe the reason and the functionality of extensions in the CONTRIBUTING.md.

Done in the development documentation


confirm population and generator variables are consistent

[ ] Make sure the bayesdb_generator_column table is populated and matches bayesdb_variable, or eliminate it altogether.
[ ] Update all callers of bayesdb_has_variable and bayesdb_variable_name to pass a generator or None, as appropriate.
[ ] Audit all callers of bayesdb_variable_numbers and bayesdb_generator_column_numbers to make sure they are sensible.
[ ] Consider eliminating bayesdb_generator_column_* in favour of bayesdb_variable_*.

[ ] Confirm every use of bayesdb_get_generator checks that the population matches, if appropriate.

[ ] Simplify multi-line list comprehensions in compile_simulate.


CMake Intel DPC++ compiler support

Please, consider adding  Intel DPC++ compiler support to CMake kits detection.
Here is some info https://www.intel.com/content/www/us/en/develop/documentation/oneapi-dpcpp-cpp-compiler-dev-guide-and-reference/top/compiler-setup/use-the-command-line/use-cmake-with-the-compiler.html
The one may be downloaded here:
https://www.intel.com/content/www/us/en/develop/documentation/oneapi-dpcpp-cpp-compiler-dev-guide-and-reference/top/compiler-setup/use-the-command-line/use-cmake-with-the-compiler.html

Are you using https://github.com/microsoft/vscode-cmake-tools extension ? If so, please open an issue in that repository.

Thanks, the issue created https://github.com/microsoft/vscode-cmake-tools/issues/3045


Updated resource page

Issue that this pull request solves
SWOC AND DWOC PARTICIPANT
Closes: #247
Proposed changes

Make the top margin small, same as contact-us page
Change the pencil icon with the same icon being used in contact-us page
The calender icon should also have the hovering effect and cursor pointer
Replace the level of trust checkbox with select box having the placeholder of level of trust
Put the valid until text under input box only

Brief description of what is fixed or changed

Made the margin same as of the contact us page.
Pencil icon is changed.
calender icon has cursor pointer and orange color on hover.
Added select box.
Added the valid until text under input box only

Types of changes
Bootstrap, Css, Javascript
Put an x in the boxes that apply

[x] Bugfix (non-breaking change which fixes an issue)
[x] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
[ ] Documentation update (Documentation content changed)
[ ] Other (please describe):

Checklist
Put an x in the boxes that apply

[x] My code follows the style guidelines of this project
[x] I have performed a self-review of my own code
[ ] I have commented my code, particularly in hard-to-understand areas
[ ] I have made corresponding changes to the documentation
[x] My changes generate no new warnings
[x] My changes does not break the current system and it passes all the current test cases.

Screenshots
Please attach the screenshots of the changes made in case of change in user interface

Other information
Any other information that is important to this pull request

@Kajol-Kumari Old PR was creating mess for me, so i opened this one. I have pushed the changes. Please check..

@Kajol-Kumari Old PR was creating mess for me, so i opened this one. I have pushed the changes. Please check..

Hey @urvashi-code1255 the screenshots look great! Just a few minor changes:

Please change the pencil icon in the "Additional Info" text-box, so that it will be the same as the one in "Your Subject" text-box in the Contact-Us page.

The select box UI is not responsive right now. Please adjust the styling to make it responsive for smaller screens.

In frontend/src/components/resource/resources.js in the input tag at line 94 kindly make the following small changes:

Remove placeholder="Date".
Add name="dob" .

Hey @urvashi-code1255 the screenshots look great! Just a few minor changes:

Please change the pencil icon in the "Additional Info" text-box, so that it will be the same as the one in "Your Subject" text-box in the Contact-Us page.

The select box UI is not responsive right now. Please adjust the styling to make it responsive for smaller screens.

In frontend/src/components/resource/resources.js in the input tag at line 94 kindly make the following small changes:

Remove placeholder="Date".
Add name="dob" .

Sorry, I haven't checked for responsiveness. I have made it responsive upto 400px and done all the requested changes :)

Sorry, I haven't checked for responsiveness. I have made it responsive upto 400px and done all the requested changes :)

Sorry, I haven't checked for responsiveness. I have made it responsive upto 400px now and done all the requested changes :)

Hey @urvashi-code1255 can we please have the level of trust section one below the other for small screen i.e the title should be on the top row and all the radio button options below it.

Sorry, I haven't checked for responsiveness. I have made it responsive upto 400px now and done all the requested changes :)

Hey @urvashi-code1255 can we please have the level of trust section one below the other for small screen i.e the title should be on the top row and all the radio button options below it.

Sure @Kajol-Kumari !!

Sure @Kajol-Kumari !!

@Kajol-Kumari changes added.

@Kajol-Kumari changes added.


Teams cannot add AudioVideoPlaybackBot as a participant

I am using the sample AudioVideoPlaybackBot, I have followed the instruction to run this bot locally and then installed the Bot in MS team, but when I call my bot from team I see the call hit my Bot in VS but it does not connect I get the "message": "MediaControllerConversationAddParticipantFailed. DiagCode: 7112" error I am new to this and cannot figure out where should I be looking, any help is appreciated as I am totally out of clues.
$>2019-11-21T14:51:35.2386656Z Info: LoggingMessageHandler.cs:167 SendAsync
ScenarioId: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
TransactionDirection: Incoming
TraceType: HttpResponse
ResponseTime: 15
request: POST http://custom.ngrok.io/api/calling
response: 202 Accepted
headers:
Client-Request-Id: f16c2698-310c-44dd-99c0-1ae4d4224258
Scenario-Id: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9,dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
Connection: close
$>2019-11-21T14:51:35.2386656Z Info: CommunicationsClientExtensions.cs:153 LogAndCreateResponse
ScenarioId: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
AppId: xxxxxx-c315-445f-abf4-xxxxxxxxxxxx
AppName: Sample.AudioVideoPlaybackBot.FrontEnd
TransactionDirection: Incoming
TraceType: HttpResponse
ResponseTime: 15
request: POST http://custom.ngrok.io/api/calling
response: 202 Accepted
headers:
Client-Request-Id: f16c2698-310c-44dd-99c0-1ae4d4224258
Scenario-Id: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
$>2019-11-21T14:51:35.2381655Z Info: CommunicationsClientExtensions.cs:151 LogAndCreateResponse
ScenarioId: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
AppId: xxxxxx-c315-445f-abf4-xxxxxxxxxxxx
AppName: Sample.AudioVideoPlaybackBot.FrontEnd
TransactionDirection: Incoming
TraceType: HttpRequest
request: POST http://custom.ngrok.io/api/calling
headers:
X-Microsoft-Skype-Chain-ID: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
Scenario-ID: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
X-Microsoft-Skype-Message-ID: f16c2698-310c-44dd-99c0-1ae4d4224258
X-Forwarded-Proto: (redacted)
X-Forwarded-For: (redacted)
Accept: application/json
Authorization: (redacted)
Host: custom.ngrok.io
User-Agent: Microsoft-Skype/3.0,(Calling/1.0)
Content-Length: 512
Content-Type: application/json; charset=utf-8
{
<EMAIL_ADDRESS>"#microsoft.graph.commsNotifications",
"value": [
{
<EMAIL_ADDRESS>"#microsoft.graph.commsNotification",
"changeType": "deleted",
"resourceUrl": "/communications/calls/461f0500-451f-4b71-ba51-b3679f88d9dd",
"resource": "/app/calls/461f0500-451f-4b71-ba51-b3679f88d9dd",
"resourceData": {
<EMAIL_ADDRESS>"#microsoft.graph.call",
"state": "terminated",
"resultInfo": {
<EMAIL_ADDRESS>"#microsoft.graph.resultInfo",
"code": 500,
"subcode": 9997,
"message": "MediaControllerConversationAddParticipantFailed. DiagCode: 7112"
},
"tenantId": "xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
"id": "461f0500-451f-4b71-ba51-b3679f88d9dd"
}
}
]
}
$>2019-11-21T14:51:35.2231625Z Info: LoggingMessageHandler.cs:138 SendAsync
ScenarioId: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
TransactionDirection: Incoming
TraceType: HttpRequest
request: POST http://custom.ngrok.io/api/calling
headers:
X-Microsoft-Skype-Chain-ID: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
Scenario-ID: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
X-Microsoft-Skype-Message-ID: f16c2698-310c-44dd-99c0-1ae4d4224258
X-Forwarded-Proto: (redacted)
X-Forwarded-For: (redacted)
Accept: application/json
Authorization: (redacted)
Host: custom.ngrok.io
User-Agent: Microsoft-Skype/3.0,(Calling/1.0)
Content-Length: 512
Content-Type: application/json; charset=utf-8
$>2019-11-21T14:51:32.4721124Z Info: LoggingMessageHandler.cs:167 SendAsync
ScenarioId: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
TransactionDirection: Incoming
TraceType: HttpResponse
ResponseTime: 3
request: POST http://custom.ngrok.io/api/calling
response: 202 Accepted
headers:
Client-Request-Id: 390c80e9-75aa-41dd-886b-88f65d828d3e
Scenario-Id: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9,dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
Connection: close
$>2019-11-21T14:51:32.4721124Z Info: CommunicationsClientExtensions.cs:153 LogAndCreateResponse
ScenarioId: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
AppId: xxxxxx-c315-445f-abf4-xxxxxxxxxxxx
AppName: Sample.AudioVideoPlaybackBot.FrontEnd
TransactionDirection: Incoming
TraceType: HttpResponse
ResponseTime: 2
request: POST http://custom.ngrok.io/api/calling
response: 202 Accepted
headers:
Client-Request-Id: 390c80e9-75aa-41dd-886b-88f65d828d3e
Scenario-Id: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
$>2019-11-21T14:51:32.4716123Z Info: CommunicationsClientExtensions.cs:151 LogAndCreateResponse
ScenarioId: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
AppId: xxxxxx-c315-445f-abf4-xxxxxxxxxxxx
AppName: Sample.AudioVideoPlaybackBot.FrontEnd
TransactionDirection: Incoming
TraceType: HttpRequest
request: POST http://custom.ngrok.io/api/calling
headers:
X-Microsoft-Skype-Chain-ID: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
Scenario-ID: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
X-Microsoft-Skype-Message-ID: 390c80e9-75aa-41dd-886b-88f65d828d3e
X-Forwarded-Proto: (redacted)
X-Forwarded-For: (redacted)
Accept: application/json
Authorization: (redacted)
Host: custom.ngrok.io
User-Agent: Microsoft-Skype/3.0,(Calling/1.0)
Content-Length: 353
Content-Type: application/json; charset=utf-8
{
<EMAIL_ADDRESS>"#microsoft.graph.commsNotifications",
"value": [
{
<EMAIL_ADDRESS>"#microsoft.graph.commsNotification",
"changeType": "updated",
"resourceUrl": "/communications/calls/461f0500-451f-4b71-ba51-b3679f88d9dd",
"resource": "/app/calls/461f0500-451f-4b71-ba51-b3679f88d9dd",
"resourceData": {
<EMAIL_ADDRESS>"#microsoft.graph.call",
"state": "establishing",
"id": "461f0500-451f-4b71-ba51-b3679f88d9dd"
}
}
]
}
$>2019-11-21T14:51:32.4686117Z Info: LoggingMessageHandler.cs:138 SendAsync
ScenarioId: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
TransactionDirection: Incoming
TraceType: HttpRequest
request: POST http://custom.ngrok.io/api/calling
headers:
X-Microsoft-Skype-Chain-ID: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
Scenario-ID: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
X-Microsoft-Skype-Message-ID: 390c80e9-75aa-41dd-886b-88f65d828d3e
X-Forwarded-Proto: (redacted)
X-Forwarded-For: (redacted)
Accept: application/json
Authorization: (redacted)
Host: custom.ngrok.io
User-Agent: Microsoft-Skype/3.0,(Calling/1.0)
Content-Length: 353
Content-Type: application/json; charset=utf-8
$>2019-11-21T14:51:31.7999780Z Info: GraphAuthClient.cs:154 SendHttpRequestAsync
ScenarioId: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
AppId: xxxxxx-c315-445f-abf4-xxxxxxxxxxxx
AppName: Sample.AudioVideoPlaybackBot.FrontEnd
CallId: 461f0500-451f-4b71-ba51-b3679f88d9dd
TenantId: xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
TransactionDirection: Outgoing
TraceType: HttpResponse
ResponseTime: 394
request: POST https://graph.microsoft.com/beta/communications/calls/461f0500-451f-4b71-ba51-b3679f88d9dd/microsoft.graph.answer
response: 202 Accepted
headers:
request-id: b75d0f1f-350e-4ad3-bb82-9ce4d588949d
client-request-id: 9cd358da-f387-42c9-9813-d1341e9e3578
x-ms-ags-diagnostic: {"ServerInfo":{"DataCenter":"East US","Slice":"SliceC","Ring":"5","ScaleUnit":"002","RoleInstance":"AGSFE_IN_17"}}
scenario-id: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
Strict-Transport-Security: max-age=31536000
Cache-Control: private
Date: Thu, 21 Nov 2019 14:51:31 GMT
Content-Length: 0
Content-Type: text/plain
$>2019-11-21T14:51:31.3728926Z Info: GraphAuthClient.cs:101 SendHttpRequestAsync
ScenarioId: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
AppId: xxxxxx-c315-445f-abf4-xxxxxxxxxxxx
AppName: Sample.AudioVideoPlaybackBot.FrontEnd
CallId: 461f0500-451f-4b71-ba51-b3679f88d9dd
TenantId: xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
TransactionDirection: Outgoing
TraceType: HttpRequest
request: POST https://graph.microsoft.com/beta/communications/calls/461f0500-451f-4b71-ba51-b3679f88d9dd/microsoft.graph.answer
headers:
Scenario-Id: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
Client-Request-Id: 9cd358da-f387-42c9-9813-d1341e9e3578
User-Agent: GraphCommunicationsClient-Sample.AudioVideoPlaybackBot.FrontEnd/<IP_ADDRESS>7
Authorization: (redacted)
Content-Type: application/json; charset=utf-8
{
"callbackUri": "https://custom.ngrok.io/api/calling",
"mediaConfig": {
<EMAIL_ADDRESS>"#microsoft.graph.appHostedMediaConfig",
"blob": "{"mpUri":"net.tcp://1.custom-msteam.domain.com:11111/MediaProcessor","audioRenderContexts":["dfb2aa1b-f104-4b3f-96e7-c32d4e805bfc"],"videoRenderContexts":["251a69da-3850-48ea-905b-b2a4b58503f6","d7fd3830-c3f6-4dac-b621-ad826f42866a","11af6fc2-2f79-4db9-93f6-fbf6852fa53e","552f8655-af57-421b-b067-1e6aa8afdad0"],"vbssRenderContexts":["873a0331-7ef1-40b7-80ca-3b366e57bbd1"],"audioSourceContexts":["fc5b748b-7d1c-4207-afbc-1cbd8418a07d"],"videoSourceContexts":["273e5d72-7b5a-4813-8eb2-bdc47fcb3bf1"],"vbssSourceContexts":["0e11699c-063f-4c41-acbd-ab46d832b1a2"],"dataRenderContexts":null,"dataSourceContexts":null,"supportedAudioFormat":"Pcm16K","videoSinkEncodingFormats":["H264","H264","H264","H264"],"vbssSinkEncodingFormats":["H264"],"initialScreenSharingRole":"Viewer","mpMediaSessionId":"64d09c6d-271d-4b1d-aa49-970320836173","regionAffinity":null,"skypeMediaBotsVersion":"<IP_ADDRESS>4","mediaStackVersion":"2<IP_ADDRESS>","mpVersion":"<IP_ADDRESS>23","callId":"461f0500-451f-4b71-ba51-b3679f88d9dd"}"
},
"acceptedModalities": [
"audio",
"video",
"videoBasedScreenSharing"
]
}
$>2019-11-21T14:51:29.9711123Z Info: LoggingMessageHandler.cs:167 SendAsync
ScenarioId: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
TransactionDirection: Incoming
TraceType: HttpResponse
ResponseTime: 1609
request: POST http://custom.ngrok.io/api/calling
response: 202 Accepted
headers:
Client-Request-Id: cd70f182-7d09-4bed-bf8f-7d6b1bb52a84
Scenario-Id: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9,dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
Connection: close
$>2019-11-21T14:51:29.9656112Z Info: CommunicationsClientExtensions.cs:153 LogAndCreateResponse
ScenarioId: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
AppId: xxxxxx-c315-445f-abf4-xxxxxxxxxxxx
AppName: Sample.AudioVideoPlaybackBot.FrontEnd
TransactionDirection: Incoming
TraceType: HttpResponse
ResponseTime: 1483
request: POST http://custom.ngrok.io/api/calling
response: 202 Accepted
headers:
Client-Request-Id: cd70f182-7d09-4bed-bf8f-7d6b1bb52a84
Scenario-Id: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
$>2019-11-21T14:51:29.9551091Z Info: CommunicationsClientExtensions.cs:151 LogAndCreateResponse
ScenarioId: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
AppId: xxxxxx-c315-445f-abf4-xxxxxxxxxxxx
AppName: Sample.AudioVideoPlaybackBot.FrontEnd
TransactionDirection: Incoming
TraceType: HttpRequest
request: POST http://custom.ngrok.io/api/calling
headers:
X-Microsoft-Skype-Chain-ID: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
X-Microsoft-Skype-Caller-Region: amer
X-Microsoft-Skype-Message-ID: cd70f182-7d09-4bed-bf8f-7d6b1bb52a84
X-Microsoft-Skype-Original-Message-ID: d7c9f605-799b-4157-bc5c-e320edfc9975
X-Forwarded-Proto: (redacted)
X-Forwarded-For: (redacted)
Accept: application/json
Authorization: (redacted)
Host: custom.ngrok.io
User-Agent: Microsoft-Skype/3.0,(Calling/1.0)
Content-Length: 1457
Content-Type: application/json; charset=utf-8
{
<EMAIL_ADDRESS>"#microsoft.graph.commsNotifications",
"value": [
{
<EMAIL_ADDRESS>"#microsoft.graph.commsNotification",
"changeType": "created",
"resourceUrl": "/communications/calls/461f0500-451f-4b71-ba51-b3679f88d9dd",
"resource": "/app/calls/461f0500-451f-4b71-ba51-b3679f88d9dd",
"resourceData": {
<EMAIL_ADDRESS>"#microsoft.graph.call",
"state": "incoming",
"direction": "incoming",
"callbackUri": "https://custom.ngrok.io/api/calling",
"source": {
<EMAIL_ADDRESS>"#microsoft.graph.participantInfo",
"identity": {
<EMAIL_ADDRESS>"#microsoft.graph.identitySet",
"user": {
<EMAIL_ADDRESS>"#microsoft.graph.identity",
"id": "c94f1ca4-ff5e-41c9-815a-6af65ede13b9",
"tenantId": "xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
}
},
"endpointType": "default",
"region": "amer",
"languageId": "en-us",
"id": "4332df0a-cad7-49f1-8d9d-041ac8638597"
},
"targets": [
{
<EMAIL_ADDRESS>"#microsoft.graph.invitationParticipantInfo",
"identity": {
<EMAIL_ADDRESS>"#microsoft.graph.identitySet",
"application": {
<EMAIL_ADDRESS>"#microsoft.graph.identity",
"id": "xxxxxx-c315-445f-abf4-xxxxxxxxxxxx"
}
},
"endpointType": "default",
"id": "0901ee33-b9dc-4144-ab80-8b190d733421",
"region": null,
"languageId": null
}
],
"tenantId": "xxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
"myParticipantId": "0901ee33-b9dc-4144-ab80-8b190d733421",
"incomingContext": {
<EMAIL_ADDRESS>"#microsoft.graph.incomingContext",
"sourceParticipantId": "4332df0a-cad7-49f1-8d9d-041ac8638597"
},
"id": "461f0500-451f-4b71-ba51-b3679f88d9dd"
}
}
]
}
$>2019-11-21T14:51:28.3472876Z Info: LoggingMessageHandler.cs:138 SendAsync
ScenarioId: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
TransactionDirection: Incoming
TraceType: HttpRequest
request: POST http://custom.ngrok.io/api/calling
headers:
X-Microsoft-Skype-Chain-ID: dbb24454-adb9-4ef9-bc3d-c5856dd31ca9
X-Microsoft-Skype-Caller-Region: amer
X-Microsoft-Skype-Message-ID: cd70f182-7d09-4bed-bf8f-7d6b1bb52a84
X-Microsoft-Skype-Original-Message-ID: d7c9f605-799b-4157-bc5c-e320edfc9975
X-Forwarded-Proto: (redacted)
X-Forwarded-For: (redacted)
Accept: application/json
Authorization: (redacted)
Host: custom.ngrok.io
User-Agent: Microsoft-Skype/3.0,(Calling/1.0)
Content-Length: 1457
Content-Type: application/json; charset=utf-8

Issue was with Certs

I know it's a while ago but can you please send your whole solution, "issue with certs" is not very helpful.

Its long time back but if I recall it was a mismatch between the cert installed and the thumbprint used in the code. Mostly setup issue. I went back and verified the certs, DNS records and other setup.

thank you hopefully this helps other people developing teams bots


Added mongodb helm chart.

Issue: https://github.com/kubernetes/kubernetes/issues/30289
Migrating from https://github.com/kubernetes/contrib/pull/1512
cc @bprashanth

cc @ingvagabund @lachie83

Thanks for the work!  Never played with mongo ... maybe this force me to give it a spin.

cc @erictune

@chrislovecnm PTAL

This looks good to functionally. I tested on a v1.3.6 GCE cluster.
One thing I ask before we merge this in is that you add a NOTES.txt that tells the user what they can/should do in order to access mongo both from inside and outside the cluster. I think you have most of it in the README at this point but I'd like to provide the user with guidance right after install.
For an example NOTES.txt check out:
https://github.com/kubernetes/charts/blob/master/incubator/jenkins/templates/NOTES.txt
Thanks @foxish!!!

@erictune @bprashanth According to the PetSet documentation, we create the pods in order, waiting for each of them to be both "running" and "ready".
In this mongodb chart, we want the readiness probe to ensure that we send traffic only to the primary and not the slave pods in a mongodb cluster. It appears that we cannot use it for that purpose, because such a readiness probe prevents the petset from scaling. Have we conflated two separate notions here or am I misunderstanding something?

@foxish The readiness probe should probably not be used for that.  You are actually hitting on a new feature that @bprashanth is working on, in terms of the master election.  The readiness probe simple tests that the PID is running correctly inside of the container.

In this mongodb chart, we want the readiness probe to ensure that we send traffic only to the primary and not the slave pods in a mongodb cluster.

The slave pods are still ready, you just don't want them to get traffic through the service. A service targets all ready pods that match the selector. You can use a second service to point to the master. You can either assign the role=master label by hand, or assign it in the init container of pet-0. A master/slave petset doesn't exist yet, like Chris mentioned. We've discussed ways to make simple master/slave easier like https://github.com/kubernetes/kubernetes/issues/28658 and https://github.com/kubernetes/kubernetes/issues/32528 but for now its DIY. Failover is another story and likely going to be harder to solve.

@viglesiasce Added and updated NOTES.txt. PTAL

Worked like a charm! Thanks @foxish!


Circular dependency for base/tools/cli?

I think we have a circular deps for main images:

base is build from tools - https://github.com/okd-project/okd-payload-pipeline/blob/main/buildconfigs/05-base.yaml
tools is built from cli - https://github.com/okd-project/okd-payload-pipeline/blob/main/buildconfigs/20-tools.yaml
cli is built from base - https://github.com/okd-project/okd-payload-pipeline/blob/main/buildconfigs/06-cli.yaml

Its not clear where to start when we want to build "real" base image with golang and things
/cc @aleskandro

Is this actually a circular dependency?

base extends from tools:centos9, which is cs9, locally imported in https://github.com/okd-project/okd-payload-pipeline/blob/main/buildconfigs/02-additional-imagestream.yaml#L9
cli is built from base <- cs9
tools is built from cli <- base <- cs9. This is a image meant to be part of the payload with this description Contains debugging and diagnostic tools for use with an OpenShift cluster.

Maybe we can track here what to do for upstreaming the forked dockerfiles for this build config?

base extends from tools:centos9, which is cs9

ooh, indeed, my bad - I though it comes from tools buildconfig

Maybe we can track here what to do for upstreaming the tools's forked dockerfile?

I think it would be confusing to change subject in this issue. Lets create a tracking issue for "upstream more stuff for 4.15" or even per-dockerfile issue


Performance/StringReplacement doesn't check for case insensitivity

0.34.2 (using Parser <IP_ADDRESS>, running on ruby 2.2.3 x86_64-darwin14)

Performance/StringReplacement auto-corrects:
s.gsub(/x/i, 'q')
s.gsub(/z/i, '')

to:
s.tr('x', 'q')
s.delete('z')

The new versions no longer match X and Z respectively.

Thanks for the bug report. I forgot to account for regex options. I am working on a fix for this now.


Package installation requires tsc to be installed globally

When I was trying to install v4.0.5 (was using v3.0.0), the command failed with the error sh: 1: tsc: not found. Through this error, I made the assumption I had to had typescript installed globally and, sure enough, once I did install it with npm i -g typescript, installation went without further issues.

The issue was indeed solved but it appears to have resurfaced.

Still needs a tsc to be preinstalled


Google search console

Description

This pull request adds a plugin for Google Search Console, which allows you to view your site performance and indexing status inside Framer.

This is https://github.com/framer/plugins/pull/18, rebased onto main


Improve resizer and improve other UI components

Improve resizer in Resizer.java
Improve Entry.java
The task is complete and following file additions were done to support the work:
NodeUserData.java
Resizer.java, Entry.java, styles.css has been fixed and improved accordingly.

On switching to maximized stage window or restoring to the old size, the resizer remains at the same coordinates on screen instead of moving to the bottom right corner.

This issue has been fixed.
Now the resizer disappears when the stage primaryStage is maximized and reappears when the stage is restored.
See


Pin BibTex key from InspireHEP stopped working

Report ID: LQEU3FTQ-euc
Expected behavior: Citekey should be replaced by the InspireHEP key when this option is selected
Actual behavior: Citekey is not updated. It did work for some time after the new InsireHEP API was released, but not anymore
Thanks in advance for the feedback

LQEU3FTQ-euc has the arXiv identifier in the pages field, I don't think that has ever worked? The current behavior expects the arXiv identifier to be in the publication title field.

Thanks @retorquere!
However, the same seems to happen with all entries, including those for which the arXiv id is in the publication title field.
Another example:
Report-ID: XLFKGFUR-euc

in XLFKGFUR-euc the publication title field has The Astrophysical Journal. I don't see an arXiv ID in this entry.

Indeed, but still, Pin BibTex key from InspireHEP doesn't fetch the  InspireHEP key

Man I don't know why my mind went there. I think I know the cause.

Can you try build 179 above?

Sorry, now there is an error fetching the InspireHEP key error; see Y9286FGY-euc

Slightly different error:
Could not fetch InspireHEP key from DOI []...PID does not exist
see X8EV5EIG-euc

The PID does not exist message comes from inspireHEP, not BBT. A new build will be rolling in soon that will make that more explicit, but you have 10.1093/mnras/stw2759 in the DOI field, and when I call https://inspirehep.net/api/doi/10.1093/mnras/stw2759 based on that, I get {"status": 404, "message": "PID does not exist."} as a response. You can click that link and see that result.

build 191 works as intended, thanks @retorquere!
Indeed, PID does not exist means that this particular entry is not in InspireHEP, my bad!

Cool, thanks for the confirmation, 5.2.79 is building


The open source license in the readme does not match the actual situation

The open source license in the readme is MIT, which does not match the actual open source license
Please refer to this section:

thanks for your reminder.


Using functions as linters prints file list to console, static linters do not

Description
Hello, I am looking at migrating our lint-staged config in package.json to a lint-staged.config.js file, moving from v8.1.5 to v9.2.1.
I've noticed something relatively minor in the console output that could be tweaked for a smoother experience.
When I just moved our JSON based config into the file everything worked as expected. However when I tried to pass functions for linters, this is when I noticed that the entire file list would be passed through to Listr and be output in the console when a function is detected as the linter. Here is an example of the output I am seeing:
git commit -m "Test lint-staged"
husky > pre-commit (node v10.13.0)
  ↓ Stashing changes... [skipped]
    → No partially staged files found...
  ❯ Running tasks...
    ❯ Running tasks for /project1{src,__mocks__}/**/*.{ts,tsx}
      ✔ lerna run lint:fix:prettier --scope project1 -- /project1/src/some/file1.tsx project1/src/some/file2.tsx /project1/src/some/file3.tsx
      ✖ lerna run lint:fix --scope project1 -- /project1/src/some/file1.tsx project1/src/some/file2.tsx /project1/src/some/file3.tsx
        git add /project1/src/some/file1.tsx /project1/src/some/file2.tsx /project1/src/some/file3.tsx
        lerna run test:related --scope project1 -- /project1/src/some/file1.tsx project1/src/some/file2.tsx /project1/src/some/file3.tsx
    ↓ Running tasks for /project1{src,__mocks__}/**/*.{json,css,md} [skipped]
      → No staged files match /project1{src,__mocks__}/**/*.{json,css,md}
    ↓ Running tasks for project2/**/*.{ts,tsx} [skipped]
      → No staged files match project2/**/*.{ts,tsx}
    ↓ Running tasks for project3/**/*.{ts,tsx} [skipped]
      → No staged files match project3/**/*.{ts,tsx}
    ↓ Running tasks for project4/**/*.{ts,tsx} [skipped]
      → No staged files match project4/**/*.{ts,tsx}
    ↓ Running tasks for project5/**/*.{ts,tsx} [skipped]
      → No staged files match project5/**/*.{ts,tsx}

The trouble with the above is, as I said relatively minor, however it gets a bit nastier when there are many files in the change list. We are working in a medium sized TypeScript monorepo that if you fall behind master for 3-4 days you will definitely have many files when pulling. I personally ran into problems during merge conflicts where I would be forced to run pre-commit against hundreds of changes from the master merge in potentially each project. In that case the console output while Listr is doing it's thing would be quite nasty:
  ❯ Running tasks...
    ❯ Running tasks for /project1{src,__mocks__}/**/*.{ts,tsx}
      ✖ lerna run lint:fix --scope project1 -- /project1/src/some/file1.tsx project1/src/some/file2.tsx /project1/src/some/file3.tsx
      /project1/src/some/file1.tsx project1/src/some/file2.tsx /project1/src/some/file3.tsx /project1/src/some/file1.tsx
      project1/src/some/file2.tsx /project1/src/some/file3.tsx /project1/src/some/file1.tsx project1/src/some/file2.tsx
      /project1/src/some/file3.tsx /project1/src/some/file1.tsx project1/src/some/file2.tsx /project1/src/some/file3.tsx
      /project1/src/some/file1.tsx project1/src/some/file2.tsx /project1/src/some/file3.tsx /project1/src/some/file1.tsx
      project1/src/some/file2.tsx /project1/src/some/file3.tsx /project1/src/some/file1.tsx project1/src/some/file2.tsx
      /project1/src/some/file3.tsx /project1/src/some/file1.tsx project1/src/some/file2.tsx /project1/src/some/file3.tsx
      /project1/src/some/file1.tsx project1/src/some/file2.tsx /project1/src/some/file3.tsx /project1/src/some/file1.tsx
      project1/src/some/file2.tsx /project1/src/some/file3.tsx /project1/src/some/file1.tsx project1/src/some/file2.tsx /
      project1/src/some/file3.tsx /project1/src/some/file1.tsx project1/src/some/file2.tsx /project1/src/some/file3.tsx
      /project1/src/some/file1.tsx project1/src/some/file2.tsx /project1/src/some/file3.tsx /project1/src/some/file1.tsx
      project1/src/some/file2.tsx /project1/src/some/file3.tsx /project1/src/some/file1.tsx project1/src/some/file2.tsx
      /project1/src/some/file3.tsx /project1/src/some/file1.tsx project1/src/some/file2.tsx /project1/src/some/file3.tsx
      /project1/src/some/file1.tsx project1/src/some/file2.tsx /project1/src/some/file3.tsx /project1/src/some/file1.tsx
      project1/src/some/file2.tsx /project1/src/some/file3.tsx /project1/src/some/file1.tsx project1/src/some/file2.tsx
      /project1/src/some/file3.tsx /project1/src/some/file1.tsx project1/src/some/file2.tsx /project1/src/some/file3.tsx
      /project1/src/some/file1.tsx project1/src/some/file2.tsx /project1/src/some/file3.tsx /project1/src/some/file1.tsx
      project1/src/some/file2.tsx /project1/src/some/file3.tsx
    ↓ Running tasks for /project1{src,__mocks__}/**/*.{json,css,md} [skipped]
      → No staged files match /project1{src,__mocks__}/**/*.{json,css,md}
    ↓ Running tasks for project2/**/*.{ts,tsx} [skipped]
      → No staged files match project2/**/*.{ts,tsx}
    ↓ Running tasks for project3/**/*.{ts,tsx} [skipped]
      → No staged files match project3/**/*.{ts,tsx}
    ↓ Running tasks for project4/**/*.{ts,tsx} [skipped]
      → No staged files match project4/**/*.{ts,tsx}
    ↓ Running tasks for project5/**/*.{ts,tsx} [skipped]
      → No staged files match project5/**/*.{ts,tsx}

It would be nice to have consistent, clean output while Listr is printing the stages to the console. I believe when no linter function is used and just a glob + static command is found, no files are printed.
Steps to reproduce
Use a function as a linter in v9.2.1
Environment

OS: macOS Mojave 10.14.2
Node.js: v10.13.0
lint-staged: v9.2.1

Yes, the behaviour of generateTasks is to use the entire task as the name passed to Listr, so this is a side-effect.
Maybe we could generate the name separately by using ["[file]"] or something as the array of filenames, so the command would be shorter, but still display where the file would go.

+1 For this, and the performance seems wrose.

+1
Possible to introduce an option to omit or truncate the file list re: function linters? We have to resolve large merge commit conflicts pretty regularly, and moving to a functional linter was the only way we could ignore files from match.
I don't want to suppress all of lint-staged's output with the -q flag because I don't think it should be an entirely invisible thing.

:tada: This issue has been resolved in version 9.4.0 :tada:
The release is available on:

npm package (@latest dist-tag)
GitHub release

Your semantic-release bot :package::rocket:


Feature request: custom coverage reporting

I've managed to get Jest running via:
load("@npm//:jest/package_json.bzl", jest_bin = "bin")

jest_bin.jest_test(
    name = "src_tests",
    args = [
        "--roots=%s" % native.package_name(),
        "--config=$(rootpath //:copy_jest_config)",
    ],
    data = [
        ":src",
        "//:copy_jest_config",
    ],
)

Due to some quirks of Jest it does require that a config is sent over (hence the target in the data attribute). However, Jest also wants to be the one to generate coverage reports. So in the jest.config.js I have the following:
module.exports = {
  cache: false,
  collectCoverage: true,
  coverageDirectory: process.env.COVERAGE_DIR,
  collectCoverageFrom: undefined,
  coverageReporters: ['text', ['lcovonly', {file: 'lcov.info'}]],
  modulePathIgnorePatterns: [],
  testMatch: ['**/*.test.js'],
  testPathIgnorePatterns: ['/node_modules/'],
};

Which means that Jest is now happily outputting lcov.info to the COVERAGE_DIR. However, the coverage reporter for js_test seems to kick in and overwrite the lcov.info file based on the V8 data (coverage.js, I think?).
Would it be possible to either add an attribute indicating a path to find existing lcov data (as in this case, where I can generate the lcov via Jest into the COVERAGE_DIR directly), or skip the generation of lcov.info if something else has already written the file?
[Note: I edited this description once I figured out it was the lcov.info file I needed to have Jest create.]

Ah so I've seen that COVERAGE_OUTPUT_FILE is one of the env variables that I could use to configure Jest (or any other lcov-enabled test runner).
So my request becomes either:

If something already exists at COVERAGE_OUTPUT_FILE can we skip the lcov generation/compilation in js_test/coverage.js?
Can there be an attribute added to js_test that disables lcov generation/compilation entirely?

I feel like 2 might be clearer, but then again you may have reasons for not wanting to accept my suggestion at all 😄

Sounds like something we could do. jest_test in rules jest could get a feature to enable jest coverage. @thesayyn wdyt?

Thanks! It would be great to have the escape hatch for all js_test rules, just in case something other than Jest is underpinning the test run. (Though adding it to rules_jest is also awesome.)

Sounds like something we could do. jest_test in rules_jest could get a feature to enable jest coverage. @thesayyn wdyt?

That one should do for both jasmine and jest rule. However, we should document how to disable the builtin coverage reporter.

2. Can there be an attribute added to js_test that disables lcov generation/compilation entirely?

It's already there actually but only available if you are a rule author (aka if you are using js_binary_lib and implementing your own rule). we never intended this to be controllable on a per-target basis.
I believe there should be a switch to disable coverage per target like the stamp attribute

+1 to adding an easy opt-out to js_test for use cases like this

This turned out to be the real challenge.  any attribute passed down to js_test is not accessible to _lcov_merger by any way env, custom launcher etc. Bazel spawns the lcov merger as a standalone process so it gets its own env. The only way to disable the built-in lcov merger is to define your own rule that overrides _lcov_merger attribute.
Though we could always halt the built-in coverage tool if some other tool is already written to the coverage file. @paullewis does that sound sensible for your use case?

Hey, sorry this caused so many headaches! Yes, for the use-case I am looking at an early exit from the built-in coverage tool if it discovers an existing file would be suitable.

Cool. I'll make a PR shortly today.


docs(mesh): update MeshGlobalRateLimit and MeshOPA targetref support table

Description

Change the targetRef support table since 2.6 it has a different layout.
Listener tags are not yet supported because the plugins need to be adjusted

Testing instructions
Preview link:
Checklist

[X] Review label added
[X] Conditional version tags added, if applicable.

For example, if this change is for an upcoming 3.6 release, enclose your content in {% if_version gte:3.6.x %} <content> {% endif_version %} tags (or if_plugin_version tags for plugins).
Use any of the following keys:

gte:<version> - greater than or equal to a specific version
lte:<version> - less than or equal to a specific version
eq:<version> - exactly equal to a specific version

You can do the same for older versions.

fix: https://github.com/Kong/kong-mesh/issues/5342

Thanks for reviewing @michaelbeaumont 👍

Hi @slonka ! If you rebase this PR, that should fix the failing broken links test (another PR was merged recently that fixes the 404 errors on dev).

Hi @cloudjumpercat ! Sorry for the delay, I've just updated the branch, let's see if it passes now.

@cloudjumpercat smoke tests still don't pass - it errors out with "invalid url" :(

@slonka Thanks! The smoke tests are expected to fail since this is from a fork, so that's okay. I'll review it today


RFC: container-runtime independent stdio setup for the container

Introduce a new osbuild-API through which the container, i.e. osbuild-run, can setup input and output (stdio) for the stage. Currently this is done passing fds over the API socket (when requested via setup-stdio). Input (the stdin for the container/stage) is a file-backed temp "buffer" to the json data. output (i.e. stdout of the container/stage) is either just the host's stdin or another file-backed temp buffer.
The buffer file is reopend for the container to get an independent file descriptor so writes and reads (and file modes) are independent.
This is a RFC, to make sure that is the right direction. If so I will clean the commits up and re-arrange them. I was also thinking of encapsulating that file-backed temp "buffer" code into its own small object (FileBuffer or some such.).

I think some of the commit messages need another round


No state change in conjunction with post

For some reason, I cannot get the state to change when I make a login $http post to my local server.
Controller:
	$scope.login = function(user){
		$http.post('/api/v1/user/login', user)
			.success(function(data, status){
				console.log(data);
				authToken.setToken(data);
				$state.go('user.exercises');
			})
			.error(function(data, status){
				$scope.status = data;
			});
	};

HTML:

            Username
            <input type="text" ng-model="user.username">

            Password
            <input type="password" ng-model="user.password">

        <button class="button button-block button-positive" ng-click="login(user)">
            Log In
        </button>

            Forgot password

ionic.project:
"proxies": [
    {
        "path": "/api/v1",
        "proxyUrl": "http://localhost:5000/api/v1"
    }
]

config.xml
<description>
    An Ionic Framework and Cordova project.
</description>
<author email="hi@ionicframework" href="http://ionicframework.com/">
  Ionic Framework Team
</author>
<content src="index.html"/>

//important
<access origin="*"/>
<allow-navigation href="http://*/*" />

<preference name="webviewbounce" value="false"/>
<preference name="UIWebViewBounce" value="false"/>
<preference name="DisallowOverscroll" value="true"/>
<preference name="android-minSdkVersion" value="16"/>
<preference name="BackupWebStorage" value="none"/>
<feature name="StatusBar">
  <param name="ios-package" value="CDVStatusBar" onload="true"/>
</feature>

I'm not sure if it has to do with the way I have it set up to use my server or if it is an actually ionic and ui-router problem. This works with my web version.

Greetings @stevenmwade!
My sensors indicate that you need to update your issue through our custom issue form. We are now requiring all issues to be submitted this way, to ensure that we have all of the information necessary to fix them as quickly as possible.
Click Here To Update Your Issue
I will have no choice but to close this issue if it is not resubmitted through the form. Please fill out the rest of the form, so that I may use my friendly robot powers to assist you.
Thank you!

I get an error alert ("issue update error") every time I submit it.
On Wed, Jul 22, 2015 at 2:57 PM Ionitron<EMAIL_ADDRESS>wrote:

Greetings @stevenmwade https://github.com/stevenmwade!
My sensors indicate that you need to update your issue through our custom
issue form http://ionicframework.com/submit-issue/#/?iid=4131. We are
now requiring all issues to be submitted this way, to ensure that we have
all of the information necessary to fix them as quickly as possible.
Click Here To Update Your Issue
http://ionicframework.com/submit-issue/#/?iid=4131
I will have no choice but to close this issue if it is not resubmitted
through the form. Please fill out the rest of the form, so that I may use
my friendly robot powers to assist you.
Thank you!
—
Reply to this email directly or view it on GitHub
https://github.com/driftyco/ionic/issues/4131#issuecomment-123860561.


How do i go faster

Im using this project since it seems like a user friendly way to achieve the latencies described here https://github.com/Vaibhavs10/insanely-fast-whisper but im trying a 27 min mp3 that seems to be processing for 20+ minutes. so what can i do to debug or go faster ?
some logs I'm seeing on modal

CUDA Version 12.1.0

Container image Copyright (c) 2016-2023, NVIDIA CORPORATION & AFFILIATES. All rights reserved.

This container image and its contents are governed by the NVIDIA Deep Learning Container License.
By pulling and using the container, you accept the terms and conditions of this license:
https://developer.nvidia.com/ngc/nvidia-deep-learning-container-license

A copy of this license is made available in this container at /NGC-DL-CONTAINER-LICENSE for your convenience.
WARNING: The NVIDIA Driver was not detected.  GPU functionality will not be available.
   Use the NVIDIA Container Toolkit to start this container with GPU support; see
   https://docs.nvidia.com/datacenter/cloud-native/ .
*************************
** DEPRECATION NOTICE! **
*************************
THIS IMAGE IS DEPRECATED and is scheduled for DELETION.
    https://gitlab.com/nvidia/container-images/cuda/blob/master/doc/support-policy.md
Received a request from Address(host='<IP_ADDRESS>', port=50528)
Request finished with status 200. (execution time: 48.7 ms, first-byte latency: 189.7 ms)
Received a request from Address(host='<IP_ADDRESS>', port=50528)
Request finished with status 200. (execution time: 46.0 ms, first-byte latency: 212.2 ms)
Received a request from Address(host='<IP_ADDRESS>', port=50528)
Request finished with status 200. (execution time: 23.4 ms, first-byte latency: 126.9 ms)
Received a request from Address(host='<IP_ADDRESS>', port=50528)
Request finished with status 200. (execution time: 32.9 ms, first-byte latency: 146.4 ms)
Received a request from Address(host='<IP_ADDRESS>', port=50528)
Request finished with status 200. (execution time: 28.2 ms, first-byte latency: 121.6 ms)
Received a request from Address(host='<IP_ADDRESS>', port=50528)

Requests may take longer to complete when a container is not actively running, as there is some time taken for cold starts and the GPU used also matters. Other than that, there's little I can do on my end to debug or improve speeds, but it is quite strange for the request to take 20+ minutes. You may want to check out the Modal docs or HuggingFace docs.

ok actually i think I'm not attached to a a GPU here, not sure why. Here are two hints i know this is the case.
This log from Modal
You are attempting to use Flash Attention 2.0 with a model initialized on CPU. Make sure to move the model to GPU after initializing it on CPU with model.to('cuda').
and the fact that I have this screenshot that shows no GPU on my localhost bun app but on your hosted app you do have a A10 attached

Any idea how I can make sure I have a GPU attached to my modal application

You can view the Modal docs here: https://modal.com/docs/examples
Also, they have a slack channel and provide quick + great help to Modal users there. A link to the slack should be somewhere in the docs or website.
You should be able to answer any questions and bugs you have with Modal there!


"unable to open database file"

I'm also getting an error when running it locally:
sqlite3.OperationalError: unable to open database file
However, when running it through Strider, it does function properly. Not sure why this is happening, and it might be something funky going on with permissions on my computer.

-@uhbrar https://github.com/ranking-agent/kp-registry/pull/18#pullrequestreview-722658886

On the sqlite error, I also saw that running locally via the main.sh, but not if I ran via docker-compose. So I think it has something to do with getting PYTHONPATH right or mounting the /data directory somehow.

-@cbizon https://github.com/ranking-agent/kp-registry/pull/18#issuecomment-892933450

I just cloned a fresh copy of the repo, installed the requirements in a venv, and ran main.sh without any issues. Does @cbizon or @uhbrar have any more insight into this issue?

I just did the same (but using conda instead of venv).
This was on master.
When I run main.sh it runs fine, but then executing refresh via the browser causes the error.

Yup, I'm on the same page as Chris. I cloned a fresh copy of the repo, recreated my venv directory, and reinstalled all requirements. I'm able to start is via main.sh, but if I try to actually do anything (get, refresh, anything at all), it causes the same sqlite error. @patrickkwang were you able to actually do anything, or did you just get it running?
As for other insights, I did run into this error 2 weeks ago, and I did something to fix it, but I just can't remember what that was, or how it got messed up again.

Thanks for clarifying. It continues to work fine for me when I refresh and get KPs.


Upgrade to Parcel v2

This upgrades Parcel from v1 to v2. The --out-file and --out-dir arguments are replaced by specifying the clientSideApp file. The --global argument is no longer supported in Parcel v2, so we specify it in index.ts instead.
I've confirmed that the package still works server-side and client-side.

Good idea @ryuichis. I've updated our test matrix.


436 Draft domain events

In order to support the flow of data back to Delius the new AP service will
publish Domain Events
A key design point is that the Domain Event messages published via
SNS/SQS should be "skinny" and provide a link ("detailUrl") to full
Event information exposed via our service's API.
In this PR we make a first attempt at designing AP Domain Events which
can support Delius' needs. Our understanding is that the highest priority
events are:

application.assessed -> the decision on eligibility for an AP place must be recorded in Delius
person.arrived -> the address must be updated in Delius
person.not-arrived -> the COM needs to be notified within Delius
person.departed -> the address must be updated in Delius

We add the specification for the Domain Events API as a separate
OpenAPI spec as for now we don't want to include it in the openApiGenerate
code generation gradle task.
Trello: https://trello.com/c/yYzrHuuR/436-move-delius-features-to-new-ap-service

@brownbearsoftware Could you take a quick look at this? I'd like to get it merged so that we can all view the swagger specs on the dev environment during our workshop on Weds.
I've tweaked the swagger config to keep this draft spec separate from the active docs used for code generation:
springdoc:
  swagger-ui:
    urls:
      - name: API
        url: "api.yml"
      - name: Domain events
        url: "domain-events-api.yml"


[aria-*] attributes do not match their roles

The blog has the following accessibility issue.

Hi, would love to help out with this if that's welcome? Let me know and I'll make a PR for it.

My guess is that this warning shows up because the icon is understood as an image, and for images the the alt attribute would be better than the aria-label.
However, in this case I'd recommend to actually hide the icon (since it's purely decorative), and give the link itself the aria-label to meet 2.4.4 link purpose.
Alternatively, you could add a visually hidden span (you'd need to add the necessary css to hide it) to your links, like in this example. But just adding aria-label to the link will do the job as well.
I also noticed that the arrow to the left is currently labelled as "next post" and the arrow to the right as "previous post",  but I wonder if the other way round (arrow left = previous, and arrow right = next) would be better?

Hey @dhinrichs-scottlogic, your help would be very much appreciated! I'd leave it up to you to decide what's the most appropriate and efficient way for handling that.

I also noticed that the arrow to the left is currently labelled as "next post" and the arrow to the right as "previous post", but I wonder if the other way round (arrow left = previous, and arrow right = next) would be better?

The behaviour of this is a bit weird. At the moment, the left arrow takes you to the next post and the right arrow takes you to the previous post. I think they should be the other way around - e.g. left arrow should take you to the previous post and the right arrow to the next post.
Should I assign this to you?

Yes, I'll have a go at it


Adding ability to only show a link to PythonTutor + Ability to customize some of the PythonTutor options

I have an idea for showing a link to PythonTutor, and not display it as an iFrame. I added the --link option to the magic for this purpose. I do not like the custom CSS much but will do for my needs.
I added some other options as well to customize the PythonTutor interface via the URL params.
Updated the README to reflect these new options. Let me know if you find this useful, or if you think I should change anything.

I'm on holidays. I will have a look and merge in some days/weeks.
If you have more ideas, feel free to open new PRs 😄

Thanks. Merged.
I've modified and added some stuff as it seems some options doesn't have an effect.

Uploaded version 0.3.0 to pypi.


METADATA in Interfaced PP - Missing

Issue Description
What did you expect to see happen?
To be able to run 2 multiple Interfaced PP in sequence...
What did you see instead?
`
(  549.13 sec) SIMULATION               : Message         -> -- Beginning step SensPost_1 of type: PostProcess                   --
(  549.13 sec) STEP SINGLERUN           : Message         -> ***  Beginning initialization ***
(  549.13 sec) STEP SINGLERUN           : DEBUG           -> jobHandler initialized
(  549.13 sec) STEP SINGLERUN           : DEBUG           -> for the role Model  the item of class PostProcessor   and name SensPost        has been initialized
(  549.13 sec) STEP SINGLERUN           : DEBUG           -> for the role Output the item of class HistorySet      and name Synchronized_History has been initialized
(  549.13 sec) STEP SINGLERUN           : DEBUG           -> for the role Output the item of class OutStreamPrint  and name Sync_FileOut    has been initialized
(  549.13 sec) STEP SINGLERUN           : Message         -> ***    Initialization done    ***
(  549.13 sec) STEP SINGLERUN           : Message         -> ***       Beginning run       ***
(  549.13 sec) HistorySet               : Warning         -> DataObject._convertToDict can be a slow operation and should be avoided where possible!
(  643.71 sec) PostProcessor            : DEBUG           -> InterfacedPostProcessor Post-Processor SensPost : start to run
Exception in thread generalOut:
Traceback (most recent call last):
File "/home/stryg/.conda/envs/raven_libraries/lib/python3.7/threading.py", line 926, in _bootstrap_inner
self.run()

File "/home/stryg/.conda/envs/raven_libraries/lib/python3.7/threading.py", line 870, in run
self._target(*self._args, **self._kwargs)

File "/home/stryg/raven/framework/Runners/SharedMemoryRunner.py", line 136, in
self.thread = InterruptibleThread(target = lambda q, *arg : q.append(self.functionToRun(*arg)),

File "/home/stryg/raven/framework/Models/PostProcessor.py", line 184, in evaluateSample
returnValue = (Input, self.interface.run(Input))

File "/home/stryg/raven/framework/PostProcessors/InterfacedPostProcessor.py", line 151, in run
outputDic = self.postProcessor.run(inputDic)

File "/home/stryg/raven/framework/PostProcessorFunctions/HistorySetSync.py", line 143, in run
outputDic['data']['ProbabilityWeight'] = inputDic['data']['ProbabilityWeight']

KeyError: 'ProbabilityWeight'
(  680.02 sec) Job Handler              : Message         ->  Process Failed <Runners.SharedMemoryRunner.SharedMemoryRunner object at 0x7f5cb8cfb7d0> internal returnCode -1
(  680.02 sec) STEP SINGLERUN           : DEBUG           -> the job "generalOut" has failed.
(  680.02 sec) STEP SINGLERUN           : Warning         -> There were 1 failed runs!
(  680.02 sec) STEP SINGLERUN           : Message         -> ***       Run finished        ***
(  680.02 sec) STEP SINGLERUN           : Message         -> ***     Closing the step      ***
(  680.02 sec) STEP SINGLERUN           : Message         -> ***        Step closed        ***
(  680.04 sec) SIMULATION               : Message         -> -- End step SensPost_1 of type: PostProcess                    --
(  680.04 sec) SIMULATION               : Message         -> -- Beginning step io_data of type: IOStep                           --
(  680.04 sec) STEP IOCOMBINED          : Message         -> ***  Beginning initialization ***
(  680.04 sec) STEP IOCOMBINED          : DEBUG           -> jobHandler initialized
(  680.04 sec) STEP IOCOMBINED          : DEBUG           -> for the role Output the item of class OutStreamPrint  and name FileOut         has been initialized
(  680.06 sec) STEP IOCOMBINED          : DEBUG           -> for the role Output the item of class OutStreamPlot   and name MyPlot2         has been initialized
(  680.06 sec) STEP IOCOMBINED          : Message         -> ***    Initialization done    ***
(  680.06 sec) STEP IOCOMBINED          : Message         -> ***       Beginning run       ***
(  680.06 sec) HistorySet               : DEBUG           -> Printing data to CSV: "FileOut.csv"
(  916.29 sec) HistorySet               : DEBUG           -> Printing metadata XML: "FileOut.xml"
(  970.83 sec) OUTSTREAM PLOT           : DEBUG           -> creating plotMyPlot2
(  973.87 sec) STEP IOCOMBINED          : Message         -> ***       Run finished        ***
(  973.87 sec) STEP IOCOMBINED          : Message         -> ***     Closing the step      ***
(  973.87 sec) STEP IOCOMBINED          : Message         -> ***        Step closed        ***
(  973.87 sec) SIMULATION               : Message         -> -- End step io_data of type: IOStep
`
Do you have a suggested fix for the development team?
Please attach the input file(s) that generate this error.  The simpler the input, the faster we can find the issue.

For Change Control Board: Issue Review
This review should occur before any development is performed as a response to this issue.

[x] 1. Is it tagged with a type: defect or task?
[x] 2. Is it tagged with a priority: critical, normal or minor?
[x] 3. If it will impact requirements or requirements tests, is it tagged with requirements?
[x] 4. If it is a defect, can it cause wrong results for users? If so an email needs to be sent to the users.
[x] 5. Is a rationale provided? (Such as explaining why the improvement is needed or why current code is wrong.)

For Change Control Board: Issue Closure
This review should occur when the issue is imminently going to be closed.

[ ] 1. If the issue is a defect, is the defect fixed?
[ ] 2. If the issue is a defect, is the defect tested for in the regression test system?  (If not explain why not.)
[ ] 3. If the issue can impact users, has an email to the users group been written (the email should specify if the defect impacts stable or master)?
[ ] 4. If the issue is a defect, does it impact the latest release branch? If yes, is there any issue tagged with release (create if needed)?
[ ] 5. If the issue is being closed without a pull request, has an explanation of why it is being closed been provided?

@mandd

checklists are good, since this defect will cause the code raising an error, an email to the users is optional


[Feature request] Add Android App Bundle (.aab) on GitHub Releases.

About Android App Bundles
How to build an app bundle?

The main benefit of App Bundles is: "optimize support for different devices, and users get smaller, more-optimized downloads."
Karma is only 1.55 MB so its pretty small already, mainly because I avoid third party frameworks and libraries that so much software seems to rely on these days.
https://liam-on-linux.dreamwidth.org/88032.html


Database opened multiple times

I was wondering if there's a preferred way to cleanly close all database connections. When running the sample code, sql.open() will get called twice, but db.close() will only get called once. My understanding is that the k6 lifecycle will run code any init code multiple times. Moving the sql.open() to setup() doesn't work.
It doesn't look like k6 supports a way to only run the init stage once. The db.close() in teardown() will only close one connection. I can't tell if some other mechanism is closing the extra connection, but unneeded connections to the database may degrade load test performance. Is there a recommended approach to this issue?

Hi there, and thanks for this great question. It's not something we've considered, but you're absolutely right that more than one connection would be created, and that db.close() would only close one of them.
As you've found out, setup() can't really propagate the connection to VUs, so unfortunately, I don't see a clean way around this. You could call open() and close() in the default function and skip setup() and teardown() altogether, using some __ITER conditionals to call sql.open() or create the table only once, but this complicates the script, and runs the risk of db.close() not being run at all if something fails in the script.
That said, at most only one additional connection would be created for each test run, and this is fixed and doesn't increase with more VUs you run the test with, so it wouldn't have an impact on test performance. This connection would be auto-closed when the test run ends and the process exits, so I don't think there's a functional impact.
It would be tricky to avoid this in the extension, and might be easier with support for a per-VU or per-scenario init function in k6, but I'm not sure we should consider that when the impact is so negligible.

Looking again, you are right that this is one per run instead of one per VU. That greatly reduces my concern. I think this can be resolved as-is. Thanks for the quick response!

I'm reopening this issue, as a similar question was posted on the forum.
After looking at this again, it does appear that a connection is established for each VU. I ran db.exec("SELECT pg_sleep_for('10 minutes');") in the default function, with 10 VUs/10 iterations, and running:
SELECT count(*) FROM pg_stat_activity
  WHERE pid <> pg_backend_pid() and usename = 'user' and backend_type = 'client backend';

... in psql showed one PID per VU (and an additional one for the CREATE TABLE statement).
I must've tested with a short query before, and wasn't seeing all the connections.
That said, I'm wondering if this is an issue that should be fixed. For Postgres, each connection can execute a single statement at a time, and I reckon this is the case for other RDBMSs. Even if we implement connection pooling, VUs would still need to wait for connections to be free in order to reuse them. So in high usage scenarios, it would still lead to 1 connection being used by each VU.
From a testing perspective, xk6-sql can serve as a way to load test the RDBMS. Each virtual user represents an individual load element, so it makes sense for each VU to create a separate DB connection.
Also, sharing data between VUs is notoriously tricky, which is why it's rarely done in k6. In order to implement this, we might need some changes in k6 itself, which likely wouldn't be trivial.
We'll discuss this internally, but it's likely a solution won't be implemented anytime soon, if at all.

Why not add a test lifecycle function do on Once per VU* at the end, when each VUE was executed, just like vueTeardown; AND we can execute the open function in init and close function in vueTeardown;


Add prebuild binaries for v10 electron for linux, mac, win

Hey
Could you add prebuild binaries for the last electron v10 release and also add an ability to build a binary for windows-electron via AppVeyor, as at the moment provided releases only for linux and mac
Would be appreciated for multiplatform building ability

I would really like this as well.  My mac has issues building node-gyp that I just can't figure out.

Duplicate of https://github.com/JoshuaWise/better-sqlite3/issues/355


30awg: truly wire wrapped?

In the wiki you mention using 30awg wrapping wire for the interconnection but the corresponding photo has the wires soldered. Would you mind comporting the text to the image for me? Thanks!

I used the kynar (wrapping) wire because it works very well for soldering traces.  It is easy to strip and holds its shape when you bend it.  You could use any wire you like but the wrapping wire is very easy to work with and solder.  So in the pic I soldered this wire between the connections on the bottom of the board.
Wire wrapping is not a skill I possess but I suppose you could do the same thing without the board and a wire wrapping tool.  Even if you are new with a soldering iron this is an easy solder job.  There are lots of folks using their original setup with Dupont connectors though.

I am going to close this for now.  If you have used a wire wrapping tool to make an ESPSomfy RTS device let us know.

Thanks for the followup. Happy to report that the wire wrapping tool came in over the weekend and the wrapping with 30awg Kynar wire utilizing the 3D printed case in the wiki was a success.

Awesome.  Can I get some pics?  Maybe we can include it as an option in the wiki.

Here are a few photos:

That is what I call a lost artform.  I think I may open up the discussions section so folks can share their projects.  I really didn't realize how many folks wanted this repo.  The discussions section would allow folks to show their projects and help others.

Though I read contracts better than I sing, I sing praises for REM, nPC and ESPSomfy: thank you!

It sounds like you have the entire gambit going on.   I have to say Nixie was one of those things I just did because I could.  Now it has more power than any of the Pentair panels.  Originally, I did it to fill the gaps that I felt were in my IntelliCenter but now there are an awful lot of Nixie implementations.  There were new schedule improvements just added as well.


Issues when pointing to a subview in a UITableViewCell

When pointing a poptip view to a subview (say, a UIButton) in a UITableViewCell, the "inView" parameter has to be the cell in order to have the poptip view positions correctly. However, that presents a couple of issues:

dismissTapAnywhere no longer works (well, maybe it does, but not as I would expect...), as the tap has to be within the cell. I resolve this by including an invisible button covering the whole screen.

the table section title and cell borders are now on top of the poptip view. I am not sure how to resolve this issue.

Could you please provide a fix or a workaround?
Cheers,
William

Added a custom view , the custom view and popover view background color should be transparent but if i cleared color of custom view by default it showed as black . How to rectify this.


morphTo fails on eager loading relation with numeric string key

Laravel Version: 8.1.0
PHP Version: 7.4.3
Database Driver & Version: Microsoft ODBC Driver 17 for SQL Server + SQLSRV 5.8.1

Description:
Laravel fails to eager load morphTo() relationship when morphed model's $keyType = 'string', but key itself is numeric.
Steps To Reproduce:
From example project https://github.com/saulens22/laravel8mssql/blob/master/tests/Feature/LaravelMssqlTest.php
$thing1 = Thing::firstOrCreate(['thekey' => 'xyz', 'data' => 'Lorem ipsum']);
$comment1 = $thing1->comments()->create([
    'comment' => 'A new comment.',
]);
// works OK
$collection = Comment::with('commentable')->get();

$thing2 = Thing::firstOrCreate(['thekey' => '123', 'data' => 'Lorem ipsum']);
$comment2 = $thing2->comments()->create([
    'comment' => 'Second comment.',
]);
// fails on next line
$collection = Comment::with('commentable')->get();

Error:
Illuminate\Database\QueryException

  SQLSTATE[22018]: [Microsoft][ODBC Driver 17 for SQL Server][SQL Server]Conversion failed when converting the nvarchar value 'xyz' to data type int. (SQL: select * from [things] where [things].[thekey] in (xyz, 123))

  at vendor/laravel/framework/src/Illuminate/Database/Connection.php:671
    667▕         // If an exception occurs when attempting to run a query, we'll format the error
    668▕         // message to include the bindings with SQL, which will make this exception a
    669▕         // lot more helpful to the developer instead of just the database's errors.
    670▕         catch (Exception $e) {
  ➜ 671▕             throw new QueryException(
    672▕                 $query, $this->prepareBindings($bindings), $e
    673▕             );
    674▕         }
    675▕

      +16 vendor frames
  17  tests/Feature/LaravelMssqlTest.php:33
      Illuminate\Database\Eloquent\Builder::get()

Will need some help here from people using SqlServer.

My quick look trough query grammar code suggests PHP auto-casting to integer, which SqlServer doesn't like.
SqlServer can convert string to int (where id in ('5', '6') works if id is integer), but fails when converting int to string (as in my example).
Simplest solution would be to wrap all query parameters in quotes, but I'm not sure it's fail-proof.

This probably comes down to the behavior of the bindValues method in the Connection:

Probably not possible for us to fix this at the moment.

I think this is possibly fixable. The is_int() method specifically checks the type, rather than infers like is_numeric().

Model::firstOrCreate() calls Builder::firstOrCreate()
Which calls the eloquent Builder::where($attributes)
Which internally calls the base Builder::where($attributes).

Illumindate\Database\Eloquent\Builder::where() is as follows.
public function where($column, $operator = null, $value = null, $boolean = 'and')
{
    if ($column instanceof Closure && is_null($operator)) {
        $column($query = $this->model->newQueryWithoutRelationships());

        $this->query->addNestedWhereQuery($query->getQuery(), $boolean);
    } else {
        $this->query->where(...func_get_args());
    }

    return $this;
}

Since a nested query will almost always wrap back around to the final if..
$this->query->where(...func_get_args());

You could probably get away with something like....
$arguments = func_get_args();

if (count($arguments) === 1 && is_array($arguments)) {
	$key = null;

	if (array_key_exists($this->getModel()->getKeyName(), $arguments[0])) {
		$key = $arguments[0][$this->getModel()->getKeyName()];
		unset($arguments[0][$this->getModel()->getKeyName()]);
	} else if (array_key_exists($this->getModel()->getQualifiedKeyName(), $arguments[0])) {
		$key = $arguments[0][$this->getModel()->getQualifiedKeyName()];
		unset($arguments[0][$this->getModel()->getQualifiedKeyName()]);
	}

	if ($key !== null) {
		$this->whereKey($key);
	}
} else {
    if ($arguments[0] === $this->getModel()->getKeyName()) {
        $this->whereKey(array_pop($arguments));
		return $this;
	}
}

$this->query->where(...$arguments);

return $this;

This is just a pure example that I threw together now, it maybe needs tidying up. This would make sure that anywhere clause that included the key is cast correctly. Line 196 of the Builder class will cast to a string.
if ($id !== null && $this->model->getKeyType() === 'string') {
    $id = (string) $id;
}

This also supports the fully qualified name when passing an array, such as from the firstOrCreate.

I think this may be fixed by https://github.com/laravel/framework/pull/34531


python37Packages.typed-ast: 1.1.1 -> 1.2.0

Semi-automatic update generated by https://github.com/ryantm/nixpkgs-update tools. This update was made based on information from https://repology.org/metapackage/python3.7-typed-ast/versions.
meta.description for python37Packages.typed-ast is: '"a fork of Python 2 and 3 ast modules with type comment support"'.

Checks done (click to expand)

built on NixOS

0 of 0 passed binary check by having a zero exit code.

0 of 0 passed binary check by having the new version present in output.

found 1.2.0 with grep in /nix/store/gvd22g26138ljq3hi6cf8pmn9p1nfb3n-python3.7-typed-ast-1.2.0

directory tree listing: https://gist.github.com/c911edfc32a212fc55df06a8abe7356d

du listing: https://gist.github.com/df99357f2dbee9dd10bff84a797c90c4

Rebuild report (if merged into master) (click to expand)

27 total rebuild path(s)
7 package rebuild(s)
7 x86_64-linux rebuild(s)
7 i686-linux rebuild(s)
6 x86_64-darwin rebuild(s)
7 aarch64-linux rebuild(s)
First fifty rebuilds by attrpath
mypy
nix-pin
python37Packages.mypy
python37Packages.pyls-mypy
python37Packages.pytest-mypy
python37Packages.typed-ast
thonny

Instructions to test this update (click to expand)

Either download from Cachix:
nix-store -r /nix/store/gvd22g26138ljq3hi6cf8pmn9p1nfb3n-python3.7-typed-ast-1.2.0 \
  --option binary-caches 'https://cache.nixos.org/ https://r-ryantm.cachix.org/' \
  --option trusted-public-keys '
  r-ryantm.cachix.org-1:gkUbLkouDAyvBdpBX0JOdIiD2/DP1ldF3Z3Y6Gqcc4c=
  cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=
  '

(r-ryantm's Cachix cache is only trusted for this store-path realization.)
Or, build yourself:
nix-build -A python37Packages.typed-ast https://github.com/r-ryantm/nixpkgs/archive/be465a3fcf3fa4a87c162721933f62a29cbf0353.tar.gz

After you've downloaded or built it, look at the files and if there are any, run the binaries:
ls -la /nix/store/gvd22g26138ljq3hi6cf8pmn9p1nfb3n-python3.7-typed-ast-1.2.0
ls -la /nix/store/gvd22g26138ljq3hi6cf8pmn9p1nfb3n-python3.7-typed-ast-1.2.0/bin

superseded, 1.3.1 is in master.


Check Home Assistant configuration FLAG

Hi
Good job for this awesome project
Would it be possible to add a binary sensor fot the Check Home Assistant configuration Addon which would indicate if the new version is ok?
In this way we could automate actions, for example automatically update, etc
Best regards

Thank you for reaching out.  We use GitHub for tracking issues, not for providing support.
If you are in need of support, you should try our Community Forum or join our Discord chat server.
You are more likely to get the answer you are looking for in those places.
Thanks! 👍
Welcome to the project! 🎉


risc-v: SV32 MMU support for qemu-rv

I'm working on implementing SV32 support (from #8602). I've opened a PR for my current WIP as a draft, as the implementation is not working as expected.
With my current implantation, I'm able to go through the mapping for the IO, kflash, ksram and pgram sections and enable the MMU, in  qemu_rv_mm_init(). From there, execution continues into and through nx_start, until  nxmsg_initialize. At which point the program falls over when accessing the global variable g_msgfreelist members.
On inspecting with GDB, I can see that the initial values for the list have changed from when they were originally set with struct list_node g_msgfreelist = LIST_INITIAL_VALUE(g_msgfreelist);. Curiously, these changes occur during the both before and after the MMU is enabled. Including if I set the values again, just before using them (like this):
void nxmsg_initialize(void)
{
  FAR struct msgbuf_s *msg;
  g_msgfreelist.next = &g_msgfreelist;
  g_msgfreelist.prev = &g_msgfreelist;

  msg = (FAR struct msgbuf_s *)kmm_malloc(sizeof(*msg) *
                                          CONFIG_PREALLOC_MQ_MSGS);
  if (msg)
    {
      int i;
      for (i = 0; i < CONFIG_PREALLOC_MQ_MSGS; i++)
        {
          list_add_tail(&g_msgfreelist, &msg->node);
          msg++;
        }
    }
}

Obviously, something is incorrect either which the MMU mapping, or the linker script setup. However, I can't seem to see the issue. Possibly @pussuw  could give me some pointers?
If you want to build locally, I'm using the compiler suggested in the readme (https://static.dev.sifive.com/dev-tools/riscv64-unknown-elf-gcc-8.3.0-2019.08.0-x86_64-linux-ubuntu14.tar.gz). I'm building like this:
make distclean
/tools/configure.sh rv-virt:knsh32
make -j 16
make export
cd ../apps
./tools/mkimport.sh -z -x ../nuttx/nuttx-export-*.tar.gz
make import
cd ../nuttx

Then running qemu with:
qemu-system-riscv32 -semihosting -s -S -M virt,aclint=on -cpu rv32 -smp 1 -bios none -kernel nuttx -nographic -serial mon:stdio

I'm then using gdb-multiarch to debug.
You'll need to apply the following to the 'apps' repo, in order to get the correct elf format, when linking. This would have to be amended as a separate PR, once resolved.
diff --git a/import/Make.defs b/import/Make.defs
index 0405e412b..7b6fb7ed5 100644
--- a/import/Make.defs
+++ b/import/Make.defs
@@ -90,5 +90,6 @@ endif

 # ELF module definitions

-LDELFFLAGS = -r -e _start -Bstatic
+LDELFFLAGS = -melf32lriscv
+LDELFFLAGS += -r -e _start -Bstatic
 LDELFFLAGS += $(addprefix -T,$(call CONVERT_PATH,$(TOPDIR)/scripts/gnu-elf.ld))

Keep in mind that i've 'hacked in' support, to try and get things going, there isn't support for both SV32 and SV39 ATM.

One common source of such issues is the config values, like ram start and size
CONFIG_RAM_SIZE=1048576
CONFIG_RAM_START=0x80100000

Another error in your config is that your user heap and pgpool virtual addresses overlap
CONFIG_ARCH_HEAP_VBASE=0xC0200000
CONFIG_ARCH_PGPOOL_VBASE=0xC0200000

Seems like you have some happy debugging to do!

@g2gps
====================================================================================
Configuration/Tool: rv-virt/knsh32
------------------------------------------------------------------------------------
  Cleaning...
  Configuring...
.config:99:warning: symbol value '1000CONFIG_APPS_DIR="../apps"' invalid for USEC_PER_TICK
  Building NuttX...
In file included from chip/qemu_rv_mm_init.c:30:
chip/qemu_rv_mm_init.c: In function 'qemu_rv_mm_init':
Error: chip/qemu_rv_mm_init.c:302:9: error: format '%lx' expects argument of type 'long unsigned int', but argument 3 has type 'uintptr_t' {aka 'unsigned int'} [-Werror=format=]
  302 |   binfo("mmu_enable: satp=%lx\n", g_kernel_pgt_pbase);
      |         ^~~~~~~~~~~~~~~~~~~~~~~~  ~~~~~~~~~~~~~~~~~~
      |                                   |
      |                                   uintptr_t {aka unsigned int}
chip/qemu_rv_mm_init.c:302:29: note: format string is defined here
  302 |   binfo("mmu_enable: satp=%lx\n", g_kernel_pgt_pbase);
      |                           ~~^
      |                             |
      |                             long unsigned int
      |                           %x
cc1: all warnings being treated as errors
make[1]: *** [Makefile:135: qemu_rv_mm_init.o] Error 1
make[1]: Target 'libkarch.a' not remade because of errors.
make: *** [tools/LibTargets.mk:53: arch/risc-v/src/libkarch.a] Error 2

@masayuki2009 Thanks, I'd overlooked that.

@pussuw I can see this build is failing for macos, sim/dynconns configuration. Is it that a result of these changes, or is there another issue here?

CI is broken for everyone, this is one fix in review https://github.com/apache/nuttx/pull/8913

@g2gps Please rebase your branch to the latest commit.


Why is there a discharge floor in the gain calculation

In GitLab by @wtbarnes on Jan 12, 2023, 14:24
When converting from photons to electrons in the response function, there is a line that imposes a limit on no less than 1 electron per photon,
https://gitlab.com/LMSAL_HUB/aia_hub/aiapy/-/blob/main/aiapy/response/channel.py#L373-375
This is not correct as there is no guarantee that a photon need produce an electron in the system. I carried this condition over from the following line in the IDL script for calculating the AIA response, aia_bp_parse_effarea.pro,
elecperphot = (evperphot * thisfullstr.elecperev) > 1

Importantly, this line has no effect as for the wavelength ranges relevant to this instrument, the electron-per-photon conversion is always > 1. However, I think this line should be removed. I'd also like to understand why this line is in the IDL code in the first place as perhaps there is something I'm missing or perhaps I misinterpreted the original intent of this condition when translating the code from IDL to Python.

In GitLab by @wtbarnes on Sep 2, 2023, 11:20
mentioned in commit cfd7e3bef94019b7f8763e3b32d8996f4bcc9f6b


Problems running bench with 1M files

Downloaded the 1M dataset and adjusted the code in DownloadHelper and Bench according to the new file names but when trying to run the bench example using ./mvnw -Pjdk11 compile exec:exec@bench it stops running after a while with a RuntimeException.
RuntimeException_executing_bench_on_1M_dataset.txt
machine_info.txt
Is there anything specific one need to adjust to make the bench example run with the 1M dataset?

Exception in thread "main" java.lang.RuntimeException: File sizes greater than 2GB are not supported on Windows--contributions welcome

Longer explanation: the easiest way to make a reasonably performant RandomAccessReader class is to use mmap, but Java's standard mmap only supports segments up to 2GB.  Hence the comments here:
/**
 * Simple sample implementation of RandomAccessReader.
 * It provides a bare minimum to run against disk in reasonable time.
 * Does not handle files above 2 GB.
 */
public class SimpleMappedReader implements RandomAccessReader {

We plugged in a native library to work around this in MMapReader, but that library does not support Windows.
So your options include (from easiest to hardest)

Use mac or linux to test large graphs
Update SimpleMappedReader to segment large files into < 2GB chunks
Implement a RandomAccessReader using standard io that matches mmap's performance
Implement Windows support for the native library we use https://github.com/indeedeng/util/tree/main/mmap

Yep I know that but I’m running on Linux x64 which is the reason why I was surprised about the 2GB limit.

        try {
            return new MMapReaderSupplier(path);
        } catch (UnsatisfiedLinkError|NoClassDefFoundError e) {
            if (Files.size(path) > Integer.MAX_VALUE) {
                throw new RuntimeException("File sizes greater than 2GB are not supported on Windows--contributions welcome");
            }

            return new SimpleMappedReaderSupplier(path);
        }

looks like for some reason it can't find the native mmap library

Will do, thx for the hint 👍🏻


Update to Remoting 3.40.

This Remoting version removes old, deprecated, unsupported protocols versions 1, 2, and 3. And the unused plain protocol. See the Remoting changelog for full details.

It looks like only Dockerfile-windows got updated, but there is also Dockerfile-windows-jdk11 and the nanoserver image files as well.

meh...my browser wasn't showing the latest...looks good.


Update setup.py for tensorflow 2(.2)

We had some complicated workarounds for TensorFlow CPU vs GPU and gast 0.2.2 vs 0.3.3 (#1348, #1350). Unfortunately, they turned out not to be compatible with pip install gpflow now that TensorFlow 2.2 is released - I don't understand WHY the logic isn't working, but it's not; pip seems to believe that gpflow requires gast 0.2.2 (despite the workaround logic!). In any case, the CPU vs GPU workaround is no longer required for TensorFlow 2.x as there is no separate GPU package. The gast workaround should no longer required either because TensorFlow 2.2 is compatible with the latest gast release so the CI should be happy. This PR removes both (and adds black to tests_requirements, which had been missing).

What was the problem with gast before? We didn't need that workaround?

Like I wrote before, I don't completely understand the technical details, but there's some difference to whether you do pip install . or python setup.py in a git clone (for which the workarounds did work) from doing pip install gpflow from PyPI (which seems to determine dependencies in some weird way that bypasses the workaround)...

Do I understand it correctly that this PR enables the installation of gpflow with the latest tensorflow (2.2.0) and gast (0.3.3) automatically using python setup.py develop or pip install -e .? GPflow is still compatible with TF 2.1.0 (and gast 0.2.2) but a user will have to manually install the correct versions of these libraries?

Yes, this PR should in no way affect GPflow's compatibility with TensorFlow 2.1. It will be up to the user to install TensorFlow 2.1 (and gast 0.2.2) correctly if that is what they want. As TensorFlow 2.2 has now been released, which works with the latest version of gast, the standard ">=2.1.0" should work fine. (Obviously we can only confirm this once we've pushed a new release to PyPI...)

I don't see how it helps users of TF2.1 and TF2.2. We allow both versions, but for installing GPflow with TF2.1, the user will have to perform some manual steps. Is this PR fixes one "bug" and introduces another?

I don't see how it helps users of TF2.1 and TF2.2.

It helps users of TF2.2 because with this fix they can do pip install gpflow and get the latest version of TF2.2 and no gast issues.

We allow both versions, but for installing GPflow with TF2.1, the user will have to perform some manual steps. Is this PR fixes one "bug" and introduces another?

GPflow does not have a direct gast dependency. If a GPflow user runs into any gast dependency issues with tensorflow 2.1, it is their problem. We should not pin gast version in GPflow.

Also, I cannot reproduce the issue.

I can reproduce the issue by creating a new conda environment:
conda create -n pip_install_test python=3.8
conda activate pip_install_test
pip install gpflow

It helps users of TF2.2 because with this fix they can do pip install gpflow and get the latest version of TF2.2 and no gast issues.

As I mentioned before, this PR solves the problem for TF2.2, but creates a problem for TF2.1 users. I would prefer that the problem would go away for both versions. Some users (e.g. prowler.io) that cannot afford to switch TF2.1 as quick as we do in GPflow.

GPflow does not have a direct gast dependency. If a GPflow user runs into any gast dependency issues with tensorflow 2.1, it is their problem. We should not pin gast version in GPflow.

The same reasoning applies to TF2.2. This dependency has no consequences for our tests - they pass. User can continue work with TF2.2 (e.g. I have been using TF2.2rc1 since its release and had no problems) without bumping to any issue.
I still cannot reproduce the issue. Can it be a side effect of python 3.8?

but creates a problem for TF2.1 users.

@awav please explain what problem you anticipate this PR creating for TF 2.1 users.

The same reasoning applies to TF2.2.

I do not understand what point you are trying to make. Yes, we do not pin TF version, only say >= 2.1 (because of the PR that removed compatibility with 2.0 specifically) - that's as it should be, no?

(e.g. I have been using TF2.2rc1 since its release and had no problems)

The issue is in how you install gpflow. If you do pip install -e . in a git-clone that does not have any issues. It's with installing directly from PyPI.

I still cannot reproduce the issue. Can it be a side effect of python 3.8?

I have not tried with conda+python3.7, but I can also reproduce the issue with python3.6 and virtualenv:
python3 -m venv test_venv
source ./test_venv/bin/activate
pip install -U pip setuptools  # the system versions on my Ubuntu 18.04 are too old
pip install gpflow

end up installing tensorflow==2.2.0 and gast==0.2.2 which is incompatible (e.g., gpflow tests fail).


display QR code when sending

Implements the QR code display from https://github.com/magic-wormhole/magic-wormhole/issues/431 - though I went with --qrcode, can change it though if you think it's too long.
Tried with some Android application, works fine.
I was wondering about the zero mode, probably doesn't make sense to have the QR code for that, right?
Lastly, screenshot:
(.venv) 0 magic-wormhole % wormhole send NEWS.md
Sending 29.3 kB file named 'NEWS.md'
Wormhole code is: 4-infancy-classroom
On the other computer, please run:

wormhole receive 4-infancy-classroom

    █▀▀▀▀▀█   ▄▀▀▀▄▄█▄▀▀▀ █▀▀▀▀▀█
    █ ███ █ ████▄ ▀ ▀▄▀█▀ █ ███ █
    █ ▀▀▀ █ █▀█▀██▄▄█ █▀█ █ ▀▀▀ █
    ▀▀▀▀▀▀▀ █ █ █▄▀ █ ▀ ▀ ▀▀▀▀▀▀▀
    █▄█▀█▀▀▄▄▀▀▄▀ ▀ ▄█▄█▄▄█████▄▄
    ▄ ▀▄▀▀▀█▄▄█▄  ▄▀ ▀▄ █▄█▀██ ▄▄
    ▄ ▄  ▀▀███▄▄ ▄▄▀█▀▄█  ▄▄▄ █▀▄
    ▀███▄█▀ ▀█▄█▀█▀▀▀▀▀ ▄▀▄ ▄▄  ▄
    ▄▄ ▄▀▀▀ ▀▀█▄▀ ▀▀██ ▄▀▄▄█▄▄█▄█
    █ ▄   ▀▄▀▄▀▄▀ ▄▀▀ ▀▄ ▄▄▄██▀ ▄
    ▀ ▀▀▀▀▀▀█▀   ▄▄▀█████▀▀▀█▄█ ▄
    █▀▀▀▀▀█ ▄▀ ▀██▀█▀  ▀█ ▀ █▄
    █ ███ █ ██ ▀  ▀▀▄▀▄ █▀▀█▀▄▀▄▄
    █ ▀▀▀ █ ▀█▀▄█ ▄█▄▀▀▄▄▀▀██▀ █
    ▀▀▀▀▀▀▀ ▀▀ ▀ ▀   ▀ ▀   ▀  ▀

Sorry, can you merge (or rebase) to main?
(I just merged #543 which also happens to fix CI).
Thanks for the PR!

Thanks!
The only thing I personally am waffling a little on is the default. (i.e. on by default, or not?)
Maybe @warner can generate an opinion.
There's a slight security-risk here, due to easily-automated QR-code scanning. Since the data encoded in the QR code is not a "real" Web URI  the transfer can't be "accidentally" destroyed by some automated system visiting the URI.
The easiest fix for the currently-failing tests is also to just make the default be "false" ;) too

also the dependency could probably be optional if you really wanted to,

I haven't looked at the dependency, but I'd rather keep the dependency itself non-optional.

The added dependency is https://pypi.org/project/qrcode and from a brief look it seems reasonable: no further dependencies, good release history, recent maintenance, many contributors.

A small amount of data collected from a simple Mastodon poll (https://mastodon.social/@meejah/113505790401742909)


commento.js: Commento can be manually initialized

I wanted to set a custom css url but it seems that with the new autoload feature this isn't possible.
Slight tweak to make this possible and added some docs for extra init options.

🤔  Alternative implementation would be to add data- attributes for each of the config params. Would allow you to keep the defered loading.


Comparison  ANOVA R vs SAS page

https://github.com/PSIAIMS/CAMIS/blob/5e19d3d0ac003e46dca043f203b3c844bb8ecca4/Comp/r-sas_anova.qmd#L9
Can we update this page to be more in line with the template

Now we have python content that can be added to the r-sas_anova page too.


Update purge test resources (both azure and aws) workflows

Description
Update purge test resources (both azure and aws) workflows
Type of change

This pull request is a minor refactor, code cleanup, test improvement, or other maintenance task and doesn't change the functionality of Radius (issue link optional).
Fixes: #7550

@ytimocin I do not think we need to create the issue for the deletion failure. It seems too noisy. other then them, lgtm.