Rethink project layout and packages

Suggestion from https://gophers.slack.com/archives/C02A3DRK6/p1723726855170079.
Project layout
https://go.dev/doc/modules/layout#server-project

[x] Server projects typically won’t have packages for export, since a server is usually a self-contained binary (or a group of binaries). Therefore, it’s recommended to keep the Go packages implementing the server’s logic in the internal directory.

Packages
https://go.dev/blog/package-names
...
 Write code that uses your package as a client would, and restructure your packages if the result seems poor. This approach will yield packages that are easier for clients to understand and for the package developers to maintain.
[x] Avoid meaningless package names. Packages named util, common, or misc provide clients with no sense of what the package contains. This makes it harder for clients to use the package and makes it harder for maintainers to keep the package focused. Over time, they accumulate dependencies that can make compilation significantly and unnecessarily slower, especially in large programs. And since such package names are generic, they are more likely to collide with other packages imported by client code, forcing clients to invent names to distinguish them.
[x] Don’t use a single package for all your APIs. Many well-intentioned programmers put all the interfaces exposed by their program into a single package named api, types, or interfaces, thinking it makes it easier to find the entry points to their code base. This is a mistake. Such packages suffer from the same problems as those named util or common, growing without bound, providing no guidance to users, accumulating dependencies, and colliding with other imports. Break them up, perhaps using directories to separate public packages from implementation.

Closing with #7.


[WebJobs][EventHubsExtension] Fix metrics when azure checkpoint container does not exist

If the container "azure-webjobs-eventhub" does not exist - scaling logic is not able to detect new EH messages.

/azp run net - eventhub - ci

/azp run net - eventhub - functions - ci

/azp run net - eventhub - functions - ci

/azp run net - eventhub - functions - tests

/azp run net - eventhub - functions - ci

Change looks good.   It appears some tests need to be fixed up to account for the new behavior.   Given that, it may be helpful to add a test or so for this specific scenario to confirm the change has the intended effect.

/azp run net - eventhub - functions - ci

@jsquire, I fixed the unit tests and run azure pipeline - it seems the errors are not PR related.

@jsquire, I fixed the unit tests and run azure pipeline - it seems the errors are not PR related.

Can you try fetching/rebasing on main?   Something is out of sync in your working directory.

@jsquire, I fixed the unit tests and run azure pipeline - it seems the errors are not PR related.

This isn't you being out of sync.   Because the CI pipeline got disabled, there was no API export done.   I've got that going in another PR but it'll block until then.   I'm going to bypass checks so that this can merge and be included in this month's release.

/check-enforcer override

Hrmm... looks like it is still blocked and I can't bypass.   Please run the ExportApi script or steal the export from here and include it.  That will unblock you.


Gradle does not find GH packages library with GITHUB_TOKEN

Is there an existing issue for this?

[X] I have searched the existing issues

Package ecosystem
gradle
Package manager version
8.4
Language version
Kotlin 1.9.20
Manifest location and content before the Dependabot update
No response
dependabot.yml content
version: 2
registries:
GitHubPackages-rr-common:
type: maven-repository
url: https://maven.pkg.github.com/ACCOUNT/rr-common
username: ACCOUNT
password: ${{secrets.BUILD_TOKEN}}
updates:

package-ecosystem: "gradle"
directory: "/"
schedule:
interval: "weekly"
commit-message:
prefix: "[Gradle]"

Updated dependency
No response
What you expected to see, versus what you actually saw
My problem is in a kotlin/gradle based private project, which uses a package in another repository of the same pro account. On normal pull requests, building the project works as expected. On PRs from dependabot, gradle cannot find the dependency.
Extract from workflow file:
name: Build and deploy
on: push
env:
  GITHUB_USERNAME: "ACCOUNT"
  GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
jobs:
  build:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4

      - name: Set up JDK
        uses: actions/setup-java@v3
        with:
          distribution: temurin
          java-version-file: ./.java-version

      - name: Compile
        run: ./gradlew compileKotlin

Extract from build.gradle.kts:
val githubUsername = System.getenv("GITHUB_USERNAME")
val githubToken = System.getenv("GITHUB_TOKEN")

repositories {
    mavenCentral()
    maven {
        name = "GitHubPackages-rr-common"
        url = uri("https://maven.pkg.github.com/ACCOUNT/rr-common")
        credentials {
            username = githubUsername
            password = githubToken
        }
    }
}

plugins {
    kotlin("jvm")
}

dependencies {
      implementation("de.ACCOUNT:rr-common:2.0.1")
}

The compile step fails on PRs from dependabot with the following error, compared to normal PRs which run just fine:
> Task :compileKotlin FAILED
FAILURE: Build failed with an exception.

3 actionable tasks: 3 executed
* What went wrong:
Execution failed for task ':compileKotlin'.
> Could not resolve all files for configuration ':compileClasspath'.
   > Could not find de.ACCOUNT:rr-common:2.0.1.
     Required by:
         project :

What do I need to do to make this work?
Native package manager behavior
No response
Images of the diff or a link to the PR, issue, or logs
No response
Smallest manifest that reproduces the issue
No response

PRs created by Dependabot use its own secrets, not the default ones: https://docs.github.com/en/code-security/dependabot/working-with-dependabot/configuring-access-to-private-registries-for-dependabot

Yes, I am aware of that.
The secret in question here is GITHUB_TOKEN, being passed to gradle as a credential to download the dependency from GitHub packages. And that fails with dependabot during the gradle run (not the dependency check
Do I have to configure that GITHUB_TOKEN somehow to make it work?

I solved this by using a personal access token instead of GITHUB_TOKEN for accessing the github package.


 The Dockerfile is structured so that it could also feasibly be used in a production capacity in the future, should a containerized deployment be desirable.

Final check / waiting for an 'approve' on the code review.


clientv3: making session ttl configurable

Fix #5989
/cc @heyitsanthony

It looks like these should take a session instead of a timeout (maybe WithSession() / WithSessionTimeout() as varargs to NewMutex/NewElection)? It's not clear what the timeout is tied to when it's passed as a regular argument

@heyitsanthony Do you also want NewSession(..., WithTimeout(X)) or just NewElection(..., WithSession(S))?

@xiang90
I'm thinking the following should be valid:
NewElection(..., WithSession(s))
NewElection(..., WithSessionTimeout(ttl))
NewSession(client, WithSessionTimeout(ttl))

alternatively we could have two separate constructors, NewSessionMutex(*Session, string) for a custom session and NewMutex(*clientv3, string) for the default. Varargs might be overkill.

@heyitsanthony
How about just
NewSession(client, WithTimeout(ttl))
NewElection(..., WithSession(s))

Having newElection, and newSessionElection might create problems in the future. If we want to add one more options, we need to do it at two places.

@xiang90 it should probably be NewElection(s *Session) (+ func (s *Session) Client() *clientv3.Client) since the election must have a session. It'd be similar to the mutex interface (https://github.com/coreos/etcd/issues/6127#issuecomment-238163237)

@heyitsanthony OK. I am going to separate this into two prs. adding withTTL into session and making election, mutex better.

close in favor of https://github.com/coreos/etcd/pull/6172


Adding capabilities of enabling POSTGIS, directly through HELM chart.

@caggles or @marcellmueller  could anyone please review

Looks good! Thanks for the contribution. Looks like CI is failing since you aren't a member and don't have access to the repository secrets so we will have to figure out the best way to merge this in 🤔

you can add me to this repo , I can create a branch and then create a PR from the branch.

Looks good! Thanks for the contribution. Looks like CI is failing since you aren't a member and don't have access to the repository secrets so we will have to figure out the best way to merge this in 🤔

you can add me to this repo , I can create a branch and then create a PR from the branch.

Done!


Changes to stabilize the fabric proxy model

Fix crypto error for fabric generic client
Implement workOrderGet API
Modify fabric generic client to use workOrderGet API

Signed-off-by: Ramakrishna Srinivasamurthy<EMAIL_ADDRESS>

Added issue https://github.com/hyperledger/avalon/issues/321 to make the implementation similar for both fabric and ethereum. A new PR can address this issue. Most if the review comments in this PR can be handled as part of new PR


Module 1.1 Assignment

Given what you have learned about Git, why would you want to use Git in your classroom?

Because I want my students to do some version control, to collaborate and to learn how to use Git and Github.


Adding board support for CC3220sf

/morph test

Since you did a merge, could you please rebase and squash, then force push to update this PR? That will keep the history cleaner. Thanks.


datapack example

Make sure you are not opening a duplicate.

[x] I have searched the issue tracker and did not find an issue describing my bug.

Description of your suggestion.
I would like to see an example of a datapack for the dungeonz mod, how to create it, so that in this example I can create my own datapacks with dungeons

An example can be found now at this repository, added with https://github.com/Globox1997/DungeonZ/commit/0f927daab9c84348b7375e82fd7559939d19a62f


Update pusher.md

Adding this sentence, as I first had to download the module to see it was incompatible with React Native clients.

Thank you for this clarification @wpenris . I have implemented the change myself manually, so I will close this PR. Thank you for updating the documentation.

Also, for transparency, I checked with R&D and this documentation change is approved.


Optional logprobs & fix llama eos/stop token

Make logprobs as optional (no logprobs field in chat completion response by default),
Fix the EOS problem for the LLaMa pipeline.
Tested cases:
First request:
curl -X POST "http://<IP_ADDRESS>:65320/v1/chat/completions" \
     -H "Content-Type: application/json" \
     -H "Authorization: Bearer YOUR_API_KEY" \
     -d '{
           "model": "llama7b",
           "messages": [
               {"role": "user", "content": "Explain how to best learn Rust."}
           ],
           "temperature": 0.7,
          "max_tokens": 1024,
          "stop": {"Single":"</s>"}
       }'

First response:
{"id":"cmpl-88fad42f-271f-49b6-ad8c-b6dc8ddda132","choices":[{"message":{"content":" Learning any programming language requires a combination of theory, practice, and dedication. Here are some steps and resources to help you learn Rust effectively:\n\n1. Start with the basics:\n\t* Understand the syntax and basic structure of Rust programs.\n\t* Learn about variables, data types, loops, and control structures.\n\t* Familiarize yourself with Rust's ownership system and borrowing mechanism.\n2. Read the Rust book:\n\t* The Rust book is an official resource that provides a comprehensive introduction to the language.\n\t* It covers topics such as syntax, type system, lifetimes, and error handling.\n\t* Read the book from start to finish, and take breaks to practice what you've learned.\n3. Experiment and build projects:\n\t* Start by writing simple programs to get a feel for the language.\n\t* Gradually move on to more complex projects, such as building a command-line tool or a small library.\n\t* Experiment with different libraries and frameworks to see how they can help you build more robust and efficient programs.\n4. Join the Rust community:\n\t* Participate in online forums, such as the Rust subreddit or the Rust Discord server.\n\t* Attend Rust meetups or conferences to connect with other Rust users and learn from their experiences.\n\t* Contribute to open-source Rust projects to gain practical experience and build your reputation in the community.\n5. Take online courses or tutorials:\n\t* There are many online courses and tutorials available that cover various aspects of Rust programming.\n\t* Some popular resources include the Rust by Example course, the Rust Programming Language course on Pluralsight, and the Rust course on Udemy.\n6. Read Rust-related articles and blogs:\n\t* Stay up-to-date with the latest developments in the Rust ecosystem by reading articles and blog posts on Rust-related topics.\n\t* Some popular Rust blogs include the Rust Bytes blog, the Rust Weekly newsletter, and the Rustlings blog.\n7. Learn C and other programming languages:\n\t* Rust is built on top of the C programming language, so having a solid understanding of C is essential for mastering Rust.\n\t* Familiarize yourself with other programming languages, such as Python, JavaScript, or Java, as they can provide a different perspective on programming and help you understand Rust's design choices.\n8. Practice, practice, practice:\n\t* The best way to learn any programming language is by writing code.\n\t* Set aside time each day or week to practice writing Rust code, and gradually increase the complexity of your projects.\n9. Learn error handling and debugging:\n\t* Rust has a strong focus on error handling and debugging, so it's essential to learn how to use the language's error handling mechanisms effectively.\n\t* Practice using the `?` operator, `match` statements, and `Result` types to handle errors in your code.\n10. Learn advanced topics:\n\t* Once you have a solid foundation in the basics, start exploring more advanced topics such as:\n\t\t+ Macros: Rust's macro system allows you to extend the language itself, which can be a powerful tool for building libraries and frameworks.\n\t\t+ Traits: Traits are a mechanism for defining a set of functions or methods that can be implemented by multiple types.\n\t\t+ Smart pointers: Rust's ownership system is based on smart pointers, which allow you to manage memory safely and efficiently.\nBy following these steps and resources, you can gain a deep understanding of the Rust programming language and become proficient in building robust and efficient software.","role":"[INST]"},"finish_reason":"stop","index":0,"logprobs":null}],"created":1718781072,"model":"llama7b","object":"chat.completion","usage":{"completion_tokens":834,"prompt_tokens":29,"total_tokens":863}}

Second request:
curl -X POST "http://<IP_ADDRESS>:65320/v1/chat/completions" \
     -H "Content-Type: application/json" \
     -H "Authorization: Bearer YOUR_API_KEY" \
     -d '{
           "model": "llama7b",
           "messages": [
               {"role": "user", "content": "How to practice?"}
           ],
           "temperature": 0.7,
          "max_tokens": 1024,
          "stop": {"Single":"</s>"}
       }'

Second response:
{"id":"cmpl-b1523b98-b71e-49de-979d-70667a5963f8","choices":[{"message":{"content":" Learning Rust can be a challenging but rewarding experience. Here are some steps you can take to practice and improve your skills in Rust:\n1. Start with the basics: Understand the syntax, variables, data types, loops, and control structures in Rust. The official Rust book is a great resource for this.\n2. Build small projects: Start by building small projects, such as a calculator, a to-do list app, or a simple game. This will help you get comfortable with the language and its ecosystem.\n3. Experiment with libraries and frameworks: Rust has a rich ecosystem of libraries and frameworks that can help you build more complex applications. Experiment with different libraries and frameworks to see how they can help you build your projects.\n4. Learn error handling: Error handling is an important aspect of Rust programming. Learn how to use Result, Option, and other error handling mechanisms to handle errors in your code.\n5. Learn about ownership and borrowing: Rust's ownership and borrowing system is one of its most unique features. Understand how to manage ownership and borrowing in your code to avoid common errors.\n6. Learn about advanced topics: Once you have a good grasp of the basics, start exploring more advanced topics such as lifetimes, borrowing, and smart pointers. These topics can help you write more efficient and safe code.\n7. Practice, practice, practice: The best way to learn Rust is by writing code. Start with small projects and gradually work your way up to more complex applications.\n8. Join a community: Join online communities such as the Rust subreddit, Rust Discord, or Rust forums to connect with other Rust users, ask questions, and learn from their experiences.\n9. Read Rust documentation: The Rust documentation is a wealth of information, and it's a great resource to learn about different aspects of the language.\n10. Take online courses or tutorials: There are many online courses or tutorials that can help you learn Rust, such as the Rust by Example course, or the Rust programming language tutorial on Pluralsight.\n111. Read Rust books: There are many great books available to learn Rust, such as \"The Rust Programming Language\", \"Rust Crash Course\", or \"Rust by Example\".\n12. Participate in coding challenges: Participate in coding challenges such as Rust's \"Rust By Example\" challenges, or the \"Rust Community Book\" to practice your skills and learn from others.\n13. Learn about advanced topics: Once you have a good grasp of the basics, start exploring more advanced topics such as lifetimes, borrowing, and smart pointers. These topics can help you write more efficient and safe code.\n14. Learn about Rust's type system: Rust's type system is one of its most powerful features. Learn how to use enums, generics, and other type-related features to write more robust and safe code.\n15. Learn about Rust's concurrency model: Rust has a unique concurrency model that allows you to write concurrent code that is both safe and efficient. Learn how to use async/await, futures, and other concurrency-related features to write concurrent code that is both safe and efficient.\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n","role":"[INST]"},"finish_reason":"length","index":0,"logprobs":null}],"created":1718781138,"model":"llama7b","object":"chat.completion","usage":{"completion_tokens":1025,"prompt_tokens":39,"total_tokens":1064}}

Apparently, the KV cache in the previous generation was used in the second request for context learning. However, the second response has some redundant outputs (no eos token was found in the second response).

Apparently, the KV cache in the previous generation was used in the second request for context learning. However, the second response has some redundant outputs (no eos token was found in the second response).

Have you implemented per-request cache clearing?

Apparently, the KV cache in the previous generation was used in the second request for context learning. However, the second response has some redundant outputs (no eos token was found in the second response).

Have you implemented per-request cache clearing? Great work here as usual 😃

Do we need to clear kv cache for each request? I thought kv cache could be used for each session (each session may have multiple requests) for context learning.

Do we need to clear kv cache for each request? I thought kv cache could be used for each session (each session may have multiple requests) for context learning.

If users deploy candle-vllm to a system with multiple chat interactions interleaved, we do not want the KV cache to be shared across requests. I think the right way to do this is to clear the KV cache when a sequence finishes (this is what we do in mistral.rs). There is also prefix caching, which can be used to allow faster in-context learning.

Do we need to clear kv cache for each request? I thought kv cache could be used for each session (each session may have multiple requests) for context learning.

If users deploy candle-vllm to a system with multiple chat interactions interleaved, we do not want the KV cache to be shared across requests. I think the right way to do this is to clear the KV cache when a sequence finishes (this is what we do in mistral.rs). There is also prefix caching, which can be used to allow faster in-context learning.

Yes, there is a kv cache leak problem because only one cache_engine instance is used for the entire lifetime of llm_engine. One solution is to create the cache_engine on a per-session basis, allowing multiple requests within a session (from a single user) to share the kv cache. This cache should be cleared after the session ends or automatically if the server's cache is nearly full. Another strategy, as you suggested, is to clear the kv cache after each request and rebuild the session context using prefix caching (this is new to me) or by recomputing the session's chat history.


unzip not available to workflow execution

Description
The self hosted runner still has issues with unzip, I have seen a couple other issues for this quickly dismissed but it appears to remain unresolved.
I am deploying the action operator and secret runner set on a k3s node using this script.
#!/bin/bash
# Scripted installment of Github Actions Self Hosted Runners

# Define namespace
NAMESPACE="arc-systems"
echo "Namespace: ${NAMESPACE}"

# Helm install runner operator
echo "Installing runner operator"
helm install arc \
    --namespace "${NAMESPACE}" \
    --create-namespace \
    --values ./values.yaml \
    oci://ghcr.io/actions/actions-runner-controller-charts/gha-runner-scale-set-controller

# Add secret for Github authorization
echo "Creating secret for Github"
kubectl create secret generic pre-defined-secret \
   --namespace="${NAMESPACE}" \
   --from-literal=github_app_id=MY_APP_ID \
   --from-literal=github_app_installation_id=MY_INSTALLATION_ID \
   --from-literal=github_app_private_key="-----BEGIN RSA PRIVATE KEY-----
-----END RSA PRIVATE KEY-----"

# Install Runner Set
echo "Installing runner set"
RUNNER_INSTALLATION_NAME="ubuntu.20.04.amd64"
GITHUB_CONFIG_URL="https://github.com/Combyne-Ag"
helm install "${RUNNER_INSTALLATION_NAME}" \
    --namespace "${NAMESPACE}" \
    --create-namespace \
    --set githubConfigUrl="${GITHUB_CONFIG_URL}" \
    --set githubConfigSecret="pre-defined-secret" \
    oci://ghcr.io/actions/actions-runner-controller-charts/gha-runner-scale-set

I have tried two different AMI's to rule out a host OS issue.
ami-0e001c9271cf7f3b9: us-east-1 - Jammy Jellyfish - v22.04 LTS - amd64 - hvm:ebs-ssd - 20240411
ami-061612d72693df8ce: us-east-1 - Focal Fossa - v20.04 LTS - amd64 - hvm:ebs-ssd - 20240416
I have tried both pinning the version of the operator and runner set at 0.9.0 and 0.9.1, neither work.
I have tested this with the Github hosted ubuntu-latest which works without issue, however on my self hosted runners deployed as described above this does not work.

Platforms affected

[ ] Azure DevOps
[ ] GitHub Actions - Standard Runners
[ ] GitHub Actions - Larger Runners

Runner images affected

[X] Ubuntu 20.04
[X] Ubuntu 22.04
[ ] macOS 11
[ ] macOS 12
[ ] macOS 13
[ ] macOS 13 Arm64
[ ] macOS 14
[ ] macOS 14 Arm64
[ ] Windows Server 2019
[ ] Windows Server 2022

Image version and build link
helm versions
gha-runner-scale-set-controller-0.9.1	0.9.1
gha-runner-scale-set-0.9.1           	0.9.1
gha-runner-scale-set-controller-0.9.0	0.9.0
gha-runner-scale-set-0.9.0           	0.9.0
Is it regression?
no
Expected behavior
Expected: the unzip utility should be installed AND executable to workflow executions
Actual behavior
As shown in the image, unzip is not executable
Repro steps
Step 1 - Execute shell script to install operator and secret runner
Step 2 - Trigger workflow on self hosted runner

After digging into several threads in various actions repos and documentation I have concluded that the runner images are actually by design 'bare' for self hosted runners compared to the github hosted runner images. Closing this issue but suggesting the documentation about this be improved


Fix RuntimeError for moe on XPU: tensors found at least two devices

There is following error on XPU while unit testing "DeepSpeed/tests/unit/moe/test_moe.py"
DeepSpeed/deepspeed/moe/sharded_moe.py line 223, in top1gating
RuntimeError: Expected all tensors to be on the same device, but found at least two devices, xpu:0 and cpu!
Fix it by device conversion.

Hi @loadams, could you help review this PR? This PR makes the syntax more reasonable and fix issue on XPU.


BUG: interpolate.Akima1DInterpolator: different values on subsequent calls

Describe your issue.
The first and third calls to Akima1DInterpolator pass the same parameters but the results are different. The result of the first and third call is the same if the second call is removed:
Reproducing Code Example
import numpy as np
import scipy

x = np.array([0.0, 1.0], dtype=float)
y = np.array([0.55, 0.55])
akima = scipy.interpolate.Akima1DInterpolator(x, y, axis=0, extrapolate=None)
print(akima(0.45))

x = np.array([0.0, 0.5, 1.0])
y = np.array([0.15, 0.67, 0.15])
akima = scipy.interpolate.Akima1DInterpolator(x, y, axis=0, extrapolate=None)
print(akima(0.45))

x = np.array([0.0, 1.0])
y = np.array([0.55,  0.55])
akima = scipy.interpolate.Akima1DInterpolator(x, y, axis=0, extrapolate=None)
print(akima(0.45))

Error message
Output:

0.55
0.6648000000000001
0.2926

SciPy/NumPy/Python version and system information
1.14.1 1.26.4 sys.version_info(major=3, minor=10, micro=7, releaselevel='final', serial=0)
Build Dependencies:
  blas:
    detection method: pkgconfig
    found: true
    include directory: C:/Users/runneradmin/AppData/Local/Temp/cibw-run-_mbvtoth/cp310-win_amd64/build/venv/Lib/site-packages/scipy_openblas32/include
    lib directory: C:/Users/runneradmin/AppData/Local/Temp/cibw-run-_mbvtoth/cp310-win_amd64/build/venv/Lib/site-packages/scipy_openblas32/lib
    name: scipy-openblas
    openblas configuration: OpenBLAS 0.3.27.dev DYNAMIC_ARCH NO_AFFINITY Zen MAX_THREADS=24
    pc file directory: D:/a/scipy/scipy
    version: 0.3.27.dev
  lapack:
    detection method: pkgconfig
    found: true
    include directory: C:/Users/runneradmin/AppData/Local/Temp/cibw-run-_mbvtoth/cp310-win_amd64/build/venv/Lib/site-packages/scipy_openblas32/include
    lib directory: C:/Users/runneradmin/AppData/Local/Temp/cibw-run-_mbvtoth/cp310-win_amd64/build/venv/Lib/site-packages/scipy_openblas32/lib
    name: scipy-openblas
    openblas configuration: OpenBLAS 0.3.27.dev DYNAMIC_ARCH NO_AFFINITY Zen MAX_THREADS=24
    pc file directory: D:/a/scipy/scipy
    version: 0.3.27.dev
  pybind11:
    detection method: config-tool
    include directory: unknown
    name: pybind11
    version: 2.12.0
Compilers:
  c:
    commands: cc
    linker: ld.bfd
    name: gcc
    version: 10.3.0
  c++:
    commands: c++
    linker: ld.bfd
    name: gcc
    version: 10.3.0
  cython:
    commands: cython
    linker: cython
    name: cython
    version: 3.0.11
  fortran:
    commands: gfortran
    linker: ld.bfd
    name: gcc
    version: 10.3.0
  pythran:
    include directory: C:\Users\runneradmin\AppData\Local\Temp\pip-build-env-w8i5lw_j\overlay\Lib\site-packages/pythran
    version: 0.16.1
Machine Information:
  build:
    cpu: x86_64
    endian: little
    family: x86_64
    system: windows
  cross-compiled: false
  host:
    cpu: x86_64
    endian: little
    family: x86_64
    system: windows
Python Information:
  path: C:\Users\runneradmin\AppData\Local\Temp\cibw-run-_mbvtoth\cp310-win_amd64\build\venv\Scripts\python.exe
  version: '3.10'

Confirmed. Wow. The last result is nonsense. And it depends on previous calls, so it's some unitialized memory. And indeed, changing np.empty to np.zeros in https://github.com/scipy/scipy/blob/main/scipy/interpolate/_cubic.py#L511 fixes the immediate problem.
I'm not immediately convinced that np.zeros is the right fix though.
Clearly, the Akima1D code is not expecting len(x) == 2.
Note that PchipInterpolator bails out early in this case: https://github.com/scipy/scipy/blob/main/scipy/interpolate/_cubic.py#L282
So I believe this would be the right fix: detect that x.shape[0] == 0 and return a linear interpolant. Would you be interested in sending a fix @DougGard ?

I've never looked into SciPy code, not sure I would be the best person for this.

No worries, we all started somewhere :-).
The fix should go around this line, I'd think: https://github.com/scipy/scipy/blob/main/scipy/interpolate/_cubic.py#L510

When the inputs have length 2, m has length 5, and the interior points are computed in
https://github.com/scipy/scipy/blob/846ecd4648c3da29bfc1e05f7487c3fa047c94ca/scipy/interpolate/_cubic.py#L513-L513
which fills in just the single point m[2].  But in
https://github.com/scipy/scipy/blob/846ecd4648c3da29bfc1e05f7487c3fa047c94ca/scipy/interpolate/_cubic.py#L516
the value at m[3] is referenced.
So it looks like the case where the length is 2 needs to be handled separately, as @ev-br suggested above.


Encountered error while trying to install package lapsolver

I have cloned this repo in my python virtual environment.  While trying to install packages in requirements.txt using pip getting the following error.
error: subprocess-exited-with-error
× python setup.py bdist_wheel did not run successfully.
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for lapsolver
error: legacy-install-failure

This looks like a version issue. Maybe try running pip install wheel in the environment.


Could not load file or assembly

Describe the bug
Can not install the library.
System information

OS: Raspbian
.Net Core version 3

Additional context
Unhandled exception. System.BadImageFormatException: Could not load file or assembly '/home/pi/.dotnet/tools/.store/microsoft.quantum.iqsharp/0.10.1911.1607/microsoft.quantum.iqsharp/0.10.1911.1607/tools/netcoreapp3.0/any/Microsoft.Quantum.IQSharp.dll'. An attempt was made to load a program with an incorrect format.
File name: '/home/pi/.dotnet/tools/.store/microsoft.quantum.iqsharp/0.10.1911.1607/microsoft.quantum.iqsharp/0.10.1911.1607/tools/netcoreapp3.0/any/Microsoft.Quantum.IQSharp.dll'

Bad image format makes it sound like you're running on a different processor architecture (e.g.: x86 vs x64 vs ARM). From your bug report, it looks like you're running on a Raspberry Pi, which is ARM-based. We haven't yet officially tested on ARM yet, I don't think, so you may be running into issues due to that.
+@anpaz-msft

@cgranade Thank you, looking forward to test when its arrive.

@cgranade I tried build and it seems working fine.
`pi@raspberrypi:~/iqsharp$ dotnet build iqsharp.sln
Microsoft (R) Build Engine version 16.3.0+0f4c62fea for .NET Core
Copyright (C) Microsoft Corporation. All rights reserved.
Restore completed in 68.93 ms for /home/pi/iqsharp/src/Core/Core.csproj.
Restore completed in 55.17 ms for /home/pi/iqsharp/src/Jupyter/Jupyter.csproj.
Restore completed in 81.32 ms for /home/pi/iqsharp/src/Tool/Tool.csproj.
Restore completed in 7.72 ms for /home/pi/iqsharp/src/Web/Web.csproj.
Restore completed in 22.64 sec for /home/pi/iqsharp/src/Tests/Tests.IQsharp.csproj.
Core -> /home/pi/iqsharp/src/Core/bin/Debug/netstandard2.1/Microsoft.Quantum.IQSharp.Core.dll
Web -> /home/pi/iqsharp/src/Web/bin/Debug/netcoreapp3.0/Microsoft.Quantum.IQSharp.Web.dll
Jupyter -> /home/pi/iqsharp/src/Jupyter/bin/Debug/netstandard2.1/Microsoft.Quantum.IQSharp.Jupyter.dll
Tool -> /home/pi/iqsharp/src/Tool/bin/Debug/netcoreapp3.0/Microsoft.Quantum.IQSharp.dll
Mocks.cs(40,38): warning CS0067: The event 'MockShell.KernelInfoRequest' is never used [/home/pi/iqsharp/src/Tests/Tests.IQsharp.csproj]
Mocks.cs(42,38): warning CS0067: The event 'MockShell.ShutdownRequest' is never used [/home/pi/iqsharp/src/Tests/Tests.IQsharp.csproj]
Mocks.cs(41,38): warning CS0067: The event 'MockShell.ExecuteRequest' is never used [/home/pi/iqsharp/src/Tests/Tests.IQsharp.csproj]
Tests.IQsharp -> /home/pi/iqsharp/src/Tests/bin/Debug/netcoreapp3.0/Tests.IQsharp.dll
Build succeeded.
Mocks.cs(40,38): warning CS0067: The event 'MockShell.KernelInfoRequest' is never used [/home/pi/iqsharp/src/Tests/Tests.IQsharp.csproj]
Mocks.cs(42,38): warning CS0067: The event 'MockShell.ShutdownRequest' is never used [/home/pi/iqsharp/src/Tests/Tests.IQsharp.csproj]
Mocks.cs(41,38): warning CS0067: The event 'MockShell.ExecuteRequest' is never used [/home/pi/iqsharp/src/Tests/Tests.IQsharp.csproj]
3 Warning(s)
0 Error(s)
Time Elapsed 00:01:11.77`

Exciting that dotnet build worked! Can you try installing IQ# in development mode (see code snippet below), perhaps, to see if that works? I would expect %simulate to fail, since the QuantumSimulator target machine is compiled against x64, but %toffoli_simulate might hopefully work.
cd ~/iqsharp/src/Tool
dotnet run -- install --develop

@cgranade Unfortunately, received the same error.
Unhandled exception. System.BadImageFormatException: Could not load file or assembly '/home/pi/iqsharp/src/Tool/bin/Debug/netcoreapp3.0/Microsoft.Quantum.IQSharp.dll'. An attempt was made to load a program with an incorrect format.
File name: '/home/pi/iqsharp/src/Tool/bin/Debug/netcoreapp3.0/Microsoft.Quantum.IQSharp.dll'

@beraybentesen: When does that error occur? Can you run dotnet run -- --version from src/Tool? Thanks for the help in sorting this out!

I suspect the problem is not on loading IQ# but one of its dependencies. In particular, I know the Simulator dll is built for x64. I can't remember if the Q# compiler library is x64 specific too (probably not).
You will need to build an ARM version of the Q# runtime (https://github.com/microsoft/qsharp-runtime). Probably one that does not include the QuantumSimulator unless you're willing to go through the effort of building the C++ simulator too. Then you can update your references to use that.

@cgranade I receive the following response:
dotnet run -- --version
Unhandled exception. System.BadImageFormatException: Could not load file or assembly '/home/pi/iqsharp/src/Tool/bin/Debug/netcoreapp3.0/Microsoft.Quantum.IQSharp.dll'. An attempt was made to load a program with an incorrect format.
File name: '/home/pi/iqsharp/src/Tool/bin/Debug/netcoreapp3.0/Microsoft.Quantum.IQSharp.dll'
@anpaz-msft Thank you for the info.
I tried the following commands:
dotnet publish src/Simulation/CsharpGeneration.App
dotnet build Simulation.sln
And received the error after running second one:
/home/pi/dotnet-arm32/sdk/3.0.100/Microsoft.Common.CurrentVersion.targets(4563,5): error MSB3030: Could not copy the file "/home/pi/qsharp-runtime/src/Simulation/Native/build/Release/Microsoft.Quantum.Simulator.Runtime.dll" because it was not found. [/home/pi/qsharp-runtime/src/Simulation/Simulators/Microsoft.Quantum.Simulators.csproj]
46 Warning(s)
1 Error(s)
I'd like to get things working if you might share a short guidance if possible.
Thanks,

@cgranade Is there anything you would recommend ? We are willing to implement solution for our arm based cluster. Best,


Log the time to index a batch of task

This was proposed by @qdequele in a private conversation and I think it’s a nice addition.

Bors merge


Developing a download & extract module for SparseBase and, its integration to SparseBase

Developing a download&extract module for users to save them the trouble of doing this process manually.
-Avoid external libraries such as libarchive due to dependency problems. Instead, use header-only libraries,
-Integrate this module into the SparseBase. Place this module utils/io folder and under the io namespace,
-Create tests

Maybe for downloaders of specific sites (SuiteSparse for instance,) we can name matrices with specific names depending on their use. For example, the main matrix can always be called "Matrix", and if an additional vector is present, we can call it "Solution". Can make users' experience nicer.

Maybe for downloaders of specific sites (SuiteSparse for instance,) we can name matrices with specific names depending on their use. For example, the main matrix can always be called "Matrix", and if an additional vector is present, we can call it "Solution". Can make users' experience nicer.

I am using unordered_map to keep <matrixName, path> pairs, maybe after I added all the files in the directory I can add the "Matrix" key which has the main matrix path. By the way, as I mentioned in the last meeting, there are some matrices that have multiple files alongside the main matrices, so calling the additional vector "Solution" might not work for those cases, because there might be multiple additional vectors.

That would make sense. Yeah, you're right. We could scrape the entire database and manually name these different matrices. It's not too crazy of an idea since we're building a class specifically for that data source, but I think we need to know the scale of the database. Do you know how many matrices there are in SuiteSparse?

I didn't get the idea. Why do we scrape the entire database? To find the matrices that have multiple files? By the way, there are 2893 matrices in total in the Suitesparse.

Yes, exactly. We can classify them into categories based on how many matrices there are and give these categories names. At least we can get an idea about how many have more than one matrix.


Support Managed Envoy Service Type

support ClusterIP for inner cluster proxy
support Loadbalancer for edge proxy
but doesn't support NodePort
ref: https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services-service-types

[ ] provide custom proxy service spec API
[ ] doc

pls assign to me

@qicz can you elaborate on which specific fields in the Envoy Service you would like to customize and why ?

@qicz can you elaborate on which specific fields in the Envoy Service you would like to customize and why ?

clusterip or loadbalancer

+1 for ClusterIP and Loadbalancer type https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services-service-types. Can you please update the GH issue to be specific about this feature .
sidenote - I dont think we can support Nodeport unless we are allowed to specify ip:port in Status.Addresses. https://gateway-api.sigs.k8s.io/references/spec/#gateway.networking.k8s.io%2Fv1beta1.GatewayAddress
would this be okay @youngnick  ?

+1 for ClusterIP and Loadbalancer type https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services-service-types. Can you please update the GH issue to be specific about this feature .
sidenote - I dont think we can support Nodeport unless we are allowed to specify ip:port in Status.Addresses. https://gateway-api.sigs.k8s.io/references/spec/#gateway.networking.k8s.io%2Fv1beta1.GatewayAddress would this be okay @youngnick ?

@arkodg updated, can you review again?

went ahead and also updated title, thanks in advance for working on this @qicz !

should EG provide ClusterIP and Loadbalancer and same time? or multi Loadbalancer service?
one case is provide internal lb and internet lb at the same time.

should EG provide ClusterIP and Loadbalancer and same time? or multi Loadbalancer service?
one case is provide internal lb and internet lb at the same time.

imo, the two type don't have to exist at the same time.
clusterip, just for internal
Loadbalancer can work for internal with eg svc  and for internet diretly

should EG provide ClusterIP and Loadbalancer and same time? or multi Loadbalancer service?
one case is provide internal lb and internet lb at the same time.

can't the client connect directly using Loadbalancer IP or Service FQDN ?

I'm saying multi services for one EnvoyProxy.

I'm saying multi services for one EnvoyProxy.

curious why, isn't Loadbalancer a superset of ClusterIP ?

Sorry, my previous information may have been a bit misleading.
So the key point is will EG allow multi services for one Gateway/EnvoyProxy?

Sorry, my previous information may have been a bit misleading.
So the key point is will EG allow multi services for one Gateway/EnvoyProxy?

can you please clarify with an example

@arkodg I'm thinking make EnvoyService to slice
https://github.com/envoyproxy/gateway/blob/384577334dea2c0ba28800643a2b94fea4eed244/api/config/v1alpha1/envoyproxy_types.go#L95

@arkodg I'm thinking make EnvoyService to slice
https://github.com/envoyproxy/gateway/blob/384577334dea2c0ba28800643a2b94fea4eed244/api/config/v1alpha1/envoyproxy_types.go#L95

can you share why  ?

@qicz can you add user face doc?

@qicz can you add user face doc?

#1203 did this, thanks @Xunzhuo

supported by #1205， #1286


Need help with ASIO

Hello! I'm trying to make a Discord bot that will be able to stream audio from an ASIO device. The library I use has the following method for sending audio:
WriteAsync(byte[] buffer, int offset, int count)
(the documentation says audio should be in PCM S16LE format at 48000 Hz).
And I know that I can attach a listener to AsioOut.AudioAvailable and get a float[] using e.GetAsInterleavedSamples()
But how do I convert it to byte[]?
I found this method somewhere:
public static byte[] GetSamplesWaveData(float[] samples, int samplesCount) {

    byte[] pcm = new byte[samplesCount * 2];
    int sampleIndex = 0, pcmIndex = 0;

    while(sampleIndex < samplesCount) {

	short outsample = (short) (samples[sampleIndex++] * short.MaxValue);
	pcm[pcmIndex] = (byte) (outsample & 0xff);
	pcm[pcmIndex + 1] = (byte) ((outsample >> 8) & 0xff);

	pcmIndex += 2;

    }

    return pcm;

}

But the audio that comes out from the bot is extremely distorted and only in the left channel.
Here is the listener I attached to AsioOut:
private async void OnAudioAvailable(object? sender, AsioAudioAvailableEventArgs e) {

    float[] samples = e.GetAsInterleavedSamples();

    await transmit.WriteAsync(GetSamplesWaveData(samples, samples.Length), 0, samples.Length);

}

Can you help me solve this problem? Am I passing the wrong parameters somewhere or is this method simply incorrect and I should do something else?
Also a note: I don't need the audio to be fully real-time, it's fine if solution creates a second or two of delay.

Closing this since I no longer need to make the bot. However I would still be interested in hearing what the solution to this could be


Update sortDependencies to 0.9

https://github.com/square/gradle-dependencies-sorter/blob/main/CHANGELOG.md#version-09

still seeing a couple bugs I wanna look into before merging


ImageNotSelectedError after using .read

I can successfully use RTesseract in this way:
filename = 'path/to/foo.jpg'
image = RTesseract.new(filename)
puts image.to_s

When I use .read to try and transform the image exactly as in the example on the read me, though...
filename = 'path/to/foo.jpg'
image = RTesseract.read(filename) do |img|
  img = img.white_threshold(245)
  img = img.quantize(256,Magick::GRAYColorspace)
end
puts image.to_s

I get .../gems/rtesseract-1.3.0/lib/rtesseract.rb:228:in `to_s': RTesseract::ImageNotSelectedError (RTesseract::ImageNotSelectedError)
I get that same error even if I merely do
  image = RTesseract.read(filename) do |img| end
  puts image.to_s

I have confirmed that RMagic is being used and that inside the block img is an instance of Magick::Image

After poking around the source code, I think I have identified the problem.
The image I was testing would normally return an empty string (which is ok, since there was no text. I'm trying to identify images with text from a large collection of images).
So after .read yields image to the block, it creates a new RTesseract object from the to_blob of the image. Doing this also eager loads @value. In my case, tesseract correctly thinks that the image has no text and returns empty string. .to_s assumes that if @value == '' then the image hasn't yet been processed and tried to recalculate @value, but throws an error when it can't.
So the problem ultimately stems from the fact that there is no distinction between an empty string OCR result and @results default value.


abc

Type: Feature Request
dsdsfdsddssds
VS Code version: Code 1.73.1<PHONE_NUMBER>f055b99068d3688932416f2346dd3b, 2022-11-09T04:27:29.066Z)
OS version: Windows_NT x64 10.0.22621
Modes:
Sandboxed: No

Thanks for creating this issue! It looks like you may be using an old version of VS Code, the latest stable release is 1.74.2. Please try upgrading to the latest version and checking whether this issue remains.
Happy Coding!

If you have an issue using VS Code, please let us know with more details. Thank you!


iot alexa integration

can you do it like that?
This is for iot Cloud. Alexa.
"common": {
"name": "Brightness of the light",
"type": "number",
"role": "value.brightness",
"read": true,
"unit": "",
"write": true,
"min": 0,
"max": 254,
"def": 0
},
"min": 0,
"max": 254,
"def": 0

Alexa = 100.. not 255
There must be no point numbers. hence 254
10,20,30,% that works with alexa and wled (brightness)
or program so that no point numbers can arise. or don't care
and..
"type": "state",
"common": {
"name": "Primary Color HEX",
"type": "mixed",
"role": "level.color.hex",
"read": true,
"unit": "",
"write": true,
"smartName": false
},
switch to:
"role": "level.color.rgb", ... not hex

in iot for alexa this role does not exist (hex)
then it can be integrated into iot without problems for alexa

i will discuss the in our dev meeting, bulbs have values 0-100 or 0-255, the WLED Api does use 0-255.
IF I change this now it will be breaking for current installation and I am wondering if I should do it in the code or the iOT adapter should handle it

if min/max is set correctly then iot adapter should be able to transfer an 1..100% value to the real value. If this is not done it should be an iot issue

if min/max is set correctly then iot adapter should be able to transfer an 1..100% value to the real value. If this is not done it should be an iot issue

thanks understood, indeed the min/max is not set for brightness will update the code to do that.


<EMAIL_ADDRESS>hash check failed

Installing 'teamviewer' (15.4.8332) [64bit]
TeamViewerPortable.zip (32.8 MB) [============================================================================] 100%
Checking hash of TeamViewerPortable.zip ... ERROR Hash check failed!
App:         extras/teamviewer
URL:         https://download.teamviewer.com/download/version_15x/TeamViewerPortable.zip
First bytes: 50 4B 03 04 14 00 02 00
Expected:    a24222de4478153c6b6c101c8d11a041498474a5a18aba65003b53ec241d7530
Actual:      c560f287766b50458740f7a0d60596614cccbc46cc3c51ff8d633eb18fe13163
Please try again or create a new issue by using the following link and paste your console output:
https://github.com/lukesampson/scoop-extras/issues/new?title=teamviewer%4015.4.8332%3A+hash+check+failed

Hi @r15ch13, sorry to bother.. I know I WAS right... but now the expected hash is different and indeed it's the previous value... I wonder if they have different locations where they are distributing the zip and for some reasons one of the zip has a different hash...
Please see the error below
Installing 'teamviewer' (15.4.8332) [64bit]
TeamViewerPortable.zip (32.8 MB) [============================================================================] 100%
Checking hash of TeamViewerPortable.zip ... ERROR Hash check failed!
App:         extras/teamviewer
URL:         https://download.teamviewer.com/download/version_15x/TeamViewerPortable.zip
First bytes: 50 4B 03 04 14 00 02 00
Expected:    a24222de4478153c6b6c101c8d11a041498474a5a18aba65003b53ec241d7530
Actual:      c560f287766b50458740f7a0d60596614cccbc46cc3c51ff8d633eb18fe13163
Please try again or create a new issue by using the following link and paste your console output:
https://github.com/lukesampson/scoop-extras/issues/new?title=teamviewer%4015.4.8332%3A+hash+check+failed

Hm, maybe a/b testing or a CDN was late on the update.

Or maybe one of the versions contains a virus... given the corona crisis,
everyone is using these tools and it is super possible that they have been
hacked...
On Thu, 9 Apr 2020 at 23:59, Richard Kuhnt<EMAIL_ADDRESS>wrote:

Hm, maybe a/b testing or a CDN was late on the update.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/lukesampson/scoop-extras/issues/3827#issuecomment-611773427,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AB7PNWPIWQNSCXZKMNKRXHLRLZANFANCNFSM4MFAKFWQ
.

--
There is no death... there is the Force

Can you open a new issue. I can't revert it right now. The bot will also run it's check again.


rn-carousel-locked is not fully implemented

rn-carousel-locked="true" doesn't work for me, partly due to the way i'm using this carousel. (Really all I want to do is disable swiping)
Regardless of how I'm using the carousel, there are still several bugs:
*1) Changing the slide is still possible using the controls, because: scope.nextSlide() and scope.prevSlide() are inconsistent. Only nextSlide() checks the 'locked' variable.
*2) Changing the slide is still possible by changing the value of rn-carousel-index.
*3) Navigating to another slide (via *2) will set 'locked' to false. iAttributes.rnCarouselLocked is then ignored because it's only checked once, and that's not enough.
I suggest creating a function like so:
function isLocked() {
    return locked || iAttributes.rnCarouselLocked;
}

and change all instances of if(locked) to if(isLocked()).
Once that's done, you can remove this code:
if (iAttributes.rnCarouselLocked) {
    scope.$watch(iAttributes.rnCarouselLocked, function(newValue, oldValue) {
        // only bind swipe when it's not switched off
        if(newValue === true) {
            locked = true;
        } else {
            locked = false;
        }
    });
}

Also, please re-add an attribute to allow us to disable swiping and add if(isLocked())return; to the beginning of the swipeStart method (actually, it should be something like if(isLocked() || isSwipingDisabled)return;.

I am just trying to disable swipe also, @wbyoko did you find a fix?

Not at that point. I hide controls in situations but swipe was still available.
Does seem like functionality that should be there.

is there a solution for this?


Data Definitions page not accessible through nav

The Data Definitions stem article page no longer surfaces in the docs navigation bar and must be browsed to directly:
https://www.cockroachlabs.com/docs/data-definition.html

As just discussed offline, in the absence of a better solution, we'll move constraints up one level as well as indexes. The rest of the topics will stay under Data Definitions for now.

We have an issue to break constraints into separate pages. And we could still consider moving Constraints, Indexes, and maybe other topics out from this section. But in any case, the data-definitions.md stub no longer adds any value, since it just replicates what's shown in the sidenav, so I'll remove it.


Eigen moved to gitlab

Build with Clang works only if C++ standard is changed from C++11 to C++14. Closing PR for now and will reopen once nGraph moves to C++14 or later standard.


Prepare POGOLib for distribution

Hi, I saw issue #7 this week and decided I could give this a go because I want to integrate this in a Xamarin.iOS project, and that's impossible in it's current state, while with some changes it's easily doable.
I did the following to improve the distributability and compatibility with other platforms:

Convert the project to a PCL with profile 78.
Refactor the code to work asynchronous as in it's current state it freezes during session creation.
Remove the dependency on log4net as platform support for it is pretty bad.

Unfortunately I'm tied to working with Xamarin Studio, and I can't seem to get HttpClient working in console apps on my Mac. So I updated the demo, but I'm not sure if it works.
Also, the formatting seems to be a little different from Visual Studio, and especially csproj and xml changes edit the tab width, and I can't seem to change this effectively from Studio.
If you find this useful and want me to fix the differences with Visual Studio I guess I could ring up an installation, but I'd like to hear your thoughts first!
(This implementation is tested on iOS, and it works great there! So thanks for this project, saves me a lot of time!)

Hmm, so it seems that MSBuild is a lot stricter on Windows than on Mac. So I might have to switch out the System.Device.Location.Portable package.

I've merged a PR which should solve your System.Device.Location.Portable issue. I like your async changes but I haven't heard of "PCL with profile 78" before, I'll read into that.
Can't really look deep into the other things as I don't have access to a pc until 8 August. :(

No problem, no rush 😄
I'll rebase this on the latest changes.
A portable class library (PCL) is mostly a regular library, but it doesn't have any access to platform specific assemblies (directly). And since your code was already really portable (platform independent), it wasn't much of a problem, just a matter of finding the right packages on NuGet.
In the coming months the .NET Standard Library will compliment this further, but support on other platforms isn't that great yet, but that'll change in the fall.

It's a shame the Template functionality was added as is, because it uses the file system, and you can't do that from a portable library. I don't think I exactly understand what it does, but there's multiple ways to fix this.
What I'd normally do for a simple caching-like structure is use Akavache, so I'm gonna go ahead and use that. Mostly because I want to go further with my own project, but I can imagine this might be up for debate.

Ok, so I think I'll be done for now. 😉
I've reverted back to S2Geometry 1.0.1 since the last PR, because it uses a NETStandard profile, and Xamarin Studio doesn't like that very much yet. I can't satisfy all dependencies when I use that version.

@Qonstrukt Hey, it has been some time and lots of changes have been made since this PR.
I'd love to target multiple frameworks (iOS, Android, other .NET frameworks versions).
I already have NuGet packaging setup correctly but wish to add the above too.
Could you help accomplish? I don't really have experience in targeting multiple frameworks in one project.

https://github.com/AeonLucid/POGOLib/tree/pcl

@AeonLucid Go to bed.

No need to target multiple platforms - just make the target of the library Profile 78 or 259 (latter is preferred for its broader reach, and as POGOLib does not use WCF, it's fine).

I guess we can close this PR as it seems all the work has been done now. Would've been easier to just merge it though. 😉
I wouldn't target profile 259 though, as I can't see why anyone would still want to use this in a Silverlight app. I honestly think profile 111 is the best choice as it targets all the relevant recent platforms, but there were some problems with the new NETStandard dependencies on NuGet which prevented me from choosing 111. Unfortunately that bug still isn't fixed: https://github.com/dotnet/corefx/issues/10445

Well to be honest I just ported a good majority of the code (including Geocoordinateportable and GPSOAuth) to netstandard1.3 (1.0 through 1.2 is not going to work due to the System.Security.Cryptography libraries. Sure we could use some portable crypto for the GPSOAuth RSA and SHA stuff, but that's about it), and made a pull request.
RuntimeInformation is not necessary in my opinion - given the diversity of platforms supported by .Net Core (and .Net Standard), there's little performance increase in using xxHash64 (as most legal use cases will not be bots, but re-makes of the game for e.g. UWP, and a majority will be ARM-based with limited RAM bandwidth, even on 64-bit ARM platforms the speeds won't be higher using the 64 bit variant).

https://github.com/AeonLucid/POGOLib/tree/proper-pcl

Well, I fetched the proper-pcl branch this afternoon, and I'm using it now. Besides the issues pointed out in PR #42, I have little problems with it, and I noticed you're using profile 111 right now, which seems fine to me. (Native HttpClient etc.)
I also noticed some packages included as sub modules, the same packages that depend on RuntimeInformation which are impossible to install currently, so I'm guessing you did this to circumvent that issue.
I would recommend looking into a service locator like Splat's (not necessarily Splat's of course) to ease the use of different IDataCache implementations and allow testing projects to more easily inject other variations.

FWIW, you can use netstandard for any project type. Xamarin supports it too now, so there's really no reason to create a profile-based PCL anymore.

This is a bit outdated now and we are now running on .NetStandard1.1. Closing this PR.


Question: migration-v7 - cucumber-style/playwright.config.ts incorrect

https://github.com/vitalets/playwright-bdd/blob/main/examples/cucumber-style/playwright.config.ts
Hi According to V7, the config should be different above from
https://vitalets.github.io/playwright-bdd/#/guides/migration-v7?id=new-steps-option
Can u suggest if changes are dual? old and new works ?

@Deepa-Mahesh-P good point! I will update config in docs, thank you.

Can u suggest if changes are dual? old and new works ?
Old config works as well. That's why example tests didn't catch it :)

Can we have 2  config files then and scripts pointing to these then
Get Outlook for Androidhttps://aka.ms/AAb9ysg

From: Vitaliy Potapov @.>
Sent: Monday, July 8, 2024 10:43:35 AM
To: vitalets/playwright-bdd @.>
Cc: Deepa-Mahesh-P @.>; Mention @.>
Subject: Re: [vitalets/playwright-bdd] Question: migration-v7 - cucumber-style/playwright.config.ts incorrect (Issue #173)
@Deepa-Mahesh-Phttps://github.com/Deepa-Mahesh-P good point! I will update config in docs, thank you.
Can u suggest if changes are dual? old and new works ?
Old config works as well. That's why example tests didn't catch it :)
—
Reply to this email directly, view it on GitHubhttps://github.com/vitalets/playwright-bdd/issues/173#issuecomment-2214283136, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AVS5MJ3CP5NW6V5SHQAX7YLZLKQRPAVCNFSM6AAAAABKPXWDWKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDEMJUGI4DGMJTGY.
You are receiving this because you were mentioned.Message ID: @.***>

Similarly Vitaly, if you suggest its ok. I can create sample projects with Cucumber-BDD/Saucelabs/Lambdatest/[Additional Appium driver i can add], Page objects pattern etc .. can we add it as a Git submodule instead. w can keep adding samples and ask others top contribute

Can we have 2  config files then and scripts pointing to these then .. i can Do a PR then?

I've made it this way - let's keep examples as simple as possible, I think two configs can be confusing:
// before playwright-bdd v7
const testDir = defineBddConfig({
  paths: ['features'],
  require: ['steps/*.ts'],
  importTestFrom: 'steps/fixtures.ts',
});

// since playwright-bdd v7
/*
const testDir = defineBddConfig({
  features: './features',
  steps: './steps',
});
*/

Similarly Vitaly, if you suggest its ok. I can create sample projects with Cucumber-BDD/Saucelabs/Lambdatest/

I like it. I suggest to put such examples into separate GitHub repos, I can add links to readme.

ok ..


Linting fails with Helm v3.8.2 or later

When running the pre-commit hook with a Helm binary v3.8.2 or later (possibly earlier versions as well), the hook will always fail with:
==> Linting *.tgz
Error unable to open tarball: open *.tgz: The filename, directory name, or volume label syntax is incorrect

The problem is ultimately caused by this line, which specifies the chart as *.tgz, rather than f"{quote(chartName)}-{quote(chartVersion)}.tgz".
I'm not familiar enough with Helm artifacts to confirm that f"{quote(chartName)}-{quote(chartVersion)}.tgz" covers every use case, but if somebody else can confirm then I can create a PR to fix the issue.

Just checked with the latest helm version and on my end it still works with the *.tgz, so I think this isn't related to the helm version but maybe based on your shell/os.
Independent of this, I think your change makes sense anyway, as it's more explicit/correct, if you can create a PR that would be great

Opened here: https://github.com/tarioch/flux-check-hook/pull/3
What platform/shell are you using? I'd like to verify the issue for my own sanity

Merged, thanks a lot. I'm using bash

Unfortunately this doesn't work if you have version wildcards. E.g.
helm pull --repo https://docs.renovatebot.com/helm-charts --version 32.x renovate

pulls down a file called renovate-32.118.0.tgz

I'm reverting this for now


private registry ECR credentials not working in v1.27.8-rancher2-2

Rancher Server Setup

Rancher version: v2.8.1
Installation option: Docker Install
Proxy/Cert Details:

Information about the Cluster

Kubernetes version: v1.27.8-rancher2-2
Cluster Type: Downstream

Custom
OS: Fedora CoreOS 39.20231119.3.0
Kernel: 6.5.11-300.fc39.x86_64
Docker version: 24.0.5

User Information

What is the role of the user logged in?

Cluster Owner

Describe the bug
ECR credentials stops working after upgrading Kubernetes to v1.27.8-rancher2-2.  I can confirm it works in v1.26.11-rancher2-2
Configured in rke_config block in Terraform:
private_registries {
  url = data.vault_kv_secret_v2.ecr.data.registry_address
  ecr_credential_plugin {
    aws_access_key_id     = data.vault_kv_secret_v2.ecr.data.access_key_id
    aws_secret_access_key = data.vault_kv_secret_v2.ecr.data.secret_access_key
  }
}

Image pull error in kubelet:
E0207 08:39:43.319282    2947 remote_image.go:167] "PullImage from image service failed" err="rpc error: code = Unknown desc = Error response from daemon: Head \"https://[redacted].dkr.ecr.eu-west-1.amazonaws.com/v2/[redacted]/dino-pod-killer/dino-pod-killer/manifests/latest\": no basic auth credentials" image="[redacted].dkr.ecr.eu-west-1.amazonaws.com/[redacted]/dino-pod-killer/dino-pod-killer:latest"
E0207 08:39:43.319351    2947 kuberuntime_image.go:53] "Failed to pull image" err="rpc error: code = Unknown desc = Error response from daemon: Head \"https://[redacted].dkr.ecr.eu-west-1.amazonaws.com/v2/[redacted]/dino-pod-killer/dino-pod-killer/manifests/latest\": no basic auth credentials" image="[redacted].dkr.ecr.eu-west-1.amazonaws.com/[redacted]/dino-pod-killer/dino-pod-killer:latest"

To Reproduce
Upgrade to or create new cluster with Kubernetes version v1.27.8-rancher2-2.
Result
Expected Result
Private registry images should be pulled
Screenshots

Additional context

We encountered this bug after upgrading Rancher to version 2.8.2 and one of our downstream clusters from version 1.26.13 to 1.27.10 on AWS. This issue specifically affects private ECR repositories, while public ECR repositories remain unaffected. To mitigate this, we've implemented a workaround by adding a Docker secret containing AWS ECR credentials to the relevant namespaces. These credentials are refreshed every 6 hours. Additionally, we've included this Docker secret in the imagepullsecrets of applicable service accounts.

@yha-sparklane
Thanks.
I got it working by using ecr-credential-provider and removing ecr_credential_plugin from current config.
I used this guide:
https://medium.com/@sajjadzaheri/how-to-authenticate-aws-ecr-on-any-kubernetes-cluster-the-right-way-26b6ee190125
Terraform:
services {
  kubelet {
    extra_env = [
      # Inject AWS credentials for ECR authentication
      "AWS_ACCESS_KEY_ID=${data.vault_kv_secret_v2.ecr.data.access_key_id}",
      "AWS_SECRET_ACCESS_KEY=${data.vault_kv_secret_v2.ecr.data.secret_access_key}"
    ]

    extra_binds = [
      # Custom binaries available to kubelet
      "/opt/danskespil/bin:/opt/danskespil/bin:ro",
      # Custom configs available to kubelet
      "/opt/danskespil/config:/opt/danskespil/config:ro"
    ]

    extra_args = {
      # https://github.com/kubernetes/cloud-provider-aws/blob/master/docs/credential_provider.md
      image-credential-provider-bin-dir = "/opt/danskespil/bin"
      image-credential-provider-config  = "/opt/danskespil/config/credential-provider-config.yaml"
    }

    cluster_dns_server = var.cluster_dns_server
  }

Butane config (CoreOS):
variant: fcos
version: 1.4.0

storage:
  files:
    - path: /opt/danskespil/bin/ecr-credential-provider
      overwrite: true
      contents:
        source: https://storage.googleapis.com/k8s-artifacts-prod/binaries/cloud-provider-aws/v1.29.0/linux/amd64/ecr-credential-provider-linux-amd64
      mode: 0755

    - path: /opt/danskespil/config/credential-provider-config.yaml
      mode: 0600
      overwrite: true
      contents:
        inline: |
          apiVersion: kubelet.config.k8s.io/v1
          kind: CredentialProviderConfig
          providers:
            - name: ecr-credential-provider
              matchImages:
                - "*.dkr.ecr.*.amazonaws.com"
                - "public.ecr.aws"
              defaultCacheDuration: "12h"
              apiVersion: credentialprovider.kubelet.k8s.io/v1

@mofr93
Thanks for your answer. Unfortunatly I don't want to use AWS secret_access_key and access_key_id. I need it to handle AWS instance profile to achieve this.

@yha-sparklane
In that case you probably have to use https://rke.docs.rancher.com/config-options/cloud-providers/aws#using-the-out-of-tree-aws-cloud-provider-for-rke or something.


feat(query): added Security Contact Email for Terraform

Proposed Changes

added a query to check if email is set in Security Contact

I submit this contribution under the Apache-2.0 license.

Since the email field is required by Terraform.
Don't think it makes sense to have a query to check if this email field is missing.
Opinions? @JoaoDuarteGomes @felipe-avelar @rafaela-soares

I agree with you, for me doesn't makes sense either...

It's up to you whether you want the query or not.
If this is an issue that can both be correctly detected statically and prevents the plan from being built, this is a legitimate query.


How fast is fast enough?

Switching to installing feedvalidator with wget shaved off another 10 seconds.

And another 10s by dropping the nodejs dependency.

Okay, let's see if this gets a sub-3 minute build on master.


[Feature Request]: Support annotations (citations) with assistants api

Scenario
Currently, citations coming from Azure OpenAI On Your Data is supported. However, if an assistant is set up with file_search, citations will not be similarly automatically added.
We want to support citations for file_search as well.

Info on file_search
Azure OpenAI assistants annotations

Solution
Modify SayCommand to create citations when assistant file_search returns annotations
### Tasks
- [x] C#
- [ ] Python
- [ ] JS

When this feature will be available ?

When this feature will be available ?

At this time we don't have timeline information. Thanks for your patience.

Requirements

Developers should be able to access the associated annotations from the assistant's response.

Findings

annotations does not provide a "quote" of the cited text [1]
it is not possible to retrieve cited "quote" either since so useful information is provided. The start_index and end_index fields refer to the start and end of the string to be replaced [2]


Edm..Date generates a sample value that is an ISO DateTime, not just Date and would fail its own validation.

When a property is of time Edm.Date, the wrong sample value is generated.
Steps to reproduce
Add a property of type Edm.Date, generate OAS.
Expected result
:
value:
date: '0001-01-01'
Actual result
:
value:
date: '0001-01-01T00:00:00.0000000'

Transferred this issue to the OpnAPI.NET repo: https://github.com/microsoft/OpenAPI.NET/issues/1101


net/http: make Transport.CancelRequest somehow work against http2

https://golang.org/cl/18873 documented loudly that CancelRequest doesn't work against HTTP/2 servers, but perhaps we can make it work anyway.
More background: #13540 ("x/net/http2: decide what to do about Transport.CancelRequest"), which made http.Client stop using CancelRequest itself.
Really, people should just stop using CancelRequest. But in many cases we created the Request, so we could also own the cancel channel and use it.

If we lived with this in Go 1.6, we can live with it in Go 1.7 and beyond. CancelRequest should just remain deprecated.


Adding Function to detectNet.h Error

Hi,
I trained my own object detection and I am trying to interact with the detection. I changed the overlay to outline the object with a box and when the object is on the left/right of the screen the left/right side of the box is changed to red.
/**
* Center Detection Flags
*/
inline void Allignment( int flag )					{ ALLIGN_FLAG = flag; }

It is declared to pass the flag from my python code into the detectNet.h.
# interact with detections on cam 0
for detection in detections_0:
	# print(detection)
	class_name = net.GetClassDesc(detection.ClassID)
	print(class_name + " Detected!")
	center = getCenter(detection)
	imgCenter = getImgCenter(display_0)
	coord_x = boxCoord(detection)

	# Right of Center
	if (coord_x > imgCenter[0] + 10):
		ALLIGNMENT = 0x1
		print("Right of Center")
	# Left of Center
	elif (coord_x < imgCenter[0] - 10):
		ALLIGNMENT = 0x2
		print("Left of Center")
	#Other
	else:
		ALLIGNMENT = 0x0

	print("-----------------------------------------")
	net.Allignment(ALLIGNMENT)

I declared and called 'Allignment' based on how the 'GetClassDesc' is documented. I use the 'make' and 'sudo make install' to compile the c++ and don't get any errors, but when I run my python program I get the error below.
Traceback (most recent call last):
File "my_detection.py", line 141, in
main()
File "my_detection.py", line 94, in main
net.Allignment(ALLIGNMENT)
AttributeError: 'jetson.inference.detectNet' object has no attribute 'Allignment'

Hi @primetime728, did you add a Python binding for it in jetson-inference/python/bindings/PyDetectNet.cpp ?
https://github.com/dusty-nv/jetson-inference/blob/master/python/bindings/PyDetectNet.cpp

@dusty-nv thank you, it worked!


Remove deprecated ArtifactAttributes type

This field is still used by KGP. This needs https://github.com/JetBrains/kotlin/pull/4983 to be merged first.

Since ArtifactTypeDefinition.ARTIFACT_TYPE_ATTRIBUTE was only introduced in 7.3, this change is being retargeted to Gradle 9.0.


Migrate to GA4

[ ] discuss migration plan with drptiago
[ ] collect claim_geo instead of claim-geo
[ ] migrate to free events format like in amplitude
[ ] update wallet TAG with new property

@sirpy @patpedrosa Does it still relevant or could be closed / moved to the IceBox ?

@johnsmith-gooddollar  the GoodDAPP is already with the GA4 tag .
So I believe this can be closed.


reading the binlog, is the gtid on the record available?

I can read from the binlog starting at a given point. I could count forward from there, but I think that gaps are allowed. So I think the records from the binlog must themselves be stamped with a GTID. But when I print out these records, I only see the old offset from non-gtid replication.
 ev.Header = &replication.EventHeader{Timestamp:0x58abc314, EventType:0x1e, ServerID:0x98352c, EventSize:0x673, LogPos:0x10081, Flags:0x0}

 ev = '=== WriteRowsEventV2 ===
Date: 2017-02-20 22:33:24
Log position: 65665
Event size: 1651
TableID: 72
Flags: 1
Column count: 58
Values:
--
...

Is the GTID hiding somewhere in the binary data, just not yet decoded?

With mysqlbinlog --hexdump I can see that there are SET @@SESSION.GTID_NEXT records in the binlog, I just have to figure out how to get (or get them past my filters, which are currently allowing only UPDATE_ROWS_EVENTv2 and WRITE_ROWS_EVENTv2)
# at 12893
#170221  4:33:21 server id 9975084  end_log_pos 12941 CRC32 0xf0b319b9
# Position  Timestamp   Type   Master ID        Size      Master Pos    Flags
#     325d 11 c3 ab 58   21   2c 35 98 00   30 00 00 00   8d 32 00 00   00 00
#     3270 01 37 a6 94 64 f5 8a 11  e6 93 fb 02 42 ac 14 00 |.7..d.......B...|
#     3280 03 11 00 00 00 00 00 00  00 b9 19 b3 f0          |.............|
#   GTID [commit=yes]
SET @@SESSION.GTID_NEXT= '37a69464-f58a-11e6-93fb-0242ac140003:17'/*!*/;
# at 12941

Ah... It looks like the GTID_EVENT is a separate event that occurs before the event that it labels.

So the sequence of the binlog leading up to a RowsEvent for my data, seems to be:
GTIDEvent,  which says SET @@SESSION.GTID_NEXT= 'uuid:57'/*!*/;
QueryEvent
TableMapEvent
RowsEvent

It's all there. The gtid just comes before the rows-event as a distinct and separate event, 3 events prior to the rows that it applies to.

👍


HTTPS binding support using binding metadata

Thank you for helping make the Dapr documentation better!
Please follow this checklist before submitting:

[ ] Commits are signed with Developer Certificate of Origin (DCO - learn more)
[ ] Read the contribution guide
[ ] Commands include options for Linux, MacOS, and Windows within codetabs
[ ] New file and folder names are globally unique
[ ] Page references use shortcodes instead of markdown or URL links
[ ] Images use HTML style and have alternative text
[ ] Places where multiple code/command options are given have codetabs

In addition, please fill out the following to help reviewers understand this pull request:
Description

Update document for HTTPS binding support using http binding metadata
Modify document to include secret store for fetching certs

Issue reference
#3330

@hhunter-ms Thanks for quick review. Have applied the fixes as suggested.

@pravinpushkar  - Trying to understand here - Is using a SecretRef the preferred method now there is a choice on how to choose to supply the certificate? And if so is there anything special (as in showing an example) of how to use SecretRef?

@pravinpushkar - Trying to understand here - Is using a SecretRef the preferred method now there is a choice on how to choose to supply the certificate? And if so is there anything special (as in showing an example) of how to use SecretRef?

@msfussell This PR is addressing two changes -
Update document for HTTPS binding support using http binding metadata - (New feature)
Modify document to include secret store for fetching certs -  (existing feature but document has no mention that certs can be fetched from secret stroe also)

@pravinpushkar - Trying to understand here - Is using a SecretRef the preferred method now there is a choice on how to choose to supply the certificate? And if so is there anything special (as in showing an example) of how to use SecretRef?

@msfussell This PR is addressing two changes -
Update document for HTTPS binding support using http binding metadata - (New feature) Modify document to include secret store for fetching certs - (existing feature but document has no mention that certs can be fetched from secret stroe also)

ok. I would still say this more explicitly in the docs (the secretKeyRef), as in write a sentence, and if you can put this with an example in a sub-heading it is much more useful. Even now the docs are a little subtle on this.

ok. I would still say this more explicitly in the docs (the secretKeyRef), as in write a sentence, and if you can put this with an example in a sub-heading it is much more useful. Even now the docs are a little subtle on this.

Sure, I will an example.

@pravinpushkar - Are you going to be able to add a sample to this article?

@pravinpushkar - Are you going to be able to add a sample to this article?

@msfussell  Added the example. Please take a look.


_1password-gui: 8.1.1 -> 8.2.0

Bump version and hash. alsa-lib needed to be updated to alsaLib.
Motivation for this change
The 8.1.1 version of 1password has a hard expiration date.
Things done

Built on platform(s)

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

[ ] For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
[ ] Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
[ ] Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
[x] Tested execution of all binary files (usually in ./result/bin/)
21.11 Release Notes (or backporting 21.05 Release notes)

[ ] (Package updates) Added a release notes entry if the change is major or breaking
[ ] (Module updates) Added a release notes entry if the change is significant
[ ] (Module addition) Added a release notes entry if adding a new NixOS module

[ ] Fits CONTRIBUTING.md.

alsaLib is an alias of alsa-lib (https://github.com/NixOS/nixpkgs/pull/126440), we probably don't want to change this back. And using the alias will make the CI fail.
https://github.com/NixOS/nixpkgs/blob/abfdb24af00d88abff4ed7184f45b0c0b8abf268/pkgs/top-level/aliases.nix#L46

I'm going to redo this.


[HUDI-5317] Fix insert overwrite table for partitioned table

Change Logs
fix https://github.com/apache/hudi/pull/7365, spark2 and spark3's behavior needs to be consistent
Impact
low
Risk level (write none, low medium or high below)
low
Documentation Update
None
Contributor's checklist

[ ] Read through contributor's guide
[ ] Change Logs and Impact were stated clearly
[ ] Adequate tests were added if applicable
[ ] CI passed

@stream2000 @leesf Could you please help to review

cc @jonvex and @lokeshj1703 to take a look :)

LGTM


New device documentation

Is there documentation somewhere regarding implementing a new device ?
I'm working on a Vulkan device and I'm having a hard time grokking what should be in the device.json file, as well as setting up the skeleton of the device implementation.
I am working with C and don't intend to use helium.
Thanks.

Hi! This is definitely a gap in SDK documentation right now, so I'll do my best to direct you here.
Even though you're not planning on using helium, the helide device is still a reasonable reference point for some of the other miscellaneous things that device implementations need in order to work in the SDK:

ANARI_DEFINE_LIBRARY_ENTRYPOINT  (Example here) is what anariLoadLibrary() looks for when loading your library dynamically. You can probably just copy that file and change names to fit your library.
The jsons are only used for generating device/object info data for anariGetDeviceExtensions, anariGetObjectSubtypes, anariGetObjectInfo, and anariGetParameterInfo. Those are about listing what extensions you implement that are in the core spec and then creating definitions for any extensions you add beyond the spec. The best strategy to use is to adapt an example json combined with CMake infrastructure for invoking the Python generation scripts (example here).
The main component you must implement is DeviceImpl -- yes it's a C++ pure-virtual class, but you don't have to use any C++ in order to use it. The stuff helium does is inject a class layer in between DeviceImpl and yours to handle generic stuff, but DeviceImpl itself is straight 1:1 with the public C API. If you understand the C API from the docs, then you should easily be able to implement DeviceImpl with whatever you want to do....it's ultimately up to you.

Let me know if you have any other questions, as there's plenty of things to talk about when starting a device from scratch!

FYI I just merged a README that explains the various aspects needed to get a device implementation going (viewable here)....I hope that helps! Let me know if anything is unclear, thanks!

Thanks! I haven't had much time to sink into my anari device lately but I'll definetly go through that file.


Force Linux host platform for Windows users

Description
Force VS Code to think the server it's connecting to is a Linux host, which caused detection problems on Windows.
Related Issue(s)
Fixes https://github.com/gitpod-io/gitpod/issues/16058
How to test

Connect to a workspace with VS Code Desktop (if you can, go get a Windows machine for this)
Don't get the OS prompt

It looks like it still prompts on Windows, although being in the config :/


How can I insert Native token at special times?

We are going to mint token every special times.
And Minted tokens should be transferred to Treasury as a Negative Imbalance.
For this, we are going to use on_intialize hook and treasury on_unbalanced method.
How can I make this?
Please help me.
Thanks.

I see you asking on stack exchange and dev chats. Issues here are not for support.


Update dependencies

Codecov Report

Merging #3 (6e961bd) into master (4dac0f9) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master       #3   +/-   ##
=======================================
  Coverage   73.75%   73.75%
=======================================
  Files           2        2
  Lines          80       80
=======================================
  Hits           59       59
  Misses         15       15
  Partials        6        6

Flag
Coverage Δ

unittests
73.75% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 4dac0f9...6e961bd. Read the comment docs.


The workbox-window message listener can report the wrong service worker

Library Affected:
workbox-window
The current logic that dispatches message events makes the assumption that the service worker sending the message is the same as the instances "own" service worker, but that's not necessarily the case since the listener is added to the ServiceWorkerContainer: https://github.com/GoogleChrome/workbox/blob/ae80e3958c79cb93f4c21bca63cd6e81f7878536/packages/workbox-window/src/Workbox.ts#L493-L504
At minimum we should update the code to set the .sw property to originalEvent.source, but it might also be worth considering whether we want to restrict messages to be just those sent via the instances registered service worker.
We could potentially even introduce an externalmessage event to be consistent with the other external* lifecycle events, but I'm not sure this is really necessary.
Thoughts?

Fixing the value in sw, and allowing developers to use that to filter if needed, seems like a reasonable approach with minimal downside.
My intuition is that there may be more scenarios in which the window client doesn't care about which SW the message comes from, and that creating a brand new event that they had to opt-in to listening to seems like overkill (unless actual developers let us know that they want that behavior).


Securing Ubuntu vps of wireguard

Hello everybody,
I have a question, Do i need to secure my VPS ( ubuntu OS) that runs wireguard/openvpn services ( both used @angristan scripts ) to prevent attacks such as DoS, DDoS or ... to my server ? if Yes, what do i need? ( cdn ? basic firewall ? ... ? )
ps. the VPS is using only wireguard and OpenVPN without any other services...

I think it should be best practice to secure VPS's from all potential avenues of attack. That includes editing the SSH config file, and whitelisting IP access 👍


Question for models/trainer.py#L325 ?

In https://github.com/nlpyang/BertSum/blob/master/src/models/trainer.py#L325 ,
After sum(), the loss.numel() must be 1 ,  What different between    (loss/loss.numel()).backward() with  loss.backward() ?
So, I guess,  the loss.numel() may express the n_docs ?
Can we use loss / normalization replace  (loss/loss.numel()) ?

Hi I have the same problem, what's your conclusion?

Hi,I have a bug about this statement:
Traceback (most recent call last):
File "train.py", line 340, in
train(args, device_id)
File "train.py", line 272, in train
trainer.train(train_iter_fct, args.train_steps)
File "/root/code/BertSum/src/models/trainer.py", line 155, in train
self._gradient_accumulation(
File "/root/code/BertSum/src/models/trainer.py", line 326, in _gradient_accumulation
loss.div(float(normalization)).backward()
File "/root/miniconda3/lib/python3.8/site-packages/torch/_tensor.py", line 307, in backward
torch.autograd.backward(self, gradient, retain_graph, create_graph, inputs=inputs)
File "/root/miniconda3/lib/python3.8/site-packages/torch/autograd/init.py", line 154, in backward
Variable._execution_engine.run_backward(
RuntimeError: CUDA error: device-side assert triggered
CUDA kernel errors might be asynchronously reported at some other API call,so the stacktrace below might be incorrect.
For debugging consider passing CUDA_LAUNCH_BLOCKING=1.
Does it have any relation with the statement?Or have you solv it?
Pardon me for my poor English!

Hi,I have a bug about this statement: Traceback (most recent call last): File "train.py", line 340, in train(args, device_id) File "train.py", line 272, in train trainer.train(train_iter_fct, args.train_steps) File "/root/code/BertSum/src/models/trainer.py", line 155, in train self._gradient_accumulation( File "/root/code/BertSum/src/models/trainer.py", line 326, in _gradient_accumulation loss.div(float(normalization)).backward() File "/root/miniconda3/lib/python3.8/site-packages/torch/_tensor.py", line 307, in backward torch.autograd.backward(self, gradient, retain_graph, create_graph, inputs=inputs) File "/root/miniconda3/lib/python3.8/site-packages/torch/autograd/init.py", line 154, in backward Variable._execution_engine.run_backward( RuntimeError: CUDA error: device-side assert triggered CUDA kernel errors might be asynchronously reported at some other API call,so the stacktrace below might be incorrect. For debugging consider passing CUDA_LAUNCH_BLOCKING=1. Does it have any relation with the statement?Or have you solv it? Pardon me for my poor English!

Ok,i have already solved the problem.It is about using BCEcross before,you should give a sigmoid layer before the output.

Hi,I have a bug about this statement: Traceback (most recent call last): File "train.py", line 340, in train(args, device_id) File "train.py", line 272, in train trainer.train(train_iter_fct, args.train_steps) File "/root/code/BertSum/src/models/trainer.py", line 155, in train self._gradient_accumulation( File "/root/code/BertSum/src/models/trainer.py", line 326, in _gradient_accumulation loss.div(float(normalization)).backward() File "/root/miniconda3/lib/python3.8/site-packages/torch/_tensor.py", line 307, in backward torch.autograd.backward(self, gradient, retain_graph, create_graph, inputs=inputs) File "/root/miniconda3/lib/python3.8/site-packages/torch/autograd/init.py", line 154, in backward Variable._execution_engine.run_backward( RuntimeError: CUDA error: device-side assert triggered CUDA kernel errors might be asynchronously reported at some other API call,so the stacktrace below might be incorrect. For debugging consider passing CUDA_LAUNCH_BLOCKING=1. Does it have any relation with the statement?Or have you solv it? Pardon me for my poor English!

Ok,i have already solved the problem.It is about using BCEcross before,you should give a sigmoid layer before the output.


[spi_device] Access fault when reading from command, address, and payload FIFOs

I tried configuring CMD_INFO_11 register for SECTOR_ERASE (opcode: 0x20, 3-byte address, upload: true, busy: true), sent the command over SPI and printed the fields of the UPLOAD_STATUS register. cmdfifo and addrfifo fields looked OK but when I try to read from the command FIFO I get an access fault:
I00135 ottf_isrs.c:89] Load/Store fault, mtval holds the fault address.
I00136 ottf_isrs.c:90] MTVAL value is 0x40051e00

I see the same behavior for address and payload FIFOs using a pretty recent bitstream (2c1f6029d).
cc @a-will @cfrantz

Thanks I will check if anything wrong in the TL-UL converting logic inside SPI_DEVICE.

The design should be OK. If HW is accessing the DPSRAM through SYS clock port, the logic lowers the SW access and hold it until HW releases the request (by getting the response from DPSRAM). Basically, the access pattern does not change across the entire DPSRAM (0x4005_1000 to 0x4005_1FFF).
Could you please check IOPMP setting? I only can think that may be the reason.

Ah.. Could you please initialize the Payload / CmdFIFO/ Addr FIFO ? I think parity error may occur if SW accesses the region.

Thanks @eunchan, I was able to read from the FIFOs using UPLOAD_CMDFIFO and UPLOAD_ADDRFIFO registers,. I'm not sure if the data coming out is correct for more complex cases but I tried sending SECTOR_ERASE (0x20) and PAGE_PROGRAM (0x02) back to back and the second read from UPLOAD_CMDFIFO sometimes returned 0x0 and sometimes 0x20. Might worth a closer look.
Re. the payload buffer and access fault issue: I spent some time debugging this because it looks like the payload buffer is not reset when the chip is reset. Tried this a couple of times reprogramming the fpga and I get an access fault only if I read past the payload depth (or try to read it when it's empty). We cannot use word reads by rounding up the payload depth but it works if I handle the tail correctly with byte reads. PLMK if you plan to relax this.
From what I observed, the payload buffer always has the last payload. Can you confirm? If that's the case we can't really handle the multiple commands with payloads in the command FIFO. I don't think it's something we want to (host should poll the BUSY bit) but just wanted to point it out.

Thanks @eunchan https://github.com/eunchan, I was able to read from the FIFOs using UPLOAD_CMDFIFO and UPLOAD_ADDRFIFO registers,. I'm not sure if the data coming out is correct for more complex cases but I tried sending SECTOR_ERASE (0x20) and PAGE_PROGRAM (0x02) back to back and the second read from UPLOAD_CMDFIFO sometimes returned 0x0 and sometimes 0x20. Might worth a closer look.

Thanks. I think there's some timing issue. Returning 0x0 may indicate the FIFO is empty, which is weird as the FIFO not empty interrupt is generated after the HW fills the FIFO first. Worth to take a look. Thanks for finding the issue.

Re. the payload buffer and access fault issue: I spent some time debugging this because it looks like the payload buffer is not reset when the chip is reset. Tried this a couple of times reprogramming the fpga and I get an access fault only if I read past the payload depth (or try to read it when it's empty). We cannot use word reads by rounding up the payload depth but it works if I handle the tail correctly with byte reads. PLMK if you plan to relax this.

As the fault occurs due to the integrity feature in the DPSRAM, the upload function can't do anything about this. HW must update only a byte at a time. It does not know when the command is finished, so as soon as it receives the 8th beat, it writes to the DPSRAM to not lose the data. So, it cannot update the entire word with correct parity bit. So, only thing FW can do, in this case, is to initialize the entire payload portion (256B) at the beginning.

From what I observed, the payload buffer always has the last payload. Can you confirm? If that's the case we can't really handle the multiple commands with payloads in the command FIFO. I don't think it's something we want to (host should poll the BUSY bit) but just wanted to point it out.

Yes. Only one payload command can be stored. And based on the discussion with @a-will, I think SW wants to block the upload function entirely when it receives a upload command, which sets BUSY bit. SO, maybe we may not need multiple command/address slots in the FIFO.

Re. the payload buffer and access fault issue: I spent some time debugging this because it looks like the payload buffer is not reset when the chip is reset. Tried this a couple of times reprogramming the fpga and I get an access fault only if I read past the payload depth (or try to read it when it's empty). We cannot use word reads by rounding up the payload depth but it works if I handle the tail correctly with byte reads. PLMK if you plan to relax this.

As the fault occurs due to the integrity feature in the DPSRAM, the upload function can't do anything about this. HW must update only a byte at a time. It does not know when the command is finished, so as soon as it receives the 8th beat, it writes to the DPSRAM to not lose the data. So, it cannot update the entire word with correct parity bit. So, only thing FW can do, in this case, is to initialize the entire payload portion (256B) at the beginning.

Yes, initializing the payload area solves this issue but is there a particular reason why the spi_device buffer is not reset when the chip is reset? Shouldn't the retention SRAM be the only memory whose contents survive a reset?

SRAM macro usually does not have reset signals. That's why the SRAM portion needs to be initialized at the beginning. While reset, if power keeps being provided, SRAM contents remain. If we need to guarantee to have clean state of SRAM after every reset, HW should have self-initialization logic inside, which I think some what needed eventually.

On Apr 4, 2022, at 9:37 AM, Alphan Ulusoy @.***> wrote:
Re. the payload buffer and access fault issue: I spent some time debugging this because it looks like the payload buffer is not reset when the chip is reset. Tried this a couple of times reprogramming the fpga and I get an access fault only if I read past the payload depth (or try to read it when it's empty). We cannot use word reads by rounding up the payload depth but it works if I handle the tail correctly with byte reads. PLMK if you plan to relax this.
As the fault occurs due to the integrity feature in the DPSRAM, the upload function can't do anything about this. HW must update only a byte at a time. It does not know when the command is finished, so as soon as it receives the 8th beat, it writes to the DPSRAM to not lose the data. So, it cannot update the entire word with correct parity bit. So, only thing FW can do, in this case, is to initialize the entire payload portion (256B) at the beginning.
Yes, initializing the payload area solves this issue but is there a particular reason why the spi_device buffer is not reset when the chip is reset? Shouldn't the retention SRAM be the only memory whose contents survive a reset?
—
Reply to this email directly, view it on GitHub https://github.com/lowRISC/opentitan/issues/11782#issuecomment-1087774333, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAJDG3R2QB6BSUOKFFZCJRLVDMLDDANCNFSM5R7XFIXQ.
You are receiving this because you were mentioned.

@alphan please check and close if no further question you have.

Thanks @eunchan. @cfrantz, it looks like spi_device SRAM will not be reset when the chip is reset.

We should memset it to zeros if the hardware doesn't do that for us.


[AKS] az aks create/update: Add new parameter --aks-custom-headers to support for custom headers

Description

Add support for the --aks-custom-headers option in aks create and aks update.

Testing Guide

History Notes

[Component Name 1] BREAKING CHANGE: az command a: Make some customer-facing breaking change.
[Component Name 2] az command b: Add some customer-facing feature.

This checklist is used to make sure that common guidelines for a pull request are followed.

[ ] The PR title and description has followed the guideline in Submitting Pull Requests.

[ ] I adhere to the Command Guidelines.

[ ] I adhere to the Error Handling Guidelines.

Could you add some tests for this new parameter and resolve those conflicts?

Could you add some tests for this new parameter and resolve those conflicts?

Sure, conflicts resolved and several test cases are updated to test --aks-custom-headers in commit #6974fe7.


23w51b yet more stuff

Conflict to be resolved later

Conflict resolved, @Shnupbups please make sure to SCREAM.


YOURLS: 404 and directory issues

My main domain is smile.ws
I have installed yourls in smile.ws/yourls.
As a result, all my shortened urls are smile.ws/yourls/link instead of smile.ws/link
I followed the wiki instructions but that didn’t help.
I looked around and found a plugin called "Swap Short Url" which is supposed to help in these situations. It has slightly different .htaccess recommendation. I followed the instructions correctly and it works, because now the urls are smile.ws/link. But when you click on them, you get a 404 error.
How can I fix this? Thanks!

PS I know that I should post this on [Yourls discouse](https://discourse.yourls.org/), but that website doesn't let me sign up for an account or post any messages. Everyone else seems to be posing issues here, so I guess this must be the place to post?

Hello,
"I have installed yourls in smile.ws/yourls. As a result, all my shortened urls are smile.ws/yourls/link" : normal behavior.
Problem with specific plugin: please see with plugin author

Problem with specific plugin: please see with plugin author

Is there anyway to get this set up working without a plugin? Thanks!

YOURLS out of the box works from the directory it's installed in.
There are multiple ways to achieve what you want: server config tweak (for instance on apache with rewrite rules), a plugin (there may be several) or other tricks.
So, without a plugin: yes, possibly, but it depends on your config and is very specific with your setup, so we cannot provide a generic trick. Hence the plugins.

@ozh Thanks for your help. Do you know of any plugins that can do this other than "Swap Short Url". I've searched around but not found anything. The problem with "Swap Short Url" is that it's not very well supported. There are people who have raised issues similar to mine from June and have not had any replies. Thanks in advance for any help you can offer.

@bigsmile01 all I know is either from YOURLS/awesome-yourls or Google :)