[DO NOT MERGE] Rework networking to use async/await

For #77
There's still some tinkering I'd like to do, but this seemed like a good spot to solicit some feedback before going any further. I think there's still a fair amount of improving to do making sure things are thread safe (especially returning to the main thread), but that's a WIP. Also, documentation and examples could use a pass over them, whether it's in a separate PR or not.
This PR switches the fundamental networking in Netable to use async/await. I've left in support for networking with Combine or callbacks, but they're now wrappers on the async/await functionality instead of the other way around.
In doing this, I've had to rewrite or change some things like retries and cancellation, and would be most interested in having another pair of eyes look over those.

@nbrooke I made the following changes:

Moved headers into Config, renamed to globalHeaders and set to immutable
Added headers field to Requests to let you set headers per-request. These will get added after global headers, so you can overwrite values as well.
Change enableLogRedaction, baseURL, logDestination and retryConfiguration to be immutable
I left requestFailureDelegate as mutable, it's read-only so I think this is fine? We could make this immutable, but it feels kind of weird given its usage?

I'm going to spend some more time investigating the concurrency checking as well, I'm also overdue for updating to Xcode 14 so some of that might come with that update.

I think requestFailureDelegate WOULD have the same problem I was imagining, even though it doesn't have any visible shared state, even swapping in a new instance both will cause a race condition, and could crash under the right circumstances, i.e.
netable.requestFailureDelegate = a

Task {
    // some netable function that calls
    // requestFailureDelegate.requestDidFail(/*...*/)
}

netable.requestFailureDelegate = b

is both a race condition on whether the call will use a or b, and, under the right circumstances (but, I now think, not THESE exact circumstances) could crash.
So I think it does make sense to make it immutable as well for an async world.
HOWEVER, I did a bit more reading on Sendable and Task isolation, and I'm now back to thinking that the original version of things was maybe actually in practice okay from a thread safety standpoint, and I think I understand why we weren't getting any compiler errors
The key thing I was misunderstanding is that Netable is in fact NOT thread safe, but it doesn't matter, because the way we are using it in the sample (and probably in our apps as well) doesn't require it to be thread safe because everything is limited to a single execution context. I misunderstood what Task does, it creates a new async execution context, but crucially, does NOT actually create it in a concurrent way, all of the code in the previous examples I gave is still executing on the same thread because the task inherits all context from it's parent. I sort of knew that, but hadn't totally got that in this case it meant we were ALWAYS in the same execution context, even with creating multiple tasks and bouncing back and
If we wrote the following (which does create a real concurrent context):
let netable = Netable(/*...*/)

Task.detached {
    await netable.request(...) // likely compile error here
}

we would be creating thread unsafe code, but here the compiler checking would kick in and (I believe would) get an error on the indicated line because Netable doesn't conform to "Sendable" so can't actually be sent to a genuinely concurrent context created by Task.detached. And if we did try and conform it to Sendable, we would get an bunch of warnings about any mutable state that was not protected.
It might eventually be useful to make Netable genuinely thread safe and Sendable, so we can potentially use it in parallel from different actors and so on, but it's probably better not to worry about that for now. I still think making everything immutable is a good idea, because it prevents the race condition in any code like the above.
The realization has two interesting follow ons:

I think this means that the @MainActor annotations in the current code are unnecessary. The callbacks for the legacy request functions, the Combine publishers, and the logging I think are guaranteed to happen on the same actor that the Netable instance was created on (which will usually be the main actor). In fact, it's probably slightly better not to have them, because getting those callbacks in the thread / execution context that the instance was created in is probably better than always getting them on the main actor. Even if it doesn't cause any problems, it's at least less efficient to do some uneccesay actor hopping there.
I think this means that async version of the code is, ironically, lower performance than the old callback based version. I mentioned previously that the decode and finalize previously ran on the URLSession background thread with that being super well documented, this code I think "fixes" that, but does it by implicitly moving them to the same actor (i.e. the main actor), so the decode operation will block the main thread.

To fix the second problem, I think we need to actually make Request conform to Sendable (to guarantee that the decode and finale functions can be called on a background thread), and probably run the decode from a Task.detached call, or maybe using async let. I'm having quite a bit of trouble figuring out how to actually structure that code to force it to run on a background thread, but suspend the main task while it is working.

I think the incantation for forcing the decode to get done on the background thread is something along the lines of replacing:
let decoded = try await request.decode(data, defaultDecodingStrategy: self.config.jsonDecodingStrategy)
let finalizedResult = try await request.finalize(raw: decoded)

with
let strategy = self.config.jsonDecodingStrategy // don't want to try and capture self, or it needs to be Sendable
let finalizedResult = Task.detached {
    let decoded = try await request.decode(data, defaultDecodingStrategy: strategy)
    return try await request.finalize(raw: decoded)
}.value

Like I said, I believe request will need to be Sendable for that to work.
Getting a bit worried there is still something I'm not understanding here though, because in trying to build a quick playground to verify the above, I also tried checking if code like the detached version I had before WOULD produce a compiler error, and I couldn't make it do that, so I feel like there still some wrinkle I'm missing.

I feel like I'm definitely missing something here...

"I think this means that the @MainActor annotations in the current code are unnecessary. "

I don't think this is true, if I run the app with the following change it complains about UI updates happening outside the main thread:
    func getPosts() {
        Task { // @MainActor in OMITTED HERE //
            do {
                let posts = try await self.netable.request(GetPostsRequest())
                self.posts.send(posts)
            } catch {
                print(error)
            }
        }
    }

Yeah, that for sure points to something we are still missing here. The documentation seems to vaguely support the idea that should work, in particular the documentation for the task constructor being called there (https://developer.apple.com/documentation/swift/task/init(priority:operation:)-5ltye) specifically says inherits the priority and actor context of the caller which definitely sounds to me like those tasks maybe should be created on the main actor if the calling code is on the main thread.
Maybe when you are on the main thread but in a synchronous context the actor context is "nothing" rather than being "main actor". so those top level tasks that the app is creating ARE actually independent (If that's the case though, then it seems like were back to "this shouldn't be thread safe"), or maybe there is no actor context here because Netable isn't an actor.
Very confusing.

Okay, getting closer to understanding this, this thread here: https://developer.apple.com/forums/thread/710646 is really useful, someone else grappling with similar issues and a solid response from Apple developer relations.
My takeaway from that thread:

Context inheritance it sounds like is static, not dynamic. So if you have a method on an actor, or annotated with a global actor like @MainActor any tasks spawned in that function will inherit the context, but a function won't inherit the dynamic actor context from the caller of that function. That also explains (I think) why it looked like this did the right thing in my little bit of testing in a playground, because that all WAS in a static context.
That means I'm back to my original position, which is that this isn't safe unless all properties of Netable are `let's or Netable is an actor.
We do need those @MainActor annotations.
We definitely should try this under Xcode 14 with strict concurrency checking before committing it

Semi-related, I'd missed before, but noticed while digging around in Netable trying some stuff out for this, but the global request failure  delegate and subject are only updated when using the legacy functions, we should probably either make that work in the async version, or mark those as deprecated as well. If we do make them work, they might need some tweaks (delegate should probably be async, and need to think about that thread things are dispatching on for the publisher.

WRT global request failure delegate/subjects, I think I'm a little more inclined to mark them as deprecated or just remove them. I think with our current architectures they make less sense than when we put them in, and atleast personally I haven't needed them any time recently.

Some kind of global failure channel seems like a pretty good fit for the ErrorService stuff in the mvvm architecture / utility belt library, so I don't think our newer approaches to architecture necessarily invalidate this.
Those global channels have always struct me as more potentially useful from a logging standpoint than from a behavioural standpoint (with the possible exception of automatic logout on any 401 errors) so I think it'd be tough for us to "need" them to make some architecture work. Question is, have we not been using them because it just didn't occur to us, and it would actually be useful, but not so useful to naturally force them into action, or is it actually NOT suitable for implementing the sort of things we thought it might be (global error logging, global error reporting to the user via popups/toasts/whatever, universal logout on 401s).

Updated a bunch of things, including just trying out moving Netable to an actor? Seems like there was enough things cropping up that it seems worth trying, and maybe a little easier than expected?

@nbrooke  I took another pass through things with the Xcode 14 concurrency checking turned on and handled all but one of the warnings. As we suspected it's mostly just being explicit about what is/isn't sendable all over the place. Let me know what you think.


CSS hack to fix scroll to anchor

as per https://github.com/jhildenbiddle/docsify-tabs/pull/61
This is a Docsify issue with not knowing the height of the docsify-tabs sections before it does the scrolling. It's been like 4 years and it hasn't been fixed yet so this hack will have to be it for now.

thank you !!


Choosing which real output device to pass sound through

Hey there,
I have two output devices: my laptop speakers and a pair of bluetooth headphones.  When I switch to wavtap, it redirects the audio to my laptop speakers.  How can I make it redirect the audio to my headphones so I can use my headphones and still capture audio with wavtap?
Thanks!

+1


GPT to add: BounceBan

Link:
https://chat.openai.com/g/g-q5uXtrvkH-bounceban-com-free-email-verification
Description:
The only email verification service that supports verifying catch-all emails. 97+% accuracy guaranteed. Free & Unlimited for ChatGPT. Tips: 1) Enter one or multiple emails for verification. 2) Enter "Gavin Lee bounceban.com" to generate and bulk verify up to 30 potential email addresses.

Done


Static URL support

I want to merge this change because it adds static url configuration.
Pull Request Checklist

[x] All visible strings are translated with proper context.
[x] All data-formatting is locale-aware (dates, numbers, and so on).
[x] The changes are tested.
[x] The code is documented (docstrings, project documentation).
[x] Changes are mentioned in the changelog.

Test Environment Config

API_URI=https://master.staging.saleor.rocks/graphql/

@marianoeramirez thank you for your contribution! :)


🐛 Bug Report: Website reloads on clicking the logo

📜 Description
Clicking on logo restarts the website as we are using an  tag to go to route /
Instead of this we can call the reset conversation method we have to start a new chat, which would make it more effecient
👟 Reproduction steps
Click on DocsGPT logo in drawer
👍 Expected behavior
It should start a new chat without the website refreshing
👎 Actual Behavior with Screenshots
Reload is encountered
💻 Operating system
MacOS
What browsers are you seeing the problem on?
Chrome
🤖 What development environment are you experiencing this bug on?
Docker
🔒 Did you set the correct environment variables in the right path? List the environment variable names (not values please!)
Yes
📃 Provide any additional context for the Bug.
No response
📖 Relevant log output
No response
👀 Have you spent some time to check if this bug has been raised before?

[X] I checked and didn't find similar issue

🔗 Are you willing to submit PR?
Yes, I am willing to submit a PR!
🧑⚖ Code of Conduct

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

Hi
It's not a bug, was reasonably added, Thanks!


Is there any academic paper for pegasus?

I want to cite pegasus, but I cannot find the academic paper for pegasus. Is there any academic paper for pegasus? I mean the first paper about pegasus.

Hi @tangmaomao16 ,
The paper about Pegasus is "Cumulus provides cloud-based data analysis for large-scale single-cell and single-nucleus RNA-seq", which was published on Nature methods in 2020.
Hope it helps.
Sincerely,
Yiming


Lua 5.4 allows 31bits utf8 codepoint

@fperrad looks like the unit test needs to be adjusted accordingly. Do you know if the luacheck lexer or parser take the Lua version into account for anything? I'm not sure (I added the <close> support to the parser unconditionally...)

@hishamhm AFAIK, the behaviour of lexer & parser doesn't depend on the Lua version, they handle a superset of all versions (for example, the lexer handles LuaJIT extensions for literal).
As I understand it, the real job of luacheck is not to recreate all the lexico/grammar errors of a particular Lua version (on error, lua anyway dies), but it is to generate warning about misused variables and/or some dangerous constructs  (lua never complains on a luacheck warning).

Makes sense! Thanks for fixing the test!


Filter building

Codecov Report

Merging #75 into master will decrease coverage by 0.77%.
The diff coverage is 49.12%.

@@            Coverage Diff            @@
##           master     #75      +/-   ##
=========================================
- Coverage   62.97%   62.2%   -0.78%
=========================================
  Files          18      18
  Lines         967    1024      +57
=========================================
+ Hits          609     637      +28
- Misses        358     387      +29

Impacted Files
Coverage Δ

src/problemgenerator/filters.py
64.01% <49.12%> (-2.02%)
:arrow_down:

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 cba22c9...a5be37c. Read the comment docs.


Integration with SmokeDetector and Metasmoke

Here's a list of changes that need to be built into Metasmoke or SmokeDetector to make them compatible with Helios:
SmokeDetector:

Notifications

[ ] Keeps cache of notifications from Helios, reloads cache when it becomes active
[ ] Pushes new notifications to its cache and to Helios and sends a message to Metasmoke over the websocket (format TBD)
[ ] New command to kick cache

Black/Watch listing

[ ] Pushes black/watch list requests to Metasmoke over websocket (Format TBD)

[ ] Falls back to pushing black/watch list requests from privileged users to Helios
[ ] Shows error when Metasmoke is down and an unprivileged user attempts to edit the black/watch list

[ ] Keeps cache of black/watch list items from Helios, reloads cache when it becomes active
[ ] Post a message when a black/watch list item is approved (will receive a WS message from Metasmoke, format TBD)
[ ] New command to kick cache

Metasmoke:

Notifications

[ ] UI for viewing/editing
[ ] Cache which can be refreshed from Helios on button click
[ ] Can push items to cache when receiving a message on it's websocket to Smokey

Black/Watch listing

[ ] Recieve black/watch list requests from SmokeDetector (push to Helios if privileged, otherwise add to pending list)
[ ] UI for approving black/watch list requests

[ ] On approval push to Helios and send WS message to smokey

[ ] Cache can be refreshed with a button click
[ ] Send invalidation notice to Helios at appropriate time when a SmokeDetector token is revoked / removed.

SmokeDetector/Metasmoke new websocket messages (format TBD):

MS -> SD  Black/watch list item has been approved (reply "message posted")
SD -> MS New black/watch list item (reply "success")
SD -> MS New notification (reply "success")
MS -> SD Kick watch/black list / notification cache (reply "success")

Some questions:
Could Helios have some endpoint which gives changes since ?
On the MS/SD websockets, is there usually a "success" reply?

Looks good to me, @AWegnerGitHub and maybe @quartata would know more about blacklisting details.
Edited to add sending a notice to Helios when a token gets invalidated.


CancellationToken

Sorry if this has been asked before but i cant find any documentation on it. Is it possible in MVC6 to get a CancellationToken triggered when aborting an ajax request for example. IsCancellationRequested is always false. From what i understand this was possible in MVC4 and WebAPI, not MVC 5+6?
public async Task<IActionResult> CancelTest(int id, CancellationToken cToken)
{
    Debug.WriteLine("Started");

    for(var i = 1; i <= 10; i++)
    {
        await Task.Delay(3000, cToken);

        if (cToken.IsCancellationRequested)
        {
            Debug.WriteLine("Canceled");
            break;
        }
    }

    return Json(new { data = "CancellationTest", id = id });
}

Use the httpContext.RequestAborted token?

Thank you. Same behaviour. I believe if you put a CancellationToken in your action method the model binder binds it to HttpContext.RequestAborted though.

Yeah, using httpContext.RequestAborted is the same thing as taking it as a parameter; https://github.com/aspnet/Mvc/blob/a5db01169af91bee3eca6ebfabf2b6b3d6c75539/src/Microsoft.AspNetCore.Mvc.Core/ModelBinding/Binders/CancellationTokenModelBinder.cs#L29

some background here..
/cc @Tratcher in case he wants to add more
The RequestAborted token is triggered server-side, by your code. It's intended to be used when the server wants to cancel pending work based on a timeout or some other criteria.
In old webapi, we used to provide a token that fired when the client disconnected, and this is what we model-bound by default. This led to the assumption that the right thing to do was to always use that token, and pass it into every API call that could accept it.
This led to a lot of exception noise in logs for cases that you really can't troubleshoot.
This also led to the wrong semantics in a lot of cases. Would you abort a database transaction if the client disconnects while it's processing?
This is why we bind RequestAborted and why aborts are now triggered in server-side code rather than by the client hanging up.
Use it in good health with this knowledge.

Thank you for background and clarification. Makes sense to me now.

Just to clarify. I understood that now CancellationToken is not triggered by a client. But is there any other way to be notified that the client aborted the connection? In my application this is a desired behavior to abandon any further server-side processing when the request is aborted.

/cc @Tratcher @davidfowl - where did we put the client disconnected token?

https://github.com/aspnet/HttpAbstractions/issues/197 ?

@rynowak RequestAborted is ClientDisconnected, we haven't made any effort to separate them. That said, client disconnects can be difficult to detect. If the client disconnects gracefully (FIN), Kestrel won't detect it unless you send multiple writes and the client sends a RST in response. If the client disconnects with a RST first Kestrel should detect that and fire RequestAborted.  WebListener currently triggers RequestAborted for FIN or RST.

So is all the information that I've ever given out on this topic false then?

@Tratcher We should do the same in Kestrel (i.e. fire the RequestAborted token for both FIN and RST). It's affecting SignalR right now.

The order the RST comes in is irrelevant. If a RST is received with or without a prior FIN, RequestAborted will fire. RequestAborted will not fire with just a FIN from the client since the TCP connection is in a half-open CLOSE_WAIT state (i.e. it's still valid to write to the response). Maybe for HTTP we should treat CLOSE_WAIT as disconnected/aborted, but we should investigate to make sure this wouldn't break real clients.

Is there any update on this issue? This is really important especially when you are dealing with disaster recovery situations where the majority of the request should not be processed (due to client disconnection). We have a microservice archuiteture and this can actually prevent a "snowball" effect.

We are currently looking at changing the RequestAborted token for the next release. There's an open PR for this change at https://github.com/aspnet/KestrelHttpServer/pull/1218.
The RequestAborted token will still fire today given failed writes or a RST from the client. In some scenarios, it's possible to send keep alive messages to the client and check the RequestAborted token to more reliably ensure the connection is still alive.

This was fixed in Kestrel.

This definately used to work as I tried it when David Paquette wrote a blog post blog post about it. What release was this fixed in, I'm trying the following code with ASP.NET Core 1.1.1 and can't get this to work as expected.
public class Model { public class CancellationToken { get; set; }

[HttpGet("foo")]
public async Task<IActionResult> Foo(Model model, CancellationToken cancellationToken)
{
    await Task.Delay(10000);
    var a = cancellationToken.IsCancellationRequested;
    var b = this.HttpContext.RequestAborted.IsCancellationRequested;
    var c = model.CancellationToken.IsCancellationRequested;
    return this.Ok(); // Set breakpoint here
}

<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script>
<script>
var request = $.get(
  "http://localhost:5000/Bar/foo",
  function(msg) {
    alert("done");
  });
setTimeout(function() {
  request.abort();
  alert('aborted');
},
1000);
</script>

@RehanSaeed - can you provide more information about what you mean by used to work? How do you expect the system to behave vs what is it doing?

"In MVC 6, uses RequestAborted which from the HttpContext which a CancellationToken so it does work as expected."
David Paquette

However, my code above does not show true for this.HttpContext.RequestAborted.IsCancellationRequested using 1.1.1.

This only works in 2.0 not in 1.x

Hello,
Please clarify: is it true that cancel a ajax call to a async action in ASP.NET Core is not possible in Version 1.x?
robert

It really has nothing to do with Ajax, there's currently no cancellation token that represents the lifetime of the client. If you want to cancel some sever side operation then you need to create a cancellation token with a timeout and pass that to whatever APIs you call.

Hi David,
I have the following async Action in my ASP.NET MVC Controller (see below) where I get some SQL as a parameter and execute that query and the user should have the possibility to press a button to cancel the running query if it takes to Long...
can you give me a short example how to cancel the async Action from the client if I press a button please?
public async System.Threading.Tasks.Task<ActionResult> ReadAsync(string queryJson, string optionsJson, [DataSourceRequest] DataSourceRequest request, CancellationToken cancelToken)
        {
            try
            {

                var query = eqService.GetQueryByJsonDict(queryJson.ToJsonDict());
                var sql = eqService.BuildQuery(query, optionsJson.ToJsonDict());

                var result = await Db.QueryAsync<dynamic>(sql, commandType: System.Data.CommandType.Text,cancellationToken: cts.Token);

                return Json(result.ToDataSourceResult(request));
            }
            catch (Exception ex)
            {
                return Json(ex);
            }

        }

I have just installed VS2017 15.3 and the CORE 2.0 SDK. Created a new ASP.NET CORE 2.0 (CORE) APP, and implemented the CancellationToken in a method, and it still doesn't get triggered. I can even close the browser (Edge), and even then, the HttpContext.RequestAborted (CancellationToken) is not triggered. I've tried with IE, Chrome and Edge, no luck so far!? Any ideas?
    public async Task<IActionResult> About(CancellationToken token)     {       try       {         ViewData["Message"] = "Your application description page.";          You're using IIS right? There's still an issue there https://github.com/aspnet/AspNetCoreModule/issues/38 (unfortunately)

Exactly... yes, i was using IIS Express, and yes, it works like a charm with the Kestrel server :)

I am using kestrel and the example code above does not work.

Thanks for contacting us. We believe that the question you've raised have been answered. If you still feel a need to continue the discussion, feel free to reopen it and add your comments.


Issue Etiquette

So far I have had 3-4 issues closed mid discussion.  Half of them were reopened.  Contributors will feel more respected and welcomed if they are allowed to close the tickets that they opened.

I disagree.
If the issue opened shouldn't/won't be implemented for whatever reason then leaving it up to the author to close it means it will just stay open forever and create noise around proper issues that aren't discussion points/questions. There are dozens of such issues peppered over this organisation.
It sounds like a lot of those things would be ideal in a gitter chatroom instead, which postcss use quite effectively to keep the noise out of the github issues. What about using that?

Gitter could be a good venue for more "discussion" stuff. Also wouldn't mind hopping on a private Slack group. Seems like there's a fairly active group of a few of us that could hash stuff out more productively in discussion than issues.

One thing in favour of Gitter is it seems to keep a history of the chats and ties in nicely with issue numbers and PRs. Slack has a chat limit and is a bit annoying with the invite only nature

Ok, lets stick with gitter

https://gitter.im/suitcss/suit

To be clear, the types of issues that I'm referring to are the types were closed mid discussion.  I'm sure we would all like as many contributors as possible, and if we turn them off providing short answers and acting like the discussion is over, that's not good for the health of the project, because there are plenty of projects that follow a more polite etiquette.  If something has been sitting around for 20 days, then it's obviously not that important to the person that opened it, and it can be closed, assuming everyone agrees that it's irrelevant the project.
Also for other joining in these issues are a good serve as a good introduction as to why certain things were done a certain way.

Seems like there's a fairly active group of a few of us that could hash stuff out more productively in discussion than issues.
+1 on the chat.

I closed this issue, as it seems we have moved to gitter.  Anyways if anyone wants it reopened let me know.  :)


Improve QAOA callback to track progress

Migrated to https://github.com/BrunoRosendo/vrp-quantum-solver/issues/3


fixed layout

Hi i am new to tokbox. how  to setup fixed  one big and rest all small, onclick replace the big with clicked small element and the make the big one is small .  I tried to achive the same,but unable to get it done. Please guide me on this. thanks for your wonderful work.

You should be able to do this just by changing classes. So give the big element an "OT_big" class. Then when you click an element make that one "OT_big" and remove "OT_big" from the others. I'm doing something similar in the demo with double click here

You should be able to do this just by changing classes. So give the big element an "OT_big" class. Then when you click an element make that one "OT_big" and remove "OT_big" from the others. I'm doing something similar in the demo with double click here


Performance Report

Performance Report
The case study is between licensee and PackageEvaluator script for registered Julia packages.
Data
Out of the packages and detected licenses from PackageEvaluator Website for registered Julia packages 100/1,759 did not match. The mismatches are here (updated 2018-06-13).
Specifics
Licensee was ran on the Julia package repositories and the top probability license was selected.
Actionables
Hope this information helps to continue improving the project.

Hi @Nosferican thanks for posting this. What version of licensee did you use? I suspect fairly old, as the very first entry (https://github.com/Algocircle/Cascadia.jl) shows licensee detecting MIT, but any semi-recent version would not because the LICENSE file has a lot more than just the MIT license.
PackageEvaluator's license detection probably works for lots of packages, but it's not robust at al. I don't know Julia, but it's pretty obvious what is going on:

https://github.com/JuliaCI/PackageEvaluator.jl/blob/3dbc8169e9d26aef36ceb97e3175465cebf2f2ec/src/prepjson.jl#L50-L57
https://github.com/JuliaCI/PackageEvaluator.jl/blob/3dbc8169e9d26aef36ceb97e3175465cebf2f2ec/src/prepjson.jl#L17-L27
https://github.com/JuliaCI/PackageEvaluator.jl/blob/3dbc8169e9d26aef36ceb97e3175465cebf2f2ec/src/constants.jl#L14-L54

It reports the first entry as MIT because it looks for MIT first and the first example's license file does include the text of the MIT license (but that's not all it includes) and PackageEvaluator sees this based on matching just one of these short regexes (from the third file above):
("MIT",[
                    r"mit license",
                    r"mit expat license",
                    r"mit \"expat\" license",
                    r"permission is hereby granted, free of charge,"]),

Obvious this is going to cause some false positive identifications of MIT, such as when other terms are included in a LICENSE file.
It would be very useful to compare licensee detections to detections from other tools that try to be robust. Unfortunately I don't think there's much that can be gleaned from a comparison to Julia PackageEvaluator output. I don't intend this as a criticism of PackageEvaluator -- I'm sure it's authors did the simplest thing that works much of the time, and that may well be the right decision for whatever their needs are.

By the way @Nosferican I noticed that you posted this to https://github.com/JuliaCI/PackageEvaluator.jl/issues/205 as well and someone there pointed out that you've got licensee identifying https://github.com/DynareTeam/Dynare.jl as Unlicense. This again makes me think you're using a very old version of licensee. I see you also mention in that issue "work on a standard machine readable metadata schema in project.toml" -- I urge you to use SPDX license expressions as the permissible values, as lots of programs already know how to deal with those and they are unambiguous -- most of the time an expression will just be a single identifier such as "Apache-2.0" (simple, but there are lots of ways to come up on one's own about how to write that fact).

Or maybe you're using a current version of licensee and taking "closest" to mean something other than intended. You write:

Licensee was ran on the Julia package repositories and the top probability license was selected.

Output of licensee 9.9.1:
$ script/git-repo https://github.com/DynareTeam/Dynare.jl
License:        NOASSERTION
Matched files:  LICENSE.md
LICENSE.md:
  Content hash:  10d088666241c6e88aafb51d721d4b78a275c221
  License:       NOASSERTION
  Closest licenses:
    Unlicense similarity:   38.92%
    Zlib similarity:        34.90%
    PostgreSQL similarity:  33.75%

NOASSERTION is what licensee is saying here. Maybe we should change "Closest licenses" to something else to warn against taking one of them as licensee saying it has detected one of them.

Thanks for the information. I used v9.9.1 choosing the top closest license as a best guess. Will be examining some of the cases to develop a better classifier (maybe using the similarity and some labels). PackageEvaluator is design exclusively for Julia packages, but I wanted to see the relative performance compared to a more general case tool. I am quite happy with Licensee. I imagine that there might be some potential insight from that sample that can be used to improve the general error of licensee for other languages that haven't been been explored.

Made a small change in #307 that hopefully will make it less likely for anyone to take "closest" as "best guess". I don't think there's anything else immediately actionable, so closing. Thanks again for opening the issue, very interesting!


renderIcon doesn't work

renderIcon={() => <Image source={require('image!home')} style = {styles.size}/>}
renderSelectedIcon={() => <Image source={require('image!home')} style = {styles.size}/>}

renderIcon={() => <Image source={require('image!ic_collected_white')} style = {styles.size}/>}
renderSelectedIcon={() => <Image source={require('image!ic_collect_white')} style = {styles.size}/>}

renderIcon = {() => <Image source={require ('image!ic_collected_white')}/>}
renderSelectedIcon = {() => <Image source={require('image!ic_collect_white')}/>}

Can you verify that your icon <Image> components show up when you use them outside of the TabNavigator?

TabNavigator  Are there any requirements for image size?

You should make them about 22x22 big but it doesn't need to be exact. You can also put some margin/padding on them to adjust their positions.

Thanks


Discussion: Networking configuration and static IP assignments

Currently, I've been working on static IPv4 assignments for my VMs, which is necessary for local IaC development when IP addresses are expected to be deterministic as I bring up/tear down machines.
Unfortunately, there isn't great interop with ARM & Multipass (ie. M1 mac), but I've gotten something jank kind of working per these docs. https://multipass.run/docs/configure-static-ips
Weirdly though, I cannot have this entire setup work with cloud-init alone. It seems like I have to manually apply a new netplan file and apply it as two separate steps. Only then do I see an IP assignment and MAC addresses matching what I expect.
multipass exec -n test12 -- sudo bash -c 'cat << EOF > /etc/netplan/10-custom.yaml
network:
    version: 2
    ethernets:
        extra0:
            dhcp4: no
            match:
                macaddress: "52:54:00:4b:ab:dd"
            addresses: [<IP_ADDRESS>/24]
EOF'

In order for this to work, I create my VMs with some special arguments:
multipass launch --name my-vm-test --network name=en0,mode=manual,mac="52:54:00:4b:ab:dd" --cloud-init cloud-init.yaml

As you can see, I supply the en0 interface, which is listed as an available bridge via multipass networks along with a static MAC address that is later linked via the netplan yaml above.
It would be nice to be able to support passing in the network_name and mac_address and maybe ip_address_v4/ip_address_v6 as parameters in the Terraform provider to handle this during initialization so I can keep it all self-contained in Terraform. Does this seem reasonable? I'd be happy to work on this if so. Open to discussing this as I'm new to Multipass and find the networking to be both poorly documented and convoluted.
I'm still a bit confused why the cloud-init supplied doesn't take affect, but I'm all ears.

Ok, I hacked this together to make sure my mental model was correct and it seems to be working. I wrote an article to document these learnings in case it's of any use to anyone.  https://ryan-schachte.com/blog/ansible_multipass/
If it seems worthwhile, I can work on making this more production ready so we can release it to support the networking options provided by the Multipass team.

go-multipass changes
provider changes

Tested locally, this seems to work well assuming I manually apply a netplan config file.
resource "multipass_instance" "dev_vm" {
  for_each = { for i, name in var.instance_names : name => {
    ip_address  = var.ip_addresses[i]
    mac_address = var.mac_addresses[i]
  } }

  name   = each.key
  cpus   = var.cpus
  memory = var.memory
  disk   = var.disk
  image  = var.image

  cloudinit_file    = local_file.cloudinit[each.key].filename
  network_interface = "en0"
  mac_address       = each.value.mac_address

  provisioner "local-exec" {
    command = <<-EOT
      multipass exec ${each.key} -- sudo bash -c 'cat << EOF > /etc/netplan/10-custom.yaml
      network:
        version: 2
        ethernets:
          extra0:
            dhcp4: no
            match:
              macaddress: "${each.value.mac_address}"
            addresses: ["${each.value.ip_address}"]
      EOF'
      multipass exec ${each.key} -- sudo netplan apply
    EOT
  }
}

Thanks for the write-up @Schachte, I am just about to embark on a similar test using multipass. It's made things a bit clearer


Get "unnecessary" range on first page

Attach (recommended) or Link to PDF file here:
https://github.com/liu-dongyu/demo/blob/main/pdf/test.pdf
Configuration:

Web browser and its version: Chrome 98.0.4758.80
Operating system and its version: MacOS 10.15.5
PDF.js version: v2.12.313 and v2.3.200
Is a browser extension: no

Steps to reproduce the problem:

A pdf online url which support range request
set disableAutoFetch: true disableStream: true rangeChunkSize: 65536 * 16 to getDocument
getPage(1) then render

What is the expected behavior? (add screenshot)
With v2.12.313，first page need 60 range request，online demo

source code
<script src="https://cdn.bootcdn.net/ajax/libs/pdf.js/2.12.313/pdf.min.js"></script>

pdfjsLib.GlobalWorkerOptions.workerSrc = "https://cdn.bootcdn.net/ajax/libs/pdf.js/2.12.313/pdf.worker.min.js";

const loadingTask = pdfjsLib.getDocument({
  url: "xx",
  disableAutoFetch: true,
  disableStream: true,
  rangeChunkSize: 65536 * 16,
});

(async function () {
  const pdfDocument = await loadingTask.promise;
  const page = await pdfDocument.getPage(1);

  page.render({
    canvasContext: document
      .getElementById("pageContainer")
      .getContext("2d"),
    viewport: page.getViewport({ scale: 1 }),
  });
})();

With v2.3.200，first page only need 3 range request (3 is the expected request times) online demo

source code
<script src="https://cdn.bootcdn.net/ajax/libs/pdf.js/2.3.200/pdf.min.js"></script>

pdfjsLib.GlobalWorkerOptions.workerSrc = "https://cdn.bootcdn.net/ajax/libs/pdf.js/2.3.200/pdf.worker.min.js";

const loadingTask = pdfjsLib.getDocument({
  url: "xx",
  disableAutoFetch: true,
  disableStream: true,
  rangeChunkSize: 65536 * 16,
});

(async function () {
  const pdfDocument = await loadingTask.promise;
  const page = await pdfDocument.getPage(1);

  page.render({
    canvasContext: document
      .getElementById("pageContainer")
      .getContext("2d"),
    viewport: page.getViewport({ scale: 1 }),
  });
})();

What went wrong? (add screenshot)
Why v2.12.313 need too many chunks to render first page and it is possible to optimize it ?

set disableAutoFetch: true disableStream: true rangeChunkSize: 65536 * 16 to getDocument

Please note that disabling of streaming will generally lead to worse performance, compared to the default values.
Furthermore, note that using such a large chunk-size may also affect things negatively.

Why v2.12.313 need so many chunks to render first page and it is possible to optimize it?

Unfortunately this is the expected result of PRs such as #14311, #14335, #14358, and #14411 which were necessary in order to avoid serious problems in corrupt PDF documents.
Note in particular https://github.com/mozilla/pdf.js/pull/14311#issue-1063833849, which contains the following passage where the second point applies to your PDF document:

Unfortunately these changes will have a number of somewhat negative side-effects, please see a possibly incomplete list below, however I cannot see a better way to address this bug.

This will slow down initial loading/rendering of all documents, at least by some amount, since we now need to fetch/parse more of the /Pages-tree in order to be able to access the last page of the PDF documents.
For poorly generated PDF documents, where the entire /Pages-tree only has one level, we'll unfortunately need to fetch/parse the entire /Pages-tree to get to the last page. While there's a cache to help reduce repeated data lookups, this will affect initial loading/rendering of some long PDF documents,
This will affect the disableAutoFetch = true mode negatively, since we now need to fetch/parse more data during document initialization. While the disableAutoFetch = true mode should still be helpful in larger/longer PDF documents, for smaller ones the effect/usefulness may unfortunately be lost.

Closing as INVALID, since we cannot "fix" this without breaking other PDF documents and that this issue is specific to badly generated PDF documents.

@Snuffleupagus before I open a new issue can you please clarify if this behavior you're describing should impact a properly linearized PDF? Because I am having this issue too with a 2000+ PDF that is definitely linearized and I am using the correct settings in getDocument. Most linearized PDFs do not load all at once but this one does.

@legistek we think so. @Snuffleupagus

Leaving a comment for those that end up here from a search. Or a link on stack overflow.
We also had this issue with PDFs that we were creating and linearizing with QPDF.
We found that if we force min-version=1.6 while creating the document, then the document loads as expected in PDF..js with settings disableAutoFetch: true and disableStream: true
The test.pdf in the original post is at PDF version 1.3. I downloaded it and used QPDF to transform it to version 1.6
qpdf --min-version=1.6 test.pdf test1_6.pdf
That document renders the first page after 3 range requests.
For anyone looking at this I believe you should still consider Snuffleupagus' comment:

Please note that disabling of streaming will generally lead to worse performance, compared to the default values.
Furthermore, note that using such a large chunk-size may also affect things negatively.

If the user is likely to read/scroll through most of the PDF, or perform a search then the streaming mode is probably better.

Leaving a comment here as well, as I have a similar issue.
Rewriting problem PDFs with QPDF does help, but it's not related to the PDF version. It's because QPDF restructures the file.
A summary of the cause of the problem:

pdf.js loads the "last" page (i.e. page "count - 1") to validate that the PDF is at least somewhat correct
because of how /Pages dicts' children work, finding information about page N requires traversing the /Pages tree for all previous pages. In the case of a PDF with all the pages in a flat structure this means reading every /Page dictionary for pages 0-N (i.e., for the last page, every /Page dictionary)
problem PDFs (at least the ones I have problems with) interleave /Page dictionaries and content, i.e. the PDF looks like this

/Pages << /Kids [ all the /Page refs ] >>
/Page for page 0
Content for page 0 (big)
/Page for page 1
Content for page 1 (big)
etc

so every Page dictionary is in a different chunk and needs to be fetched separately.

In addition, pdf.js awaits each of those requests in turn, so for a 300 page document you are waiting for 300 XHRs one after the other. I recently had a PR accepted #18627 which will send the XHRs in parallel, which will mitigate the issue, but you'll still be sending 300 XHRs.
QPDF fixes this because when it rewrites the PDF the structure is
/Pages << /Kids [ all the /Page refs ] >>
/Page for page 0
/Page for page 1
etc (other /Page dicts)
Content for page 0 (big)
Content for page 1 (big)
etc (other content objects)
... and so all the /Page dicts are within a small number of chunks.
Although there's an argument that such interleaved PDFs are 'bad', they seem to be quite common from digitisation. I will start a discussion about whether there are circumstances where we can trust a PDF enough to use the /Pages->/Kids as a random access lookup table.


Prefer ctest and cmake --install over generated targets

:notebook_with_decorative_cover: Description
This PR contains a bunch of things left out of #1657 intentionally to keep that PR simple.
:memo: Checklist

[x] All user-facing changes have changelog entries.
[x] The changes are reflected on docs.tenzir.com/vast, if necessary.
[x] The PR description contains instructions for the reviewer, if necessary.

:dart: Review Instructions
Commit-by-commit, or file-by-file when enabling "hide whitespace changes".

Actually, addendum after looking at the CI results: The gcc warning is not a false positive imho, this is a real bug in data_processor.hpp. We just can't do much about it since it's in caf. So at least the commit message/comment should be reworded.


Openthread build flags

Fixes: #28197
Update openthread to build flag changes for fixing #28197.
see https://github.com/zephyrproject-rtos/openthread/pull/29
It also introduces zephyr_get_targets() that allows fetching of build target from a directory and down.
This is useful when including external modules where only libraries
required by Zephyr should be built, and remove the need of setting build flags on openthread libraries not used by Zephyr.
This has the positive side effect of reducing the number of build steps and build time significantly.
Before, 780 steps:
time ninja -Cbuild
[708/708] Linking CXX executable zephyr/zephyr.elf
135.08user 30.24system 0:46.21elapsed 357%CPU

After, 480 steps:
time ninja -Cbuild
[480/480] Linking CXX executable zephyr/zephyr.elf
84.02user 18.92system 0:30.72elapsed 335%CPU

DNM added because manifest contains pull/29/head.


Example demonstrating how to use the ProComponent API

I stumbled across the Halogen.Component.Profunctor module by chance a few days ago but couldn't find any relevant documentation or examples, hence this pull request.

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

I'm going to close this for now, for two reasons:

The Halogen API has changed, so this is broken.
This example probably doesn't line up with a real-world use case. I think this is more likely to be used for something like wrapping/unwrapping values rather than conversions.


Add uk_UA translation files

Q
A

Bug fix?
no

New feature?
yes

BC breaks?
no

Deprecations?
no

Related tickets
fixes #X, partially #Y, mentioned in #Z

License
MIT

Plugin doesn't contain translation to Ukrainian, i added needed files.

Thanks a lot!


AfterMapping causing null reference exception with interface mapping

When using interface mapping with AfterMapping, like so:
[Mapper]
public interface ITheMapper {
    To Map(From from);
}

public class MapReg : IRegister {
    public void Register(TypeAdapterConfig config) {
        config.NewConfig<From, To>()
            .AfterMapping(to => { Console.WriteLine("Mapped!"); });
    }
}

Then in the generated code, the Action is null, so Action1.Invoke(result) results in null reference exception:
public partial class TheMapper : ITheMapper
{
    private Action<To> Action1;

    public To Map(From p1)
    {
        if (p1 == null)
        {
            return null;
        }
        To result = new To();
        Action1.Invoke(result);
        return result;

    }
}

That's the main:
using Microsoft.Extensions.DependencyInjection;
using Question;

var services = new ServiceCollection();
services.AddSingleton<ITheMapper,TheMapper>();
var myMapper = services.BuildServiceProvider().GetService<ITheMapper>();
myMapper!.Map(new From() {Name = "self"});

improved description

@tariano I believe block expressions are not supported for code generation. Can you try moving your code to an external method and call that method as a inline expression instead?


Add TaskExecutionMetadata to TaskExecutionEvent

TL;DR
Add TaskExecutionMetadata to TaskExecutionEvent. At this point this only captures whether a task on a spot node or not.
Type

[ ] Bug Fix
[x] Feature
[ ] Plugin

Are all requirements met?

[x] Code completed
[ ] Smoke tested
[x] Unit tests added
[ ] Code documentation added
[ ] Any pending items have an associated Issue

Complete description
https://docs.google.com/document/d/1nqAp5-DanklNvG6OeQ3uIacZYGvf0oXioz7CboP_CsU/edit
Tracking Issue
https://github.com/lyft/flyte/issues/520
Follow-up issue
NA

Also hold, I want to understand this change. This is a great change and should be done for other TaskExecution metadata as well. can we sync?

I am talking WRT - https://github.com/lyft/flyte/issues/325

@kumare3 TaskExecutionMetadata is entirely brand new as of https://github.com/lyft/flyteidl/pull/82

Codecov Report

Merging #190 into master will increase coverage by 0.02%.
The diff coverage is 85.71%.

@kumare3 TaskExecutionMetadata is entirely brand new as of https://github.com/lyft/flyteidl/pull/82

I realize that, but I think can you think throttle listed issue as well

@kumare3 sorry I replied before I saw your link, thanks for pointing out that issue

friendly ping @EngHabu @kumare3


Update editor Window preview position when resizing window.

A small follow-up to https://github.com/godotengine/godot/pull/92506, updates preview position when window size is changed.

Thanks!


Add ability to map kwargs to hook

It would be really helpful to be able to map any number of kwargs to a hook field. For instance using this hook:
license->: tackle robcyxz/tackle-license --output {{project_slug}}

It doesn't work though naturally you would think it would since the license provider has a variable output. Since these are not positional, they should not be in the args: list = [] definition. Instead, they should map to a dict field. In the case of the tackle hook, it should be the extra_context or override field.
This should be done with #80, Removing ModelMetaclass, and changing to pyparsing for lexxing input args in evaluate_args

Added kwargs key to hooks to map unknown kwargs to a field.


GEODE-2644: Cleanup logging tests

This is only part of the work for GEODE-2644. This PR simply cleans up existing logging tests.

I've resolved conflicts with develop.

On develop, gfsh command "change loglevel --level" has these completions:
<[0. null - =ALL,
    0. null - =DEBUG,
    0. null - =ERROR,
    0. null - =FATAL,
    0. null - =INFO,
    0. null - =OFF,
    0. null - =TRACE,
    0. null - =WARN]>

While on my branch, it has these completions:
<[0. null - =ALL,
    0. null - =DEBUG,
    0. null - =DETAIL,
    0. null - =ERROR,
    0. null - =FATAL,
    0. null - =INFO,
    0. null - =NOTE,
    0. null - =OFF,
    0. null - =TRACE,
    0. null - =WARN]>


Necessary lines commented out in PyInstaller module?

Empire Version
2.2 (and current dev branch)
OS Information (Linux flavor, Python version)
Xubuntu 17.10, Python 3.6
Expected behavior and description of the error, including any actions taken immediately prior to the error. The more detail the better.
When trying to create a stager using the pyInstaller module, an error is given about installPath_Str not being defined.
Screenshot of error, embedded text output, or Pastebin link to the error
This error is given immediately after running "execute" when creating the pyInstaller stager module:
[!] Exception: global name 'installPath_Str' is not defined
Any additional information
The installPath_Str object is required for the pyInstaller script to run, but it seems like the two lines that retrieve it from the config table of the database have been commented out. This results in an error when attempting to generate a stager using the pyInstaller module.
Lines 115 and 116 in this commit: https://github.com/EmpireProject/Empire/commit/d0b2ba41b42e6139b223183e806ee2bbac465c9e

Fixed in the dev branch. https://github.com/EmpireProject/Empire/commit/9093b3df9e04dbdc15de5cc28e3efb0cdaedda1e


NPM audit finds high severity vulnerabilities

Describe the bug
NPM audit finds high severity vulnerabilities when doing npm install.
To Reproduce
Follow steps at https://quartz.jzhao.xyz/
git clone https://github.com/jackyzha0/quartz.git
cd quartz
npm i

Expected behavior
NPM does not find any high severity vulnerabilities.
Screenshots and Source
This is my console output for npm i
oliver@vmi1560528:~/vps/apps/quartz$ npm i

added 521 packages, and audited 523 packages in 22s

171 packages are looking for funding
  run `npm fund` for details

5 vulnerabilities (2 moderate, 3 high)

To address issues that do not require attention, run:
  npm audit fix

Some issues need review, and may require choosing
a different dependency.

Run `npm audit` for details.
npm notice
npm notice New minor version of npm available! 10.2.3 -> 10.9.0
npm notice Changelog: https://github.com/npm/cli/releases/tag/v10.9.0
npm notice Run npm install -g<EMAIL_ADDRESS>to update!
npm notice
oliver@vmi1560528:~/vps/apps/quartz$ npm audit fix

changed 4 packages, and audited 523 packages in 3s

171 packages are looking for funding
  run `npm fund` for details

# npm audit report

path-to-regexp  2.0.0 - 3.2.0
Severity: high
path-to-regexp outputs backtracking regular expressions - https://github.com/advisories/GHSA-9wv6-86v2-598j
No fix available
node_modules/path-to-regexp
  serve-handler  *
  Depends on vulnerable versions of path-to-regexp
  node_modules/serve-handler

2 high severity vulnerabilities

Some issues need review, and may require choosing
a different dependency.

Desktop (please complete the following information):

Quartz Version: v4.4.0
node Version: v20.10.0
npm version: v10.2.3
OS: Ubuntu

This is an upstream issue: https://github.com/vercel/serve-handler/issues/212


Everything exported as TypeObjectName

Search terms

Question
I have an object declared this way:
/**

A class for interacting with THS over WAMP. Use ThsClient.create() to create a new instance.

@public
*/
export class MyClient {
...random code
}

TypeDoc generates this header in the documentation:
ClassMyClient
It does that for everything in the project; Namespaces, enums, interfaces. All of it.
How do I get it to generate MyClient instead of ClassMyClient

There was a bug which caused kind names to be mashed up against the reflection name, #2748
You could do this by (ab)using TypeDoc's locales option option to overwrite the kind translations (these ones) with empty strings.
The right way to do this is with a custom theme which overwrites the header template to remove them, there is no option to remove the type from the header, though I guess the headings option could be extended with a flag for that...


Add Fundamentals-Income Statement

Codecov Report
Base: 77.02% // Head: 83.41% // Increases project coverage by +6.38% :tada:

Coverage data is based on head (15cd178) compared to base (877f732).
Patch coverage: 100.00% of modified lines in pull request are covered.

Additional details and impacted files
@@            Coverage Diff             @@
##           master       #5      +/-   ##
==========================================
+ Coverage   77.02%   83.41%   +6.38%
==========================================
  Files           8       10       +2
  Lines         148      205      +57
  Branches        8        8
==========================================
+ Hits          114      171      +57
  Misses         29       29
  Partials        5        5

Impacted Files
Coverage Δ

...lphaVantage.Net/Fundamentals/AlphaVantageClient.cs
100.00% <100.00%> (ø)

...Vantage.Net/Fundamentals/IncomeStatementRequest.cs
100.00% <100.00%> (ø)

...antage.Net/Fundamentals/IncomeStatementResponse.cs
100.00% <100.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

:umbrella: View full report at Codecov.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.


5565 safe load common data

Controlled exception from load common data and delete common data so can't interfere in the user creation process
Fixed a typo in a message

Please @juanignaciosl check this PR

:+1:


[Feature Request] Select Option with Html

Existing Component
Yes
Component Name
select
Description
Please can you add the ability to insert html code into select option label:
  <el-select>
    <el-option v-for="item in items"
               :key="item.key"
               :label="item.label"    <---Here if I use html into label value it will be converted into text
               :value="item.key">
    </el-option>
  </el-select>

https://element.eleme.io/#/en-US/component/select#custom-template

@Leopoldthecoder Hi and thank you so much for you reply, but I need that this html code is displayed also into "input" control when is selected.

I need that this html code is displayed also into "input" control

I'm not sure if I get this right, but input control only displays plain texts, not HTML strings.

ok...thanks


Benchmark against faster Python trk loader

At some point, should compare with @emanuele's https://github.com/emanuele/load_trk, for a comparison for a more optimized Python trk reader.

Hi @arokem , I've just updated my repository with two additional implementations that visibly speed up the loading. For now, I just named them load_trk_new.py and load_trk_numba.py. The simple test test_load_trk_numpy_save.py compares them and also reports the timing of loading the same amount of data with numpy.load(), which I consider the lower bound. The output of this test executed on my laptop (SSD) appears in the README. Let me know if I can be of help for your future comparisons!

Hi @emanuele, I noticed that the numba version is loading all the data in memory first before processing compared to the other methods that only read the requested streamlines from the file (via a sequence of file seeking + reading).

I made some improvements on parsing the streamline lengths. It is kind of exploiting how uint32 and float32 represent the numbers in binary. Here's the relevant part. I'm curious to see what you guys think, I'm probably missing some corner cases, right?

I have created an experimental JavaScript implementation that includes a benchmark against other formats. These results may be very different from Python. In particular, JavaScript does not natively support the uint64 offsets required by TRX nor the float16 used by the default converter. I realize this issue is specifically about Python, but each of you may have insights regarding the JavaScript implementation and opportunity for optimizations. One could also use the same datasets for evaluation of both the native Python and C++ implementations. The trx32 shows performance if both offsets and positions use 32-bit values (though this is not allowed with the current standard).

Pretty cool demo. It is intriguing why the trk and tck perform so much better compared to trx! Do you have an intuition why?
Also, I have a naive question. Did you compare the loaded streamlines from the different files to make sure the data was properly loaded? I don't see that in trx_bench.mjs

The TRK and TCK have no compression. The performance of both TRK and TCK are actually pretty slow, because they interleave the track length and vertex position information. They just look fast relative to compressed formats. Segmenting the offsets and the positions makes them a lot faster. The VTK requires a lot of disk space because tff_convert_tractogram uses float64 for the vertex positions.

For this experiment were the TRX compressed (deflate)? And does JavaScript supports memmap (reading a whole chunk to memory at the time) or it has to actually read the bytes into memory (sequential)?

@frheault

I have updated the benchmark to compare trk, and trk.gz with 3 levels of gzip compression (1 fastest, 6 default, 11 slowest) as well as TRX with 3 levels of zip compression (1 fastest, 4 default, 6 slowest).
. In brief, trx level 1 is slightly slower than trk.gz while trx levels 4 and 6 are particularly slow.
The compressed benchmarks are about 50% faster than before - I switched to fflate instead of Pako/JSZip. This influences both trx and trk.gz, so the overall story does not change.
For C programs, zstd offers dramatically faster decompression than gzip. Like gzip, it is a single file method, so not compatible with trx. However, I did try trk.zstd using JavaScript fzstd - I include the comparison below. zstd does allow remarkable compression, but the JavaScript decompressor is not as fast as fflate.

I think my JavaScript TRX reading implementation is complete. I was thinking of generating a pull request to this repository. Can you see any missing features? Again, this is available as a drag and drop web page viewer, which can help others support this specification.

@neurolabusc Thank you for this, I will dig into it this weekend!
I was wondering if it was possible for trx to have the ''0'' compression (Using STORED instead of DEFLATE)? In python, thanks to the zip header we don't have to unzip at all and all files are accessible directly (just like if it was a folder).
This would be closer to trk/tck without compression, like the 'base' file format rather than the choice of compression we put on top of it.

@frheault This is a good point.
My original test was with the raw output from your tff_convert_tractogram script, which does use STORED not DEFLATE. However, I only tested uncompressed TRX with pako, and did not try this later when I discovered the faster fflate. I retested with fflate, and does a great job. The residual big performance penalty to TRX is the use of float16, which is not native to JavaScript (or x86-64). The TRX32 shows the performance when uint32 is used for offsets and float32 for position. With these modifications, the size is the same as uncompressed TRK (as they are both uncompressed and have the same precision) but the speed of TRX is much faster (since the scalar, property, position and line length information are not interleaved, and can each be read with a single block read):

msec x10
mb

TRK
4060
137.4

TRX
14712
69.9

TRX32
499
137.4

I would strongly advocate for the specification to be changed to optionally allow offsets to be UINT32 (as this is the maximum allowed by most graphics languages, is sufficient for most processed datasets, and results in smaller files). Likewise, it would be great if your converter provided the option to allow the user to choose the float32 precision for positions.
As an aside, your latest modifications to tff_convert_tractogram.py lead to a segmentation fault when I try to convert any tracts, for example from here:
python ./tff_convert_tractogram.py dpsv.trx dp.trk
zsh: segmentation fault  python ./tff_convert_tractogram.py dpsv.trx dp.trk

This is a regression as an early commit (14f7cac) works fine.

That regression is a good reminder that we need tests for everything. At least smoke testing.

I did a little research, while x86-64 does not natively support float16, it includes the SSE/AVX instructions for converting half (float16) to single precision (float32) _mm_cvtph_ps/_mm256_cvtph_ps and the reverse _mm_cvtps_ph/_mm256_cvtps_ph.  Likewise, ARM has similar Neon instructions VCVT_F32_F16 and VCVT_F16_F32. This would allow low level languages like C and sophisticated libraries like Numpy to rapidly decode/encode float16s. Unfortunately, these are not available in JavaScript.


Remove Client.net

Deprecated in 0.15.0

Should be done together with #1047 (remove GatewayClient)

Should be done on #1048


fix typo in overrideScope deprecation warning

This was fixed in https://github.com/NixOS/nixpkgs/commit/fceab3ec621e13b6317af77c7177c7ebd2c1dd64


Keyvault Spring Boot Actuator support

Summary
Spring Boot Actuator support for Key Vault
Issue Type

New Feature

Starter Names

key vault spring boot starter

Additional Information

These three files got deleted accidentally:

azure-spring-boot-starters/azure-mediaservices-spring-boot-starter/README.md
azure-spring-boot-starters/azure-servicebus-spring-boot-starter/README.md
azure-spring-boot-starters/azure-storage-spring-boot-starter/README.md

I did not remove those, please coordinate this with whomever removed them.

Hi, @mnriem .
Please resolve the conflicts. 🙏

Hi, @mnriem .

I did not remove those, please coordinate this with whomever removed them.


fix: pass mode to vite build

I don't think we need to do that, you can set mode in vite.config.ts.
@antfu WDYT?

@Ti-webdev Can you provide more context about what problem you are trying to fix here?

I prepared two versions for deploy: public and debug
It allows me switch to debug version on prod.
define mode in vite.config.ts works for me:
defineConfig({
   mode: process.env.MODE || process.env.NODE_ENV || 'development',
   ...
})

Looks like this issue is resolved for you. Closing now, thanks for your contributions.


MAUI: Update authentication samples

Description

Fixed OAuth workflow on all MAUI platforms.
Updated UI and functionality for Create and save map and  Search for webmap.
Fixed functionality and updated UI for Token secured challenge.

Type of change

[x] Bug fix

Platforms tested on:

[x] WinUI
[x] Android
[x] iOS
[x] MacCatalyst

Checklist

[x] Runs and compiles on all active platforms
[ ] Legacy platforms still compile and run (if applicable)
[x] Branch is up to date with the latest main/v.next
[x] All merge conflicts have been resolved
[x] Self-review of changes
[x] There are no warnings related to changes
[x] No unrelated changes have been made to any other code or project files
[ ] sample_sync.py runs without making changes
[x] Codemaid and XAML styler extensions have been run on every changed file
[x] Code is commented with correct formatting
[x] All variable and method names are good and make sense
[x] There is no leftover commented code
[ ] Screenshots are correct size and display in description tab

The apps and code look good just a couple nitpicks:
ArcGIS token challenge
- In ArcGIS Pro, when private content is authorized for access and added to a map, the MapView will typically zoom to the extent of the layer. Might be worth considering as user friendliness and similarity to Pro spec could reasonably justify adding this.
Authenticate with OAuth
- In About under How to use the sample, "premium content" implies that there are types of contents associated with pay tiers. Maybe "private content" would be more accurate?


What is casdoor's api?

When openvpn is used to connect to casdoor for identity authentication and oauth2 protocol is used, there is a problem, what is the api interface of casdoor's user information? How to make the call so that the user information obtained from casdoor is passed to openvpn.

@lsx1205 see docs: https://casdoor.org/docs/how-to-connect/oauth/#how-to-use-accesstoken


Issues listening for file changes

Hi there,
First of all wanted to really give my thanks to you for this amazing tool! It really made my life easier using docker under macOs.
Sadly though I'm opening this issue because I am looking for a fix for the following scenario.
I am developing in Go and I'm using this https://github.com/githubnemo/CompileDaemon in order to listen to file changes and automatically rebuild my go binary.
However when I boot up dinghy and sequently my Go container every change I make in my IDE will not get picked up by the daemon. But when I don't use dinghy and just use native docker for mac without any magic the daemon works correctly.
Any idea what kind of fix I can apply to solve this annoying issue? Cuz as of now it kind of forces me to always skip on using dinghy for my Go projects.
I really appreciate any help you could provide!
Some additional info:
Dinghy Version 4.6.1
Virtualbox  Version 5.1.30 r118389 (Qt5.6.3)
Boot2Docker version 17.09.1-ce, build HEAD : e7de9ae - Fri Dec  8 19:41:36 UTC 2017
Docker version 17.09.1-ce, build 19e2cf6
Firewall deactivated
dinghy-FsEvents.output is empty
PS.
I should probably mention as well that the file actually does update correctly inside the container if I modify it in my IDE, it just doesn't trigger a rebuild event for the daemon.
Running fsevents_to_vm start ./ manually I get this output:
/Library/Ruby/Gems/2.3.0/gems/net-ssh-2.9.4/lib/net/ssh/transport/session.rb:67:in `initialize': Object#timeout is deprecated, use Timeout.timeout instead.
Error sending event: Connection refused - connect(2) for nil port 22
    /Library/Ruby/Gems/2.3.0/gems/net-ssh-2.9.4/lib/net/ssh/transport/session.rb:70:in `initialize'
    /Library/Ruby/Gems/2.3.0/gems/net-ssh-2.9.4/lib/net/ssh/transport/session.rb:70:in `open'
    /Library/Ruby/Gems/2.3.0/gems/net-ssh-2.9.4/lib/net/ssh/transport/session.rb:70:in `block in initialize'
    /System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/2.3.0/timeout.rb:74:in `timeout'
    /System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/2.3.0/timeout.rb:120:in `timeout'
    /Library/Ruby/Gems/2.3.0/gems/net-ssh-2.9.4/lib/net/ssh/transport/session.rb:67:in `initialize'
    /Library/Ruby/Gems/2.3.0/gems/net-ssh-2.9.4/lib/net/ssh.rb:207:in `new'
    /Library/Ruby/Gems/2.3.0/gems/net-ssh-2.9.4/lib/net/ssh.rb:207:in `start'
    /Library/Ruby/Gems/2.3.0/gems/fsevents_to_vm-1.1.3/lib/fsevents_to_vm/ssh_emit.rb:24:in `ssh'
    /Library/Ruby/Gems/2.3.0/gems/fsevents_to_vm-1.1.3/lib/fsevents_to_vm/ssh_emit.rb:14:in `event'
    /Library/Ruby/Gems/2.3.0/gems/fsevents_to_vm-1.1.3/lib/fsevents_to_vm/cli.rb:30:in `block in start'
    /Library/Ruby/Gems/2.3.0/gems/fsevents_to_vm-1.1.3/lib/fsevents_to_vm/watch.rb:14:in `block (2 levels) in run'
    /Library/Ruby/Gems/2.3.0/gems/fsevents_to_vm-1.1.3/lib/fsevents_to_vm/watch.rb:12:in `each'
    /Library/Ruby/Gems/2.3.0/gems/fsevents_to_vm-1.1.3/lib/fsevents_to_vm/watch.rb:12:in `block in run'
    /Library/Ruby/Gems/2.3.0/gems/rb-fsevent-0.9.8/lib/rb-fsevent/fsevent.rb:45:in `run'
    /Library/Ruby/Gems/2.3.0/gems/fsevents_to_vm-1.1.3/lib/fsevents_to_vm/watch.rb:17:in `run'
    /Library/Ruby/Gems/2.3.0/gems/fsevents_to_vm-1.1.3/lib/fsevents_to_vm/cli.rb:24:in `start'
    /Library/Ruby/Gems/2.3.0/gems/thor-0.19.4/lib/thor/command.rb:27:in `run'
    /Library/Ruby/Gems/2.3.0/gems/thor-0.19.4/lib/thor/invocation.rb:126:in `invoke_command'
    /Library/Ruby/Gems/2.3.0/gems/thor-0.19.4/lib/thor.rb:369:in `dispatch'
    /Library/Ruby/Gems/2.3.0/gems/thor-0.19.4/lib/thor/base.rb:444:in `start'
    /Library/Ruby/Gems/2.3.0/gems/fsevents_to_vm-1.1.3/exe/fsevents_to_vm:4:in `<top (required)>'
    /usr/local/bin/fsevents_to_vm:22:in `load'
    /usr/local/bin/fsevents_to_vm:22:in `<main>'

@nrko I bumped into the same issue when trying to use dinghy with go framework like buffalo. However, I workaround it by using gin reload utility. Here is the solution https://github.com/gobuffalo/buffalo/issues/620, hope that helps.

The fvevents_to_vm error is because you need to pass in more flags to get it running manually, I'll update the README for that project.
I'm not familiar with CompileDaemon but it looks like it uses inotify underneath to watch to file changes, so I'm a little surprised it doesn't "just work". Just to make sure, is the code you're editing in your HOME folder somewhere? Dinghy only syncs and watches the user's home dir.
If you install inotifywait in the same container and run inotifywait /your/code/dir, does it output an event when you modify the file? That'd at least show us whether inotify is generating the event as expected.

I confirm that the code I am editing is in my HOME folder.
I just installed inotifywait inside the container and ran the command but I am not getting anything at all while modifying the files.
Setting up watches.
Watches established.

That's all I have unfortunately.

Hm then inotify events aren't even getting triggered, this may be difficult to debug remotely. Are you able to share your docker container config, either the docker run command or the docker-compose config as applicable?
How about this minimal test from the fsevents_to_vm readme? You don't need to run fsevents_to_vm manually for this:
docker run --rm -it -v $HOME:/fstest ubuntu:trusty
# inside the container
apt-get update && apt-get install -y inotify-tools
inotifywait /fstest

Then touch $HOME/test on your host computer from another shell, and inotifywait inside the container should emit an event for that touch, it should look like /fstest/ ATTRIB test

Oh also let's make sure the daemon is still running and didn't die due to https://github.com/codekitchen/dinghy/issues/262 -- do you see a fsevents_to_vm process running on your host computer when dinghy is running?

I know it's really hard to debug like this remotely and I really appreciate the help!
So I did the fsevents_to_vm minimal test and I correctly got the output /fstest/ ATTRIB test.
Then that got me curious and I went back to my original container and again started inotifywait ./ inside of it and outside the container I simply did the same test with touch test in the directory of the project and I correctly got ./ ATTRIB test as the output in the container. But unfortunately I get no events if I just edit the files. All this time the fsevents_to_vm process was correctly running on my host computer.
My Dockerfile config is as follows:
FROM golang:alpine

ENV APP_DIR $GOPATH/src/github.com/nrko/project
ENV CT_COMMAND --version

# install go dep
RUN apk update \
    && apk add ca-certificates git \
    && go get -u github.com/golang/dep/cmd/dep

# Install dependencies
RUN apk add --update alpine-sdk \
    && rm -rf /var/cache/apk/*

# Setup file system
RUN mkdir -p ${APP_DIR} \
    && mkdir /var/log/project \
    && chmod 755 /var/log/project

COPY . ${APP_DIR}
WORKDIR ${APP_DIR}

RUN make deps
RUN make deps-dev

CMD CompileDaemon -build="make install" -command="ct ${CT_COMMAND}"

Oh OK that's good info thanks. With that extra debug info, my best guess is that this is the same issue covered in https://github.com/codekitchen/fsevents_to_vm/issues/7 , which I had honestly forgotten about until I just started looking through the project again, I wish I'd made that connection sooner.
Basically, right now fsevents_to_vm just modifies the mtime of the file in the VM, no matter what actually happened on the host, and some apps don't listen to ATTRIB inotify events, only actual write events.
I still think this is probably fixable, I just haven't had a chance to dig into it yet. It sounds like it is a fairly widespread issue though, so I'll try to schedule some time for that soon.

That's great news if it can be fixed! I really appreciate you taking the time to look into this!
Altho I'm not very familiar with the fsevents_to_vm codebase let me know if I can help somehow.


CSS

The front-end needs to have CSS to make it look more appealing and easier to use.

Completed


Compiling App against Next Major shows AL0186 error

Since two nights our Next Major pipeline shows AL0186 errors.
For a few of our pages the compiler cannot find the fields from a Table Extension.
page/AutBlanketSalesOrder.Page.al(1120,35): error AL0186: Reference '"BET AUT Trans.-/Call Order No."' in application object 'Sales Header' does not exist
page/AutomotiveSalesOrder.Page.al(1936,63): error AL0186: Reference '"BET AUT Our Item No."' in application object 'Sales Header' does not exist
page/AutomotiveSalesOrder.Page.al(1948,35): error AL0186: Reference '"BET EDI Doc. No."' in application object 'Sales Header' does not exist
page/AutomotiveSalesOrderList.Page.al(645,35): error AL0186: Reference '"BET AUT Plant"' in application object 'Sales Header' does not exist
page/AutomotiveSalesOrderList.Page.al(657,63): error AL0186: Reference '"BET AUT Our Item No."' in application object 'Sales Header' does not exist

there was no change within these objects and there are plenty of other fields in these pages from the table extension which cause no error.

I can confirm the very same like @rdebath described it for RunPageLink.

@BazookaMusic Can you please forward? There is some major issue in the latest AL Language build 13.*, it seems.

I seem to also have the same issue with a LinkFields property on an XMLport
##[error]./C:/agents/Agent1/_work/612/s/App/Self/src/XMLport/HSBCNURGCTpain00100103.XmlPort.al(163,38): error AL0186: Reference '"TVT.HSBC Snder Bank Branch No."' in application object 'Payment Export Data' does not exist

    schema
    {
        tableelement("Gen. Journal Line"; "Gen. Journal Line")
        {
            XmlName = 'Document';
            UseTemporary = true;
            tableelement(companyinformation; "Company Information")
            {
...
                    tableelement(paymentexportdata; "Payment Export Data")
                    {
                        LinkFields = "TVT.HSBC Snder Bank Branch No." = FIELD("TVT.HSBC Snder Bank Branch No."), "SEPA Instruction Priority Text" = FIELD("SEPA Instruction Priority Text"), "Transfer Date" = FIELD("Transfer Date"), "SEPA Batch Booking" = FIELD("SEPA Batch Booking"), "SEPA Charge Bearer Text" = FIELD("SEPA Charge Bearer Text");
                        LinkTable = PaymentExportDataGroup;
                        XmlName = 'CdtTrfTxInf';
                        UseTemporary = true;
...

I have the same with the SubPageLink.

The fix for this issue has been checked in to the master branch. It will be available in the bcinsider.azurecr.io/bcsandbox-master Docker image starting from platform build number 24.0.15812.0 and VS Code Extension Version 13.0.934715.
If you don’t have access to these images you need to become part of the Ready2Go program: aka.ms/readytogo
For more details on code branches and docker images please read:
https://blogs.msdn.microsoft.com/nav/2018/05/03/al-developer-previews-multiple-releases-and-github/
https://freddysblog.com/2020/06/25/working-with-artifacts/

Huh, looks like we've only been getting 'core' versions since the 28th Jan.
I can only see Version 24 localised versions for 27th Jan and before.
Oh, and your "Ready2Go" information is out of date (aka.ms/readytogo no longer exists). The sastoken provided by that program is no longer needed; you just have to add the -accept_insiderEula flag See here.
Also https://github.com/microsoft/navcontainerhelper/issues/3327 if that's a more appropriate spot.


FSDP checkpointing and auto-resume not working due to FileNotFoundError [incomplete checkpoint]

FSDP checkpointing and auto-resume not working due to FileNotFoundError [incomplete checkpoint]

When EFA hardware failure happens - or the user runs scancel during checkpointing, this issue could happen.
Consider adding some application level code to delete the most recent incomplete checkpoint before trying to resume with the last known-good checkpoint.


Compatibility with new SDK

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

It's not missing an include, it's just that it's being built for an older version of SDK that doesn't have FollowRedirectsPolicy


Container shuts down immediately

Hi.  I am not well versed with docker, so it may not be surprising that I couldn't get this to work.  I am installing it on my synology nas using the container manager.  About a year ago, I successfully installed the standard pi-hole in docker and have been using it, but I've wished for scheduled blocking and this seemed simpler than creating my own cron jobs, since I know little about that.  When I start the container, however, it shuts down immediately.  The log gives this error:  "exec /s6-init: exec format error"
The closest I've come to decoding that is that it could indicate trying to run a 64 bit program on a 32 bit machine, but that doesn't seem like it would make sense here running on my ds920+ in docker.  Any suggestions?

What's your run command

Thanks for the reply. Unfortunately I am too ignorant to know how to answer that question.  To start the container, I'm just clicking the start button in the container manager.  It doesn't tell me what command it's actually using.  I don't see that info in the logs that it generates on its own.  Can you tell me how to find out what the run command is?


auto format on save for all changed files

Current behaviour
Auto format function only formats the current buffer file even if there are multiple changed go files. It could be confusing when doing :wall.
Changed behaviour
Auto format function formats all changed files.
Known issue
neovim is having issue detecting changed buffers. The below script could fix but it's probably out this plugin's scope.
augroup checktime
    autocmd!
    if !has("gui_running")
        "silent! necessary otherwise throws errors when using command
        "line window.
        autocmd BufEnter,FocusGained,BufEnter,FocusLost,WinLeave * checktime
    endif
augroup END

LGTM! But I have one question, is there any side effect of *.go pattern? If not, is it possible that we just switch from <buffer> to *.go instead?

LGTM! But I have one question, is there any side effect of *.go pattern? If not, is it possible that we just switch from <buffer> to *.go instead?

None I can think of tbh. Happy to make it use *.go pattern for all cases

Thanks very much!


Update scalafmt-core to 2.7.4

Codecov Report

Merging #348 into master will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master     #348   +/-   ##
=======================================
  Coverage   62.84%   62.84%
=======================================
  Files          38       38
  Lines        1281     1281
  Branches        8        8
=======================================
  Hits          805      805
  Misses        476      476

Impacted Files
Coverage Δ

...e/src/main/scala/laserdisc/protocol/Protocol.scala
95.00% <ø> (ø)

core/src/main/scala/laserdisc/protocol/RESP.scala
91.33% <ø> (ø)

fs2/src/main/scala/laserdisc/fs2/MkResource.scala
0.00% <ø> (ø)

fs2/src/main/scala/laserdisc/fs2/RedisClient.scala
67.92% <ø> (ø)

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 f3eab99...46861b5. Read the comment docs.


Task build fails due to ffi changes

Description
Task build fails
task build
task: [rust:build] cargo build --message-format=short --features=ffi
task: [rust:swift-build] rustup component add rust-src 2> /dev/null
task: [rust:swift-build] rustup target add x86_64-apple-darwin 2> /dev/null
error: none of the selected packages contains these features: ffi
task: Failed to run task "rust:build": exit status 101
task: Failed to run task "rust:build": exit status 101

Steps to reproduce
task build

Additional context
No response
Hedera network
other
Version
V.0.13.0
Operating system
macOS

Hi! For now you can just cargo build, after this release that'll be fixed (specifically #491)

Hey @izik1
Thanks that worked after I manually installed protobuf and cloned the sub module(protobufs) as well.
KR
Jerome


Fix to INAV timeouts

This is a temporary fix, it appears to work, but I couldn't perform a detailed testing because I really have to run now. @mhkabir it would be appreciated if you could vet it.
I will report an issue about the divergence in time sources later, upon a bit more detailed investigation.
@davids5 FYI.

Still giving issues. Not like before, where the whole shell was filled within seconds, but :
nsh> position_estimator_inav: GPS timeout

This could be an independent issue then. I couldn't get timeouts with this fix.

Applied on master, closing.


defs-cmds: fix typo in help string

Thanks, will merge on CI pass! (note most of this code is being replaced and as part of that docs as a whole will be revisited)

Actually, we also need a CLA approval. Let me get that setup on this repo.

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

This effort no longer applies since the latest merge which rewrites most of the code


Aim not working

The aimbot isn't working on my end as well. I tried press/hold the key but nothing happens.

same issue

Fixed.

Fixed.

Thank you! Works perfect


Documentation on how to keep the user logged in

Improve documentation
Describe the problem
Currently, there's no documentation on how to keep the user logged in after the application is closed and opened again. The user have to log in again.
Describe the improvement
Improve the documentation on how to keep the user logged in. This is something that is done automatically on the js library, but not on this one.
Additional context
This will likely be used on Dart Web Apps and Flutter Apps to provide a good user experience.

I could get this working on Flutter using the shared_preferences plugin:
/// Persist the current user session. This method should be called when
/// the user log in into the app.
Future<void> _persistSession(Session session) {
  print('Persisting session string');
  return sharedPreferences.setString( //This is the shared preferences instance
    supabaseSessionKey,
    session.persistSessionString,
  );
}

/// Recover the previous user session, if any.
///
/// This method should be used on the main function, before `runApp`
Future<bool> recoverSession() async {
  // TODO: Use secure storage instead of shared preferences
  if (sharedPreferences.containsKey(supabaseSessionKey)) {
    print('Found persisted session string, attempting to recover session');
    final jsonStr = sharedPreferences.getString(supabaseSessionKey)!;
    final response = await client.auth.recoverSession(jsonStr);
    if (response.error == null) {
      print('Session successfully recovered for user ID: ${response.user!.id}');
      _persistSession(response.data!);
      return true;
    }
  }
  return false;
}

Hi @bdlukaa, thanks for your code example. To be better, you can listen to app lifecycle to support recovering session on app resumes.
You can take a look at the example here

Improve the documentation on how to keep the user logged in. This is something that is done automatically on the js library, but not on this one.

We will create a Supabase flutter library to support this feature. Stay tuned for further updates.

Since I see that the flutter package is released, I see it's implemented with SharedPreferences, but is this really secure?

I don't think so.

I don't think so. flutter_secure_storage can be used for Android, iOS and Linux.

Hi @Vinzent03 @bdlukaa, originally we choose SharedPreferences cos it's easy to use and it also supports flutter web.
Thanks for the suggestion @bdlukaa, we will look into it and update you as soon as possible.

Hi @Vinzent03 @bdlukaa, now you can use any plugin to persist user session with Custom Localstorage


What are the units?

In this file, you have documentation comments, but what are the units for values like latitude and altitude? Is it meters? Feet?
https://github.com/icapps/flutter-background-location-tracker/blob/b7b8ee1622f81dd3faa15f93964424a0900404bf/lib/src/model/background_location_update_data.dart#L6-L15

Latitude and longitude are in degrees.

The primary unit in which longitude and latitude are given is degrees (°). There are 360° of longitude (180° E ↔ 180° W) and 180° of latitude (90° N ↔ 90° S). Each degree can be broken into 60 minutes (’). Each minute can be divided into 60 seconds (”). For finer accuracy, fractions of seconds given by a decimal point are used. A base-sixty notation is called a sexagesimal notation.

We do return it as a simple double, but it's still in degrees. See astro.unl.edu
The horizontalAccuracy is in meters, as is the Altitude.


Added placeholder images of graphs with animations

Added the placeholder graph images for countries and installations graphs.
Fixed the font in the placeholder images.
Added animations for the placeholder graphs that loop.

-Polished nav bar
-added new scroll bar
-added new visualisation installations graph


Fix vnode event move

This PR adds a reapplyEvents proc (called during moveDom) that removes event handlers from the attached dom element, then reapplies them pointing to the new vnode. This is necessary because after diffing the new vnode now owns the attached dom element.
This approach feels a little costly as the handlers must be replaced on each diff. I initially tried to instead attach the vdom to the dom node so that the event wrapper could use that, and the vnode could be updated, but that did not work. What are your thoughts @Araq?
This would solve #254 and #117

Are you sure that solves all issues without introducing new ones? I remember older versions doing that and only shifting the problems around. I've since then become delusional about virtual DOMs and DOM diffing altogether, it's all just a bit abstraction inversion and will never work reliably. :-(

Are you sure that solves all issues without introducing new ones?

No, I'm not. But the tests pass and it seems to work with the manual testing I've done

I remember older versions doing that and only shifting the problems around.

Any pointers for where to look on this? I can't find anything in the git/issue history

I've since then become delusional about virtual DOMs and DOM diffing altogether, it's all just a big abstraction inversion and will never work reliably. :-(

Perhaps, but Karax is the most developed Nim webapp library so it would be nice to keep it going. Receiving vnodes in event handlers is a part of the public API, so we should either fix it or deprecate and offer only onevent(ev: Event) instead. The two ideas I had were the one in this PR, and one that attaches the vdom to the dom element. I'm happy to explore other options if anybody has alternative ideas?
I'd be curious to hear your thoughts on vdom/diffing and what you would do now instead. Signal based reactivity (and no vdom) is popular now, but maybe there's something better out there.

I'd be curious to hear your thoughts on vdom/diffing and what you would do now instead. Signal based reactivity (and no vdom) is popular now, but maybe there's something better out there.

My later attempt was "Knete", Karax's DSL for producing the real DOM. Inside event handlers you then mutate the real DOM directly. It's much more annoying to use for "todo app", but I'd probably use it over the current Karax. Best Interop with the rest of the DOM ecosystem and all of its widgets etc plus you're unlikely to run into catastrophic performance problems.
The underlying problem is that of state duplication. You have the "raw" data which is then replicated in the UI (and enriched via styling etc) which can cause all these synchronization bugs that DOM diffing wipes away. But this problem might also be solvable by an API that extracts the data again from the UI state. Also, usually you have some duplicated state inherently as during input you want to do validation before committing it.


Add autologging to most functions (commands)

http://ninthtest.info/python-autologging/intro.html#logging-and-tracing-by-hand

Doesn't support Python3.8, let's just make our own

Wait no, looks like it's just old and hasn't been updated. Let's give it a shot.

No, but I want time too. Hmm

Added


How to build with russian language

I add -V option for build:
resume.pdf: resume.md
	pandoc --standalone --template style_chmduquesne.tex \
	--latex-engine=xelatex \
	--from markdown --to context \
	-V papersize=A4 \
	-V lang=russian \
	-o resume.tex resume.md; \
	context resume.tex

But, after building I don't see russian characters in output pdf file.
How to fix this?

I don't know... is this the way to set the language in ConTeXt? (Remember we aren't using LaTeX here)


[SPARK-12734][BUILD] Fix Netty exclusion and use Maven Enforcer to prevent future bugs

Netty classes are published under multiple artifacts with different names, so our build needs to exclude the io.netty:netty and org.jboss.netty:netty versions of the Netty artifact. However, our existing exclusions were incomplete, leading to situations where duplicate Netty classes would wind up on the classpath and cause compile errors (or worse).
This patch fixes the exclusion issue by adding more exclusions and uses Maven Enforcer's banned dependencies rule to prevent these classes from accidentally being reintroduced. I also updated dev/test-dependencies.sh to run mvn validate so that the enforcer rules can run as part of pull request builds.
/cc @rxin @srowen @pwendell. I'd like to backport at least the exclusion portion of this fix to branch-1.5 in order to fix the documentation publishing job, which fails nondeterministically due to incompatible versions of Netty classes taking precedence on the compile-time classpath.

I'd like to backport the dev/test-dependencies infrastructure as far back as branch-1.5 so that we can merge a similar fix there as well. After this fix gets in, I think we should audit the build for other dependencies which should be banned via enforcer rules.

Test build #49041 has started for PR 10672 at commit 798441a.

LGTM. Other candidates for banning: the servlet API jars in all its packagings

Test build #49041 has finished for PR 10672 at commit 798441a.

This patch fails from timeout after a configured wait of `250m`.
This patch merges cleanly.
This patch adds no public classes.

Merged build finished. Test FAILed.

Test FAILed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/49041/
Test FAILed.

I've opened two pull requests to backport the dev/test-dependencies infra to branch-1.5 and 1.6, which should allow me to backport this change as well.
I agree about the servlet API JARs, that's a good case. We should also exclude the ASM classes, since pulling in old versions of ASM is a leading cause of Java 8 compatibility issues. I'll update this in a little bit in order to cover those two obvious cases. There might be a couple of other candidates that are worth banning, but I'd like to cover them in followups.

Actually, I might choose to handle those separately in a followup next week in order to have more time to think through a few additional cases, including the exclusion of certain Jetty versions. I want to get the enforcer infra and the Netty fix in first to unblock a 1.5 doc building problem.

LGTM.

Thanks for reviewing. I'm going to merge this into master and will open separate PRs to test the backports, which might possibly require a different set of exclusion rules.

I discovered that the now-removed netty.io:netty dependency places its classes under the org.jboss.netty namespace, so I guess there's not a conflict between netty.io:netty-all and netty.io:netty. As a result, I think that we may need to allow transitive dependencies on netty.io:netty but should continue to ban the org.jboss.netty:netty artifact. I'll submit a followup to handle this tomorrow.

I've opened https://github.com/apache/spark/pull/10693 to hotfix the exclusions. In the 1.5 and 1.6 backport branches, I've re-scoped the changes to only exclude org.jboss.netty:netty.


Update sbt-crossproject, ... to 0.6.1

Updates

org.portable-scala:sbt-crossproject
org.portable-scala:sbt-scalajs-crossproject

from 0.6.0 to 0.6.1.
I'll automatically update this PR to resolve conflicts as long as you don't change it yourself.
If you'd like to skip this version, you can just close this PR. If you have any feedback, just mention @scala-steward in the comments below.
Have a fantastic day writing Scala!

Ignore future updates
Add this to your .scala-steward.conf file to ignore future updates of this dependency:
updates.ignore = [{ groupId = "org.portable-scala" }]

labels: semver-patch

Codecov Report

Merging #119 into master will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master     #119   +/-   ##
=======================================
  Coverage   37.27%   37.27%
=======================================
  Files          32       32
  Lines         947      947
  Branches       10       10
=======================================
  Hits          353      353
  Misses        594      594

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 7ddf2ab...c3062a9. Read the comment docs.


Feat/2 connect virtmanager directly to qemusystem from the libvirt container

So far no luck, it has to do with polkit. Polkit gets PID of -1, which doesn't exist, so either rootless virt-manager sending wrong pid because its in the container or Polkit cannot find the virt-manager for the same reason.

After installing libvirt natively, I checked the logs for more clues of how the PID works.
My assumption was correct, though partially. While I'm not 100% sure that rootless virt-manager sends the PID, it does matter that the PID from virt-manager must exist inside the /proc of the container.
Thus, instead of fixing it in the container file, I'll fix it through podman itself. One way to fix it is to run virt-manager from another container.


Merge the new repo

Merge them

Hey @codewithpom, we are currently in the middle of a rewrite of the whole library for the 5.2 update. We'll review your PR once we are finished with the Update.

Ok

Can I even help you in this @aaryanrr

Thanks for asking. We'll let you know if there is anything needed! You can Join the discord server for discussing possible features to Contribute.

It is me Padmashree