[WIP] trying to tame the slow tests

step 1: identify slow tests
set test timeouts

tests: 2 sec
integration tests: 20 sec

I more or less can confirm your list locally:

It seems some tests even run into a 15 minute timeout when they fail...
Note the screenshot is from running the .preview integration tests, while on AppVeyor the "regular" integration tests are run only.

I added https://github.com/fsprojects/Paket/compare/test_speed?expand=1 in order to download the test-results from AppVeyor. Now I got this:

Seems like half an hour is spent on 2 test (15 minutes each). I briefly looked at those tests and their log but nothing obvious:

Log output test #3166
\u001b[37;2mC:\projects\paket\integrationtests\scenarios\i003166-pack-multitarget-with-p2p-by-tfm\temp already exists.\u001b[0m
C:\projects\paket\integrationtests\scenarios\i003166-pack-multitarget-with-p2p-by-tfm\temp> dotnet build MyProj.Main -c Release
\u001b[32mdotnet build MyProj.Main -c Release\u001b[0m
{IsError = false;
 Message =
  "Microsoft (R) Build Engine version 15.9.20+g88f5fadfbe for .NET Core";}
{IsError = false;
 Message = "Copyright (C) Microsoft Corporation. All rights reserved.";}
{IsError = false;
 Message = "";}
{IsError = false;
 Message = "  Paket version 5.209.1";}
{IsError = false;
 Message = "  Starting full restore process.";}
{IsError = false;
 Message = "  Downloading Argu 5.2";}
{IsError = false;
 Message = "  Downloading System.Memory 4.5.2";}
{IsError = false;
 Message = "  Download of Argu 5.2 done in 1 second. (2551 kbit/s, 0 MB)";}
{IsError = false;
 Message = "  Downloading FSharp.Core 4.3.2";}
{IsError = false;
 Message =
  "  Download of System.Memory 4.5.2 done in 1 second. (1184 kbit/s, 0 MB)";}
{IsError = false;
 Message =
  "  Download of FSharp.Core 4.3.2 done in 488 milliseconds. (40066 kbit/s, 2 MB)";}
{IsError = false;
 Message = "  Performance:";}
{IsError = false;
 Message = "   - Disk IO: 358 milliseconds";}
{IsError = false;
 Message = "   - Average Download Time: 202 milliseconds";}
{IsError = false;
 Message = "   - Number of downloads: 3";}
{IsError = false;
 Message = "   - Average Request Time: 96 milliseconds";}
{IsError = false;
 Message = "   - Number of Requests: 3";}
{IsError = false;
 Message = "   - Runtime: 2 seconds";}
{IsError = false;
 Message =
  "  Restoring packages for C:\projects\paket\integrationtests\scenarios\i003166-pack-multitarget-with-p2p-by-tfm\temp\MyProj.Main\MyProj.Main.csproj...";}
{IsError = false;
 Message =
  "  Restoring packages for C:\projects\paket\integrationtests\scenarios\i003166-pack-multitarget-with-p2p-by-tfm\temp\MyProj.Common\MyProj.Common.csproj...";}
{IsError = false;
 Message =
  "  Generating MSBuild file C:\projects\paket\integrationtests\scenarios\i003166-pack-multitarget-with-p2p-by-tfm\temp\MyProj.Common\obj\MyProj.Common.csproj.nuget.g.props.";}
{IsError = false;
 Message =
  "  Generating MSBuild file C:\projects\paket\integrationtests\scenarios\i003166-pack-multitarget-with-p2p-by-tfm\temp\MyProj.Common\obj\MyProj.Common.csproj.nuget.g.targets.";}
{IsError = false;
 Message =
  "  Generating MSBuild file C:\projects\paket\integrationtests\scenarios\i003166-pack-multitarget-with-p2p-by-tfm\temp\MyProj.Main\obj\MyProj.Main.csproj.nuget.g.props.";}
{IsError = false;
 Message =
  "  Generating MSBuild file C:\projects\paket\integrationtests\scenarios\i003166-pack-multitarget-with-p2p-by-tfm\temp\MyProj.Main\obj\MyProj.Main.csproj.nuget.g.targets.";}
{IsError = false;
 Message =
  "  Restore completed in 232.32 ms for C:\projects\paket\integrationtests\scenarios\i003166-pack-multitarget-with-p2p-by-tfm\temp\MyProj.Common\MyProj.Common.csproj.";}
{IsError = false;
 Message =
  "  Restore completed in 230.85 ms for C:\projects\paket\integrationtests\scenarios\i003166-pack-multitarget-with-p2p-by-tfm\temp\MyProj.Main\MyProj.Main.csproj.";}
{IsError = false;
 Message =
  "  MyProj.Common -> C:\projects\paket\integrationtests\scenarios\i003166-pack-multitarget-with-p2p-by-tfm\temp\MyProj.Common\bin\Release\net45\MyProj.Common.dll";}
{IsError = false;
 Message =
  "  MyProj.Main -> C:\projects\paket\integrationtests\scenarios\i003166-pack-multitarget-with-p2p-by-tfm\temp\MyProj.Main\bin\Release\net45\MyProj.Main.dll";}
{IsError = false;
 Message =
  "  MyProj.Common -> C:\projects\paket\integrationtests\scenarios\i003166-pack-multitarget-with-p2p-by-tfm\temp\MyProj.Common\bin\Release\netstandard2.0\MyProj.Common.dll";}
{IsError = false;
 Message =
  "  MyProj.Main -> C:\projects\paket\integrationtests\scenarios\i003166-pack-multitarget-with-p2p-by-tfm\temp\MyProj.Main\bin\Release\netstandard2.0\MyProj.Main.dll";}
{IsError = false;
 Message = "";}
{IsError = false;
 Message = "Build succeeded.";}
{IsError = false;
 Message = "    0 Warning(s)";}
{IsError = false;
 Message = "    0 Error(s)";}
{IsError = false;
 Message = "";}
{IsError = false;
 Message = "Time Elapsed 00:00:04.16";}
C:\projects\paket\integrationtests\scenarios\i003166-pack-multitarget-with-p2p-by-tfm\temp> paket C:\projects\paket\bin_netcore\paket.dll pack "C:\projects\paket\integrationtests\scenarios\i003166-pack-multitarget-with-p2p-by-tfm\temp\out"
\u001b[32mdotnet C:\projects\paket\bin_netcore\paket.dll pack "C:\projects\paket\integrationtests\scenarios\i003166-pack-multitarget-with-p2p-by-tfm\temp\out" \u001b[0m
Performance:
 - Runtime: 1 second
Paket version 5.209.1
No description was provided for package "MyProj.Common". Generating from ID and project output type.
No description was provided for package "MyProj.Main". Generating from ID and project output type.
Packaging: C:\projects\paket\integrationtests\scenarios\i003166-pack-multitarget-with-p2p-by-tfm\temp\MyProj.Main\paket.template
Packaging: C:\projects\paket\integrationtests\scenarios\i003166-pack-multitarget-with-p2p-by-tfm\temp\MyProj.Common\paket.template
Wrote: C:\projects\paket\integrationtests\scenarios\i003166-pack-multitarget-with-p2p-by-tfm\temp\out\MyProj.Main.1.0.0.nupkg
Wrote: C:\projects\paket\integrationtests\scenarios\i003166-pack-multitarget-with-p2p-by-tfm\temp\out\MyProj.Common.1.0.0.nupkg
Performance:
 - Runtime: 1 second
{References = All;
 Dependencies = Value is not created.;
 OfficialName = "MyProj.Common";
 Version = "1.0.0";
 LicenseUrl = "";
 IsDevelopmentDependency = false;
 FrameworkAssemblyReferences = [];}
[(PackageName ("FSharp.Core","fsharp.core"),
  VersionRequirement (Minimum <IP_ADDRESS>,No),
  ExplicitRestriction || (>= net45) (>= netstandard2.0));
 (PackageName ("Suave","suave"), VersionRequirement (Specific 1.1.3,No),
  ExplicitRestriction >= net45);
 (PackageName ("Argu","argu"), VersionRequirement (Specific 5.2.0,No),
  ExplicitRestriction && (< net45) (>= netstandard2.0))]
{References = All;
 Dependencies = Value is not created.;
 OfficialName = "MyProj.Main";
 Version = "1.0.0";
 LicenseUrl = "";
 IsDevelopmentDependency = false;
 FrameworkAssemblyReferences = [];}
[(PackageName ("FSharp.Core","fsharp.core"),
  VersionRequirement (Minimum <IP_ADDRESS>,No),
  ExplicitRestriction || (>= net45) (>= netstandard2.0));
 (PackageName ("Suave","suave"), VersionRequirement (Specific 1.1.3,No),
  ExplicitRestriction >= net45);
 (PackageName ("MyProj.Common","myproj.common"),
  VersionRequirement (Minimum 1.0.0,No),
  ExplicitRestriction || (>= net45) (>= netstandard2.0));
 (PackageName ("Argu","argu"), VersionRequirement (Specific 5.2.0,No),
  ExplicitRestriction && (< net45) (>= netstandard2.0))]

Also even more interestingly this disappeared in https://github.com/fsprojects/Paket/pull/3593 For no real reason, now the test-suite (in the PR) runs in half an hour...


Send access to Hidora environment

@dev-ng @dev-ng @JohannesHool : Did you receive your invitations for the Hidora test environment?


Improve pythonPath config for Open-Needs

#38

When I press "ESC" during the question for the Python Path, I get this error:
![image](https://user-images.githubusercontent.com/998700/155086340-9d6f20a4-449b-4a69-a81f-304907a686e7.png)

But even if aborted, a Python venv gets used:
Running cmd: python -c "import sys; print(sys.executable)"
Successful exec
Running cmd: /home/daniel/workspace/open-needs/open-needs-ide/.venv/bin/python --version
Successful exec
Python path: /home/daniel/workspace/open-needs/open-needs-ide/.venv/bin/python
Running cmd: /home/daniel/workspace/open-needs/open-needs-ide/.venv/bin/python -c "from needls.version import __version__; print(__version__)"
Successful exec
Saved text doc of type: jsonc

But that's the wrong one. It the one from that main open-needs-ide project and not the one from our test-env project.


Docs: Missing closing ``` from function comment

What were you searching in the docs?
https://docs.powertools.aws.dev/lambda/python/latest/api/event_handler/bedrock_agent.html
The example is not correctly displayed as there are missing closing ```
Is this related to an existing documentation section?
https://docs.powertools.aws.dev/lambda/python/latest/api/event_handler/bedrock_agent.html
How can we improve?
Add the ```
Got a suggestion in mind?
Add ``` to close the example
Acknowledgment

[X] I understand the final update might be different from my proposed suggestion, or refused.

Hi @massi-ang! Thanks for pointing this out, nice catch! Do you want to send a PR to fix it? That would be amazing.
We haven't officially released this feature yet and are still working on documentation. We expect to launch it by the end of this month.


Cannot find local JBR for EAP 2022.2 snapshot

Describe the bug
> Task :runIde
[gradle-intellij-plugin :intellij-aya:runIde] Cannot find java executable in: C:\Users\aaaa\.gradle\caches\modules-2\files-2.1\com.jetbrains\jbre\jbr_jcef-17.0.3-windows-x64-b469.3\extracted

But in C:\Users\aaaa\.gradle\caches\modules-2\files-2.1\com.jetbrains\jbre\jbr_jcef-17.0.3-windows-x64-b469.3\extracted
I see
$ ls
jbr_jcef-17.0.3-x64-b469/
markerFile

But when I ran the same code last week, the JBR was successfully resolved. So I opened the previously downloaded JBR jbr_jcef-17.0.3-windows-x64-b463.3 and I see
$ ls
jbr/
markerFile

If the rename of JBR folder is intended, the problematic code is here I guess (possible a simple .startsWith helps):
https://github.com/JetBrains/gradle-intellij-plugin/blob/5cd564676e72f69979a067888ff229a15976939b/src/main/kotlin/org/jetbrains/intellij/jbr/JbrResolver.kt#L189-L190
To Reproduce
use id("org.jetbrains.intellij") version "1.7.0-SNAPSHOT" in build.gradle.kts and run from IDE
Expected behavior
JBR is found and used to launch Intellij IDEA.
Environment:

OS: Windows 10
Gradle IntelliJ Plugin Version 1.7.0-SNAPSHOT
Gradle Version 7.4.2

EDIT: one simple workaround: rename jbr_jcef-17.0.3... to jbr

Also requested by JetBrains partners to continue plugin development, please fix. JetBrains Runtime changed layout permanently since 2022.2

Getting the same error when running ./gradlew buildPlugin using GW 222.3048.1-CUSTOM-SNAPSHOT
> Task :buildSearchableOptions
[gradle-intellij-plugin :jetbrains-gateway-plugin:buildSearchableOptions] Cannot find java executable in: /workspace/.gradle/caches/modules-2/files-2.1/com.jetbrains/jbre/jbr_jcef-17.0.3-linux-x64-b469.12/extracted

Environment:

OS: Linux
Gradle IntelliJ Plugin Version 1.6.0
Gradle Version 7.0.2

As a workaround, we disabled 'buildSearchableOptions' on build.gradle.kts:
tasks {
    buildSearchableOptions {
        isEnabled = false
    }
}

Hi anyone who encounters this issue, a simple workaround is renaming jbr_jcef-17.0.3-x64-b469 folder to jbr. 😄

For me the proposed workaround isn't working.
I have renamed extracted\jbr_jcef-17.0.3-x64-b469.12 to extracted\jbr
However, I receive
Process 'command 'C:\Users\Edoardo\.gradle\caches\modules-2\files-2.1\com.jetbrains\jbre\jbr_jcef-17.0.3-windows-x64-b469.12\extracted\jbr\bin\java.exe'' finished with non-zero exit value 1

For me the proposed workaround isn't working. I have renamed extracted\jbr_jcef-17.0.3-x64-b469.12 to extracted\jbr However, I receive
Process 'command 'C:\Users\Edoardo\.gradle\caches\modules-2\files-2.1\com.jetbrains\jbre\jbr_jcef-17.0.3-windows-x64-b469.12\extracted\jbr\bin\java.exe'' finished with non-zero exit value 1

Which version of Gradle IntelliJ Plugin are you using? I got the same error in 1.6.0. You can try the snapshot version

Could you folks please verify if the latest snapshot works for you?

Could you folks please verify if the latest snapshot works for you?

Updated org.jetbrains.kotlin.jvm to 1.7.0 and now it's working!
Thank you!


See if self property is terribly expensive.

No longer relevant. Not going to make async an extensible object. Closed by 1e9c7a80604b55ad1d01b52ca2c07ac556ead0e6.


Library functions to include

One possibility for the pixelflow library is to incorporate a collection of 'custom functions' compatible with the pixelflow function (for mapping over each object, masked region or bounding box).  This issue is to collect ideas for functions to include, particularly those useful to existing project work or that already exist and can be shared this way.  Please add to the list below or leave a comment.

[ ] cosine transform (Marjan)
[ ] elliptic fourier descriptors (Alan) https://pyefd.readthedocs.io/en/latest/
[ ] 3D SH shape descriptors (Alan) https://github.com/AllenCell/aics-shparam

Porespy 'regionprops_3D' 3D shape and size metrics (https://porespy.org/modules/generated/generated/porespy.metrics.regionprops_3D.html)
And ability to add to features data frame like props_to_DataFrame function (https://porespy.org/modules/generated/generated/porespy.metrics.props_to_DataFrame.html)


Feater/about update

Can you merge main into your branch so that it is up to date with the current code?

This is looking great! Ready to go in as soon as the comments above are resolved! 😄

Looks good to me! Great work guys, merging it in now!


olGeometryUtils may return invalid coordinates

Requesting a profile for https://www.geodaten.bayern.de/freizeitwege/KML/114.kml leads to invalid coordinates.
0: Array(3) [ 1094269.731043048, 6049028.267027583, 0 ]

1: Array(3) [ 1094281.216886971, 6049082.192386966, 0 ]

Reason for the failed operation:
The selected geometry is a MultiLineString. The further processing cannot create a valid LineString and returns the original geometry.
The content of the KML simplified:


Update BuildTools and core-setup to the latest.

Fix #201

Can you update anything in core-setup.proj yet? I'd only say #201 is done once the Repo API implementation exceptions are gone.

Good point.  Updated.
I guess the only "TODO" part that is left is that the PublishCoreSetupBinaries task is still running.  This is necessary because the CLI doesn't know to pick these binaries up from the transport feed's assets directory yet.
I'll log a separate issue for solving that later, when the CLI can uptake it.

Thinking more, I should update Core-setup to start writing to the transport feed ‘assets’ directory now. That way CLI can use the assets when it gets updated.


add recent localization contributors

This PR adds @shogo82148, @toshimaru, and @quaresmateo as contributors for the localization-related issues and pull requests. Thank you!
For the record, here's how I made these changes:
$ npx all-contributors-cli
? What do you want to do? Add new contributor or edit contribution type
? What is the contributor's GitHub username? shogo82148
? What are the contribution types? 🌍  Translation

$ npx all-contributors-cli
? What do you want to do? Add new contributor or edit contribution type
? What is the contributor's GitHub username? toshimaru
? What are the contribution types? 🌍  Translation

$ npx all-contributors-cli
? What do you want to do? Add new contributor or edit contribution type
? What is the contributor's GitHub username? quaresmateo
? What are the contribution types? 🌍  Translation

Note: You can also pass arguments to the CLI:
npx all-contributors-cli add <username> <contribution>
# Example:
npx all-contributors-cli add quaresmateo translation,code,doc

cc @github/docs

Removed All Contributors

https://github.com/coding-blocks/certificate-worker/issues/37#issue-728232458

This PR adds @shogo82148, @toshimaru, and @quaresmateo as contributors for the localization-related issues and pull requests. Thank you!
For the record, here's how I made these changes:
$ npx all-contributors-cli
? What do you want to do? Add new contributor or edit contribution type
? What is the contributor's GitHub username? shogo82148
? What are the contribution types? 🌍  Translation

$ npx all-contributors-cli
? What do you want to do? Add new contributor or edit contribution type
? What is the contributor's GitHub username? toshimaru
? What are the contribution types? 🌍  Translation

$ npx all-contributors-cli
? What do you want to do? Add new contributor or edit contribution type
? What is the contributor's GitHub username? quaresmateo
? What are the contribution types? 🌍  Translation

Note: You can also pass arguments to the CLI:
npx all-contributors-cli add <username> <contribution>
# Example:
npx all-contributors-cli add quaresmateo translation,code,doc

cc @github/docs


Error Creating Index

Please provide us with the following information:
Cannot successfully index a PDF document after provisioning the application.

This issue is for a: (mark with an x)
- [ x] bug report -> please search issues before submitting
- [ ] feature request
- [ ] documentation issue or request
- [ ] regression (a behavior that used to work and stopped in a new release)

Minimal steps to reproduce

Freshly provision the application and attempt to upload a pdf file.

Any log messages given by the failure

UI Error Message:
System.Net.Http.HttpRequestException: net_http_message_not_success_statuscode_reason, 400, Bad Request at System.Net.Http.HttpResponseMessage.EnsureSuccessStatusCode() at SharedWebComponents.Services.ApiClient.UploadDocumentsAsync(IReadOnlyList`1 files, Int64 maxAllowedSize, String cookie)
Underlying Error (App Insights) Message:
The antiforgery token could not be decrypted. The key {fadc1d55-bf1a-40ee-a0c2-cebe7f949163} was not found in the key ring. For more information go to https://aka.ms/aspnet/dataprotectionwarning
Exception type System.Security.Cryptography.CryptographicException
Failed method	Microsoft.AspNetCore.DataProtection.KeyManagement.KeyRingBasedDataProtector.UnprotectCore
Expected/desired behavior

The ability to successfully upload a pdf document and index it with Azure AI Search.

OS and Version?

Window 11, Visual Studio 2022.
Updates are current.

Versions

??

Mention any other details that might be useful
Puzzled. Uploaded this issue yesterday, but did not find it today (6/11/24). Hoping you're not closing it without replying.
As a customer-facing architect for Microsoft, I highly recommend this application to customers on a continual basis for learning and reference. I would expect the courtesy of a reply. Thanks!

Thanks! We'll be in touch soon.

The antiforgery token could not be decrypted. The key {fadc1d55-bf1a-40ee-a0c2-cebe7f949163} was not found in the key ring.

Maybe try clean cookie and cache and retry? That might caused by an outdated client app

Interestingly, the problem worked itself out. Must have been cached.
Thanks!


Extend dev-guidelines handbook

This PR wants to improve and extend the dev guidelines with coding best practices, sample code snippets, and describing common scenarios present in io-projects
cc @gunzip @francescopersico

some more topics (memo to myself):

@Undermaken i suggest to merge this and go on
@cloudify may you please let me merge PR for this repo ?


feat: enable securing metrics endpoints

This PR introduces a new flag called secure-metrics-server which allows configuring secure metrics endpoints in topolvm-controller and topolvm-node. https://github.com/topolvm/topolvm/issues/736 made it possible to utilize the new secure metrics serving feature introduced in https://github.com/kubernetes-sigs/controller-runtime/pull/2407.

@toshipp good call. I wasn't planning to change the helm chart, but I can give it a try. Should I target having it enabled by default, or just add new options to the chart so it can be set up if needed?

I don't have additional comments.

Should I target having it enabled by default, or just add new options to the chart so it can be set up if needed?

IMO, it's better to disable secure metrics endpoints by default for compatibility. Let's wait Toshi's answer.

@suleymanakbas91
IIUC, this feature needs a new role, so it is better to set it as disabled default.

@toshipp Sorry that this is taking a bit long. I want to have all the chart-related changes and documentation in place so that users can enable this feature without much hassle. However, it took me longer than expected, and the enablement of the feature in this PR got prioritized for us. I'd really appreciate if we could get this PR merged and then I'll work on the chart-related changes and the documentation in a separate PR.

@suleymanakbas91
OK. We'll merge this.


Decouple templates from alert definitions and notifications

In our bosun setup, I encountered a unique situation.

An alert, when triggered should send POST notification (A Proper JSON) on one/many of our endpoints. The JSON content may also vary.
An alert, when triggered should send a formatted email to a DL.
An alert, when acted upon(i.e. Close/Ack) should send notifications as a formatted email to a DL.

Since, Bosun supports only one template bound to an alert definition, it is impossible to achieve above goals with a single alert definition.
So, I looked into the code and tweaked the code so that we can choose a template of our choice while sending a notification.
The key concepts I assumed and implemented are as follows:

Template should have a way to store body without all html wrapper tags. So, 'postBody' in addition to subject and body.
In alert definition itself, set up which templates are to be used for which notifications i.e. notificationTemplates = n1:t2, etc. If none is set, alert's default template will be used.
When an alert is triggered, all the additional templates and default templates will be executed and stores in redisDB
Action notification should be different from warn/crit notification. So, set 'actionNotification' explicitly. If not set, pick up the notifications for existing abnormal state
Similar to 'unknownTemplate', provide a way to setup actionTemplate as well.
While notifying, if notification is of type 'post', prefer postBody over body if present. For emails, prefer body.

The config for me now looks like:
template atemplate {
    subject = `{{$first := index .States 0}}{{$count := len .States}}
    {{.User}} {{.ActionType}}
    {{if gt $count 1}} {{$count}} Alerts
    {{else}} Incident #{{$first.Id}} ({{$first.Subject}})
    {{end}}`
  body = `{{$count := len .States}}{{.User}} {{.ActionType}} {{$count}} alert{{if gt $count 1}}s{{end}}:

Message  {{.Message}}

Incidents:

  {{range .States}}

      #{{.Id}}:
      {{.Subject}}

  {{end}}

`

}

template t1 {
    subject = mysubject1
    body = mybody1
    postBody = `
                {"name" : {{.Alert.Vars.notes}}}
                `
}

template t2 {
    subject = mysubject2
    body = mybody2
}

template t3{
    subject = mysubject3
    body = mybody3
}

notification n1 {
    post = http://myApp/savealertsdetails
    body = {{.|json}}
    useBody = true
}

notification n2 {
    print = true
}

notification n3 {
    print = true
}

notification n4 {
    email =<EMAIL_ADDRESS>}

actionTemplate = atemplate

alert a1{
    template = t1
    warn =1
    crit =1
    notificationTemplates = n1:t2, n2:t3
    actionNotification = n4
    warnNotification = n1
    critNotification =n2,n3
}

Does this seem like a proper way to address this issue?
Thanks,
Rohit.

@rohitpmore Some screenshots of current spec I'm working on are in Bosun slack at https://bosun.slack.com/files/kylebrandt/F2Z0QDYMV/pasted_image_at_2016_11_04_07_54_am.png

Hi Kyle, sorry for much-delayed replies.
Was offline for quite some time.
The spec's look nice. Is this the current spec or further modifications are
done.
I would be happy to assist in any manner required.
Thanks,
Rohit.
On Fri, Nov 4, 2016 at 7:26 PM, Kyle Brandt<EMAIL_ADDRESS>wrote:

@rohitpmore https://github.com/rohitpmore Some screenshots of current
spec I'm working on are in Bosun slack at https://bosun.slack.com/files/
kylebrandt/F2Z0QDYMV/pasted_image_at_2016_11_04_07_54_am.png
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/bosun-monitor/bosun/issues/1918#issuecomment-258437393,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AIG_0wQbT3s3N2so1AoHtDBUr0FXS946ks5q6zlygaJpZM4KHRJs
.

--
Rohit More
"Simplicity is the most difficult thing to secure in this world" - George
Sand

Will be fixed in https://github.com/bosun-monitor/bosun/pull/2135


Allow users to override string casting for Objects and add an Object.to_string() method.

I have tried every which way I can to find any existing reference to this Issue, but I can't find an Issue or PR that mentions it, despite believing I'd seen one before. If this is a duplicate, just let me know and close it. Otherwise...
Issue description:
It is extremely inconvenient that users cannot customize the way in which the engine stringifies Objects. Many people see print(obj) and then wonder, "Okay, how can I control what that prints from my Object," like many other general-purpose languages do. And while it's true that GDScript isn't a general-purpose language, the fact that this possibility isn't available is still frustrating, especially when it isn't just about printing, but perhaps logging data to our own custom logging solutions using var2str() with any arbitrary Variant.
The current alternative available is just to write our own utility script class:
extends Reference
class_name Util
static func to_string(p_var):
    if typeof(p_var) == TYPE_OBJECT and p_var.has_method("to_string"):
        return p_var.to_string():
    return var2str(p_var)

But this then makes any code shared between projects reliant on this simple Util method. If multiple people had to do this for projects, and then also shared plugins or assets that had debug information using something like this, we'd end up with competing codebases in the global namespace when all of this stuff should really be built into the engine core itself to begin with.
In my opinion, var2str(var) should really do what Util.to_string(var) is doing already. We should also be able to access this same content with both str(obj) and obj.to_string() (for other languages' sake, even if to_string() is not necessarily essential for GDScript with the str() global method).
WDYT?

I see var2str as a marshalling method, not only a way to print an object
I think things like print or str should look for a to_string() method and script should be able to override that method. I don't think the functionality of var2str should change since str2var is meant to convert the output back into a variant.
It seems like here
https://github.com/godotengine/godot/blob/92d317a0b08edfa42e5e2b79196b32a33d5209e8/core/variant.cpp#L1577
Is where we could get the script, see if it has a method of to_string and call it if it does.

I will give this a go and add this to Object::_bind_methods
BIND_VMETHOD(MethodInfo(Variant::STRING, "_to_string"));

does print(str(obj)) work?

@girng
print(obj) will work, the modification is to an internal method of converting a variant to a string.

This new PR I've made is better than the previous one. str(obj) calls obj.to_string(), and to_string can be overridden. For languages like C# that already have Object.ToString they can implement how the the Godot Object turns into a string pretty easily.
you can still do print(obj) and it'll call your to_string() function also

Fixed by #27886.


Change Log Level for Unmatched Selectors

what

The current log level for specified selector did not match any releases is too verbose (IMO)
Propose moving it to debug or warn log levels

2018/07/26 01:28:44 specified selector did not match any releases in helmfile.d/0610.kubernetes-dashboard.yaml

why

If you have a directory with a couple dozen helmfiles, selectors might not apply to most files
The fact that the selector did not match becomes noisy and is alarming to those unfamiliar

Good catch! I believe debug level would be enough, especially given we still get useful error when the selector did not match any releases in any helmfile.


MSH wrong version check

The last update 2.3.6 broke the reading of msh files created with Gmsh < 4.2 as it raises a ValueError at line 98 in msh_io/msh4_1.py
ValueError: not enough values to unpack (expected 1, got 0)
It seems that the line 7 in msh_io/main.py
versions = {"2": msh2, "4.0": msh4_0, "4.1": msh4_1, "4": msh4_1}
is not correct since the key "4" should be associated to the reader msh4_0 and not msh4_1.
On my different Gmsh versions, msh files exported by Gmsh 4.1.5 have 4 under $MeshFormat while files exported by Gmsh 4.2.2 have 4.1.

Go get 2.3.7.


python311Packages.cron-descriptor: 1.2.35 -> 1.4

Automatic update generated by nixpkgs-update tools. This update was made based on information from passthru.updateScript.
meta.description for python311Packages.cron-descriptor is: Library that converts cron expressions into human readable strings
meta.homepage for python311Packages.cron-descriptor is: https://github.com/Salamek/cron-descriptor
Updates performed

Ran passthru.UpdateScript

To inspect upstream changes
Impact
Checks done

built on NixOS
The tests defined in passthru.tests, if any, passed
found 1.4 with grep in /nix/store/c0fvgfs18mcvhpy68a4swqkbpiic0aj7-python3.11-cron_descriptor-1.4
found 1.4 in filename of file in /nix/store/c0fvgfs18mcvhpy68a4swqkbpiic0aj7-python3.11-cron_descriptor-1.4

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

6 total rebuild path(s)

6 package rebuild(s)

First fifty rebuilds by attrpath
apache-airflow
baserow
healthchecks
python311Packages.cron-descriptor
python311Packages.django-celery-beat
python312Packages.cron-descriptor

Instructions to test this update (click to expand)

Either download from Cachix:
nix-store -r /nix/store/c0fvgfs18mcvhpy68a4swqkbpiic0aj7-python3.11-cron_descriptor-1.4 \
  --option binary-caches 'https://cache.nixos.org/ https://nix-community.cachix.org/' \
  --option trusted-public-keys '
  nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=
  cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=
  '

(The Cachix cache is only trusted for this store-path realization.)
For the Cachix download to work, your user must be in the trusted-users list or you can use sudo since root is effectively trusted.
Or, build yourself:
nix-build -A python311Packages.cron-descriptor https://github.com/r-ryantm/nixpkgs/archive/b879f328b02e7d4fdcc7a6049e0750e74299639f.tar.gz

Or:
nix build github:r-ryantm/nixpkgs/b879f328b02e7d4fdcc7a6049e0750e74299639f#python311Packages.cron-descriptor

After you've downloaded or built it, look at the files and if there are any, run the binaries:
ls -la /nix/store/c0fvgfs18mcvhpy68a4swqkbpiic0aj7-python3.11-cron_descriptor-1.4
ls -la /nix/store/c0fvgfs18mcvhpy68a4swqkbpiic0aj7-python3.11-cron_descriptor-1.4/bin

Pre-merge build results
We have automatically built all packages that will get rebuilt due to
this change.
This gives evidence on whether the upgrade will break dependent packages.
Note sometimes packages show up as failed to build independent of the
change, simply because they are already broken on the target branch.
Result of nixpkgs-review run on x86_64-linux 1

3 packages failed to build:

apache-airflow
baserow
python311Packages.django-celery-beat

3 packages built:

healthchecks
python311Packages.cron-descriptor
python312Packages.cron-descriptor

Maintainer pings
cc @phaer for testing.

Result of nixpkgs-review pr 280845 run on x86_64-linux 1

2 packages failed to build:

apache-airflow
apache-airflow.dist

9 packages built:

baserow
baserow.dist
healthchecks
python311Packages.cron-descriptor
python311Packages.cron-descriptor.dist
python311Packages.django-celery-beat
python311Packages.django-celery-beat.dist
python312Packages.cron-descriptor
python312Packages.cron-descriptor.dist


Definitions not exported

Describe the bug
In my global-settings.jsonc file, I've specified a management group to target, let's call this ManagementGroupExample. This should include all policies from the child subscriptions or management groups. I'm able to get all the policy assignments just fine, but for the definitions, only the ones set on ManagementGroupExample are exported. If I take a copy of an existing policy definition that is scoped to a subscription, and then I scope this copy to ManagementGroupExample, then the export will include the definition. The definition is a custom one by the way.
I've looked at the functions in this module and it seems like the function New-EPACPolicyDefinition is the one used to generate the json. However, both this function and the function script (New-EPACPolicyDefinition.ps1) don't seem to be called by anything else.
Furthermore, under the RawDefinitions folder (found under export folder), I can see that the definitions I'm looking for are in there, but just not exported out into .jsonc format into the policyDefinitions folder.
To Reproduce
Just run Export-AzPolicyResources or Export-AzPolicyResources -DefinitionsRootFolder .\Definitions -OutputFolder Output
Expected behavior
All definitions starting at the target scope level, including the ones in the child subs and management group, should be exported
EPAC Version
10.1.9
Here's the output of my Powershell run:
===================================================================================================
Get scope tree for EPAC environment 'epac-prd' at root scope /managementGroups/mg-redacted
===================================================================================================
Retrieved 285 Resource Groups
Processing 285 Resource Groups...

Scope tree for EPAC environment 'epac-prd' at root scope /managementGroups/mg-redacted complete.
    Management groups = 12
    Subscriptions     = 23
    Resource groups   = 285

===================================================================================================
Get Policy Resources for EPAC environment 'epac-prd' at root scope /managementGroups/mg-redacted
===================================================================================================
Retrieved 1000 Policy definitions
Retrieved 2000 Policy definitions
Retrieved 3000 Policy definitions
Retrieved 3533 Policy definitions
Retrieved 130 Policy Set definitions
Retrieved 109 Policy Assignments
Retrieved 19 Role Assignments
Retrieved 548 Role Definitions
Retrieved 392 Policy Exemptions
Processing Exemptions for orphaned assignments

===================================================================================================
Policy Resources found for EPAC environment 'epac-prd' at root scope /managementGroups/mg-redacted
===================================================================================================

Policy counts:
    BuiltIn        = 3518
    Managed (4) by:
        This PaC   = 0
        Other PaC  = 0
        Unknown    = 4
    Inherited      = 0
    Excluded       = 0

Policy Set counts:
    BuiltIn        = 130
    Managed (0) by:
        This PaC   = 0
        Other PaC  = 0
        Unknown    = 0
    Inherited      = 0
    Excluded       = 0

Policy Assignment counts:
    Managed (98) by:
        This PaC              = 0
        Other PaC             = 0
        Unknown               = 60
        DfC Security Policies = 0
        DfC Defender Plans    = 38
    With identity             = 15
    Excluded                  = 0

Policy Exemptions:
    Managed (384) by:
        This PaC  = 0
        Other PaC = 0
        Unknown   = 384
    Orphaned      = 0
    Expired       = 8
    Excluded      = 0

Role Assignments:
    Principal Ids         = 7
    With Role Assignments = 7
    Role Assignments      = 19

===================================================================================================
Processing 4 Policies from EPAC environment 'epac-prd'
===================================================================================================

===================================================================================================
Processing 0 Policy Sets from EPAC environment 'epac-prd'
===================================================================================================

===================================================================================================
Collating 98 Policy Assignments from EPAC environment 'epac-prd'
===================================================================================================

===================================================================================================
Output Exemption list (384)
===================================================================================================

===================================================================================================
Output 384 active (not expired or orphaned) Exemptions for epac environment 'epac-prd'
===================================================================================================

===================================================================================================
Optimizing 22 Policy Assignment trees
===================================================================================================

===================================================================================================
Creating 22 Policy Assignment files
===================================================================================================

===================================================================================================
Creating Ownership CSV file
===================================================================================================

@chaoscreater - Please review the documentation and parameters section in Export-AzPolicyResources.ps1 to ensure you are using the correct parameters for your specific export.  In this case, it sounds like you will want to add -IncludeChildScopes but there may be other parameters in there that help you get the desired level of export.  Let me know how this works and I can investigate further if this switch doesn't work.

@chaoscreater - Please review the documentation and parameters section in Export-AzPolicyResources.ps1 to ensure you are using the correct parameters for your specific export. In this case, it sounds like you will want to add -IncludeChildScopes but there may be other parameters in there that help you get the desired level of export. Let me know how this works and I can investigate further if this switch doesn't work.

Thanks. It seems like the newer versions after 1.1.3 have changed the output. It used to contain the definitions, but now the jsonc just shows this:

{
"$schema": "https://raw.githubusercontent.com/Azure/enterprise-azure-policy-as-code/main/Schemas/policy-definition-schema.json"
}

Is there another parameter I need to output the definition contents?

@chaoscreater - Please review the documentation and parameters section in Export-AzPolicyResources.ps1 to ensure you are using the correct parameters for your specific export. In this case, it sounds like you will want to add -IncludeChildScopes but there may be other parameters in there that help you get the desired level of export. Let me know how this works and I can investigate further if this switch doesn't work.

Thanks. It seems like the newer versions after 1.1.3 have changed the output. It used to contain the definitions, but now the jsonc just shows this:

{
"$schema": "https://raw.githubusercontent.com/Azure/enterprise-azure-policy-as-code/main/Schemas/policy-definition-schema.json"
}

Is there another parameter I need to output the definition contents?

I'm also seeing this issue
Watching ""

@chaoscreater @a8ree - I think I've found the bug and a fix.  Running some test now and should have a fix in today.

@chaoscreater @a8ree - I think I've found the bug and a fix.  Running some test now and should have a fix in today.

Thanks, running ok for me now


Initial implementation of runtime

The runtime provides command run() methods with common tools such as
logger, reporter and various clients. This change will allow removing a
lot of boilerplate from the various commands and make refactoring them
simpler as extracting methods will require fewer parameters.
@vkareh @pvasant @oriAdler @zvikorn WDYT?
I'd be happy for any suggestions on better naming, if we want this level of flexibility or if we should initialize all the clients for all commands anyways, and if you think this approach makes sense. If we agree on this direction i'll follow up with a cleanup of all the other commands (right now added just a couple to show the impact).
SDA-6207

@tbrisker I like the runtime idea. I'm wondering if we can do lazy components though. For example:
r := rosa.NewRuntime()
cluster, err := r.OCM().GetCluster()

then inside the module
func (r *Runtime) OCM() *ocm.Client {
  if r.ocm == nil {
    r.ocm = ocm.CreateNewClientOrExit(r.Logger, r.Reporter)
    defer r.ocm.Close()
  }
  return r.ocm
}

Thoughts?

@vkareh lazy init could work for aws but not for ocm client which requires the defered cleanup. Unfortunately go doesn't have a "destructor" concept. Is the initialization of the clients expensive enough that it's worth making it lazy?

Then let's avoid the lazy init and back to what you had originally :)

rebased on top of https://github.com/openshift/rosa/pull/741 and fixed issues, other PR can go in first or this one can be merged and the other one closed.

LGTM

@tbrisker you have a separate PR for the Simplify logger package commit - do you plan on removing it from this PR?

Added a few more commands and split between the runtime and the command migration. Would be good if we can get this in after 1.2.3 is released and then we can open separate PRs for migrating various commands instead of having one gigantic PR that migrates all of them and is impossible to review.

/lgtm


Language Localisations

I'd love to provide German Translations for devRantron.

Excellent idea! Although, I need to change the internal structure a little bit as I never thought about language localisation. Give me couple of days to setup the structure and I will give you shout.

Id be willing to do Swedish :)


[v2.7] Add CIS-1.8 (k8s v1.26) Scan capability

Backport of https://github.com/rancher/rancher/issues/43159
CIS Workbench has released CIS-1.8 for k8s v1.26 (on oct 6th).
This issue is pending the creation of cis-1.8 in kube-bench's cfg. We will start integrating CIS-1.8 to Rancher cis-benchmark once the profile will be made available upstream.
Past issue for CIS-1.7 : https://github.com/rancher/rancher/issues/41631

Validated on rancher v.27-head with CIS chart version 4.3.0-rc4:
Fresh install checks :

Provisioned k8s v1.26 hardened and non-hardened RKE1, RKE2 and K3s clusters and ran cis 1.8 hardened as well as 1.8 permissive profile scan.

Upgrade checks :

Provisioned k8s v1.25 hardened and non-hardened RKE1, RKE2 and K3s clusters and then installed CIS 4.2.0 chart on all the clusters and ran scan using v1.7 profile.
Upgraded clusters to k8s v1.26 and then upgraded the chart to CIS 4.3.0-rc4 version.
Ran CIS 1.8 hardened as well as 1.8 permissive profile scan.

Local cluster checks :

Created hardened and non-hardened k8s v1.26 RKE1, RKE2 and K3s clusters and ran CIS 1.8 hardened as well as permissive profile scans.

Result:

All scan passed except below ones, which are expected and will be release noted:

One failure in RKE1 hardened cluster:

Mixed
4.1.7	Ensure that the certificate authorities file permissions are set to 600 or more restrictive (Automated)

Failures in RKE2 clusters:

Fail
1.1.1	Ensure that the API server pod specification file permissions are set to 600 or more restrictive (Automated)
Fail
1.1.3	Ensure that the controller manager pod specification file permissions are set to 600 or more restrictive (Automated)
Fail
1.1.5	Ensure that the scheduler pod specification file permissions are set to 600 or more restrictive (Automated)
Fail
1.1.7	Ensure that the etcd pod specification file permissions are set to 600 or more restrictive (Automated)


Nodata issue

I am trying to display an elevation dataset, but it seems pyvista-xarray somehow uses the nodata value as the minimum value to render the data, making it look like a long vertical column. Is it possible to specify a minimum value to prevent pyxarray from using the nodata value for rendering?
import rioxarray

da = rioxarray.open_rasterio("madison.tif")
da = da.rio.reproject("EPSG:3857")

# Grab the mesh object for use with PyVista
mesh = da[dict(band=0)].pyvista.mesh(x="x", y="y")

# plot in 3D
mesh.warp_by_scalar().plot()

Rendering the original lidar point cloud
import leafmap
leafmap.view_lidar('madison.las', cmap='terrain')

The minimum and maximum values of the GeoTIFF are recognized by QGIS correctly. Not sure why pyxarray does not recognize them.

The minimum and maximum values of the GeoTIFF are recognized by QGIS correctly. Not sure why pyxarray does not recognize them.

The nodata value is in the metadata of the geotiff itself. If you have rioxarray installed, we could use that accessor to get the nodata value programmatically (as I do above)
This is actually a bit of a nuanced issue, and my exhausted brain doesn't have a great solution for you at the moment... the solution I provide in #35 has what could be serious side effects by modifying the data inplace or copying the values (converting int to float and thus blowing up memory usage for large datasets)

Thanks for looking into it. The issue seems a bit more complicated than I expected. da.rio.nodata can indeed get the nodata value. -32768.0 seems quite commonly used for nodata. Can we modify the GeoTIFF nodata value to zero or a value slighly smaller than the minimum value? This can potentially create new GeoTIFF that works with pvxarray. What I meant is to prepare an input file that will works with pvxarray rather than asking pvxarray to deal with such nodata issue.


Add syft packages sub command.

As an API author I would like to leverage syft to list packages so that the output can be used by API consumers.
AC
Add the following new command.
 syft packages [IMAGE-PATH]

Add a sub-command that mimics the behavior of the root command for listing packages.
The primary use case is to output json but keep existing flag options from the root command such as -o.
Keep the existing root command

Steps to Test

Analyze known sample image for known package content.
Test existing syft flags (e.g. -o)

Steps to Test Failures

Ensure that malformed inputs are handled correctly
Ensure that root commands remain functional
Ensure empty arguments are also handled correctly

This would be an ideal time to include CLI-level testing (assert the CLI behaves as it should)

this has been completed (a while ago, I think sometime Jan 2021)


Update production.mdx

Had to add DATABASE_URL to connect postgres to a railway service, so adding that in README

Ah, looks like Railway changed this. It used to provide DATABASE_URL automatically if you had a Postgres service in the same project.
Thanks a bunch!


[Bug]: Dates showing up incorrectly (might be timezone issue)

Relevant scope
event content
Description
All events are showing one day earlier than they actually are. Content files have the correct date in frontmatter, but no timestamp, and I'm on GMT-4, which is why I suspect timezones.

I can contribute the fix if that sounds good.

Hi, I just assigned you the task, it might be related to the timezone indeed: I released a really simple solution so far.


Add option to generate multiple charts for same target resource

Signed-off-by: Emruz Hossain<EMAIL_ADDRESS>

 Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.You have signed the CLA already but the status is still pending? Let us recheck it.


Add Bazel 0.3.0 support

This PRs adds Bazel 0.3.0 support.
Bazel 0.3.0 removes a lot of files from the Bazel binary in https://github.com/bazelbuild/bazel/commit/d91d047da35511487c4fcce6f5e438ba779a668b#diff-b6d6ae0d41e460758b3217d7fd82094c so we cannot use @bazel_tools//third_party/... for junit, mockito and joda any more. This PR just adds them to WORKSPACE as maven_jars to makes the project support both Bazel 0.2.3 and 0.3.0.

Please don't merge this PR until we verified this change also doesn't break Twitter's internal building environment for Heron.

@nlu90 - this PR works even with bazel 0.2.3 in my mac.

Yes, this one works with both Bazel 0.2.3 and 0.3.0.
I was working on #524 and found Brew had upgraded to Bazel 0.3.0. So I submitted this PR to unblock #524.

👍

@windie - now you could work on #524

@kramasamy @nlu90
Did we verify this change not to break Twitter's internal building environment for Heron?

@maosongfu - I verified with bazel 0.2.3 and it works. Essentially it works with both bazel 0.2.3 and bazel 0.3.0. In Twitter environment, we can continue to use bazel 0.2.3


DNR CPUE != our calculated CPUE

https://github.com/hkundel/CASC_Fish_Climate/blob/a5bf9980de13e2f67746b1c97389114d360fc231/Data_and_Scripts/Scripts/b_MN_Flat_File_Aggregation.Rmd#L145
DNR provide a calculated CPUE, but there are several instances where our calculated CPUE (using DNR provided catch and effort) do not equal what the DNR provided.

IN the individual fish file there is a field called CPUE (Y/N) and this is supposed to indicate whether or not the CPUE is N. Kelsey Vitense suggests that "Right way to compute CPUE is to remove raw data marked CPUE=N and use CPUE_INCLUDED for effort"


Perturbations incorrectly placed in documentation

poliastro_error.txt
🐞 Problem

🖥 Please paste the output of following commands
conda info -a
I do not use conda
python -c "import poliastro.testing; poliastro.testing.test()"
Does not show messages
pip freeze | grep astropy
astropy==3.0.3
pip freeze | grep poliastro
poliastro==0.11.dev0
🎯 Goal

💡 Possible solutions

📋  Steps to solve the problem

Comment below about what you've started working on.
Add, commit, push your changes
Submit a pull request and add this in comments - Addresses #<put issue number here>
Ask for a review in comments section of pull request
Celebrate your contribution to this project 🎉

This will be the correct way to import perturbations:
from poliastro.core.perturbations import J2_perturbation

This is a documentation bug, because I think the User Guide has the old perturbation imports.
Regarding the style thing, it's a warning (not an error) so I would not worry.

Thanks @tomdean1 for reporting!

I'm labeling this as "help wanted", so pull requests welcome. It's kind of important though, so if nobody does, I'll fix it next week.

a) I didn't fix it "the following week" and b) I duplicated this at #436, so I will rename this and close that.

Thanks @shreyasbapat!


Since v1.2.2, Closing a model after its connection is closed throws

This behavior is inconsistent with what the actual RabbitMQ client does.
Given this code:
var factory = new FakeConnectionFactory();
var connection = factory.CreateConnection();

var model = connection.CreateModel();
connection.Close();
model.Close();

the line model.Close() throws an AlreadyClosedException whereas, when the fake factory is replaced by RabbitMQ.Client.ConnectionFactory, no exception is thrown.
We should be consistent with RabbitMQ.Client's behavior.

Fixed in release v1.3.1


Error message: "llama.cpp error: 'done_getting_tensors: wrong number of tensors; expected 388, got 195'"

I  converted the model into the llama.cpp's own format (.GGUF). And this model could run successful in colab like snapshot.

But when i loaded this model in LLM Studio or Jan, i got error message. Anyone met this problem? How to resolve this?

Many thanks!

Likely a duplicated of my opening issue #22

See: https://github.com/ggerganov/llama.cpp/pull/5638

@datquocnguyen Not working

Same issue

@001123 @churongcon Please could you try installing/compiling llama.cpp from this specific commit and then redo the conversion step (to create the .gguf file):
https://github.com/jordankanter/llama.cpp/tree/87a41f53ae3a01dde4c198df72cfb99ba2c9f586
git clone https://github.com/jordankanter/llama.cpp
git checkout 87a41f53ae3a01dde4c198df72cfb99ba2c9f586

@001123 @churongcon, please disregard my previous comment. I have found the reason. "llama.cpp" has been modified, resulting in a converted version of phogpt-4b being associated with 387 tensors, instead of the previous 388. To load it with the latest version of Studio, you can simply reconvert phogpt-4b using the latest "llama.cpp".

@001123 @churongcon please try https://huggingface.co/vinai/PhoGPT-4B-Chat-gguf


fix encoding errors for Thai localization files

Just as an FYI: nice - I saw this problem when I was trying to build previously. Glad you fixed it!


Add Not Show give error

Ad failed to load : 0
Failed to load rewarded ad, Error: LoadAdError(code: 0, domain: com.google.android.gms.ads, message: Unable to obtain a JavascriptEngine., responseInfo: ResponseInfo(responseId: null, mediationAdapterClassName: , adapterResponses: []))

Hi @DineshJat123
Based on the provided log, it looks similar to a known issue which is being tracked at https://github.com/googleads/googleads-mobile-flutter/issues/527.
Closing this issue in favor of that issue. Please follow it for further updates.


collectd, failed to write batch: timeout

I have about 18 instances of collectd sending data to the collectd listener of InfluxDB, and for the first couple minutes everything seems to run fine until the following message starts to appear.
[collectd] 2015/06/30 20:46:08 failed to write batch: timeout

Far as I can tell, as soon as that shows up, queries for data just hang.
-- Once the 'failed to write batch' messages start, queries like this just hang
SELECT max(value) FROM "sensors_value" WHERE type = 'temperature' AND time > now() - 1h GROUP BY time(1m), host ORDER BY asc

-- However this works without issue the entire time
SHOW TAG KEYS FROM cpu_value

versions
Linux hostname 4.0.6-1-ARCH #1 SMP PREEMPT Tue Jun 23 14:25:08 CEST 2015 x86_64 GNU/Linux
influxdb - git master - a2bf480
grafana - git master - a38a06a
collectd - 5.5.0
I happen to be running zfs root as well, but far as I can tell that shouldn't be an issue.
log (after restarting influxdb)
using configuration at: /etc/influxdb.conf
2015/06/30 20:39:00 [INFO] raft: Node at <IP_ADDRESS>:8088 [Follower] entering Follower state
2015/06/30 20:39:00 read local node id: 1
[shard] 2015/06/30 20:39:01 flush 17981 points in 0.577s
[shard] 2015/06/30 20:39:01 flush 17528 points in 0.567s
2015/06/30 20:39:01 [WARN] raft: Heartbeat timeout reached, starting election
2015/06/30 20:39:01 [INFO] raft: Node at <IP_ADDRESS>:8088 [Candidate] entering Candidate state
2015/06/30 20:39:01 [DEBUG] raft: Votes needed: 1
2015/06/30 20:39:01 [DEBUG] raft: Vote granted. Tally: 1
2015/06/30 20:39:01 [INFO] raft: Election won. Tally: 1
2015/06/30 20:39:01 [INFO] raft: Node at <IP_ADDRESS>:8088 [Leader] entering Leader state
2015/06/30 20:39:01 [INFO] raft: Disabling EnableSingleNode (bootstrap)
2015/06/30 20:39:01 [DEBUG] raft: Node <IP_ADDRESS>:8088 updated peer set (2): [<IP_ADDRESS>:8088]
2015/06/30 20:39:01 [DEBUG] raft: Node <IP_ADDRESS>:8088 updated peer set (2): [<IP_ADDRESS>:8088]
2015/06/30 20:39:01 [DEBUG] raft: Node <IP_ADDRESS>:8088 updated peer set (2): [<IP_ADDRESS>:8088]
2015/06/30 20:39:01 [DEBUG] raft: Node <IP_ADDRESS>:8088 updated peer set (2): [<IP_ADDRESS>:8088]
2015/06/30 20:39:01 [DEBUG] raft: Node <IP_ADDRESS>:8088 updated peer set (2): [<IP_ADDRESS>:8088]
[shard] 2015/06/30 20:39:02 flush 16957 points in 0.524s
[shard] 2015/06/30 20:39:02 flush 17782 points in 0.410s
[shard] 2015/06/30 20:39:03 flush 17500 points in 0.506s
[shard] 2015/06/30 20:39:04 flush 17917 points in 0.547s
[shard] 2015/06/30 20:39:04 flush 17831 points in 0.505s
[shard] 2015/06/30 20:39:04 flush 812 points in 0.026s
[shard] 2015/06/30 20:39:05 flush 99 points in 0.019s
[shard] 2015/06/30 20:39:05 flush 650 points in 0.042s
[shard] 2015/06/30 20:39:05 flush 1126 points in 0.028s
[shard] 2015/06/30 20:39:05 flush 574 points in 0.032s
[shard] 2015/06/30 20:39:05 flush 578 points in 0.037s
[shard] 2015/06/30 20:39:05 flush 692 points in 0.049s
[shard] 2015/06/30 20:39:05 flush 1104 points in 0.041s
[httpd] 2015/06/30 20:39:05 listening on HTTP: [::]:8086
[collectd] 2015/06/30 20:39:05 collectd UDP started
[udp] 2015/06/30 20:39:05 Started listening on :2054
2015/06/30 20:39:05 InfluxDB starting, version 0.9, commit unknown
2015/06/30 20:39:05 GOMAXPROCS set to 8
2015/06/30 20:39:06 Sending anonymous usage statistics to m.influxdb.com
[collectd] 2015/06/30 20:46:08 failed to write batch: timeout
[collectd] 2015/06/30 20:46:13 failed to write batch: timeout
[collectd] 2015/06/30 20:46:18 failed to write batch: timeout
[collectd] 2015/06/30 20:46:23 failed to write batch: timeout
[collectd] 2015/06/30 20:46:28 failed to write batch: timeout
[collectd] 2015/06/30 20:46:33 failed to write batch: timeout
[collectd] 2015/06/30 20:46:38 failed to write batch: timeout
[collectd] 2015/06/30 20:46:43 failed to write batch: timeout
    <snip>
[collectd] 2015/06/30 21:08:45 failed to write batch: timeout
[collectd] 2015/06/30 21:08:50 failed to write batch: timeout
[collectd] 2015/06/30 21:08:55 failed to write batch: timeout
[retention] 2015/06/30 21:08:57 retention policy enforcement check commencing
[retention] 2015/06/30 21:08:57 retention policy shard deletion check commencing
[shard] 2015/06/30 21:08:58 flush 725 points in 0.028s
[shard] 2015/06/30 21:08:58 flush 117 points in 0.015s
[shard] 2015/06/30 21:08:58 flush 452 points in 0.018s
[shard] 2015/06/30 21:08:58 flush 1060 points in 0.019s
[shard] 2015/06/30 21:08:58 flush 489 points in 0.025s
[shard] 2015/06/30 21:08:58 flush 538 points in 0.017s
[shard] 2015/06/30 21:08:58 flush 479 points in 0.017s
[shard] 2015/06/30 21:08:59 flush 1008 points in 0.023s
[collectd] 2015/06/30 21:09:00 failed to write batch: timeout
[collectd] 2015/06/30 21:09:05 failed to write batch: timeout
[collectd] 2015/06/30 21:09:10 failed to write batch: timeout
[collectd] 2015/06/30 21:09:15 failed to write batch: timeout
    <snip>

/etc/influxdb.conf
reporting-disabled = false

[meta]
  dir = "/var/lib/influxdb/meta"
  hostname = "localhost"
  bind-address = ":8088"
  retention-autocreate = true
  election-timeout = "1s"
  heartbeat-timeout = "1s"
  leader-lease-timeout = "500ms"
  commit-timeout = "50ms"

[data]
  dir = "/var/lib/influxdb/data"

[cluster]
  shard-writer-timeout = "5s"

[retention]
  enabled = true
  check-interval = "10m"

[admin]
  enabled = true
  bind-address = ":8083"

[http]
  enabled = true
  bind-address = ":8086"
  auth-enabled = false
  log-enabled = false
  write-tracing = false
  pprof-enabled = false

[collectd]
  enabled = true
  bind-address = ":2100"
  database = "collectd"
  typesdb = "/etc/collectd/types.db"
  batch-size = 512
  batch-timeout = "30s"

[udp]
  enabled = true
  bind-address = ":2054"
  database = "udp"
  batch-size = 1024
  batch-timeout = "10s"

[monitoring]
  enabled = true
  write-interval = "24h"

[continuous_queries]
  enabled = true
  recompute-previous-n = 2
  recompute-no-older-than = "10m"
  compute-runs-per-interval = 10
  compute-no-more-than = "2m"

[hinted-handoff]
  enabled = true
  dir = "/var/lib/influxdb/hh"
  max-size =<PHONE_NUMBER>
  max-age = "168h"
  retry-rate-limit = 0
  retry-interval = "1s"

/etc/collectd.conf
TypesDB "/etc/collectd/types.db"
Interval 30

LoadPlugin syslog

<Plugin syslog>
    LogLevel warning
</Plugin>

LoadPlugin battery
LoadPlugin cpu
LoadPlugin df
LoadPlugin disk
LoadPlugin entropy
LoadPlugin interface
LoadPlugin irq
LoadPlugin load
LoadPlugin memory
LoadPlugin network
LoadPlugin processes
LoadPlugin sensors
LoadPlugin swap
LoadPlugin users

<Plugin "cpu">
  ReportByState true
  ReportByCpu true
  ValuesPercentage true
</Plugin>

<Plugin "network">
    Server "<IP_ADDRESS>" "2100"
</Plugin>

Thanks for the report @jasonrm
@jwilder -- would increasing the shard timeout help? Not as a solution, but to understand this issue better?

@otoolep Possibly.  It's currently 5s but should probably be configurable.  https://github.com/influxdb/influxdb/blob/master/cluster/points_writer.go#L17
If it's a single node, that means that a local write is taking longer than 5s to write a batch.  If it's in a cluster, all the nodes took longer than 5s to write.  The shard flushes look like they are happening pretty quickly so I wonder if something is getting deadlocked.

I've had InfluxDB stop accepting writes a couple of times in as many days now, testing on a single node.
Logs here, I killed it to produce a stack trace.

@pdf -- are you using collectd input? If not, how are you writing data into the system?

TSDB, as indicated by the logs.  Is this likely input-specific?  I figured it was likely something on the back of the retention policies stopping the world.

I didn't check the logs yet, and quickly wanted to understand if you were also working with collectd.
Retention policy enforcement is designed not to be an issue, and even then the only shards that affected are those that are older than the retention period of the policy. Of course, there could always be a bug. Are you writing data into the past?

Can you describe what writing data into the past entails?  I'd surmise it's possible for multiple clients to send data to the same measurement that preceeds the timestamp on a record that's already been sent - this seems like something that would be difficult to prevent with multiple writers.  In this case, I'm sending metrics via scollector from the bosun project.

By "writing into the past" I mean writing data that has timestamps
(significantly) earlier than now. For example, writing data with timestamps
representing yesterday. If the target retention policy is, say, 6 hours it
would mean you would be creating data in the system that would be deleted
almost immediately.
Philip
On Wed, Jul 1, 2015 at 9:24 PM, Peter Fern<EMAIL_ADDRESS>wrote:

Can you describe what writing data into the past entails? I'd surmise it's
possible for multiple clients to send data to the same measurement that
preceeds the timestamp on a record that's already been sent - this seems
like something that would be difficult to prevent with multiple writers. In
this case, I'm sending metrics via scollector from the bosun project.
—
Reply to this email directly or view it on GitHub
https://github.com/influxdb/influxdb/issues/3199#issuecomment-117868372.

Gotcha, nothing like that sort of period - we'd be looking at seconds out of order rather than hours.

https://github.com/influxdb/influxdb/issues/3214 also reported that the system either hung when under write load. There are also messages in the logs regarding retention enforcement.
Retention enforcement runs, by default, every 10 minutes, so it will be source of much logging. It may be co-incidental that both logs contain messages about retention when the problem happens. It may not be. I'm running some tests this morning to see if I can bring out any issues related to retention enforcement.

My naive guess would be that #3214 is different (2GB RAM total, OOM-killed, maybe?), but I did note that the retention logs appeared immediately before the consistent timeouts on both occasions I encountered them.  This certainly could be coincidence though.  Is there something more useful I can do than cause a stack-trace if I encounter it again?

@pdf -- what are you retention policy settings? Did you create a retention policy yourself?
If you have the disk space, you could disable retention policy enforcement, and see if your system runs for longer. You can re-enable retention enforcement at any time (it will require a restart) which will then delete any old data. The configuration to change is this line here:
https://github.com/influxdb/influxdb/blob/master/etc/config.sample.toml#L54
Set it to false, and you should see no more log messages about it. This isn't a fix, but it might allow us to rule out retention enforcement as a factor.

I altered the default retention policy to 30d.  If I can reproduce the error again, I'll disable retention enforcement then, since I'll be moderately certain that it's likely to occur regularly.  I might have just hit two flukes in quick succession, so disabling it now may not really tell us anything - smells like a race or something similarly nasty to track down.

Thanks @pdf -- that may be sufficient. Let me know if you continue to see the issue.

Still seeing failed to write point batch to database with both graphite and collectd. I've set retention enabled = false and running 2b2cc3c. Usually it only takes about one-two minutes before I start to see the errors after I restart the service. iostat shows disk util to be under 10% and all the influxd processes are usually in the sleeping state.
I am able to use a PHP library to send data to the udp listener without issue.
I've poked around with perf a bit, but haven't seen anything that really jumps out at me.

@jasonrm -- we just released 0.9.1, which has new timeout configuration options. You could try increasing this setting: https://github.com/influxdb/influxdb/blob/master/etc/config.sample.toml#L41 though 2 seconds may be sufficient (it is 100ms in the code you are running now). We don't consider this a "fix" per se, but is part of our work towards improving write throughput.

@jasonrm -- do let us know if this improves anything.

Sorry, forgot to include that I had updated my config to include the new timeout configuration options. At both 2 and 15 seconds I still would get the error within one to two minutes after a restart.
I hadn't noticed it before, but queries to the database I use for the udp listener don't hang.

OK, well at least we know the issue you are seeing @jasonrm is not related to retention enforcement -- thanks.

@jasonrm -- there are two other timing controls you should try to change. I'm not saying these are the "fix" but it may allow us to understand better what is happening within your system.
https://github.com/influxdb/influxdb/blob/master/etc/config.sample.toml#L51
https://github.com/influxdb/influxdb/blob/master/etc/config.sample.toml#L52
The second is only in master right now, either build from source or pull down a nightly build in about a day or so.
https://influxdb.com/download/index.html
Try bumping each to, say, 30 seconds. That should be plenty long enough for the data to get through your system, assuming it's not a total lock-up due to a bug.
What are your data rates like? 18 machines sending out data every 30 seconds is probably not huge.

I'm almost sure at this point that it is only triggered by a query, something similar to https://groups.google.com/forum/#!topic/influxdb/H11ivieFPG4
I can run this query without issue,
-- works
SELECT mean(value) FROM "dbi" WHERE type = 'order_payment_method' AND time > now() - 6h GROUP BY time(1h), type_instance ORDER BY asc

however, change mean to difference (or anything that isn't a valid function) and within seconds I start to see the failed to write point batch errors.
-- breaks
SELECT difference(value) FROM "dbi" WHERE type = 'order_payment_method' AND time > now() - 6h GROUP BY time(1h), type_instance ORDER BY asc

Does the problematic query return?

In the admin UI i get back Server returned error: function not found: "difference"

I'm pretty sure difference isn't wired up yet - see #1825.

I think I was running into #2685, where trying to call any function that doesn't exist results in the database being locked (or something that has similar appearance).

OK, if this is a query-related issue, I'll take a look. Much of the query code is being re-written at the moment.

Having spent some more time on this, it does look like invalid queries are causing the database to be locked in my case too.

Hello,
I can trigger this bug using a "mode" query for example (from grafana)
[http] 2015/07/10 14:27:36 <IP_ADDRESS> - - [10/Jul/2015:14:27:36 +0200] GET /query?db=graphite&epoch=ms&p=zzzzz&q=SELECT+mode%28value%29+FROM+%22count%22+WHERExxxx 5.376143ms
[graphite] 2015/07/10 14:27:46 failed to write point batch to database "graphite": timeout
[graphite] 2015/07/10 14:27:51 failed to write point batch to database "graphite": timeout
I am using nightly builld : "InfluxDB starting, version 0.9.1-rc1-111-g8b67872, commit 8b67872d6bd1013d455e3b12af3e79b24d78bf0d"
Regards
Olivier

@olivierHa -- any chance you can use the "developer" functionality of your browser to show the actual request that Grafana is making to InfluxDB?

The query is :
SELECT mode(value) FROM "count" WHERE provider = 'XXX' AND time > now() - 1h GROUP BY time(10s), api ORDER BY asc
I also can reproduce the issue using the influxdb cli with the same query :
The return is : ERR: function not found: "mode"
Using Grafana :
{"results":[{"error":"function not found: "mode""}]}
In both case, I got the "failed to write to point batch timeout"
Regards
Olivier

Major changes the write and query paths in 0.9.3 as well as better plugin support. Please let us know if these issues still happen with 0.9.3 installed.


Prefilled form for linear stepper doesn't allow one to click on all steps

Bug, feature request, or proposal:
Feature request
What is the expected behavior?
A linear stepper whose associated form is populated using patchValue or setValue and is valid should allow you to click on any of the steps right away.
What is the current behavior?
I have to keep pressing the "next" button as I am restricted to clicking on steps I have visited and the one immediately after.
What are the steps to reproduce?

Create a linear stepper with > 3 steps
Associate the stepper with a form and each step with a form group
Programmatically patch the value of the form groups associated with the steps to a valid state
Not all steps on the stepper are clickable even though the form and the groups are valid

What is the use-case or motivation for changing an existing behavior?
Saving the user's progress for a long form and returning them to the step they left off on.
Which versions of Angular, Material, OS, TypeScript, browsers are affected?
I'm on Angular 5.2.3, Angular Material 5.2, MacOS, TS 2.4.2.

Also having this problem in Angular 6.0.1, Material 6.0.2, TS 2.7.2.  It was working as @MrSnappingTurtle and I expected in version 2.0.0-beta.12 however.
This issue makes the stepper only usable in "create" mode and not "edit" mode.  Which is to say it's not very usable as a UI component at all when [linear]="true".  We're making the move to upgrade to 6.0, but this issue is making me have to rethink our whole UX around our forms.
Is there anything I can do to help get this fixed?

So it looks like this was changed on purpose to fix 8667 in commit PR 10048.
To me this seems like the wrong solution to the problem.  In the case that was made for #8667, the example was a prefilled out billing address form, which would be considered valid and thus not require the user to visit that step.  In my view, the fix to that problems is to add a new form-control to the billing address form that is tantamount to a required "I acknowledge" checkbox, not to change the mat-stepper behavior and have it make distinctions about whether the form is really valid.
The tie to "stepControl" or "completed" is the right one.  If a consumer of this library needs to have edge-case logic about what completed actually means, it should be done by them through the "stepControl" or "completed" interface.
Maybe a middleground solution is to allow for "completed" to be either a boolean or a (CdkStepper) => boolean that can be called to determine any special edge-case behavior like the example in 8667?

Any thoughts on this?  Would a PR be wanted?

@andymockli Given that this was assigned p4 priority, I don't think we'll get a response any time soon.

any update on this one? I have hit this issue as well and would be great to hear if there has been any progress on this .. linear stepper is pretty useless to me otherwise.

Facing the  same issue while developing an update form. Badly looking to fix this without going to handle the buttons by myself just to ensure maintainability.

A temporary workaround for this might be like this:
HTML:
<mat-horizontal-stepper  #stepper **(animationDone)="setAllMatStepsAsInteracted()"** linear>
.
.
.
</mat-horizontal-stepper>

TypeScript:
  @ViewChild('stepper') formStepper: MatStepper;
setAllMatStepsAsInteracted(){
  this.formStepper.steps.forEach((matStep : CdkStep)=>{
    matStep.interacted=true;
  });
}

Note 1: we might decide to check for the validity of each step before u set the stepper as interacted(completely fail safe)
Note 2 : Using the completed instead of interacted also works.

Closing this because, as far as I can tell, it is working as expected. The linear property explicitly means that that users need to move through the steps in order. Furthermore, you can set the completed state of a step directly if prefilling the data counts as completed in your app.


fix derive column stats for 'expr and A is not null' (#37235)

pick from #37235
the algorithm for computing stats for "expr1 and expr2" predicate is as following:

compute output stats of expr1 based on input stats. the result stats is denoted by leftStats
compute stats of expr2 based on leftStats after step1, leftStats should be normalized to avoid abnormal cases, such as ndv > rowCount or numNulls > rowCount

Issue Number: close #xxx

Proposed changes
Issue Number: close #xxx

run buildall

run buildall

run buildall


S46 40% firmware

Hi,
I bought the SAM40 from https://notfromsam.com/products/s46-custom-kit and there is information on Discord that I can get the open source firmware. Do you have a link?
I only found the json (https://github.com/Oh-My-Mechanical-Keyboard/yAndrKeyboardFirmware/blob/main/configs/keyboards/yandrstudio/ble/sam40/info-via-sam40ble.json)
Kind regards

TinyUF2 Bootloader 0.5.2-dirty - st/cmsis_device_f4 (v2.6.4-1-g2615e86) st/stm32f4xx_hal_driver (v1.7.9) tinyusb (0.10.1-109-g9b3ec69b)
Model: YR_STUDIO KB_FM
Board-ID: YRKB_UPDATE

Looks like it's here: https://github.com/Oh-My-Mechanical-Keyboard/qmk_firmware/tree/y_and_r_kb_pool/keyboards/yandrstudio/ble/sam40


BQL parser leaks a goroutine.

gw:
When parsing large integer (>= 2^63), the parser leaks a goroutine due to peg. The leaked goroutine is https://github.com/sensorbee/sensorbee/blob/bffc8059fd9e4dbf156543c8c369ce7277da6a25/bql/parser/bql.peg.go#L936. The parser stops to read the channel s after attempting to parse large integer, so the goroutine may block forever. Both of the sender and the receiver are generated by peg.

The generated code (linked in the above comment ) is improved on new PEG library and the new generated code is merged with #132 , so close this issue. When a similar problem is occurred, please create a new issue.


Persist environments in localStorage

With this PR, we enable the back office to store the user's environments in the browser's localStorage.
This PR is set as WIP because I need to know if I'm lowering the coverage or not.

Current coverage is 86.33% (diff: 86.20%)

Merging #133 into develop will increase coverage by 0.05%

@@            develop       #133   diff @@
==========================================
  Files           116        116
  Lines          1924       1947    +23
  Methods          57         57
  Messages          0          0
  Branches        147        147
==========================================
+ Hits           1660       1681    +21
- Misses          210        212     +2
  Partials         54         54

Powered by Codecov. Last update d50fa36...34074f9


[Feature Request]: Create read more page for blog data fetched by backend

Is there an existing feature request for this?

[X] I have searched the existing feature requests

Describe the feature you would like to request

What problem does this feature solve?
when blog are too big it is not good to show all content on blog page
if blog is big then turn cate it and there should be a read more page where we show full content of blog !!
this data has been fetched by BACKEND
Alternative solutions
No response
Confirmation

[X] I have read the Bitbox Contributing Guidelines
[X] I am a GSSOC-EXT contributor
[X] I am a HACKTOBERFEST contributor
[X] I have starred the Bitbox repository
[X] I would like to help implement this feature

Hyy @Sawan-Kushwah, I'm assigning this issue to you.


Restrict numeric workarounds to ROCm GPUs

Updates and restricts numeric workarounds to ROCm GPUs.
As an aside, how important is it that the softmax operation be in torch.float32 precision (e.g., compared to being autocast to bfloat16)? I ask because for large (5000+ atom) inputs, float32 precision requires 30GB or more of GPU memory to compute this softmax when using several diffusion_num_augmentations.

@amorehead hey, i think bfloat16 is acceptable, let me make that casting customizable.
this precaution was done for float16

@amorehead man, you are truly in the wild west

Tell me about it

@amorehead hey, i think bfloat16 is acceptable, let me make that casting customizable.
this precaution was done for float16

On my side, I just removed the dtype=torch.float32 bit in attention.py so that torch's AMP package can decide which precision to use there.

@amorehead yup that works, i just made it customizable in the latest version, and defaulted the casting to off


GPU_PrimitiveBatch issue

Jonathan,
I'm having trouble using GPU_PrimitiveBatch. My intention is to draw a series of line segments with current color. I make a call with:
GPU_PrimitiveBatch( NULL, target, GPU_LINE_STRIP, 5, floatPointsPackedAsXY, 5, uShortIndexes, GPU_BATCH_XY )
and it crashes in get_complete_mod_color, because I'm simultaneously not supplying image, and not using colors. I don't need per-vertex color, or texture. I'd like to use a single color to render this shape. I tried supplying a dummy image param, but then it just draws triangles.
Please hlep.

By stepping through code, and temporarily patching get_complete_mod_color I arrived to actual rendering inside PrimitiveBatchV in Renderer_GL_Common.inl:
if(indices == NULL)
            glDrawArrays(GL_TRIANGLES, 0, num_indices);
        else
            glDrawElements(GL_TRIANGLES, num_indices, GL_UNSIGNED_SHORT, (void*)0);

As you see, it's always drawing triangles, not the specified primitive. Is this simply unfinished? I'm going to try and plug in the primitive from parameter here. I assume this should be fixed in main branch.

For my purposes, it would be perfectly acceptable to use GPU_Polygon, to draw a line strip (with thickness), if GPU_Polygon had another parameter that let me specify if I want to close this polygon, or keep it open (line strip). 👍

Could you take a look at my commit, please?

Yep, these are good thoughts.  Thanks for your work on this!  (other discussion on merge thread)


Autocomplete form fields

Would Amy benefit from installing ajax autocomplete for specific form fields - for example, when selecting a user for a new task.
https://pypi.python.org/pypi/django-ajax-selects
https://github.com/crucialfelix/django-ajax-selects/

On Thu, Mar 19, 2015 at 08:39:33PM -0700, Nick Young wrote:

Would Amy benefit from installing ajax autocomplete for specific
form fields - for example, when selecting a user for a new task.

That sounds reasonable.  How does task-selection work now?  There are
few enough roles that selecting the role with Django's stock select
should work fine, but picking a from an event page or an event from a
person page would probably benefit from this approach.  I'd wait for
more folks to chime in before diving into the implementation though.

+1 to doing this now for fields with a small number of fixed values
(tasks, badges) - we can extend to larger things (users, events) later.

I've worked a good-bit with django-selectable, and find it works really well and is simple to integrate. Used it extensively with django-crispy-forms as well so I don't think there are any conflicts. Very few changes to the html templates; otherwise it's as simple as customizing the widgets used in the forms, and creating "lookups" which define an AJAX request and a queryset.
Docs: http://django-selectable.readthedocs.org/en/v0.9.X/quick-start.html
I would generally implement in any cases where there are FK or M2M fields with greater than 30 or so options; these are the fields I identified from just scanning the source

InstructorsForm.airport
Person.airport
Event.tags, Event.site in admin
Task in admin (event, person, likely not role as there aren't too many options)

Want me to give it a go?

Hey @shapiromatron!
django-selectable looks really nice and I'd love to see it in Amy. However, I don't want you to start working on it yet, because we have #234 and #242 blocking (and I'd rather you avoided unnecessary rebasing).
By the way, do you perhaps have any links on how to use django-selectable and django-crispy-forms and class based views altogether? I hope we won't have to write a ModelForm for every Create and UpdateView we have.
Cheers,
Piotr

Great, I'll wait for you to merge before starting.
Here's an example from my own project of how to integrate, using the EffectTag as an example. My project is overly complicated as I was learning as I went, but you can see the general steps with this example:

Add lookup(s) to register an AJAX search for a model or model-field:
https://github.com/shapiromatron/hawc/blob/master/project/assessment/lookups.py#L12

Override original field on forms.py to make a selectable field:
https://github.com/shapiromatron/hawc/blob/master/project/assessment/forms.py#L117

In the template, add a few html-tags and requirements:
https://github.com/shapiromatron/hawc/blob/master/project/templates/assessment/effecttag_form.html#L4

The AJAX URLs are automatically-created when adding the package to settings, so no mods to views.py or urls.py are required.

But to answer your question, yes, in order to use the autocomplete/selectable magic, we'll likely need to add some additional ModelForms.

Hey @shapiromatron,
#234 and #242 are now merged, so you can start working on a better autocomplete features. Thanks!


Consider removing support for deprecated k8s APIs in service discovery

Proposal
Prometheus currently supports discovering the following roles with deprecated APIs:

discovery.k8s.io/v1beta1 of EndpointSlice, no longer served as of k8s 1.25
networking.k8s.io/v1beta1 of Ingress, no longer served as of k8s 1.22

Considering that k8s 1.22 is End of Life since 2022-12-08 and k8s 1.25 will be on 2023-10-28, it might be worth considering removing support for those, which will simplify the maintenance of the discovery code.
I haven't been able to find a policy that describes the supported k8s versions in Prometheus, would that also be something worth clarifying in the process?

I do not think it costs us a lot to maintain the code, and when new deprecations will come we might to rewite the code to handle them again. for me it's a no-cost to keep them as far as I see it.

It's actually making contributions in that area trickier. Take for example #12338: it took me some time to figure out why the code is the way it is in the first place (I hadn't looked at the SD bits ever before), and then fix each test twice. Similarly, any change to ingress/endpointslices data lookup will need to be duplicated.
Worth noting that the API is not just deprecated though: it's just gone from supported versions of k8s.
Re: deprecations: the ones that this issues refers to were not GA and as such the stability guarantees around them weren't very strong. networking.k8s.io/v1 Ingresses are GA for instance, and so them going away anytime soon is extremely unlikely. From the deprecation policy:

There are no current plans for a major version revision of Kubernetes that removes GA APIs.

Okay, I understand better your feedback and it's important to us. I will
carry this issue to the proper maintainer.
Le mar. 26 sept. 2023, 19:15, Mickaël Carl @.***> a
écrit :

It's actually making contributions in that area trickier. Take for example
#12338 https://github.com/prometheus/prometheus/pull/12338: it took me
some time to figure out why the code is the way it is in the first place (I
hadn't looked at the SD bits ever before), and then fix each test twice.
Similarly, any change to ingress/endpointslices data lookup will need to be
duplicated.
Worth noting that the API is not just deprecated though: it's just gone
from supported versions of k8s.
Re: deprecations: the ones that this issues refers to were not GA and as
such the stability guarantees around them weren't very strong.
networking.k8s.io/v1 Ingresses are GA for instance, and so them going
away anytime soon is extremely unlikely. From the deprecation policy
https://kubernetes.io/docs/reference/using-api/deprecation-policy/:
There are no current plans for a major version revision of Kubernetes that
removes GA APIs.
—
Reply to this email directly, view it on GitHub
https://github.com/prometheus/prometheus/issues/12884#issuecomment-1735961851,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AACHHJSQOVZVVOGWAPPSCHLX4MESVANCNFSM6AAAAAA5EBU2FA
.
You are receiving this because you commented.Message ID:
@.***>

Even though I wholeheartedly agree with you @mickael-carl, I unfortunately know lots of companies that are using versions as old as 1.20 fully supported by the respective provider, so if we break that compatibility we'll force them to be stranded on old Prometheus versions. I don't like it myself either, but I think for Prometheus it would be best to keep this support for another year or two.

Well, the nice thing is that this wouldn't break 1.20 compatibility, only some APIs that were already marked as deprecated at that time. The only thing that would be broken would be folks still using the v1beta1 version of ingresses and that's a pretty easy thing to fix right?

I see what you mean. What would the actual compatibility be then? As in the first version that serves the v1 APIs?

Ingress v1 has been available since k8s 1.19, which has deprecated the v1beta1 API as well, from the changelog:

Ingress and IngressClass resources have graduated to networking.k8s.io/v1. Ingress and IngressClass types in the extensions/v1beta1 and networking.k8s.io/v1beta1 API versions are deprecated and will no longer be served in 1.22+. Persisted objects can be accessed via the networking.k8s.io/v1 API.

hmm .. I'm inclined to agree with you, but what do you think of running a Twitter and Mastodon poll to gauge an indication of versions used?

@brancz while I wouldn't mind sending out such a survey, I actually wouldn't be able to, not having an account on any of those platforms 🙂 Additionally and fwiw (just to try and make my case a bit further), 1.29 just came out marking 10+ versions in a row for the availability of ingress v1, and the deprecation of ingress v1beta1. Similarly, it's now been 9 releases that EndpointSlice v1beta1 is deprecated.

Adding the "Prometheus 3.0" milestone since it could make sense for a new major version to drop deprecated APIs?

We discussed this at the dev summit today. There weren't many attendees, so take this with a grain of salt, but the general consensus was to drop the deprecated API with v3.
If anyone has issues with that, please comment here.

The change has been merged in the release-3.0 branch.


Would this package support CUDA hardware acceleration SDK, like NVEnc and NVDec back-end?

Hi,
FFmpeg is supposed to support NVIDIA CUDA CODEC SDK, please refer to https://developer.nvidia.com/FFmpeg
So I wonder whether this wrapper also support the GPU back-end encode and decode?
I believe it'll be extremely useful.
Thanks,

From the linked page:

… it’s simply a matter of compiling FFmpeg binary with the required support for NVIDIA libraries and using the resulting binaries to speed up video encoding/decoding.

So configuring ffmpeg with the nvidea libraries is the first requirement (the who to is also described on that page).
Then you need to choose the correct video codecs when actually encoding the video. The exact process it not yet perfectly clear to me. It seems you can use h264_cuvid to decode h264 streams into YUV and encode streams to h264 using h264_nvenc.

Check the official documentation on this provided by NVIDIA here. I would also love to have this feature especially since my Python application already uses CUDA.

Is the problem is solved?

at least till now... i dont know how to run it on gpu... otherwise i directly run os.system(ffmpeg)

cmd= ['ffmpeg','-hwaccel','cuda','-hwaccel_output_format','cuda']
(
ffmpeg
.input(in_path)
.output(out_path,vcodec=h264_nvenc)
.run(cmd)
)


Production MySQL not listing any data

Summary
I'm attempting to deploy openfga to production using the mysql datastore. I've been able to migrate the openfga tables, create store and authorization models. The problem is that I'm unable to list any stores. It's something I need within my code to find existing stores that I can attach to.
I can:

Create Stores
Create Authorization Models

I can't:

List stores
List authorization models

Once I run certain commands, I'm unable to use any list command on production mysql server.
When I use docker-compose, I am able to list the stores within my database, and list the authorization models.
How do I debug the problem?
Other data

How are you running OpenFGA? Docker and Binary
What datastore are you using? MySQL
Are you running OpenFGA with any configuration overrides or with any of the flags mentioned in openfga run --datastore-engine mysql --datastore-uri 'sc_xxx:exxx@tcp(10.xxx.xxx.xxx:3306)/sc_xxx?parseTime=true'?
Do you have any logs or traces that could help us debug the problem? Not yet.

Hi @kivo360! A couple of questions:

I've been able to migrate the openfga tables

Can you expand on this? Did you run openfga migrate to create the tables from scratch, or did you copy existing stores & models from another environment?

The problem is that I'm unable to list any stores

Do you get any errors or just empty responses?

I too am running into this issue, have created the tables with openfga migrate and everything seems to be working. I can create a store through the API quite happily and this does appear in the store table.
openfga-1  | 2024-02-19T12:30:35.127Z	INFO	grpc_req_complete	{"grpc_service": "openfga.v1.OpenFGAService", "grpc_method": "CreateStore", "grpc_type": "unary", "request_id": "16f0884f-5e6a-44c8-8f49-3a00395564b2", "user_agent": "GuzzleHttp/7", "raw_request": {"name":"teststore"}, "raw_response": {"id":"01HQ0NHFKAZNHBCP825S79SKM7","name":"teststore","created_at":"2024-02-19T12:30:35Z","updated_at":"2024-02-19T12:30:35Z"}, "peer.address": "<IP_ADDRESS>:56214", "grpc_code": 0}

MariaDB [upipuma]> select * from store;
+----------------------------+-----------+---------------------+---------------------+---------------------+
| id                         | name      | created_at          | updated_at          | deleted_at          |
+----------------------------+-----------+---------------------+---------------------+---------------------+
| 01HQ0NHFKAZNHBCP825S79SKM7 | teststore | 2024-02-19 12:30:35 | 2024-02-19 12:30:35 | 0000-00-00 00:00:00 |
+----------------------------+-----------+---------------------+---------------------+---------------------+
1 row in set (0.00 sec)

However tying to list any stores gives me nothing back. I can't see any stores in the playground either.
openfga-1  | 2024-02-19T12:30:35.130Z	INFO	grpc_req_complete	{"grpc_service": "openfga.v1.OpenFGAService", "grpc_method": "ListStores", "grpc_type": "unary", "request_id": "b3ebc11f-f2da-4692-924d-ddd57bd5bc01", "user_agent": "GuzzleHttp/7", "raw_request": {"page_size":100,"continuation_token":""}, "raw_response": {"stores":[],"continuation_token":""}, "peer.address": "<IP_ADDRESS>:56214", "grpc_code": 0}

If I create an authorization model against that store id it creates successfully and I can see it in the list authorizations call just nothing coming back from listing the stores which is a bit of a key feature for me.
This all works perfectly fine when working in memory though, it's just the mysql engine.
Any advice would be appreciated.

Hi @asphytotalxtc! The issue in your case seems to be that deleted_at is set at  0000-00-00 00:00:00, but ListStores is looking for nil to find all the stores: https://github.com/openfga/openfga/blob/b1e0b5ed08b3a0ab22cd7605487972c21d7fe75a/pkg/storage/mysql/mysql.go#L566
My guess is that you don't have strict mode enabled: https://dev.mysql.com/doc/refman/8.0/en/sql-mode.html#sql-mode-strict

Strict mode affects whether the server permits '0000-00-00' as a valid date:

If strict mode is not enabled, '0000-00-00' is permitted and inserts produce no warning.

If strict mode is enabled, '0000-00-00' is not permitted and inserts produce an error, unless IGNORE is given as well. For INSERT IGNORE and UPDATE IGNORE, '0000-00-00' is permitted and inserts produce a warning.

Related: https://github.com/openfga/openfga/issues/449

This also happened to be a MariaDB problem. When I switched from MariaDB to MySQL the problem almost disappeared. I don't know why there's such a huge discrepancy between the two systems, however. The SQL in many test scripts didn't have any differences.
I have no experience with Golang.  I didn't have the chance to see what's wrong with the insertion logic between the two.

I wonder if there is something we can add in OpenFGA to throw an error if strict mode isn't enabled. Otherwise, this is a very sneaky bug...

Closing in favor of https://github.com/openfga/openfga/issues/1399

There is one relevant config that needs to check explicit_defaults_for_timestamp. This config needs to be set to ON. otherwise, the  MySQL/MariaDB will set timestamp to NOT NULL
https://mariadb.com/kb/en/server-system-variables/#explicit_defaults_for_timestamp


Language Analysis

Confirm whether to continue using Kotlin as the implementation language, or change to Java.

I think that the evidence presented within #16 and #19 provide good justification for the targeting of Kotlin for the implementation of this capability.

Kotlin work has so far been readable and I've been able to interpret it as a java programmer.
In our discussions we have talked about being able to adjust as we go should the code become too 'Kotlinic'. An eye will be kept on the ability of a java programmer to understand the code easily. With this in mind we are happy to continue using Kotlin and this issue can be closed.


ci: update tests workflow to use centralised reusable workflow and auto-suggest format changes

Follow up to #153.

Are the failures stemming from __solve(::NonlinearProblem, ::<SimpleNonlinearSolveAlg>) being removed in favor of ImmutableNonlinearProblem?

The current failure is just the depwarn https://github.com/JuliaGPU/GPUCompiler.jl/issues/616 ?

https://github.com/EnzymeAD/Enzyme.jl/blob/e1edaf7482dee3be5bcf35afb7527cea808a1f07/Project.toml#L39 doesn't support the latest GPUCompiler yet. I think LLVM 8 was the blocking issue there https://github.com/maleadt/LLVM.jl/issues/435 (cc @wsmoses)

(NOTE TO SELF) LuxTestUtils (https://github.com/SciML/DeepEquilibriumNetworks.jl/blob/de2c730e689e1de445c63e203e545a5725e58d04/Project.toml#L47) needs to be updated to the latest version

@wsmoses I thought you said v0.12.33 should do it? https://github.com/SciML/DeepEquilibriumNetworks.jl/actions/runs/10562146339/job/29259477769?pr=159#step:6:71

@avik-pal you got this as part of your other update?

yeah, I will merge that and then figure out the failure here.

Once https://github.com/SciML/DeepEquilibriumNetworks.jl/actions/runs/10675542556/job/29587688915?pr=159#step:6:950 is fixed the tests will pass


[CI run] Reserve the exact capacity in ToBits for BigIntegers

Hmm, I think I need to push the branch directly to the repo in order to trigger the CI; closing this one.


Fix for imgui 1.90 with IMGUI_DISABLE_OBSOLETE_FUNCTIONS

This PR contains fixes for imgui 1.90 when using the IMGUI_DISABLE_OBSOLETE_FUNCTIONS flag.
Associated discussions : https://github.com/SFML/imgui-sfml/issues/301
For this PR to be finalized, the minimum supported version will have to be updated from 1.89 to 1.90.
The supported versions with the flag enabled would range from 1.90 (November 2023) to 1.91.0 (July 2024)
To make the change on the CI settings and docs, I guess I should wait for the imgui_version branch to be merged back into the 2.6.x branch ?
PS: if several tests are implemented for different imgui targets, it could be interesting to also target the -docking tags associated with each imgui version.
(EDIT: not sure if anything could break on those branches though).

Oh, it seems that the changes are still compatible with 1.89.
I also just realized that the switch cases I modifed are no longer needed...
I will tweak that.

What do we gain by upgrading the minimum ImGui version for ImGui-SFML 2 besides the ability to remove more deprecated functions?

Upgrading the minimum version with the associated fixes could allow users to build with the more strict compilation flag, but I realize that maybe we are not many to do that and it's not worth it.
In that case you can wait for deprecation redirectors to disappear from imgui sources before migrating the code and the minimum version, it seems like those breakages are generally trivial to fix.
Concerning this PR, it appears that the changes are still compatible with 1.89, and would allow building with the deprecation flag from 1.89 to 1.91.0.
I will have to test with a gamepad that navigation still works properly.
For more details about API deprecation, I just realized that an exhaustive list exists at the beginning of imgui.cpp (look for "API BREAKING CHANGES" near line 430).

Concerning this PR, it appears that the changes are still compatible with 1.89, and would allow building with the deprecation flag from 1.89 to 1.91.0.

If we can remove the use of interfaces that exist in 1.89 but were deprecated later, I'm cool with that.

If/When you merge this PR, I invite you to update the imgui_version branch to include the 1.91.5 version tag.

Thanks!


token-swap js: Prepare package for npm

Run pretty properly
Add build:program like for spl-token
Add TypeScript to CI
snake_case -> camelCase variables
Combine transactions on swap initialization
Make instruction functions static

Please let me know if there are any other things required to get this package out.  I aimed to model this after the token package.

Do we just want to drop the flow binding?  I'm not opposed

🐫


autoloading not working

Autoloading is not working for class LanguageDetector on case sensitive file system, since the file is named languageDetector.php instead of LanguageDetector.php
This is fixed in https://github.com/nitotm/efficient-language-detector/pull/1

Yes, I noticed, not sure what happened, its correct on my local. Will push fix soon.

Fixed, should work now. Any other thing you can let me know.