Gradle Kotlin (Spring Boot) - languageVersion = JavaLanguageVersion.of(22) - Not working

Current Behavior
java {
	toolchain {
		languageVersion = JavaLanguageVersion.of(22)
	}
}

Produces:

[info] Java Home: C:\Users\.........\.vscode\extensions\redhat.java-1.33.0-win32-x64\jre\17.0.11-win32-x86_64
[info] JVM Args: --add-opens=java.base/java.util=ALL-UNNAMED,--add-opens=java.base/java.lang=ALL-UNNAMED,--add-opens=java.base/java.lang.invoke=ALL-UNNAMED,--add-opens=java.prefs/java.util.prefs=ALL-UNNAMED,--add-opens=java.base/java.nio.charset=ALL-UNNAMED,--add-opens=java.base/java.net=ALL-UNNAMED,--add-opens=java.base/java.util.concurrent.atomic=ALL-UNNAMED,-XX:MaxMetaspaceSize=384m,-XX:+HeapDumpOnOutOfMemoryError,-Xms256m,-Xmx512m,-Dfile.encoding=UTF-8,-Duser.country=ES,-Duser.language=es,-Duser.variant
[info] Gradle User Home: C:\Users\..........\.gradle
[info] Gradle Version: 8.8
[error] FAILURE: Build failed with an exception.

* What went wrong:
Could not resolve all dependencies for configuration ':compileClasspath'.
> Failed to calculate the value of task ':compileJava' property 'javaCompiler'.
   > Cannot find a Java installation on your machine matching this tasks requirements: {languageVersion=22, vendor=any, implementation=vendor-specific} for WINDOWS on x86_64.
      > No locally installed toolchains match and toolchain download repositories have not been configured.

* Try:
> Learn more about toolchain auto-detection at https://docs.gradle.org/8.8/userguide/toolchains.html#sec:auto_detection.
> Learn more about toolchain repositories at https://docs.gradle.org/8.8/userguide/toolchains.html#sub:download_repositories.
> Run with --stacktrace option to get the stack trace.
> Run with --info or --debug option to get more log output.
> Run with --scan to get full insights.
> Get more help at https://help.gradle.org.

CONFIGURE FAILED in 1s
[error] [gradle-server] The supplied build action failed with an exception.
[error] Error getting build for d:\.................. The supplied build action failed with an exception.
[info] Found 0 tasks

Expected Behavior
java {
	toolchain {
		languageVersion = JavaLanguageVersion.of(21)
	}
}

CONFIGURE SUCCESSFUL in 1s
[info] Found 40 tasks
Steps to Reproduce

Download the project at https://start.spring.io/

Version project Spring Boot: 3.3.2
Language: Java
Java version: 22
Gradle kotlin == Gradle kotlin dsl

From VSC you modify something or simply update and it gives an error in version 22
languageVersion = JavaLanguageVersion.of(22)

Gradle version
https://start.spring.io/ - 3.3.2 spring boot
Environment
Windows
JAVA_HOME => D:...........\Java\jdk-22.0.1

Note: The Spring Boot parent project does not seem to be able to have version 22. But the Spring Boot modules/microservices/child projects can. But once the parent includes them with: include("module1, module n+1) the modules/microservices/children can no longer have version 22.
So we have:

SpringBoot parent: cannot have version 22 but can have version 21

SpringBoot module/microservice/child: can have version 22

When the parent links with include("child/microservice/child") then the child cannot have version 22 and we are left with

SpringBoot parent: version 21

SpringBoot module/microservice/child: version 21

If you try another version it will give an error.

https://github.com/gradle/gradle/issues/30214

I could be wrong but I'm guessing if you run gradlew -q javaToolchains then you'll get your jdk-22 listed with Detected by: Current JVM and that's the only way Gradle is detecting JDK22 and so compiling from the CLI.
From your logs, the VSCode extension is using C:\Users\.........\.vscode\extensions\redhat.java-1.33.0-win32-x64\jre\17.0.11-win32-x86_64 to run Gradle so it can no longer find the JDK22 as it's not the current JVM.
You could setup toolchain detection properly on your machine.  Then Gradle should be able to find JDK22 regardless of what JDK is being used to run Gradle.  That is suggested in the Gradle error message you've pasted and the weblinks are given.
Or you could try adding the VSCode setting "java.import.gradle.java.home": "D:\\your path here\\Java\\jdk-22.0.1".  Then the extension should run Gradle with that JDK and JDK22 should be found as a toolchain.

The Java Home C:\Users\.........\.vscode\extensions\redhat.java-1.33.0-win32-x64\jre\17.0.11-win32-x86_64 is used to launch the gradle server (the server providing all the related gradle features)
And the gradle daemon should have the capability to detect the jdk it needs. Where is your jdk 22 installed? I opened this project in my machine and cannot reproduce it

This is my gradle:
[plugins {
java
id("org.springframework.boot") version "3.3.3"
id("io.spring.dependency-management") version "1.1.6"
}
group = "com.........."
version = "0.0.1-SNAPSHOT"
// java {
// 	toolchain {
// 		languageVersion = JavaLanguageVersion.of(21)
// 	}
// }
repositories {
mavenCentral()
}
dependencies {
implementation("org.springframework.boot:spring-boot-starter")
testImplementation("org.springframework.boot:spring-boot-starter-test")
testRuntimeOnly("org.junit.platform:junit-platform-launcher")
}
// tasks.withType {
// 	useJUnitPlatform()
// }
subprojects{
apply(plugin="java")
apply(plugin="org.springframework.boot")
apply(plugin="io.spring.dependency-management")
group = "com.wammo"
version = "0.0.1-SNAPSHOT"

java {
    toolchain {
        languageVersion = JavaLanguageVersion.of(22)
    }
}
configurations {
    compileOnly {
        extendsFrom(configurations.annotationProcessor.get())
    }
}
repositories {
    mavenCentral()
}

dependencies {

    implementation("org.springframework.boot:spring-boot-starter-web")
    testImplementation("org.springframework.boot:spring-boot-starter-test")

    // implementation("org.springframework.boot:spring-boot-starter-security")
    // testImplementation("org.springframework.security:spring-security-test")

    developmentOnly("org.springframework.boot:spring-boot-devtools")

    compileOnly("org.projectlombok:lombok")
    annotationProcessor("org.projectlombok:lombok")

}

 tasks.withType<JavaCompile>().configureEach {

    options.compilerArgs.add("-parameters")
}

// En las pruebas de integración necesitan los parámetros.

// tasks.withType<Test> {
//     useJUnitPlatform()
// }

}](url)
This is my gradle, with multiple microservices.
I have it in modules because if I have to update any dependency I do it in cascade instead of going project by project and wasting time.
I have downloaded the project again from spring boot init and it is still the same.

gradlew -q javaToolchains:

It does detect version 22. But it's like it doesn't want to detect it.

This is my gradle:
plugins {
    java
    id("org.springframework.boot") version "3.3.3"
    id("io.spring.dependency-management") version "1.1.6"
}

group = "com......"

version = "0.0.1-SNAPSHOT"

java { toolchain { languageVersion = JavaLanguageVersion.of(21) } }

repositories { mavenCentral() }

dependencies {
    implementation("org.springframework.boot:spring-boot-starter")
    testImplementation("org.springframework.boot:spring-boot-starter-test")
    testRuntimeOnly("org.junit.platform:junit-platform-launcher")
}

// tasks.withType<Test> {
// 	useJUnitPlatform()
// }

subprojects {
    apply(plugin = "java")
    apply(plugin = "org.springframework.boot")
    apply(plugin = "io.spring.dependency-management")

    group = "com......"
    version = "0.0.1-SNAPSHOT"

    java { toolchain { languageVersion = JavaLanguageVersion.of(21) } }
    configurations { compileOnly { extendsFrom(configurations.annotationProcessor.get()) } }
    repositories { mavenCentral() }

    dependencies {
        implementation("org.springframework.boot:spring-boot-starter-web")
        testImplementation("org.springframework.boot:spring-boot-starter-test")

        // implementation("org.springframework.boot:spring-boot-starter-security")
        // testImplementation("org.springframework.security:spring-security-test")

        developmentOnly("org.springframework.boot:spring-boot-devtools")

        compileOnly("org.projectlombok:lombok")
        annotationProcessor("org.projectlombok:lombok")
    }

    tasks.withType<JavaCompile>().configureEach { options.compilerArgs.add("-parameters") }

    // En las pruebas de integración necesitan los parámetros.

    // tasks.withType<Test> {
    //     useJUnitPlatform()
    // }
}

This is my gradle, with multiple microservices.
I have it in modules because if I have to update any dependency I do it in cascade instead of going project by project and wasting time.
I have downloaded the project again from spring boot init and it is still the same.

gradlew -q javaToolchains:

It does detect version 22. But it's like it doesn't want to detect it.

This is my gradle:
plugins {
	java
	id("org.springframework.boot") version "3.3.3"
	id("io.spring.dependency-management") version "1.1.6"
}

group = "com......"
version = "0.0.1-SNAPSHOT"

java {
	toolchain {
		languageVersion = JavaLanguageVersion.of(21)
	}
}

repositories {
	mavenCentral()
}

dependencies {
	implementation("org.springframework.boot:spring-boot-starter")
	testImplementation("org.springframework.boot:spring-boot-starter-test")
	testRuntimeOnly("org.junit.platform:junit-platform-launcher")
}

// tasks.withType<Test> {
// 	useJUnitPlatform()
// }

subprojects{
    apply(plugin="java")
    apply(plugin="org.springframework.boot")
    apply(plugin="io.spring.dependency-management")

    group = "com........"
    version = "0.0.1-SNAPSHOT"

    java {
        toolchain {
            languageVersion = JavaLanguageVersion.of(21)
        }
    }
    configurations {
        compileOnly {
            extendsFrom(configurations.annotationProcessor.get())
        }
    }
    repositories {
        mavenCentral()
    }

    dependencies {

        implementation("org.springframework.boot:spring-boot-starter-web")
        testImplementation("org.springframework.boot:spring-boot-starter-test")

        // implementation("org.springframework.boot:spring-boot-starter-security")
        // testImplementation("org.springframework.security:spring-security-test")

        developmentOnly("org.springframework.boot:spring-boot-devtools")

        compileOnly("org.projectlombok:lombok")
        annotationProcessor("org.projectlombok:lombok")

    }

     tasks.withType<JavaCompile>().configureEach {

        options.compilerArgs.add("-parameters")
    }

    // En las pruebas de integración necesitan los parámetros.

    // tasks.withType<Test> {
    //     useJUnitPlatform()
    // }
}

This is my gradle, with multiple microservices.
I have it in modules because if I have to update any dependency I do it in cascade instead of going project by project and wasting time. Then each project will have its specific dependencies apart from the Java version itself, some dependencies, tests and others...
I have downloaded the project again from spring boot init and it is still the same.

**gradlew -q javaToolchains:**

It does detect version 22. But it's like it doesn't want to detect it.

Have you tried set java.import.gradle.java.home to java 22?

Yes I am using it. But it's no use.

You missed the "java" part.
It's java.import.gradle.java.home not java.import.gradle.home
:)

You are right. It seems to be working fine now. Thank you very much. That fixes the problem. Why do you have to manually tell it?

I do not have a concrete answer for now. Sometime the gradle cli behavior may different from the gradle tooling api. But it also may related with the implementation of the gradle task server in this extension.
Anyway, good to know the issue is addressed.


Cloning fails on Windows 10

Receive the following when cloning via git bash on Windows 10
$ git clone https://github.com/in28minutes/spring-microservices.git Cloning into 'spring-microservices'... remote: Enumerating objects: 937, done. remote: Total 937 (delta 0), reused 0 (delta 0), pack-reused 937 Receiving objects: 100% (937/937), 90.94 MiB | 11.81 MiB/s, done. Resolving deltas: 100% (424/424), done. warning: unable to access '01.framework-introductions/jpa-in-10-steps/src/main/java/com/in28minutes/learning/jpa/jpain10steps/.gitattributes': Filename too long error: unable to create file 01.framework-introductions/jpa-in-10-steps/src/main/java/com/in28minutes/learning/jpa/jpain10steps/JpaIn10StepsApplication.java: Filename too long error: unable to create file 01.framework-introductions/jpa-in-10-steps/src/main/java/com/in28minutes/learning/jpa/jpain10steps/UserDaoServiceCommandLineRunner.java: Filename too long error: unable to create file 01.framework-introductions/jpa-in-10-steps/src/main/java/com/in28minutes/learning/jpa/jpain10steps/UserRepositoryCommandLineRunner.java: Filename too long fatal: cannot create directory at '01.framework-introductions/jpa-in-10-steps/src/main/java/com/in28minutes/learning/jpa/jpain10steps/entity': Filename too long warning: Clone succeeded, but checkout failed. You can inspect what was checked out with 'git status' and retry with 'git restore --source=HEAD :/' '

Can you try to checkout into a folder directly in c:?


Added 2 Games on C

Title and Issue number

Games Developed On C & issue #720
Close #720

Checklist:

[X] I have mentioned the issue number in my Pull Request.
[X] I have commented my code, particularly in hard-to-understand areas
[X] I have created a helpful and easy to understand README.md

C codes are not accept led, only c code with frontend will be accepted


feat: don't upscale images

This PR prevents us from resizing images to larger than the source. Instead we can let next/image do the resizing in the browser. Rather than returning the max size image, we instead redirect to the image that is the correct size. This is to avoid having multiple URLs that all refer to the same image, which the browser will potentially download multiple times.
Demo page. The image is displayed at twice the source size. Open the image in a new tab and you'll see it has redirected to the smaller size

npm ERR! @netlify/routing-local-proxy-darwin-x64 not accessible from netlify-cli:@netlify/routing-local-proxy
pain


Add OnValueChange prop to Select Component

🚀 Feature Proposal
It would be nice if there was an onValueChange prop for the Select Component as this will allow updating the selectedOption when there is a stateChange on the selectedOption value.
Currently, there is only an onSelect prop which updates the selectedOption when the user selects the option manually.

Removed select form my screens because I need to clear all the fields.

@matheuszenker what do you mean with clear?

@jobinmatt can you please also provide an example code of what you're trying to achieve? Seems like I couldn't catch your idea for the proper implementation

One of the issues that I was having was that the select component's selectedOption property (selectedOption={this.state.selected}) would not update(the selected option that is displayed by the component) when the selected state variable(this.state.selected) was updated by some other code(this.setState({selected: 'some value'})).


Names must match /^[_a-zA-Z][_a-zA-Z0-9]*$/ but "" does not.

After upgrading from 3.0.0-beta.14 to 3.1.4 i'm getting this error.
Missing onError handler for invocation 'extracting-queries', error was 'Error: Names must match /^[_a-zA-Z][_a-zA-Z0-9]*$/ but "test-app" does not.

Names must match /^[_a-zA-Z][_a-zA-Z0-9]*$/ but "test-app" does not.

I don't have any empty field names "" so not sure where this is coming from all of s sudden.
Is there an easier way to debug this as the error would seem to be telling me a GraphQL filed name is empty and not able to match the regex check but thats all the message is saying it doesn't tell me what file.
It doesn't tell me any exact file that might have the error in so its really difficult to debug ?
Ive seen this in the upgrade docs but still not sure as it doesn't seem like I have an invalid filed as far as empty "". https://github.com/angeloashmore/gatsby-source-prismic/tree/0be79841508c599eee8074b2db423d935b917168#graphql-valid-field-names

Closing this as the docs already discuss this in detail. Malformed graphql names was the issue here.
Thank you for the great docs for pointing this issue out.
https://github.com/angeloashmore/gatsby-source-prismic#GraphQL-valid-field-names

@chapster11 Glad you found a fix. I've come across the same issue where using Prismic's labels feature on rich text fields adds an empty "" field.
This is something that can be automatically detected and printed to the console. I'll keep this in mind when we do those improvements. 👍

@angeloashmore Just wondering, what is the workaround for the labels on rich text fields? Would it be as simple as updating the JSON to put something in the ""?

Hi @riceboyler, sorry, I haven't come across this issue in a while so I can't remember the actual error that appears. If you project is showing that now, do you mind posting a screenshot or copy of the output?
To resolve the issue until the plugin can handle it automatically, you can reformat the labels field manually. If I remember correctly, the labels field turns into something like this:
{
  "": {
    "my-label": "my-label"
  }
}

You should be able to change it to:
{
  "labels": ["my-label"]
}

I started migrating from the Prismic fork of the original plugin (@prismicio/gatsby-source-prismic-graphql) to this one on a project I inherited and came across this issue. Below is my error output.
Names must match /^[_a-zA-Z][_a-zA-Z0-9]*$/ but "" does not.

Names must match /^[_a-zA-Z][_a-zA-Z0-9]*$/ but "" does not.

Names must match /^[_a-zA-Z][_a-zA-Z0-9]*$/ but "" does not.

Names must match /^[_a-zA-Z][_a-zA-Z0-9]*$/ but "" does not.
    at assertValidSchema (/Users/andrey.drozd/Development/main-site/node_modules/graphql/type/validate.js:73:11)
    at validate (/Users/andrey.drozd/Development/main-site/node_modules/graphql/validation/validate.js:54:35)
    at extractOperations (/Users/andrey.drozd/Development/main-site/node_modules/gatsby/src/query/query-compiler.js:212:20)
    at processQueries (/Users/andrey.drozd/Development/main-site/node_modules/gatsby/src/query/query-compiler.js:171:45)
    at compile (/Users/andrey.drozd/Development/main-site/node_modules/gatsby/src/query/query-compiler.js:82:19)
    at updateStateAndRunQueries (/Users/andrey.drozd/Development/main-site/node_modules/gatsby/src/query/query-watcher.ts:220:40)
    at extractQueries (/Users/andrey.drozd/Development/main-site/node_modules/gatsby/src/services/extract-queries.ts:18:3)'
⢀ extract queries from components

It is indeed from labels on Rich Text Fields. I confirmed this by digging into the node_modules and console logging around some of the code from the stacktrace.
Did Prismic change its API for labels and that's why this is an issue for older projects? Because I have something like the below:
"text_block": {
                "type": "StructuredText",
                "config": {
                  "multi": "paragraph, preformatted, heading1, heading2, heading3, heading4, heading5, heading6, strong, em, hyperlink, image, embed, list-item, o-list-item, o-list-item",
                  "label": "Text block",
                  "labels": {
                    "": [
                      {
                        "name": "color-red"
                      }
                    ]
                  }
                }
              },

but it should be as @angeloashmore states above. Below is an example from Prismic docs on labels (https://user-guides.prismic.io/en/articles/1943308-add-custom-styles-to-rich-text)
"page-body": {
  "type": "StructuredText",
  "config": {
    "label": "Page Body",
    "placeholder": "Enter your text...",
    "labels": ["right-align", "center-align"]
  }
}


[SP-643] feature: update ueberauth_intercom dependencies

@danielkaram Please, update the changelog and version as well! Thanks!


609 dashboard updates

The Problem

The Solution

Checklist:

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

It could be that im not fully understanding what some of these changes are doing for the dashboard, but I don't think that logic like this should live on the frontend (and also it seems like there is duplicate logic between the dashboard and the admin endpoints)

That was bo and/or rahul, I’m not sure what those changes are doing
On Mon, Dec 16 2019 at 6:57 PM, <<EMAIL_ADDRESS>> wrote:

It could be that im not fully understanding what some of these changes are
doing for the dashboard, but I don't think that logic like this should
live on the frontend (and also it seems like there is duplicate logic
between the dashboard and the admin endpoints)
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub (
https://github.com/ConnextProject/indra/pull/647?email_source=notifications&email_token=AIR5IWCE6X5MFS42WHNHA5TQZAIW5A5CNFSM4J3KNXEKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEHAR7UI#issuecomment-566304721
) , or unsubscribe (
https://github.com/notifications/unsubscribe-auth/AIR5IWACDFRVFZYWFHOAMH3QZAIW5ANCNFSM4J3KNXEA
).

That was bo and/or rahul, I’m not sure what those changes are doing

@bohendo @rhlsthrm any context im missing?

I added all that multisig scanner stuff. It was designed to be an in-depth scan for one multisig at a time so I didn't need the node's db. The tweak check way way faster client side so that's what I went with.
This copy of getCreate2Address is way more powerful than what's in cf-core utils, we might want to consider replacing that one with this one.
This copy of the multisig scanner also scans way more combinations of historical stuff than the node's so we might also want to replace the node's scanner w this one.. but I like the responsiveness & tweakableness of the client-side version so I'm not 100% sure I want to get rid of it from the dashboard entirely.. this might be something else we could incorporate into the cf-core utils & import into both the node & dashboard.


support withAWS assume role

Hi team,
Apologies if I have missed how to accomplish this, but it appears using Assume Role is not supported as the AWS_SESSION_TOKEN is not being sent with the request when specifying the awsAccessKey and awsSecretKeys?
Our CI server lives in account X and is assuming the cicd role in Account Y
I have confirmed that the permissions are all fine by printing out the keys/token and testing via the command line.
Can we add support for STS Assume roles?
Pipeline code below:
            withAWS(region: params.AWS_REGION, role: cicdRoleName, roleAccount: awsAccountId) {
                codeBuildResult = awsCodeBuild projectName: config.repoName,
                    region: params.AWS_REGION,
                    sourceControlType: 'project',
                    credentialsType: 'keys',
                    awsAccessKey: env.AWS_ACCESS_KEY_ID,
                    awsSecretKey: env.AWS_SECRET_ACCESS_KEY,
                    envVariables: "${codebuildEnvVars}"
            }

Jenkins Error:
[Pipeline] awsCodeBuild
00:00:12.128 [AWS CodeBuild Plugin] Using given AWS access and secret key for authorization
00:00:12.278 [AWS CodeBuild Plugin] The security token included in the request is invalid. (Service: AWSCodeBuild; Status Code: 400; Error Code: UnrecognizedClientException; Request ID: 36dab899-4f28-11e8-90d9-891f23967dfc)
[Pipeline] End of Pipeline

GitHub has been notified of this commit’s build result

CodeBuildException
	at CodeBuildStep$CodeBuildExecution.run(CodeBuildStep.java:286)
	at CodeBuildStep$CodeBuildExecution.run(CodeBuildStep.java:249)
	at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1$1.call(AbstractSynchronousNonBlockingStepExecution.java:47)
	at hudson.security.ACL.impersonate(ACL.java:260)
	at org.jenkinsci.plugins.workflow.steps.AbstractSynchronousNonBlockingStepExecution$1.run(AbstractSynchronousNonBlockingStepExecution.java:44)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)
Finished: FAILURE

Thanks for letting us know about this use case. Have you tried using a set of CodeBuild credentials? They have IAM Role support. Giving an option to manually specify the session token would integrate better with the withAWS syntax in your pipeline, however. I'll mark this as a feature request.

I haven't tried using the CodeBuild creds, We use federated IDP for user access and do not provision local IAM user.  Thanks for the quick reply we will implement a workaround in the mean time.

I didn't hear back from @b-b3rn4rd in the pull request, but I made a minor change and pushed it in 32f5a78e9db195e7a595a3f4b606d6c5931e5acf. Thanks for the feedback--I'm glad we could get this use case working.

@b-b3rn4rd @samdammers This change was released in version 0.25 of the plugin

Hi,
Seems like I'm having the same issue.
I thought you guys resolved it.
Or maybe I'm using "withAWS" wrong with your plugin?
                        withAWS(region: 'ap-southeast-2', role: 'CodeBuildWithJenkinsServiceRole', roleAccount: '123456789123', externalId: '123456-2c1a-4367-aa09-123456') {
                            sh 'aws ssm get-parameter --name "/github-codebuild/github/token"'
                            try {
                            cbResult = awsCodeBuild projectName: 'rds-for-pretokengen-lambda',
                                sourceControlType: 'project',
                                credentialsType: 'keys',
                                awsAccessKey: env.AWS_ACCESS_KEY_ID,
                                awsSecretKey: env.AWS_SECRET_ACCESS_KEY,
                                region: 'ap-southeast-2',
                                envVariables: '[ { GITHUB_OWNER, company }, { GITHUB_REPO, rds-for-pretokengen-lambda } ]',
                                artifactTypeOverride: 'S3',
                                artifactLocationOverride: 'githubcodebuild-artifacts',
                                overrideArtifactName: 'True'
                            } catch (Exception cbEx) {
                                cbResult = cbEx.getCodeBuildResult()
                            }
                        }

Getting this error:
[Pipeline] awsCodeBuild
[AWS CodeBuild Plugin] Using given AWS access and secret key for authorization
[AWS CodeBuild Plugin] The security token included in the request is invalid. (Service: AWSCodeBuild; Status Code: 400; Error Code: UnrecognizedClientException; Request ID: 361b1373-5638-41df-bddc-81dd53078beb; Proxy: )

So, essentially I'm running Jenkins master in  container on Fargate.
I've added the following perms to container's task role (I think that should suffice as those are exactly the same I've used in the User's attached poly - the user creds I've used to kick start Codebuild jobs) - Cloudformation style:
  ECSPassRoleCodebuild:
    Type: "AWS::IAM::ManagedPolicy"
    Properties:
      ManagedPolicyName: !Sub "${AWS::StackName}-passrole-codebuild"
      PolicyDocument:
        Version: '2012-10-17'
        Statement:
          - Sid: AllowPassRoleCodebuild
            Action:
              - "iam:PassRole"
            Effect: Allow
            Resource:
              - "*"

  ECSCodebuildPerms:
    Type: "AWS::IAM::ManagedPolicy"
    Properties:
      ManagedPolicyName: !Sub "${AWS::StackName}-codebuild-perms"
      PolicyDocument:
        Version: '2012-10-17'
        Statement:
          - Action:
              - "codebuild:StartBuild"
              - "codebuild:BatchGetBuilds"
              - "codebuild:BatchGetProjects"
            Effect: Allow
            Resource:
              - "arn:aws:codebuild:ap-southeast-2:123456789123:project/*"
          - Effect: Allow
            Resource:
              - "arn:aws:logs:ap-southeast-2:123456789123:log-group:/aws/codebuild/*:*"
              - "arn:aws:logs:ap-southeast-2:123456789123:log-group:/aws/codebuild/*"
            Action:
              - logs:GetLogEvents
              - logs:FilterLogEvents
          - Effect: Allow
            Resource:
              - "arn:aws:s3:::githubcodebuildartifacts"
            Action:
              - "s3:GetBucketVersioning"
          - Effect: Allow
            Resource:
              - "arn:aws:s3:::githubcodebuildartifacts/*"
            Action:
              - "s3:PutObject"
          - Effect: Allow
            Resource:
              - "arn:aws:s3:::githubcodebuildartifacts/*"
            Action:
              - "s3:GetObject"
          - Effect: Allow
            Resource:
              - "arn:aws:codebuild:ap-southeast-2:123456789123:project/*"
            Action:
              - "codebuild:StartBuild"
              - "codebuild:BatchGetBuilds"
              - "codebuild:BatchGetProjects"

I actually looked at the PR you've mentioned above(Just after I've finished writing the comment above) - https://github.com/jenkinsci/aws-codebuild-plugin/pull/8
And then figured that "awsSessionToken: env.AWS_SESSION_TOKEN" was missing.
Now it's working!
Thank you :)
Can you please document this config in the plugin description?
It was a pain to find the right config :(

Updated README a6c535575fd76f37a361099899cf13fca961af86


TestCaseJavaParser.java:54-56: Continue implementation of...

The puzzle 146-ff001db1 from #146 has to be resolved:
https://github.com/volodya-lombrozo/jtcop/blob/c0a06570d033fe8efb019dd2bee9736072fa9cfe/src/main/java/com/github/lombrozo/testnames/javaparser/TestCaseJavaParser.java#L54-L56
The puzzle was created by @rultor on 31-May-23.
Estimate: 90 minutes,  role: DEV.
If you have any technical questions, don't ask me, submit new tickets instead. The task will be "done" when the problem is fixed and the text of the puzzle is removed from the source code. Here is more about PDD and about me.

@0pdd 2 puzzles #151, #152 are still not solved.

@0pdd 2 puzzles #151, #155 are still not solved; solved: #152.

@0pdd 2 puzzles #151, #157 are still not solved; solved: #152, #155.

@0pdd 3 puzzles #151, #160, #161 are still not solved; solved: #152, #155, #157.

@0pdd 5 puzzles #151, #161, #164, #165, #166 are still not solved; solved: #152, #155, #157, #160.

@0pdd 4 puzzles #151, #161, #164, #166 are still not solved; solved: #152, #155, #157, #160, #165.

@0pdd 3 puzzles #151, #161, #164 are still not solved; solved: #152, #155, #157, #160, #165, #166.

@0pdd 4 puzzles #151, #161, #170, #171 are still not solved; solved: #152, #155, #157, #160, #164, #165, #166.

@0pdd 4 puzzles #151, #161, #171, #173 are still not solved; solved: #152, #155, #157, #160, #164, #165, #166, #170.

@0pdd 3 puzzles #151, #161, #171 are still not solved; solved: #152, #155, #157, #160, #164, #165, #166, #170, #173.

@0pdd 2 puzzles #151, #171 are still not solved; solved: #152, #155, #157, #160, #161, #164, #165, #166, #170, #173.

@0pdd the puzzle #151 is still not solved; solved: #152, #155, #157, #160, #161, #164, #165, #166, #170, #171, #173.


input and output data formats for fission functions

Is there somewhere a good description of ALL input and output data formats for fission functions?
I understand Fission functions can only be invoked based on events. If this happens, what kind of input data can be passed to functions (I assume by value only), what formats?Is the input data encoded in the event or is it separate data?I understand data streams can be input into Fission functions. Is any format accepted such as JSON, CSV, AVRO, binary and text format?Can I also input vidoes, images, data logs to Fission functions.I cannot find an single document for Fission that describes all options for input and output data for fission functions.Thanks for any hint

Hi @tfahringer - Fission functions themselves are agnostic of the data encoded in the body of the HTTP request.
For Workflows, there is a distinction between unstructured (blob) data and structured data.
Structured data is parsed, which makes it query-able in other tasks. This allows you to use expressions to reference subsets of the data { output('TaskA').myField }
Unstructured data is passed from outputs to inputs uninterpreted, as raw data. You cannot use expressions on it.
Upon receiving the response of a Fission function, the workflows checks the content-type whether it is structured data. The following formats are supported:

Structured data: application/json, text/plain, and some protobuf models specific to the workflow engine.
Unstructured data: everything else.

Indeed, this should be better documented! 🙂


cmake: build the final Jar when compiled with WITH_JNI

Unlike the Makefile, which builds a Jar with an embedded shared library (and without tests), the CMake code builds a Jar with the Java classes only (including some Java tests), which is somewhat unusable. Allow building the full Jar with the embedded shared library from CMake as well, and allow running the Java tests as well as part of the check target.
CMake's UseJava module supports adding resources since CMake 3.21, but we need to support CMake 3.12 for now, so we can't use that, which means that adding the shared library will need to be done using a custom command. Also, there's some weird dependency graph currently, because the JNI headers that librocksdbjni.so depends on are generated by the add_jar() command of the Java classes Jar, but we need librocksdbjni.so for creating the final Jar.

@speedbmike - please have a look


Check that deployment ready replicas greater than zero

There is a case where both ReadyReplicas and Replicas are 0
and the Eventually passes. Adding this to avoid this situation.
Signed-off-by: Ori Braunshtein<EMAIL_ADDRESS>

LGTM


Plex Kills

https://github.com/Notifiarr/website/issues/15
Per Nit "will still need both session & kill endpoints available"
https://discord.com/channels/764440599066574859/764441447445037086/837506117940412426

[[plex.ender.<username>]]
  idle_eps = 2       # number of episodes played without interaction
  days     = "12345" # 0 = sunday, 1 = monday, 6 = saturday
  times    = [       # 10pm - 2am
    "22-24",
    "0-2"
  ]


Standardize and stabilize outputs of wwinference() wrapper function

Goal
Before a first release (checklist here), we will want to make sure that the main model fitting wrapper function, wwinference() returns a stable set of contents. Right now, we are returning a post-processed draws dataframe + mappings to sites and labs, dates, and maps to the subpopulations.  We are also doing a diagnostic check internally within the wrapper function, while also showing the user how to do this from the stan fit object separately in the vignette.
I think it would be best that we don't mix post-processing and model fit at all, and instead write the wwinference() function such that it returns a nested list, ww_fit containing raw_stan_fit_obj, input_data, and stan_data_args. Only the first two will be used in downstream functions, but it might be helpful, similar to the passing around the input data, to pass around the inputs to the stan model (e.g. the priors) for comparing outputs with different priors.
From this, we would overload downstream functions to take in the ww_fit object and generate the draws dataframe, run the diagnostics, plot the results, and (eventually) evaluate the results. The main change from the current workflow right now would be to adjust get_draws_df() to take in the ww_fit object and remove the internal calls to get_draws_df() and get_model_diagnostic_flags()
The goal of all of this would be to 1 modularize the codebase so each function performs one step in the workflow, and 2 put the onus on us to demonstrate the workflow of the package step-by-step and the user to perform each action on the fitted model object.
Requirements

[ ] output the following elements from wwinference(): raw_stan_fit_obj, input_data  and stan_data_args. All will be lists. Optionally, we could separate the ww_data and hosp_data and pass back both as dataframes
[ ] rewrite get_draws_df() (perhaps rename to extract_posterior_draws()) to take in the ww_fit object as an output and return something that looks like draws_df() currently. Allow user to pass in args to only include certain variables among a set of allowed variables.
[ ] revise vignette to demonstrate each of these steps
[ ] add a mermaid diagram describing how the functions interact

@seabbs @gvegayon @dylanhmorris Curious any other thoughts here

Without fully understanding the details, I think the key here is leveraging S3 methods:

If it makes sense, I would reuse existing generic methods like plot and summary to provide post-processing information. You also have the coef, vcov, and confint generics you can use to allow the user to intuitively extract information from the model.
For functions like get_draws_df(), you can always write a generic method so the function may take a fitted model or something else, giving flexibility without much of a hurdle.
I would also try to lean on existing methods from other packages like stan itself.

@gvegayon I am currently writing a bunch of tests of the functions and thinking now would be a good time to do some of this since it will require reworking wwinference() and the post-processing a bit (so get_draws_df() and get_model_diagnostic_flags(). I'm going to start a new PR for this which will include tests for everything from fitting to post-processing. Might tag you if I have questions on how to do the function overloading/creation of the class attribute if that's ok!


pre-command and post-command runs in docker container

Currently if I create a pre-command or post-command it runs outside of my docker container.  Given that my test environment sits within docker, i would rather by default the hooks was run within the context of the same docker container my tests will run in.  This will give me the chance to run setup tasks like installing assets and post command like caching assets for the next build.
thx.

Sorry for the radio silence on this one, been pondering how this fits into future plans for the agent and for the docker-compose plugin.
I think that as it stands, the pre-command and post-command hooks need to be in the domain of the agent. Will talk over with the team where your suggestion might make sense.

I wrote this a while back and I think what you are saying makes sense.  Will close this one. Thanks!

We have come up with a need for this. The post-command hook needs some resources inside the docker container to run, and we don't want to install all these resources on the agent. Has anyone come up with a way to do this?


docs(ast): improve formatting of AstBuilder doc comments

#6757
#6756  👈
main

This stack of pull requests is managed by Graphite. Learn more about stacking.

Join @overlookmotel and the rest of your teammates on  Graphite

Only affects formatting of comments, so merging without review.


docs(admin-gui-auth) Added step by step directions

to @pd333's point, maybe just have the line earlier on that says key-auth is used in this example and link to the section with the other methods

I think we should call it "Admin GUI" here and update the doc when 34 is released. We haven't called it "Kong Manager" with customers; I can see them getting confused by the switch in terminology.

Customers are familiar with key-auth, I think it is a useful example to show. I do agree that I can add a "disclaimer" that other methods are available.


Ignore generated types

This changes two parts of the gql codegen process.
1.) Ignoring generated files
Originally the *.generated.ts files were committed so that CI could validate the types.
Now that we have a hosted API, we can pull them from there.
This does mean that local breaking changes on both the API & UI will not pass in CI now, but that was rarely, if ever the case. The API should strive to not have breaking changes anyways.
Benefits

Reduced clutter in commits
Reduced merge conflicts while rebasing
The gql-codegen process is much faster now, because we don't lint or prettify the generated files now

The only down side of this is not being able to see schema changes between commits/branches. But this is minor and available in other places.
2.) Schema Location
Previously we required devs to symlink the schema.grahql file from their local API folder.
Because this:

Allowed the frontend to use a schema modified in a working branch on the API
Allowed IDEs to use this schema file to autocomplete/validate our graphql documents

However, symlinks are gross and this prevented using a remote schema even though you could use a remote API.
Now

We pull the schema from the API
Which API is configured by .env files which gql-codegen now loads
gql-codegen generates a schema.graphql file for our IDEs/us to use

Caveats

The server process has to be running to generated types. Not a big deal.

Schema is baked at build time which means based on API being referenced the built package could change.

We do have a few generated things that are used at runtime (the fragment matcher and the type policies).
If anything this is more accurate as the package would be closer to what the API is serving.
If the API has breaking changes it could fail the build though.

LGTM!


The version of Apollo-master

What is the version of the Apollo-master now? Is it the same as Apollo-r5.5.0? And what is the different between Apollo-master and others?

Apollo master is the dev branch.


Splunk 9.3 breaks app

In Splunk 9.3, the python version setting defaults to Python 3.9. After upgrading I noticed git_for_splunk stopped working. I was getting the following error:
AttributeError: module 'time' has no attribute 'clock'
There are two references to time.clock() in input_module_gitforsplunk.py. I changed these to time.time() and the app appears to be working again.
I believe time.clock() was deprecated in Python 3.8 and the default Python version prior to Splunk 9.3 was Python 3.7. You can get around the default version setting as stated here https://docs.splunk.com/Documentation/Splunk/9.3.0/Python3Migration/ChangesEnterprise

Thank you for reporting this jackammerman. I have fixed it and put a new version on Splunkbase. Thanks again!


2.1 version bump and Gradle bump

Signed-off-by: Amit Galitzky<EMAIL_ADDRESS>Description
updated gradle version to 7.4.2 and OS version to 2.1
Issues Resolved
#578
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

Will need to wait for job-scheduler and common utils to upgrade for CI to pass

Current issue is due to incompatibility with core due to terminology change, it is tracked here: https://github.com/opensearch-project/OpenSearch/issues/3663


Docs: fix disallowMultipleSpaces invalid example

Fixes #1252

Coverage remained the same at 99.1% when pulling a326ea5489cec552022623fcda3f1ba5d68a89d5 on hzoo:patch-4 into da3cb064ed561a72b6abbe06507b56228c53ead2 on jscs-dev:master.

Merged, thank you


rework check and rename to proc

remove file action, normalize dependency paths

on hold until we merge history management.


Error messages can't get through

It seems that System.js somehow interferes with error messaging and blocks the actual error:

Steps to reproduce:

npm install react react-dom
Change app.js to code below
npm start

var React = require('react');
var ReactDOM = require('react-dom');

var o = { key: "value" };

Component = React.createElement("div", null,
    React.createElement("h1", null, o)
);

ReactDOM.render(Component, document.getElementById('map'));

I tried to set "production: false" in various places which seems to contain System.js config. Node process env as development didn't affect this. System.js seems to think its in production mode, but it still loads React libraries in non-minified pieces instead of one minified bundle.

node_modules/cbuild/process.js defines NODE_ENV as production, changing that to development shows the original error message. The stack trace could still be better though...

Latest cbuild in Github now has a -d flag. Adding it to the cbuild calls of package.json scripts in this repo will then fix the problem. I'll do some more testing before releasing the new cbuild to npm and then close this issue.
I just realized Chrome shows a decent stack trace from SystemJS if you click "..." instead of the down arrow.

It could automatically set the -d flag if your NODE_ENV environment variable equals development.

I'm not sure, but default with Webpack et al is development. This would make the initial experience better and provide more information. Only when (or if) moving to production are build scripts made for production.
Re: chrome dev tools: this explains why I got so different stack traces. I was sometimes clicking that (...) and sometimes somewhere else. It's possible, but pretty tedious to read React's error message this way.

I couldn't get the cbuild upgraded and working with the dev mode.
I removed npm's older cbuild and did npm install charto/cbuild. It brought down the newer version, but it's missing the dist folder and thus can't function at all.
Instead I cloned the cbuild repo and managed to get it working without the -d flag by having Atom compile it. With the -d flag in use I got this:
Build error:
{ [Error: Cannot find module 'cbuild/process-dev.js' from '/Users/jussiarpalahti/tmp/charto-map-frontend']
  cause: [Error: Cannot find module 'cbuild/process-dev.js' from '/Users/jussiarpalahti/tmp/charto-map-frontend'],
  isOperational: true }

I haven't made any JS packages myself, so I'm completely out in the woods with this.

Yes, now I got it. process-dev.js is same as process.js, but for development. I created it and ran bundle-reload. Now I get the correct error message. It seems the problem inducing statement in original source is lost. Though now I can't recall if these types of error messages worked correctly with Webpack or jspm...
Anyways, problem solved!

Fixed in charto/cbuild@9aacccf and released v0.0.6 on npm.


chore: turn off [Inhabited β] : Inhabited (Sum α β)

This would disable the instances for Inhabited (Sum α β) from Inhabited β, because this can easily result in non-defeq Inhabited instances by competing with the instance from the left-summand.
I'm not sure whether this is a good idea or not: people might be surprised that this instance is missing.
An alternative would be an instance [IsEmpty α] [Inhabited β] : Inhabited (Sum α β) that could only fire when the other instances couldn't. However this would either have to happen in Mathlib, or we'd need to move IsEmpty up to Lean.
See zulip discussion.

Closed in favour of #5284


[dv/otp_ctrl] Fix mem_rd_with_rand_reset_failure

This PR fixes the otp_ctrl_mem_rd_with_rand_reset issue. Previous change
on apply_resets_concurrently only intends to change
otp_ctrl_stress_all_with_rand_reset sequence, but it happens to apply
the change in all apply_resets_concurrently task.
Signed-off-by: Cindy Chen<EMAIL_ADDRESS>

Thanks Rupert for catching that! Let me update them.


Scrolling on Mobile isn’t great

Follow up to @eXponenta recent mobile PR #13
Scrolling the code is a poor experience in iOS (and maybe others) because the default page overflow/scroll behavior.  Would suggest not allowing the body to scroll and or using fixes to lock the whole view so that scrolling only happens in the code editor.

I doesn't have iOS device and i can not test on real devices.
In Browser Stack it works normal.
I tryed disable showing keyboard, but i don't have ideas how to do it.
Monocai editor there is poor support mobile devices in design.

Okay, I can try to work on this then.


File is not written if disk is full

@nhp wrote on slack

jetzt weiss ich warum das immer leer war: da meine platte voll war hat er nur von einem bruchteil der events auch das product-detail-json geschrieben.

So the product detail json is not written when disk is full. This should end in an exception

How can this be safely implemented?

File_put_contents returns bytes written, so we can check against the string length strlen()

What about other key-value store implementations? Checking each snippet write is an overhead.

The current problem is, that the disk is full. I expect from redis/varnish/... to take care of that themselves.

Closed via:

https://github.com/lizards-and-pumpkins/lib-search-engine-filesystem/issues/21
https://github.com/lizards-and-pumpkins/lib-key-value-store-filesystem/issues/47
https://github.com/lizards-and-pumpkins/lib-queue-backend-filesystem/issues/66


Pick the best or available overloaded signatures in Conditional types

This is not a bug but compiler can be good as this?
TypeScript Version:  2.7.0-dev.20180206

Search Terms:
Code
type Call<T extends () => any> = T extends (this: T) => infer R ? R : never;
type Cast<T> = Call<CastMap<T>>;
interface CastMap<T> extends AnyBaseToConsume<T> {
  (this: ThisType<true>): true;
  (this: ThisType<false>): false;
  (this: ThisType<boolean>): boolean;
  (this: ThisType<void>): void;
}

type A = Cast<true>;

Expected behavior:
A is true or boolean (as the result of true | boolean) or boolean | void.
In the case of Cast<true>, compiler shouldn't be able to infer R from (this: ThisType<false>): false; and (this: ThisType<void>): void;. They will never be callable. Compiler should omit them.
At least the compiler shouldn't pick the last one only, should pick the all overloaded signatures.
Actual behavior:
A is void.
Playground Link:
Related Issues:

This is actually by design. inference in return type position is not meant to be an overload resolution process. it is not really supposed to be used with overloads.

Okay.


redefined axis remembers inappropriate attributes

Reported by steven c hankin on 19 Dec 2008 01:57 UTC
When redefined an axis definition remembers attributes that were created earlier
In the Ferret script below note that a Y (latitude) axis has ended up with a modulo=360. attribute attached to it.
yes? define axis/x=-90:90:5/units=degrees/edges yax
yes? define axis/y=-90:90:5/units=degrees/edges yax
Replacing definition of axis YAX
yes? let a = y[save/file=modulo_bug.nc/clobber a
 LISTing to file modulo_bug.nc
yes? q
/home/porter/hankin/tmp> ncdump -h modulo_bug.nc
netcdf modulo_bug {
dimensions:
        YAX = 36 ;
variables:
        double YAX(YAX) ;
                YAX:units = "DEGREES" ;
                YAX:axis = "Y" ;
                YAX:modulo = 360. ;  // <== WRONG !!
                YAX:point_spacing = "even" ;
        float A(YAX) ;
                A:missing_value = -1.e+34f ;
                A:_FillValue = -1.e+34f ;
                A:long_name = "Y[GY=YAX](gy=yax]
yes?)" ;

Migrated-From: http://dunkel.pmel.noaa.gov/trac/ferret/ticket/1614

Comment by ansley.b.manke on 6 Jan 2009 20:49 UTC
One-line fix in fer/gnl/redefine_axis_att.F:
We have this block:
ELSE  ! if new_modulo is false then remove attribute from axis
...
but did not set the attribute name to "modulo" to find and remove that attrib


\n and \t doesn't work in controls, unless if set via GDScript

\n and \t doesn't work in Label, Button, etc. when set via the editor. It does work though via GDScript.
Looks like this has been lost on the way:
https://github.com/godotengine/godot/issues/2967#issuecomment-210496149

That's a duplicate of #2967, no?

Oh, it's still open, my bad, I thought it was closed.


Add support for PSWAP and ISWAP gates in the runtime.

Context
We would like to add support for the PennyLane PSWAP and ISWAP gates to our compilation architecture. Originally, no Catalyst device supported them natively, so they weren't considered, but the Braket plugin which was supported at a later point in time does come with support for them.
Goal
We would like to support the following example without having to rely on decomposition:
import pennylane as qml
from catalyst import *

dev = qml.device("braket.local.qubit", wires=2, shots=100)

@qjit
@qml.qnode(dev)
def f(x: float):
    qml.Hadamard(0)
    qml.PSWAP(x, wires=[0, 1])
    qml.ISWAP(wires=[1, 0])
    return qml.probs()

We can check that right decomposition occurs by inspecting the captured program:
>>> f.jaxpr
{ lambda ; a:f64[]. let
    b:f64[4] = func[
      call_jaxpr={ lambda ; c:f64[]. let
           = qdevice[
            rtd_kwargs={'shots': 100, 'device_type': 'braket.local.qubit', 'backend': 'braket_sv'}
            rtd_lib=/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/catalyst/utils/../lib/librtd_openqasm.dylib
            rtd_name=OpenQasmDevice
          ]
          d:AbstractQreg() = qalloc 2
          e:AbstractQbit() = qextract d 0
          f:AbstractQbit() = qinst[op=Hadamard qubits_len=1] e
          g:AbstractQbit() = qextract d 1
          h:AbstractQbit() i:AbstractQbit() = qinst[op=SWAP qubits_len=2] f g
          j:AbstractQbit() k:AbstractQbit() = qinst[op=CNOT qubits_len=2] h i
          l:AbstractQbit() = qinst[op=PhaseShift qubits_len=1] k c
          m:AbstractQbit() n:AbstractQbit() = qinst[op=CNOT qubits_len=2] j l
          o:AbstractQbit() = qinst[op=S qubits_len=1] n
          p:AbstractQbit() = qinst[op=S qubits_len=1] m
          q:AbstractQbit() = qinst[op=Hadamard qubits_len=1] o
          r:AbstractQbit() s:AbstractQbit() = qinst[op=CNOT qubits_len=2] q p
          t:AbstractQbit() u:AbstractQbit() = qinst[op=CNOT qubits_len=2] s r
          v:AbstractQbit() = qinst[op=Hadamard qubits_len=1] t
          w:AbstractObs(num_qubits=2,primitive=compbasis) = compbasis v u
          x:f64[4] = probs[shape=(4,)] w
          y:AbstractQreg() = qinsert d 0 v
          z:AbstractQreg() = qinsert y 1 u
           = qdealloc z
        in (x,) }
      fn=<QNode: wires=2, device='braket.local.qubit', interface='auto', diff_method='best'>
    ] a
  in (b,) }

PSWAP and ISWAP are not present, instead we see CNOT, SWAP, and single qubit gates.
Technical details
Generally, Catalyst handles unsupported gates in the Python layer. For this, it relies on the tape expansion mechanism of the device chosen by the user, decomposing any gates not considered "supported". Additionally, Catalyst will also decompose any gates that are unsupported by the compilation pipeline, specifically the QIR interface between compiled program and runtime.
In order to support the new gates, they need to be added in several places:

the list of supported gates in the QJITDevice class:
https://github.com/PennyLaneAI/catalyst/blob/cc580544ead54403ed054da75a6694ecdfc9a0b9/frontend/catalyst/pennylane_extensions.py#L201

a QIR-style function declaration for each gate needs to be added to the C-API  of the runtime:
https://github.com/PennyLaneAI/catalyst/blob/cc580544ead54403ed054da75a6694ecdfc9a0b9/runtime/include/RuntimeCAPI.h#L51-L52

an implementation of the C-API function, calling the QuantumDevice's NamedOperation function,  similar to:
https://github.com/PennyLaneAI/catalyst/blob/cc580544ead54403ed054da75a6694ecdfc9a0b9/runtime/lib/capi/RuntimeCAPI.cpp#L350-L355

an implementation in the OpenQASM-based Braket backend device, by updating the operation map:
https://github.com/PennyLaneAI/catalyst/blob/cc580544ead54403ed054da75a6694ecdfc9a0b9/runtime/lib/backend/openqasm/OpenQasmBuilder.hpp#L71-L74

Note that when installing Catalyst from source, the OpenQASM device is not build by default. Refer to the linked documentation for how to build and test the device.

I have updated the four files, and I can build the updated catalyst with make runtime ENABLE_OPENQASM=ON and make frontend successfully. I am fairly certain what I did was correct: I will make a branch for the issue later.
The problem I have is with testing. I am trying to test with
`import pennylane as qml
from catalyst import *
dev = qml.device("braket.local.qubit", wires=2, shots=100)
@qjit
@qml.qnode(dev)
def f(x: float):
qml.Hadamard(0)
qml.PSWAP(x, wires=[0, 1])
qml.ISWAP(wires=[1, 0])
return qml.probs()`
and see whether the f.jaxpr still does the decomposition, or does it just call the PSWAP and ISWAP instructions directly.
However, I'm running into an issue with the imports. I cannot seem to import jax on my machine:
>>> import pennylane Traceback (most recent call last):   File "<stdin>", line 1, in <module>   File "/home/paul/.local/lib/python3.10/site-packages/pennylane/__init__.py", line 26, in <module>     import pennylane.numpy   File "/home/paul/.local/lib/python3.10/site-packages/pennylane/numpy/__init__.py", line 87, in <module>     from .wrapper import wrap_arrays, extract_tensors, tensor_wrapper   File "/home/paul/.local/lib/python3.10/site-packages/pennylane/numpy/wrapper.py", line 23, in <module>     from .tensor import tensor   File "/home/paul/.local/lib/python3.10/site-packages/pennylane/numpy/tensor.py", line 25, in <module>     from pennylane.operation import Operator   File "/home/paul/.local/lib/python3.10/site-packages/pennylane/operation.py", line 256, in <module>     from pennylane.math import expand_matrix   File "/home/paul/.local/lib/python3.10/site-packages/pennylane/math/__init__.py", line 37, in <module>     from .matrix_manipulation import expand_matrix, reduce_matrices, get_batch_size   File "/home/paul/.local/lib/python3.10/site-packages/pennylane/math/matrix_manipulation.py", line 24, in <module>     from pennylane.wires import Wires   File "/home/paul/.local/lib/python3.10/site-packages/pennylane/wires.py", line 21, in <module>     from pennylane.pytrees import register_pytree   File "/home/paul/.local/lib/python3.10/site-packages/pennylane/pytrees.py", line 22, in <module>     import jax.tree_util as jax_tree_util   File "/home/paul/.local/lib/python3.10/site-packages/jax/__init__.py", line 35, in <module>     from jax import config as _config_module   File "/home/paul/.local/lib/python3.10/site-packages/jax/config.py", line 17, in <module>     from jax._src.config import config  # noqa: F401   File "/home/paul/.local/lib/python3.10/site-packages/jax/_src/config.py", line 27, in <module>     from jax._src import lib   File "/home/paul/.local/lib/python3.10/site-packages/jax/_src/lib/__init__.py", line 84, in <module>     cpu_feature_guard.check_cpu_features() RuntimeError: This version of jaxlib was built using AVX instructions, which your CPU and/or operating system do not support. You may be able work around this issue by building jaxlib from source.
Moreover, importing catalyst is even worse:
>>> import catalyst Illegal instruction (core dumped)
I am working with Linux paul-Standard-PC-Q35-ICH9-2009 6.2.0-39-generic #40~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Thu Nov 16 10:53:04 UTC 2 x86_64 x86_64 x86_64 GNU/Linux (a UTM VM on an Intel i5 MAC). Since the environment is linux x86_64, jax should have no issues. I am a bit confused as to what happened.
The jax and jaxlib version are both 0.4.14, as confirmed by the make frontend script:
install Catalyst Frontend /usr/bin/python3 -m pip install -e . Defaulting to user installation because normal site-packages is not writeable Obtaining file:///home/paul/catalyst   Installing build dependencies ... done   Checking if build backend supports build_editable ... done   Getting requirements to build editable ... done   Preparing editable metadata (pyproject.toml) ... done Requirement already satisfied: pennylane>=0.32 in /home/paul/.local/lib/python3.10/site-packages (from PennyLane-Catalyst==0.3.3.dev0) (0.34.0) Requirement already satisfied: jax==0.4.14 in /home/paul/.local/lib/python3.10/site-packages (from PennyLane-Catalyst==0.3.3.dev0) (0.4.14) Requirement already satisfied: jaxlib==0.4.14 in /home/paul/.local/lib/python3.10/site-packages (from PennyLane-Catalyst==0.3.3.dev0) (0.4.14) Requirement already satisfied: scipy in /home/paul/.local/lib/python3.10/site-packages (from PennyLane-Catalyst==0.3.3.dev0) (1.11.4) Requirement already satisfied: tomlkit in /home/paul/.local/lib/python3.10/site-packages (from PennyLane-Catalyst==0.3.3.dev0) (0.12.3) Requirement already satisfied: ml-dtypes>=0.2.0 in /home/paul/.local/lib/python3.10/site-packages (from jax==0.4.14->PennyLane-Catalyst==0.3.3.dev0) (0.3.2) Requirement already satisfied: numpy>=1.22 in /home/paul/.local/lib/python3.10/site-packages (from jax==0.4.14->PennyLane-Catalyst==0.3.3.dev0) (1.26.3) Requirement already satisfied: opt-einsum in /home/paul/.local/lib/python3.10/site-packages (from jax==0.4.14->PennyLane-Catalyst==0.3.3.dev0) (3.3.0) Requirement already satisfied: networkx in /home/paul/.local/lib/python3.10/site-packages (from pennylane>=0.32->PennyLane-Catalyst==0.3.3.dev0) (3.2.1) Requirement already satisfied: rustworkx in /home/paul/.local/lib/python3.10/site-packages (from pennylane>=0.32->PennyLane-Catalyst==0.3.3.dev0) (0.13.2) Requirement already satisfied: autograd in /home/paul/.local/lib/python3.10/site-packages (from pennylane>=0.32->PennyLane-Catalyst==0.3.3.dev0) (1.6.2) Requirement already satisfied: toml in /home/paul/.local/lib/python3.10/site-packages (from pennylane>=0.32->PennyLane-Catalyst==0.3.3.dev0) (0.10.2) Requirement already satisfied: appdirs in /home/paul/.local/lib/python3.10/site-packages (from pennylane>=0.32->PennyLane-Catalyst==0.3.3.dev0) (1.4.4) Requirement already satisfied: semantic-version>=2.7 in /home/paul/.local/lib/python3.10/site-packages (from pennylane>=0.32->PennyLane-Catalyst==0.3.3.dev0) (2.10.0) Requirement already satisfied: autoray>=0.6.1 in /home/paul/.local/lib/python3.10/site-packages (from pennylane>=0.32->PennyLane-Catalyst==0.3.3.dev0) (0.6.7) Requirement already satisfied: cachetools in /home/paul/.local/lib/python3.10/site-packages (from pennylane>=0.32->PennyLane-Catalyst==0.3.3.dev0) (5.3.2) Requirement already satisfied: pennylane-lightning>=0.34 in /home/paul/.local/lib/python3.10/site-packages (from pennylane>=0.32->PennyLane-Catalyst==0.3.3.dev0) (0.34.0) Requirement already satisfied: requests in /usr/lib/python3/dist-packages (from pennylane>=0.32->PennyLane-Catalyst==0.3.3.dev0) (2.25.1) Requirement already satisfied: typing-extensions in /home/paul/.local/lib/python3.10/site-packages (from pennylane>=0.32->PennyLane-Catalyst==0.3.3.dev0) (4.9.0) Requirement already satisfied: future>=0.15.2 in /usr/lib/python3/dist-packages (from autograd->pennylane>=0.32->PennyLane-Catalyst==0.3.3.dev0) (0.18.2) Building wheels for collected packages: PennyLane-Catalyst   Building editable for PennyLane-Catalyst (pyproject.toml) ... done   Created wheel for PennyLane-Catalyst: filename=PennyLane_Catalyst-0.3.3.dev0-0.editable-cp310-cp310-linux_x86_64.whl size=9512 sha256=edb2f5433622a14020cc6d0df4b1c90d38fbf21427c292b379e10a870f60faf3   Stored in directory: /tmp/pip-ephem-wheel-cache-mpd9e2ae/wheels/0f/1e/3c/b35aee31d4d6ae2980f5166ef6643177f0887a9c4baef6e6a0 Successfully built PennyLane-Catalyst Installing collected packages: PennyLane-Catalyst   Attempting uninstall: PennyLane-Catalyst     Found existing installation: PennyLane-Catalyst 0.3.3.dev0     Uninstalling PennyLane-Catalyst-0.3.3.dev0:       Successfully uninstalled PennyLane-Catalyst-0.3.3.dev0 Successfully installed PennyLane-Catalyst-0.3.3.dev0 rm -r frontend/PennyLane_Catalyst.egg-info
Any help would be appreciated. Thanks.

Update on the previous issue: building jax and jaxlib from source resolved the "AVX not supported" error but the default build version for jax and jaxlib is 0.4.24. Catalyst only supports jax version 0.4.14 exactly, and does not support any higher versions. This might worth looking into.

BUG: upon a fresh git clone --recurse-submodules --shallow-submodules https://github.com/PennyLaneAI/catalyst.git, the make mlir will fail. This is because in catalyst/mlir/Makefile, we have
all: llvm mhlo enzyme dialects

However, two tests fail for a fresh git-cloned catalyst repo's make llvm:
paul@paul-Standard-PC-Q35-ICH9-2009:~/catalyst/mlir$ make llvm
build LLVM and MLIR enabling Python bindings
cmake -G Ninja -S llvm-project/llvm -B /home/paul/catalyst/mlir//llvm-project/build \
	-DCMAKE_BUILD_TYPE=Release \
	-DLLVM_BUILD_EXAMPLES=OFF \
	-DLLVM_TARGETS_TO_BUILD="host" \
	-DLLVM_ENABLE_PROJECTS="mlir" \
	-DLLVM_ENABLE_ASSERTIONS=ON \
	-DMLIR_ENABLE_BINDINGS_PYTHON=ON \
	-DPython3_EXECUTABLE=/usr/bin/python3 \
	-DPython3_NumPy_INCLUDE_DIRS=$(/usr/bin/python3 -c "import numpy as np; print(np.get_include())") \
	-DCMAKE_C_COMPILER=/usr/bin/clang \
	-DCMAKE_CXX_COMPILER=/usr/bin/clang++ \
	-DCMAKE_C_COMPILER_LAUNCHER=/usr/bin/ccache \
	-DCMAKE_CXX_COMPILER_LAUNCHER=/usr/bin/ccache \
	-DLLVM_USE_SANITIZER="" \
	-DLLVM_ENABLE_LLD=ON \
	-DLLVM_ENABLE_ZLIB=ON \
	-DLLVM_ENABLE_ZSTD=ON
-- bolt project is disabled
-- clang project is disabled
-- clang-tools-extra project is disabled
-- compiler-rt project is disabled
-- cross-project-tests project is disabled
-- libc project is disabled
-- libclc project is disabled
-- lld project is disabled
-- lldb project is disabled
-- mlir project is enabled
-- openmp project is disabled
-- polly project is disabled
-- pstl project is disabled
-- flang project is disabled
-- Found Python3: /usr/bin/python3 (found suitable version "3.10.12", minimum required is "3.6") found components: Interpreter
-- Could NOT find LibEdit (missing: LibEdit_INCLUDE_DIRS LibEdit_LIBRARIES)
-- Native target architecture is X86
-- Threads enabled.
-- Doxygen disabled.
-- Ninja version: 1.10.1
-- Could NOT find OCaml (missing: OCAMLFIND OCAML_VERSION OCAML_STDLIB_PATH)
-- Could NOT find OCaml (missing: OCAMLFIND OCAML_VERSION OCAML_STDLIB_PATH)
-- OCaml bindings disabled.
-- LLVM host triple: x86_64-unknown-linux-gnu
-- LLVM default target triple: x86_64-unknown-linux-gnu
-- Building with -fPIC
-- Targeting X86
-- Found Python3: /usr/bin/python3 (found suitable version "3.10.12", minimum required is "3.6") found components: Interpreter Development Development.Module Development.Embed
-- Found Python3: /usr/bin/python3 (found suitable version "3.10.12", minimum required is "3.6") found components: Interpreter Development.Module NumPy
-- Found python include dirs: /usr/include/python3.10
-- Found python libraries: /usr/lib/x86_64-linux-gnu/libpython3.10.so
-- Found numpy v1.26.3: /home/paul/.local/lib/python3.10/site-packages/numpy/core/include
-- Checking for pybind11 in python path...
-- found (/home/paul/.local/lib/python3.10/site-packages/pybind11/share/cmake/pybind11)
-- Found pybind11: /home/paul/.local/lib/python3.10/site-packages/pybind11/include (found version "2.11.1")
-- Found pybind11 v2.11.1: /home/paul/.local/lib/python3.10/site-packages/pybind11/include
-- Python prefix = '', suffix = '', extension = '.cpython-310-x86_64-linux-gnu.so
-- Registering ExampleIRTransforms as a pass plugin (static build: OFF)
-- Registering Bye as a pass plugin (static build: OFF)
-- LLVM FileCheck Found: /home/paul/catalyst/mlir/llvm-project/build/bin/FileCheck
-- git version: v0.0.0 normalized to 0.0.0
-- Version: 1.6.0
-- Performing Test HAVE_THREAD_SAFETY_ATTRIBUTES -- failed to compile
-- Performing Test HAVE_GNU_POSIX_REGEX -- failed to compile
-- Performing Test HAVE_POSIX_REGEX -- success
-- Performing Test HAVE_STEADY_CLOCK -- success
-- Configuring done
-- Generating done
-- Build files have been written to: /home/paul/catalyst/mlir/llvm-project/build
# TODO: when updating LLVM, test to see if mlir/unittests/Bytecode/BytecodeTest.cpp:55 is passing
# and remove filter
LIT_FILTER_OUT="Bytecode" cmake --build /home/paul/catalyst/mlir//llvm-project/build --target check-mlir llvm-symbolizer
[56/57] Running the MLIR regression tests
FAIL: MLIR :: python/execution_engine.py (1 of 1739)
******************** TEST 'MLIR :: python/execution_engine.py' FAILED ********************
Script:
--
: 'RUN: at line 1';   /usr/bin/python3 /home/paul/catalyst/mlir/llvm-project/mlir/test/python/execution_engine.py 2>&1 | /home/paul/catalyst/mlir/llvm-project/build/bin/FileCheck /home/paul/catalyst/mlir/llvm-project/mlir/test/python/execution_engine.py
--
Exit Code: 1

Command Output (stderr):
--
/home/paul/catalyst/mlir/llvm-project/mlir/test/python/execution_engine.py:341:16: error: CHECK-LABEL: expected string not found in input
# CHECK-LABEL: TEST: testComplexMemrefAdd
               ^
<stdin>:35:23: note: scanning from here
TEST: testF16MemrefAdd
                      ^
<stdin>:37:7: note: possible intended match here
Expected<T> must be checked before access or destruction.
      ^

Input file: <stdin>
Check file: /home/paul/catalyst/mlir/llvm-project/mlir/test/python/execution_engine.py

-dump-input=help explains the following input dump.

Input was:
<<<<<<
             .
             .
             .
            30:  [6. 7.]]
            31:
            32: TEST: testMemrefAdd
            33: [32.5] + 6.0 = [38.5]
            34:
            35: TEST: testF16MemrefAdd
label:341'0                           X error: no match found
            36: JIT session error: Symbols not found: [ __extendhfsf2, __truncsfhf2 ]
label:341'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
            37: Expected<T> must be checked before access or destruction.
label:341'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
label:341'1           ?                                                    possible intended match
            38: Unchecked Expected<T> contained error:
label:341'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
            39: Failed to materialize symbols: { (main, { _mlir_main, _mlir__mlir_ciface_main, _mlir_ciface_main, main }) }
label:341'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>>>>>>

--

********************
FAIL: MLIR :: mlir-cpu-runner/math-polynomial-approx.mlir (2 of 1739)
******************** TEST 'MLIR :: mlir-cpu-runner/math-polynomial-approx.mlir' FAILED ********************
Script:
--
: 'RUN: at line 1';     /home/paul/catalyst/mlir/llvm-project/build/bin/mlir-opt /home/paul/catalyst/mlir/llvm-project/mlir/test/mlir-cpu-runner/math-polynomial-approx.mlir -pass-pipeline="builtin.module(func.func(test-math-polynomial-approximation,convert-arith-to-llvm),convert-vector-to-llvm,func.func(convert-math-to-llvm),convert-func-to-llvm,reconcile-unrealized-casts)"  | /home/paul/catalyst/mlir/llvm-project/build/bin/mlir-cpu-runner                                                           -e main -entry-point-result=void -O0                                    -shared-libs=/home/paul/catalyst/mlir/llvm-project/build/lib/libmlir_c_runner_utils.so       -shared-libs=/home/paul/catalyst/mlir/llvm-project/build/lib/libmlir_runner_utils.so     | /home/paul/catalyst/mlir/llvm-project/build/bin/FileCheck /home/paul/catalyst/mlir/llvm-project/mlir/test/mlir-cpu-runner/math-polynomial-approx.mlir
--
Exit Code: 2

Command Output (stderr):
--
PLEASE submit a bug report to https://github.com/llvm/llvm-project/issues/ and include the crash backtrace.
Stack dump:
0.
FileCheck command line:  /home/paul/catalyst/mlir/llvm-project/build/bin/FileCheck /home/paul/catalyst/mlir/llvm-project/mlir/test/mlir-cpu-runner/math-polynomial-approx.mlir

--

********************
********************
Failed Tests (2):
  MLIR :: mlir-cpu-runner/math-polynomial-approx.mlir
  MLIR :: python/execution_engine.py

Testing Time: 197.60s
  Excluded   :   21
  Unsupported:  344
  Passed     : 1852
  Failed     :    2
FAILED: tools/mlir/test/CMakeFiles/check-mlir /home/paul/catalyst/mlir/llvm-project/build/tools/mlir/test/CMakeFiles/check-mlir
cd /home/paul/catalyst/mlir/llvm-project/build/tools/mlir/test && /usr/bin/python3 /home/paul/catalyst/mlir/llvm-project/build/./bin/llvm-lit -sv /home/paul/catalyst/mlir/llvm-project/build/tools/mlir/test
ninja: build stopped: subcommand failed.
make: *** [Makefile:59: llvm] Error 1

So the three later targets are never built, since the makefile is interrupted by this error. At the python frontend the syndrome is when one tries to import catalyst, one gets the ModuleNotFoundError: No module named 'mlir_quantum' error.
Currently I am working around this by building all 4 targets by hand. In this fashion even if some tests failed the built binaries will still be there. Please look into why a fresh build has failed tests.

After building all the mlir targets one by one by hand, I was able to import catalyst. However a new problem arises: seems like the jax without AVX just won't work with catalyst. A simple dev=qml.device("default.qubit") will encounter errors:
So I guess whatever machine I'm using that doesn't have AVX is just hopeless for catalyst.
As an alternative, my school (UofT) does have remote Ubuntu x86_64 machines I can ssh into. I can run the sample program in the issue (in the "Goal" section) with the released version of catalyst (aka the pip install pennylane-catalyst one, which grabs jax and jaxlib 0.4.14) and obtain the same output program as listed in the issue. However these machines do not have lld and so currently I cannot build my changed version from source. I will contact the system admin and get it to work on these machines.

Hey @paul0403! If you can't get the source installation to work locally, developing via a PR directly on github here would be an okay workaround -- the CI checks on the PR will run the test suite with each commit, ensuring all tests are passing.

Hey @paul0403! If you can't get the source installation to work locally, developing via a PR directly on github here would be an okay workaround -- the CI checks on the PR will run the test suite with each commit, ensuring all tests are passing.

Hi @josh146 , on the PR I created the, most of the CI checks are stuck on "expected — Waiting for status to be reported", with "This workflow requires approval from a maintainer.". Apparently every time I commit someone from the catalyst team needs to manually approve to run the CI checks. Is there any way I can do the checks from my end? Thanks.

@josh146  I just made some changes. Please run CI again. Thanks

@josh146 I just made some changes. Please run CI again. Thanks.

All the feature functionality pipelines have passed (yay). The three failed tests are readthedocs, c++ formatting, and Check Catalyst Build / Runtime Code Coverage (Linux) (pull_request) . The first two are easily fixable by me. For the last one, the report is at
https://github.com/PennyLaneAI/catalyst/actions/runs/7531845654/job/20501338908?pr=458
Seems like there was some issue uploading to codecov to generate a report and this would be unfixable from my end. Fortunately the codecov one doesn't come with the required tag so it's not urgent.
I'll fix the format and documentation in a bit.

@josh146 I just made some changes. Please run CI again. Thanks.
I fixed the C++ formatting and squashed the previous commits. This run is supposed to pass al functional feature CIs and the C++ formatting CI.
The readthedocs CI seems unfixable from my end: the report says the sphinx versioin in the CI is not high enough.

@josh146 I just made some changes. Please run CI again. Thanks.
Fixing a typo

It is with great pleasure that I report that I have resolved the "AVX not supported" error! Turns out when setting up my VM with UTM on my macbook, UTM's default CPU option just happened to choose an intel processor that does not support AVX instructions, causing all the troubles. I have manually specified a cpu with avx support.  From my branch in the PR I built catalyst with
# In top-level directory catalyst
make runtime ENABLE_OPENQASM=ON
make mlir
make frontend

My test file is located at catalyst/hi.py in the top level catalyst directory:
import pennylane as qml
from catalyst import *

dev = qml.device("braket.local.qubit", wires=2, shots=100)
#dev = qml.device("lightning.qubit", wires=2, shots=100)
#dev = qml.device("default.qubit", wires=2, shots=100)

@qjit
@qml.qnode(dev)
def f(x:float):
   qml.Hadamard(0)
   qml.PSWAP(x, wires=[0,1])
   qml.ISWAP(wires=[1,0])
   return qml.probs()

print(f(0))
print(f.jaxpr)

With braket.local.qubit, I still get pennylane._device.DeviceError: Device braket.local.qubit does not exist. Make sure the required plugin is installed. However with lightning.qubit I get the expected output
[0.55 0.   0.45 0.  ]
{ lambda ; a:f64[]. let
    b:f64[4] = func[
      call_jaxpr={ lambda ; c:f64[]. let
           = qdevice[
            rtd_kwargs={'shots': 100, 'mcmc': False}
            rtd_lib=/home/paul/catalyst/runtime/build/lib/librtd_lightning.so
            rtd_name=LightningSimulator
          ]
          d:AbstractQreg() = qalloc 2
          e:AbstractQbit() = qextract d 0
          f:AbstractQbit() = qinst[op=Hadamard qubits_len=1] e
          g:AbstractQbit() = qextract d 1
          h:AbstractQbit() i:AbstractQbit() = qinst[op=SWAP qubits_len=2] f g
          j:AbstractQbit() k:AbstractQbit() = qinst[op=CNOT qubits_len=2] h i
          l:AbstractQbit() = qinst[op=PhaseShift qubits_len=1] k c
          m:AbstractQbit() n:AbstractQbit() = qinst[op=CNOT qubits_len=2] j l
          o:AbstractQbit() = qinst[op=S qubits_len=1] n
          p:AbstractQbit() = qinst[op=S qubits_len=1] m
          q:AbstractQbit() = qinst[op=Hadamard qubits_len=1] o
          r:AbstractQbit() s:AbstractQbit() = qinst[op=CNOT qubits_len=2] q p
          t:AbstractQbit() u:AbstractQbit() = qinst[op=CNOT qubits_len=2] s r
          v:AbstractQbit() = qinst[op=Hadamard qubits_len=1] t
          w:AbstractObs(num_qubits=2,primitive=compbasis) = compbasis v u
          x:f64[4] = probs[shape=(4,)] w
          y:AbstractQreg() = qinsert d 0 v
          z:AbstractQreg() = qinsert y 1 u
           = qdealloc z
        in (x,) }
      fn=<QNode: wires=2, device='lightning.qubit', interface='auto', diff_method='best'>
    ] a
  in (b,) }

(Notice the PSWAP and ISWAP are still decomposed as CNOTs and SWAPs, as their support is only added to openqasm, not the lightning.qubit)
Did I miss anything in the installation? I did build with make runtime ENABLE_OPENQASM=ON

@maliasadi Hi Ali, thanks for the help! I completely missed the requirement.txt!
With amazon-braket plugin installed, this commit can now achieve its goal. Here's a small test I just ran:
import pennylane as qml
from catalyst import *

dev = qml.device("braket.local.qubit", wires=2, shots=100)

@qjit
@qml.qnode(dev)
def h():
   qml.ISWAP(wires=[0,1])
   qml.PSWAP(1.23, wires=[0,1])  # some randomly picked angle phi
   return qml.probs()

This program now gives
>>> h()
array([1., 0., 0., 0.])
>>> h.jaxpr
{ lambda ; . let
    a:f64[4] = func[
      call_jaxpr={ lambda ; . let
           = qdevice[
            rtd_kwargs={'shots': 100, 'device_type': 'braket.local.qubit', 'backend': 'braket_sv'}
            rtd_lib=/home/paul/catalyst/frontend/catalyst/utils/../../../runtime/build/lib/librtd_openqasm.so
            rtd_name=OpenQasmDevice
          ]
          b:AbstractQreg() = qalloc 2
          c:AbstractQbit() = qextract b 0
          d:AbstractQbit() = qextract b 1
          e:AbstractQbit() f:AbstractQbit() = qinst[op=ISWAP qubits_len=2] c d
          g:AbstractQbit() h:AbstractQbit() = qinst[op=PSWAP qubits_len=2] e f 1.23
          i:AbstractObs(num_qubits=2,primitive=compbasis) = compbasis g h
          j:f64[4] = probs[shape=(4,)] i
          k:AbstractQreg() = qinsert b 0 g
          l:AbstractQreg() = qinsert k 1 h
           = qdealloc l
        in (j,) }
      fn=<QNode: wires=2, device='braket.local.qubit', interface='auto', diff_method='best'>
    ]
  in (a,) }

which is expected! The functionality passes a first-impression sanity check since both gates leave |00> invariant, so the probability returned should be [1,0,0,0], and indeed it is. Also the program now no longer decomposes the ISWAP and PSWAP gates into other gates. It just calls the ISWAP and PSWAP quantum instructions from the librtd_openqasm.so directly, which was the goal of this issue!
I have class in a bit so I will answer the questions on the PR and write unit tests at a later time!

@josh146 I just made some changes. Please run CI again. Thanks.

@josh146 I just made some changes. Please run CI again. Thanks.

@josh146 I just made some changes. Please run CI again. Thanks.

Will do. @paul0403 I recommend going forward commenting on the PR, rather than the issue 🙂


OC-424 ~ Used different logger and removed unnessecary exception

This pull request makes the build fail.

This pull request makes the build fail.


Installation succeeds but builds entirely wrong fstab file

Describe the bug
I'm trying to setup a new laptop (Dell XPS 15). The installation succeeds but on boot the partition is not accessible:
Waiting 10 seconds for device /dev/nvme0n1p2 to appear.......... - failure
/dev/nvme0n1p2 is unavailable

I used a boot disk to investigate and the partition was totally fine. I mounted it and poked around and saw that the fstab file was totally wrong. It was identical to that of the nixos bootdisk i used during provisioning:
# This is a generated file.  Do not edit!
#
# To make changes, edit the fileSystems and swapDevices NixOS options
# in your /etc/nixos/configuration.nix file.
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>

# Filesystems.
tmpfs / tmpfs x-initrd.mount,mode=0755 0 0
/dev/root /iso auto x-initrd.mount 0 0
/iso/nix-store.squashfs /nix/.ro-store squashfs x-initrd.mount,loop 0 0
tmpfs /nix/.rw-store tmpfs x-initrd.mount,mode=0755 0 0
overlay /nix/store overlay x-initrd.mount,lowerdir=/nix/.ro-store,upperdir=/nix/.rw-store/store,workdir=/nix/.rw-store/work 0 0

# Swap devices.

To Reproduce
Steps to reproduce the behavior:
I'm not sure. My system config uses sops-nix for secrets so it would be a pain to try to instally my config on a vm or whatever to test this.
Expected behavior

System information
nixos 23.05
Additional context
This is the machine config in question:
https://github.com/solomon-b/nixos-config/blob/main/flake.nix#L223-L241
And this is a script i use to wrap nixos-anywhere:
https://github.com/solomon-b/nixos-config/blob/main/installer/install-pc.sh#L39

Closing due to user error.


Removes border radius from transparent input in UpdateableLatestForecast

Pull Request: Removes border radius from transparent input in UpdateableLatestForecast
Related Issue
Asana ref
Changes Made

Removes rounded-md from transparent input element in UpdateableLatestForecast component

Testing
Tested locally and in preview
Before/after:

I could maybe merge this without review - as far as I can tell I haven't missed this component being used elsewhere in the codebase, mostly just wanted you to check rounded-md isn't a Chesterton's Fence thing


Required dependency failed

What steps will reproduce the problem?
composer update
What's expected?
Successful packages update
What do you get instead?

Installation request for yiisoft/yii-debug dev-master -> satisfiable by yiisoft/yii-debug[dev-master].
- yiisoft/yii-debug dev-master requires yiisoft/yii-bootstrap-implementation ^3.0@dev -> no matching package found.

Additional info
yii-base-web composer.json :
 "require-dev": {
        "yiisoft/yii-debug": "dev-master",
        "yiisoft/yii-gii": "dev-master",
        "phpunit/phpunit": "^7.0"
    },

What is the idea of yiisoft/yii-bootstrap-implementation?

Q
A

Yii version
3.0

PHP version
PHP 7.2.10-0ubuntu<IP_ADDRESS>

Operating system
Ubuntu <IP_ADDRESS>

We'll get rid of this dependency soon. @simialbi already did for Yii 2.

I'd be happy to port https://github.com/yiisoft/yii2-debug/commit/097f7e52eaa3e46c33d20802fcc72904b35e2688 to this repository, if it's okay with @simialbi (👋 )
I'm just confused by one thing: Why is there still work being done in yii2-debug 2.1? (as I understand it, there will be no Yii 2.1 release, and we should focus all efforts on 3.0)

@simialbi yes, it is definitely acceptable and is very much needed for the whole idea of Yii 3.0 to work well.

@machour 2.1 doesn't mean it's for Yii 2.1. It's just SemVer.


Sheet creation error from slashes in investigation title

When creating sample sheets from template, we get an unexpected error if the investigation title contains slashes:
ISA-Tab import failed: [Errno 2] No such file or directory: '/tmp/tmpuvoltlic/Template_Test/a_investigation_title/slash_Biocrates_MxP_Quant_500_Kit_LC.txt'

We need to replace the characters internally to prevent this. Slashes in titles should still be allowed.

It turns out this actually happens in cubi-isa-tempates, will open a separate ticket there.

Fixed. Should upgrade to the next cubi-isa-templates release once it's tagged, but a dev commit is fine for now.


[Service Bus] Identify steps to run stress tests on VM

One of the steps identified maybe running stress tests on CI/CD as fast as possible. https://github.com/Azure/azure-sdk-for-js/issues/1983
Another is https://github.com/Azure/azure-sdk-for-js/issues/1959 when we have more information on requirements for these test runs.

The stress test suite for Event Hubs and Service Bus is being re-visited. This includes infrastructure as well as scenario updates. Therefore, we are de-prioritizing improving existing stress test cases in their current state


"Building unpackaged app" tutorial should explain how to get XAML to work in unpackaged

The content only goes as far as calling the DD APIs, but doesn't provide an offramp to creating a GUI app

Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

ID: 2a490a57-1f12-5646-2906-dca6ead89518
Version Independent ID: 7ea6aaad-bf8d-2a2e-3012-11e8e2ebe917
Content: Advanced tutorial - Build and deploy an unpackaged app that uses the Windows App SDK - Windows apps
Content Source: hub/apps/windows-app-sdk/tutorial-unpackaged-deployment.md
Product: reunion
Technology: deployment
GitHub Login: @zaryaf
Microsoft Alias: zafaraj

Yes, as it's currently written this topic is focused solely on a console app. But a while ago I went through this topic except I created a WPF project instead, and that worked. I had to add win10-x64, and I proved that WinAppSDK was being loaded ok, and that I could call some WinAppSDK APIs (not necessarily exactly the code in the tutorial, but something equally interesting, I think).
That was about a month ago and I keep planning to update this topic with that experiment when I get some time. So at the same time I'll see what I can do about providing the offramp you mention. Of course, the "GUI app" in question could be WPF or WinForms or Win32, but it wouldn't be a WinUI 3 app (since you wouldn't need to bootstrap that).
So I've back-logged that work for myself and I'll track it along with my existing workstreams. I'll go ahead and close this so that I'm not tracking it twice, and I'll come back here and update when I get around to doing the work.
Thanks!
-Steve

thanks @stevewhims ! Just to clarify, when building a winui3 unpackaged app, I expect that someone still needs to bootstrap the framework, as well as whatever manifest entries we need, CRT requirements, etc. I realize some of these are changing between 1.0 and future, but as of today we don't have a public sample that shows how to build a WinUI 3 unpackaged app.

I see, good point! Ok, I'll investigate that scenario, too. :)


Problem rendering Instagram logo

Hi,
I have built svgren based on the sources from June 2 (with Agg renderer) and I've noticed an issue rendering a particular svg.
In this screenshot the expected result is to the right but the actual result to the left. The white lines that form the camera is missing.

This was working in the older build I had with Cairo renderer.
I'm attaching the file. Can you reproduce this or is it a problem on my end?
test2.zip

Hi,
I have just tried it on linux with latest sources. All works good for me.
Are you running it on windows? Do  you install svgren via NuGet package?

This is on Windows, yes. I'll try upgrading and hopefully it solves it.

Ok, if it doesn't, feel free to reopen the bug, I'll try to reproduce it on Windows then.


refactor: [dev-7142] world map to typescript

this is preliminary work for dev-7142 so that I can make changes that we can track since the World map file is moving.

@joshlacey the map package fails to build. Remember to test all the way through editor.

@joshlacey the map package fails to build. Remember to test all the way through editor.

I tested the editor and everything was working. I did see when I ran the build again that the import for the topo.json file wasn't correct, IDK why it didn't throw an error sooner than running the build.
just pushed the change up


WIP - Stitching web UI with intake catalog

part of #27
TODO

[x] Fix the error  'url_quote' from 'werkzeug.urls'
[x] add logic to query nested .yml
[x] remove test.yml
[ ] add tests for key/value pairs to pick

need to fix the key value -> string -> dict -> extract in the jinja template -> pass to the UI


Hide the page size UI element

Added to Sprint 23.10

Keep current default page size and hide the dropdown of page sizes.


Cannot connect to the Docker daemon

On Mac OS/X El Capitan, after installing the Docker Toolkit and launching the Docker CLI, it apparently created the VM successfully, but neither docker-machine nor docker can run successfully. For example, "docker info" just returns "Cannot connect to the Docker daemon." Running "docker-machine env default" returns "Error running connection boilerplate: Error getting driver URL: Something went wrong running an SSH command!"

You should always run the docker commands from a shell created using Application/Docker Quickstart Terminal, because it sets up the required environment variables.
Or you can set these in your .bash_profile:
export DOCKER_HOST=tcp://<IP_ADDRESS>:2376
export DOCKER_MACHINE_NAME=default
export DOCKER_TLS_VERIFY=1
export DOCKER_CERT_PATH=/Users/james/.docker/machine/machines/default

There's something wrong with the Docker Quickstart. That's the point of my
post. I can run it manually with the following from Terminal:
docker-machine create --driver virtualbox DockerBox
text=docker-machine env DockerBox
eval $text
docker-machine ssh DockerBox
On Mon, Nov 30, 2015 at 11:01 PM, zakum1<EMAIL_ADDRESS>wrote:

You should always run the docker commands from a shell created using
Application/Docker Quickstart Terminal, because it sets up the required
environment variables.
Or you can set these in your .bash_profile:
export DOCKER_HOST=tcp://<IP_ADDRESS>:2376
export DOCKER_MACHINE_NAME=default
export DOCKER_TLS_VERIFY=1
export DOCKER_CERT_PATH=/Users/james/.docker/machine/machines/default
—
Reply to this email directly or view it on GitHub
https://github.com/docker/kitematic/issues/1261#issuecomment-160864295.

@GasCreature Can you provide some background information on perhaps previous docker installations?
Can you share the version of your tools?
docker-machine --version
docker version

I did not have Docker previously installed on this Mac, which is on a factory install of El Capitan. The Docker Toolbox is from a few days ago.
The boot2docker version is 1.9.1, Nov 20 2015.
Docker version 1.9.1 build a34a1d5.
Docker-machine version 0.5.1 (7e8e38e).
OS X El Capitan version 10.11.1.
At least one one attempt, Docker Quickstart Terminal seems to work now. But this is after the workaround I described before.
The issue could be because I set HOME to something other than /Users/gas in .profile. Maybe Quickstart Terminal is making some assumptions about the home directory apart from what bash actually does upon completing .profile. I noticed a .docker from a few days ago in /Users/gas. My "real" .docker directory is elsewhere.

I don't think it's just the quick start, a lot of the docker/machine settings rely on the user's home directory and precisely the information we need to understand what's going on.
Could you share exactly all of the changes you made and how they were applied (gist of .rc .profile would help)
Thanks

Try to repro like this:
1.Create user "gas".

These commands...
ln -s /u /Users
mkdir -p /u/gas/home/tmp
touch /u/gas/home/.profile
ln -s /u/gas/tmp /u/gas/home/tmp
ln -s /u/gas/home/.profile /u/gas/.profile
ln -s /u/gas/.ssh /u/gas/home/.ssh

Put into .profile
HOME=/u/gas/home
if [ -f /usr/local/share/chruby/chruby.sh ] ;then
source /usr/local/share/chruby/chruby.sh
source /usr/local/share/chruby/auto.sh
fi
PATH=.:$PATH
export HOME=/u/gas/home

Install VirtualBox by running an otto sample (https://ottoproject.io/downloads.html). Installing manually is probably fine, too.

If possible, do this:
cd /u/gas/Library
rm -rf VirtualBox
ln -s /u/gas/home/Library/VirtualBox

Install Docker Toolbox.

@GasCreature It seems that you have a pretty custom setup - We currently only support vanilla setups which is why Toolbox may not be working well for you.
I would advise against installing virtualbox separately from Toolbox and letting it do all of the setup for you.

Thanks for looking at this. My two cents:
a) Most of the time, the developer will already have VirtualBox already installed, so "advise against installing virtualbox separately" is not going to be effective.
b) Yes, it makes sense to "only support vanilla setups" (for now, anyway) but it may be smart to remove assumptions about the home directory if possible.

@GasCreature you're right that the assumption is difficult, but we package the different tools for the versions that are known to work well.
For example using vbox 4.3 may be ok, but more than likely will cause more issues than the stable release of 5.0.10 included with Toolbox.
Regarding the home folder it's simply due to the default Vbox setup which maps your local folder to the VM.


Any update for cluster support?

Hi,
Any update for cluster support? I think the community would be happy if ardb support cluster like redis now

there is a redis cluster proxy dynomite, ardb can be used as backend in it.

Thank you!


Adding STDevRxExt in Utility section

Project URL
https://github.com/stdevteam/STDevRxExt
Category
Utility
Description
STDevRxExt contains some extension functions for RxSwift and RxCocoa which makes our live easy.
Why it should be included to awesome-ios (optional)
Checklist

[x] Only one project/change is in this pull request
[x] Addition in chronological order (bottom of category)
[x] Supports iOS 9 / tvOS 10 or later
[x] Supports Swift 4 or later
[x] Has a commit from less than 2 years ago
[x] Has a clear README in English

          1 Warning

:warning:
Found 1 link issue, a project collaborator will take care of these, thanks :)

Link issue by awesome_bot

Line
Status
Link

937
404
https://github.com/jaredsinclair/JTSImageViewController

  Generated by :no_entry_sign: Danger

Please, move this project to reactive-programming category


Latest Stories Block

Feature Description
The existing Web Story block works fine. But there should be a block that displays multiple latest stories.
Additional Context

Ensure that it works for both AMP and non-AMP mode.
Ensure the responsiveness of stories on mobile screens. Like they can be similar to Facebook or Instagram smaller sized stories which turns to bigger/full screen when tapped.
Ensure that the block works on all pages and not just homepage or front page.

For the basic layout, the block should have options: -

to show maximum number of stories
option to show or hide view all or more stories that may lead to example.com/stories archive page
number of columns (max can be defined like 6) and then if we choose 4 columns and 8 number of stories > 2 rows having 4 stories in each should be rendered
some additional options like hide/show post date, author name, etc.

Do not alter or remove anything below. The following sections will be managed by moderators only.
Acceptance Criteria

Implementation Brief

Hey @digitalsetups, thanks for opening this issue!
We're already looking into the various possibilities for more blocks, and a "Latest Stories" block is certainly planned! It would offer similar functionality like the existing "Latest Posts" block in WordPress, which I think is what you cover in your request (number of items, number of columns, etc.).
The part with supporting a example.com/stories archive page we still have to figure out independently from that. Right now we don't have an archive page.

@o-fernandez / @pbakaus / @amedina - please confirm if this should be added to the stable release scope

nope, we'll have to do this after 1.0 stable. Great suggestion though!

I think this is something that would be great to do and would benefit from a product spec and some UX thinking. Moving to my queue for a product brief.

Closing as this is being worked on by rtCamp.