[Chore] DeprecationWarning: The punycode module is deprecated. Please use a userland alternative instead

What technical task needs doing?
We need to figure out how to remove the warnings when using the Node 22 LTS with Terra Draw package.json commands.
├─┬<EMAIL_ADDRESS>│ └─┬<EMAIL_ADDRESS>│   └─┬<EMAIL_ADDRESS>│     └──<EMAIL_ADDRESS>├─┬<EMAIL_ADDRESS>│ └─┬<EMAIL_ADDRESS>│   ├─┬<EMAIL_ADDRESS>│   │ └──<EMAIL_ADDRESS>deduped
│   └─┬<EMAIL_ADDRESS>│     └─┬<EMAIL_ADDRESS>│       └──<EMAIL_ADDRESS>deduped
└─┬<EMAIL_ADDRESS>  └─┬<EMAIL_ADDRESS>    └─┬<EMAIL_ADDRESS>      └──<EMAIL_ADDRESS>
serve can be fixed, eslint is v8 is deprecated (needs upgrading in and of itself), and jest-environment-jsdom does not have a new version out yet (30 is in alpha).

eslint I doubt will get fixed without just migrating to v9 #374
Jest has an open issue https://github.com/jestjs/jest/issues/15367

#374 resolves the punycode warning relating to eslint


Master

Coverage remained the same at 70.056% when pulling 31a90ce87faed9af388d11df41588b819dde8875 on master into<PHONE_NUMBER>2e609f4fb2df6cc18061b8f1b90372 on develop.


FR: Specifications block redesign - Phase 2

Change the sections to accordions on mobile

@shirin27 Can this one be moved to the backlog, please?

Change the sections to accordions on mobile

Can't remember what this means?

Follow up of issue #35

Full design was implemented in #35 . Issue closed.


CronJob duplicates on Vercel

Bug Report
Current Behavior
Currently I have one CronJob which works fine, but when i redeploy my "production" environment in Vercel, using documentation provided method I see duplicated CronJob in my ui.quirrel.dev webpage.
Is this behaviour expected, or "old" CronJob instances should be cleaned up after new deployment?
Input Code
Just regular CronJob
import { CronJob } from "quirrel/next";

export default CronJob(
  "api/customCron",
  async () => {
    // await ...
  }
)

Expected behavior/code
I expect that old CronJob instances should be deleted and only one is visible in ui.quirrel.dev webpage.
Environment

Quirrel version: 1.9.2
Node/npm version: node 16/pnpm 7.9.5
Nextjs 12.2
Vercel

Additional context/Screenshots
package.json
{
  "scripts": {
    "build:vercel": "next build && quirrel ci"
  }
}

Thank you in advance!

quirrel ci is supposed to clean up old cronjobs, that's right. Here's the code: https://github.com/quirrel-dev/quirrel/blob/2feba926bc3836a4f0cb40f63b3ffe65aa9ee2eb/src/api/scheduler/jobs-repo.ts#L301-L356
Not sure what's causing this. Could you try to write up some a minimal reproduction steps that I can use to reproduce this issue? That'd help me resolve it.

Closing this, feel free to reopen.

Hey @Skn0tt, sorry for late reply I cannot reopen, so im writing it here.
Im currently using this setup:

Vercel for next.js app
Self-hosted quirrel on netlify

Build command: "build:vercel": "next build && quirrel ci"
As you can see, quirrel tried to update cron jobs

And unfrotunately UI shows 2 jobs, which are actually executed 2 times, so if i rerun this, it will be 3 jobs, 4 jobs and etc...

Self-hosted quirrel on netlify
Could you elaborate on how you set that up? I'm not aware of any way of hosting the Quirrel app on Netlify, so it'd be very interesting to learn what you mean by this.

And unfrotunately UI shows 2 jobs,

I have the suspicion that these two jobs, which are seemingly to the same URL, share the same path but have different hosts. The UI only shows the path, but if you hover over it, the tooltip should show the full URL. My suspicion is that one is https://preview-a.vercel.app/api/populate-patients/cron and the other is https://preview-b.vercel.app/api/populate-patients/cron, or something similar. That breaks Quirrel's cron deduplication.
If that's the case, check if the QUIRREL_BASE_URL variable is the same for all your deployments. quirrel ci relies on that to properly deduplicate.

@Skn0tt
Sorry for confusing you, it's not Netlify, its fly.io. I followed this approach https://dev.to/remixtape/self-hosting-quirrel-5af7
Regarding the QUIRREL_BASE_URL looks like im missing it! Ill try to add it and then will try to redeploy.

@Skn0tt looks like that we managed to fix it! Thank you very much for support.


Comments available before a closing curly brace indent incorrectly once formatted.

Description:
Comments available before a closing curly brace indent incorrectly once formatted.
Before formatting...
import ballerina/http;

service on new http:Listener(8090) {
    resource function get .(http:Caller caller, http:Request req) {
        string[] fruits = ["asd"];
        foreach var item in fruits {

        }
        //Comment
    }
}

After formatting...
import ballerina/http;

service on new http:Listener(8090) {
    resource function get .(http:Caller caller, http:Request req) {
        string[] fruits = ["asd"];
        foreach var item in fruits {

        }
    //Comment
    }
}

Steps to reproduce:
Affected Versions:
slp8

Closing this issue since it is a duplicate of https://github.com/ballerina-platform/ballerina-lang/issues/26380. Please refer the linked issue for tracking purposes.


Fix support for GitLab payload

I just tried to use it from gitlab.com by manually setting up the hook. It seems our logic for gitlabhq is no longer working, possibly because the payload changed since it was written. You can find the code here.
Focusing only on the relevant parts, I get a payload that looks like this:
{
   "ref":"refs/heads/master",
   "user_id":12345,
   "user_name":"David Ebbo",
   "repository":{
      "name":"Mvc51ApplicationFx451",
      "url":"git@gitlab.com:david-ebbo/Mvc51ApplicationFx451.git",
      "description":"Test MVC project",
      "homepage":"https://gitlab.com/david-ebbo/Mvc51ApplicationFx451"
   }
}

And for a public repo (as is the case for https://gitlab.com/david-ebbo/Mvc51ApplicationFx451), we’re expecting an http URL and not ssh. So that blows up in there.

Gitlab folks wrote:

The repository['url'] field has returned the ssh url for long time (maybe from beginning of GitLab). You can use the repository['homepage'] field and add .git to it to get the git over HTTP url.

@davidebbo hey. You can follow advice and use homepage for HTTP url. In future we are planning to explicitly add git_http_url and git_ssh_url for hook payload

As you mentioned, it was missing the is_private (or public) field as part of hook payload.   One workaround is to Http GET on  repository['homepage'] url.   For public, it returns 200.  For private, it redirect to login (302).   Of course, it is best they include this info in the playload.
{
  "before": "20fb361885bc66358b7d73e1bd11eda08c643b49",
  "after": "1ba391f4d100ab8dde08e8bf77355a67325182d6",
  "ref": "refs/heads/master",
  "checkout_sha": "1ba391f4d100ab8dde08e8bf77355a67325182d6",
  "user_id": 99630,
  "user_name": "Suwat Bodin",
  "project_id": 168565,
  "repository": {
    "name": "HelloPrivate",
    "url": "git@gitlab.com:suwatch01/HelloPrivate.git",
    "description": "",
    "homepage": "https://gitlab.com/suwatch01/HelloPrivate"
  },
  "commits": [
    {
      "id": "1ba391f4d100ab8dde08e8bf77355a67325182d6",
      "message": "testing gitlab2\n",
      "timestamp": "2015-02-19T20:24:08-08:00",
      "url": "https://gitlab.com/suwatch01/HelloPrivate/commit/1ba391f4d100ab8dde08e8bf77355a67325182d6",
      "author": {
        "name": "Suwath Ch",
        "email"<EMAIL_ADDRESS>      }
    }
  ],
  "total_commits_count": 1
}

From hook payload you cant say if project is public or private right now

But we will consider including visibility flag (public/internal/private) in future version

ETA?
I think unless that flag is available, it is best we always treat it as public repo and only use http.  It will fail with private repo but we will live with that limitation - well at least we have some support.
Work around by HttpGET on homepage url and decide based on 200 or 302 status is probably too weak.

ETA?

Possibly 7.10

I think unless that flag is available, it is best we always treat it as public repo and only use http. It will fail with private repo but we will live with that limitation - well at least we have some support.

What kind of problem you are trying to solve. Why you need to know if project is public from webhook?

For continuous integration, once we receive the hook notification, we will perform the git fetch from the gitlab repository and deploy.   We need to know whether to git fetch https or ssh.  Make sense?

Any reasons why you cant use only one method. For example SSH

For public repo, it is not necessary for user to setup SSH key pair between Kudu and GitLab.  This is the simplest workflow.   For private, it is required.
Of course, once we have the full integration (with oauth and all), it will be transparent to user.  However, best practice wise, we only want to do just necessary thing - not more.

Here is a thought: ignore whether the repo is public or private. Instead, choose to use ssh URL only if we in fact have an ssh key. If we don't, fall back to http. Problem solved!

That could be another workaround.  I just think long term we should have that info.  It is available on https://gitlab.com/api/v3/projects rest api (public: true).   Just a matter of adding it to the hook, I guess.
@randx what 7.10 means in term of date?  It is not July 10 correct?

Do we use that knowledge for anything other than determining whether to use ssh or http? If so, basic it on presence of ssh key feels pretty solid. e.g. someone might legitimately decide to use ssh to a public repo and set up an ssh key to do that. Even though that's not how we set things up by default, it's perfectly valid.

Idea with ssh keys looks valid to me.

what 7.10 means in term of date? It is not July 10 correct?

We have release every 22nd each month. Right now we are 7.7. So 7.10 is April 22. But I think we can improve web hooks even earlier. It looks like an easy fix.

How you setup integration with GitLab project. Are you using GitLab OAuth? If so you can use OAuth2 token for cloning private repo.
git clone<EMAIL_ADDRESS>

We have some documentation for requesting OAuth token here - http://doc.gitlab.com/ce/api/oauth2.html

Anyway I am going to improve web hooks soon so you will know if project is public or not.

Wonderful, looking forward to try it out.
As for setup integration, short term, one would need to do a manual setup to integrate with GitLab.   We will discuss on the timeline to achieve a full OAuth integration with GitLab and Azure Portal.  Will keep you update on schedule.

Anyway I am going to improve web hooks soon so you will know if project is public or not.

Can you give a timeline how soon it is?  If it will be next week, we could wait.  Otherwise, we will probably do some small surgical fix to test E2E.

I made a fix - https://github.com/gitlabhq/gitlabhq/commit/2617f8d14af870e5364c6299483164d33006e087
It will be available in current release (7.8) at Monday

Awesome, thanks Dmitriy!

You are welcome :)

And it was released in 7.8 yesterday and now also available on gitlab.com

Thanks.  We can see the new properties (visibility, http and ssh urls) in the hook payload.   We can proceed from here.

I rewrote the documentation on setting up CI, including with GitLab. Find it on https://github.com/projectkudu/kudu/wiki/Continuous-deployment


fix: last updated and new mod check

What
fix: last updated and new mod check

:tada: This PR is included in version 1.10.1 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket:


Remove unused uglify-js dependency

Removes the uglify-js dependency, which is not actively used anywhere. Likely this was used at some point in the past before being replaced with @rollup/plugin-terser.

Fixed the merge conflicts that occurred from merging #161.


Causing issue with capifony deploy

I'm sorry if this is the wrong place for this issue, but for the last day or so I haven't been able to do a "cap deploy" - it always bombs out when it gets to the KnpMenu, giving the following error:
Cloning into /var/www/vhosts/MY_HOST/releases/20111110220445/vendor/KnpMenu...
error: SSL certificate problem, verify that the CA cert is OK. Details:
error:14090086:SSL routines:SSL3_GET_SERVER_CERTIFICATE:certificate verify failed while accessing https://github.com/knplabs/KnpMenu.git/info/refs
Do you have any idea how to fix this? Thanks

seems like you need to report it to github. We are not responsible for the SSL configuration of the github server.

Ok, I'll give that a go then. Thanks for the quick response.

Just in case anyone comes across this this when they've got the same problem...it was caused by using the https address of the git repository in the deps file. It worked when I used the git:// address instead.

Also, have a look at this: http://stackoverflow.com/questions/3777075/https-github-access


Publish Vue3 version of @rancher/components

Closing because a Vue3 version of @rancher/components has been published^1


Fix prioritization of routes with dynamic routing

If I have :
/$post/index.js
/quotes/$author$.js

If I request the page /quotes, it will get absorbed by the first route /$post/index.js. I expect it to be run by the second route /quotes/$author$.js.
This PR aims at fixing it.

[x] add test case
[x] fix error described above

Solution implemented
Fortunately the default descending order gives us this :
> ['a','1','A','0','$'].sort()
["$", "0", "1", "A", "a"]

So we can use the descending order to put the pages/folders starting with $ at the end of the list (deprioritize them).
> ["/$post", "/$post/$comment", "/$post/comments", "/blog/$post/comment/$id$", "/quotes/$author$"].sort().reverse()
[
  "/quotes/$author$",
  "/blog/$post/comment/$id$",
  "/$post/comments",
  "/$post/$comment",
  "/$post"
]

Going to close this as @ijjk made a PR: #7449


docs/devel/release-process.md: add vscode-aks-tools

Follow up to https://github.com/inspektor-gadget/inspektor-gadget/pull/1608

The CI fails but it is not related to this PR. I'll merge.


OAK-6756: Convert oak-auth-external to OSGi R7 annotations

done.

With the last commit, the diff in OSGi metadata is as follows
org.apache.jackrabbit.oak.spi.security.authentication.external.impl.DefaultSyncHandler
    MetaType
        Attributes
            - namespace = http://www.osgi.org/xmlns/metatype/v1.0.0 (String)
            + namespace = http://www.osgi.org/xmlns/metatype/v1.2.0 (String)
        Designates
            org.apache.jackrabbit.oak.spi.security.authentication.external.impl.DefaultSyncHandler
                - pid = org.apache.jackrabbit.oak.spi.security.authentication.external.impl.DefaultSyncHandler (String)
        ObjectClassDefinitions
            org.apache.jackrabbit.oak.spi.security.authentication.external.impl.DefaultSyncHandler
                - description = Description for org.apache.jackrabbit.oak.spi.security.authentication.external.impl.DefaultSyncHandler (String)
                + description =  (String)

org.apache.jackrabbit.oak.spi.security.authentication.external.impl.ExternalLoginModuleFactory
    Declarative Services
        References
            syncManager
                - bind = bindSyncManager (String)
                - unbind = unbindSyncManager (String)
                + field-collection = service (String)
            idpManager
                - bind = bindIdpManager (String)
                - unbind = unbindIdpManager (String)
                + field-collection = service (String)
    MetaType
        Attributes
            - namespace = http://www.osgi.org/xmlns/metatype/v1.0.0 (String)
            + namespace = http://www.osgi.org/xmlns/metatype/v1.2.0 (String)
        Designates
            org.apache.jackrabbit.oak.spi.security.authentication.external.impl.ExternalLoginModuleFactory
                - pid = org.apache.jackrabbit.oak.spi.security.authentication.external.impl.ExternalLoginModuleFactory (String)
        ObjectClassDefinitions
            org.apache.jackrabbit.oak.spi.security.authentication.external.impl.ExternalLoginModuleFactory
                - description = Description for org.apache.jackrabbit.oak.spi.security.authentication.external.impl.ExternalLoginModuleFactory (String)
                + description =  (String)

org.apache.jackrabbit.oak.spi.security.authentication.external.impl.principal.ExternalPrincipalConfiguration
    MetaType
        Attributes
            - namespace = http://www.osgi.org/xmlns/metatype/v1.0.0 (String)
            + namespace = http://www.osgi.org/xmlns/metatype/v1.2.0 (String)
        ObjectClassDefinitions
            org.apache.jackrabbit.oak.spi.security.authentication.external.impl.principal.ExternalPrincipalConfiguration
                - description = Description for org.apache.jackrabbit.oak.spi.security.authentication.external.impl.principal.ExternalPrincipalConfiguration
(String)
                + description =  (String)

@jsedding , thanks.... but honestly i am not sure that the new diff is actually good or still needs some work.

[...] i am not sure that the new diff is actually good or still needs some work.

@anchela At the risk of explaining things you already know, here I go. Most remaining diffs relate to the metatype, which is informational and used predominantly for the rendering of configuration UIs. The most risky diff in the metatype is IMHO the removal of the Designates > pid field. This seems to be a recurring pattern in this sort of refactoring, and I assume that it defaults to the value of the line above (not sure what it's called).
The only change in the declarative services XML is the change of two field from method injection to field injection. I did this, because I suspect that the previous implementation was not 100% correct. I think that during an "update" of a bound service, if the reference is dynamic (which it isn't here), the "bind" method is called before the "unbind" method. I.e. in "unbind" you need to check if the value in the field and the value to be unbound are the same object before you set it to null. Since the bind/unbind methods in question had no other logic than setting the field, I thought it safer to switch them to field injection.
TL;DR - With all that said, I am confident that this PR is good to be merged. 🙂

@anchela I only tested with a local QS build. I don't even know if I can easily access testing platforms for AEMaaCS deployments as an external dev.

I read the spec on the subject of the pid in the Designate element and found that the pid attribute is ignored if a factoryPid attribute is present. Both, the DefaultSyncHandler and the ExternalLoginModuleFactory have the factoryPid attribute specified. Thus the new version is arguably more correct than the old version that includes the ignored pid attribute.

The getPids() method returns an array of PIDs that were specified in the pid attribute of the Object elements. The getFactoryPids() method returns an array of the factoryPid attributes. For factories, the related pid attribute is ignored because all instances of a factory must share the same meta type. (emphasis is mine)

Source: https://docs.osgi.org/specification/osgi.cmpn/8.0.0/service.metatype.html#i1492258

@jsedding , that actually makes sense.
@anchela, do you have specific worries about the diff? To me it looks perfectly fine.

@jsedding , i didn't know. so thanks for all the explanation that helps
@mbaedke , thanks for the additional info....
so, i think we are good.... and sorry for not being responsive. was busy elsewhere and didn't have too much time to help here.


Questions

Hi!, Thank you for this amazing library, however it is not clear by documentation if it supports matrix/tensor multiplication..
Does it employ also thread parallelism? (Parallel.For, in addition to SIMD instructions)
If it supports tensor/matrix multiplication it would be great for use in machine learning, just in case it supports it already (in example a forward pass in a neural network is just  a(Wx+b) where W is matrices of weights, x input vector, b bias and a activation function) , how do I use the tensor/matrix multiplication? thanks

Ok nevermind, looked at the very clean source code, it obviously don't support it.
It would be nice to have, implementing it would not be easy though. Also I would add a  IParallelProvider generic parameter
allowing people to switch a Parallel.For when needed.
For the machine learning PART, usually the input is computed in parallel, so there are x1,x2,x3,x4 inputs
therefore there is a matrix operation   a(W*(x1|x2|x3|x4) + b) = (y1|y2|y3|y4) allowing such operation with SIMD-smart-optimized matrix multiplication plus Parallel.For would make NetFabric.Numberics.Tensors very appetible for machine learning

Hi @Darelbi! I kicked off this library to streamline SIMD operations on spans. Along the way, I stumbled upon System.Numerics.Tensors, which shared some similarities but came with its own set of limitations. So, I've been refining my version to overcome these limitations and enhance both performance and functionality. I've laid a solid foundation and now I'm ready to ramp up improvements. Open to new ideas and contributions. Also intrigued by the idea of using Parallel.For.

Hi @Darelbi,
I've been playing around with this idea lately. Unfortunately, every attempt I've made runs into the snag that any ref struct, like Span<T>, can't reside in the heap. That means they're a no-go for lambda expressions which are required for all parallelization solutions.
Check out this prototype you can fiddle with:
using System.Numerics;

const int size = 10_000;
var source = Enumerable.Range(0, size).ToArray();
var destination = new int[size];

Tensor.Apply<int, DoubleOperator<int>>(source, destination);

Console.WriteLine("Array processing complete.");

static class Tensor
{
    public static void Apply<T, TOperator>(ReadOnlySpan<T> source, Span<T> destination)
        where TOperator: IUnaryOperator<T, T>
        => Apply<T, T, TOperator>(source, destination);

    public static void Apply<T, TResult, TOperator>(ReadOnlySpan<T> source, Span<TResult> destination)
        where TOperator: IUnaryOperator<T, TResult>
    {
        if(source.Length > 100)
            ParallelApply<T, TResult, TOperator>(source, destination);
        else
            Apply<T, TResult, TOperator>(source, destination, 0, source.Length);
    }

    static void ParallelApply<T, TResult, TOperator>(ReadOnlySpan<T> source, Span<TResult> destination)
        where TOperator: IUnaryOperator<T, TResult>
    {
        var availableCores = Environment.ProcessorCount;
        var size = source.Length;
        var chunkSize = size / availableCores;

        var actions = new Action[availableCores];
        for (var coreIndex = 0; coreIndex < availableCores; coreIndex++)
        {
            var startIndex = coreIndex * chunkSize;
            var endIndex = (coreIndex == availableCores - 1)
                ? size
                : (coreIndex + 1) * chunkSize;
            actions[coreIndex] = () => Apply<T, TResult, TOperator>(source, destination, startIndex, endIndex);
        }
        Parallel.Invoke(actions);
    }

    static void Apply<T, TResult, TOperator>(ReadOnlySpan<T> source, Span<TResult> destination, int startIndex, int endIndex)
        where TOperator: IUnaryOperator<T, TResult>
    {
        for (var index = startIndex; index < endIndex; index++)
        {
            destination[index] = TOperator.Invoke(source[index]);
        }
    }
}

interface IUnaryOperator<T, TResult>
{
    static abstract TResult Invoke(T x);
}

readonly struct DoubleOperator<T>
    : IUnaryOperator<T, T>
    where T: INumberBase<T>, IMultiplyOperators<T, T, T>
{
    public static T Invoke(T x) => T.CreateChecked(2) * x;
}

Attempting to pin the span, as suggested here, doesn't work with generics.
Also, giving a callback delegate a shot, as suggested here, lands us in the same heap issue (boxing).
At this point, it seems like the only way forward is to switch to Memory<T>, which means reworking the entire public API, but it may be worth it.
Here's a prototype using Memory<T>:
using System.Numerics;

const int size = 10_000;
var source = Enumerable.Range(0, size).ToArray();
var destination = new int[size];

Tensor.Apply<int, DoubleOperator<int>>(source, destination);

Console.WriteLine("Array processing complete.");

static class Tensor
{
    public static void Apply<T, TOperator>(ReadOnlyMemory<T> source, Memory<T> destination)
        where TOperator: IUnaryOperator<T, T>
        => Apply<T, T, TOperator>(source, destination);

    public static void Apply<T, TResult, TOperator>(ReadOnlyMemory<T> source, Memory<TResult> destination)
        where TOperator: IUnaryOperator<T, TResult>
    {
        if(source.Length > 100)
            ParallelApply<T, TResult, TOperator>(source, destination);
        else
            Apply<T, TResult, TOperator>(source.Span, destination.Span, 0, source.Length);
    }

    static void ParallelApply<T, TResult, TOperator>(ReadOnlyMemory<T> source, Memory<TResult> destination)
        where TOperator: IUnaryOperator<T, TResult>
    {
        var availableCores = Environment.ProcessorCount;
        var size = source.Length;
        var chunkSize = size / availableCores;

        var actions = new Action[availableCores];
        for (var coreIndex = 0; coreIndex < availableCores; coreIndex++)
        {
            var startIndex = coreIndex * chunkSize;
            var endIndex = (coreIndex == availableCores - 1)
                ? size
                : (coreIndex + 1) * chunkSize;
            actions[coreIndex] = () => Apply<T, TResult, TOperator>(source.Span, destination.Span, startIndex, endIndex);
        }
        Parallel.Invoke(actions);
    }

    static void Apply<T, TResult, TOperator>(ReadOnlySpan<T> source, Span<TResult> destination, int startIndex, int endIndex)
        where TOperator: IUnaryOperator<T, TResult>
    {
        for (var index = startIndex; index < endIndex; index++)
        {
            destination[index] = TOperator.Invoke(source[index]);
        }
    }
}

interface IUnaryOperator<T, TResult>
{
    static abstract TResult Invoke(T x);
}

readonly struct DoubleOperator<T>
    : IUnaryOperator<T, T>
    where T: INumberBase<T>, IMultiplyOperators<T, T, T>
{
    public static T Invoke(T x) => T.CreateChecked(2) * x;
}

Do you have any more suggestions?

I made some enhancements. Now, each chunk has a minimum size to prevent spending more time managing threads than processing the data. The APIs now support both Memory<T> and Span<T>, but CPU parallelization is only available for Memory<T> APIs. To prevent ambiguity, overloads for arrays are also required. This implies that all operations must include these overloads, which is quite a bit of work...
using System.Numerics;

const int size = 10_010;
var source = Enumerable.Range(0, size).ToArray();
var destination = new int[size];

Console.WriteLine("Array processing started.");
Tensor.Apply<int, DoubleOperator<int>>(source, destination);
Console.WriteLine("Array processing complete.");

static class Tensor
{
    const int minChunkSize = 100;

    public static void Apply<T, TOperator>(T[] source, T[] destination)
        where TOperator: IUnaryOperator<T, T>
        => Apply<T, T, TOperator>(source.AsMemory(), destination.AsMemory());

    public static void Apply<T, TResult, TOperator>(T[] source, TResult[] destination)
        where TOperator: IUnaryOperator<T, TResult>
        => Apply<T, TResult, TOperator>(source.AsMemory(), destination.AsMemory());

    public static void Apply<T, TOperator>(ReadOnlyMemory<T> source, Memory<T> destination)
        where TOperator: IUnaryOperator<T, T>
        => Apply<T, T, TOperator>(source, destination);

    public static void Apply<T, TResult, TOperator>(ReadOnlyMemory<T> source, Memory<TResult> destination)
        where TOperator: IUnaryOperator<T, TResult>
    {
        if(source.Length > 2 * minChunkSize)
            ParallelApply<T, TResult, TOperator>(source, destination);
        else
            Apply<T, TResult, TOperator>(source.Span, destination.Span);
    }

    static void ParallelApply<T, TResult, TOperator>(ReadOnlyMemory<T> source, Memory<TResult> destination)
        where TOperator: IUnaryOperator<T, TResult>
    {
        var availableCores = Environment.ProcessorCount;
        var size = source.Length;
        var chunkSize = int.Max(size / availableCores, minChunkSize);

        var actions = new List<Action>(availableCores);
        var start = 0;
        var remaining = size;
        var index = 0;
        while (remaining > 0)
        {
            var length = (remaining < 2 * chunkSize)
                ? remaining
                : chunkSize;

            Console.WriteLine($"Core: {index} Start: {start} Length: {length}");

            var sourceSpan = source.Slice(start, length);
            var destinationSpan = destination.Slice(start, length);
            actions.Add(() => Apply<T, TResult, TOperator>(sourceSpan.Span, destinationSpan.Span));

            start += length;
            remaining -= length;
            index++;
        }
        Console.WriteLine("Parallel processing started.");
        Parallel.Invoke(actions.ToArray());
    }

    public static void Apply<T, TOperator>(ReadOnlySpan<T> source, Span<T> destination)
        where TOperator: IUnaryOperator<T, T>
        => Apply<T, T, TOperator>(source, destination);

    public static void Apply<T, TResult, TOperator>(ReadOnlySpan<T> source, Span<TResult> destination)
        where TOperator: IUnaryOperator<T, TResult>
    {
        Console.WriteLine($"Processing chunk! Source: {source.Length} Destination: {destination.Length}");
        // SIMD processing to be added here
        for (var index = 0; index < source.Length && index < destination.Length; index++)
            destination[index] = TOperator.Invoke(source[index]);
    }
}

interface IUnaryOperator<T, TResult>
{
    static abstract TResult Invoke(T x);
}

readonly struct DoubleOperator<T>
    : IUnaryOperator<T, T>
    where T: INumberBase<T>, IMultiplyOperators<T, T, T>
{
    public static T Invoke(T x) => T.CreateChecked(2) * x;
}

I ran tests on branch #29, but the results aren't too encouraging. The multicore performance is slower, regardless of whether SIMD is employed or not. I need to explore the hardware constraints to understand this better.

BenchmarkDotNet v0.13.12, Windows 10 (10.0.19045.4353/22H2/2022Update)
Intel Core i7-7567U CPU 3.50GHz (Kaby Lake), 1 CPU, 4 logical and 2 physical cores
.NET SDK 9.0.100-preview.1.24101.2
  [Host]    : .NET 8.0.2 (<IP_ADDRESS>11), X64 RyuJIT AVX2
  Scalar    : .NET 8.0.2 (<IP_ADDRESS>11), X64 RyuJIT
  Vector128 : .NET 8.0.2 (<IP_ADDRESS>11), X64 RyuJIT AVX
  Vector256 : .NET 8.0.2 (<IP_ADDRESS>11), X64 RyuJIT AVX2

| Method           | Job       | Categories | Count | Mean         | StdDev     | Median       | Ratio         |
|----------------- |---------- |----------- |------ |-------------:|-----------:|-------------:|--------------:|-
| Baseline_Double  | Scalar    | Double     | 1000  |  1,078.60 ns |  40.114 ns |  1,060.22 ns |      baseline |
| System_Double    | Scalar    | Double     | 1000  |    406.24 ns |  13.758 ns |    399.47 ns |  2.67x faster |
| NetFabric_Double | Scalar    | Double     | 1000  |  2,180.41 ns | 166.326 ns |  2,150.15 ns |  2.05x slower |
| Baseline_Double  | Vector128 | Double     | 1000  |  1,042.76 ns |  20.052 ns |  1,035.44 ns |  1.04x faster |
| System_Double    | Vector128 | Double     | 1000  |    205.04 ns |   4.889 ns |    203.97 ns |  5.28x faster |
| NetFabric_Double | Vector128 | Double     | 1000  |  2,270.89 ns | 125.795 ns |  2,307.96 ns |  2.07x slower |
| Baseline_Double  | Vector256 | Double     | 1000  |  1,444.38 ns | 116.838 ns |  1,456.48 ns |  1.31x slower |
| System_Double    | Vector256 | Double     | 1000  |    152.14 ns |  11.168 ns |    149.91 ns |  7.20x faster |
| NetFabric_Double | Vector256 | Double     | 1000  |  2,201.52 ns |  80.728 ns |  2,205.31 ns |  2.04x slower |
|                  |           |            |       |              |            |              |               |
| Baseline_Float   | Scalar    | Float      | 1000  |  1,209.83 ns |  61.967 ns |  1,197.02 ns |      baseline |
| System_Float     | Scalar    | Float      | 1000  |    480.37 ns |  33.768 ns |    472.45 ns |  2.54x faster |
| NetFabric_Float  | Scalar    | Float      | 1000  |  2,359.35 ns |  93.242 ns |  2,387.54 ns |  1.96x slower |
| Baseline_Float   | Vector128 | Float      | 1000  |    770.33 ns |  53.606 ns |    750.29 ns |  1.57x faster |
| System_Float     | Vector128 | Float      | 1000  |    126.49 ns |   9.335 ns |    125.69 ns |  9.58x faster |
| NetFabric_Float  | Vector128 | Float      | 1000  |  2,152.34 ns |  89.694 ns |  2,153.25 ns |  1.79x slower |
| Baseline_Float   | Vector256 | Float      | 1000  |    762.05 ns |  79.493 ns |    753.45 ns |  1.56x faster |
| System_Float     | Vector256 | Float      | 1000  |     67.04 ns |   1.134 ns |     66.90 ns | 18.42x faster |
| NetFabric_Float  | Vector256 | Float      | 1000  |  1,999.26 ns |  90.642 ns |  2,017.39 ns |  1.66x slower |
|                  |           |            |       |              |            |              |               |
| Baseline_Half    | Scalar    | Half       | 1000  | 12,504.44 ns | 286.312 ns | 12,399.19 ns |      baseline |
| System_Half      | Scalar    | Half       | 1000  | 12,231.32 ns | 120.729 ns | 12,238.40 ns |  1.02x faster |
| NetFabric_Half   | Scalar    | Half       | 1000  |  9,433.74 ns | 867.650 ns |  9,546.42 ns |  1.35x faster |
| Baseline_Half    | Vector128 | Half       | 1000  |  9,697.71 ns | 240.589 ns |  9,676.38 ns |  1.29x faster |
| System_Half      | Vector128 | Half       | 1000  | 10,333.35 ns | 852.316 ns |  9,931.87 ns |  1.18x faster |
| NetFabric_Half   | Vector128 | Half       | 1000  |  8,915.24 ns | 799.399 ns |  8,905.60 ns |  1.51x faster |
| Baseline_Half    | Vector256 | Half       | 1000  | 10,267.79 ns | 924.079 ns |  9,858.21 ns |  1.26x faster |
| System_Half      | Vector256 | Half       | 1000  |  9,777.72 ns |  98.069 ns |  9,765.89 ns |  1.28x faster |
| NetFabric_Half   | Vector256 | Half       | 1000  |  9,393.03 ns | 475.270 ns |  9,403.79 ns |  1.36x faster |
|                  |           |            |       |              |            |              |               |
| Baseline_Int     | Scalar    | Int        | 1000  |  1,297.64 ns |  12.022 ns |  1,299.23 ns |      baseline |
| System_Int       | Scalar    | Int        | 1000  |    407.63 ns |   4.247 ns |    409.42 ns |  3.18x faster |
| NetFabric_Int    | Scalar    | Int        | 1000  |  2,341.00 ns | 112.485 ns |  2,360.99 ns |  1.69x slower |
| Baseline_Int     | Vector128 | Int        | 1000  |  1,353.19 ns |  75.724 ns |  1,316.32 ns |  1.05x slower |
| System_Int       | Vector128 | Int        | 1000  |    115.52 ns |   6.332 ns |    114.52 ns | 11.38x faster |
| NetFabric_Int    | Vector128 | Int        | 1000  |  2,108.18 ns | 110.913 ns |  2,122.89 ns |  1.54x slower |
| Baseline_Int     | Vector256 | Int        | 1000  |  1,307.51 ns |  21.841 ns |  1,305.11 ns |  1.01x slower |
| System_Int       | Vector256 | Int        | 1000  |     64.33 ns |   1.039 ns |     64.19 ns | 20.18x faster |
| NetFabric_Int    | Vector256 | Int        | 1000  |  1,993.01 ns |  90.504 ns |  2,016.42 ns |  1.55x slower |
|                  |           |            |       |              |            |              |               |
| Baseline_Long    | Scalar    | Long       | 1000  |  1,045.51 ns |  18.504 ns |  1,044.03 ns |      baseline |
| System_Long      | Scalar    | Long       | 1000  |    406.87 ns |   7.117 ns |    405.92 ns |  2.57x faster |
| NetFabric_Long   | Scalar    | Long       | 1000  |  2,256.12 ns | 163.947 ns |  2,250.57 ns |  2.18x slower |
| Baseline_Long    | Vector128 | Long       | 1000  |  1,071.94 ns |  48.088 ns |  1,050.91 ns |  1.04x slower |
| System_Long      | Vector128 | Long       | 1000  |    207.46 ns |   4.846 ns |    205.69 ns |  5.03x faster |
| NetFabric_Long   | Vector128 | Long       | 1000  |  2,197.30 ns | 162.174 ns |  2,164.07 ns |  2.15x slower |
| Baseline_Long    | Vector256 | Long       | 1000  |  1,047.96 ns |  16.598 ns |  1,042.90 ns |  1.00x slower |
| System_Long      | Vector256 | Long       | 1000  |    123.71 ns |   0.750 ns |    123.83 ns |  8.46x faster |
| NetFabric_Long   | Vector256 | Long       | 1000  |  2,191.66 ns | 103.227 ns |  2,201.34 ns |  2.03x slower |
|                  |           |            |       |              |            |              |               |
| Baseline_Short   | Scalar    | Short      | 1000  |  1,050.32 ns |  13.160 ns |  1,051.75 ns |      baseline |
| System_Short     | Scalar    | Short      | 1000  |    413.54 ns |  14.802 ns |    409.65 ns |  2.52x faster |
| NetFabric_Short  | Scalar    | Short      | 1000  |  2,185.30 ns | 169.597 ns |  2,129.97 ns |  2.16x slower |
| Baseline_Short   | Vector128 | Short      | 1000  |  1,042.56 ns |  10.547 ns |  1,041.07 ns |  1.01x faster |
| System_Short     | Vector128 | Short      | 1000  |     57.45 ns |   2.324 ns |     56.74 ns | 18.53x faster |
| NetFabric_Short  | Vector128 | Short      | 1000  |  2,001.51 ns |  93.791 ns |  2,016.08 ns |  1.89x slower |
| Baseline_Short   | Vector256 | Short      | 1000  |  1,125.94 ns |  93.649 ns |  1,092.19 ns |  1.05x slower |
| System_Short     | Vector256 | Short      | 1000  |     39.64 ns |   3.571 ns |     38.01 ns | 26.02x faster |
| NetFabric_Short  | Vector256 | Short      | 1000  |  1,980.78 ns |  87.917 ns |  2,002.02 ns |  1.85x slower |

Maybe run into bandwith limitation?
Il gio 25 apr 2024, 17:41 Antão Almada @.***> ha
scritto:

I ran tests on branch #29
https://github.com/NetFabric/NetFabric.Numerics.Tensors/pull/29, but
the results aren't too encouraging. The multicore performance is slower,
regardless of whether SIMD is employed or not. I need to explore the
hardware constraints to understand this better.
BenchmarkDotNet v0.13.12, Windows 10 (10.0.19045.4353/22H2/2022Update)
Intel Core i7-7567U CPU 3.50GHz (Kaby Lake), 1 CPU, 4 logical and 2 physical cores
.NET SDK 9.0.100-preview.1.24101.2
[Host]    : .NET 8.0.2 (<IP_ADDRESS>11), X64 RyuJIT AVX2
Scalar    : .NET 8.0.2 (<IP_ADDRESS>11), X64 RyuJIT
Vector128 : .NET 8.0.2 (<IP_ADDRESS>11), X64 RyuJIT AVX
Vector256 : .NET 8.0.2 (<IP_ADDRESS>11), X64 RyuJIT AVX2
| Method | Job | Categories | Count | Mean | StdDev | Median | Ratio |
|----------------- |---------- |----------- |------
|-------------:|-----------:|-------------:|--------------:|-
| Baseline_Double | Scalar | Double | 1000 | 1,078.60 ns | 40.114 ns |
1,060.22 ns | baseline |
| System_Double | Scalar | Double | 1000 | 406.24 ns | 13.758 ns | 399.47
ns | 2.67x faster |
| NetFabric_Double | Scalar | Double | 1000 | 2,180.41 ns | 166.326 ns |
2,150.15 ns | 2.05x slower |
| Baseline_Double | Vector128 | Double | 1000 | 1,042.76 ns | 20.052 ns |
1,035.44 ns | 1.04x faster |
| System_Double | Vector128 | Double | 1000 | 205.04 ns | 4.889 ns |
203.97 ns | 5.28x faster |
| NetFabric_Double | Vector128 | Double | 1000 | 2,270.89 ns | 125.795 ns
| 2,307.96 ns | 2.07x slower |
| Baseline_Double | Vector256 | Double | 1000 | 1,444.38 ns | 116.838 ns |
1,456.48 ns | 1.31x slower |
| System_Double | Vector256 | Double | 1000 | 152.14 ns | 11.168 ns |
149.91 ns | 7.20x faster |
| NetFabric_Double | Vector256 | Double | 1000 | 2,201.52 ns | 80.728 ns |
2,205.31 ns | 2.04x slower |
| | | | | | | | |
| Baseline_Float | Scalar | Float | 1000 | 1,209.83 ns | 61.967 ns |
1,197.02 ns | baseline |
| System_Float | Scalar | Float | 1000 | 480.37 ns | 33.768 ns | 472.45 ns
| 2.54x faster |
| NetFabric_Float | Scalar | Float | 1000 | 2,359.35 ns | 93.242 ns |
2,387.54 ns | 1.96x slower |
| Baseline_Float | Vector128 | Float | 1000 | 770.33 ns | 53.606 ns |
750.29 ns | 1.57x faster |
| System_Float | Vector128 | Float | 1000 | 126.49 ns | 9.335 ns | 125.69
ns | 9.58x faster |
| NetFabric_Float | Vector128 | Float | 1000 | 2,152.34 ns | 89.694 ns |
2,153.25 ns | 1.79x slower |
| Baseline_Float | Vector256 | Float | 1000 | 762.05 ns | 79.493 ns |
753.45 ns | 1.56x faster |
| System_Float | Vector256 | Float | 1000 | 67.04 ns | 1.134 ns | 66.90 ns
| 18.42x faster |
| NetFabric_Float | Vector256 | Float | 1000 | 1,999.26 ns | 90.642 ns |
2,017.39 ns | 1.66x slower |
| | | | | | | | |
| Baseline_Half | Scalar | Half | 1000 | 12,504.44 ns | 286.312 ns |
12,399.19 ns | baseline |
| System_Half | Scalar | Half | 1000 | 12,231.32 ns | 120.729 ns |
12,238.40 ns | 1.02x faster |
| NetFabric_Half | Scalar | Half | 1000 | 9,433.74 ns | 867.650 ns |
9,546.42 ns | 1.35x faster |
| Baseline_Half | Vector128 | Half | 1000 | 9,697.71 ns | 240.589 ns |
9,676.38 ns | 1.29x faster |
| System_Half | Vector128 | Half | 1000 | 10,333.35 ns | 852.316 ns |
9,931.87 ns | 1.18x faster |
| NetFabric_Half | Vector128 | Half | 1000 | 8,915.24 ns | 799.399 ns |
8,905.60 ns | 1.51x faster |
| Baseline_Half | Vector256 | Half | 1000 | 10,267.79 ns | 924.079 ns |
9,858.21 ns | 1.26x faster |
| System_Half | Vector256 | Half | 1000 | 9,777.72 ns | 98.069 ns |
9,765.89 ns | 1.28x faster |
| NetFabric_Half | Vector256 | Half | 1000 | 9,393.03 ns | 475.270 ns |
9,403.79 ns | 1.36x faster |
| | | | | | | | |
| Baseline_Int | Scalar | Int | 1000 | 1,297.64 ns | 12.022 ns | 1,299.23
ns | baseline |
| System_Int | Scalar | Int | 1000 | 407.63 ns | 4.247 ns | 409.42 ns |
3.18x faster |
| NetFabric_Int | Scalar | Int | 1000 | 2,341.00 ns | 112.485 ns |
2,360.99 ns | 1.69x slower |
| Baseline_Int | Vector128 | Int | 1000 | 1,353.19 ns | 75.724 ns |
1,316.32 ns | 1.05x slower |
| System_Int | Vector128 | Int | 1000 | 115.52 ns | 6.332 ns | 114.52 ns |
11.38x faster |
| NetFabric_Int | Vector128 | Int | 1000 | 2,108.18 ns | 110.913 ns |
2,122.89 ns | 1.54x slower |
| Baseline_Int | Vector256 | Int | 1000 | 1,307.51 ns | 21.841 ns |
1,305.11 ns | 1.01x slower |
| System_Int | Vector256 | Int | 1000 | 64.33 ns | 1.039 ns | 64.19 ns |
20.18x faster |
| NetFabric_Int | Vector256 | Int | 1000 | 1,993.01 ns | 90.504 ns |
2,016.42 ns | 1.55x slower |
| | | | | | | | |
| Baseline_Long | Scalar | Long | 1000 | 1,045.51 ns | 18.504 ns |
1,044.03 ns | baseline |
| System_Long | Scalar | Long | 1000 | 406.87 ns | 7.117 ns | 405.92 ns |
2.57x faster |
| NetFabric_Long | Scalar | Long | 1000 | 2,256.12 ns | 163.947 ns |
2,250.57 ns | 2.18x slower |
| Baseline_Long | Vector128 | Long | 1000 | 1,071.94 ns | 48.088 ns |
1,050.91 ns | 1.04x slower |
| System_Long | Vector128 | Long | 1000 | 207.46 ns | 4.846 ns | 205.69 ns
| 5.03x faster |
| NetFabric_Long | Vector128 | Long | 1000 | 2,197.30 ns | 162.174 ns |
2,164.07 ns | 2.15x slower |
| Baseline_Long | Vector256 | Long | 1000 | 1,047.96 ns | 16.598 ns |
1,042.90 ns | 1.00x slower |
| System_Long | Vector256 | Long | 1000 | 123.71 ns | 0.750 ns | 123.83 ns
| 8.46x faster |
| NetFabric_Long | Vector256 | Long | 1000 | 2,191.66 ns | 103.227 ns |
2,201.34 ns | 2.03x slower |
| | | | | | | | |
| Baseline_Short | Scalar | Short | 1000 | 1,050.32 ns | 13.160 ns |
1,051.75 ns | baseline |
| System_Short | Scalar | Short | 1000 | 413.54 ns | 14.802 ns | 409.65 ns
| 2.52x faster |
| NetFabric_Short | Scalar | Short | 1000 | 2,185.30 ns | 169.597 ns |
2,129.97 ns | 2.16x slower |
| Baseline_Short | Vector128 | Short | 1000 | 1,042.56 ns | 10.547 ns |
1,041.07 ns | 1.01x faster |
| System_Short | Vector128 | Short | 1000 | 57.45 ns | 2.324 ns | 56.74 ns
| 18.53x faster |
| NetFabric_Short | Vector128 | Short | 1000 | 2,001.51 ns | 93.791 ns |
2,016.08 ns | 1.89x slower |
| Baseline_Short | Vector256 | Short | 1000 | 1,125.94 ns | 93.649 ns |
1,092.19 ns | 1.05x slower |
| System_Short | Vector256 | Short | 1000 | 39.64 ns | 3.571 ns | 38.01 ns
| 26.02x faster |
| NetFabric_Short | Vector256 | Short | 1000 | 1,980.78 ns | 87.917 ns |
2,002.02 ns | 1.85x slower |
—
Reply to this email directly, view it on GitHub
https://github.com/NetFabric/NetFabric.Numerics.Tensors/issues/24#issuecomment-2077721460,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AA2R4E3CZQUJEGBZ33SFCRDY7EW3JAVCNFSM6AAAAABFO3XALCVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDANZXG4ZDCNBWGA
.
You are receiving this because you were mentioned.Message ID:
@.***>

@Darelbi I kept on researching and wrote an article explaining the current steps: https://aalmada.github.io/posts/Unleashing-parallelism/
Feedback and ideas are welcome!

Thanks for It. Very interesting. Btw what are the specs of your system?
Il sab 4 mag 2024, 00:58 Antão Almada @.***> ha scritto:

@Darelbi https://github.com/Darelbi I kept on researching and wrote an
article explaining the current steps:
https://aalmada.github.io/posts/Unleashing-parallelism/
Feedback and ideas are welcome!
—
Reply to this email directly, view it on GitHub
https://github.com/NetFabric/NetFabric.Numerics.Tensors/issues/24#issuecomment-2093864072,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AA2R4E6M6CNQ4JXLMALBV6TZAQI73AVCNFSM6AAAAABFO3XALCVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDAOJTHA3DIMBXGI
.
You are receiving this because you were mentioned.Message ID:
@.***>

I've been testing it on multiple systems: an Apple M1 (8 logical cores, AdvSIMD), an old Intel i7-7567U (4 logical cores, AVX2) and, for the published results, an AMD Ryzen 9 7940HS (16 logical cores, AVX512).


corrected clk_gpout3 to gpio pin 25 as per the rp2040 datasheet

According to the RP2040 datasheet (https://datasheets.raspberrypi.org/rp2040/rp2040-datasheet.pdf - 1.4.3. GPIO Functions table on page 14) the GPIO pin 25 is designated for clk_gpout3.

ping @liamfraser - is the code in the SDK wrong, or is the function table in the datasheet wrong?

We've verified internally that the datasheet is correct and it's the SDK-code that is incorrect. Thanks @twasiluk

can you please rebase onto develop-1.1.1


Updated version on NuGet.org?

Version 1.7.0 does not work for me (failing on init). Master (version 2.0.0) however does (even if the server is not 2.0.0).
But, the problem is that version 2.0.0 of the parse sdk is not available on NuGet, so our build-server fails. I see from older discussions that 1.8.0 was a planned release. I haven't tried that branch though.
Are there any plans for updating NuGet.org with a newer version?

Once the unit tests for the master branch have been written, automatic NuGet publishing can be set up by reconfiguring the AppVeyor build settings. As of right now, you can generate a NuGet package by building from source, but you can also just reference the .dll file that is also generated. If you cannot figure out how to generate a NuGet package, here is a link to the one generated by the AppVeyor build from the latest commit.

As for "version 1.8.0" that is in it's own branch, it is an unfinished older version of the project kept as a backup, in case the master branch has some kind of major issue. It is also useful as a reference source when making modifications to the master branch.

Ok. I added it as a binary dependency already. Thanks.


Remove export to ./file in client-side code so Winston works in the browser

The File transport is included in the browser bundle, which requires the fs module and so it blows up when bundling winston with something like Webpack.
This is mostly a proof of concept because the code is hideous, but the idea is to remove that transport completely when building the browser version.
The following code will be removed from the output transports.js file:
Object.defineProperty(exports, 'File', {
  configurable: true,
  enumerable: true,
  get: function get() {
    return require('./file');
  }
});

I am sure there is a more elegant way to write the babel transformation, but I've never done one before so I will defer to someone who knows what they're doing as far as best practices.

I'm unsure why the there is a failing test, it's working for my locally in node 6.17.1 and doesn't appear related to the browser build at all.


Empty interface results in error

File contents:
import io;

interface Request {}
interface Response {}

results in:
Fatal error: Can only object_alloc_args() from a class object.
Latest develop build.

This is fixed in the latest version, but i still need to merge this in the develop-branch.


Link to chats in each note?

Any chance you could add a link to the original URL for the chat in attributes of the note?
I have a command line tool that exports GPT chats to markdown but it is much more manual than your tool here. Would be great to have a reference back to the original chat though, so you can jump back into it. Otherwise great little tool!

Done. Check the master branch.
Lot of changes.
Note that you will have to reimport your conversations as I added metadata for this to work efficiently.

Delete your archive folder
Remove the plugin
Follow documentation

NB: plugin name has changed. Read installation paragraph in documentation to be accurate

Thanks so much, will give it a try!

@Superkikim what am I doing wrong? I have the metadata now, but still not the URL

@Superkikim what am I doing wrong? I have the metadata now, but still not the URL

Click on the file title. Not the heading.
I'll try to make it more obvious soon to improve user experience.

Got it! Nice one, thanks that will work well for me.


[Backup] Migrate backup to track2 SDK

Description

Here are main changes for Backup migration to track2:

In track2, use HttpResponseError instead of CloudError.
Modify test_afs_xxx to live test.
Update test_wl_sql_xxx ,delete some operations that cannot be completed by live test(register,unregister).

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.

Backup

hi @PARADISSEEKR what's status of the PR?

cc @qwordy

Some test failed.
https://clitestresultstac.blob.core.windows.net/20210521-055502-506086/backup.report.parallel.html

I ran it again.
https://clitestresultstac.blob.core.windows.net/20210521-122625-720256/backup.report.parallel.html
@PARADISSEEKR Could you verify the correctness of the two failed test cases? Thanks.

Please fix "a RP".

Please fix "a RP".

It has been fixed

/azp run

@andyliuliming, @fengzhou-msft, @zqingqing1 Could you help review this PR?


Gradient Issues

The preload preloads the default gradient color instead of user-set gradient colors before switching to the user-set gradient color.

@HarryWangATX
This can't be solved, due to the user set gradient can't be loaded until your config is loaded from API.

i think the dia bot should have user set gradient as well, unless the current gradient is intended

i think the dia bot should have user set gradient as well, unless the current gradient is intended

I was thinking the same, will look into that in version 1.4.2

okay

dia bot outline is still not custom gradient


Update font-koruri to version 20160506

Changes to a cask
Editing an existing cask

[x] Commit message includes cask’s name (and new version, if applicable).
[x] brew cask audit --download font-koruri is error-free.
[x] brew cask style --fix font-koruri left no offenses.

@vitorgalvao Fixed from your review and passed audit and rubocop. Thank you!


--auto-gen-config produces Metrics/LineLength twice if Metrics/LineLength is configured in .rubocop.yml

This is the same as https://github.com/rubocop-hq/rubocop/issues/5228, it still occurs in 0.59.2 and was not indeed fixed in 0.52.1 (https://github.com/rubocop-hq/rubocop/commit/a8ce761d1c2580ed8dee3cfcf1b05fe066effa16).
RuboCop version
$ rubocop -V
0.59.2 (using Parser <IP_ADDRESS>, running on ruby 2.5.1 x86_64-darwin16)

I can't reproduce the problem. Here's the result I get:
 /tmp/5528$ echo Metrics/LineLength: > .rubocop.yml
 /tmp/5528$ echo "  Max: 100" >> .rubocop.yml
 /tmp/5528$ echo "'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'" > example.rb
 /tmp/5528$ rubocop -V
0.59.2 (using Parser <IP_ADDRESS>, running on ruby 2.5.1 x86_64-linux)
 /tmp/5528$ rubocop --auto-gen-config
Added inheritance from `.rubocop_todo.yml` in `.rubocop.yml`.
Phase 1 of 2: run Metrics/LineLength cop (skipped because the default Metrics/LineLength:Max is overridden)
Phase 2 of 2: run all cops
Inspecting 1 file
C

1 file inspected, 1 offense detected
Created .rubocop_todo.yml.
 /tmp/5528$ ls -a
.  ..  example.rb  .rubocop_todo.yml  .rubocop.yml
 /tmp/5528$ cat .rubocop_todo.yml
# This configuration was generated by
# `rubocop --auto-gen-config`
# on 2018-10-24 23:06:19 +0200 using RuboCop version 0.59.2.
# The point is for the user to remove these configuration records
# one by one as the offenses are removed from the code base.
# Note that changes in the inspected code, or installation of new
# versions of RuboCop, may require this file to be generated again.

# Offense count: 1
# Configuration parameters: AllowHeredoc, AllowURI, URISchemes, IgnoreCopDirectives, IgnoredPatterns.
# URISchemes: http, https
Metrics/LineLength:
  Max: 103
 /tmp/5528$

Interesting. I took another look and by accident discovered this:
$ echo Metrics/LineLength: > .rubocop.yml
$ echo "  Max: 80" >> .rubocop.yml
$ echo "'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa'" > example.rb
$ rubocop -V
0.59.2 (using Parser <IP_ADDRESS>, running on ruby 2.5.3 x86_64-darwin17)

$ rubocop --auto-gen-config
Phase 1 of 2: run Metrics/LineLength cop
Inspecting 1 file
C

1 file inspected, 1 offense detected
Created .rubocop_todo.yml.
Phase 2 of 2: run all cops
Inspecting 1 file
C

1 file inspected, 1 offense detected
Created .rubocop_todo.yml.

$ cat .rubocop_todo.yml
# This configuration was generated by
# `rubocop --auto-gen-config`
# on 2018-10-25 16:39:21 +0200 using RuboCop version 0.59.2.
# The point is for the user to remove these configuration records
# one by one as the offenses are removed from the code base.
# Note that changes in the inspected code, or installation of new
# versions of RuboCop, may require this file to be generated again.

# Offense count: 1
# Configuration parameters: AllowHeredoc, AllowURI, URISchemes, IgnoreCopDirectives, IgnoredPatterns.
# URISchemes: http, https
Metrics/LineLength:
  Max: 103

# Offense count: 1
# Configuration parameters: AllowHeredoc, AllowURI, URISchemes, IgnoreCopDirectives, IgnoredPatterns.
# URISchemes: http, https
Metrics/LineLength:
  Max: 103

Note how I set the limit to 80, which is the default in RuboCop and thus the first phase doesn't seem to be skipped. I can reproduce your result if I use 100 as the limit.

Setting the limit to the default value is an edge case, and the duplicated entry we produce is harmless, so I suggest we don't fix it.

I can reproduce your result if I use 100 as the limit.

Can you really? Because then you and I get different results with the exact same input. Is there anybody else with the same problem?

Can you really? Because then you and I get different results with the exact same input.

I might be confused here. I can reproduce that this issue does not exist when using a max of 100. My guess is that when I opened this issue I was in a project where the Max was 80 and noticed this behavior. What I forgot was to report with a new test case instead of just linking to the old, fixed issue.
Anyway, if you think that this edge case should not be handled since it's benign I think we can close this issue :)

:+1: All right!


[CS] Simplify getCalleeDeclAndArgs

This PR starts associating argument labels for key path subscript components, which allows the special case for them in getCalleeDeclAndArgs to be removed, and also allows us to correctly ignore choices with mismatching labels in some cases.
This PR then uses getCalleeLocator in order to find callees in getCalleeDeclAndArgs, which fixes one case where we weren't finding callees for operator calls, and another case where we were incorrectly returning a subscript callee for a call made on the result of a subscript such as x[]().
Resolves SR-11438, SR-11439 & SR-11440.

@swift-ci please test

@swift-ci please test source compatibility


Google autocomplete failing to set input

Resources:
Before submitting an issue, please consult our troubleshooting guide (http://ionicframework.com/docs/troubleshooting/) and developer resources (http://ionicframework.com/docs/developer-resources/)
Ionic version:  (check one with "x")
[ ] 1.x (For Ionic 1.x issues, please use https://github.com/ionic-team/ionic-v1)
[ ] 2.x
[x] 3.x
I'm submitting a ...  (check one with "x")
[x] bug report
[ ] feature request
[ ] support request => Please do not submit support requests here, use one of these channels: https://forum.ionicframework.com/ or http://ionicworldwide.herokuapp.com/
Current behavior:
When using google.maps.places.Autocomplete and selecting an item from the list of suggested completions, the input field is not filled with the new value. Also, the "place_changed" event is never triggered. Autocomplete works just fine when using ionic-angular v3.3.0, but is broken on v3.4.0 and newer.
Expected behavior:
When an item is selected on the dropdown of suggested completions, the value in the input field is changed to the value of the selected item. The "place_changed" google.maps.event is then fired. This is working when using ionic-angular v3.3.0.
Steps to reproduce:
Build and run demo app (which uses ionic-angular v3.3.0): https://github.com/dallinski/ionic-autocomplete-bug
It works as expected.
Change to v3.4.0 branch (which uses ionic-angular v3.4.0): https://github.com/dallinski/ionic-autocomplete-bug/tree/v3.4.0
It does not work as expected. onPlaceChange is never called.
Related code:
Other information:
Ionic info: (run ionic info from a terminal/cmd prompt and paste output below):
cli packages:
@ionic/cli-plugin-cordova       : 1.6.1
@ionic/cli-plugin-ionic-angular : 1.4.1
@ionic/cli-utils                : 1.7.0
ionic (Ionic CLI)               : 3.7.0

global packages:
Cordova CLI : 6.4.0

local packages:
@ionic/app-scripts : 1.3.7
Cordova Platforms  : ios 4.2.1
Ionic Framework    : ionic-angular 3.3.0

System:
Node       : v7.10.0
OS         : macOS Sierra
Xcode      : Xcode 8.3.3 Build version 8E3004b
ios-deploy : 1.9.1
ios-sim    : 5.0.13
npm        : 3.10.9

I used https://github.com/danielehrhardt/Ionic-2-Google-Maps-Marker-Cluster

I don't have the time to create a plnkr right now, but I will soon.

Marked as needs info awaiting some sample code.

I got a demo app coded up that exhibits the bug:
Build and run demo app (which uses ionic-angular v3.3.0): https://github.com/dallinski/ionic-autocomplete-bug
It works as expected.
Change to v3.4.0 branch (which uses ionic-angular v3.4.0): https://github.com/dallinski/ionic-autocomplete-bug/tree/v3.4.0
It does not work as expected. onPlaceChange is never called.

I tried your demo app using the following versions of ionic-angular: 3.3.0, 3.4.0, and 3.7.1 (which also involves upgrades to Angular, rxjs, zone.js, and @ionic/app-scripts)
In all cases, your demo app worked and did not exhibit any issue with onPlaceChange not being called.
I am going to close this but will be happy to reopen it if it can be duplicated.

Here's a video of the v3.4.0 build exhibiting the bug on my machine: http://recordit.co/DpkcgT4hlO
I'm super confused why it's not behaving that way for you.

One key bit I get from your video that is not in your write-up is that you are running your test on an iOS device. I ran my tests in the browser. Worked fine... :)
I'll re-open and re-run the tests on both an iOS device and an Android device when I get a chance (probably tomorrow).

Sorry for not mentioning that, and thanks for taking a look at this issue.

@kensodemann I'm having same problem. Any update on this?


Add smely socks

https://www.smogon.com/forums/threads/mimikyu.3715930/

@HisuianZoroark Are the move flags OK? I copied them from Curse but since this one doesn't have any target weirdness it might be able to have more normal interactions.


Unstable connection

Compile latest ipp-usb from source on a Raspberry Pi 3B+ running Ubuntu 20.04 which connects to a HP LaserJet MFP M28a via usb. Printing is OK, but sometimes hang, and I have to switch off and switch on the printer to get it back to work. Browsing to printer sever at port 60000 hang every now and then, during which I see lot of messages saying "kernel: usb 1-1.1.2: usbfs: usb_submit_urb returned -121" in journalctl output. With sane-airscan, it reports finding a scanner, but fail to scan, the scanning bar in the machine started moving from the left to right, but stop in the middle.

I have latest sane 1.0.30 installed from ppa:rolfbensch/sane-git, so I try the escl backend, it also found the scanner, but scanimage -d escl:http://<IP_ADDRESS>:60000 > a.pnm gave this output:
Output format is not set, using pnm as a default.
scanimage: rounded value of br-x from 215.9 to 215.9
scanimage: rounded value of br-y from 297.011 to 297.011
scanimage: sane_start: Invalid argument

And the printer has to be reboot again.

Hi @scubajeff,
I've tried to blindly fix it, please test again

My bad. With -o file the scanner is working perfectly. When the console hangup, /var/log/ipp-usb/ has multiple entries of USB[1]: zero-size read. How can I send you the log file?

Did you mean that I don't need any CUPS package installed? Not just cups, but also cups-browsed, cups-daemon, cups-filters, cups-ipp-utils, cups-server-common, etc.?

Like I said, scanning locally with scanimage works. But trying to scan using simple-scan on another machine failed. The scanner got listed, but failed to scan. ipp-usb log shows that simple-scan tried to get GET /eSCL/ScanJobs/1.0/NextDocument HTTP/1.1 after a scan job created, that failed with 404. While local scanimage was doing GET /eSCL/ScanJobs/yk1lecc6-b1yz-v2zm-1005-9wqtyq05/NextDocument HTTP/1.1, it also failed with 404, but scan completed.

By the way, I'm using eSCL backend.

Some more observation fyi. If only ipp-usb is annoucing print queue, Android and Ubuntu machine on the same network will pick it up nicely, but iOS devices will not. If I create an avahi service file, avahi will announce it, it will show up in iOS printer list, but then Android and Ubuntu will list two print queues.
It would be nice to have ipp-usb to announce Airprint print queue to iOS devices.

You may send me log files directly by e-main<EMAIL_ADDRESS>Please, try scanning with my eSCL backend:

https://github.com/alexpevzner/sane-airscan -- project page
https://download.opensuse.org/repositories/home:/pzz/ -- binary packages

May I ask you to send me Avahi service file, that works with iOS?

I tried your backend this morning. airscan-discover can find the scanner, but scanimage with airscan backend can't find any.
I will send you the log file and avahi service file when I get back home later.

I upgrade the Ubuntu client machine to sane 1.0.30, simple-scan works now. I had setup saned in the print server, and my scan client in Android phone also works. So the issues unsolved are hang in web console and proper way to share print queue and scan device. I've sent you email with log file and avahi service file. During this logging, I experienced hang when I try to open web console home tab.

Hi @scubajeff,
I've created 3 new issues, based on your feedback: #4, #5 and #6
#4 and #6 are now hopefully fixed (please, test and confirm)
#5 is work in progress

Please look to my comment in the #5


Update HiHome_WZB-TRVL.md

_TZE200_c88teujp belongs to Saswell_SEA802-Zigbee.md

_TZE200_c88teujp belongs to Saswell_SEA802-Zigbee.md


About the normalization for Inception v3 when calculating FID

Thank you for sharing your excellent work!
I'm curious as to why you chose to re-normalize the fake images in this section. Considering that Inception v3 requires input values within [-1, 1], the generated fake images on this line already meet the requirement of inception v3. Therefore, I believe that re-normalizing these images could potentially result in an incorrect FID score if you're using a pre-trained Inception v3 model from torchvision.
From what I understand, re-normalization of the tensor is necessary only when we employ standard normalization as per ImageNet statistics, like in this ImageNet training example.
I hope you will clarify this issue to achieve a fair comparison in image synthesis.

Thanks for your attention to our work. We checked the normalization in our evaluation codes and found that this problem does not exist.
The input of inception v3 is not [-1, 1]. We used the code of DM-GAN to test FID. The image passes through transforms.ToTensor(), and its distribution becomes [0, 1] (https://github.com/MinfengZhu/DM-GAN/blob/d515995b6fade48be9762c7f069c9d889d4d5559/eval/FID/fid_score.py#L222), and then is normalized to the target interval (https://github.com/MinfengZhu/DM-GAN/blob/d515995b6fade48be9762c7f069c9d889d4d5559/eval/FID/fid_score.py#L222).
Our code (https://github.com/tobran/GALIP/blob/35d0c2fd64eec2e95e7c905cb71f96d81475a46f/code/lib/modules.py#L270) converts it from [-1, 1] to [0, 1] (consistent with the distribution after transforms.ToTensor() of DM-GAN), and then normalizes it to the target interval, so the final data distribution input to inception v3 is consistent with DM-GAN.
At the same time, we save the generated images and test them using DM-GAN's evaluation codes. The results are consistent with our code.


When request error by ajax - show Prettyprint

Many times when i develop my APP i had problem with debug in on ajax.

I think that will be nice if is ( ajax ) request then Prettyprint res, otherwise i have to copy response to html file then read it
Details
Type: ErrorException
Code: 8
Message: Undefined index: ohno
File: [....]adm.php
Line: 23
Trace
[...]

You can see the rendered HTML in the HTML tab. Check it. :dango:

I think you may have opened this PR against the wrong branch? There's over 250 commits in this PR…

Please create a new PR by branching 3.x then putting your change on your new branch and then creating the PR between your new branch and 3.x.


Add js protocol package

if the server-sdk-js is going to use this package, every proto should be generated (ingress + egress + sip)

that makes sense, do we need the livekit_internal.proto, too?

I don't think we'll need it, is is indeed internal


Add a red accent

I'ts too hard to maintain the big number of accents. That's why we leave only fantastic four.


NativeSelect placeholder is shown in the menu

What package has an issue
@svelteuidev/core
A clear and concise description of what the bug is
You can find the placeholder for the NativeSelect component also in the select menu but it is disabled.
The bug is not reproducible on chrome.
In which browser(s) did the problem occur?
Safari
Steps To Reproduce

Open https://www.svelteui.org/core/native-select on Safari
Click one of the NativeSelect Components with a placeholder

Do you know how to fix the issue
No
Are you willing to participate in fixing this issue and create a pull request with the fix
No
Relevant Assets
Safari:

Chrome:

I don't think there is a bug here, since NativeSelect uses the <select> tag, which has different behaviour in each browser. This is just the normal behaviour of <select> in Safari.

Oh, less work for us 😂
I did not know it, thank you


More ergonomic ways of writing Ids

Category
User level API changes
Describe the feature you'd like to request
It would be nice to have more ergonomic ways of writing down policy and entity ids. Currently you have write them as a string, and then call .parse() on them. For fully static data, this is cumbersome and delays error detection until runtime.
Describe the solution you'd like
One solution here would be to have macros for writing ids. You could image something like:
entityuid!(#r"User::"Alice""#)

Parse rules would be checked at compile time, allowing you skip calling .unwrap or handling the error, and making it compile time error if the ID was invalid.
Describe alternatives you've considered
The current situation is workable.
Additional context
This is somewhat inspired by serde_jsons json! macro.
Is this something that you'd be interested in working on?

[X] 👋 I may be able to implement this feature request
[ ] ⚠ This feature might incur a breaking change

In addition to policy and entity ids, we can also do this for Names in general.

I wrote a prototype in #744, which proposes a different syntax. Instead of having an argument which is the string representation of entity uids, it asks for two argument: an entity type and an eid. The eid is simply a string. This design avoids the nuance around string escaping and provides users a more flexible way to specify eids. For instance, they can use raw string syntax when they need literal backslashes like `euid!(Foo, r#""#).


In Fm Radio Broadcast add more presets and if is posible RDS DATA

Hello, in FM radio when scan for new stationa it only memorize 20 radio stations, please, ad at least 100 memories or UNLIMITED.
¿IT IS POSIBLE FOR YOU TO AD "RDS" RADIO DATA SYSTEM AND MAKE TO SHOW Station Name, PTy, radio text, ct clock date and time from the radio station signal? Like in cars radios.
PS, RT, PTY, CT, AF, TP,TA...

I will be happy if you modify to accept 100 pressets
Thanks

This is a ham radio not a broadcast receiver. The FM radio is just an extra function. The FM radio chip has no RDS functionality and alike. 20 stations is plenty enough. I'm not willing to work on expanding that, sorry.


fixadd the FAQ for Aliyun DLF and add the fs.xx.impl…

Proposed changes
merge master change : https://github.com/apache/doris/pull/25594/files

Further comments
If this is a relatively large or complex change, kick off the discussion at<EMAIL_ADDRESS>by explaining why you chose the solution you did and what alternatives you considered, etc...

run buildall

#25594


Spawned Unowned Kerbals not removed on Contract failure conditions

If an Unowned kerbal with trait  Citizen, Civil-Servant, or ServiceKerbal is spawned to a location and the contract fails. Then the kerbals  and any spawned vessels are not removed by Contract Configurator. but remain deployed.
Players can "terminate" these in the tracking station, however this has the effect of changing the kerbal from Unowned to Crew and they are listed as KIA in the lost tab of the Astronaut complex.
If the player has not set dead and missing kerbals return on, then they will remain in the lost tab. On return the kerbals are moved to the Available tab. where they can be dismissed by the player and are then removed from the roster completely.
This does not other game affects  for players using Stock Astronaut complex, or TRP-Hire mod, however if players are using MKS the astronaut complex is unusable for hiring until the dead kerbals with these traits are removed from the roster.

Closed with v2.1.5 release of KSRGAP. Code also present in KSR TLA for next release.


Handle all unhandled promise rejections.

This gives us a clearer error if something goes wrong when calling hasura migrate

Can't wait until we're all on the version of Node where this is just the default


Basic layout 3: Grid layout

Breakdown schetsen

Linke info:

https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_grid_layout


support additional trans-uranic elements

update the atomic data and isotope lists
update the SMILES and SMARTS parsers

It looks like the fileParsers test broke:
****
Test Assert
Expression Failed:
Violation occurred on line 3446 in file /home/travis/build/rdkit/rdkit/Code/GraphMol/FileParsers/test1.cpp
Failed Expression: !m
****
terminate called after throwing an instance of 'Invar::Invariant'
  what():  Test Assert

No wonder, you added the element!
    0.0000    0.0000    0.0000 Lv  0  0  0  0  0  0  0  0  0  0  0  0

This test should be modified or removed:

void testIssue269() {
  BOOST_LOG(rdInfoLog) << "-------------------------------------" << std::endl;
  BOOST_LOG(rdInfoLog) << "Bad issue 269: handling of bad atom symbols in CTABs"
                       << std::endl;


Unrooted Android: How to build librealsense.so and how to interface

Required Info

Camera Model
D400

Operating System & Version
Android

Language
C++

Issue Description
With PR #3083 there is support for unrooted Android on the development branch. However the only
how-tos out there are for Android Studio apps.
We are using Qt5, not Android Studio for development. Therefore we need to get the raw librealsense.so / librealsense.a file that we can integrate into our project.
In the "old" Android docs the build was through CMake and indeed produced a librealsense.so / librealsense.a file in the end. Is this still supported in the unrooted model (What would be the CMake variables to set? What are the necessary source files to build librealsense.so for unrooted Android?)?
If yes, I assume there are some necessary steps to integrate with the Java-based USB management. What are the interface points there? Is there a minimal example that shows how to get something going on Android, just using librealsense.so?

Hi @xtrawurst
I'm not entirely familiar with Qt for Android. First things I wanted to note is that we are not removing the "old" method of working on Android, it is still being covered by CI and should continue to work.
The new approach relies on requesting proper permissions in Java for the activity and passing that information to C++. You can build librealsense2.so via CMake with the new backend (by setting a dedicated CMake flag) but you'd need a way to handle permissions in order for it to work on an unrooted phone.
@matkatz might be able to offer more useful answer

@dorodnic Thanks!
@matkatz No specific Qt instructions are necessary. Just some instructions on how to best build librealsense2.so for Android and how the Java-based permissions connect with the native stuff. Also, I know that in the past libusb was used (for Android, too). IIRC all the USB communication is now through direct ioctl() rather than libUSB. But is libUVC still used on Android? I saw some files in the PR that carried UVC in the name so I was wondering. It would be good to have a high-level overview of how things work now on Android.

@xtrawurst It seems that librealsense is designed to be linux-compatible, thus using low-level libraries as libsusb, which is also supported on Android, but with a permission drawback. A better approach would be to have the devices to provide support for Android Open Accessory, so we could instead use USBManager.
For instance other imaging devices are currently following that approach, like Flir One.

@indigohedgehog Android native support has been added to librealsense (since V2.19.0). It is built on top of Android's UsbHost API and works on unrooted devices.
A sample Java project with  can be found here with instructions (readme.md):
https://github.com/IntelRealSense/librealsense/tree/master/wrappers/android/examples/java_example

@xtrawurst, there is an Android wrapper could be found in Github:https://github.com/zhouwg/irsa.wish it's useful for your purpose.

Hi @xtrawurst
Sorry that it took so long, as @dorodnic said, due to Android permissions limitations, before you can start work with either Java or Native code, you must request permissions for the USB device.
The java wrapper contains 3 classes (Enumerator, DeviceWatcher, RsContext) which together detect USB attach events, request for user permissions and create a UVC device on the native said via JNI calls.
Once the UVC device is created you can either use the c++ API or the Java Api.
Building the so without the AAR means that you will need to handle the USB permissions and create the UVC devices on the native said.

Closing this ticket, please feel free to reopen if problem persists. Thank you.


adding my youtube clone

I added my youtube clone project with Reactjs + Material UI

I'm sorry, sir, all works done fine, or i made some mistake? (I'm beginner)