Test Failure: istio-pilot-e2e-envoyv2-v1alpha3-k8s-latest

https://gubernator.k8s.io/build/istio-prow/logs/istio-pilot-e2e-envoyv2-v1alpha3-k8s-latest/832/
Multiple failures, although there are some passing tests as well:
=== RUN   TestGrpc/check/headless
2019-02-12T15:42:04.821720Z	info	Running command kubectl --namespace istio-system logs headless-5d88994854-55rrc -c istio-proxy  --kubeconfig=
2019-02-12T15:42:05.125238Z	error	Got 0 for 1ba42e0b-fe4b-49d5-9bfc-bfd5deb451bb in logs of headless from primary cluster, want 1
2019-02-12T15:42:06.125514Z	info	Running command kubectl --namespace istio-system logs headless-5d88994854-55rrc -c istio-proxy  --kubeconfig=
2019-02-12T15:42:06.502920Z	error	Got 0 for a72bb763-29f0-96ff-a7aa-6c1cc13fda9f in logs of headless from primary cluster, want 1
2019-02-12T15:42:07.503272Z	info	Running command kubectl --namespace istio-system logs headless-5d88994854-55rrc -c istio-proxy  --kubeconfig=
2019-02-12T15:42:07.795914Z	error	Got 0 for ed3914ee-339e-45e2-96a8-e70ffc75c09e in logs of headless from primary cluster, want 1
2019-02-12T15:42:08.796164Z	info	Running command kubectl --namespace istio-system logs headless-5d88994854-55rrc -c istio-proxy  --kubeconfig=
2019-02-12T15:42:09.112282Z	error	Got 0 for 1ba42e0b-fe4b-49d5-9bfc-bfd5deb451bb in logs of headless from primary cluster, want 1
2019-02-12T15:42:10.112646Z	info	Running command kubectl --namespace istio-system logs headless-5d88994854-55rrc -c istio-proxy  --kubeconfig=
--- FAIL: TestGrpc (200.87s)

--- FAIL: TestGrpc (200.87s)
    --- FAIL: TestGrpc/request (193.05s)
        --- FAIL: TestGrpc/request/a_from_primary_cluster->a_70 (10.27s)
        	pilot_test.go:213: try again
        --- FAIL: TestGrpc/request/a_from_primary_cluster->a.istio-system_70 (10.20s)
        	pilot_test.go:213: try again
        --- FAIL: TestGrpc/request/a_from_primary_cluster->a_7070 (10.21s)
        	pilot_test.go:213: try again
        --- FAIL: TestGrpc/request/a_from_primary_cluster->a.istio-system_7070 (10.20s)
        	pilot_test.go:213: try again
        --- FAIL: TestGrpc/request/a_from_primary_cluster->b_70 (10.29s)
        	pilot_test.go:213: try again
        --- FAIL: TestGrpc/request/a_from_primary_cluster->b.istio-system_70 (10.40s)
        	pilot_test.go:213: try again
        --- FAIL: TestGrpc/request/a_from_primary_cluster->b_7070 (55.81s)
        	pilot_test.go:213: try again
        --- FAIL: TestGrpc/request/a_from_primary_cluster->b.istio-system_7070 (10.29s)
        	pilot_test.go:213: try again
        --- FAIL: TestGrpc/request/a_from_primary_cluster->headless_70 (10.41s)
        	pilot_test.go:213: try again
        --- PASS: TestGrpc/request/a_from_primary_cluster->headless.istio-system_70 (36.40s)
        --- PASS: TestGrpc/request/a_from_primary_cluster->headless_7070 (0.51s)
        --- PASS: TestGrpc/request/a_from_primary_cluster->headless.istio-system_7070 (0.47s)
        --- PASS: TestGrpc/request/a_from_primary_cluster->t_70 (0.50s)
        --- PASS: TestGrpc/request/a_from_primary_cluster->t.istio-system_70 (0.53s)
... skipping 101 lines ...
=== RUN   TestHttp/request/t_from_primary_cluster->headless.istio-system_8080
=== RUN   TestHttp/check

There was a lot of repeated messages like this. Not sure if these are benign or not:
2019-02-12T15:39:20.334690Z	error	client request error command failed: "The connection to the server <IP_ADDRESS> was refused - did you specify the right host or port?\n" exit status 1 for grpc://a.istio-system:7070 in a from primary cluster
2019-02-12T15:39:21.438324Z	error	client request error command failed: "The connection to the server <IP_ADDRESS> was refused - did you specify the right host or port?\n" exit status 1 for grpc://a.istio-system:7070 in a from primary cluster
2019-02-12T15:39:22.610192Z	error	client request error command failed: "The connection to the server <IP_ADDRESS> was refused - did you specify the right host or port?\n" exit status 1 for grpc://a.istio-system:7070 in a from primary cluster
2019-02-12T15:39:23.712108Z	error	client request error command failed: "The connection to the server <IP_ADDRESS> was refused - did you specify the right host or port?\n" exit status 1 for grpc://a.istio-system:7070 in a from primary cluster
2019-02-12T15:39:24.813737Z	error	client request error command failed: "The connection to the server <IP_ADDRESS> was refused - did you specify the right host or port?\n" exit status 1 for grpc://a.istio-system:7070 in a from primary cluster
2019-02-12T15:39:25.918024Z	error	client request error command failed: "The connection to the server <IP_ADDRESS> was refused - did you specify the right host or port?\n" exit status 1 for grpc://a.istio-system:7070 in a from primary cluster
2019-02-12T15:39:27.023754Z	error	client request error command failed: "The connection to the server <IP_ADDRESS> was refused - did you specify the right host or port?\n" exit status 1 for grpc://a.istio-system:7070 in a from primary cluster
2019-02-12T15:39:28.213914Z	error	client request error command failed: "The connection to the server <IP_ADDRESS> was refused - did you specify the right host or port?\n" exit status 1 for grpc://a.istio-system:7070 in a from primary cluster
2019-02-12T15:39:29.318571Z	error	client request error command failed: "The connection to the server <IP_ADDRESS> was refused - did you specify the right host or port?\n" exit status 1 for grpc://a.istio-system:7070 in a from primary cluster
2019-02-12T15:39:30.424176Z	error	client request error command failed: "The connection to the server <IP_ADDRESS> was refused - did you specify the right host or port?\n" exit status 1 for grpc://a.istio-system:7070 in a from primary cluster

@nmittler, looking at the TestGrpc history, it looks like you might be familiar with these tests. Any chance you can take a quick look and see what is going wrong?

@howardjohn can you take a look?

Yep, I'll look at it now

These "try again" failures are quite irritating.  Just got them for https://k8s-gubernator.appspot.com/build/istio-prow/pr-logs/pull/istio_istio/11734/istio_auth_sds_e2e/1933 as well.  Any interest in a better error description?

Looking at the failing tests, one thing I have seen in common is often we are failing to connect to the kubernetes cluster. Example on line 1068:
error: error when deleting "testdata/networking/v1alpha3/service-entry-google.yaml": Delete https://<IP_ADDRESS>/apis/networking.istio.io/v1alpha3/namespaces/istio-system/serviceentries/service-entry-google: dial tcp <IP_ADDRESS>:443: getsockopt: connection refused

It looks like this results in things not being cleaned up. Maybe this is affecting later tests.

For the istio_auth_sds_e2e tests, it looks like the main tests are actually passing, and what is failing is the "log check", where it reads through the logs to check for the requests. These are failing every time, not flaky.
It seems like perhaps the logging was changed such that these requests are no longer logged, causing the failures.

I am seeing the same failure as https://github.com/istio/istio/issues/11929
ingressgateway_test.go:258: Got non 200 status code while changing rules: map[200:499 503:1]

For example https://k8s-gubernator.appspot.com/build/istio-prow/pr-logs/pull/istio_istio/12159/istio-pilot-e2e-envoyv2-v1alpha3/16111
We don't know if the 503 was the first problem, the last problem, or occurred somewhere in the middle.  The test code tests/e2e/tests/pilot/ingressgateway_test.go knows the sequence but doesn't report it.
I will create a small PR to get more information about this problem.

I created a test PR to see if the 503 was appearing at the beginning.  It is not.  It appears in the middle:
The test got 451 200s, then a 503, then 48 200s.
https://k8s-gubernator.appspot.com/build/istio-prow/pr-logs/pull/istio_istio/12207/istio-pilot-e2e-envoyv2-v1alpha3/16225
Here is the failure from https://storage.googleapis.com/istio-prow/pr-logs/pull/istio_istio/12207/istio-pilot-e2e-envoyv2-v1alpha3/16225/artifacts/pilot-test-c3c015e66e654900a3a29997f3/istio-ingressgateway-69bf5f7b6d-k6j7h_container:istio-proxy.log with the request before and afterward
[2019-03-02T23:41:39.882Z] "GET /c HTTP/1.1" 200 - "-" 0 460 1 1 "<IP_ADDRESS>" "Go-http-client/1.1" "bdf14e6c-a368-4c51-9cf7-8a50bb0d42d0" "uk.bookinfo.com" "<IP_ADDRESS>:80" outbound|80|v3|c.istio-system.svc.cluster.local - <IP_ADDRESS>:80 <IP_ADDRESS>:53104 -
[2019-03-02T23:41:39.932Z] "GET /c HTTP/1.1" 503 UC "-" 0 57 0 - "<IP_ADDRESS>" "Go-http-client/1.1" "eedcd241-00e7-4b64-b0bc-bd14100757c7" "uk.bookinfo.com" "<IP_ADDRESS>:80" outbound|80|v3|c.istio-system.svc.cluster.local - <IP_ADDRESS>:80 <IP_ADDRESS>:53104 -
[2019-03-02T23:41:39.982Z] "GET /c HTTP/1.1" 200 - "-" 0 460 5 4 "<IP_ADDRESS>" "Go-http-client/1.1" "1109a36b-116c-4818-8f14-25785b761f32" "uk.bookinfo.com" "<IP_ADDRESS>:80" outbound|80|v3|c.istio-system.svc.cluster.local - <IP_ADDRESS>:80 <IP_ADDRESS>:53104 -

According to https://www.envoyproxy.io/docs/envoy/latest/configuration/access_log#default-format-string "UC" means "Upstream connection termination in addition to 503 response code.".
I also checked out the server logs.  The requests before the 503 show up both in the c-v1 and v-v2 logs.  Around the 503 the calls were handled by V2, V2, V1, 503, V1, V2.  This suggests that both V1 and V2 were alive and healthy at the time the 503 happened.
I ran the same test case using my Macbook against IBM ICS for three hours and had no failures.  It was taking about 5 minutes a test so perhaps 0 failures out of 60 runs.  Prow and CircleCI seem to be failing this test about 5% of the time.  No clue why.

Could the 503s be related to https://github.com/istio/istio/issues/12183 ?

I correlated the 503 to the progress of the test.
https://storage.googleapis.com/istio-prow/pr-logs/pull/istio_istio/12207/istio-pilot-e2e-envoyv2-v1alpha3/16225/build-log.txt
Before the 503 we had deployed rule-503test-destinationrule-c-add-subset.yaml which defines subsets v1,v2,v3,v4 (but v3 and v4 point at v1 and v2 so only two pods are involved.  rule-503test-update-virtualservice.yaml ensures traffic is routed only to v3,v4.
Then we apply rule-503test-destinationrule-c-del-subset.yaml to eliminate the definitions of v1 and v2.
2 seconds later the 503 occurs.
I will dig into the event stream ... Perhaps a bug of applying a change to a DR leaves a small period in which there are no subsets for a host.

I watched the Envoy logs as I modified a DestinationRule.  I saw a 2ms delay between when it logs “gRPC config for type.googleapis.com/envoy.api.v2.Cluster accepted with 82 resources” and when it logs “gRPC config for type.googleapis.com/envoy.api.v2.ClusterLoadAssignment” with the IP and weight of the cluster.
2ms seems very tiny but the test case hits the server every 50ms.  If there is a 2ms delay before the subset is configured it would mean a 4% failure rate … which is in the ballpark for what I am seeing on this test.
Suppose when Envoy receives the 82 new resources it throws away or somehow forgets the IP addresses or weights of existing clusters?
I would hope that the IP addresses and weights of the cluster is in the same packet as the list of resources but perhaps it is in the next packet, or perhaps the code that processes the packet is blocked before assigning weights to the revised clusters.
Perhaps Envoy can’t route to a cluster until it has received a ClusterLoadAssignment?

Could https://github.com/envoyproxy/envoy/issues/6252 be the cause of the 503?

In addition to the 503s I am now seeing it fail because it runs out of time.  https://k8s-gubernator.appspot.com/build/istio-prow/pr-logs/pull/istio_istio/12675/istio-pilot-e2e-envoyv2-v1alpha3/16953#istioioistiotestse2etestspilot-testhttprequest reports after running === RUN   TestHttp/request/a_from_primary_cluster->b_8080:
*** Test killed with quit: ran too long (26m0s).

The last 5 failures:
https://prow.k8s.io/view/gcs/istio-prow/logs/istio-pilot-e2e-envoyv2-v1alpha3-k8s-latest-master/240 - boskos/mason infra issue
https://prow.k8s.io/view/gcs/istio-prow/logs/istio-pilot-e2e-envoyv2-v1alpha3-k8s-latest-master/241
Appears to be a legitimate issue with TestGateway_HTTPSIngress. Connections are consistently refused from that point on, but there is nothing in the logs in ingress gateway or pilot that indicates a problem. I think I'll need someone from networking team to look deeper into this to find a clue.
https://prow.k8s.io/view/gcs/istio-prow/logs/istio-pilot-e2e-envoyv2-v1alpha3-k8s-latest-master/245
mason/boskos flake: /home/prow/go/src/istio.io/istio/prow/mason_lib.sh: line 21: kill: (1586) - No such process
https://prow.k8s.io/view/gcs/istio-prow/logs/istio-pilot-e2e-envoyv2-v1alpha3-k8s-latest-master/251
gcr.io flake: Your client has taken too long to issue its request.
https://prow.k8s.io/view/gcs/istio-prow/logs/istio-pilot-e2e-envoyv2-v1alpha3-k8s-latest-master/252
*** Test killed with quit: ran too long (26m0s).

The test looks very much green to me. Please re-open if it starts flaking again.


Feedback: No category for OSS Complliance Management tooling

Some feedback about the CDF Landscape was raised as part of the SwampUP days.
Specifically the lack of categorisation for tools such as white source, blackduck, etc.
I'm happy to create some pull requests, but wanted to check here on a couple of points:

Should we look to have these tools on the CDF Landscape ?
Should we create a new category for them ( specifically point 3 under new entries 'We are unlikely to create a new category for projects as we'd rather find the best home with the current options.' )
What should that category be called if we do create one

I feel like there is value in having these tools on the landscape, and potentially a new category for them. Although I'm not sure on the naming (OSS Compliance Management doesn't feel quite right )
Would be great to get some feedback on it.

Would love to chat about this during the next landscape meeting too


Add state regenerator

IStateRegenerator interface has been added, along with implementations StateRegenerator and QueuedStateRegenerator, - src/chain/regen/

it can regenerate states from blocks that have already been processed , given forkChoice, stateCache, checkpointStateCache, and db.blocks
it intelligently attempts to perform the smallest amount of regeneration necessary to regen the requested state. To that end, it exposes 4 different methods.
it reuses some block processing machinery (emitCheckpointEvent, runStateTransition) so as to enable re-seeding the checkpoint cache (using the emitted events)
it throws a RegenError with well-defined error codes and types, this allows us to tighten the interface to disallow nulls.
it queues requests, one regeneration allowed at a time
getPreState(block: BeaconBlock): Promise<ITreeStateContext> - similar to getPreState that we were using in our block processor. It can request a more recent checkpoint state if the block occurs after many skip-slots, skipping epoch transitions :)
getCheckpointState(cp: Checkpoint): Promise<ITreeStateContext> - returns the checkpoint state. It minimizes regeneration by first searching the checkpoint cache for checkpoint states with cp.root, which may then just be processSlotsed. Otherwise regens the 'ol-fashioned way', by state root.
getBlockSlotState(blockRoot: Root, slot: Slot): Promise<ITreeStateContext> - returns the block state at the requested slot. This is a lot like getCheckpointState, but more flexible, especially useful for dealing with the head state, eg: regen.getBlockSlotState(forkChoice.getHeadRoot(), clock.currentSlot). This is nice, because in periods of skip slots, we will only process the checkpoint with the blockRoot once.
getState(stateRoot: Root): Promise<ITreeStateContext> - returns the state whose root is stateRoot. This is where the actual block replay happens. It iterates backwards thru the block tree from the requested state, to the first state that we have cached, (searching the checkpointStateCache as well!), then replaying the blocks that were iterated thru to the requested state, once a state has been found.

e2e still failing :( seems attestations can't be produced in some cases
2020-09-24 23:34:54  [VALIDATOR 0-8]   error: Failed to produce attestation slot=95, committee=0, error=Failed to obtain attestation at slot 95 and committee 0: Validator not in given committee

oh man, linting error :(

failing unit test :rofl:


bugfix: find_regions ranks result

fixes #103

Codecov Report

Merging #117 (91b7c97) into main (2aa1bc0) will increase coverage by 0.13%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##             main     #117      +/-   ##
==========================================
+ Coverage   48.69%   48.82%   +0.13%
==========================================
  Files          27       27
  Lines        3025     3027       +2
==========================================
+ Hits         1473     1478       +5
+ Misses       1552     1549       -3

Impacted Files
Coverage Δ

siibra/core/parcellation.py
61.27% <100.00%> (+1.62%)
:arrow_up:

siibra/core/region.py
45.54% <0.00%> (+0.34%)
:arrow_up:

Continue to review full report at Codecov.

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


Build: Action updates

Upload artifacts

Originally I tried bumping the .NET SDK. With latest 2.1 (2.1.818, still out of support), I got test failures:
Microsoft.Build.Exceptions.InvalidProjectFileException: The imported project "/home/runner/.dotnet/sdk/2.1.818/15.0/Microsoft.Common.props" was not found. Confirm that the path in the <Import> declaration is correct, and that the file exists on disk.  /home/runner/.dotnet/sdk/2.1.818/Sdks/Microsoft.NET.Sdk/Sdk/Sdk.props

With .NET 5 or 6, I got restore errors like:
/usr/local/share/dotnet/sdk/5.0.403/NuGet.targets(131,5): error : Invalid framework identifier ''. [/Users/sandy/xam-git/mirepoix/mirepoix.proj]

With 3.1.415, I got restore errors like:
/usr/local/share/dotnet/sdk/3.1.415/NuGet.targets(128,5): error : Value cannot be null. (Parameter 'folderName') [/Users/sandy/xam-git/mirepoix/mirepoix.proj]

Anyway, this worked out, the Actions-based build now uploads artifacts. See https://github.com/xamarin/mirepoix/actions/runs/1482465895:


feat(data): All dashboard color token VALUES have been updated to mee…

All dashboard color token VALUES have been updated to mee...t accessibility requirements.
PLUS: Dashboard Gap color tokens: Add “fill-1”. Rename “fill” to “fill-2”
PLUS: Refactor code to move origin tokens above base tokens.

:tada: This PR is included in version 4.13.0 :tada:
The release is available on:

npm package (@latest dist-tag)
GitHub release

Your semantic-release bot :package::rocket:


Add note about CRAN release [skip ci]

Hi @hetong007 , could you please take a look and fill in the blanks when you are available?  Next time I can do more thorough checks before tagging a release. ;-)

Thanks for the notes. I think r-hub and win-builder are sufficient and they have covered almost all submission tests in the previous releases. This time, the reverse-dependency is kinda tricky and infeasible to check on our side (at least I don't know a convinient way) for every release, unless it has significant breaking changes.

Excellent!  I will continue working on the reverse dependecies.


Startup-script doesn't work with python file

Hi all,
I'm trying to create startup script in Compute Engine - in directly way when create VM instance, I want to run command just like in SSH command line. Here my startup script:
#!/bin/bash
sudo python3 /home/minhngc4795/test.py

Here is my test.py file, I want to write line "test" to test.txt file in folder:
#!/usr/bin/python3
file = open("test.txt","w")
file.write("test")
file.close()

When I start VM instance and check /var/log/syslog, it doesn't return error code or anything, just return 0
Sep  7 10:18:18 startupscript systemd[1]: Starting Google Compute Engine Startup Scripts...
Sep  7 10:18:18 startupscript startup-script: INFO Starting startup scripts.
Sep  7 10:18:18 startupscript startup-script: INFO Found startup-script in metadata.
Sep  7 10:18:18 startupscript startup-script: INFO startup-script: Return code 0.
Sep  7 10:18:18 startupscript startup-script: INFO Finished running startup scripts.

But nothing happens in my folder. I try to figure it out but nothing come up. Pls help me, thks a lot.
I'm using Ubuntu 16.04.5 LTS

Startup scripts can be python scripts or any other interpreter. I suggest you just use your test.py script as the startup script and don't try to call a script that may or may not exist.

Startup scripts run as root, so you shouldn't be calling sudo. By calling sudo you are creating a new shell and your script likely won't run in the way you expect.

If you log into a VM, you can test out your startup script by running the following command:
sudo /usr/bin/google_metadata_script_runner --script-type=startup --debug

Thks all, but nothing change. The output is still same, I used python code as startup and didn't use sudo.
Return from sudo /usr/bin/google_metadata_script_runner --script-type=startup --debug:
startupscript systemd[1]: Starting Google Compute Engine Startup Scripts...
startupscript startup-script: INFO Starting startup scripts.
startupscript startup-script: INFO Found startup-script in metadata.
startupscript startup-script: INFO startup-script: Return code 0.

Thanks @gut! Closing this off.

no problem. I hope this is exactly the problem @minhthehash . Please confirm if otherwise.

Great! Have fun then.


release automation: add default PR search for start-release

Description
start-release gave an empty [PR]() link
https://github.com/stackrox/stackrox/actions/runs/3016841701#summary-8254641794
I don't know why it was empty because it did create the PR (https://github.com/stackrox/stackrox/pull/3013). Could the script provide a search to find the PR if we do not get a PR link from creating it?

The PR is not created, as it was a dry-run. For real run the PR link will be there.


Implement PriceByGroup

Pretty sure this fails at runtime. Have you tested it on your device?

I'm not sure. When I run it, there is an error in android studio "unable to determine activity name". Don't know what it means, but the widget works.

Also: Not quite sure the prices should be Float.
We get them as String, are there good reasons to change that?
Currency conversion will never come, since it does not make sense in this use case.
Wouldn't we be parsing the String to Floats just to reformat them afterwards for a text field?

I think it's better to have the raw data in the right format, because that's what is expectable. If you get the prices as float, you are also completely free to choose how you want to display them (point instead of comma, with or without € etc).

I have this feeling that now you just wanted to prove something 🤨😂 My floats would have worked much better there, but well, it'll do. xD

I misunderstood the whole thing! Missed the attached issue 🤦

We could remove the price from Meal class now ^^


SpanScalingInsufficientData insight is unmapped

SpanScalingWell insight is not mapped as well

Duplicate of https://github.com/digma-ai/digma-intellij-plugin/issues/1210


DiagnosticSource.BeforeView/AfterView not called in RenderPartial

I was trying to move from wrapped views to DiagnosticSource for MVC profiling in ASP.NET Core, but I've come across a major difference in behavior.
Currently, DiagnosticSource.BeforeView and .AfterView are called for regular views (here):
DiagnosticSource.BeforeView(view, viewContext);

await view.RenderAsync(viewContext);

DiagnosticSource.AfterView(view, viewContext);

Compared to the RenderPartial (and Async, etc.) pipeline (here):
await viewEngineResult.View.RenderAsync(viewContext);

...it's not wrapped in DiagnosticSource. The result is that instead of a rich profiling tree I can narrow issues down in like this:

The best I can get is:

Was this an intentional decision?

If so: why?
If not: can I submit a PR to add the .BeforeView and .AfterView calls?

Was this an intentional decision?

We've only implemented DiagnosticSource eventing when/where someone has specifically asked for it 😆. I see no reason why we can't fix this.
What's your proposal for the details of the event?
@Eilon - opinion on a breaking change to https://github.com/aspnet/Mvc/blob/8f8bf5af341b5cc07e0611dc9a3a02e471e2bf63/src/Microsoft.AspNetCore.Mvc.ViewFeatures/ViewFeatures/HtmlHelper.cs#L42 to add the DiagnosticSouce as an additional constructor arg?

What's your proposal for the details of the event?

I'd expect it (naively) to call BeforeView with the same args as exist today - but if for some reason a BeforePartialView is desired...I don't suppose it matters much either way.

@rynowak I'm ok with a breaking change to this, though we can also do it without a breaking change by adding a 2nd ctor that has the extra param, and have the current ctor chain to the new one. I'm fine either way.

I feel like since this is 2.0.0 we might as well go ahead and add the extra arg. This is the default implementation of the IHtmlHelper<> and it's almost always created by DI.

@NickCraver - It looks like the existing code gives BeforeView/AfterView for both partials and views when they are returned from a controller - so yeah let's just keep using those.
Feel free to send a PR.

Implemented in #6386, closing out to cleanup.


Is it possible to realize weighted machine learning on Qlib?

❓ Questions and Help
I want to give different weights to each stock based on market value, and  train the lightGBM model with the samples and their weights. But it seems troublesome for me to realize weighted machine learning under the framework of Qlib.
If I can get the weight for each stock outside Qlib, is it possible to realize weighted machine learning on Qlib?
I think I should modify codes in Qlib.contrib.model?
Thanks!

@JessieJie1998
Hi, it is possible to train model with weighted samples in Qlib.
Here is an example from my personal code base.

The weights are stored as a column in the dataset.
You can follow this example.
We may release examples with weighted samples in the future.

@you-n-g Thanks for your prompt reply


Fix CI for notebook testing

Description

Limit testing to only notebooks that we are going to fully support.
Related Issues

Checklist

[ ] Is this code covered by new or existing unit tests or integration tests?
[ ] Did you run make test successfully?
[ ] Do new classes, functions, methods and parameters all have docstrings?
[ ] Were existing docstrings updated, if necessary?
[ ] Was external documentation updated, if necessary?

Additional Notes or Comments

Codecov Report
Attention: 44 lines in your changes are missing coverage. Please review.

Comparison is base (cbe6b32) 78.22% compared to head (8094019) 81.01%.
Report is 61 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1105      +/-   ##
==========================================
+ Coverage   78.22%   81.01%   +2.79%
==========================================
  Files         101       98       -3
  Lines        6351     6400      +49
==========================================
+ Hits         4968     5185     +217
+ Misses       1383     1215     -168

Files
Coverage Δ

superduperdb/__init__.py
100.00% <100.00%> (ø)

superduperdb/__main__.py
71.42% <100.00%> (ø)

superduperdb/container/component.py
82.92% <100.00%> (+2.92%)
:arrow_up:

superduperdb/container/encoder.py
89.83% <100.00%> (ø)

superduperdb/container/serializable.py
97.95% <100.00%> (+2.83%)
:arrow_up:

superduperdb/db/filesystem/artifacts.py
75.86% <100.00%> (ø)

superduperdb/db/mongodb/artifacts.py
80.00% <100.00%> (ø)

superduperdb/server/client.py
75.18% <100.00%> (-0.18%)
:arrow_down:

superduperdb/server/server.py
83.05% <100.00%> (-0.15%)
:arrow_down:

superduperdb/container/artifact.py
96.36% <92.85%> (-1.51%)
:arrow_down:

... and 9 more

... and 6 files with indirect coverage changes

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

Description
Limit testing to only notebooks that we are going to fully support.
Related Issues
Checklist

[ ]  Is this code covered by new or existing unit tests or integration tests?
[ ]  Did you run make test successfully?
[ ]  Do new classes, functions, methods and parameters all have docstrings?
[ ]  Were existing docstrings updated, if necessary?
[ ]  Was external documentation updated, if necessary?

Additional Notes or Comments

Let us run this check nightly?


Ollama windows version not working

It was working fine even yesterday, but I got an update notification and it hasn't been working since. I even tried deleting and reinstalling the installer exe, but it seems the app shows up for a few seconds and then disappears again, but powershell still recognizes the command - it just says ollama not running.

@sdrshn-nmbr check Windows Defender, the current version has signature issue because of that Defender is treating it as a Trozen and removes the file. You can download a new copy and install it, and when defender alert pops, you can Whitelist the file.

That worked @adminazhar thanks!


Only date shown, not version

The appdata of this app contains a release entry with the version attribute only:
https://github.com/flathub/io.designer.GravitDesigner/blob/master/io.designer.GravitDesigner.appdata.xml
But on the Flathub website, only a date is shown:
https://flathub.org/apps/details/io.designer.GravitDesigner

It seems to work so far.


1 item in disk storage, can't remove it

Issue description:
Disk says there's one item in it, no item found, can't remove it.
What happens:
I've got one item in my disk. No idea how that item got there, can't remove it when I place only this disk in a drive, a network with only this disk doesn't show any items.
What you expected to happen:
the item to show up or the network to remove it if it's not valid.
Steps to reproduce:
No idea how it got there and when.
Version (make sure you are on the latest version before reporting):

Minecraft: 1.12.2
Forge: <IP_ADDRESS>24
Refined Storage: refinedstorage-1.5.32

Does this issue occur on a server? singleplayer, no way to reproduce on a server
Screenshot with NBT data from the disk with the item

#908


TWSF: Add twitter API integration

On user request, search the #thisweeksf hashttag as well as @orbitalpodcast DMs and collect new tweets/messages that have appeared.
Be sure to ignore bots. If the tweet full text begins with "RT @", it's no good.
Associate tweet/message with user. Store user id, name, screen name, full text, and URL.

See #38.


 It would be handy if it would simply let the original operation complete, or, if there were some easy way to get the list of operations in progress as a user.

#883 should fix this


Fixed #34180 -- Added note ref resetting language in test tear-downs.

Fixed #34180 -- Wrote addition to docs to address a bug.
Added an explanation about a bug that changes the active language in subsequent tests when the test language is by using a cookie or HTTP header

@fnaimi66 Do you have time to keep working on this?

Updated in #16510.


Download/Save fails if outputs have been added

Thank you for this great utility.
Unfortunately, I can't get onnx-modifier to save a model if one or more outputs have been added. Other features work
as expected though (deleting nodes, etc.).
To reproduce:

Load squeezeNet (link provided in the help)
Select any node, like for instance: GlobalAveragePool
Add output (pool10_1)
Download/Save = Error

Log:
~~~
[2023-05-17 12:39:12,355] ERROR in app: Exception on /download [POST]
Traceback (most recent call last):
  File "/usr/local/lib/python3.6/dist-packages/flask/app.py", line 2073, in wsgi_app
    response = self.full_dispatch_request()
  File "/usr/local/lib/python3.6/dist-packages/flask/app.py", line 1518, in full_dispatch_request
    rv = self.handle_user_exception(e)
  File "/usr/local/lib/python3.6/dist-packages/flask/app.py", line 1516, in full_dispatch_request
    rv = self.dispatch_request()
  File "/usr/local/lib/python3.6/dist-packages/flask/app.py", line 1502, in dispatch_request
    return self.ensure_sync(self.view_functions[rule.endpoint])(**req.view_args)
  File "app.py", line 27, in modify_and_download_model
    onnx_modifier.modify(modify_info)
  File "/root/onnx-modifier/onnx_modifier.py", line 362, in modify
    self.add_outputs(modify_info['added_outputs'])
  File "/root/onnx-modifier/onnx_modifier.py", line 201, in add_outputs
    shape_info = onnx.shape_inference.infer_shapes(self.model_proto)
AttributeError: module 'onnx' has no attribute 'shape_inference'

I actually solved the issue. The problem was with the version # of the onnx python package.
Maybe requirement.txt should be added with the min. version numbers to avoid this issue.
Thank you.


CalculateUACoeffs fails when iLow2 == iHigh2

Bug description

The CalculateUACoefficients subroutine was modified in 030500ef2b402273c90853b01151e75b610b1e11 and the subroutine Calculate_C_alpha was added. Under some circumstances, the indices determined in this subroutine, iLow2 and iHigh2, are set to the same value. This seems to occur if min(Cd) is not close to alpha = 0. The logic used to determine alphaLower and alphaUpper results in a single point being passed to Calculate_C_alpha which requires at least two points to be provided to perform a linear curve fit. In Debug mode this results in a bounds access error in Calculate_C_alpha. In Release mode, no warning is produced though I'm not sure how the curve fit is successful.
To Reproduce

Steps to reproduce the behavior:

Compile the dev branch in Debug
Run any of the following regression tests:

AWT_YFix_WSt
AWT_WSt_StartUp_HighSpShutDown
AWT_YFree_WTurb
UAE_Dnwind_YRamp_WSt
WP_VSP_WTurb_PitchFail
SWRT_YFree_VS_EDG01

Program exits with the array bound mismatch error shown below

Expected behavior

Simulation runs to completion.
Screenshots, if applicable

This is the backtrace produced by gfortran
Output:
----------------------------------------------------------
At line 1187 of file /projects/openfast.worktrees/dev/modules/aerodyn/src/AirfoilInfo.f90
Fortran runtime error: Array bound mismatch for dimension 1 of array 'b' (2/1)

Error termination. Backtrace:
#0  0xffffaec9d08b in ???
#1  0xffffaec9ddb3 in ???
#2  0xffffaec9e2e7 in ???
#3  0xaaaae177686f in calculate_c_alpha
	at /projects/openfast.worktrees/dev/modules/aerodyn/src/AirfoilInfo.f90:1187
#4  0xaaaae177d3b3 in calculateuacoeffs
	at /projects/openfast.worktrees/dev/modules/aerodyn/src/AirfoilInfo.f90:1065
#5  0xaaaae178aa6b in readaffile
	at /projects/openfast.worktrees/dev/modules/aerodyn/src/AirfoilInfo.f90:757
#6  0xaaaae178c4f7 in __airfoilinfo_MOD_afi_init
	at /projects/openfast.worktrees/dev/modules/aerodyn/src/AirfoilInfo.f90:146
#7  0xaaaae0f32c07 in init_afiparams
	at /projects/openfast.worktrees/dev/modules/aerodyn/src/AeroDyn.f90:4376
#8  0xaaaae1038193 in __aerodyn_MOD_ad_init
	at /projects/openfast.worktrees/dev/modules/aerodyn/src/AeroDyn.f90:380
#9  0xaaaadff5f6a7 in __fast_subs_MOD_fast_initializeall
	at /projects/openfast.worktrees/dev/modules/openfast-library/src/FAST_Subs.f90:769
#10  0xaaaadffc0bb3 in __fast_subs_MOD_fast_initializeall_t
	at /projects/openfast.worktrees/dev/modules/openfast-library/src/FAST_Subs.f90:66
#11  0xaaaadfe6d33f in fast
	at /projects/openfast.worktrees/dev/glue-codes/openfast/src/FAST_Prog.f90:97
#12  0xaaaadfe6e237 in main
	at /projects/openfast.worktrees/dev/glue-codes/openfast/src/FAST_Prog.f90:34
/projects/openfast.worktrees/dev/build/glue-codes/openfast/openfast /projects/openfast.worktrees/dev/build/reg_tests/glue-codes/openfast/AWT_YFix_WSt/AWT_YFix_WSt.fst  > /projects/openfast.worktrees/dev/build/reg_tests/glue-codes/openfast/AWT_YFix_WSt/AWT_YFix_WSt.log
COMPLETE with code 2
<end of output>

OpenFAST Version

dev branch commit 853ba8ca9f82d8bf1552638f9fa82af750750952
 **************************************************************************************************
 OpenFAST

 Copyright (C) 2024 National Renewable Energy Laboratory
 Copyright (C) 2024 Envision Energy USA LTD

 This program is licensed under Apache License Version 2.0 and comes with ABSOLUTELY NO WARRANTY.
 See the "LICENSE" file distributed with this software for details.
 **************************************************************************************************

 OpenFAST-dev
 Compile Info:
  - Compiler: GCC version 11.4.0
  - Architecture: 64 bit
  - Precision: double
  - OpenMP: No
  - Date: Oct  4 2024
  - Time: 20:10:17
 Execution Info:
  - Date: 10/04/2024
  - Time: 20:18:07+0000

System Information (please complete the following information):

OS: Ubuntu 22.04
Compiler: gfortran 11.4.0
Compiler settings: -DCMAKE_BUILD_TYPE=Debug

Additional context

@bjonkman do you have any insights?

Yes, we should add some logic to check that there are at least 2 points sent to this routine.
I think some of this problem comes from the airfoils having a fairly coarse discretization in the -20 to 20 degree range. Our assumption that there are sufficient points in that range may not be valid.
The file that is causing issues in the AWT model looks like this:

@deslaughter, have we resolved this?

Yes, it's been resolved enough that it doesn't cause segfaults. Further exploration of the calculation of unsteady aero parameters from the polars would be good, but this shouldn't hold up the release.


500 Error when saving IP Address when SLAAC status does not exist.

Environment

Python version: 3.6
Nautobot version: 1.1.4

Steps to Reproduce

Delete SLAAC status from Nautobot
Attempt to create an IP address (IPv4/IPv6)
Receive a 500 error

Expected Behavior
The IP address gets created successfully

Observed Behavior
2021-10-27 15:38:14,189 ERROR [django.request:230] log 30452<PHONE_NUMBER>77184 Internal Server Error: /ipam/ip-addresses/add/
Traceback (most recent call last):
  File "/opt/nautobot/lib64/python3.6/site-packages/django/core/handlers/exception.py", line 47, in inner
    response = get_response(request)
  File "/opt/nautobot/lib64/python3.6/site-packages/django/core/handlers/base.py", line 181, in _get_response
    response = wrapped_callback(request, *callback_args, **callback_kwargs)
  File "/opt/nautobot/lib64/python3.6/site-packages/django/views/generic/base.py", line 70, in view
    return self.dispatch(request, *args, **kwargs)
  File "/opt/nautobot/lib64/python3.6/site-packages/nautobot/core/views/generic.py", line 266, in dispatch
    return super().dispatch(request, *args, **kwargs)
  File "/opt/nautobot/lib64/python3.6/site-packages/nautobot/utilities/views.py", line 94, in dispatch
    return super().dispatch(request, *args, **kwargs)
  File "/opt/nautobot/lib64/python3.6/site-packages/django/views/generic/base.py", line 98, in dispatch
    return handler(request, *args, **kwargs)
  File "/opt/nautobot/lib64/python3.6/site-packages/nautobot/core/views/generic.py", line 293, in post
    if form.is_valid():
  File "/opt/nautobot/lib64/python3.6/site-packages/django/forms/forms.py", line 177, in is_valid
    return self.is_bound and not self.errors
  File "/opt/nautobot/lib64/python3.6/site-packages/django/forms/forms.py", line 172, in errors
    self.full_clean()
  File "/opt/nautobot/lib64/python3.6/site-packages/django/forms/forms.py", line 376, in full_clean
    self._post_clean()
  File "/opt/nautobot/lib64/python3.6/site-packages/django/forms/models.py", line 405, in _post_clean
    self.instance.full_clean(exclude=exclude, validate_unique=False)
  File "/opt/nautobot/lib64/python3.6/site-packages/django/db/models/base.py", line 1216, in full_clean
    self.clean()
  File "/opt/nautobot/lib64/python3.6/site-packages/nautobot/extras/plugins/validators.py", line 20, in wrapper
    model_clean_func(model_instance)
  File "/opt/nautobot/lib64/python3.6/site-packages/nautobot/ipam/models.py", line 891, in clean
    if self.status == IPAddress.STATUS_SLAAC and self.family != 6:
  File "/opt/nautobot/lib64/python3.6/site-packages/django/utils/functional.py", line 61, in _get_
    return self.fget(cls)
  File "/opt/nautobot/lib64/python3.6/site-packages/nautobot/ipam/models.py", line 848, in STATUS_SLAAC
    cls.__status_slaac = Status.objects.get_for_model(IPAddress).get(slug="slaac")
  File "/opt/nautobot/lib64/python3.6/site-packages/cacheops/query.py", line 353, in get
    return qs._no_monkey.get(qs, *args, **kwargs)
  File "/opt/nautobot/lib64/python3.6/site-packages/django/db/models/query.py", line 431, in get
    self.model._meta.object_name

Related to #1169


[Incident] OpenScapes unauthenticated users and CPU usage spike

Summary
Over the past 2 weeks there has been a spike in usage of the OpenScapes hub. User pods have been increasingly steadily over time. Because nodes scale with users on a 1-1 ratio, this has resulted in a large spike in nodes as well.
Hub information

Hub URL: openscapes.2i2c.org

Timeline (if relevant)
All times in US/Pacific
2021-01-02 11:00AM
OpenScapes emails 2i2c support saying that they've gotten an extremely large AWS bill for December.
They reported several users who they did not add to the hub, and who had GitHub accounts created in the last 2 weeks.
The hub was shut down as a precautionary measure.
12:01pm
A look at the grafana logs showed that around the 21st the hub users started going up steadily:

It seems like many of these users were maxing out the CPU:

Though the plot for users with high CPU usage is broken so this is hard to confirm:

EDIT: the users have mining software in their filesystems:

12:40pm
Found the reason that unauthorized users can access:
Any github user that logs into this hub is authorized. A new GitHub account was created from scratch, and attempted to log-in, and was able to do so successfully despite not being added to the hub's user list.
Noticed that the openscapes hub does not explicitly have an allowed_usersconfig set:

here's the 2i2c gke hub
https://github.com/2i2c-org/infrastructure/blob/b6ab94a3e029a4418e137a434b69d3db1999f96e/config/hubs/2i2c.cluster.yaml#L90-L96

here's the openscapes hub
https://github.com/2i2c-org/infrastructure/blob/b6ab94a3e029a4418e137a434b69d3db1999f96e/config/hubs/openscapes.cluster.yaml#L149-L154

21:00
The hub is made inaccessible via this PR: https://github.com/2i2c-org/infrastructure/pull/911
21:25
Corrected the configuration to properly authorize users: https://github.com/2i2c-org/infrastructure/commit/2449ab1b4bdcda7c35ae0c87c2f832fcc0abe85f
Also deleted all of the users on the hub, so they will need to be manually added back in.

After-action report
There are two major takeaways from this incident:

We need some kind of automated cost reporting infrastructure to account for runaway costs like this.
We need better testing infrastructure to make sure that basic failure modes aren't present (like anybody being able to access a hub regardless of authorization)

What went wrong

We were not alerted to this increased usage + CPU maxing out when it happened. Because nobody was actively paying attention to the cluster, we only learned about this when the AWS bill came in.
We had no automated checks for whether our authentication was working properly, and so did not detect that any github user was allowed in.
There is no easy (or documented) way for a hub administrator to restrict access to all users of the hub, so we are constrained to do this by manually shutting down hub users until somebody with cluster access can restrict the whole hub
Automatic deploys for AWS did not work when we merged in a PR to fix this

We had a PR open to automate this, it had 2 approvals, but it had not been merged at the time: https://github.com/2i2c-org/infrastructure/pull/885

Where we got lucky
The OpenScapes team checked their bill relatively quickly, otherwise we would have incurred significant extra cloud cost. They were on track to spend $20,000 in January alone.
Action items
Process improvements

https://github.com/2i2c-org/infrastructure/issues/913

Documentation improvements

PR to instruct hub admins how to restrict access to their hub via the UI: https://github.com/2i2c-org/pilot/pull/119
{{ summary }} [link to github issue]

Technical improvements

https://github.com/2i2c-org/infrastructure/pull/885 is merged
We've already got an issue to build cost reporting infrastructure, we should probably focus a bit of attention on this to get an MVP: https://github.com/2i2c-org/infrastructure/issues/328
Updated https://github.com/2i2c-org/infrastructure/issues/879 to mention that we should test for unauthorized user access not being possible.

Actions

[x] Incident has been dealt with or is over
[x] Re-enable OpenScapes auto-deploys
[x] https://github.com/2i2c-org/infrastructure/issues/916
[x] Follow up with OpenScapes to figure out how to recoup some of their costs
[x] Sections above are filled out
[x] Incident title and after-action report is cleaned up
[x] All actionable items above have linked GitHub Issues
[ ] Confirm resolved OpenScapes billing issue

update: new user image
@betolink just set the hub's user image to busybox:latest so that user sessions cannot start. We'll use this as a short-term fix until we can either shut down the hub entirely or patch this bug in the authentication.

I've made the hub inaccessible (https://github.com/2i2c-org/infrastructure/pull/911).

With https://github.com/2i2c-org/infrastructure/pull/885/commits/2449ab1b4bdcda7c35ae0c87c2f832fcc0abe85f, I've fixed the hole here letting anyone unauthenticated through. I also took a look at our config to see if we had other hubs missing this config, and there weren't any.

I've made a backup of the jupyterhub.sqlite file on the openscapes hub, and deleted the existing database. Upon next deploy, this will remove all existing users on the hub including the cryptominers.

I've updated the top comment with some follow-up issues. @yuvipanda do you agree with the main things to follow up on? Feel free to add or edit as you wish.

Update: report sent to OpenScapes
I've sent an email report to OpenScapes with the following text:

Email text
Hey all - here is a brief after action report to describe what happened, and the current state of things. I'm also cc'ing the Code for Science and Society team so that they have visibility.
Summary of what happened
The JupyterHub configuration for the OpenScapes hub was missing an option that was not critical for the hub to function properly, but was critical for authorization to function properly. Because of this, unauthorized users were able to access the hub. This was 2i2c's responsibility and we missed this mis-configuration.
An anonymous user found the link to the OpenScapes hub, was able to log-in without authorization, and around Dec 21st they started creating fake user accounts and spinning up crypto mining sessions on the hub. This resulted in the large spike in cloud costs.
Erin noticed this spike on the morning of January 2nd (US/Pacific time) and alerted 2i2c support. By that evening we had patched this bug and deleted the non-admin user accounts. There were around 2 weeks of heavy use related to this user's crypto-mining scripts.
Current situation

The hub is now secured: the incorrect configuration that made it possible for unauthorized users to access the hub has been fixed.
All non-admin users are deleted: we did this to ensure that nefarious users wouldn't have access, you can manually add back any users via the JupyterHub admin UI
The user image is still BusyBox: that will need to be changed back for user images to work again. I also have a PR to add this suggestion to our docs, thanks Luis for thinking of this

Next steps

We should file a support ticket with AWS Support telling them what happened, and asking for an invoice adjustment due to crypto mining abuse. It is common for AWS to forgive cloud costs that are the result of abuse. I will help you put together whatever materials we need to make a case. The screenshots that Luis shared, along with our Grafana logs, should help greatly.
If they do not forgive these costs, then 2i2c will bear the cost. We will discount the monthly hub fee until the cloud costs you incurred during this time window are covered.
In parallel, the 2i2c engineering team will work on process and technology improvements to avoid this in the future. We've identified a number of places to improve our practises moving forward.

You can find a full incident report and ongoing conversation here.
Erin and others - I want to extend my apologies for this problem, and the stress that it has caused. We'll take necessary precautions to avoid this in the future, and will follow up if we have clarifications we need then. We'll also do what is necessary to make sure that OpenScapes isn't the one to bear the extra cloud costs.

I've put together a short report for the OpenScapes team to use in their appeal to reduce their cloud bill. Here's a link:
https://docs.google.com/document/d/106VbSeHDOGbsu-oLENmVJIWkK3MZu-EQN22Qgia4ybo/edit#

Thanks so much for this doc, @choldgraf. I have added additional details for what I was doing on the AWS side to manage and monitor. I submitted and will stay in touch about resolution.

Hey @erinmr / @jules32 - just wanted to see if you had any updates from AWS on this one.

Thanks for checking in @choldgraf - a note today said sorry they are slow, still reviewing

We've just heard back from @erinmr that AWS has forgiven their cloud bill for this incident. I think that we can close this one. Phew!
Thanks so much everybody for being a combination of helpful, patient, and generally awesome :-)


ENG-1300 ENG-1334 Simplify store generation

Description
Simplify the generation of new stores by changing the signature of the Store.Generate func:
Generate(func(Store) Generator) Store

A Generator may be obtained by using Eager or Lazy:
func Eager(s ...Store) Generator
func Lazy(c Condition, f func(Store) Store) Generator

All other interfaces and unnecessary functions were discarded. In addition, all the examples were updated and the sudoku example was deleted pending revision. Lastly, another method was added to the main Store interface: Validate. It receives a store.Condition to establish operational validity.
Changes

Deleted store.If, store.Scope.
Deleted store.Action and changed store.Generator to be any.
Added store.Eager, store.Lazy and changed the signature of Store.Generate.
Added .Validate to the Store interface.

@davidrijsman And I met to discuss that Eager and Lazy are both there to make it more ergonomic for the user.


feat: As a user, I want to consumer-restriction to support upstream_id

Description
It looks like the ingress operator no longer supports Service and instead advises Upstream https://github.com/apache/apisix-ingress-controller/pull/230. However, this prevents consumer-restriction from being used since it doesn't offer a type of upstream_id
The use-case is to be able to configure which "Service" (which I guess is Upstream objects using the ingress controller) a given consumer or consumer_group can access.

I think what you need is Restricting by service_id similar feature, right?
https://apisix.apache.org/docs/apisix/plugins/consumer-restriction/#restricting-by-service_id

I think what you need is Restricting by service_id similar feature, right? https://apisix.apache.org/docs/apisix/plugins/consumer-restriction/#restricting-by-service_id

Yeah, I think that would work


Creation of webhooks for scaling global service should not be allowed

Rancher Versions:
Server:v1.4.0-rc6
**Docker Version:**1.12.6
**OS and where are the hosts located? (cloud, bare metal, etc):**Ubuntu, Cloud
**Setup Details: (single node rancher vs. HA rancher, internal DB vs. external DB)**Single node
**Environment Type: (Cattle/Kubernetes/Swarm/Mesos)**Cattle
Steps to Reproduce:

Create a global service
Create a webhook for a global service

Results:
Currently creation of webhook for a global service is allowed and the webhook can be executed.
Webhook should not be created. It should give out a relevant message.
Create a webhook for global service
soumyas-MBP:testwget soumya$  curl -i -H 'Accept: application/json' -H 'Content-Type: application/json' http://<IP_ADDRESS>:8080/v1-webhooks/receivers?projectId=1a5 -X POST -d '{"name": "scaleservicesup2", "driver": "scaleService", "scaleServiceConfig": {"action": "up", "amount": 1, "serviceId": "1s8", "min": 1, "max": 4}}'
HTTP/1.1 200 OK
Content-Length: 962
Content-Type: application/json
Date: Wed, 01 Feb 2017 00:00:50 GMT
Expires: Thu, 01 Jan 1970 00:00:00 GMT
Server: Jetty(9.2.11.v20150529)
Set-Cookie: PL=rancher;Path=/
X-Api-Account-Id: 1a5
X-Api-Schemas: http://<IP_ADDRESS>:8080/v1-webhooks/schemas
X-Api-User-Id: 1a1
X-Rancher-Version: v1.4.0-rc6

{"actions":{},"driver":"scaleService","id":"1go6","links":{"self":"http://<IP_ADDRESS>:8080/v1-webhooks/receivers/1go6?projectId=1a5"},"name":"scaleservicesup2","scaleServiceConfig":{"action":"up","amount":1,"max":4,"min":1,"serviceId":"1s8","type":"scaleService"},"state":"activating","type":"receiver","url":"http://<IP_ADDRESS>:8080/v1-webhooks/endpoint?token=eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJjb25maWciOnsic2VydmljZUlkIjoiMXM4IiwiYW1vdW50IjoxLCJhY3Rpb24iOiJ1cCIsIm1pbiI6MSwibWF4Ijo0fSwiZHJpdmVyIjoic2NhbGVTZXJ2aWNlIiwicHJvamVjdElkIjoiMWE1IiwidXVpZCI6IjE2YzU4OGRiLWM5MDctNGQ4NC04NGJlLTE1MDNkNDkzN2YyNyJ9.3aSc-8P2H6JbV-V52at_lBj9_YXlHL9jeDZHigz4vQKBTL8KXMcB0cG0bIxMei3A51kXVYW-KJ13kICbuW5eNJ-4lae-51HpjnyfhfUGzmkeb_7gaxZmsZBKBjHzjqythr0fU66rWsWOehzaJsw6uPufEjGFpM6Jab6DBNjckDjPuksFmyHsovErfAvruKH2VNlRNuJ-nl3qyLbrTjHb_Sa5BbClUPexASqFEE7qgCJOBuEpyVb0k8iyIMnuvtb93Zzp_H8seHfhI7hmez5UJYN2aBnzyCyoIwRi34jDG-ajLaEUTDosC9FJ7kulDRu14ues-ppjdwLz4EtTAKXZUw"}

Execute the webhook
soumyas-MBP:testwget soumya$ curl -i -H 'X-API-Project-Id: 1a5' -H 'Accept: application/json' -H 'Content-Type: application/json' http://<IP_ADDRESS>:8080/v1-webhooks/endpoint?token=eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9.eyJjb25maWciOnsic2VydmljZUlkIjoiMXM4IiwiYW1vdW50IjoxLCJhY3Rpb24iOiJ1cCIsIm1pbiI6MSwibWF4IjoxMDB9LCJkcml2ZXIiOiJzY2FsZVNlcnZpY2UiLCJwcm9qZWN0SWQiOiIxYTUiLCJ1dWlkIjoiYTgzN2MyNzItZDNlYi00MjhhLTkxZTgtYjQ1MjdmYTNlNmJmIn0.Pj3TOi9DsjBVFVlsgDX09E20UNKma0S0nSqjReP68bHGZsYCh05dwP9dP5fzQDeVoya1380iFG307tsZDGD8DgCZAaDSzPa1vC61D9RqBBp3yLF_5Na7KjAbnvXRYVmX1C8z1Tg10KFUuARrgxKkrc0J_aMbnOlDWA68J3tTpFyZq4iYwl2UsLMcZfRhe0SDvLDW7im1GkaKvMnn4rxELUJ0KmDNu9zYI71ZwqjkLw9Yh_VH7fH8qVuvlycJMJ2QDLsM5EGFqsEGRJua2GkBzS440n0XsarKlz7oFINcYSnLOIlmYCtzy726o5MXROsBifIYir6LYBQgKLZWRu7fwA -X POST
HTTP/1.1 200 OK
Content-Length: 0
Content-Type: text/plain; charset=UTF-8
Date: Wed, 01 Feb 2017 00:29:28 GMT
Expires: Thu, 01 Jan 1970 00:00:00 GMT
Server: Jetty(9.2.11.v20150529)
Set-Cookie: PL=rancher;Path=/
X-Api-Account-Id: 1a5
X-Api-Schemas: http://<IP_ADDRESS>:8080/v1/schemas
X-Api-User-Id: 1a1
X-Rancher-Version: v1.4.0-rc6

Tested with v1.4.0-rc7. Creation of webhooks for global service is not allowed as expected.
soumyas-MBP:testwget soumya$ curl -i -H 'Accept: application/json' -H 'Content-Type: application/json' http://<IP_ADDRESS>:8080/v1-webhooks/receivers?projectId=1a5 -X POST -d '{"name": "scaleservicesupglobal", "driver": "scaleService", "scaleServiceConfig": {"action": "up", "amount": 1, "serviceId": "1s11", "min": 1, "max": 100}}'
HTTP/1.1 400 Bad Request
Content-Length: 198
Content-Type: application/json
Date: Thu, 02 Feb 2017 04:16:17 GMT
Expires: Thu, 01 Jan 1970 00:00:00 GMT
Server: Jetty(9.2.11.v20150529)
Set-Cookie: PL=rancher;Path=/
X-Api-Account-Id: 1a5
X-Api-Schemas: http://<IP_ADDRESS>:8080/v1/schemas
X-Api-User-Id: 1a1
X-Rancher-Version: v1.4.0-rc7

{"actions":{},"links":{"self":"http://<IP_ADDRESS>:8080/v1-webhooks/receivers"},"message":"Cannot create webhook for global service 1s11","status":"Server Error","statusCode":400,"type":"error"}


Deprecated features

In my log I see some warnings about deprecated features (not urgent yet):
2024-03-12 20:46:20.885 WARNING (MainThread) [homeassistant.components.light] Entity light.lamp_eetkamer (<class 'custom_components.ics2000.light.KlikAanKlikUitDevice'>) is using deprecated supported features values which will be removed in HA Core 2025.1. Instead it should use <LightEntityFeature: 1> and color modes, please report it to the author of the 'ics2000' custom integration and reference https://developers.home-assistant.io/blog/2023/12/28/support-feature-magic-numbers-deprecation 2024-03-12 20:46:20.885 WARNING (MainThread) [homeassistant.components.light] light.lamp_eetkamer (<class 'custom_components.ics2000.light.KlikAanKlikUitDevice'>) does not set supported color modes, this will stop working in Home Assistant Core 2025.3, please report it to the author of the 'ics2000' custom integration
Do you have plans in the near future to update this extension or could I help by making a PR with the necessary changes?

Sorry for the late reply. I have not been doing a lot lately with HA but I'll see if I can update. PR is always nice!

I see you already started working on this (or are already finished with it). So not really useful for me to work on this I guess?


Provide canonical URL for package detail pages

...as well as a mechanism to provide it anywhere when required
Fixes #968
I gave it a thought and according to this, absolute URLs should be used in rel=canonical links. There might be an issue, that the canonical URL currently changes whether the webpage is served over http:// or https:// but https://pypi.io/ does the redirect, so I don't think it should be a problem.
I did not accompanied this change with a test, as I'm not sure how to properly test it. My idea is to test that rendered HTML pages with specific package version always have the appropriate rel=canonical link, however I'm not sure where would be the good starting point for this, help is appreciated.

My idea for the test is something this:
@pytest.mark.parametrize("package", [("Sphinx", "1.3.5")])
def test_canonical_url_is_present_in_package_detail(webtest, package):
    resp = webtest.get("/project/{}/{}/".format(*package))
    assert '<link rel="canonical" href="http://localhost/project/{}/">'.format(package[0]) in resp.body.decode('utf-8')

I just need to put the package in there, as during the test no packages are present :(

Hey, sorry for the delay in getting back to you here.
You should be able to add packages by doing something like:
p = ProjectFactory.create()
rs = [ReleaseFactory.create(project=p) for _ in range(3)]

(Those classes are in tests/common/db/packaging.py file).
That should create a project, and then create three releases to go with it.
One other note, I think it'd be better to actually use xpath or csselect via webtest rather than doing a simple string test. That way we protect against say, accidentally commenting it out.

Thanks for help. However, as soon as I do this:
def test_canonical_url_is_present_in_package_detail():
    proj = ProjectFactory.create()
    assert True

I get:
sqlalchemy.exc.UnboundExecutionError: Could not locate a bind configured on mapper Mapper|Project|packages or this Session

Try adding a db_session keyword arg to the test.

Actually, db_request, but it helped, thanks a lot.

Ok, something very broken is going on here and after a few hours I've not yet figured out wtf is going on with the test suite here. I'm going to just commit this as is and later I'll see if I can't figure out why webtest and db_session don't play nicely together.

Thanks.
For the reference:
def test_canonical_url_is_present_in_package_detail(db_session, webtest):
    project = ProjectFactory.create()
    release = ReleaseFactory.create(project=project)
    db_session.flush()  # ?
    db_session.commit()  # ?
    resp = webtest.get("/project/{}/{}/".format(release.name, release.version))
    assert '<link rel="canonical" href="http://localhost/project/{}/">'.format(release.name) in resp.body.decode('utf-8')  # needs a better check (DOM level)


Deprecating SmartGridAPI and adding ActionAPI

Resolves part of https://github.com/Shopify/pos-next-react-native/issues/31855
Background
We are updating the APIs and Targets to be more generic for future use, and this PR replaces the existing SmartGridAPI with a generic ActionAPI by deprecating SmartGridAPI and adding an identical ActionAPI
🎩

Checklist

~[ ] I have :tophat:'d these changes~
~[ ] I have updated relevant documentation~

missed the export added here: https://github.com/Shopify/ui-extensions/pull/1749


Use pathlib when in python 3

Better to manually work with paths since python 3 isn't available everywhere.


[Feature] add check isfinite hook

Motivation
It is hard to check whether the loss is abnormal while running the code. Especially, when the loss is nan or inf, the program should be stopped to reduce waste of resources.
Modification
Add a hook named CheckIsfiniteHook, which will assert whether the loss is normal after the train iterator.
BC-breaking (Optional)
Need to delete the ssd_head assert codes.
A simple example is as follows:
2021-07-23 15:48:36,546 - mmdet - INFO - Epoch [1][450/73292]	lr: 1.796e-03, eta: 7 days, 13:34:11, time: 0.371, data_time: 0.008, memory: 2382, loss_cls: nan, loss_bbox: nan, loss: nan
Traceback (most recent call last):
  File "/home/wangyudong/code/main-code/mmdetection/tools/train.py", line 190, in <module>
    main()
  File "/home/wangyudong/code/main-code/mmdetection/tools/train.py", line 186, in main
    meta=meta)
  File "/home/wangyudong/code/main-code/mmdetection/mmdet/apis/train.py", line 171, in train_detector
    runner.run(data_loaders, cfg.workflow)
  File "/home/wangyudong/anaconda3/envs/mmdet/lib/python3.7/site-packages/mmcv/runner/epoch_based_runner.py", line 127, in run
    epoch_runner(data_loaders[i], **kwargs)
  File "/home/wangyudong/anaconda3/envs/mmdet/lib/python3.7/site-packages/mmcv/runner/epoch_based_runner.py", line 51, in train
    self.call_hook('after_train_iter')
  File "/home/wangyudong/anaconda3/envs/mmdet/lib/python3.7/site-packages/mmcv/runner/base_runner.py", line 307, in call_hook
    getattr(hook, fn_name)(self)
  File "/home/wangyudong/code/main-code/mmdetection/mmdet/core/isfinite_hook/isfinite_hook.py", line 19, in after_train_iter
    'loss become infinite or NaN!'
AssertionError: loss become infinite or NaN!

Need to discuss:
Is it better to put this hook in mmcv?

Put IsfiniteHook into core/hook.
Put IsfiniteHook into custom hooks.
Save 'loss become infinite or NaN!' into log file when the loss is infinite or Nan. This is due to IsfiniteHook's priority is set to very_low which same as log hook but IsfiniteHook's will call before log hook.
TODO:

Delete SSD Head assert codes.
Whether put this hook into default_runtime.py? Only add in a single SSD config file now.

only add it for ssd
train.py still have chech_isinfinit

Change QQ group QRcode in this PR

Need to resolve conflicts.

Confirmed this hook works correctly

Add test unit

Ping @ZwwWayne


IncrementStrategy

TruncateToLimit
DisabledIfOverflow
Overflow

/// <summary>
/// Controls how increment and decrement behaves.
/// </summary>
public enum IncrementMode
{
    /// <summary>
    /// Truncate to the limit if overflow would have happened.
    /// </summary>
    Truncate,

    /// <summary>
    /// Add the increment even if it overflows the limit.
    /// </summary>
    Overflow,

    /// <summary>
    /// Don't allow incrementing if the limit would be overflown.
    /// </summary>
    DisableIfOverflow,
}

BoundaryPolicy
OnLimitReached (kind of meh since it has a silly callback-like name)

BoundaryPolicy is nice, thanks!


feat: add read support for Name Resolution Block

Hi,
thanks for your patience with this PR. I'm keen for us to have nrb_record_eui48 and nrb_record_eui64 supported as well. also, netip.Addr is preferable to net.IP for the record if possible.

I'm keen for us to have nrb_record_eui48 and nrb_record_eui64 supported as well. also, netip.Addr is preferable to net.IP for the record if possible.

Thx for taking a look. I'll add this once I circle back to that. We delayed integrating that feature internally.

yeah I'm struggling to find good samples as well. but I think so far it looks good to me. we can test it as a PR with different files and see how it works and what would be the best next step.

yeah I'm struggling to find good samples as well. but I think so far it looks good to me. we can test it as a PR with different files and see how it works and what would be the best next step.

Thx, let me know if you need anything.


[SchemaRegistry] move cache to client from serializer

addresses: #13292

/azp run python - schemaregistry - tests

/azp run python - schemaregistry - tests


Expose blur function or equivalent.

monaco-editor npm version: 0.7.0
Browser: Chrome
OS: Mac
What I want to do is to blur editor and invoke actions when user click outside of editor. Problem is that I would like to prevent anything else from happening. Basically the same way you would close modal window, but it's not so simple in my context.
What would help me a lot is one of those:

Monaco can expose blur() function - that would be consistent with existing editor.focus(). I could blur editor myself but it's not the best solution.
When creating editor pass clickOutsideAlwaysBlursEditor: true that if set would catch clicks outside of editor or popups/suggestions etc and call event.stopPropagation();
Expose onMouseUpOutside and similar functions that I could use to reliably know when user clicked outside of editor and popup windows.

@krzychukula
I agree that 1. could be added, but it is trivial to implement on your side via editor.isFocused() and document.activeElement.blur().
I'm sorry, but I don't understand neither 2 nor 3. The editor only listens on its dom node. The only case it adds a global mouse move listener is in the clicking + dragging case which is done to allow for behaviours similar to clicking + dragging in a <textarea>.

Thanks!

In Angular 4 and TypeScript it is:
if (document.activeElement instanceof HTMLElement) {
             document.activeElement.blur();
 }


Cannot install tts-autolabel

Collecting tts-autolabel
Using cached https://modelscope.oss-cn-beijing.aliyuncs.com/releases/dependencies/kantts/tts_autolabel-1.1.1-py3-none-any.whl (80 kB)
Discarding https://modelscope.oss-cn-beijing.aliyuncs.com/releases/dependencies/kantts/tts_autolabel-1.1.1-py3-none-any.whl (from https://modelscope.oss-cn-beijing.aliyuncs.com/releases/repo.html): Requested tts-autolabel from https://modelscope.oss-cn-beijing.aliyuncs.com/releases/dependencies/kantts/tts_autolabel-1.1.1-py3-none-any.whl has inconsistent version: expected '1.1.1', but metadata has '1.1.2'
Using cached https://modelscope.oss-cn-beijing.aliyuncs.com/releases/dependencies/kantts/tts_autolabel-1.0.1-py3-none-any.whl (63 kB)
Using cached https://modelscope.oss-cn-beijing.aliyuncs.com/releases/dependencies/kantts/tts_autolabel-1.0-py3-none-any.whl (62 kB)
ERROR: Cannot install tts-autolabel==1.0, tts-autolabel==1.0.1, tts-autolabel==1.1.2, tts-autolabel==1.1.7 and tts-autolabel==1.1.8 because these package versions have conflicting dependencies.

I also encountered the same problem, have you solved it?

no, I even can't find it in https://pypi.org/search/?q=autolabel&o=

still not work with create conda env:
My python is 3.10, my stable diffusion use it: maybe I should install python 3.11 and follow your step:
Collecting librosa (from tts-autolabel)
Using cached https://mirrors.aliyun.com/pypi/packages/e2/a2/4f639c1168d7aada749a896afb4892a831e2041bebdcf636aebfe9e86556/librosa-0.10.1-py3-none-any.whl (253 kB)
Collecting numpy<=1.23.1 (from tts-autolabel)
Using cached https://mirrors.aliyun.com/pypi/packages/8b/11/75a93826457f94a4c857a38ea3f178915f27ff38ffee1753e36994be7810/numpy-1.23.1-cp310-cp310-win_amd64.whl (14.6 MB)
Collecting sox (from tts-autolabel)
Using cached https://mirrors.aliyun.com/pypi/packages/3f/67/1810e9a69956eb236967b7174c11fd8d8c2cdab051509286f72e6c7e147e/sox-1.4.1-py2.py3-none-any.whl (39 kB)
Requirement already satisfied: pyyaml in c:\users\admin\appdata\roaming\python\python310\site-packages (from tts-autolabel) (6.0)
Requirement already satisfied: tqdm in c:\programdata\miniconda3\envs\venvbart\lib\site-packages (from tts-autolabel) (4.65.0)
Requirement already satisfied: scipy in c:\programdata\miniconda3\envs\venvbart\lib\site-packages (from tts-autolabel) (1.11.1)
INFO: pip is looking at multiple versions of tts-autolabel to determine which version is compatible with other requirements. This could take a while.
Collecting tts-autolabel
Using cached https://modelscope.oss-cn-beijing.aliyuncs.com/releases/dependencies/kantts/tts_autolabel-1.1.7-py3-none-any.whl (116 kB)
Using cached https://modelscope.oss-cn-beijing.aliyuncs.com/releases/dependencies/kantts/tts_autolabel-1.1.2-py3-none-any.whl (80 kB)
Requirement already satisfied: numpy in c:\programdata\miniconda3\envs\venvbart\lib\site-packages (from tts-autolabel) (1.24.3)
Collecting typeguard (from tts-autolabel)
Downloading https://mirrors.aliyun.com/pypi/packages/18/01/5fc45558268ced46d86292763477996a3cdd505567cd590a688e8cdc386e/typeguard-4.1.5-py3-none-any.whl (34 kB)
Collecting kaldi-native-fbank (from tts-autolabel)
Using cached https://mirrors.aliyun.com/pypi/packages/fe/d4/c91cfac45bcebf26056bf721ab9303ede62329c0bc192f526591a54992d7/kaldi_native_fbank-1.18.5-cp310-cp310-win_amd64.whl (231 kB)
Collecting pypinyin (from tts-autolabel)
Downloading https://mirrors.aliyun.com/pypi/packages/00/fc/3e82bf38739a7b2c4f699245ce6c84ff254723c678c2cdc5d2ecbddf9afb/pypinyin-0.49.0-py2.py3-none-any.whl (1.4 MB)
---------------------------------------- 1.4/1.4 MB 21.8 MB/s eta 0:00:00
Collecting g2p-en (from tts-autolabel)
Downloading https://mirrors.aliyun.com/pypi/packages/d7/d9/b77dc634a7a0c0c97716ba97dd0a28cbfa6267c96f359c4f27ed71cbd284/g2p_en-2.1.0-py3-none-any.whl (3.1 MB)
---------------------------------------- 3.1/3.1 MB 16.6 MB/s eta 0:00:00
Collecting tts-autolabel
Using cached https://modelscope.oss-cn-beijing.aliyuncs.com/releases/dependencies/kantts/tts_autolabel-1.1.1-py3-none-any.whl (80 kB)
Discarding https://modelscope.oss-cn-beijing.aliyuncs.com/releases/dependencies/kantts/tts_autolabel-1.1.1-py3-none-any.whl (from https://modelscope.oss-cn-beijing.aliyuncs.com/releases/repo.html): Requested tts-autolabel from https://modelscope.oss-cn-beijing.aliyuncs.com/releases/dependencies/kantts/tts_autolabel-1.1.1-py3-none-any.whl has inconsistent version: expected '1.1.1', but metadata has '1.1.2'
Using cached https://modelscope.oss-cn-beijing.aliyuncs.com/releases/dependencies/kantts/tts_autolabel-1.0.1-py3-none-any.whl (63 kB)
Using cached https://modelscope.oss-cn-beijing.aliyuncs.com/releases/dependencies/kantts/tts_autolabel-1.0-py3-none-any.whl (62 kB)
ERROR: Cannot install tts-autolabel==1.0, tts-autolabel==1.0.1, tts-autolabel==1.1.2, tts-autolabel==1.1.7 and tts-autolabel==1.1.8 because these package versions have conflicting dependencies.
The conflict is caused by:
tts-autolabel 1.1.8 depends on nls-fa
tts-autolabel 1.1.7 depends on nls-fa
tts-autolabel 1.1.2 depends on nls-pykaldi
tts-autolabel 1.0.1 depends on nls-pykaldi
tts-autolabel 1.0 depends on nls-pykaldi
To fix this you could try to:

loosen the range of package versions you've specified
remove package versions to allow pip attempt to solve the dependency conflict

ERROR: ResolutionImpossible: for help visit https://pip.pypa.io/en/latest/topics/dependency-resolution/#dealing-with-dependency-conflicts

同样的问题，windows系统安装时

I install it in WSL2-Ubuntu22.04, use python3.10

windows  python3.10  同样出现这个问题
Collecting tts-autolabel
Using cached https://modelscope.oss-cn-beijing.aliyuncs.com/releases/dependencies/kantts/tts_autolabel-1.1.1-py3-none-any.whl (80 kB)
Discarding https://modelscope.oss-cn-beijing.aliyuncs.com/releases/dependencies/kantts/tts_autolabel-1.1.1-py3-none-any.whl (from https://modelscope.oss-cn-beijing.aliyuncs.com/releases/repo.html): Requested tts-autolabel from https://modelscope.oss-cn-beijing.aliyuncs.com/releases/dependencies/kantts/tts_autolabel-1.1.1-py3-none-any.whl has inconsistent version: expected '1.1.1', but metadata has '1.1.2'
Using cached https://modelscope.oss-cn-beijing.aliyuncs.com/releases/dependencies/kantts/tts_autolabel-1.0.1-py3-none-any.whl (63 kB)
Using cached https://modelscope.oss-cn-beijing.aliyuncs.com/releases/dependencies/kantts/tts_autolabel-1.0-py3-none-any.whl (62 kB)
ERROR: Cannot install tts-autolabel==1.0, tts-autolabel==1.0.1, tts-autolabel==1.1.2, tts-autolabel==1.1.7 and tts-autolabel==1.1.8 because these package versions have conflicting dependencies.
The conflict is caused by:
tts-autolabel 1.1.8 depends on nls-fa
tts-autolabel 1.1.7 depends on nls-fa
tts-autolabel 1.1.2 depends on nls-pykaldi
tts-autolabel 1.0.1 depends on nls-pykaldi
tts-autolabel 1.0 depends on nls-pykaldi
To fix this you could try to:

loosen the range of package versions you've specified
remove package versions to allow pip attempt to solve the dependency conflict

ERROR: ResolutionImpossible: for help visit https://pip.pypa.io/en/latest/topics/dependency-resolution/#dealing-with-dependency-conflicts


accept publish key or PAT in PublishDialog

Publishing packages requires either a Publish Key or a PAT (Personal Access Token).
The implementation is not really nice. Maybe someone else has a good idea?

The UI currently always shows the abbrevation (PAT). Should the first occurrence be changed to PAT (Personal Access Token) ?

Thanks!


Enable HTTP/2 on preload/delegate nodes

Problem
HTTP/2 is not supported on preload/delegate hostnames:

node0.preload.ipfs.io, node1.preload.ipfs.io
node0.delegate.ipfs.io,node1.delegate.ipfs.io

Test
$ npm install -g is-http2-cli

$ is-http2 ipfs.io
✓ HTTP/2 supported by ipfs.io
Supported protocols: h2 http/1.1

$ is-http2 node0.delegate.ipfs.io
× HTTP/2 not supported by node0.delegate.ipfs.io
Supported protocols: http/1.1

Motivation
Preload/delegate (https://github.com/ipfs/js-ipfs/issues/2155) hosts receive multiple parallel requests from js-ipfs running in browser context. Browsers limit the number of concurrent requests/connections to ~6.
In HTTP/2 requests are multiplexed on a single connection, which improves performance and removes the amount of requests being in pending state.

This is live.
mburns@rialto:~)$ sudo /usr/bin/is-http2 node0.delegate.ipfs.io
✓ HTTP/2 supported by node0.delegate.ipfs.io
Supported protocols: h2 http/1.1


Avoid using session storage entirely. It does weird things in iframes.

#197  👈
main

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

Join @jklein24 and the rest of your teammates on  Graphite

Merge activity

Oct 4, 8:19 PM EDT: @jklein24 merged this pull request with Graphite.


'odo watch comp-name' detects and push changes, but nothing gets updated

`odo push' on the other hand works flawlessly.
Below console output for both commands. First odo watch' executed and nodejs-ex/views/index.html changed in notepad.exe. No changes appears on app page. Then after stopping odo watch odo push` executed and app page gets updated.
watch
odo watch node-test1 -v
DEBU[0000] Trying to connect to server <IP_ADDRESS>:8443 - %!v(MISSING)
DEBU[0000] Server https://<IP_ADDRESS>:8443 is up
DEBU[0000] isLoggedIn err:  <nil>
 output: "developer"
DEBU[0000] Getting BuildConfig: node-test1-a3
DEBU[0000] Source for component node-test1 is file://C:/p/nodejs-ex (local)
DEBU[0000] starting WatchAndPush, path: /p/nodejs-ex, component: node-test1
DEBU[0000] adding watch on path /p/nodejs-ex
DEBU[0000] ignoring watch for \p\nodejs-ex\.git
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\hooks
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\info
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\logs
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\logs\refs
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\logs\refs\heads
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\logs\refs\remotes
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\logs\refs\remotes\origin
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\objects
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\objects\03
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\objects\58
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\objects\65
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\objects\78
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\objects\7f
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\objects\81
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\objects\88
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\objects\a4
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\objects\c2
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\objects\ca
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\objects\d4
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\objects\ef
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\objects\f7
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\objects\info
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\objects\pack
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\refs
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\refs\heads
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\refs\remotes
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\refs\remotes\origin
DEBU[0000] ignoring watch for \p\nodejs-ex\.git\refs\tags
DEBU[0000] adding watch on path \p\nodejs-ex\helm
DEBU[0000] adding watch on path \p\nodejs-ex\helm\nodejs
DEBU[0000] adding watch on path \p\nodejs-ex\helm\nodejs\templates
DEBU[0000] adding watch on path \p\nodejs-ex\openshift
DEBU[0000] adding watch on path \p\nodejs-ex\openshift\pipeline
DEBU[0000] adding watch on path \p\nodejs-ex\openshift\templates
DEBU[0000] adding watch on path \p\nodejs-ex\tests
DEBU[0000] adding watch on path \p\nodejs-ex\views
Waiting for something to change in /p/nodejs-ex
DEBU[0024] filesystem watch event: "\\p\\nodejs-ex\\views\\index.html": WRITE
DEBU[0024] adding watch on path \p\nodejs-ex\views\index.html
DEBU[0024] filesystem watch event: "\\p\\nodejs-ex\\views\\index.html": WRITE
DEBU[0024] adding watch on path \p\nodejs-ex\views\index.html
File \p\nodejs-ex\views\index.html changed
Pushing files...
DEBU[0025] Copying files [\p\nodejs-ex\views\index.html] to pod
DEBU[0025] Waiting for deploymentconfig=node-test1-a3 pod
DEBU[0025] Status of node-test1-a3-1-rxc6n pod is Running
DEBU[0025] Pod node-test1-a3-1-rxc6n is running.
DEBU[0025] Copying to pod node-test1-a3-1-rxc6n
my localpath is /p/nodejs-ex
Please wait, building component....
---> Installing application source ...
---> Installing all dependencies
up to date in 1.072s
---> Building in production mode
---> Pruning the development dependencies
up to date in 0.833s
/opt/app-root/src/.npm is not a mountpoint
---> Cleaning the npm cache /opt/app-root/src/.npm
/tmp is not a mountpoint
---> Cleaning the /tmp/npm-*
run: stopped
run: started
Waiting for something to change in /p/nodejs-ex
DEBU[0176] filesystem watch event: "\\p\\nodejs-ex\\views\\index.html": WRITE
DEBU[0176] adding watch on path \p\nodejs-ex\views\index.html
DEBU[0176] filesystem watch event: "\\p\\nodejs-ex\\views\\index.html": WRITE
DEBU[0176] adding watch on path \p\nodejs-ex\views\index.html
DEBU[0176] filesystem watch event: "\\p\\nodejs-ex\\views\\index.html": WRITE
DEBU[0176] adding watch on path \p\nodejs-ex\views\index.html
DEBU[0176] filesystem watch event: "\\p\\nodejs-ex\\views\\index.html": WRITE
DEBU[0176] adding watch on path \p\nodejs-ex\views\index.html
File \p\nodejs-ex\views\index.html changed
Pushing files...
DEBU[0177] Copying files [\p\nodejs-ex\views\index.html] to pod
DEBU[0177] Waiting for deploymentconfig=node-test1-a3 pod
DEBU[0177] Status of node-test1-a3-1-rxc6n pod is Running
DEBU[0177] Pod node-test1-a3-1-rxc6n is running.
DEBU[0177] Copying to pod node-test1-a3-1-rxc6n
my localpath is /p/nodejs-ex
Please wait, building component....
---> Installing application source ...
---> Installing all dependencies
up to date in 0.96s
---> Building in production mode
---> Pruning the development dependencies
up to date in 0.883s
/opt/app-root/src/.npm is not a mountpoint
---> Cleaning the npm cache /opt/app-root/src/.npm
/tmp is not a mountpoint
---> Cleaning the /tmp/npm-*
run: stopped
run: started
Waiting for something to change in /p/nodejs-ex
DEBU[0251] filesystem watch event: "\\p\\nodejs-ex\\views\\index.html": WRITE
DEBU[0251] adding watch on path \p\nodejs-ex\views\index.html
DEBU[0251] filesystem watch event: "\\p\\nodejs-ex\\views\\index.html": WRITE
DEBU[0251] adding watch on path \p\nodejs-ex\views\index.html
DEBU[0251] filesystem watch event: "\\p\\nodejs-ex\\views\\index.html": WRITE
DEBU[0251] adding watch on path \p\nodejs-ex\views\index.html
DEBU[0251] filesystem watch event: "\\p\\nodejs-ex\\views\\index.html": WRITE
DEBU[0251] adding watch on path \p\nodejs-ex\views\index.html
File \p\nodejs-ex\views\index.html changed
Pushing files...
DEBU[0253] Copying files [\p\nodejs-ex\views\index.html] to pod
DEBU[0253] Waiting for deploymentconfig=node-test1-a3 pod
DEBU[0253] Status of node-test1-a3-1-rxc6n pod is Running
DEBU[0253] Pod node-test1-a3-1-rxc6n is running.
DEBU[0253] Copying to pod node-test1-a3-1-rxc6n
my localpath is /p/nodejs-ex
Please wait, building component....
---> Installing application source ...
---> Installing all dependencies
up to date in 0.96s
---> Building in production mode
---> Pruning the development dependencies
up to date in 0.994s
/opt/app-root/src/.npm is not a mountpoint
---> Cleaning the npm cache /opt/app-root/src/.npm
/tmp is not a mountpoint
---> Cleaning the /tmp/npm-*
run: stopped
run: started
Waiting for something to change in /p/nodejs-ex

push
c:\p\nodejs-ex>odo push
Pushing changes to component: node-test1
my localpath is /p/nodejs-ex
Please wait, building component....
---> Installing application source ...
---> Installing all dependencies
up to date in 1.372s
---> Building in production mode
---> Pruning the development dependencies
up to date in 1.17s
/opt/app-root/src/.npm is not a mountpoint
---> Cleaning the npm cache /opt/app-root/src/.npm
/tmp is not a mountpoint
---> Cleaning the /tmp/npm-*
run: stopped
run: started
changes successfully pushed to component: node-test1

Hmm, it is possible that it is something related to how path are handled in windows :-(

@dgolovin
Is this happening even when you run odo push and odo watch after that?

@kadel yes, I have the same problem.
If I update the index.html and run odo push. Then update the page in browser, I can see the changes. Then I run 'odo watch', change 'index.html', see the 'odo watch' pushed the changes, update page in browser and don't see the changes.


Dataset link not working ？

The dataset link you provided （https://www.dropbox.com/s/o53umyg6mn3zhxy/data.tar.gz?dl=1）
doesn't seem to be able to be downloaded, can you check it for an update, thank you.

The link from README works for me, so maybe the reason is that your machine cannot connect to DropBox for some reason?

I also met this problem. Maybe the dataset link is not stable. I can link in the homepage of dropbox but the dataset link is not available to reach. Actually I once linked in the website and start to download the dataset. But failed while downloading. After that the link cannot be linked in.

the same problem, please fix this error, thanks :)

@ZhaoShengjian  @WuZheng326 @Kunkka007 Previously, I could not reproduce the issue (the link worked properly at least on two different machines). However, this time, I confirm the issue, I will let you know once it is fixed.

Hi @ZhaoShengjian @WuZheng326 @Kunkka007
The link seems to be working again, could you confirm that?


Wordpress Elementor 406 ERROR when saving

Description
I get an 406 error when I try to save a page with elementor plugin and the latest version of Wordpress.
I don't really know how to fix this in combination with DirectAdmin's CustomBuild 2.0 hoping someone can help me.
Audit Logs / Triggered Rule Numbers
Tue Sep 29 21:01:21.890191 2020] [:error] [pid 4051360:tid<PHONE_NUMBER>45536] [client ] [client ] ModSecurity: Access denied with code 406 (phase 2). Pattern match "(?:\\$(?:\\((?:\\(.\\)|.)\\)|\\{.\\})|[<>]\\(.\\))" at ARGS:actions. [file "/etc/modsecurity.d/REQUEST-932-APPLICATION-ATTACK-RCE.conf"] [line "366"] [id "932130"] [msg "Remote Command Execution: Unix Shell Expression Found"] [data "Matched Data:
Your Environment

CRS version (e.g., v3.2.0): 3.3.0
Paranoia level setting: 2
ModSecurity version (e.g., 2.9.3):  2.24.5
Web Server and version (e.g., apache 2.4.41): 2.4.46
Operating System and version: CentOS 8 with DirectAdmin 1.61.5

Confirmation
[ X ] I have removed any personal data (email addresses, IP addresses,
passwords, domain names) from any logs posted.

Currently, we are, officially, NOT supporting any WordPress plugin. Anyway, here is the rule from my personal collection which should cover this case (put it inside file REQUEST-900-EXCLUSION-RULES-BEFORE-CRS.conf):
SecRule REQUEST_FILENAME "@endsWith /wp-admin/admin-ajax.php" \
    "id:9990134,\
    phase:2,\
    pass,\
    t:none,\
    nolog,\
    chain"
    SecRule ARGS:action "@streq elementor_ajax" \
        "t:none,\
        chain"
        SecRule &ARGS:action "@eq 1" \
            "t:none,\
            ctl:ruleRemoveTargetByTag=attack-xss;ARGS:actions,\
            ctl:ruleRemoveTargetById=933210;ARGS:actions,\
            ctl:ruleRemoveTargetById=932140;ARGS:actions,\
            ctl:ruleRemoveTargetById=932105;ARGS:actions,\
            ctl:ruleRemoveTargetById=932130;ARGS:actions"


prelights ingestion is failing

Error message:
{
  "timestamp": "2024-12-24T09:30:35.670Z",
  "level": "warn",
  "correlationId": "8ab62528-c7b9-4007-a8fa-216738518266",
  "message": "Ingestion failed",
  "payload": {
    "processName": "preLights",
    "cause": "Could not discover any published evaluations",
    "error": "Could not decode external response, prelightsFeedCodec failed with: Expecting { preprint: Array<{ preprintdoi: string }> } at rss.channel.1.item.1.preprints but instead got: undefined, Expecting { preprint: Array<{ preprintdoi: string }> } at rss.channel.1.item.2.preprints but instead got: undefined"
  }
}

Feed state at time of issue
<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"

	xmlns:georss="http://www.georss.org/georss"
	xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#"
	>

	<channel>
		<title>preLights</title>
		<link>https://prelights.biologists.com/</link>

		<lastBuildDate>Mon, 23 Dec 2024 07:34:06 +0000</lastBuildDate>
		<language>en-GB</language>
		<sy:updatePeriod>hourly</sy:updatePeriod>
		<sy:updateFrequency>1</sy:updateFrequency>
		<atom:link href="https://prelights.biologists.com/feed/sciety/?key=trdvKJGc342dbfurvtvwsv5y&hours=120" rel="self" type="application/rss+xml" />

		<image>
			<url>https://prelights.biologists.com//dist/images/preLights.svg</url>
			<title>Preprint highlights, selected by the biological community</title>
			<link>https://prelights.biologists.com/</link>
		</image>

		<generator>https://wordpress.org/?v=6.6.2</generator>
<site xmlns="com-wordpress:feed-additions:1">143028432</site>

					<item>
					<category><![CDATA[highlight]]></category>
					<title>Restoring mechanophenotype reverts malignant properties of ECM-enriched vocal fold cancer</title>
					<link>https://prelights.biologists.com/highlights/restoring-mechanophenotype-reverts-malignant-properties-of-ecm-enriched-vocal-fold-cancer/</link>
					<guid isPermaLink="false">https://prelights.biologists.com/?post_type=highlight&p=39236</guid>
					<author>Teodora Piskova</author>
					<image>
						<url>https://prelights.biologists.com/wp-content/uploads/2024/12/Unbenannt.png</url>
					</image>
					<pubDate>Thu, 19 Dec 2024 11:33:37 +0000</pubDate>

					<oneLineSummary>Can restoring vocal fold mechanics combat cancer? This preprint explores how!</oneLineSummary>
					<content:encoded>
						<![CDATA[
Introduction
 The extracellular matrix (ECM) drives cancer progression (1), but most relevant studies focus solely on solid tumours where cells are not exposed to significant forces. Unlike most cancers, vocal fold cancer (VFC) develops in a tissue that constantly experiences mechanical stress (in this case, from speaking and breathing). VFC…]]>
					</content:encoded>
					<doi></doi>

					<preprints>

							<preprint>
								<preprinturl>https://www.biorxiv.org/content/10.1101/2<IP_ADDRESS>9159v1</preprinturl>
								<preprintdoi>10.1101/2<IP_ADDRESS>9159</preprintdoi>
								<preprintauthorresponse>No</preprintauthorresponse>
								<preprintauthorresponseurl></preprintauthorresponseurl>
								<preprintauthorresponseexcerpt>
									<![CDATA[]]>
								</preprintauthorresponseexcerpt>
							</preprint>
					</preprints>
								</item>
						<item>
					<category><![CDATA[highlight]]></category>
					<title>Phosphorylation of huntingtin at S421 supercharges cellular transport by turbocharging kinesin and dynein motors on endosomes and lysosomes</title>
					<link>https://prelights.biologists.com/highlights/phosphorylation-of-huntingtin-at-s421-supercharges-cellular-transport-by-turbocharging-kinesin-and-dynein-motors-on-endosomes-and-lysosomes/</link>
					<guid isPermaLink="false">https://prelights.biologists.com/?post_type=highlight&p=39265</guid>
					<author>Abhishek Poddar</author>
					<image>
						<url></url>
					</image>
					<pubDate>Wed, 21 Aug 2024 06:25:53 +0000</pubDate>

					<oneLineSummary>Phosphorylation Power: Unlocking Huntingtin's Role in Enhancing Intracellular Transport</oneLineSummary>
					<content:encoded>
						<![CDATA[
Background
 This study explores how the phosphorylation of huntingtin at the S421 site influences intracellular transport of early endosomes and lysosomes. The findings reveal that cells expressing endogenous levels of phosphomimetic huntingtin (HTT-S421D) exhibit enhanced transport activity, with lysosomes traveling longer distances and a greater fraction of them displaying…]]>
					</content:encoded>
					<doi>https://doi.org/10.1242/prelights.39265</doi>

								</item>
						<item>
					<category><![CDATA[highlight]]></category>
					<title>Necrosulfonamide causes oxidation of PCM1 and impairs ciliogenesis and autophagy</title>
					<link>https://prelights.biologists.com/highlights/necrosulfonamide-causes-oxidation-of-pcm1-and-impairs-ciliogenesis-and-autophagy/</link>
					<guid isPermaLink="false">https://prelights.biologists.com/?post_type=highlight&p=39257</guid>
					<author>Abhishek Poddar</author>
					<image>
						<url></url>
					</image>
					<pubDate>Tue, 19 Mar 2024 07:00:46 +0000</pubDate>

					<oneLineSummary>Necrosulfonamide disrupts ciliogenesis and autophagy by inducing PCM1 oxidation and aggregation via ROS production, independent of MLKL.</oneLineSummary>
					<content:encoded>
						<![CDATA[
Background:
 Centriolar satellites are small, protein assemblies located near centrioles in animal cells. They play a key role in cellular processes such as centriole duplication, ciliogenesis (formation of primary cilium), autophagy and regulation of microtubule dynamics. PCM1 (pericentriolar material 1) is a key component of the centriolar satellites which serves…]]>
					</content:encoded>
					<doi>https://doi.org/10.1242/prelights.39257</doi>

								</item>

						<description>Preprint highlights, selected by the biological community Feed</description>
						</channel>
</rss>

Two highlights are not associated with preprints. This could be an error on Prelight's side. However given that they are sending it I suggest we assume it is valid in their eyes. I have updated the decoding and subsequent transformation to our domain model accordingly.
Highlights causing this issue:

10.1242/prelights.39257
10.1242/prelights.39265


RD2: If DayOfMonth is null, set using NextPaymentDate or DateEstablished

To match logic in legacy recurring donations, when the Day_Of_Month__c field is null on the Recurring Donation record, use the day value from either the NextPaymentDate (if not null) or DateEstablished fields.

Critical Changes
Changes
Issues Closed
New Metadata
Deleted Metadata

**lurch: attach W-037296

Tracking W-037296

@rponti-sforg This is ready for testing Rick. Thanks.


assignment_1

What changes are you trying to make? (e.g. Adding or removing code, refactoring existing code, adding reports)
Added code to complete assignment_1
What did you learn from the changes you have made?
basic python programming
Was there another approach you were thinking about making? If so, what approach(es) were you thinking of?
No other approach
Were there any challenges? If so, what issue(s) did you face? How did you overcome it?
No challenges
How were these changes tested?
used vscode to run the functions created
A reference to a related issue in your repository (if applicable)
Checklist

[ ] I can confirm that my changes are working as intended

No change to the assignment.


Add Error Handling for Connecting to SMART version of Dashboard

Fail gracefully by showing an error message if a connection cannot be made to the SMART on FHIR application.

Being tracked by CCSMCDS-92.


Unit Test FastEndpoints exception

I am getting the exception when trying to run the unit test case as below: (getting error in line 42)

Getting error when trying to make call SendCreatedAtAsync() in below screenshot:

I only get error when trying SendCreatedAtAsync(). For SendAsync() or SendNotFoundAsync(), it works fine. Please help.
Error description:
Message:
System.InvalidOperationException : Service provider is null on the current HttpContext! Set it yourself for unit tests.
Stack Trace:
HttpResponseExtensions.SendCreatedAtAsync(HttpResponse rsp, String endpointName, Object routeValues, Object responseBody, JsonSerializerContext jsonSerializerContext, Boolean generateAbsoluteUrl, CancellationToken cancellation)
HttpResponseExtensions.SendCreatedAtAsync[TEndpoint](HttpResponse rsp, Object routeValues, Object responseBody, Nullable1 verb, Nullable1 routeNumber, JsonSerializerContext jsonSerializerContext, Boolean generateAbsoluteUrl, CancellationToken cancellation)
Endpoint2.SendCreatedAtAsync[TEndpoint](Object routeValues, TResponse responseBody, Nullable1 verb, Nullable`1 routeNumber, Boolean generateAbsoluteUrl, CancellationToken cancellation)
CreateCompany.HandleAsync(CreateCompanyRequest req, CancellationToken ct) line 27
CreateCompanyTests.CreateCompany_GivenValidCompany_ReturnsCompany() line 43
--- End of stack trace from previous location ---

it's a bit tricky to unit test endpoints that use SendCreatedAt since it requires mocking out a LinkGenerator and as well as populating the http context correctly. a basic unit test however can be done as follows:
https://github.com/FastEndpoints/FastEndpoints/blob/9d983c2dadad9c9d0f6e114934f25a26725abec1/Tests/UnitTests/FastEndpoints.UnitTests/WebTests/UnitTests.cs#L128-L135
to be able to properly check if the correct Location header value is returned, you should turn it in to an integration test.

It still gives same error. My changed code is below:
private readonly CreateCompany _createCompany;
private readonly Mock _mockCompanyService;
private readonly CancellationToken _ct;
public CreateCompanyTests()
{
var linkgen = new Mock();
_mockCompanyService = new Mock();
_createCompany = Factory.Create
(ctx =>
{
var services = new ServiceCollection();
services.AddSingleton(linkgen);
ctx.RequestServices = services.BuildServiceProvider();
},
_mockCompanyService.Object
);
}

just tried the following and it works:
var linkgen = new Mock<LinkGenerator>().Object;

var ep = Factory.Create<Endpoint>(ctx =>
{
    var services = new ServiceCollection();
    services.AddSingleton(linkgen);
    ctx.RequestServices = services.BuildServiceProvider();
    ctx.Response.Body = new MemoryStream();
});

await ep.HandleAsync(default);

ep.HttpContext.Response.Body.Position = 0;
var msg = new StreamReader(ep.HttpContext.Response.Body).ReadToEnd();

var pass = msg == "{\"msg\":\"hello\"}";

Console.WriteLine("test passed: " + pass);
Console.Read();

public class Endpoint : EndpointWithoutRequest
{
    public override void Configure()
    {
        Get("test");
        AllowAnonymous();
    }

    public override async Task HandleAsync(CancellationToken c)
    {
        await SendCreatedAtAsync("/get-company", new { id = 1 }, new { msg = "hello" });
    }
}