Hook up the change image ui to our image service

Todo after approval

[ ] Unhook the temporary launch button
[x] Fix broken test
[x] Pass in image service config

For testing
Pull these in:
https://git.dev.d2l/projects/CORE/repos/le/pull-requests/5728/overview
https://git.dev.d2l/projects/CORE/repos/lp/pull-requests/3361/overview
And read about the d2l.System.Services.CourseImageCatalog.Endpoint in the Homepages docs.dev page

@ryantmer Any more things to address?

To me, looks good! :shipit:

LGTM

Gotta run ci on my bitbucket PRs before it'll let me merge them, so this'll wait till then


Secrets panel on Srcbook page improvements

Some simple improvements to secrets panel that would be nice:

Better 'empty state' experience
Support for adding new secrets inline

We will get some designs but in the meantime simple is better.

@benjreinhart  I have made some improvements could you please review? and if any modifications you want  do let me know

Sorry for the confusion here but #310 should have closed this for now.


Implemented base52 encoding of positive integers

Added a new VariableMapping that maps variable IDs (UInt32) to a base 52 representation using letters a-zA-Z. This way, the representation is a valid variable name in the lp file.  Possibly the idea can be taken even further, using more characters, since other characters are also allowed in the variable names. This would be straightforward to do, should we feel for it.

I noticed a problem with the proposed mapping. For large problems, it will generate any combination of letters, including keywords of the lp-format. I see no other way around this than to add a prefix "x" to each variable name.


Fix duplicate user entries for vpn usage

Description

Refactor on UsageManagerImpl.createVPNUserEvent. Currently, the present method creates and removes a VPN user event. So this PR abstract this method into an handle, and creates methods to create and delete VPN user events.
Additionally, the new created method prevents duplicated entries for same user, with same userId, domainId and zoneId

Types of changes

[ ] Breaking change (fix or feature that would cause existing functionality to change)
[ ] New feature (non-breaking change which adds functionality)
[X] Bug fix (non-breaking change which fixes an issue)
[X] Enhancement (improves an existing feature and functionality)
[ ] Cleanup (Code refactoring and cleanup, that may add test cases)

Screenshots (if appropriate):
How Has This Been Tested?

environment
Ubuntu 16.04
ACS <IP_ADDRESS>
Manual test
To test VPN.USER.ADD event I duplicate a entry on cloud_usage.usage_event  with:
type = 'VPN.USER.ADD'
and processed = 0
Expected: Do not create a entry on cloud_usage.usage_vpn_user
Result:
2020-04-29 21:35:02,011 DEBUG [cloud.usage.UsageManagerImpl] (Usage-Job-1:null) (logid:) We do not need to create the usage VPN user [4] assigned to account [4] because it already exists.
To test VPN.USER.REMOVE event I duplicate a entry on cloud_usage.usage_event  with:
type = 'VPN.USER.REMOVE'
and processed = 0
Expected: If we have more than one entry for this event, we will delete then all
Result:
2020-04-30 12:01:29,481 DEBUG [cloud.usage.UsageManagerImpl] (Usage-Job-1:null) (logid:) Deleting vpn user [23] assigned to account [4] domain [2] and zone [0] that was created at [Thu Apr 30 11:43:52 AMT 2020].
Result2:
2020-04-30 12:16:06,339 WARN  [cloud.usage.UsageManagerImpl] (Usage-Job-1:null) (logid:) No usage entry for vpn user [23] assigned to account [4] domain [2] and zone [0] was found.

@blueorangutan package

@GabrielBrascher a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

Packaging result: ✖centos7 ✖debian. JID-1290

@blueorangutan package

@rhtyd a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

Packaging result: ✖centos7 ✖debian. JID-1293

@blueorangutan package

@rhtyd a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

Packaging result: ✔centos7 ✖debian. JID-1305

@blueorangutan package

@rhtyd a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

Packaging result: ✔centos7 ✖debian. JID-1350

@blueorangutan package

@rhtyd a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

Packaging result: ✔centos7 ✔debian. JID-1360

@blueorangutan test

@rhtyd a Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests

@blueorangutan package

@rhtyd a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

Packaging result: ✖centos7 ✖debian. JID-1381

Hello guys, this is an interesting one.
Can I get some reviews here?

@RodrigoDLopez I'm not sure why the packaging failed, I'll kick again
@blueorangutan package

@rhtyd a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

Packaging result: ✖centos7 ✖debian. JID-1401

@blueorangutan package

@rhtyd a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

Packaging result: ✖centos7 ✔debian. JID-1402

@blueorangutan package

@rhtyd a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

Packaging result: ✔centos7 ✔debian. JID-1403

@blueorangutan test

@rhtyd a Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests

Trillian test result (tid-1755)
Environment: kvm-centos7 (x2), Advanced Networking with Mgmt server 7
Total time taken: 53467 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr4085-t1755-kvm-centos7.zip
Intermittent failure detected: /marvin/tests/smoke/test_vpc_redundant.py
Intermittent failure detected: /marvin/tests/smoke/test_vpc_vpn.py
Smoke tests completed. 83 look OK, 0 have error(s)
Only failed tests results shown below:

Test
Result
Time (s)
Test File


update to v2.1 of ci; use docker executors

PR description
update to v2.1 of ci; use docker executors
Fixed Issue(s)

update to v2.1 of ci; use docker executors

Closing. Superceeded by PR#6.

Overriden by #6


go-digest repository is moved.

github.com/docker/distribution/digest repository is moved to github.com/opencontainers/go-digest/blob/master/digest.go.

duplicated issue.. closed TT


hassgraph: add option to show/hide historical values

Adds the options for apps/hassgraph/hass_graph.star to hide the historical values on the right

I have read the CLA Document and I hereby sign the CLA

recheck

@vincentezw PTAL

@vincentezw PTAL

thanks for the heads up.
Looks great, thanks for adding this @jgog, probably should have been an option from the start 😄


Source code?

I can see binary file downloads, but no source code. Since this project is licensed under the Apache license, it'd be nice to see the source.
I recommend uploading binary releases to the releases section of the project, rather than to the Git repo.

I recommend uploading binary releases to the releases section of the project, rather than to the Git repo.

@rouben I already uploading binary releases to the releases section.

I can see binary file downloads, but no source code. Since this project is licensed under the Apache license, it'd be nice to see the source.

Thanks, but I don't want to share source code at least for now, because:

I don't want to,
In zdownloader I am currently using my libraries that have additional functionalities not used in the program. So when I isolate source code needed only by zdownloader then I will think about sharing the source code.

Thanks for the explanation. I hope to see the source soon! I think the Apache license doesn't require you to release the source code unlike the GPL, but it would certainly make things easier for contributions, which are basically impossible at the moment. I'm also a bit hesitant to try this software out, since it's a black box, and I really don't want to run it unattended on my Linux box.


nixos\babeld: add type extraConfig

Motivation for this change
#76184
Things done

[ ] Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
Built on platform(s)

[ ] NixOS
[ ] macOS
[ ] other Linux distributions

[ ] Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
[ ] Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
[ ] Tested execution of all binary files (usually in ./result/bin/)
[ ] Determined the impact on package closure size (by running nix path-info -S before and after)
[ ] Ensured that relevant documentation is up to date
[ ] Fits CONTRIBUTING.md.

nixos\babeld that looks really windows'ish. The correct format is nixos/babeld

nixos\babeld that looks really windows'ish. The correct format is nixos/babeld

writing commit message while in a conference..

writing commit message while in a conference..


test: test claim when guaranteed destination is missing from target outcome

note that this is an important case, as it arises in the virtual funding protocol!
Description
Title Clear, single line description of the pull request, written as though it was an order.
Then, following a single blank line, a summary of the change and which issue is fixed, including

[ ] what is the problem being solved
[ ] why this is a good approach
[ ] what are the shortcomings of this approach, if any

It may include

[ ] background information, such as "Fixes #"
[ ] benchmark results
[ ] links to design documents
[ ] dependencies required for this change

The summary may omit some of these details if this PR fixes a single ticket that includes these details. It is the reviewer's discretion.
Changes [Optional]
Multiple changes are not recommended, so this section should normally be omitted. Unfortunately, they are sometimes unavoidable. If there are multiple logical changes, list them separately.

'foo' is replaced by 'bar'
'fizzbuzz' is optimized for gas

How Has This Been Tested? [Optional]
Did you need to run manual tests to verify this change? If so, please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration
:warning: Does this require multiple approvals? [Optional]
Please explain which reason, if any, why this requires more than one approval.

[ ] Is it security related?
[ ] Is it a significant process change?
[ ] Is it a significant change to architectural, design?

Checklist:
Code quality

[ ] I have written clear commit messages
[ ] I have performed a self-review of my own code
[ ] This change does not have an unduly wide scope
[ ] I have separated logic changes from refactor changes (formatting, renames, etc.)
[ ] I have commented my code wherever necessary (can be 0)
[ ] I have added tests that prove my fix is effective or that my feature works, if necessary

Project management

[ ] I have applied the appropriate labels
[ ] I have linked to all relevant issues (can be 0)
[ ] I have linked to all dependent issues (can be 0)
[ ] I have assigned myself to this PR
[ ] I have chosen the appropriate pipeline on zenhub for the linked issue

@andrewgordstewart if it's ok with you I will close this so I can put #3747 straight into master.


Optimization schemas renamed to Dynamic schemas

Renamed optimization schemas to dynamic schemas.
Changed multiple names in summarize_opt_run() in src/quacc/schemas/ase.py.

@exenGT: Thanks again for your comment on this. I'm going to close this PR for now because it is a breaking change for users with the only gain being a clearer function name.
For now, I will simply update the docstring to emphasize that it supports the dynamics class.


Assembly Load(byte[]) with native compiled exe/dll

I am really excited and fascinated by CoreRT!
Porting one of my existing projects I struggle with this code:
var bytes = File.ReadAllBytes(@"C:\corert\native_helper.dll");
Console.WriteLine($"bytes: {bytes.Length}");
var assembly = Assembly.Load(bytes);

My main program/exe (c# compiled to native code) wants to load my library "native_helper.dll" bytes (also c# compiled to native code). It throws this error:

bytes: 3379120
"Unhandled Exception: System.PlatformNotSupportedException: Operation is not supported on this platform."

In System.Private.CoreLib.dll it checks for "AppDomain.CheckLoadByteArraySupported();" and I guess that's where it crashes.
I searched through the samples and tried serveral options in .csproj. I ended up with those:
<OutputType>Library</OutputType>
<NativeLib>Shared</NativeLib>

How can I load assembly bytes into my program like in .NET Framework (code above)? Is this even possible after compiling it into native code? Thanks guys!

This is not possible in CoreRT. Take a look at the discussion in https://github.com/dotnet/corert/issues/6949 about the different options.
Duplicate of #6949

@jkotas: I saw #6949 but it doesn't address loading an assembly by bytes, does it? How would I accomplish it with CoreRT?

It does not matter whether the assembly is bytes in memory or file on disk. The solution is same for both.

@jkotas, @MichalStrehovsky
Sorry I still don't get it. Aren't those solutions adressing loading a .NET Core managed library that hasn't been compiled to native code with CoreRT?
English isn't my first language so apologies for that, I try to rephrase my goal:
What I want to do is use Assembly.Load(byte[]) and load a CoreRT native compiled library.

@MichalStrehovsky  Thanks for clearing that up. Could you please give an example on how to execute a native assembly loaded from bytes? I appreciate it.

Could you please give an example on how to execute a native assembly loaded from bytes? I appreciate it.

It's not possible on Windows; you have to write the buffer to a file on disk and load from there. I don't know about Linux/macOS.

@MichalStrehovsky, @jkotas : So there is no equivalent to MemoryModule (1000+ stars https://github.com/fancycode/MemoryModule) in CoreRT? Maybe we see it in future?

You can build MemoryModule as a library and p/invoke into it from C#.
We are not planning to add similar functionality to CoreRT proper. Bypassing the operating system's module loader means that the operating system is not aware of the module. Lots of things will work, but there will be things that don't work as expected. We don't want to take on that support burden.

@MichalStrehovsky: Fair enough. So after all there is no way to load a native assembly from bytes in .NET Core. Thanks and have a great day!


Generic inference fails when parameter is supertype of union

TypeScript Version:  3.0.1

Search Terms: nested supertype union generic inference
Code
enum Types {
    Loading = 'Loading',
    Failure = 'Failure',
    Success = 'Success',
}

type Loading = { type: Types.Loading };

type Failure<E> = {
    type: Types.Failure;
    value: E;
};

type Success<A> = {
    type: Types.Success;
    value: A;
};

type Loaded<E, A> = Failure<E> | Success<A>;
type RemoteData<E, A> = Loading | Loaded<E, A>;

type MyResponse = { foo: number };
type MyFailure = string;
declare const loaded: Loaded<MyFailure, MyResponse>;
declare const remoteData: RemoteData<MyFailure, MyResponse>;

declare const checkIsSuccess: <E, A>(remoteData: RemoteData<E, A>) => boolean;

checkIsSuccess(remoteData);
checkIsSuccess(remoteData);

// Inferred generics are `string, string`, expected `string, MyResponse`
// Type 'MyResponse' is not assignable to type 'string'.
checkIsSuccess(loaded);
// Workaround: specify generics explicitly
checkIsSuccess<MyFailure, MyResponse>(loaded);

Expected behavior:
Actual behavior:
Playground Link: https://www.typescriptlang.org/play/index.html#src=enum Types {
    Loading %3D 'Loading'%2C
    Failure %3D 'Failure'%2C
    Success %3D 'Success'%2C
}

type Loading %3D { type%3A Types.Loading }%3B

type Failure<E> %3D {
    type%3A Types.Failure%3B
    value%3A E%3B
}%3B

type Success<A> %3D {
    type%3A Types.Success%3B
    value%3A A%3B
}%3B

type Loaded<E%2C A> %3D Failure<E> | Success<A>%3B
type RemoteData<E%2C A> %3D Loading | Loaded<E%2C A>%3B

type MyResponse %3D { foo%3A number }%3B
type MyFailure %3D string%3B
declare const loaded%3A Loaded<MyFailure%2C MyResponse>%3B
declare const remoteData%3A RemoteData<MyFailure%2C MyResponse>%3B

declare const checkIsSuccess%3A <E%2C A>(remoteData%3A RemoteData<E%2C A>) %3D> boolean%3B

checkIsSuccess(remoteData)%3B
checkIsSuccess(remoteData)%3B

%2F%2F Inferred generics are `string%2C string`%2C expected `string%2C MyResponse`
%2F%2F Type 'MyResponse' is not assignable to type 'string'.
checkIsSuccess(loaded)%3B
%2F%2F Workaround%3A specify generics explicitly
checkIsSuccess<MyFailure%2C MyResponse>(loaded)%3B

Related Issues:

Alias-expanding and culling the example for clarity:
type Failure<E> = {
    type: "fail";
    value: E;
};

type Success<A> = {
    type: "pass";
    value: A;
};

declare const loaded: Failure<string> | Success<{ foo: number }>;
declare const checkIsSuccess: <E, A>(remoteData: Failure<E> | Success<A>) => boolean;

checkIsSuccess(loaded);

And here's the version that works:
type Failure<E> = {
    type: "fail";
    errorMessage: E; // 🌟
};

type Success<A> = {
    type: "pass";
    value: A;
};

declare const loaded: Failure<string> | Success<{ foo: number }>;
declare const checkIsSuccess: <E, A>(remoteData: Failure<E> | Success<A>) => boolean;

checkIsSuccess(loaded);

I think the root cause here is that we're collecting inference candidates even when a discriminating property from the containing type tells us it can't happen.

This works as expected in all available TS versions in the playground, the issue can be closed


SMP Packet re-assembly at BT transport level

The intention of this PR is to add packet re-assembly to SMP.
The PR consists of two commits:

adding generic SMP packet re-assembly;
adding modification of BT transport that allows to use re-assembly, if requested via Kconfig option.

TODO:

[x] unit tests of smp_pkasm
[x] testing

@philips77 this should ultimately implement https://github.com/apache/mynewt-mcumgr/issues/6

@joerchan

Should check if this is called when bonded peers are disconnected. I think it is, but not 100% sure.

It is but you may verify my. It is also called when you interrupt transmission by, for example, powering down TX device in the middle of transmission.

@de-nordic, could you address my previous comment: https://github.com/zephyrproject-rtos/zephyr/pull/41306#discussion_r773655773?

@de-nordic, could you address my previous comment: #41306 (comment)?

The link does not seem to point to any comment.

@de-nordic, it's the hidden one. Please expand my review comments so that you can see all of them. Then, the GH should be able to focus on this comment when you click the link.

@de-nordic, it's the hidden one. Please expand my review comments so that you can see all of them. Then, the GH should be able to focus on this comment when you click the link.

Stupid GH failed to show it. Got screen shot from Filip and fixed it.

@cvinayak @joerchan @kapi-no @philips77 @nvlsianpu I need to call you back to the review because I have quite modified smp_bt_chr_write , after @cvinayak has reviewed the code and pointed out possible improvements; the changes are:

the error processing is done first and function returns immediately from error paths with BT_GATT_ERR type value;
check for positive ret has been as code for ret >= 0 has been moved after error processing, so it is no longer needed;
final return value, for positive outcome, is reduced to len.

@de-nordic I've added @alwa-nordic as a reviewer, since he has taken over for me.


Static content in cell and headers

Hello,
I've two questions:

Is it possible to add static content for each cell of the kanban board? Otherwise is there a way to cycle all cells?
When the kanban board scrolls, is it possible to keep the headers fixed at the top?

Thanks,
Regards

Hi,

you can use the KanbanPlainCard. This card has no content by default. You can design your own card with this one. You can find a sample here: https://github.com/KhaosCoders/wpf-kanban/blob/master/Samples/WpfApp1/KanbanPlainCardWindow.xaml
this is a good point. I'm afraid it is not possible right now. But I will consider it next time I work on this side project

You can find fixed column headers in the latest version: (2.0.0)[https://www.nuget.org/packages/WPF-Kanban/2.0.0]
Have fun =)


Increased TextAppearanceSelector spacing and restyled its sliders (created Slider.svelte).

Implemented a slider component for type=range input elements (Slider.svelte) and used it in the TextAppearanceSelector.
Wrapped the contents of TextAppearanceSelector in a grid div to increase vertical spacing.

When I first click on the Text Appearance button, it looks like the first slider has focus?

I created issue #299 to track the first control having focus.
I fixed a few things during review:

change barColor and progressColor to reactive statements
fix text color when dark theme
make icons larger now that there is more space


Options on relationships (includes, data)

Hi, thanks for your work on this, it's been useful.
I have two questions about the options of how relationships are rendered:

currently, it seems that returning [ relationship: RelationshipType ] from relationships will automatically include the resource in the response, which is not ideal.  This seems to be coming from here: https://github.com/jeregrine/jsonapi/blob/master/lib/jsonapi/serializer.ex#L68.

one of the problems I've encountered already is with has_many relationships with large numbers of relations.  even including the resource identifiers (type, id) for many relations can bloat pretty quickly to the point that you might be looking for pagination of the data portion of the relationship:

"relationships": {
      "comments": {
        "links": {
          "self": "http://example.com/articles/1/relationships/comments",
          "related": "http://example.com/articles/1/comments"
        },
        "data": [
          { "type": "comments", "id": "5" },
          { "type": "comments", "id": "12" },
          //and many many more...
        ]
      }
    }

so it would be nice to have an option to not include the data, which is legit JSONAPI as far as I understand (http://jsonapi.org/format/#document-resource-object-relationships).
"relationships": {
      "comments": {
        "links": {
          "self": "http://example.com/articles/1/relationships/comments",
          "related": "http://example.com/articles/1/comments"
        },
      }
    }

I'm happy to put some work into this, but I'm still learning Elixir so I'll be a bit slow and possibly not writing idiomatic code.

@pschuegr So if you don't pre-load those relationships it won't render.
That said this is a common source of error and trouble and I'd be happy to accept any work to improve it. Thanks!


Abstract classes injection

I'm trying to use Room and Toothpick together. Because Room only has an abstract class accessible, I wrote a provider for it, but for some reason toothpick doesn't create a factory, I get the following error:
toothpick.registries.NoFactoryFoundException: No factory could be found for class <package>.AppDatabase. Check that the class has either a @Inject annotated constructor or contains @Inject annotated members. If using Registries, check that they are properly setup with annotation processor arguments.
Annotating members inside abstract AppDatabase didn't lead to anything, constructor can't be annotated, and this is probably wrong anyway. I tried with reflection enabled and disabled, didn't help either
@Singleton @ProvidesSingletonInScope
class DataBaseProvider: Provider<AppDatabase> {
    @Inject lateinit var context: Context
    override fun get(): AppDatabase =
            Room.databaseBuilder(context.applicationContext,
                    AppDatabase::class.java, "database").build()

}

@Database(entities = arrayOf(Habbit::class, Category::class), version = 1)
abstract class AppDatabase : RoomDatabase() {
    abstract fun habbitDao(): IHabbitDao
    abstract fun categoryDao(): ICategoryDao
}

bind(AppDatabase::class.java).toProvider(DataBaseProvider::class.java)

@DomiBlaze I am using room with toothpick successfully in to projects, without any issues.
Can you try injecting the Application to the provider's constructor? And then use the application as a context to create the Room instance?
class DataBaseProvider
@Inject
constructor(private val application: Application): Provider<AppDatabase> {
}

@DomiBlaze https://github.com/DomiBlaze it should work. My guess is that
when you inject it, your context is not what you expect.
If you bind your AppDatabase in a module installed into the application
scope, make sure the scope you use for injection is the scope of your
application.
We will need to see the full stack trace to investigate further.
2018-04-20 0:04 GMT-07:00 Konstantinos Paparas<EMAIL_ADDRESS>
@DomiBlaze https://github.com/DomiBlaze I am using room with toothpick
successfully in to projects, without any issues.
Can you try injecting the Application to the provider's constructor?
And then use the application as a context to create the Room instance?
class DataBaseProvider
@Inject constructor(private val application: Application): Provider {
}
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/stephanenicolas/toothpick/issues/289#issuecomment-383001604,
or mute the thread
https://github.com/notifications/unsubscribe-auth/ABv33XgLV33iDtRbuQ6ewHBLDtCrxnujks5tqYiFgaJpZM4Tb6Yw
.

@stephanenicolas
Yep, I used the wrong scope for injection, rookie mistake. Maybe it could be added to the error message? Something like Check that injected scope is supposed to contain requested factory.
Thanks!

Feel free to create a PR to enhance the appropriate error message.


Implement the bindless pattern for the geometry.

To prepare the move of the graphics engine into it's own crate, I started to convert the geometry rendering to the bindless parttern. This greatly reduces the time to record the render pass data. We use the fact, that the lifetime of all geometry is bound to the lifetime of a map. We collect all textures and vertex data into one binding array / buffer, and can then draw all geometry of a map in one draw call. On the CPU side this reduced the time to render to around 1/4 and drawcall greatly on my system. The GPU render times only got slightly better (it seems for my 4080 the scene is "too simple" and we are bottlenecked by log occupancy).
I removed the caching for maps and models, since it interfered with the assembly process (I also think the caching for those two resources is not very usefull, since loading is very snappy already and caching would result in memory bloat).
I removed the picker geometry renderer, since it was unused anyhow. I added a tile renderer for the debugging of tiles, since I couldn't re-use the geometry renderer for it anymore.
I removed the debug marker for two function, so that the compiler can better optimize the tight loop for the writing of geometry instructions.

I will resolve the merge conflicts.

I rebased it and the branch is feature complete now. But I see some stalls in the pointer shadow renderer which I want to investigate in the comming week.

Just want to add that we see these spiked on both the main branch and this branch. So the review could start non the less.

Okay, fixed all problem:

Bindless on DX12 works (workaround applies until WGPU fixed the bug)
Point shadow renders correctly using bindless.

The performance is not as good as I expected and we seem to have a lot of spices. I think this is a result of the way we currently do multi-threading. A test running all render branches on the main thread resultet in better performance.

Rebased the branch again against main.

I'm currently reworking all renderer to use the bindless approach and seperate "what" to paint and "how" to paint. I will keep open this PR for reference, but won't rebase it. The next PR, which I hope to finish this weekend will replace this PR instead.


Proposal: Only show current context

It would be nice (when writing tools around kubectx) to only show the current context, maybe something like
$ kubectx --current

Which would only output your current context, not all contexts and highlighting the current one.

kubectx with no args already shows the current context

No, it highlights the current context. It's incredibly difficult to detect which line is highlighted programatically. Give it a shot.

@ahmetb

kubectx with no args already shows the current context

No, it highlights the current context. It's incredibly difficult to detect which line is highlighted programatically. Give it a shot.

@joelmellon kubectx is not meant for programatical invocation. Use kubectl for that please. Also we have "kubectx -c" now.


release-plz update and release-plz release-pr ignores yanked versions

https://github.com/MarcoIeni/release-plz/issues/507#issuecomment-1422187766

blocked by https://github.com/rust-lang/cargo/issues/11693

Maybe reading the cargo audit codebase might help

Also, maybe calling the registry api directly might help
https://doc.rust-lang.org/nightly/cargo/reference/registry-index.html


CS50 vs code has not been opening

My CS50 code space I've just been loading for days now. It's not been coming up
Version: 1.74.0
Commit: 5235c6bb189b60b01b1f49062f4ffa42384f8c91
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/<IP_ADDRESS> Safari/537.36
Embedder: codespaces

You need to file this issue against the provider of the CS50 code spaces.


react 15.5 compatibility

commit 832d81278b10ec88e0aecc32b4811aa42fe035cc included compatibility for react 15.5. Are there any plans to create a release from after this commit and publish to npm?

As I already told in #72 (comment), I'm currently talking to @alexcurtis about what he wants to do with the repo, ...
Hope to push this repo asap to npm, but don't have any ETA at the moment 😕

v2.0.0is released as of now! 🙂


[Possible Bug] 401 Unauthorized registered as 200 OK (?)

Either your script is registering 401 Unauthorized as 200 OK, or I'm losing my marbles...
Response headers from my server: (yes, this is a public API)
HTTP/1.1 401 Unauthorized

Date                         : Tue, 30 May 2017 19:16:00 GMT
Server                       : Apache/2.4.25 OpenSSL/1.0.1e-fips mod_bwlimited/1.4
X-Powered-By                 : PHP/7.1.5
Access-Control-Allow-Methods : GET
Access-Control-Allow-Origin  : *
Vary                         : Accept-Encoding,User-Agent
Content-Encoding             : gzip
X-UA-Compatible              : IE=edge
Strict-Transport-Security    : max-age=16070400; includeSubDomains
X-Content-Type-Options       : nosniff
Content-Length               : 1226
Keep-Alive                   : timeout=5, max=100
Connection                   : Keep-Alive
Content-Type                 : text/html; charset=UTF-8

(relevant) Result from your script:
 [*] Checking to see if the server responds with 404... 200 OK
 [*] The server responds with 200 OK. Be prepared for tons of false-positives!

What might be causing this? I'd be happy to fix an issue on my end!

@michenriksen This issue has probably gone stale. Can you look into this or close the issue as NR?


Live layout options does not seem effective on dev branch

Checklist:

[x] I updated to the latest version available
[x] I cleared the cache of my browser

Release with the issue:
dev branch.
Last working release (if known):
Stable release is fine.
Browser and Operating System:

Chrome 121
Description of problem:

None of the live layout options seems to be doing anything:
https://github.com/dermotduffy/frigate-hass-card/assets/29582865/770dddd3-c7ea-4f49-b168-272329d05b0a
Frigate card diagnostic information

{
  "card_version": "5.2.0",
  "browser": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/<IP_ADDRESS> Safari/537.36",
  "date": "2024-02-13T16:38:03.386Z",
  "frigate_versions": {
    "624fd5a51dc304193d7e34ab79e1dae3": "5.0.1/0.13.1-34fb1c2"
  },
  "lang": "en",
  "timezone": "America/Sao_Paulo",
  "git": {
    "build_version": "5.2.0-dev+gee2bb25",
    "build_date": "Sun, 04 Feb 2024 14:26:01 GMT",
    "commit_date": "Sat, 3 Feb 2024 16:41:07 -0800"
  },
  "ha_version": "2024.2.1",
  "config": {
    "type": "custom:frigate-card",
    "automations": [
      {
        "conditions": {
          "fullscreen": false
        },
        "actions": [
          {
            "action": "custom:frigate-card-action",
            "frigate_card_action": "live_substream_off"
          }
        ]
      },
      {
        "conditions": {
          "fullscreen": true,
          "media_query": "(min-width: 1500px)"
        },
        "actions": [
          {
            "action": "custom:frigate-card-action",
            "frigate_card_action": "live_substream_on"
          }
        ]
      }
    ],
    "overrides": [
      {
        "conditions": {
          "fullscreen": true
        },
        "overrides": {
          "menu": {
            "style": "overlay",
            "buttons": {
              "substreams": {
                "enabled": true
              }
            }
          },
          "live": {
            "layout": {
              "fit": "contain",
              "position": {
                "x": 50,
                "y": 50
              }
            }
          }
        }
      }
    ],
    "cameras_global": {
      "live_provider": "go2rtc",
      "go2rtc": {
        "modes": [
          "webrtc"
        ]
      },
      "image": {
        "refresh_seconds": 1
      }
    },
    "menu": {
      "buttons": {
        "frigate": {
          "enabled": true
        },
        "snapshots": {
          "enabled": false
        },
        "image": {
          "enabled": false
        },
        "cameras": {
          "alignment": "opposing"
        },
        "timeline": {
          "enabled": false
        },
        "media_player": {
          "enabled": true
        },
        "live": {
          "enabled": true
        },
        "clips": {
          "enabled": true
        },
        "substreams": {
          "enabled": false,
          "priority": 51,
          "icon": "mdi:high-definition",
          "alignment": "opposing"
        },
        "mute": {
          "enabled": true
        },
        "display_mode": {
          "enabled": false
        }
      },
      "style": "outside",
      "position": "top"
    },
    "cameras": [
      {
        "camera_entity": "camera.portao_do_terreiro",
        "webrtc_card": {
          "url": "portao_do_terreiro"
        },
        "go2rtc": {}
      },
      {
        "camera_entity": "camera.video_porteiro_do_terreiro",
        "webrtc_card": {
          "url": "video_porteiro_do_terreiro"
        }
      },
      {
        "camera_entity": "camera.terreiro",
        "webrtc_card": {
          "url": "terreiro"
        },
        "dependencies": {
          "cameras": [
            "terreiro_hd"
          ]
        }
      },
      {
        "camera_entity": "camera.terreiro",
        "title": "Terreiro (HD)",
        "id": "terreiro_hd",
        "webrtc_card": {
          "url": "terreiro_hd"
        },
        "hide": true,
        "go2rtc": {
          "stream": "terreiro_hd"
        }
      }
    ],
    "live": {
      "controls": {
        "next_previous": {
          "style": "none"
        },
        "title": {
          "mode": "none"
        },
        "thumbnails": {
          "mode": "none"
        },
        "builtin": false
      },
      "layout": {
        "fit": "cover",
        "position": {
          "x": 0,
          "y": 0
        }
      },
      "show_image_during_load": true,
      "lazy_unload": [
        "unselected",
        "hidden"
      ]
    },
    "image": {
      "mode": "camera"
    },
    "dimensions": {
      "aspect_ratio": "16:9"
    },
    "performance": {
      "profile": "low"
    },
    "media_viewer": {
      "auto_unmute": [
        "selected",
        "visible"
      ]
    },
    "elements": [
      {
        "type": "custom:frigate-card-conditional",
        "conditions": {
          "view": [
            "live"
          ],
          "camera": [
            "camera.terreiro"
          ],
          "media_loaded": true
        },
        "elements": [
          {
            "type": "custom:frigate-card-menu-submenu-select",
            "entity": "select.camera_do_terreiro_visao_noturna",
            "alignment": "opposing",
            "priority": 52,
            "options": {
              "0": {
                "icon": "mdi:theme-light-dark"
              },
              "1": {
                "icon": "mdi:weather-sunny"
              },
              "2": {
                "icon": "mdi:weather-night"
              }
            }
          }
        ]
      }
    ]
  }
}

Javascript errors shown in the web inspector (if applicable):
None.
Additional information:

Thank you very much for testing the dev branch! Will investigate.

@felipecrs There's definitely work to be done here. As you probably noticed, the card on the dev branch supports a grid of cameras. As such, I'm not sure it makes sense for media layout options to be associated with live and media_viewer, rather than with the camera itself -- since it is reasonable to want to adjust the dimensions and media layout for 1 camera, but not another.
Proposal:

Add dimensions and layout under the camera config, which would control the dimensions/layout when anything for that camera is displayed (e.g. live or media). This would allow different cameras in the grid to have different dimensions/layouts (e.g. different aspect ratios).
Keep dimensions at the top level also, since there are views that are not camera specific that still need dimensions (e.g. gallery views, image views, timeline view).
Remove support for layout options under both live and media_viewer (since the layout options for the camera will be used as per 1 above).

I think the only negative effect of the above is in the case where someone wanted different media layouts options, for the same camera, between live and media viewer. But I can't think of a realistic case where this would be wanted...
Opinions? Am I missing anything?

This is interesting.
I was not expecting to have the live layout configuration to apply to the cameras when they are in grid view mode. In grid view mode, I would expect the cameras to still follow their own aspect ratios and let the grid view arrange them the way it can.
Instead, I was only expecting that when the live view is opened (be it a single camera stream or the multi-camera grid), the live layout settings to be applied.
That said: I understand the need of different live layout settings per camera, but so far, the previous option (global live layout setting) was working very well for me. That's because I have some cameras in 16:9 native for which the layout settings won't make any difference anyway, while for the others it would make a difference.
Finally, even applying the global live layout settings for cameras when in a grid view seems good. Maybe it can even be done by default and no need for a toggle to change this behavior.
So, unless I'm missing some point too, my opinion/suggestion is to keep the global live layout setting, apply it to everywhere: single camera view, grid view card boundaries, camera within the grid view.

But I would also be ok with your proposal as well. I could still have it set globally through cameras_global anyway.
I just think it may be too much work for you. :)

Finally, even applying the global live layout settings for cameras when in a grid view seems good. Maybe it can even be done by default and no need for a toggle to change this behavior.

I don't think this would work as people expect. The live layout options apply on an individual video or image object directly (it's this CSS property). Since the card dimensions are by default "adjust the card to match the contents of the card", the live layout options never have the appearance of having any effect unless also paired with a dimensions setting to constrain the card (like you did in your config). But in grid mode, this dimension constraint cannot be introduced without allowing scrolling -- since the grid library does not appear to support any height constraints.
Scenario: If my global live layout option is letterbox, and I put the card in grid mode, nothing will actually be letter-boxed, since the dynamic grid height cannot actually be constrained like this. Instead, the grid will be unletterboxed and will just scroll within the 16:9 dimensions of the card -- giving the appearance that the layout options were entirely ignored.
From a principle of least surprise, if each camera had its own dimensions, I think this would be a lot clearer.

Makes sense. 😊


Synchronize the modification of the WiFi problems in QEMU.

Summary
Fixed several discovered issues when using the QEMU WiFi feature, which now requires syncing to the community.
Impact
Fixed the several issues with the QEMU WiFi function.
Testing
All modifications have been verified locally.

@liqinhuixm please fix the conflict

@xiaoxiang781216 Done.


Small details to integrate to HASS energy board

Hi,
One can find info needed to integrate sensors to energy dashboard:
https://developers.home-assistant.io/docs/core/entity/sensor/#long-term-statistics
It is just some additional plugin values passed so that the statistics engine detects sensor type.
Hope it helps! When I have time I can type those in too into code....

Hi and thanks for the tip!
I didn't know it would be that simple. I shall try it out and hopefully include it in the next release 👍

Here have a look:
https://privateer925-my.sharepoint.com/:i:/g/personal/samihulkko_quantum-black-hole_com/EasnxLkiwk5Am4k2bwpts08B69tk-ZRS3PvlISqYdUaHgA?e=JWajWO
SH

Energy dashboard is supported in the latest version


chore(ci): fix build on PR

@chrisns I think the problem is node i386 is't supporting erbium anymore: https://hub.docker.com/r/i386/node/
Try to update to dubmnium

Ok just saw your comment to #774 I will close this in favor of yours


Easy way to log request and response bodies

Is your feature request related to a problem? Please describe.
I am trying to build a logging mechanism in my app which logs every request and response. There are many tutorials on how to do this. I think the most popular is:
https://exceptionnotfound.net/using-middleware-to-log-requests-and-responses-in-asp-net-core/
Unfortunately, I think that logging request and response bodies is too complicated because both request body and response body are Streams instead of strings. Just look at this code in this article. To achieve just simple logging we have to write a lot of difficult code. This also causes other problems which are related to Streams, i.e. Large Object Heap.
Many of these problems are described below this article in comments.
Describe the solution you'd like
I'd like to have an easy way to log request and response bodies in ASP.NET Core.
Solutions:

Request and response bodies should be strings instead of streams (don't know if this is possible)
Give a user some method to get request and response body as a string.

Additional context
Almost every app needs some way to log events happening in it. Middleware in ASP.NET Core seems the best place to include logging. Unfortunately, there is no official or approved solution on how to perform logging request and responses in ASP.NET Core.

Dupe of https://github.com/aspnet/AspNetCore/issues/3700


Add umpire pools to face geometric factor memory

I'm not 100% sure if I did this right, @tomstitt , @v-dobrev could I trouble you for a review?

PR
Author
Editor
Reviewers
Assignment
Approval
Merge

#2934
@artv3
@v-dobrev
@v-dobrev + @camierjs
3/28/22
⌛due 4/11/22
⌛due 4/18/22

PR Checklist

[ ] Code builds.
[ ] Code passes make style.
[ ] Update CHANGELOG:

[ ] Is this a new feature users need to be aware of? New or updated example or miniapp?
[ ] Does it make sense to create a new section in the CHANGELOG to group with other related features?

[ ] Update INSTALL:

[ ] Had a new optional library been added? If so, what range of versions of this library are required? (Make sure the external library is compatible with our BSD license, e.g. it is not licensed under GPL!)
[ ] Have the version ranges for any required or optional libraries changed?
[ ] Does make or cmake have a new target?
[ ] Did the requirements or the installation process change? (rare)

[ ] Update continuous integration server configurations if necessary (e.g. with new version requirements for each of MFEM's dependencies)

[ ] .github
[ ] .appveyor.yml

[ ] Update .gitignore:

[ ] Check if make distclean; git status shows any files that were generated from the source by the project (not an IDE) but we don't want to track in the repository.
[ ] Add new patterns (just for the new files above) and re-run the above test.

[ ] New examples:

[ ] All sample runs at the top of the example source file work.
[ ] Update examples/makefile:

[ ] Add the example code to the appropriate SEQ_EXAMPLES and PAR_EXAMPLES variables.
[ ] Add any files generated by it to the clean target.
[ ] Add the example binary and any files generated by it to the top-level .gitignore file.

[ ] Update examples/CMakeLists.txt:

[ ] Add the example code to the ALL_EXE_SRCS variable.
[ ] Make sure THIS_TEST_OPTIONS is set correctly for the new example.

[ ] List the new example in doc/CodeDocumentation.dox.
[ ] If new examples directory (e.g.examples/pumi), list it in doc/CodeDocumentation.conf.in
[ ] Companion pull request for documentation in mfem/web repo:

[ ] Update or add example-specific documentation, see e.g. the src/examples.md.
[ ] Add the description, labels and screenshots in src/examples.md and src/img.
[ ] In examples.md, list the example under the appropriate categories, add new categories if necessary.
[ ] Add a short description of the example in the "Extensive Examples" section of features.md.

[ ] New miniapps:

[ ] All sample runs at the top of the miniapp source file work.
[ ] Update top-level makefile and makefile in corresponding miniapp directory.
[ ] Add the miniapp binary and any files generated by it to the top-level .gitignore file.
[ ] Update CMake build system:

[ ] Update the CMakeLists.txt file in the miniapps directory, if the new miniapp is in a new directory.
[ ] Add/update the CMakeLists.txt file in the new miniapp directory.
[ ] Consider adding a new test for the new miniapp.

[ ] List the new miniapp in doc/CodeDocumentation.dox
[ ] If new miniapps directory (e.g.miniapps/nurbs), add it to MINIAPP_SUBDIRS in the makefile.
[ ] If new miniapps directory (e.g.miniapps/nurbs), list it in doc/CodeDocumentation.conf.in
[ ] Companion pull request for documentation in mfem/web repo:

[ ] Update or add miniapp-specific documentation, see e.g. the src/meshing.md and src/electromagnetics.md files.
[ ] Add the description, labels and screenshots in src/examples.md and src/img.
[ ] The miniapps go at the end of the page, and are usually listed only under a specific "Application (PDE)" category.
[ ] Add a short description of the miniapp in the "Extensive Examples" section of features.md.

[ ] New capability:

[ ] All new public, protected, and private classes, methods, data members, and functions have full Doxygen-style documentation in source comments. Documentation should include descriptions of member data, function arguments and return values, template parameters, and prerequisites for calling new functions.
[ ] Pointer arguments and return values must specify whether ownership is being transferred or lent with the call.
[ ] Any new functions should include descriptions of their intended use e.g. for internal use only, user-facing, etc., along with references to example code whenever possible/appropriate.
[ ] Consider adding new sample runs in existing examples to highlight the new capability.
[ ] Consider saving cool simulation pictures with the new capability in the Confluence gallery (LLNL only) or submitting them, via pull request, to the gallery section of the mfem/web repo.
[ ] If this is a major new feature, consider mentioning it in the short summary inside README (rare).
[ ] List major new classes in doc/CodeDocumentation.dox (rare).

[ ] Update this checklist, if the new pull request affects it.
[ ] Run make unittest to make sure all unit tests pass.
[ ] Run the tests in tests/scripts.
[ ] (LLNL only) After merging:

[ ] Update internal tests to include the new features.

I think it would be better to make the device type an optional argument like we did with the geometric factors: https://github.com/mfem/mfem/blob/master/mesh/mesh.cpp#L11935-L11978.
You can use MemoryType::DEFAULT like we do here then pick the actual type based on that value like we do here. Does that make sense?

This PR is now under review (see the table in the PR description). To help with the review process, please do not force push to the branch.

Hey... this failed:
84/112 Test  #84: navier_tgv_np2 ........................***Failed    0.37 sec

Hey... this failed: 84/112 Test  #84: navier_tgv_np2 ........................***Failed 0.37 sec

I'll try restarting the failed windows job.

@artv3, try re-merging master, there was a cmake issues that caused such failures...

Now a different test failed in that windows job -- it looks like that windows CI environment is not very stable.

Merged in next for testing...


Exception when adding an object to a GraphicsLayer created in code, but only in WASM

If I create a GraphicsLayer in code for Blazor WASM, I get a System.InvalidOperationException exception when I add anything to the layer. The exception message is The render handle is not yet assigned.  In MAUI Hybrid Blazor, the code works as expected.
I create the layer like this in the OnViewRendered event of the MapView
GraphicsLayer? customLayer;
Task ViewRendered()
{
    if (customLayer == null)
    {
        customLayer = new GraphicsLayer(null, "Code Behind", 1.0, true, ListMode.Show);
        // Using the this syntax produces the same results
        customLayer = new GraphicsLayer(null, "Code Behind", null, null, null);
        return _mapView!.AddLayer(customLayer);
    }
    return Task.CompletedTask;
}

I am adding a marker for a point like this:
SimpleMarkerSymbol symbol = new SimpleMarkerSymbol(new Outline(new MapColor("blue")), new MapColor("red"), 10);

var marker = new Graphic(new Point(point.Longitude, point.Latitude), symbol);

await customLayer!.Add(marker);

The exception happens at the customLayer!Add(marker) line. Is this a bug or am I defining the layer incorrectly?
What is happening
A System.InvalidOperationException of The render handle is not yet assigned. is thrown
What should happen
A marker symbol should be displayed
Steps to reproduce the problem

Clone the demo
Restore the nuget packages
Edit Program.cs and replace "INSERT YOUR KEY HERE" with your API key
Build and the run app
You should see a map. There will be a layerlist widget with 3 layers listed. The one labeled "Code Behind" is created in the code, and the other two are in the markup
Click the "Draw Route" button. You will see a route and stops drawn on the markup layers.
The stops should also be drawn on the "Code Behind" but are not and an exception message will display below the map

Tested under Windows 11 with Blazor web as the target platform. Compiled with VS 2022 17.8.0 Preview 4.0 and GeoBlazor 2.4.0

Thank you for the project example, it was very easy to replicate the issue. It looks like this problem has been solved in the latest release of GeoBlazor 2.5.0 (in both .net 7 and .net 8) can you try updating your project to the latest version and confirming if it's fixed for you?

Closing as we believe this is fixed.


Running with coverage produces error

Describe the bug
TypeError: Cannot read properties of null (reading 'result')
    at mergeProcessCovs (/workspaces/redacted/node_modules/.pnpm/@bcoe+v8-coverage@0.2.3/node_modules/@bcoe/v8-coverage/dist/lib/merge.js:22:44)
    at file:///workspaces/redacted/node_modules/.pnpm/@vitest+coverage-v8@1.4.0_vitest@1.5.0/node_modules/@vitest/coverage-v8/dist/provider.js:266:22
    at async Promise.all (index 1)
    at async V8CoverageProvider.reportCoverage (file:///workspaces/redacted/node_modules/.pnpm/@vitest+coverage-v8@1.4.0_vitest@1.5.0/node_modules/@vitest/coverage-v8/dist/provider.js:263:11)
    at async Vitest.reportCoverage (file:///workspaces/redacted/node_modules/.pnpm/vitest@1.5.0_@types+node@20.12.6_@vitest+ui@1.4.0_jsdom@24.0.0_less@4.1.3_stylus@0.59.0/node_modules/vitest/dist/vendor/cac.qnW6GNL2.js:12014:7)
    at async file:///workspaces/redacted/node_modules/.pnpm/vitest@1.5.0_@types+node@20.12.6_@vitest+ui@1.4.0_jsdom@24.0.0_less@4.1.3_stylus@0.59.0/node_modules/vitest/dist/vendor/cac.qnW6GNL2.js:11789:7
    at async Vitest.runFiles (file:///workspaces/redacted/node_modules/.pnpm/vitest@1.5.0_@types+node@20.12.6_@vitest+ui@1.4.0_jsdom@24.0.0_less@4.1.3_stylus@0.59.0/node_modules/vitest/dist/vendor/cac.qnW6GNL2.js:11795:12)
    at async t.rerunTests (/root/.vscode-server/extensions/vitest.explorer-0.6.0/dist/worker.js:3:4352)
    at async t.runTestFiles (/root/.vscode-server/extensions/vitest.explorer-0.6.0/dist/worker.js:3:4153)
    at async t.runTests (/root/.vscode-server/extensions/vitest.explorer-0.6.0/dist/worker.js:3:3622)

Reproduction
No repro yet - hoping the stack trace is enough.
Output
[INFO 9:47:27 AM] [v0.6.0] Vitest extension is activated because Vitest is installed or there is a Vite/Vitest config file in the workspace.
[INFO 9:47:27 AM] [API] Running Vitest: v1.5.0 (/workspaces/WATS/vitest.workspace.ts)
[INFO 9:47:28 AM] [API] Vitest process 22069 created
[Worker]  Vitest  "cache.dir" is deprecated, use Vite's "cacheDir" instead if you want to change the cache director. Note caches will be written to "cacheDir/vitest"
[Worker] Coverage reports directory is generated: /tmp/vitest-coverage-240cb5ae-b6a8-477a-b9ea-0653864416cf
[INFO 9:47:36 AM] Running all tests in WATS

[INFO 9:48:54 AM] [TEST] run-test: redacted.test.ts  redacted 10.31s

[Error 9:49:23 AM] [Error TypeError] TypeError: Cannot read properties of null (reading 'result')
    at mergeProcessCovs (/workspaces/redacted/node_modules/.pnpm/@bcoe+v8-coverage@0.2.3/node_modules/@bcoe/v8-coverage/dist/lib/merge.js:22:44)
    at file:///workspaces/redacted/node_modules/.pnpm/@vitest+coverage-v8@1.4.0_vitest@1.5.0/node_modules/@vitest/coverage-v8/dist/provider.js:266:22
    at async Promise.all (index 1)
    at async V8CoverageProvider.reportCoverage (file:///workspaces/redacted/node_modules/.pnpm/@vitest+coverage-v8@1.4.0_vitest@1.5.0/node_modules/@vitest/coverage-v8/dist/provider.js:263:11)
    at async Vitest.reportCoverage (file:///workspaces/redacted/node_modules/.pnpm/vitest@1.5.0_@types+node@20.12.6_@vitest+ui@1.4.0_jsdom@24.0.0_less@4.1.3_stylus@0.59.0/node_modules/vitest/dist/vendor/cac.qnW6GNL2.js:12014:7)
    at async file:///workspaces/redacted/node_modules/.pnpm/vitest@1.5.0_@types+node@20.12.6_@vitest+ui@1.4.0_jsdom@24.0.0_less@4.1.3_stylus@0.59.0/node_modules/vitest/dist/vendor/cac.qnW6GNL2.js:11789:7
    at async Vitest.runFiles (file:///workspaces/redacted/node_modules/.pnpm/vitest@1.5.0_@types+node@20.12.6_@vitest+ui@1.4.0_jsdom@24.0.0_less@4.1.3_stylus@0.59.0/node_modules/vitest/dist/vendor/cac.qnW6GNL2.js:11795:12)
    at async t.rerunTests (/root/.vscode-server/extensions/vitest.explorer-0.6.0/dist/worker.js:3:4352)
    at async t.runTestFiles (/root/.vscode-server/extensions/vitest.explorer-0.6.0/dist/worker.js:3:4153)
    at async t.runTests (/root/.vscode-server/extensions/vitest.explorer-0.6.0/dist/worker.js:3:3622)

Version
v0.6.0
Validations

[X] Check that you are using the latest version of the extension
[X] Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
[X] Check that this is a concrete bug. For Q&A open a GitHub Discussion or join our Discord Chat Server.
[X] The provided reproduction is a minimal reproducible example of the bug.

at file:///workspaces/redacted/node_modules/.pnpm/@vitest+coverage-v8<EMAIL_ADDRESS>                                                                      ^^^^^        ^^^^^

Could you try if updating the coverage package works? Vitest expects that all Vitest packages have matching versions.

I get the same after upgrading:
[Error 3:49:10 PM] [Error TypeError] Cannot read properties of null (reading 'result')
TypeError: Cannot read properties of null (reading 'result')
    at mergeProcessCovs (/workspaces/redacted/node_modules/.pnpm/@bcoe+v8-coverage@0.2.3/node_modules/@bcoe/v8-coverage/dist/lib/merge.js:22:44)
    at file:///workspaces/redacted/node_modules/.pnpm/@vitest+coverage-v8@1.5.0_vitest@1.5.0/node_modules/@vitest/coverage-v8/dist/provider.js:2374:22
    at async Promise.all (index 0)
    at async V8CoverageProvider.reportCoverage (file:///workspaces/WATS/node_modules/.pnpm/@vitest+coverage-v8@1.5.0_vitest@1.5.0/node_modules/@vitest/coverage-v8/dist/provider.js:2371:11)
    at async Vitest.reportCoverage (file:///workspaces/redacted/node_modules/.pnpm/vitest@1.5.0_@types+node@20.12.6_@vitest+ui@1.4.0_jsdom@24.0.0_less@4.1.3_stylus@0.59.0/node_modules/vitest/dist/vendor/cac.qnW6GNL2.js:12014:7)
    at async file:///workspaces/redacted/node_modules/.pnpm/vitest@1.5.0_@types+node@20.12.6_@vitest+ui@1.4.0_jsdom@24.0.0_less@4.1.3_stylus@0.59.0/node_modules/vitest/dist/vendor/cac.qnW6GNL2.js:11789:7
    at async Vitest.runFiles (file:///workspaces/redacted/node_modules/.pnpm/vitest@1.5.0_@types+node@20.12.6_@vitest+ui@1.4.0_jsdom@24.0.0_less@4.1.3_stylus@0.59.0/node_modules/vitest/dist/vendor/cac.qnW6GNL2.js:11795:12)
    at async t.rerunTests (/root/.vscode-server/extensions/vitest.explorer-0.6.0/dist/worker.js:3:4352)
    at async t.runTestFiles (/root/.vscode-server/extensions/vitest.explorer-0.6.0/dist/worker.js:3:4153)
    at async t.runTests (/root/.vscode-server/extensions/vitest.explorer-0.6.0/dist/worker.js:3:3622)

Here's my vitest.workspace.ts file:
import { nxViteTsPaths } from<EMAIL_ADDRESS>import { v4 } from 'uuid';
import { UserConfig, defineWorkspace } from "vitest/config";

const userConfig: UserConfig = {
  plugins: [nxViteTsPaths()],
  test: {
    env: {
      VITEST: v4()
    },
    pool: 'forks',
    testTimeout: 60_000 * 3,
    maxConcurrency: 3,
    maxWorkers: 10,
    hookTimeout: 60_000 * 3,
    globals: true,
    globalSetup: ['./jest.global-setup.ts'],
    setupFiles: ['./jest.setup.ts'],
    cache: {
      dir: '../../../node_modules/.vitest',
    },
    environment: 'node',
    include: ['src/**/*.{test,spec}.{js,mjs,cjs,ts,mts,cts,jsx,tsx}'],
    exclude: ['src/apps/widgets/**/*']
  },
  esbuild: {
    target: 'es2022'
  },
};

export default defineWorkspace([
  userConfig
]);

I have the same issue :
[Error 21:15:15] [Error TypeError] Cannot read properties of null (reading 'result')
TypeError: Cannot read properties of null (reading 'result')
    at mergeProcessCovs (/Users/ludovic/Projets/starter/node_modules/.pnpm/@bcoe+v8-coverage@0.2.3/node_modules/@bcoe/v8-coverage/dist/lib/merge.js:22:44)
    at file:///Users/ludovic/Projets/starter/node_modules/.pnpm/@vitest+coverage-v8@1.5.0_vitest@1.5.0_@types+node@20.12.7_jsdom@24.0.0_/node_modules/@vitest/coverage-v8/dist/provider.js:2374:22
    at async Promise.all (index 0)
    at async V8CoverageProvider.reportCoverage (file:///Users/ludovic/Projets/starter/node_modules/.pnpm/@vitest+coverage-v8@1.5.0_vitest@1.5.0_@types+node@20.12.7_jsdom@24.0.0_/node_modules/@vitest/coverage-v8/dist/provider.js:2371:11)
    at async Vitest.reportCoverage (file:///Users/ludovic/Projets/starter/node_modules/.pnpm/vitest@1.5.0_@types+node@20.12.7_jsdom@24.0.0/node_modules/vitest/dist/vendor/cac.qnW6GNL2.js:12014:7)
    at async file:///Users/ludovic/Projets/starter/node_modules/.pnpm/vitest@1.5.0_@types+node@20.12.7_jsdom@24.0.0/node_modules/vitest/dist/vendor/cac.qnW6GNL2.js:11789:7
    at async Vitest.runFiles (file:///Users/ludovic/Projets/starter/node_modules/.pnpm/vitest@1.5.0_@types+node@20.12.7_jsdom@24.0.0/node_modules/vitest/dist/vendor/cac.qnW6GNL2.js:11795:12)
    at async t.rerunTests (/Users/ludovic/.vscode/extensions/vitest.explorer-0.6.2/dist/worker.js:3:4427)
    at async t.runTestFiles (/Users/ludovic/.vscode/extensions/vitest.explorer-0.6.2/dist/worker.js:3:4228)
    at async t.runTests (/Users/ludovic/.vscode/extensions/vitest.explorer-0.6.2/dist/worker.js:3:3697)

If it can help to find the issue cause, this is my configuration :
// vitest.workspace.ts
import { defineWorkspace } from "vitest/config";

export default defineWorkspace(["apps/*", "packages/*"]);

// vitest.config.ts
import { coverageConfigDefaults, defineConfig } from "vitest/config";

export default defineConfig({
  test: {
    coverage: {
      provider: "v8",
      exclude: [
        ...coverageConfigDefaults.exclude,
        "commitlint.config.ts",
        "**/vitest-setup.ts",
        "tooling/*",
        "packages/utils/src/index.ts",
        "**/*.stories.tsx",
      ],
    },
  },
});

I use @vitest/coverage-v8 and vitest v1.5.0

me the same. In the log, I can see a temporary folder for the coverage has been created. However, after running a coverage test, I only see 2 coverage files (e.g. /var/folders/s6/3j1v_rn101x9f5m7w63bssb80000gn/T/vitest-coverage-9bf5988c-bdc1-436f-a101-d9a8d7337d36/.tmp/coverage-0.json) under .tmp folder of the temporary coverage folder, and the content of both of the files are simply null.
When I run vitest run --coverage, the coverage files are generated as expected.
@sheremet-va Do you know how to print out the command used by the vscode extension to generate the coverage result to the log?

Do you know how to print out the command used by the vscode extension to generate the coverage result to the log?

It uses programmatic API with your config but overrides the directory.
Is there any good reproduction I can check to debug this issue?

Do you know how to print out the command used by the vscode extension to generate the coverage result to the log?

It uses programmatic API with your config but overrides the directory.
Is there any good reproduction I can check to debug this issue?

No, unfortunately not. But as you can see, others are also having the issue, so I think maybe closing this in 3 days seems a bit rushed?

No, but at least we can then speculate and discuss theories around what the root cause could be, and dive into it together.
Is there any way where we can insert some kind of logging to help determine the cause of this?

You can add DEBUG: "vite:*,vitest:coverage" to vitest.nodeEnv option.

@ffMathy @ludovicmnji By any chance you have multiple configs in your monorepo? When I remove all configs but only one left on the workspace root, it works perfectly

No, but at least we can then speculate and discuss theories around what the root cause could be, and dive into it together.

You can still speculate, the issue is not locked. More info on why I require that every issue has a reproduction: https://antfu.me/posts/why-reproductions-are-required

I get that. I'm an open source maintainer myself (with 100+ NuGet packages and 10+ NPM packages under my disposal). It can be tiring and people can be very mean.
However, I am just saying that you probably also have an interest in getting good ratings for the extension, right? It's not all black and white. I get where you are coming from, but this issue now has 3 upvotes (despite it being closed), so it might be affecting a lot of people.
@alvis I'll try that soon and report back.

@alvis that unfortunately didn't work for me. I just have one Vitest workspace file in the root of my repo.

@ffMathy do you have a config file alongside your workspace file?
here is my config
// vitest.workspace.ts
import { defineWorkspace } from "vitest/config";

export default defineWorkspace(["**/vitest.config.ts"]);

// vitest.config.ts
import tsconfigPaths from 'vite-tsconfig-paths';
import { defineConfig } from 'vitest/config';

export default defineConfig({
  plugins: [tsconfigPaths()],
  test: {
    watch: false,
    coverage: {
      all: true,
      clean: true,
      include: ['**/source/**'],
      provider: 'v8',
      reporter: ['lcov', 'text', 'html'],
    },
    include: ['**/*.(spec|spec-d).?(c|m)[jt]s?(x)'],
  },
});

No, I only have a workspace file (the one I posted in an earlier comment) ❤🙏

@ffMathy @ludovicmnji By any chance you have multiple configs in your monorepo? When I remove all configs but only one left on the workspace root, it works perfectly

I have multiple configs (monorepo config). I have vitest.workspace.ts + vitest.config.ts in root (because coverage in monorepo can't be configured in each package) and I have vitest.config.ts in multiple packages.

I'm also facing this issue with a monorepo and never realized that the vitest vscode extension already provides basic coverage support. I'm still trying to figure the issue out so do not expect a repro anytime soon.
My finding on the TypeError: Cannot read properties of null (reading 'result') error message was because of coverage files being stored with a null string and when this LoC in coverage-v8 package is trying to read the coverage file what it got was just a null object and mergeProcessCovs expect an object { result: [] }.
173   const contents = await fs.readFile(filename, 'utf-8'); // the file contains `null`
174   const coverage = JSON.parse(contents) as RawCoverage; // coverage = null
175   merged = mergeProcessCovs([merged, coverage]) // coverage should be at least `{ result: [] }`

Even though I am not 100% sure why the coverage file contains null and I'm still trying to debug. IMHO L174-L175 should have a basic check to ensure that coverage is not nullish before it tries to merge the coverage.

IMHO L174-L175 should have a basic check to ensure that coverage is not nullish before it tries to merge the coverage.

It should not do that. The coverage value should never be null, there is a check for that when it's stored. If it is null at this point, then something went wrong prior to that. If we have a check here, the issue will just be swallowed and harder to debug.

It should not do that. The coverage value should never be null, there is a check for that when it's stored. If it is null at this point, then something went wrong prior to that. If we have a check here, the issue will just be swallowed and harder to debug.

Good point. IIUC, the coverage here is where the coverage file was first created after each test. coverage here is returning null which explains why we got null from the coverage file.
Good news is that I was able to reproduce the error, which was quite unexpected. Based from the provided config files above I can deduce that the root cause of the coverage content being nullish was because of test.coverage.enabled was not set to true in vite.config.ts. I can consistently reproduce the error message and while you might not need a repro for that, you can use this repo for verification if needed.
I’m not sure how to handle this. An easy approach might be to provide some hints or simply enable coverage, regardless of the value of test.coverage.enabled in vite.config.ts.
Another possible root cause could be incorrect configuration of vite.workspace.ts. The workspace config confuses me and I question the need of it.

@motss I updated my vitest.config.ts file with test.coverage.enabled in the monorepo root, and it's working now, too.
// vitest.config.ts
import { coverageConfigDefaults, defineConfig } from "vitest/config";

export default defineConfig({
  test: {
    coverage: {
      enabled: true,
      provider: "v8",
      exclude: [
        ...coverageConfigDefaults.exclude,
        "commitlint.config.ts",
        "**/vitest-setup.ts",
        "tooling/*",
        "packages/utils/src/index.ts",
        "**/*.stories.tsx",
      ],
    },
  },
});

But I don't want to run coverage when I simply run pnpm run test.


Hengguo/sq medium blog

Type of Change
feature or bug fix or documentation or validation or others
API changed or not
Description
detail description
Expected Behavior & Potential Risk
the expected behavior that triggered by this PR
How has this PR been tested?
how to reproduce the test (including hardware information)
Dependency Change?
any library dependency introduced or removed

will not merge to master


Localize $@ in all subs using eval

@einhverfr ping?

had an issue with code conflicts and a problem on my repo. fixed and merged.
On Sat, Jan 9, 2016 at 3:48 PM, Erik Huelsmann<EMAIL_ADDRESS>wrote:

@einhverfr https://github.com/einhverfr ping?
—
Reply to this email directly or view it on GitHub
https://github.com/ledgersmb/PGObject/pull/3#issuecomment-170244557.

--
Best Wishes,
Chris Travers
Efficito:  Hosted Accounting and ERP.  Robust and Flexible.  No vendor
lock-in.
http://www.efficito.com/learn_more


Put API code into a library

Hey, this project is great!
However, I would be even more useful, if we could separate the presentation/app code and the API handling. A crates.io library would allow others to build their own apps using this crate.
For example, I was thinking about building a small website displaying the same information like your CLI app.

Hi Michael, thanks for opening this issue.
You mean publishing the API handling like fetching stations etc as an API wrapper crate?
It's a good idea, and will make the code more maintainable. I might do it soon-ish but can't promise any timeline :)


test(cli): add timestamps in log files

https://coveord.atlassian.net/browse/CDX-300
Proposed changes
Prepend a timestamp on every line that is added to the artifacts.
This will help knowing how long each spawn process takes

CDX-300

Just doing some tests with the github action before marking the PR ready for review


protobuf java square write code-gen

#I'm trying to generate code from the GA4GH-schema proto files using:
https://github.com/square/wire
At the moment I am chasing down file dependencies as maven is telling me:
Wire Plugin: Failure compiling proto sources. Failed to locate google/protobuf/struct.proto

I note that:
https://github.com/ga4gh/ga4gh-schemas/blob/master/src/main/proto/ga4gh/variants.proto#L10
refers to "google/protobuf/struct.proto"
and GA4GH-schema repo contains a few of these proto files from google.api
https://github.com/ga4gh/ga4gh-schemas/tree/master/src/main/proto/google/api
but not struct.proto
I am curious as to why we include in our GA4GH-schema repo these annotations.proto and http.proto files at all as they don't seem project specific (did we require some custom hacked version?), and why struct.proto is not there.   I can find it here:
https://github.com/google/protobuf/tree/master/src/google/protobuf
but am concerned with the versioning, and think it is strange we have our own copies anyhow.
Here is my non-working attempt to use square write pb code-gen:
https://github.com/jpdna/mango/tree/wire_proto
@heuermh  may have thoughts as well

Google ships the struct.proto here https://github.com/google/protobuf/blob/master/src/google/protobuf/struct.proto which is included when you do protoc.

As for why we have our own copies:
https://github.com/ga4gh/ga4gh-schemas/issues/696
Is this too much of an implementation detail? Would the APIs be cleaner without them?

Protobuf gives you a nice way to namespace packages, and including them is done with a -I just like one might imagine for compiling C code. I would like to keep them in a separate repository, but we need to offer a way to easily get them (for people like Justin), when they go to compile. Until there's a "proto repository" of sorts, some combination of keeping your own copy, git submodules, or downloading via a script are our best options. I think we could close this by adding the struct.proto to our repo. Since we use protoc we get some of Google's dependencies for free.
I'm really happy to learn about Wire, we need alternative implementations of protobuf, especially at the code generation end.


Ubuntu 20.04: connects, then immediately disconnects

The setup is Ubuntu 20.04 starting from non-X11 configuration. Then standard
sudo apt install xrdp
which pulls in X11 and gnome (not sure how much of gnome). Nothing else is explicitly installed.
The standard non-root user was set up to only login with ssh keys, This caused xrdp authentication problems. Setting a password and using it for the xrdp connection (via krdc) seems to allow better authentication although there is still a gnome keyring problem
From what I can tell then the Xserver starts up fine but then immediately closes down (with or without parallel console ssh login).
This is how far I got.
I scoured issues and forums for an extended time but could not identify a solution. I tried Xwrapper.config allowed_users=anyone but without success.
Here are relevant logs:
$ tail /var/log/Xauth.log
Jun 27 17:33:46 linuxrdp xrdp-sesman[1721]: pam_unix(xrdp-sesman:session): session opened for user ubuntu by (uid=0)
Jun 27 17:33:46 linuxrdp systemd-logind[384]: New session c5 of user ubuntu.
Jun 27 17:33:46 linuxrdp systemd: pam_unix(systemd-user:session): session opened for user ubuntu by (uid=0)
Jun 27 17:33:47 linuxrdp gnome-keyring-daemon[1813]: couldn't access control socket: /run/user/1000/keyring/control: No such file or directory
Jun 27 17:33:49 linuxrdp xrdp-sesman[1721]: pam_unix(xrdp-sesman:session): session closed for user ubuntu
Jun 27 17:33:49 linuxrdp systemd-logind[384]: Failed to restore VT, ignoring: Bad file descriptor
Jun 27 17:33:51 linuxrdp systemd-logind[384]: Session c5 logged out. Waiting for processes to exit.
Jun 27 17:33:57 linuxrdp systemd-logind[384]: Removed session c5.

$ tail /var/log/xrdp-sesman.log
[20220627-17:33:43] [INFO ] A connection received from ::1 port 57836
[20220627-17:33:43] [INFO ] ++ created session (access granted): username ubuntu, ip ::ffff:140.XXX.XXX.XX:56248 - socket: 12
[20220627-17:33:44] [INFO ] starting Xorg session...
[20220627-17:33:44] [DEBUG] Closed socket 9 (AF_INET6 :: port 5910)
[20220627-17:33:44] [DEBUG] Closed socket 9 (AF_INET6 :: port 6010)
[20220627-17:33:44] [DEBUG] Closed socket 9 (AF_INET6 :: port 6210)
[20220627-17:33:44] [DEBUG] Closed socket 8 (AF_INET6 ::1 port 3350)
[20220627-17:33:44] [INFO ] calling auth_start_session from pid 1721
[20220627-17:33:46] [DEBUG] Closed socket 7 (AF_INET6 ::1 port 3350)
[20220627-17:33:46] [DEBUG] Closed socket 8 (AF_INET6 ::1 port 3350)
[20220627-17:33:46] [INFO ] /usr/lib/xorg/Xorg :10 -auth .Xauthority -config xrdp/xorg.conf -noreset -nolisten tcp -logfile .xorgxrdp.%s.log
[20220627-17:33:47] [CORE ] waiting for window manager (pid 1733) to exit
[20220627-17:33:47] [CORE ] window manager (pid 1733) did exit, cleaning up session
[20220627-17:33:48] [INFO ] calling auth_stop_session and auth_end from pid 1721
[20220627-17:33:49] [DEBUG] cleanup_sockets:
[20220627-17:33:50] [DEBUG] cleanup_sockets: deleting /run/xrdp/sockdir/xrdp_chansrv_socket_10
[20220627-17:33:50] [DEBUG] cleanup_sockets: deleting /run/xrdp/sockdir/xrdpapi_10
[20220627-17:33:51] [INFO ] ++ terminated session:  username ubuntu, display :10.0, session_pid 1721, ip ::ffff:<IP_ADDRESS>:56248 - socket: 12

$ tail /var/log/xrdp.log
[20220627-17:33:38] [INFO ] Socket 12: AF_INET6 connection received from ::ffff:140.XXX.XXX.XX port 56248
[20220627-17:33:38] [DEBUG] Closed socket 12 (AF_INET6 ::ffff:<IP_ADDRESS> port 3389)
[20220627-17:33:38] [DEBUG] Closed socket 11 (AF_INET6 :: port 3389)
[20220627-17:33:39] [INFO ] Using default X.509 certificate: /etc/xrdp/cert.pem
[20220627-17:33:39] [INFO ] Using default X.509 key file: /etc/xrdp/key.pem
[20220627-17:33:39] [ERROR] Cannot read private key file /etc/xrdp/key.pem: Permission denied
[20220627-17:33:40] [DEBUG] TLSv1.3 enabled
[20220627-17:33:40] [DEBUG] TLSv1.2 enabled
[20220627-17:33:40] [DEBUG] Security layer: requested 3, selected 0
[20220627-17:33:41] [INFO ] connected client computer name: LinuxComputer2
[20220627-17:33:41] [INFO ] adding channel item name rdpdr chan_id 1004 flags 0xc0800000
[20220627-17:33:41] [INFO ] adding channel item name rdpsnd chan_id 1005 flags 0xc0000000
[20220627-17:33:41] [INFO ] adding channel item name cliprdr chan_id 1006 flags 0xc0a00000
[20220627-17:33:42] [INFO ] Non-TLS connection established from ::ffff:140.XXX.XXX.XX port 56248: encrypted with standard RDP security
[20220627-17:33:42] [DEBUG] xrdp_000006b7_wm_login_mode_event_00000001
[20220627-17:33:42] [INFO ] Loading keymap file /etc/xrdp/km-00000409.ini
[20220627-17:33:42] [WARN ] local keymap file for 0x00000409 found and doesn't match built in keymap, using local keymap file
[20220627-17:33:43] [DEBUG] xrdp_wm_log_msg: connecting to sesman ip <IP_ADDRESS> port 3350
[20220627-17:33:43] [INFO ] xrdp_wm_log_msg: sesman connect ok
[20220627-17:33:43] [DEBUG] xrdp_wm_log_msg: sending login info to session manager, please wait...
[20220627-17:33:43] [DEBUG] return value from xrdp_mm_connect 0
[20220627-17:33:44] [INFO ] xrdp_wm_log_msg: login successful for display 10
[20220627-17:33:45] [DEBUG] xrdp_wm_log_msg: started connecting
[20220627-17:33:47] [INFO ] lib_mod_log_peer: xrdp_pid=1719 connected to X11rdp_pid=1734 X11rdp_uid=1000 X11rdp_gid=1000 client_ip=::ffff:140.XXX.XXX.XX client_port=56248
[20220627-17:33:47] [DEBUG] xrdp_wm_log_msg: connected ok
[20220627-17:33:49] [DEBUG] xrdp_mm_connect_chansrv: chansrv connect successful
[20220627-17:33:50] [DEBUG] Closed socket 22 (AF_INET6 ::1 port 57836)
[20220627-17:33:50] [DEBUG] Closed socket 12 (AF_INET6 ::ffff:<IP_ADDRESS> port 3389)
[20220627-17:33:51] [DEBUG] xrdp_mm_module_cleanup
[20220627-17:33:51] [DEBUG] Closed socket 23 (AF_UNIX)
[20220627-17:33:52] [DEBUG] Closed socket 24 (AF_UNIX)

$ tail ~/.xession-errors
Xsession: X session started for ubuntu at Mon Jun 27 17:33:47 UTC 2022
dbus-update-activation-environment: setting DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1000/bus
dbus-update-activation-environment: setting DISPLAY=:10.0
localuser:ubuntu being added to access control list
dbus-update-activation-environment: setting QT_ACCESSIBILITY=1
dbus-update-activation-environment: setting USER=ubuntu
dbus-update-activation-environment: setting XDG_SESSION_TYPE=x11
dbus-update-activation-environment: setting HOME=/home/ubuntu
dbus-update-activation-environment: setting XRDP_PULSE_SINK_SOCKET=xrdp_chansrv_audio_out_socket_10
dbus-update-activation-environment: setting XRDP_PULSE_SOURCE_SOCKET=xrdp_chansrv_audio_in_socket_10
dbus-update-activation-environment: setting DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1000/bus
dbus-update-activation-environment: setting PULSE_SCRIPT=/etc/xrdp/pulse/default.pa
dbus-update-activation-environment: setting IM_CONFIG_PHASE=1
dbus-update-activation-environment: setting LOGNAME=ubuntu
dbus-update-activation-environment: setting XDG_SESSION_CLASS=user
dbus-update-activation-environment: setting PATH=/sbin:/bin:/usr/bin:/usr/local/bin:/snap/bin
dbus-update-activation-environment: setting XRDP_SOCKET_PATH=/run/xrdp/sockdir
dbus-update-activation-environment: setting XDG_RUNTIME_DIR=/run/user/1000
dbus-update-activation-environment: setting DISPLAY=:10.0
dbus-update-activation-environment: setting LANG=C.UTF-8
dbus-update-activation-environment: setting UID=1000
dbus-update-activation-environment: setting SHELL=/bin/bash
dbus-update-activation-environment: setting QT_ACCESSIBILITY=1
dbus-update-activation-environment: setting XRDP_SESSION=1
dbus-update-activation-environment: setting GPG_AGENT_INFO=/run/user/1000/gnupg/S.gpg-agent:0:1
dbus-update-activation-environment: setting PWD=/home/ubuntu
dbus-update-activation-environment: setting XDG_DATA_DIRS=/usr/share/gnome:/usr/local/share:/usr/share:/var/lib/snapd/desktop

tail ~/.xorgxrdp.10.log
[  5946.674] rdpRRScreenSetSize: width 800 height 600 mmWidth 212 mmHeight 159
[  5946.674] rdpRRGetInfo:
[  5946.674]   screen resized to 800x600
[  5946.674]   RRScreenSizeSet ok 1
[  5946.674] rdpClientConGotConnection:
[  5946.674] rdpClientConGotConnection: g_sck_accept ok new_sck 7
[  5946.674] rdpClientConGetConnection: idle_disconnect_timeout set to non-positive value, idle timer turned off
[  5946.674] rdpAddClientConToDev: adding first clientCon 0x555f24bc7110
[  5946.729] rdpRRGetInfo:
[  5946.770] rdpInDeferredRepeatCallback:
[  5946.770] rdpkeybChangeKeyboardControl:
[  5946.770] rdpkeybChangeKeyboardControl: autoRepeat off
[  5946.823] rdpRRGetInfo:
[  5946.829] rdpClientConProcessMsgVersion: version 0 0 0 1
[  5946.829] rdpClientConProcessScreenSizeMsg: set width 800 height 600 bpp 32
[  5946.829] rdpClientConProcessScreenSizeMsg: shmemid 12 shmemptr 0x7f69e29c0000
[  5946.829] rdpClientConProcessMsgClientInput: invalidate x 0 y 0 cx 800 cy 600
[  5947.900] KbdSync: toggling num lock
[  5947.900] rdpkeybChangeKeyboardControl:
[  5947.900] rdpkeybChangeKeyboardControl: autoRepeat off
[  5948.984] rdpmouseControl: what 2
[  5948.984] rdpmouseDeviceOff:
[  5948.984] rdpkeybControl: what 2
[  5948.984] rdpkeybDeviceOff:
[  5948.986] rdpkeybControl: what 3
[  5948.986] rdpkeybUnInit: drv 0x555f246d5bf0 info 0x555f249dc820, flags 0x0
[  5948.986] rdpUnregisterInputCallback: proc 0x7f69eacf88e0
[  5948.986] rdpmouseControl: what 3
[  5948.986] rdpmouseUnInit: drv 0x555f246d7600 info 0x555f2486c090, flags 0x0
[  5948.986] rdpUnregisterInputCallback: proc 0x7f69eacfd430
[  5948.987] rdpCloseScreen:
[  5948.987] xorgxrdpDownDown:
[  5948.987] xorgxrdpDownDown: 1
[  5948.987] rdpClientConDeinit:
[  5948.987] rdpClientConDeinit: disconnecting clientCon
[  5948.987] rdpClientConDisconnect:
[  5948.987] rdpRemoveClientConFromDev: removing clientCon 0x555f24bc7110
[  5948.987] rdpClientConDeinit: deleting file /run/xrdp/sockdir/xrdp_display_10
[  5948.987] rdpClientConDeinit: deleting file /run/xrdp/sockdir/xrdp_disconnect_display_10
[  5948.991] (II) Server terminated successfully (0). Closing log file.

No WW warnings.

I manually started $ gnome-keyring-daemon and reset the ubuntu user password. This gets a little further perhaps:
$ tail /var/log/auth.log
Jun 27 20:40:00 li xrdp-sesman[930]: pam_unix(xrdp-sesman:session): session opened for user ubuntu by (uid=0)
Jun 27 20:40:00 li systemd-logind[423]: New session c1 of user ubuntu.
Jun 27 20:40:16 li gnome-keyring-daemon[898]: The Secret Service was already initialized
Jun 27 20:40:16 li gnome-keyring-daemon[898]: The PKCS#11 component was already initialized
Jun 27 20:40:16 li xrdp-sesman[930]: pam_unix(xrdp-sesman:session): session closed for user ubuntu
Jun 27 20:40:16 li systemd-logind[423]: Failed to restore VT, ignoring: Bad file descriptor
Jun 27 20:40:17 li systemd-logind[423]: Session c1 logged out. Waiting for processes to exit.
Jun 27 20:40:21 li systemd-logind[423]: Removed session c1.

$ tail  /var/log/xrdp-sesman.log
[20220627-20:40:00] [INFO ] A connection received from ::1 port 50222
[20220627-20:40:00] [INFO ] ++ created session (access granted): username ubuntu, ip ::ffff:140.xxx.xxx.xx:34866 - socket: 12
[20220627-20:40:00] [INFO ] starting Xorg session...
[20220627-20:40:00] [DEBUG] Closed socket 9 (AF_INET6 :: port 5910)
[20220627-20:40:00] [DEBUG] Closed socket 9 (AF_INET6 :: port 6010)
[20220627-20:40:00] [DEBUG] Closed socket 9 (AF_INET6 :: port 6210)
[20220627-20:40:00] [DEBUG] Closed socket 8 (AF_INET6 ::1 port 3350)
[20220627-20:40:00] [INFO ] calling auth_start_session from pid 930
[20220627-20:40:00] [DEBUG] Closed socket 7 (AF_INET6 ::1 port 3350)
[20220627-20:40:00] [DEBUG] Closed socket 8 (AF_INET6 ::1 port 3350)
[20220627-20:40:00] [INFO ] /usr/lib/xorg/Xorg :10 -auth .Xauthority -config xrdp/xorg.conf -noreset -nolisten tcp -logfile .xorgxrdp.%s.log
[20220627-20:40:01] [CORE ] waiting for window manager (pid 931) to exit
[20220627-20:40:16] [CORE ] window manager (pid 931) did exit, cleaning up session
[20220627-20:40:16] [INFO ] calling auth_stop_session and auth_end from pid 930
[20220627-20:40:16] [DEBUG] cleanup_sockets:
[20220627-20:40:16] [DEBUG] cleanup_sockets: deleting /run/xrdp/sockdir/xrdp_chansrv_audio_out_socket_10
[20220627-20:40:16] [DEBUG] cleanup_sockets: deleting /run/xrdp/sockdir/xrdp_chansrv_audio_in_socket_10
[20220627-20:40:16] [DEBUG] cleanup_sockets: deleting /run/xrdp/sockdir/xrdpapi_10
[20220627-20:40:16] [INFO ] ++ terminated session:  username ubuntu, display :10.0, session_pid 930, ip ::ffff:140.xxx.xxx.xx:34866 - socket: 12

Thanks for the comprehensive logs.
I think your window manager is exiting early:-
[20220627-17:33:47] [CORE ] waiting for window manager (pid 1733) to exit
[20220627-17:33:47] [CORE ] window manager (pid 1733) did exit, cleaning up session

Installing xrdp does not install GNOME - it might install bits of it due to pulling in other dependencies which depend on bits of GNOME however.
Do you specifically want a GNOME desktop for xrdp? If so, the next step is to explicitly install it (which pulls in a LOT of software). If not, installing another desktop (e.g. XFCE) might be a better way to go. Let me know which way you want to go.

Remote X11 with ssh forwarding works BTW but is very slow for the specific app.

I installed apt install xfce4 but still get the same result:
Jun 28 15:08:25 xfce xrdp-sesman[1595]: pam_unix(xrdp-sesman:session): session opened for user ubuntu by (uid=0)
Jun 28 15:08:25 xfce systemd-logind[397]: New session c3 of user ubuntu.
Jun 28 15:08:27 xfce gnome-keyring-daemon[1588]: The Secret Service was already initialized
Jun 28 15:08:27 xfce gnome-keyring-daemon[1588]: The PKCS#11 component was already initialized
Jun 28 15:08:27 xfce xrdp-sesman[1595]: pam_unix(xrdp-sesman:session): session closed for user ubuntu
Jun 28 15:08:27 xfce systemd-logind[397]: Failed to restore VT, ignoring: Bad file descriptor
Jun 28 15:08:27 xfce systemd-logind[397]: Session c3 logged out. Waiting for processes to exit.
Jun 28 15:08:36 xfce systemd-logind[397]: Removed session c3.

xrdp-sesman.log
[20220628-15:08:24] [INFO ] A connection received from ::1 port 39452
[20220628-15:08:24] [INFO ] ++ created session (access granted): username ubuntu, ip ::ffff:<IP_ADDRESS>:57026 - socket: 12
[20220628-15:08:25] [INFO ] starting Xorg session...
[20220628-15:08:25] [DEBUG] Closed socket 9 (AF_INET6 :: port 5910)
[20220628-15:08:25] [ERROR] g_tcp_bind(9, 6010) failed bind IPv6 (errno=98) and IPv4 (errno=22).
[20220628-15:08:25] [DEBUG] Closed socket 9 (AF_INET6 :: port 0)
[20220628-15:08:25] [DEBUG] Closed socket 9 (AF_INET6 :: port 5911)
[20220628-15:08:25] [DEBUG] Closed socket 9 (AF_INET6 :: port 6011)
[20220628-15:08:25] [DEBUG] Closed socket 9 (AF_INET6 :: port 6211)
[20220628-15:08:25] [DEBUG] Closed socket 9 (AF_INET6 :: port 5912)
[20220628-15:08:25] [DEBUG] Closed socket 9 (AF_INET6 :: port 6012)
[20220628-15:08:25] [DEBUG] Closed socket 9 (AF_INET6 :: port 6212)
[20220628-15:08:25] [DEBUG] Closed socket 8 (AF_INET6 ::1 port 3350)
[20220628-15:08:25] [INFO ] calling auth_start_session from pid 1595
[20220628-15:08:25] [DEBUG] Closed socket 7 (AF_INET6 ::1 port 3350)
[20220628-15:08:26] [DEBUG] Closed socket 8 (AF_INET6 ::1 port 3350)
[20220628-15:08:26] [INFO ] /usr/lib/xorg/Xorg :12 -auth .Xauthority -config xrdp/xorg.conf -noreset -nolisten tcp -logfile .xorgxrdp.%s.log
[20220628-15:08:26] [CORE ] waiting for window manager (pid 1596) to exit
[20220628-15:08:27] [CORE ] window manager (pid 1596) did exit, cleaning up session
[20220628-15:08:27] [INFO ] calling auth_stop_session and auth_end from pid 1595
[20220628-15:08:27] [DEBUG] cleanup_sockets:
[20220628-15:08:27] [DEBUG] cleanup_sockets: deleting /run/xrdp/sockdir/xrdp_chansrv_socket_12
[20220628-15:08:27] [DEBUG] cleanup_sockets: deleting /run/xrdp/sockdir/xrdpapi_12
[20220628-15:08:27] [INFO ] ++ terminated session:  username ubuntu, display :12.0, session_pid 1595, ip ::ffff:<IP_ADDRESS>:57026 - socket: 12

[20220628-15:08:21] [INFO ] Socket 12: AF_INET6 connection received from ::ffff:140.xx port 57026
[20220628-15:08:21] [DEBUG] Closed socket 12 (AF_INET6 ::ffff:<IP_ADDRESS> port 3389)
[20220628-15:08:21] [DEBUG] Closed socket 11 (AF_INET6 :: port 3389)
[20220628-15:08:22] [INFO ] Using default X.509 certificate: /etc/xrdp/cert.pem
[20220628-15:08:22] [INFO ] Using default X.509 key file: /etc/xrdp/key.pem
[20220628-15:08:22] [ERROR] Cannot read private key file /etc/xrdp/key.pem: Permission denied
[20220628-15:08:22] [DEBUG] TLSv1.3 enabled
[20220628-15:08:22] [DEBUG] TLSv1.2 enabled
[20220628-15:08:23] [DEBUG] Security layer: requested 3, selected 0
[20220628-15:08:23] [INFO ] connected client computer name: LinuxGeoMuseum2
[20220628-15:08:23] [INFO ] adding channel item name rdpdr chan_id 1004 flags 0xc0800000
[20220628-15:08:23] [INFO ] adding channel item name rdpsnd chan_id 1005 flags 0xc0000000
[20220628-15:08:23] [INFO ] adding channel item name cliprdr chan_id 1006 flags 0xc0a00000
[20220628-15:08:23] [INFO ] Non-TLS connection established from ::ffff:140.xx port 57026: encrypted with standard RDP security
[20220628-15:08:23] [DEBUG] xrdp_00000639_wm_login_mode_event_00000001
[20220628-15:08:23] [INFO ] Loading keymap file /etc/xrdp/km-00000409.ini
[20220628-15:08:24] [WARN ] local keymap file for 0x00000409 found and doesn't match built in keymap, using local keymap file
[20220628-15:08:24] [DEBUG] xrdp_wm_log_msg: connecting to sesman ip <IP_ADDRESS> port 3350
[20220628-15:08:24] [INFO ] xrdp_wm_log_msg: sesman connect ok
[20220628-15:08:24] [DEBUG] xrdp_wm_log_msg: sending login info to session manager, please wait...
[20220628-15:08:24] [DEBUG] return value from xrdp_mm_connect 0
[20220628-15:08:25] [INFO ] xrdp_wm_log_msg: login successful for display 12
[20220628-15:08:25] [DEBUG] xrdp_wm_log_msg: started connecting
[20220628-15:08:26] [INFO ] lib_mod_log_peer: xrdp_pid=1593 connected to X11rdp_pid=1597 X11rdp_uid=1000 X11rdp_gid=1000 client_ip=::ffff:140.xx client_port=57026
[20220628-15:08:26] [DEBUG] xrdp_wm_log_msg: connected ok
[20220628-15:08:27] [DEBUG] xrdp_mm_connect_chansrv: chansrv connect successful
[20220628-15:08:27] [DEBUG] Closed socket 22 (AF_INET6 ::1 port 39452)
[20220628-15:08:27] [DEBUG] Closed socket 12 (AF_INET6 ::ffff:<IP_ADDRESS> port 3389)
[20220628-15:08:28] [DEBUG] xrdp_mm_module_cleanup
[20220628-15:08:28] [DEBUG] Closed socket 23 (AF_UNIX)
[20220628-15:08:28] [DEBUG] Closed socket 24 (AF_UNIX)

.xsession-error
Xsession: X session started for ubuntu at Tue Jun 28 15:08:26 UTC 2022
dbus-update-activation-environment: setting DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1000/bus
dbus-update-activation-environment: setting DISPLAY=:12.0
localuser:ubuntu being added to access control list
dbus-update-activation-environment: setting QT_ACCESSIBILITY=1
dbus-update-activation-environment: setting USER=ubuntu
dbus-update-activation-environment: setting XDG_SESSION_TYPE=x11
dbus-update-activation-environment: setting HOME=/home/ubuntu
dbus-update-activation-environment: setting XRDP_PULSE_SINK_SOCKET=xrdp_chansrv_audio_out_socket_12
dbus-update-activation-environment: setting XRDP_PULSE_SOURCE_SOCKET=xrdp_chansrv_audio_in_socket_12
dbus-update-activation-environment: setting DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1000/bus
dbus-update-activation-environment: setting PULSE_SCRIPT=/etc/xrdp/pulse/default.pa
dbus-update-activation-environment: setting IM_CONFIG_PHASE=1
dbus-update-activation-environment: setting LOGNAME=ubuntu
dbus-update-activation-environment: setting XDG_SESSION_CLASS=user
dbus-update-activation-environment: setting PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/gam
es:/snap/bin
dbus-update-activation-environment: setting XRDP_SOCKET_PATH=/run/xrdp/sockdir
dbus-update-activation-environment: setting XDG_RUNTIME_DIR=/run/user/1000
dbus-update-activation-environment: setting DISPLAY=:12.0
dbus-update-activation-environment: setting LANG=C.UTF-8
dbus-update-activation-environment: setting UID=1000
dbus-update-activation-environment: setting SHELL=/bin/bash
dbus-update-activation-environment: setting QT_ACCESSIBILITY=1
dbus-update-activation-environment: setting XRDP_SESSION=1
dbus-update-activation-environment: setting GPG_AGENT_INFO=/run/user/1000/gnupg/S.gpg-agent:0:1
dbus-update-activation-environment: setting PWD=/home/ubuntu
dbus-update-activation-environment: setting XDG_DATA_DIRS=/usr/share/gnome:/usr/local/share:/usr/share:/var/lib/snapd/desktop

.xorgxrdp
...
[  1619.845] rdpkeybUnInit: drv 0x560cdef97d30 info 0x560cdf29eba0, flags 0x0
[  1619.845] rdpUnregisterInputCallback: proc 0x7f0f030238e0
[  1619.845] rdpmouseControl: what 3
[  1619.845] rdpmouseUnInit: drv 0x560cdef99740 info 0x560cdf12e410, flags 0x0
[  1619.845] rdpUnregisterInputCallback: proc 0x7f0f03ea4430
[  1619.846] rdpCloseScreen:
[  1619.846] xorgxrdpDownDown:
[  1619.846] xorgxrdpDownDown: 1
[  1619.847] rdpClientConDeinit:
[  1619.847] rdpClientConDeinit: disconnecting clientCon
[  1619.847] rdpClientConDisconnect:
[  1619.847] rdpRemoveClientConFromDev: removing clientCon 0x560cdf2b4870
[  1619.847] rdpClientConDeinit: deleting file /run/xrdp/sockdir/xrdp_display_12
[  1619.847] rdpClientConDeinit: deleting file /run/xrdp/sockdir/xrdp_disconnect_display_12
[  1619.848] (II) Server terminated successfully (0). Closing log file.

grep WW ,xorgxrdp
   (WW) warning, (EE) error, (NI) not implemented, (??) unknown.
[  1619.128] (WW) The directory "/usr/share/fonts/X11/cyrillic" does not exist.
[  1619.128] (WW) The directory "/usr/share/fonts/X11/100dpi/" does not exist.
[  1619.129] (WW) The directory "/usr/share/fonts/X11/75dpi/" does not exist.
[  1619.129] (WW) The directory "/usr/share/fonts/X11/100dpi" does not exist.
[  1619.129] (WW) The directory "/usr/share/fonts/X11/75dpi" does not exist.
[  1619.147] (WW) Falling back to old probe method for XRDPDEV
[  1619.147] (WW) VGA arbiter: cannot open kernel arbiter, no multi-card support

Not sure why display :12 is used. :10 is for x11 forwarding, :11 probably from an earlier rdp display attempt.
I am using gdm3.
I went ahead and followed https://operavps.com/install-xrdp-on-ubuntu-20/ to circumvent Xsession startup completely by editiing /etx/xrdp/startwm.sh to start xfce4 directly without dm.
That worked. It allowed my to use rdp with krdc. But it may be nicer to avoid that and use the regular Xsession setup. Would lightdm be an alternative ?

By default xrdp-sesman will look for a free display number in the range {10..}. If it can't be sure the display number is free, it skips it and goes on to the next.
In terms of Ubuntu session startup, there's a lot of clever scripting that goes on to try to find the session manager to use. It's all based under /etc/X11, so if you've got an ability to read bash, I'd urge you to look in there, in particular /etc/X11/Xsession.d/50x11-common_determine-startup
TLDR; If you've got an executable file called ~/.xsession, the startup scripts will try to run that to start the session for the user. Otherwise, the scripts will probably try to start whatever /etc/alternatives/x-session-manager is pointing to - this is the system default.
On my 20.04 system which starts GNOME by default:-

$ ls -l /etc/alternatives/x-session-manager
lrwxrwxrwx 1 root root 22 Dec  7  2020 /etc/alternatives/x-session-manager -> /usr/bin/gnome-session

To set the system default to xfce4:-

$ sudo update-alternatives --config x-session-manager
There are 3 choices for the alternative x-session-manager (providing /usr/bin/x-session-manager).

  Selection    Path                    Priority   Status
------------------------------------------------------------
* 0            /usr/bin/gnome-session   50        auto mode
  1            /usr/bin/gnome-session   50        manual mode
  2            /usr/bin/startxfce4      50        manual mode
  3            /usr/bin/xfce4-session   40        manual mode

Press  to keep the current choice[*], or type selection number: 3
update-alternatives: using /usr/bin/xfce4-session to provide /usr/bin/x-session-manager (x-session-manager) in manual mode

Try that, and come back to me.

Thanks. I had looked at /etc/X11/Xsession.d but did not realize that x-session-manager was a symlink. Also, the scripting has a lot of indirection and options.
I restored startwm.sh and used $ sudo update-alternatives --config x-session-manager to select the xfce4-session session manager.
That worked fine !
To summarize, starting from a headless ubuntu install, it is necessary to install a desktop, choose the session manager, and then xrdp:

apt install xfce4 xfce-goodies # ca. 1.3GB, also installs xorg et al., and a lot of gnome, pick lightdm as it is lighter, goodies are optional
update-alternatives --config x-session-manager #pick session manager
apt install xrdp

Reboot not necessary but a good time to test if everything works after a reboot.
Looks simple enough but took a while to figure out. Let me close the issue.

The setup (option 3 above) directly launches the xfce4 desktop. While I prefer that to logging in through a dm, how would one configure to connect a dm first ?

If by dm, you mean something like gdm3 or lightdm, that's not possible I'm afraid. You can use the xrdp login facilities, but they're pretty light on features.

Yes, gdm3 or lightdm. That's ok, thanks.

By default xrdp-sesman will look for a free display number in the range {10..}. If it can't be sure the display number is free, it skips it and goes on to the next.
In terms of Ubuntu session startup, there's a lot of clever scripting that goes on to try to find the session manager to use. It's all based under /etc/X11, so if you've got an ability to read bash, I'd urge you to look in there, in particular /etc/X11/Xsession.d/50x11-common_determine-startup
TLDR; If you've got an executable file called ~/.xsession, the startup scripts will try to run that to start the session for the user. Otherwise, the scripts will probably try to start whatever /etc/alternatives/x-session-manager is pointing to - this is the system default.
On my 20.04 system which starts GNOME by default:-
$ ls -l /etc/alternatives/x-session-manager
lrwxrwxrwx 1 root root 22 Dec  7  2020 /etc/alternatives/x-session-manager -> /usr/bin/gnome-session
To set the system default to xfce4:-
$ sudo update-alternatives --config x-session-manager
There are 3 choices for the alternative x-session-manager (providing /usr/bin/x-session-manager).
Selection    Path                    Priority   Status

0            /usr/bin/gnome-session   50        auto mode
1            /usr/bin/gnome-session   50        manual mode
2            /usr/bin/startxfce4      50        manual mode
3            /usr/bin/xfce4-session   40        manual mode

Press  to keep the current choice[*], or type selection number: 3
update-alternatives: using /usr/bin/xfce4-session to provide /usr/bin/x-session-manager (x-session-manager) in manual mode
Try that, and come back to me.

Could you also share details about Gnome? I get the following after I've left my session idle and come back to it, lets say in 3-4 hours.

update-alternatives --config x-session-manager
provided me with list of installed x-session-managers and once I selected mate (that's what I have got installed), it worked for me.
Thanks for the link (https://github.com/neutrinolabs/xrdp/issues/2293#issuecomment-1169175746) @matt335672