cilium, gops: remap to fixed port to avoid collision with nodeport range

See commit msg.

test-me-please

Nice catch! Could you please also update Hubble Relay as I think it's also affected (nodeport protection is global)? It also enables gops by default with the default listen address (see hubble-relay/cmd/serve/serve.go).

Ah, good point, that one fell through the cracks :/ will add.

the overall changes LGTM, however a couple points that we need to take care:

It would likely be better to Fatal if we can't initialize gops. If gops isn't running at all we won't be able to debug Cilium if we need it;

Ok, fair enough, I'll change to error out with Fatal instead.

Currently, the default is <IP_ADDRESS>:0 and we are changing it to localhost:XXXX, maybe we should keep the <IP_ADDRESS>.

No strong opinion here, I can change it back. Locally, I had it on [::1]:XXX first to map it to v6 only to avoid occupying a v4 port, but then I thought localhost instead would be cleaner to not make any addr family assumptions.

I don't see a "reuse port" in gops, so it is likely that we will hit something similar as #11573.

I haven't run into it on local testing at least and looking into gops code it seems to gracefully clean up the socket on termination, but maybe @tklauser has more insight as gops contributor. :)

test-me-please

the overall changes LGTM, however a couple points that we need to take care:

It would likely be better to Fatal if we can't initialize gops. If gops isn't running at all we won't be able to debug Cilium if we need it;

Ok, fair enough, I'll change to error out with Fatal instead.

Currently, the default is <IP_ADDRESS>:0 and we are changing it to localhost:XXXX, maybe we should keep the <IP_ADDRESS>.

No strong opinion here, I can change it back. Locally, I had it on [::1]:XXX first to map it to v6 only to avoid occupying a v4 port, but then I thought localhost instead would be cleaner to not make any addr family assumptions.

FWIW, we had #13165 where the agent health endpoint was listening on localhost: and this lead to problems in IPV6-only environments. Not quite sure whether that is applicable here, but I think sticking to <IP_ADDRESS> is the safer option.

I don't see a "reuse port" in gops, so it is likely that we will hit something similar as #11573.

I haven't run into it on local testing at least and looking into gops code it seems to gracefully clean up the socket on termination, but maybe @tklauser has more insight as gops contributor. :)

Haven't encountered it so far either, but I think it would be worth to add SO_REUSEADDR and SO_REUSEPORT to upstream gops to be on the safe side. Will send a PR.

[...]

Haven't encountered it so far either, but I think it would be worth to add SO_REUSEADDR and SO_REUSEPORT to upstream gops to be on the safe side. Will send a PR.

Sounds good, thanks @tklauser !

Implementation LGTM apart from the else branch nits.

Done, thanks!

Might be worth adding the new default ports to the table in Documentation/operations/system_requirements.rst as well (search for The following ports should also be available on each node, cannot link to the source file due to GitHub rendering it).

Also done now.

As already commented, will take care of adding SO_REUSEADDR/SO_REUSEPORT to gops upstream. We can then pull this in a follow-up PR.

Added tracking via #14332.

test-me-please

(4.9 failure potentially related to https://github.com/cilium/cilium/issues/11512)

retest-4.9

(4.9 failure potentially related to #11512)

No, I think it was caused by https://github.com/cilium/cilium/pull/14335. Travis CI seems like a flake. Once net-next is green, it should be good to merge :tada:

retest-runtime

I think the first two commits should be merged so the version in go.mod is bumped as part of the same commit as the vendor/ directory.

I don't always update go.mod, so for me the separation into these two commits was for myself for future reference in that it's clear next time I check the git log that we have go.mod bump as one part and the rest is sync-up.

You may also want to add Fixes #14332 to the commit message bumping gops.

Done, good point.

test-me-please

I think the first two commits should be merged so the version in go.mod is bumped as part of the same commit as the vendor/ directory.

I don't always update go.mod, so for me the separation into these two commits was for myself for future reference in that it's clear next time I check the git log that we have go.mod bump as one part and the rest is plain sync-up.

The problem with two commits is that it breaks bisects. go build will complain about the mismatch between the version in vendor/ and the one in go.mod. What I'd do to bump the dependency is go get github.com/google/gops@latest && go mod tidy && go mod vendor. This will update go.mod, go.sum and vendor/ and can then be committed as one unit.
But I guess in this case it's also fine to keep the two separate commits for your reference, as bisectability shouldn't really a big issue here. Or maybe adding the command above helps for future reference as well?

I think the first two commits should be merged so the version in go.mod is bumped as part of the same commit as the vendor/ directory.

I don't always update go.mod, so for me the separation into these two commits was for myself for future reference in that it's clear next time I check the git log that we have go.mod bump as one part and the rest is plain sync-up.

The problem with two commits is that it breaks bisects. go build will complain about the mismatch between the version in vendor/ and the one in go.mod. What I'd do to bump the dependency is go get github.com/google/gops@latest && go mod tidy && go mod vendor. This will update go.mod, go.sum and vendor/ and can then be committed as one unit.
But I guess in this case it's also fine to keep the two separate commits for your reference, as bisectability shouldn't really a big issue here. Or maybe adding the command above helps for future reference as well?

Ah, good to know as well. Sure, I can still squash them together after CI is done/green adding the above to the commit decr. That should be fine & we won't need to rerun CI again.

Marked for backport to v1.8 as this also fixes an issue with port collision between gops agent and the proxy, see #13400. I'll send a manual backport PR as cherry-picking is not straight forward.

1.8 backport PR: #15634

Apologies, I forgot to mark this as backport-pending/1.8 when opening #15634. Done so now.


Added slack integration secure secret to .travis.yml

Wonder why this didn't trigger a notification in the #github channel on Slack...

Does this send a notification to slack?


Fix test case for table name case sensitive databases

Pull Request Test Coverage Report for Build 9061

0 of 0   changed or added relevant lines in 0 files are covered.
3 unchanged lines in 1 file lost coverage.
Overall coverage remained the same at 64.063%

Files with Coverage Reduction
New Missed Lines
%

sharding-orchestration/sharding-orchestration-core/src/main/java/org/apache/shardingsphere/orchestration/internal/util/IpUtils.java
3
76.0%

Totals

Change from base Build 210:
0.0%

Covered Lines:
9040

Relevant Lines:
14111

💛  - Coveralls


Move ClearCommand to global

Pull Request Test Coverage Report for Build 456

1 of 1 (100.0%)  changed or added relevant line in 1 file are covered.
No unchanged relevant lines lost coverage.
Overall coverage remained the same at 71.142%

Totals

Change from base Build 448:
0.0%

Covered Lines:
1950

Relevant Lines:
2741

💛  - Coveralls


Added missing error check

Description
Added missing error check
Fixes #270
Type of change

Bug fix (non-breaking change which fixes an issue)

Codecov Report

Merging #295 into master will decrease coverage by 0.08%.
The diff coverage is 50.00%.

@@            Coverage Diff             @@
##           master     #295      +/-   ##
==========================================
- Coverage   80.67%   80.58%   -0.09%
==========================================
  Files          15       15
  Lines        1578     1581       +3
==========================================
+ Hits         1273     1274       +1
- Misses        222      223       +1
- Partials       83       84       +1

Impacted Files
Coverage Δ

storage/storage.go
72.27% <50.00%> (-0.17%)
:arrow_down:

Continue to review full report at Codecov.

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


Adds manual testing instructions for find feature

Codecov Report

Merging #236 (5871948) into master (147e8ae) will not change coverage.
The diff coverage is n/a.

@@            Coverage Diff            @@
##             master     #236   +/-   ##
=========================================
  Coverage     77.01%   77.01%
  Complexity      699      699
=========================================
  Files            97       97
  Lines          2219     2219
  Branches        274      274
=========================================
  Hits           1709     1709
  Misses          412      412
  Partials         98       98

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 147e8ae...5871948. Read the comment docs.


Use the singleton instances for nullary data constructors

Currently, singleton instances for nullary data constructors are generated:
The example below is for [] constructor of the [a] data type.

public final class ZMZN extends ghc_prim.ghc.types.tycons.ZMZN
{
    public static ZMZN INSTANCE;

    static {
        ZMZN.INSTANCE = new ZMZN();
    }

    public int getTag() {
        return 1;
    }
}

But when generating the singleton accessor in the module class, we don't use this INSTANCE when we should:
ghc_prim.ghc.Types
    public static Closure DZMZN() {
        if (Types.DZMZN == null) {
            Types.DZMZN = (Closure)new ZMZN();
        }
        return Types.DZMZN;
    }

The function above should instead generate:
    public static Closure DZMZN() {
        return ghc_prim.types.datacons.ZMZN.INSTANCE;
    }

This should have a minor perf improvement + startup time improvement in that the new code will be compiled very quickly since it fits within the MaxTrivialSize parameter of the HotSpot JVM (and probably other JVMs too).
This is primarily a code generator change.

Implemented in aa41f67


Support trusts when you support private

The context of this feature request is when Cor / the object orientation system supports private attributes/routines/etc in contrast with Perl's traditional way of everything being public.
I feel that it is important to have a mechanism where otherwise-private methods (and maybe also attributes, but at least methods) can be effectively public within an inner circle of related and co-developed classes.
The main use case is when a feature conceptually presents a single unified API but for technical reasons has to be implemented using multiple classes.  The set of classes that together implement something in common can see each others' privates but external users of the collection can not.
An example of this is a factory pattern such as a container and inter-connected elements of the container where a container object must be used to create element objects and users may not instantiate an element object directly.  Conceptually the DBI ecosystem would be an example with the inter-connectedness of connection handles and statement handles that collectively are a single API and both kinds of objects would link to each other internally.
The requested feature manifests in different forms depending on the host language.

Raku calls it "trusts": https://docs.raku.org/language/typesystem#trait_trusts

.NET calls it "internal scope": https://docs.microsoft.com/en-us/dotnet/csharp/language-reference/keywords/internal

Java calls it "package-private" scope: https://docs.oracle.com/javase/tutorial/java/javaOO/accesscontrol.html

Personally I like the .NET model the most but it relies on the concept of assemblies which is more unique to .NET.  When entities are declared "internal" then anything in the same assembly can access it like it is public.  The assembly is loosely the .NET analogy to a CPAN distribution "lib" folder or a Java Jar or a DLL and is a multi-level namespace.
The Java model is fundamentally deficient in contrast, where the scope includes anything declared in the exact same namespace and only that namespace, which limits the organization of a class group across a hierarchy and also allows access by tests or other parties' code that is declared in the same Java package namespace.
The Raku model seems to be the best one for Perl to emulate.  It doesn't rely on assembly concepts and is strictly on an individual class-by-class basis; each class declares that it "trusts" one or more other classes, and only those named classes have the special privilege.  Since the feature request is only meant to exist within co-developed classes by the same author and is NOT meant to be about third-party extension, being closed to known parties is the whole point.
The simplest implementation is just on a whole-class level, where class X just declares it trusts class Y, and then class Y can invoke all of the private methods of class X but no one else can.
Another option which adds complexity but also control is we can have an extra scope such as "trusting" that is an alternative to "private" or "public" that methods can be declared with such that only those methods in X declared "trusting" may be invoked by Y and "private" is still restricted to "X".  This is what .NET/Java do, whereas I recall Raku is just all or none.  The simpler whole-class option is all I require, but this additional granularity is gravy if available.
A related feature request is that whole classes can be marked private or trusting, this is for when classes are only meant to be used internally and not be part of a public API.
A related feature request is that constructors of classes can independently be marked private or trusting which controls how objects can be instantiated.  So in the DBI analogy, a Statement class would be public but its constructor would be trusting so that only a Connection object may instantiate a Statement object but the public can then use it.
Please let me know if you have any questions.

This can be done in Perl by using a coderef in a lexical variable as the setter, and then making sure both classes are defined within the scope of the lexical variable.
Zydeco example:
use v5.16;
use Data::Dumper;

package Local::App {
	use Zydeco;

	my $shared_method;

	class SecretBox {
		has $secret (
			reader => 'spill',
			writer => \$shared_method,
		);

		factory new_secret ( Str $text ) {
			my $self = $class->new;
			$self->$shared_method( $text );
			return $self;
		}
	}

	class TrustedWriter {
		has box! ( type => SecretBox );

		method alter_box ( Str $text ) {
			$self->box->$shared_method( $text );
		}
	}
}

my $box = Local::App->new_secret( "Hello world" );

say $box->spill;
print Dumper($box);

my $writer = Local::App->new_trustedwriter( box => $box );
$writer->alter_box( "Bonjour monde" );

say $box->spill;
print Dumper($box);

Here's basically the same thing, just using plain Moo, so no truly private attributes:
use v5.16;
use Data::Dumper;

{
	package Local::App;

	my $shared_method;

	package Local::App::SecretBox {
		use Moo;

		has '$secret' => (
			is       => 'bare',
			init_arg => undef,
			reader   => 'spill',
		);

		$shared_method = sub {
			my ( $self, $text ) = ( shift, @_ );
			$self->{'$secret'} = $text;
		};
	}

	sub new_secret {
		my ( undef, $text ) = ( shift, @_ );
		my $self = 'Local::App::SecretBox'->new;
		$self->$shared_method( $text );
		return $self;
	}

	package Local::App::TrustedWriter {
		use Moo;

		has box => ( is => 'ro', required => 1 );

		sub alter_box {
			my ( $self, $text ) = ( shift, @_ );
			$self->box->$shared_method( $text );
		}
	}

	sub new_trustedwriter {
		my ( $self, @args ) = ( shift, @_ );
		my $self = 'Local::App::TrustedWriter'->new( @args );
		return $self;
	}
}

my $box = Local::App->new_secret( "Hello world" );

say $box->spill;
print Dumper($box);

my $writer = Local::App->new_trustedwriter( box => $box );
$writer->alter_box( "Bonjour monde" );

say $box->spill;
print Dumper($box);

For clarity, trusts would specifically only be between 2 classes.  In particular, something can not say it trusts a role.  The idea is that nothing can get itself trusted by something else, all the control is on the side of the one doing the trusting.

So I had a new realization that the visibility feature I considered so important, trusts/internal/etc, can likely for what I want be faked over top of a fundamental OO system that only natively has private+public.
I am speaking of the feature where internals of class X can be effectively public to classes Y and Z while effectively private to every other class.
As such I am no longer that concerned with the plan for Corinna version 1 to exclude more than the relatively simple and straight forward private+public dual.
The main scenario I was concerned with that traditionally benefitted from a trusts/etc feature involved connected objects that were mutually created exclusively by factory methods.
In this context, there would be at least a one-way internal reference between the objects, where the factory method of the first object provides a reference to itself via a constructor argument of the object of the other class it creates, and then the newer object stores the reference to its creator in one of its own instance members, and that is optionally exposed via an accessor so a user can ask the newer object who its parent is.
In this context, code in each of the 2 classes would often want to access each others' internals for reasons but no other classes should, and typically these internals would not be exposed publicly.
A hypothetical example is that a DBI statement handle is created by a DBI connection handle factory method, and so those 2 handle objects would have have access to each others' internals but non-DBI classes would not.
So an alteration to class design that can work around a lack of language-native trusts/etc is that each class which conceptually wants to have shared internals is implemented as a corresponding inner+outer pair of classes, where an object of outer has a private member which is an object of inner, and inner's members are all public and are the members that outer conceptually has.
In this context, the factory method of class X that makes an object of class Y would pass both the outer X and the inner X objects as arguments to the constructor of Y, and Y then stores both as private members, and Y never exposes the inner X object to the public, though it might expose the outer X object to the public.  And then code in Y has access to the internals of X via the inner X object and no other object has access to those internals if it wasn't made by a factory of X, except transitively.
I will still have to test this but I think it would probably work.

Closing out tickets that are post-MVP. We will revisit this later.


Don't work in python 3.12.3

It works for me. Could you please elaborate further on your issue? (e.g. are there any errors raised?)


Expand architecture to reflect the functioning of an HA Rancher cluster

The architecture page (https://rancher.com/docs/rancher/v2.x/en/overview/architecture/) would benefit from having a section following the 1 node architecture that details the functioning of an HA cluster.
How is traffic distributed between 3+ Rancher API Servers?
How do they negotiate quorum? (the latter may belong in the HA docs)
I think it makes sense to have a diagram here and perhaps links to quick start guides somehow branching off here for each of the architectures described.
There are a lot of architectures deployed in customer environments and of course, we would probably only want to approach the most recommended install methods for single node and HA here.  I think we should slim down the installation docs that are scattered around in some way so that the alternative methods are mentioned but don't pose a confusion hazard, even for those that arrive at those pages by direct link from somewhere.
Maybe offer a short blurp referencing the other different architecture options and links to relevant docs for them?

we should slim down the installation docs

The installation docs will eventually be somewhat rearranged so that the high availability installation is the default and the single node option is downplayed.
I agree that it makes sense to have separate diagrams for the single node rancher server and a high availability Rancher server cluster. I think this diagram has played a part in misleading people to believe that the Rancher server can be part of a user cluster, so this change should clarify things.
The other architecture for Rancher is an air gap installation. You can install Rancher on a single node or high availability cluster in an air gapped environment, but realistically speaking, the same people that care about security/air gap would probably also care about high availability. So I can see another diagram being made for a high availability/air gap Rancher server cluster, but the single node/air gap configuration might be unnecessary.

Closing this issue because it is addressed by https://github.com/rancher/docs/pull/1960


Repository field in package.json is improperly formatted

According to NPM docs, the repository field in package.json files should be formatted as such:
  "repository": {     "type": "git",     "url": "git+https://github.com/microsoft/FluidFramework.git"   },
Currently, it appears to be formatted as a string:
 "repository": "https://github.com/microsoft/FluidFramework.git"
This has caused a few issues with scripts that rely on the formatting.

@bekell We'd likely prefer the simpler "repository": "github:microsoft/FluidFramework" form. I assume that would satisfy downstream tooling.

The downstream tooling we've written relies on an object in the repository field instead of a string. However, this could arguably be considered a bug on our tooling since the shorthand version you provided is an acceptable format according to NPM docs.
Ideally we'd prefer if it was in object format, but understandable if you prefer the simpler shorthand format. We'll update our tooling if you end up going with the shorthand string format.


feat: aws s3 only feature and print error from ticdc

refer to https://github.com/pingcap-inc/tidb2dw/issues/64

Thanks for your contribution! But how about only add a new mode like export-only?

Sure, let's support the databricks first. And I will support the export-only mode for s3 and gcs.


🐛 Bug Report: plugin-scaffolder-node-test-utils cannot be imported as a dev dependency

📜 Description
When importing @backstage/plugin-scaffolder-node-test-utils (only published version seems to be 0.1.0-next.0)  in a test, yarn install works fine and downloads the dependency to node_modules, but running the test then fails with
Cannot find module '@backstage/plugin-scaffolder-node-test-utils' from 'actions/Xyz.test.ts'

The issue seems to be that @backstage/plugin-scaffolder-node-test-utils has an invalid package.json file. It defines the file index.esm.js as the entrypoint but the package output does not include such a file.

👍 Expected behavior
using createMockActionContext() from plugin-scaffolder-node-test-utils in a test should work rather than fail.
👎 Actual Behavior with Screenshots
Test suite failed to run

    Cannot find module '@backstage/plugin-scaffolder-node-test-utils' from 'actions/GetOwner.test.ts'

       9 | import { createMockActionContext } from '@backstage/plugin-scaffolder-node-test-utils';
      10 |
    > 11 | describe('xyz', () => {
         |                                        ^

      at Resolver._throwModNotFoundError (../../../node_modules/jest-resolve/build/resolver.js:427:11)
      at Object.<anonymous> (actions/GetOwner.test.ts:11:40)

👟 Reproduction steps
In a plugin directory, do yarn add --dev @backstage/plugin-scaffolder-node-test-utils, then yarn install.
Now write a test trying to use
import { createMockActionContext } from '@backstage/plugin-scaffolder-node-test-utils';

[...]

   const ctx = createMockActionContext({
      input: { [...] },
    });

📃 Provide the context for the Bug.
No response
🖥 Your Environment
No response
👀 Have you spent some time to check if this bug has been raised before?

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

🏢 Have you read the Code of Conduct?

[X] I have read the Code of Conduct

Are you willing to submit PR?
None

Ah, duplicate, sorry.
https://github.com/backstage/backstage/issues/23380


Increase timeout for email and import endpoints

Bug Description
I mentioned this on MM, but filing here to track it somewhere. The following URLs have a 504 gateway timeout, though they are long running operations. This causes some undefined errors in Indico which causes emails to be sent many times, or a potentially incomplete import operation.
POST https://events.canonical.com/event/NNN/manage/registration/NNN/registrations/email
POST https://events.canonical.com/event/NNN/manage/registration/NNN/registrations/import
If you could bump the timeout for this to several minutes this would be helpful.
To Reproduce
One simple way to test this is to import >500 users into an event registration using CSV.
Environment
events.canonical.com
events.staging.canonical.com
Relevant log output
--

Additional context
Once changed, we should confirm this works as expected, I'm not sure if there is also a client side read timeout involved in addition. The message I get is definitely server side though.

The timeout was changed for:
POST https://events.staging.canonical.com/event/NNN/manage/registration/NNN/registrations/email
POST https://events.staging.canonical.com/event/NNN/manage/registration/NNN/registrations/import

Test: 800 participants were successfully imported.


animation support?

Does anyone have an example for animation support if this directive allows it?

They are events, so just hook into the appropriate event lifecycle hooks.
The only not-very-elegant thing would be getting a reference to the chart. In the example, you already have one, but you would need grab it. I honestly can't remember what the event method signature is, you might get a reference to the chart. I would drop a debugger in there and see what you get.


Fix Tf load models

Hi @mckayward,
This PR contains the different possibilities about how to load a pretrained model on TF.
I've tried to be more clear as possible providing to you the different approachs in the INFO.md file.
You need to adapt a little bit the eval script(specifying the right path where to load the model) because I 've tested everything on a single container.

Thanks! I'm going to go ahead and merge this, and then pare it down before merging into FloydHub's version.


Fix for issue #51

I had to change to a more specific sinon dependency as the later version that I got at first broke all the tests.
The fix implemented allows for using Backbone.history.loadUrl() into an uninitialized subRoute (like in the blog examples).
Closes issue #51

LGTM :+1:


It is no more possible to read resource-labels generated in the release 1102.vde5663d777cf

It is not possible to read resource-labels from config file org.jenkins.plugins.lockableresources.LockableResourcesManager.xml generated in the release 1102.vde5663d777cf
resolve #434
Testing done

create config with resource-labels in 1102
update to 1106 - No label are there
remove all <string> and </string> from org.jenkins.plugins.lockableresources.LockableResourcesManager.xml
restart jenkins again - all labels are there

Submitter checklist

[x] The Jira / Github issue, if it exists, is well-described.
[x] The changelog entries and upgrade guidelines are appropriate for the audience affected by the change (users or developers, depending on the change) and are in the imperative mood (see examples).

The changelog generator for plugins uses the pull request title as the changelog entry.
Fill in the Proposed upgrade guidelines section only if there are breaking changes or changes that may require extra steps from users during the upgrade.

[ ] There is automated testing or an explanation that explains why this change has no tests.
[ ] New public functions for internal use only are annotated with @NoExternalUse. In case it is used by non java code the Used by {@code <panel>.jelly} Javadocs are annotated.
[ ] New or substantially changed JavaScript is not defined inline and does not call eval to ease the future introduction of Content Security Policy (CSP) directives (see documentation).
[ ] For dependency updates, there are links to external changelogs and, if possible, full differentials.
[ ] For new APIs and extension points, there is a link to at least one consumer.
[ ] Any localizations are transferred to *.properties files.
[ ] Changes in the interface are documented also as examples.

Maintainer checklist
Before the changes are marked as ready-for-merge:

[ ] There is at least one (1) approval for the pull request and no outstanding requests for change.
[ ] Conversations in the pull request are over, or it is explicit that a reviewer is not blocking the change.
[ ] Changelog entries in the pull request title and/or Proposed changelog entries are accurate, human-readable, and in the imperative mood.
[ ] Proper changelog labels are set so that the changelog can be generated automatically. See also release-drafter-labels.
[ ] If the change needs additional upgrade steps from users, the upgrade-guide-needed label is set and there is a Proposed upgrade guidelines section in the pull request title (see example).
[ ] java code changes are tested by automated test.

@MarkEWaite can you please check my English here. Maybe you has better idea, how we can inform user about breaking changes. My first think was to update release-change-logs. But it is not correct, because update to any new release need the same information. And this will be not applicable. I think, this kind is fine.


IBM-Swift/Kitura-StencilTemplateEngine#6

added Loader to the context, with the path of as the parent of the
rendered template file

@ianpartridge please review the PR.

Looks good to me, @vadimeisenbergibm - do you want to merge it or shall I?

@ianpartridge please merge


put the pod string into data area of request

put the pod string into data area of request
make the resource(service, pod, vm and image) 's delete operation as DELETE method

This fix makes the request url clean without pod data, put the pod data string into data area of the request.  And adding DELETE operation for resource(such as service, pod, vm and image) 's delete operation.
API change list

kill vm

old
POST /vm/kill?vmId=vm-xxxx
new
DELETE /vm?vmId=vm-xxxx

remove service

old
POST /service/delete"?podId=pod-xxxx&service=xxx
new
DELETE /service?podId=pod-xxxx&service=xxx

remove pod

old
POST /pod/remove?podId=pod-xxxx
new
DELETE /pod?podId=pod-xxxx

remove image

old
POST /images/remove?imageId=xxxx
new
DELETE /image?imageId=xxxx

create pod

old
POST /pod/create?podArgs={"id":"xxx", "containers":.....}
new
POST /pod/create
put the pod data string into request, and set Content-Type to application/json.

run pod

old
POST /pod/run?podArgs={"id":"xxx", "containers":.....}
new
POST /pod/run
put the pod data string into request, and set Content-Type to application/json.

PS. This patch will impact the hypernetes
Test Result
root@ubuntu:/home/lei/src/github.com/hyperhq/hyper# ./hyper images
REPOSITORY     TAG                 IMAGE ID                           CREATED             VIRTUAL SIZE
busybox        latest              3d5bcd78e074                2015-10-21 05:56:30              1.1 MB
root@ubuntu:/home/lei/src/github.com/hyperhq/hyper# ./hyper rmi busybox
Image(busybox) is successful to be deleted!
root@ubuntu:/home/lei/src/github.com/hyperhq/hyper# ./hyper pull busybox
latest: Pulling from busybox
bf0f46991aed: Pull complete
3d5bcd78e074: Pull complete
busybox:latest: The image you are pulling has been verified. Important: image verification is a tech preview feature and should not be relied on to provide security.
Digest: sha256:5551dbdfc48d66734d0f01cafee0952cb6e8eeecd1e2492240bf2fd9640c2279
Status: Downloaded newer image for busybox:latest
root@ubuntu:/home/lei/src/github.com/hyperhq/hyper# curl -X POST http://<IP_ADDRESS>:12345/pod/create -d "$(cat examples/ubuntu.pod)" -H "Content-Type: application/json"
{"Cause":"","Code":0,"ID":"pod-QALerbrTch"}
root@ubuntu:/home/lei/src/github.com/hyperhq/hyper# vim examples/ubuntu.pod
root@ubuntu:/home/lei/src/github.com/hyperhq/hyper# curl -X POST http://<IP_ADDRESS>:12345/pod/create -d "$(cat examples/ubuntu.pod)" -H "Content-Type: application/json"
{"Cause":"","Code":0,"ID":"pod-qUPYFiXNzt"}
root@ubuntu:/home/lei/src/github.com/hyperhq/hyper# ./hyper list
         POD ID                      POD Name             VM name    Status
 pod-QALerbrTch   test-container-create-busyb                       pending
 pod-qUPYFiXNzt   test-container-create-busyb                       pending
root@ubuntu:/home/lei/src/github.com/hyperhq/hyper# curl -X DELETE http://<IP_ADDRESS>:12345/pod?podId=pod-QALerbrTch
{"Cause":"","Code":0,"ID":"pod-QALerbrTch"}
root@ubuntu:/home/lei/src/github.com/hyperhq/hyper# curl -X DELETE http://<IP_ADDRESS>:12345/pod?podId=pod-qUPYFiXNzt
{"Cause":"","Code":0,"ID":"pod-qUPYFiXNzt"}
root@ubuntu:/home/lei/src/github.com/hyperhq/hyper# ./hyper list
         POD ID                      POD Name             VM name    Status
root@ubuntu:/home/lei/src/github.com/hyperhq/hyper# ./hyper images
REPOSITORY     TAG                 IMAGE ID                           CREATED             VIRTUAL SIZE
busybox        latest              3d5bcd78e074                2015-10-21 05:56:30              1.1 MB
root@ubuntu:/home/lei/src/github.com/hyperhq/hyper#

LGTM


Feature: support for SAMLv2 IdPs

SAML is still cool!

@sjauld will be in v0.1.31 that is building as I type this.

Legendary!


[BETA] SASS section doesn't work

Challenge Name

http://beta.freecodecamp.com/en/challenges/sass/store-data-with-sass-variables
Issue Description

Seems like sass section doesn't work yet.
Browser Information

Browser Name, Version: Opera 47.0
Operating System: MacOS
Mobile, Desktop, or Tablet: Desktop

Your Code

Learn Sass

Some random title

This is a paragraph with some random text in it

Header #2

Here is some more random text.

Here is another header

Even more random text within a paragraph

Screenshot

This is a known issue. We're closing this but will definitely get this working before we push beta to production.


Nothing loads from any shimmie sites in v5.2.4, but they load in v5.0.0a1

When I load anything from and/or add sources from simmie sites (v5.2.4) they don't show any images, tags sometimes show up but still no images.
I tried using an older version (v5.0.0a1) and it worked perfectly. Could it be a bug?
First time posting here, thanks.

Oh really? Maybe that explains my issue over at #558 as of 11 days ago.

It indeed sounds like a bug, especially if it affects the Shimmie boards included in the release (r34, shishnet, etc.). However I could not reproduce on my end.
So that I can be sure we're talking about the same websites, on which boards did you try exactly?
Did you try a clean install? (i.e. deleting the contents of C:\Users\%USERNAME%\AppData\Local\Bionus\Grabber and installing again) I know of people having non-working Sankaku for whom this fixed the issue.

Perhaps it's worth noting that the Wiki says Shimmie is supported but not 100%.

Yeah, because lots of Shimmie have custom stuff going on, and there's custom Shimmie versions around which are not compatible with the original version.
The Grabber supports mainly the official one, that is the one here:
http://shimmie.shishnet.org/v2/
But I don't mind adding semi-custom code to support big boards that made small modifications.


Add backport request handler

Issue #, if available:
Description of changes:
Add a /backport handler to the prow plugin, currently for go, but should be able to work for other projects as well.
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

/approve


AddAndGetCircomProof IsOld0 issue

I used MerkleTree.AddAndGetCircomProof to get the CircomProcessorProof for my circuit use. It could generate the zkp for the first inserted leaf, but if I inserted a new leaf, it would occur assert failed error while generating zkp
Assert Failed.
Error in template ForceEqualIfEnabled_229 line: 56
Error in template SMTProcessor_235 line: 243

I found out that the IsOld0 of CircomProcessorProof for the second inserted leaf should be false, but when I executed MerkleTree.AddAndGetCircomProof to get the zkp for the second inserted leaf, the IsOld0 was true.
Below is the test code.
package main

import (
	"context"
	"fmt"
	"math/big"

	"github.com/iden3/go-merkletree-sql/v2"
	"github.com/iden3/go-merkletree-sql/v2/db/memory"
)

func main() {
	context := context.Background()

	treeStorage := memory.NewMemoryStorage()
	mt, err := merkletree.NewMerkleTree(context, treeStorage, 5)
	if err != nil {
		panic(err)
	}

	key1 := big.NewInt(0)
	value1 := big.NewInt(12)

	key2 := big.NewInt(1)
	value2 := big.NewInt(13)

	proof1, err := mt.AddAndGetCircomProof(context, key1, value1)
	if err != nil {
		panic(err)
	}

	proof2, err := mt.AddAndGetCircomProof(context, key2, value2)
	if err != nil {
		panic(err)
	}

	fmt.Printf("IsOld0 for leaf1: %v\n", proof1.IsOld0)  // true
	fmt.Printf("IsOld0 for leaf2: %v\n", proof2.IsOld0)  // true
}

I think the problem is on 194 line, I cannot set 0 for key, otherwise IsOld0 will be set to true.


dump.rdb

Hi,
Why didn't I find this file “dump.rdb”. Thx u ve much.

Hi,  This is the database file of redis ~= 5， maybe the storage system has changed in the recent versions... The name is not important, just for sure that you have successfully import the data.

ok , thx u again.
---Original---
From<EMAIL_ADDRESS>Date: Thu, Jul 23, 2020 17:42 PM
To<EMAIL_ADDRESS>Cc: "Author"<author<EMAIL_ADDRESS>Subject: Re: [THUDM/CogQA] dump.rdb (#23)
Hi,  This is the database file of redis ~= 5， maybe the storage system has changed in the recent versions... The name is not important, just for sure that you have successfully import the data.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or unsubscribe.

我想问下，为什么我在训练集中数据，对应的supporting factor在fully wiki库中很多都没有索引到呀。。

@Two222 应该是有的


router-perf-v2 touchstone_compare Error: Issue capturing results from elasticsearch using config

When I run router-perf in Jenkins https://mastern-jenkins-csb-openshift-qe.apps.ocp-c1.prod.psi.redhat.com/job/scale-ci/job/e2e-benchmarking-multibranch-pipeline/job/router-perf/351/console. Got the error below.
touchstone_compare --database elasticsearch -url xxxx:443 -u xxxx --config /home/jenkins/ws/workspace/multibranch-pipeline_router-perf/workloads/router-perf-v2/mb-touchstone.json -o csv --output-file /home/jenkins/ws/workspace/multibranch-pipeline_router-perf/workloads/router-perf-v2/ingress-performance.csv --rc 0
touchstone - ERROR - Error: Issue capturing results from elasticsearch using config {'filter': {'test_type': 'http'}, 'buckets': ['routes', 'conn_per_targetroute', 'keepalive'], 'aggregations': {'requests_per_second': ['avg'], 'latency_95pctl': ['avg']}}
touchstone - ERROR - Error: Issue capturing results from elasticsearch using config {'filter': {'test_type': 'edge'}, 'buckets': ['routes', 'conn_per_targetroute', 'keepalive'], 'aggregations': {'requests_per_second': ['avg'], 'latency_95pctl': ['avg']}}
touchstone - ERROR - Error: Issue capturing results from elasticsearch using config {'filter': {'test_type': 'passthrough'}, 'buckets': ['routes', 'conn_per_targetroute', 'keepalive'], 'aggregations': {'requests_per_second': ['avg'], 'latency_95pctl': ['avg']}}
touchstone - ERROR - Error: Issue capturing results from elasticsearch using config {'filter': {'test_type': 'reencrypt'}, 'buckets': ['routes', 'conn_per_targetroute', 'keepalive'], 'aggregations': {'requests_per_second': ['avg'], 'latency_95pctl': ['avg']}}

I read https://github.com/cloud-bulldozer/e2e-benchmarking/pull/332 and thought my Jenkins job may need update to reflect the change in https://github.com/jaredoconnell/e2e-benchmarking/blob/8af52a9d0e3c66d9df3b3c07acb29e746a58b7b8/workloads/router-perf-v2/env.sh#L24-L31

Hi @qiliRedHat, if you pay attention to the log lines, they say that touchstone couldn't find any metric using those filters, it seems like it was able to find mix termination metrics but it's missing the http, edge, passthrough and reencrypt ones.
Also, I've seen that the selected termination was mix, the problem is that the touchstone configuration file in this repo is meant to be used with all terminations, we would need to include a new one for each termination

@rsevilla87 As you said with all TERMINATIONS specified, the problem didn't reproduce.
04-07 18:15:20.013  touchstone_compare --database elasticsearch -url https://search-perfscale-dev-chmf5l4sh66lvxbnadi4bznl3a.us-west-2.es.amazonaws.com:443 -u b85440ee-bfe9-4983-a3bf-5b3ef978932f --config /home/jenkins/ws/workspace/multibranch-pipeline_router-perf/workloads/router-perf-v2/mb-touchstone.json -o csv --output-file /home/jenkins/ws/workspace/multibranch-pipeline_router-perf/workloads/router-perf-v2/ingress-performance.csv --rc 0
04-07 18:15:25.241  Thu Apr  7 10:15:24 UTC 2022 Installing requirements to generate spreadsheet


feat: adds deduplicate_token on Tokens. adds settings on Tenants

Description

adds deduplicate_token on Tokens. adds settings on Tenants

Testing required outside of automated testing?

[x] Not Applicable

Screenshots (if appropriate):

[x] Not Applicable

Rollback / Rollforward Procedure

[x] Roll Forward
[ ] Roll Back

Reviewer Checklist

[ ] Description of Change
[ ] Description of outside testing if applicable.
[ ] Description of Roll Forward / Backward Procedure
[ ] Documentation updated for Change

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


feat: null element support (POC)

Summary

Test plan

Codecov Report
Attention: Patch coverage is 81.25000% with 12 lines in your changes missing coverage. Please review.

Project coverage is 93.58%. Comparing base (d218336) to head (264d123).

Files with missing lines
Patch %
Lines

src/constructs/quantifiers.ts
66.66%
3 Missing :warning:

src/encoder.ts
84.61%
2 Missing :warning:

src/builders.ts
83.33%
1 Missing :warning:

src/constructs/capture.ts
75.00%
1 Missing :warning:

src/constructs/char-class.ts
88.88%
1 Missing :warning:

src/constructs/lookahead.ts
75.00%
1 Missing :warning:

src/constructs/lookbehind.ts
75.00%
1 Missing :warning:

src/constructs/negative-lookahead.ts
75.00%
1 Missing :warning:

src/constructs/negative-lookbehind.ts
75.00%
1 Missing :warning:

Additional details and impacted files
@@             Coverage Diff             @@
##              main     #104      +/-   ##
===========================================
- Coverage   100.00%   93.58%   -6.42%
===========================================
  Files           17       17
  Lines          160      187      +27
  Branches        42       55      +13
===========================================
+ Hits           160      175      +15
- Misses           0       12      +12

Flag
Coverage Δ

93.58% <81.25%> (-6.42%)
:arrow_down:

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

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


samples: migrate samples from GoogleCloudPlatform/java-docs-samples /pubsub/cloud-client

Looks like you already migrated these and there are no changes here - closing.


AttributeError: type object 'DB' has no attribute '_async_session_maker'

INFO:     <IP_ADDRESS>:56046 - "POST /auth/token/login HTTP/1.1" 500 Internal Server Error
ERROR:    Exception in ASGI application
Traceback (most recent call last):
  File "/data/homes/fractal/.conda/envs/fractal/lib/python3.8/site-packages/uvicorn/protocols/http/h11_impl.py", line 404, in run_asgi
    result = await app(  # type: ignore[func-returns-value]
  File "/data/homes/fractal/.conda/envs/fractal/lib/python3.8/site-packages/uvicorn/middleware/proxy_headers.py", line 78, in __call__
    return await self.app(scope, receive, send)
  File "/data/homes/fractal/.conda/envs/fractal/lib/python3.8/site-packages/fastapi/applications.py", line 269, in __call__
    await super().__call__(scope, receive, send)
  File "/data/homes/fractal/.conda/envs/fractal/lib/python3.8/site-packages/starlette/applications.py", line 124, in __call__
    await self.middleware_stack(scope, receive, send)
  File "/data/homes/fractal/.conda/envs/fractal/lib/python3.8/site-packages/starlette/middleware/errors.py", line 184, in __call__
    raise exc
  File "/data/homes/fractal/.conda/envs/fractal/lib/python3.8/site-packages/starlette/middleware/errors.py", line 162, in __call__
    await self.app(scope, receive, _send)
  File "/data/homes/fractal/.conda/envs/fractal/lib/python3.8/site-packages/starlette/middleware/cors.py", line 84, in __call__
    await self.app(scope, receive, send)
  File "/data/homes/fractal/.conda/envs/fractal/lib/python3.8/site-packages/starlette/exceptions.py", line 93, in __call__
    raise exc
  File "/data/homes/fractal/.conda/envs/fractal/lib/python3.8/site-packages/starlette/exceptions.py", line 82, in __call__
    await self.app(scope, receive, sender)
  File "/data/homes/fractal/.conda/envs/fractal/lib/python3.8/site-packages/fastapi/middleware/asyncexitstack.py", line 21, in __call__
    raise e
  File "/data/homes/fractal/.conda/envs/fractal/lib/python3.8/site-packages/fastapi/middleware/asyncexitstack.py", line 18, in __call__
    await self.app(scope, receive, send)
  File "/data/homes/fractal/.conda/envs/fractal/lib/python3.8/site-packages/starlette/routing.py", line 670, in __call__
    await route.handle(scope, receive, send)
  File "/data/homes/fractal/.conda/envs/fractal/lib/python3.8/site-packages/starlette/routing.py", line 266, in handle
    await self.app(scope, receive, send)
  File "/data/homes/fractal/.conda/envs/fractal/lib/python3.8/site-packages/starlette/routing.py", line 65, in app
    response = await func(request)
  File "/data/homes/fractal/.conda/envs/fractal/lib/python3.8/site-packages/fastapi/routing.py", line 217, in app
    solved_result = await solve_dependencies(
  File "/data/homes/fractal/.conda/envs/fractal/lib/python3.8/site-packages/fastapi/dependencies/utils.py", line 500, in solve_dependencies
    solved_result = await solve_dependencies(
  File "/data/homes/fractal/.conda/envs/fractal/lib/python3.8/site-packages/fastapi/dependencies/utils.py", line 500, in solve_dependencies
    solved_result = await solve_dependencies(
  File "/data/homes/fractal/.conda/envs/fractal/lib/python3.8/site-packages/fastapi/dependencies/utils.py", line 525, in solve_dependencies
    solved = await solve_generator(
  File "/data/homes/fractal/.conda/envs/fractal/lib/python3.8/site-packages/fastapi/dependencies/utils.py", line 449, in solve_generator
    return await stack.enter_async_context(cm)
  File "/data/homes/fractal/.conda/envs/fractal/lib/python3.8/contextlib.py", line 568, in enter_async_context
    result = await _cm_type.__aenter__(cm)
  File "/data/homes/fractal/.conda/envs/fractal/lib/python3.8/contextlib.py", line 171, in __aenter__
    return await self.gen.__anext__()
  File "/net/nfs4/pelkmanslab-fileserver-common/data/homes/fractal/fractal-server/fractal_server/app/db/__init__.py", line 59, in get_db
    async with cls._async_session_maker() as async_session:
AttributeError: type object 'DB' has no attribute '_async_session_maker'

Patch:

diff --git a/examples/server/fractal_server/migrations/env.py b/examples/server/fractal_server/migrations/env.py
index 093d0b1..60188ed 100644
--- a/examples/server/fractal_server/migrations/env.py
+++ b/examples/server/fractal_server/migrations/env.py
@@ -6,7 +6,8 @@ from sqlalchemy.engine import Connection
 from sqlmodel import SQLModel

 from fractal_server.app import models  # noqa
-from fractal_server.config import settings
+from fractal_server.config import get_settings
+from fractal_server.syringe import Inject

 # this is the Alembic Config object, which provides
 # access to the values within the .ini file in use.
@@ -41,6 +42,7 @@ def run_migrations_offline() -> None:
     script output.

     """
+    settings = Inject(get_settings)
     context.configure(
         url=settings.DATABASE_URL,
         target_metadata=target_metadata,
@@ -66,8 +68,9 @@ async def run_migrations_online() -> None:
     and associate a connection with the context.

     """
-    from fractal_server.app.db import engine
+    from fractal_server.app.db import DB

+    engine = DB.engine_async()
     async with engine.connect() as connection:
         await connection.run_sync(do_run_migrations)


Carried LM-types PR and modified with new models

cc @lewtun I carried your former PR and modified with new models for text-generation task page

@lewtun I wanted to add your commit signature email to merger notes coauthor section but couldn't find it in the notes of your PRs, can you give that through slack?


Check binder

Fixes for binder

I will merge it after I updated the requirements to the release and checked if everything is working :)


[crypto] renaming NamespaceKeys -> namespace::Keys

This PR applies four changes all related to the same issue: naming in crypto.

Use namespaces to differentiate different algorithm keys (ed25519::Ed25519PublicKey becomes ed25519::PublicKey (see rational below).
Prefix specific crypto traits with T to avoid name collisions (because people like to import traits::* and we can't do use traits::* as _ in rust yet.
Rename private/public key into signing/verifying key (this gives a good indication as to what type of keys we're handling).
Rename multi ed25519 signing/verifying "key" into signing/verifying "keys".

The biggest change is obviously the use of namespaces to indicate what types of keys we are using.
The rational is that:

from the point of view of the ed25519 library, a key is just a key
from the point of view of the caller, rust provides namespace just for this

@matbd @thefallentree I don't think this is a breaking change, hence I didn't tag the PR with "breaking". Tell me if I'm wrong : o

see https://github.com/libra/libra/pull/3441

This PR applies four changes all related to the same issue: naming in crypto.

Use namespaces to differentiate different algorithm keys (ed25519::Ed25519PublicKey becomes ed25519::PublicKey (see rational below).

Prefix specific crypto traits with T to avoid name collisions (because people like to import traits::* and we can't do use traits::* as _ in rust yet.

Rename private/public key into signing/verifying key (this gives a good indication as to what type of keys we're handling).

Rename multi ed25519 signing/verifying "key" into signing/verifying "keys".

The biggest change is obviously the use of namespaces to indicate what types of keys we are using.
The rational is that:

from the point of view of the ed25519 library, a key is just a key

from the point of view of the caller, rust provides namespace just for this

IMO we shouldn’t change to signing and verifying key. How does this help in practice at this stage?

@kchalkias I don't have a strong preference towards signing/private verifying/public, I did this change to avoid name collisions in @matbd 's tool.


Resolve issue for running code remotely

Resolve issue for running code remotely when running machine's switch inconsistent with remote ones.

@juhlee-microsoft azure cases don't go here


[RFC] yalc push -i

yalc push -i would prompt the user for each dependent package. Then the user could choose explicitly which packages to push to.

What is your use case when you push many packages at once?


DOCS-#2943: Document modin.engines.base.io, modin.engines.base.series

What do these changes do?

Note for reviewers: additionally docstrings and high-level documentation for modin.backends.pandas.parsers was added. Also code duplication in modin.engines.base.io.io was eliminated by usage of Pandas Appender decorator.

I think we want to have a separate section on the readthedocs for Modin developers.
I don't think we need a .md file next to ordinary ones, as reading it locally, while is not techincally hard, gives worse impression than is possible with the RTD.
So I think I'd like to see the "explanatory documentation" as a separate entitity on the RTD.

@vnlitvinov , @devin-petersohn we can add additional clause in the Developer Section/System Architecture part in the RTD and add links to the files from docs/flow/ as it done in the last commit. Is it appropriate solution?

Overall very nice.
One question would be - how the reader is expected to get from main page on readthedocs to flow subpages you've written here?

Thanks for the comments! I have added a note in the docs/index.rst with mentioning of implementation docs.
P.S. docstrings were formatted according to requirements of script from https://github.com/modin-project/modin/pull/2968.

Restarting CI

@vnlitvinov Should we mark these as blocked by #2968?

@devin-petersohn  I think we can merge this and fix stuff that script would find later to keep stuff rolling.

Please, look at this. Also, I would prefer to mark classes, specific engines, backends and alike in rst documentation (for example, enclose to <something>) to make these more highlighted.

For specific parts highlighting double back quotes (``) are used as it is done in the rest of System architecture docs.

Also, add files documented with docstrings to CI for check, please.

Files were added into CI.

@amyskov , please, resolve the conflicts.

@amyskov , please, resolve the conflicts.

Conflicts were resolved. Also links to pandas API was added for modin.engines.base.io.io.


How to Output Embedded Sentence Vector?

https://github.com/hanxiao/bert-as-service
I hope this project can help you.

what i mean is use self_models to output sentence vector rather than Google pre-trained models


NameError: name 'yoact_base_config' is not defined

How can I resolve the error in running eval.py? NameError: name 'yoact_base_config' is not defined

maybe check the spelling
--config=yolact_base_config


doc: [scorecard] - Proposal to check the security of the operators

Description of the change:
Proposal
Motivation for the change:
Improve tooling to ensure the QA

/test e2e-aws-helm
/test e2e-aws-ansible
/test e2e-aws-subcommand

@camilamacedo86 I notice there are specific aspects of this proposal that are specific to OpenShift. Are you proposing that these tests are only run in the context of OpenShift operators?
In our upstream repo, we are trying to remove OpenShift-specific code, tests, and documentation, so could you update the proposal to either remove the OpenShift-specific references OR move the OpenShift-specific ideas to a separate section so it's clear what you're proposing would belong upstream vs downstream?

HI @joelanford,

@camilamacedo86 I notice there are specific aspects of this proposal that are specific to OpenShift. Are you proposing that these tests are only run in the context of OpenShift operators?
No. @dmesser made questions related to OCP but the proposal in order to attend these concerns in any k8s platform.

do you see this test running a security scan on the operator image?  or is that out of scope?

HI @jmccormick2001,
I thought more in the common basic validation over the k8s resources used by it.  What do you suggest regards security scan on the operator image? May we can add here at least of a future idea of improvement. WDYT?

HI @jmccormick2001,
I thought more in the common basic validation over the k8s resources used by it. What do you suggest regards security scan on the operator image? May we can add here at least of a future idea of improvement. WDYT?

yeah, perhaps with clair/quay going open source, they have a security scan API that could be called to do the scan, not sure, but that has crossed my paths before as something that would have been useful in validating image security before it goes to a registry or out into the public domain.

Hi @jmccormick2001,
WDYT about we keep here what is in our controller only at least for now since? I mean this proposal is about we check the values in resources gen/managed by it. Then, in the future, we may have a better idea to improve it?
Regards the chair/quay it will validate the security of the images which are pushed to the quay, so IHMO would be out of the scope since it is not about the common security practices for k8s resources in this platforms. WDYT?
Are you ok with?

Hi @joelanford and @jmccormick2001,
Add a line (36) in order to clarify your points.  Please, let me know what do you think and if we could merge this one.

ok, I think I understand the scope and purpose of this now, that being to implement the security standards that kubesec.io v2 is recommending.  I wonder if this is considered standard or is this just one vendor's recommended list? the proposal might make the case as to why this is the security recommendations that we would get behind (build tests for).

I wonder if this is considered standard or is this just one vendor's recommended list? the proposal might make the case as to why this is the security recommendations that we would get behind (build tests for).
This are the common standards / good practices no matter the vendor. Following a summary regards the reasons:

Resources limits defined (memory/CPU): See here you can find a good explanation and some ref links.
Regards the capability as SYS_ADMIN and CAP_SYS_ADMIN and the mage be rootless: See https://github.com/operator-framework/operator-sdk/pull/2140#discussion_r343676733 where I added a very good reference. Also, I'd recommend checking my blog post here for a better understanding of how the containers work and why we can compromise the host if the user in the container has root access your permissions to check the process (/proc/). However, you can find a lot of other articles and references over the same subjects in the internet.

Closing this for now. Tracked idea internally to allow discussions over.


front-end-cli has a problem

There is a type error in the cli. this abi Object need to be daiContractConfig.abi.abi

below is the package version info.
{
  "name": "react-next-wagmi",
  "version": "0.0.1",
  "private": true,
  "scripts": {
    "dev": "next dev",
    "build": "next build",
    "start": "next start",
    "lint": "next lint"
  },
  "dependencies": {
    "ethers": "^6.9.2",
    "next": "^13.4.0",
    "react": "^18.2.0",
    "react-dom": "^18.2.0",
    "zksync-ethers": "^6.0.0"
  },
  "devDependencies": {
    "@types/node": "^17.0.31",
    "@types/react": "^18.0.9",
    "@types/react-dom": "^18.0.3",
    "eslint": "^8.15.0",
    "eslint-config-next": "^12.1.6",
    "typescript": "^5.0.4"
  }
}

sorry i may issued in a wrong place


Fix value vs object identity error (closes #39)

And BTW…
json_logging/__init__.py:193:8: E1003: Bad first argument 'self.__class__' given to super() (bad-super-call)

And no, I won't make another 1liner PR, it is easy to fix yourself.

And BTW…
json_logging/__init__.py:193:8: E1003: Bad first argument 'self.__class__' given to super() (bad-super-call)

And no, I won't make another 1liner PR, it is easy to fix yourself.

when do u see it happen?

released https://pypi.org/project/json-logging/1.0.6/

when do u see it happen?

The above is pylint output. pip install + call it. You call is still Python2.


wrong versioning description in contributing.rst

Describe the bug
This does not describe our current versioning system:
Parsl follows the ``major.minor[.maintenance[.build]]`` numbering scheme for versions. Once major features
for a specific milestone (minor version) are met, the minor version is incremented and released via PyPI and Conda.
Fixes to minor releases are made via maintenance releases.

Expected behavior
Correct description of our version numbering

fixed by #2465


[HELP] Relay activating on on startup /  dont react

I have a Raspberry Pi 2 Model B. If the script starts, the relay activating automatic. If I want to open or close the garage door using the website the relay gives no response.
The relay is on GPIO 23.
I try to change:
42 gpio.output(self.relay_pin, False) <--was True
72 gpio.output(self.relay_pin, True) <--was False
73 time.sleep(0.2)
74 gpio.output(self.relay_pin, False) <--was True
But thats not working either.
I hope someone can help me out.

both codes to activate the relay:
Gpio.output (self.relay_pin, False)
Gpio.output (self.relay_pin, True)
Only while using "gpio.cleanup()" the relay deactivate.
what am I doing wrong here?

I read that to carry out my error arises from an error in the RPi.GPIO. To fix this you need to enable device tree in config.tx using "device_tree=on" and to run "sudo apt-get install python-dev-python rpi.gpio" in terminal. I'm going to try if this helps!


Use local model data archive if available.

This makes packaging easier.

Thanks @hobbes1069 I've managed to make our build work with the patch here. It wasn't super trivial though, so it'd be nice to have this documented somehow.

Updating the README is simple enough, but how often will the model data change? When it does we would have to remember to update the URL in the README... Another option would be to use a redirect. It may be as easy as creating a symbolic link between the latest data file, something like:
ln -s lpcnet_191005_v1.0.tgz lpcnet_latest.tgz
I need to check if apache automatically treats that as a redirect or not... Then when new model data is here, you just update the link.

Ok, redirects are a little more complicated, so the file downloaded would end up being lpcnet_latest.tgz, I don't see that as a huge issue. Thoughts?

Redirects will be a good improvement, but as a start, I was really thinking of just adding here a note indicating that the test data can be retrieved either automatically via cmake's build process or via http://rowetel.com/downloads/deep/ .
But, that web page needs to be configured at least to show the files available in that directory as in http://ftpmirror.gnu.org/hello/

Oh and perhaps more importantly, to mention that it should be downloaded to build/ without extracting that tar file before building. I learned that after reading the CMakeLists.txt file - that's what I meant that isn't trivial.

I need to think about this some more. Also, I'm working out how to handle packaging. This shouldn't get packaged as a separately library as its sole purpose is for freedv mode 2020.


docs/sourcetree.md: add command to set Python version inside poetry's virtualenv

No objections, but I wonder why you'd want to specify a different python version?

To have the exact same environment we have in CI. Python 3.8 is the default
on Ubuntu 20.04, while we use Python 3.7 in CI. There were some issues with
package updates with pipenv: different versions were resolved when using
different Python versions, which resulted in huge useless diffs. Hopefully
it's not issue with poetry anymore, though.
On Thu, Feb 10, 2022 at 3:13 PM Heikki Linnakangas @.***>
wrote:

No objections, but I wonder why you'd want to specify a different python
version?
—
Reply to this email directly, view it on GitHub
https://github.com/zenithdb/zenith/pull/1254#issuecomment-1034851048,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAJ4XLLI7AGNVU4LK4LBCO3U2OTWJANCNFSM5OALNZEA
.
Triage notifications on the go with GitHub Mobile for iOS
https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675
or Android
https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.
You are receiving this because you authored the thread.Message ID:
@.***>

3.7 in CI was suggested by @funbringer  but we can easily change it to 3.8 (or any other) if need.

@LizardWizzard, I think the note is still worth it for completeness: we already warn users that newer Pythons may do something different than our CI.

@yeputons CI now uses 3.9.2 is that still a problem? See https://github.com/neondatabase/docker-images/blob/main/rust/Dockerfile#L59
I'm ok with the change, if it's still needed let's fix the version number in the doc and merge.
P.S. Highly recommend using pyenv. It allows you to easily install any python version and even configure it on a per-directory basis. Personally, I have venv for zenith managed by pyenv and it is smoothly picked up by poetry. Maybe for that you'll need something like that in your poetry.toml:
[virtualenvs]
create = false

@LizardWizzard ,

CI now uses 3.9.2 is that still a problem?

Hmm, how about we bump the minimal supported version to 3.9 then? There are some incompatibilities between Python 3.9 and currently claimed minimal version 3.7, which we may accidentally use. poetry is smart enough to pick up the Python specified in pyproject.toml and err if it's not available, so updating it should be ok.
I'd say using a newer version still may cause problems (e.g., the default on Ubuntu 22.04 LTS is backward-incompatible Python 3.10), so I'd keep the few lines which tell the user how to pinpoint the version they want.
I intend to merge the new three commits as is without squashing.


Assigned direct feed card is wiped after signing out and back in on mobile

If you haven’t already, check out our contributing guidelines for onboarding and email<EMAIL_ADDRESS>to request to join our Slack channel!

Version Number:
Reproducible in staging?:
Reproducible in production?:
If this was caught on HybridApp, is this reproducible on New Expensify Standalone?:
If this was caught during regression testing, add the test name, ID and link from TestRail:
Email or phone of affected tester (no customers):
Logs: https://stackoverflow.com/c/expensify/questions/4856
Expensify/Expensify Issue URL:
Issue reported by: @joekaufmanexpensify
Slack conversation (hyperlinked to channel name): ts_external_expensify_expense
Action Performed:
Prerequisite: User added a company card

Assign the card to a member
Sign out of the app and sign back in to the app.
Click company cards from more features

Expected Result:
Card assigned is displayed in cards page
Actual Result:
Assign card page displayed and assigned details are wiped out
Workaround:
Unknown
Platforms:

Which of our officially supported platforms is this issue occurring on?

[ ] Android: Standalone
[ ] Android: HybridApp
[ ] Android: mWeb Chrome
[x] iOS: Standalone
[x] iOS: HybridApp
[ ] iOS: mWeb Safari
[ ] MacOS: Chrome / Safari
[ ] MacOS: Desktop

Screenshots/Videos

Add any screenshot/video evidence

View all open jobs on GitHub

@joekaufmanexpensify did we want to make this external? I'm missing the linked convo that produced this bug report.

Initial discussion is here! It stalled a bit and I am not sure if this can be external as there was discussion of an API issue. I just bumped the thread to get resolution on that.

Hey Im Artem and taking this one

Just started the investigation on friday, today have more time and looking into this

This PR might help with this https://github.com/Expensify/Web-Expensify/pull/44833

This should be fixed with BE change

@mountiny thats will be great as it looks like data is just missing and optimistically serves before logout

This is now fixed


Feature/puppet

Added puppet support. Let me know of anything to change and i'll complete ASAP.
 Squash all those unnecessary commits.

There are some Rubocop violations on the code changes. Please run:
bundle exec rake lint

to check your Ruby syntax against the Rubocop rules for the project.
You should rebase against the develop branch to so this merges cleanly. The conflicts are minor and should be pretty obvious and easy to sort out.
Thanks!

LGTM!


[Bug]: Can't connect to the server

Application
Outline Client
Describe the bug
After upgrading to version 1.13.0 I can't connect to the server on iOS
Steps to reproduce

Open the application
Click "Connect" button

What did you expect to happen?
No response
What actually happened?
No response
Outline Version
1.13.0
What operation system are you using?
iOS
Operating System Version
No response
Screenshots and Videos

Rebooting the device helped


Level 37: The system cannot find the path specified.

After completing level 36, level 37 description was followed by the sentence The system cannot find the path specified.
Typing githug reset have this output:

Thanks for your great game.

Same thing on level 39.

sh@sh-PC[mingw64]:git_hug(master) $ githug test push_branch
D:/msys64/mingw64/lib/ruby/gems/2.3.0/gems/githug-0.4.4/lib/githug/game.rb:38:in test_level': undefined method full_description' for false:FalseClass (NoMethodError)
from D:/msys64/mingw64/lib/ruby/gems/2.3.0/gems/githug-0.4.4/lib/githug/cli.rb:24:in test'         from D:/msys64/mingw64/lib/ruby/gems/2.3.0/gems/thor-0.14.6/lib/thor/task.rb:22:in run'
from D:/msys64/mingw64/lib/ruby/gems/2.3.0/gems/thor-0.14.6/lib/thor/invocation.rb:118:in invoke_task'         from D:/msys64/mingw64/lib/ruby/gems/2.3.0/gems/thor-0.14.6/lib/thor.rb:263:in dispatch'
from D:/msys64/mingw64/lib/ruby/gems/2.3.0/gems/thor-0.14.6/lib/thor/base.rb:389:in start'         from D:/msys64/mingw64/lib/ruby/gems/2.3.0/gems/githug-0.4.4/bin/githug:4:in <top (required)>'
from D:/msys64/mingw64/bin/githug:23:in load'         from D:/msys64/mingw64/bin/githug:23:in '

                               Githug                                    *

Thanks for the report. This could be a Windows specific issue. I don't have access to a Windows machine currently, I'll try to see what is going on with these 2 levels.

It seems that shell commands with 2> /dev/null in these levels do not run on Windows..

On Windows, /dev/null should instead be NUL I believe.  I'm going to have a go at fixing this!


Can I trigger a write to Influx on every piece of sensor information?

(This may affect more than just writes to Influx, but it is where I have noticed the issue)
I have an MQTT sensor that measures household power.  HA receives the data and writes it to Influx.  However, it only appears to write when the value changes.  Long periods of constant power use do not get updates, leading to a graph as shown below:

The green line is what I see given the blue sensor points, but the red line is what I would expect. (Please forgive the scrawl, it seemed the easiest way to illustrate the situation).
Can I make each piece of sensor data be written, even if it is the same as the last one?

The crux of the issue is here - https://github.com/sdague/home-assistant/blob/90ca6a09987496f83ef1c7513da896913c841614/homeassistant/components/influxdb.py#L104 - influxdb is only listening to state changes. It would need to change to MATCH_ALL for that to work.

The crux is actually at the state machine: https://github.com/balloob/home-assistant/blob/dev/homeassistant/core.py#L511-L512
A state update is ignored if the new reported state is exactly the same as the previous state.
This is not something that can be changed as all of Home Assistant depends on this.
In your case, how come that power usage was exactly the same for 7 minutes while before it was showing minor fluctuations?

The sensor only updates once per watt-hour of consumption, so at low power levels very small fluctuations often get smoothed out.  I presume the earlier period was just near some boundary condition, and something changed ever-so-slightly to move it away from that, hence showing a fairly static power level.
Would it be realistic to look into the possibility of marking selected sensors as "every value is important"?  I can see that for presence detecting you might only want to view changes in state, but for viewing (and ultimately for analysing) power usage, it is relevant to have positive confirmation that the power usage is the same now as it was a few minutes ago.  Or do you think this is something that should not fall within the domain of Home Assistant? I set this up because HA provided a ready made way of writing MQTT sensor data to Influx alongside all the other HA information - I could find an alternative method of logging the sensor data that doesn't omit points.

I think it should fall within the domain of Home Assistant.
Looking at the different components, this is something that is only relevant for sensor entities with a unit of measurement - but not all of them. It depends if the platform is caching data that it gets from device/cloud or that it is actually retrieving the latest information when new data is polled. Only in the last case would we want to send a state changed event.
I need to give this some more thought.

I wrote an workaround in the z-wave sensor module for my motion detection that only fired "on"  events and was subject for the same problem as here. If we could fire state events that has not changed then that workaround might be removed as well. Maybe it could be a new kind of event, "state reported"

@alanbowman in Grafana, when you create your graph there is a fill option when using influxdb as a data source. You can set that to fill(previous) and that should turn your example graph into a steep cliff instead of a slope like you showed.
Example raw query I use for temperatures:
SELECT last("value") FROM "°F" WHERE "domain" = 'sensor' AND $timeFilter GROUP BY time($interval), "entity_id" fill(previous)


Reading serial data

When I receive data from the event 'onReadDataFromPort', how can I format as a readable UTF-8 string?  I believe its currently being passed as hex chars.
Thanks for the great contribution!

I hope it works for you.
Worked for me

onConnectedDevice() {
RNSerialport.writeString("HELLO");
}
onReadData(data) {
let str = "";
let characterCount = data.length;
for(let i = 0; i< characterCount; i+=2) {
str += String.fromCharCode(parseInt(data.substr(i, 2), 10));
}
alert(str) //string
}

I tested it with Arduino
My arduino code

void setup() {
Serial.begin(9600);
}
void loop()
{
if(Serial.available())
{
String k = Serial.readString();
if(k == "HELLO")
Serial.write("Hello World");
}
}


[RELAY][RUNTIME] Add compute and schedule attributes for all ops in relay/op/tensor.py

This PR ports over schedule and compute attributes for the operators in tensor.py. I hope this will serve as an example of adding this behavior for operators so others in the community can help continue the work of making Relay operator complete.
I simply copied over the same scheduling primitives from NNVM, and am using out of the box compute functions. Feedback much appreciated.
For details on helping with the rest of the operators please read here #2050.
cc @tqchen @MarisaKirisame @slyubomirsky @zhiics @siju-samuel

this code seems way too highly repetitive to me.
this is a typical snippet of _tensor.py, with every other line being virtually like this.
def sqrt_compute(attrs, inputs, output_type, target):     assert len(inputs) == 1     return [topi.sqrt(inputs[0])]  register_compute("sqrt", sqrt_compute) register_schedule("sqrt", schedule_broadcast)
there are 3 things:
define, which assert len and use topi
register_compute
register_schedule
register_compute, register_schedule could be merged into one single function
sqrt_compute can be made into one line by writing a hof that take two argument (the topi func and num of input)
If I were to write this, I will declare a table that store the name, and the num of input, traverse it, and define function with metaprogramming, to minimize the chance of error, and to maximize reuse(other code that build ontop of relay can simply read the table).
Of course, it might be going too far for tvm coding style, but fusing register_compute/register_schedule is certainly doable, and so is using a hof.

@MarisaKirisame the argument against that style (which is roughly) what NNVM has done is that it becomes much harder for users to read and modify. Most code is effectively read-only, and especially code like this will not change often. I think it is better to err on repetitive and readable than inscrutable.

It seems that we have several classes named as Module including the ones from runtime. I am totally okay with them, but would it be a little confusing for TVM beginners? But again, I like the renaming from Environment to Module as it is more friendly to those who are familiar with LLVM.

Merge this in and will update the follow-up on #2059 to depend on this


Reliability and Issues running in parallel with Docker Desktop

The current script is a great, educational example on how one can use vnpkit to use WSL2 in a VPN environment.
I ended up making a number of adjustments to the script to:
a) If the script is executed again, kill all lingering processes from last run both on windows and linux side, as currently it would start to stack processes and wouldn't work right.
#pre-cleanup any running processes
echo "Cleaning up anything left running..."
PROCS=("socat" "vpnkit-tap-vsockd")
for value in "${PROCS[@]}"
do
while pidof $value; do
echo "Killing ${value}...$(pidof $value)"
kill $(pidof $value)
done
done
b) Look up the vpnkit parent id before killing to ensure I'm not killing an active 'docker desktop' instance of vpnkit.
cleanup_vpnkit() {
PIDS="$(${POWERSHELL_PATH} -Command "(Get-Process "vpnkit").Id")"
echo "PIDS: $PIDS"
mypids=( $(echo "$PIDS" | fmt -999) )
for i in "${mypids[@]}"; do
PID="$(echo "$i" | tr -d '\n' | tr -d '\r')"
PARENT="$(${POWERSHELL_PATH} -Command "(Get-Process -Id ((gwmi win32_process |? processid -eq $PID).parentprocessid)).ProcessName" | tr -d '\n\r')"
echo "Parent: '$PARENT'"
if [ ! "$PARENT" = "Docker Desktop" ]; then
echo "Delete it!"
${POWERSHELL_PATH} -Command "Stop-Process -Id $PID"
else
echo "Keep it!"
fi
done
}
Lastly, I wrapped the script with something that runs it in a tmux and pipes output to a log file, then I run that via wsl cli in the background (windows batch script):
#!/bin/bash
#---start go script
if [ ! "$(id -u)" = "0" ]; then
echo "Not root, calling self as root..."
sudo -E sh -c "$0"
exit "$?"
else
echo "Running as root..."

for i in $(ps -ef | grep "/bin/sh ./wsl-vpnkit" | grep -v grep | awk '{print $2}'); do kill $i; done
fi
if ps -ef | grep -v grep | grep "/bin/sh ./wsl-vpnkit" >/dev/null; then
echo "Wait 60 sec for graceful death..."
sleep 60
fi
if ps -ef | grep -v grep | grep "/bin/sh ./wsl-vpnkit" >/dev/null; then
echo "Not so graceful kill of older processes..."
for i in $(ps -ef | grep "/bin/sh ./wsl-vpnkit" | grep -v grep | awk '{print $2}'); do kill -9 $i; done
fi
#startup
echo "Starting up..."
cd /opt/wsl-vpnkit
if [ -f "./wsl-vpnkit.out" ]; then
mv ./wsl-vpnkit.out ./wsl-vpnkit.out.$(date +'%Y%m%d%H%M%S')
fi
tmux new -d './wsl-vpnkit > ./wsl-vpnkit.out 2>&1'
#---end go script
The windows batch script contents:
wsl -d <my_wsl_distribution> /opt/wsl-vpnkit/go &
This seems to be working pretty reliably for me, so I wanted to share.
I do hope Microsoft either includes a solution like this, or otherwise identifies an alternative solution to make WSL2 work cleanly in VPN environments.  Until then, this is working nicely!

One last note on this.  I'm still left with docker-desktop killing all vpnkit instances (including my wsl-vpnkit instance), I don't have a workaround for that.  But with the above solution, I can just re-run my batch script and I'll be back up and running in no time.

It looks like simply copying 'vpnkit.exe' to something different, i.e. 'wsl-vpnkit.exe' and calling that in the script resolves docker desktop stomping on it.

Thanks, and it's great to hear that you've found the script useful. I'll see about addressing the points you raised in a future PR.

@jamesdboone I've incorporated some of your script with #15 and #19.


Rdrp 856 filterout pnp fn

Pull Request submission

changed filter_PNP_data helper function to reset index and drop the old one
added test_filter_PNP_data unit test to test_staging_helpers

Closes or fixes

Detail the ticket(s) you are closing with this PR
Closes # RDRP-856

Code

[ ] Code runs The code runs on my machine
[ ] Conflicts resolved There are no conflicts (I have performed a rebase if necessary)
[ ] Requirements My/our code functions according to the requirements of the ticket
[ ] Dependencies I have updated the environment yaml so it includes any new libraries I have used
[ ] Configuration file updated any high level parameters that the user may interact with have been put into the config file (and imported to the script)
[ ] Clean Code

[ ] Code is as PEP 8 compliant as I can humanly make it
[ ] Code passess flake8 linting check
[ ] Code adheres to DRY

[ ] Type hints All new functions have type hints

Documentation
Any new code includes all the following forms of documentation:

[ y] Function Documentation Docstrings within the function(s')/methods have been created

[y ] Includes Args and returns for all major functions
[ ] The docstring details data types

[ ] Updated Documentation: User and/or developer working doc has been updated

Data

[ ] All data needed to run this script is available in Dev/Test
[ ] All data is excluded from this pull request
[ ] Secrets checker pre-commit passes

Testing

[ y] Unit tests Unit tests have been created and are passing or a new ticket to create tests has been created

Peer Review Section

[ ] All requirements install from (updated) requirements.txt
[ ] Documentation has been created and is clear - check the working document
[ ] Doctrings (Google format) have been created and accurately describe the function's functionality
[ ] Unit tests pass, or if not present a new ticket to create tests has been created
[ ] Code runs The code runs on reviewer's machine and/or CDSW

Final approval (post-review)
The author has responded to my review and made changes to my satisfaction.

[ ] I recommend merging this request.

Review comments
Insert detailed comments here!
These might include, but not exclusively:

bugs that need fixing (does it work as expected? and does it work with other code
that it is likely to interact with?)
alternative methods (could it be written more efficiently or with more clarity?)
documentation improvements (does the documentation reflect how the code actually works?)
additional tests that should be implemented (do the tests effectively assure that it
works correctly?)
code style improvements (could the code be written more clearly?)
Do the changes represent a change in functionality so the version number should increase? Start a discussion if so.
As a review you can generates the same outputs from running the code

Your suggestions should be tailored to the code that you are reviewing.
Be critical and clear, but not mean. Ask questions and set actions.

docstring has been tidied up...
tests rerun successfully
This change is part of the requirement to:
AC1 BERD data is isolated from the full dataset
AC3 BERD separated data set is in a format that can be used during
the BERD pipeline run (a pandas dataframe and a CSV QA file)


update doc for native_histogram_bucket_limit to reflect resolution re…

…duction

Updated doc for native_histogram_bucket_limit config to reflect automatic resolution reduction done in https://github.com/prometheus/prometheus/issues/12864.

I was unaware of this PR when I created #14483. You were first, but now #14483 is already merged. Sorry for that.


Rework generated APIs for better compatibility

The problems
Problem 1: changes in data class properties
Currently all request/response types for domain commands are data classes. While these are easy to declare on library side, and use on the consumer side, they can cause a bunch of compatibility issues when they evolve.
Because we automatically generate the domain types and commands from the protocol definitions, we don't really control changes. More specifically, we cannot "remember the past" and keep some methods (with DeprecationLevel.HIDDEN) for backwards binary compatibility - everything is generated based on a single version of the protocol, without knowledge of past (and obviously future) versions. On top of that, additions and removals of experimental properties in the tip-of-tree version of the protocol (which is the one used by chrome-devtools-kotlin) are quite common.
It is unlikely that users instantiate event types and command response types themselves (apart from mocks/tests) because that's done by this library itself when deserializing inbound frames. However, most of our domain commands have the form fun myCommand(input: MyCommandRequest): MyCommandResponse, so users have to build a MyCommandRequest instance every time they call such method. This makes those compatibility issues a real problem (not just hypothetical).
Problem 2: Commands don't all have a request and response type
In the initial API design, I had decided that when a command doesn't take any parameter, it is pointless to create a -Request input type and have an input argument of that type in the command's method. It is more convenient for the user to just call a no-arg method, instead of creating an instance of an empty class just for the sake of calling the method.
However, this means that if a command didn't have any parameter in a previous version of the protocol, but has one (even optional) in a future version, the corresponding method will go from 0 arguments to 1 argument, which is a backwards-incompatible change (even if the argument has a default value). The same is true the other way around if all command parameters are dropped: the method will lose its input argument.
Similarly, if a command doesn't return any result, no output -Response type is created, and the corresponding method has a Unit return type. This can cause similar binary compatibility issues if we go from 0 to more result values and vice-versa.
Problem 3: experimental warnings
Another (minor) problem caused by using data class constructors directly is that experimental types or properties in the input generate opt-in warnings for the data class constructor. We can't mark the whole constructor as experimental, as that would be painful and misleading for the user (because the class itself is not experimental). However, we could mark individual builder properties as experimental.
Proposal
Request builders and factory functions
To mitigate problem 1, it would be best to limit the number of places where users need to call the all-property constructors of such data classes. Since the biggest offender should by far be the command's -Request types, we could focus on them and keep data classes for event and response types (which likely only affect tests, for which binary compat is unnecessary).
We could provide nice builders for those request classes and possibly factory functions with builder lambdas where callers can set properties, which would be both source and binary backwards compatible. For example:
public data class GetEventListenersRequest(
  public val objectId: RemoteObjectId,
  public val depth: Int? = null,
  public val pierce: Boolean? = null,
) {
  public class Builder(
    public val objectId: RemoteObjectId? = null
    public var depth: Int? = null
    public var pierce: Boolean? = null

    public fun build(): GetEventListenersRequest = GetEventListenersRequest(
        objectId ?: error("objectId is mandatory"),
        depth,
        pierce,
    )
  }
}

fun GetEventListenersRequest(init: GetEventListenersRequest.Builder.() -> Unit): GetEventListenersRequest {
    return GetEventListenersRequest.Builder().apply(init).build()
}

// usage
val request = GetEventListenersRequest {
    objectId = someObjectId
    depth = 42
    // we don't have to provide all optional properties
}
session.someCommand(request)

The problem with this approach is that mandatory properties are not checked at compile time. An improvement would be:
public data class GetEventListenersRequest(
  public val objectId: RemoteObjectId,
  public val depth: Int? = null,
  public val pierce: Boolean? = null,
) {
  public class Builder(
    public val objectId: RemoteObjectId,
  ) {
    public var depth: Int? = null
    public var pierce: Boolean? = null

    public fun build(): GetEventListenersRequest = GetEventListenersRequest(objectId, depth, pierce)
  }
}

fun GetEventListenersRequest(objectId: RemoteObjectId, optionalArgsInit: GetEventListenersRequest.Builder.() -> Unit = {}): GetEventListenersRequest {
    return GetEventListenersRequest.Builder(objectId).apply(optionalArgsInit).build()
}

// usage
val request = GetEventListenersRequest(objectId = someObjectId) {
    depth = 42
    // we don't have to provide all optional properties
}

// usage with no optional property
val request = GetEventListenersRequest(objectId = someObjectId)

But then we have a new binary incompatibility issue if a mandatory argument becomes optional.
Convenient overloads for command methods
No matter what we decide here, we could actually forget about the factory function, and directly do exactly the same but at the domain command method level. Using the same example:
class DOMDebuggerDomain(...) {

  // basic command method with request object
  suspend fun getEventListeners(input: GetEventListenersRequest): GetEventListenersResponse = ...

  // convenient overload with mandatory params + lambda for optional params
  suspend fun getEventListeners(
      objectId: RemoteObjectId,
      optionalArgs: GetEventListenersRequest.Builder.() -> Unit = {},
  ): GetEventListenersResponse {
    val builder = GetEventListenersRequest.Builder(objectId)
    val input = builder.apply(optionalArgs).build()
    return getEventListeners(input)
  }
}

A few more thoughts. The final design in the linked post is not perfect: mandatory properties are not checked at compile time, which is a problem IMO. Mandatory properties cannot be added or removed safely anyway without breaking backwards compatibility. For this reason, I believe those mandatory properties could be provided as arguments instead of inside a configuration lambda:
val person = Person(name = "Robert", age = 32) {
    nickName = "Bob"
}

Some stats to inform the decision. Here is the diff between https://github.com/ChromeDevTools/devtools-protocol/tree/a5b6b3ebc9922bf681fbd260cb0f8bdc75fb067b (2021-01-06) and https://github.com/ChromeDevTools/devtools-protocol/tree/5bd2c6ad07beefd20b96f8bbf1c8497564f08341 (2022-08-15):
{
    "commandStats": {
        "inputParams": {
            "added": {
                "mandatoryNonXp": 0,
                "mandatoryXp": 0,
                "optionalNonXp": 15,
                "optionalXp": 12
            },
            "removed": {
                "mandatoryNonXp": 0,
                "mandatoryXp": 0,
                "optionalNonXp": 3,
                "optionalXp": 0
            },
            "changed": {
                "mandatoryToOptional": 8,
                "optionalToMandatoryNonXp": 0,
                "optionalToMandatoryXp": 0,
                "noLongerExperimental": 0,
                "becameExperimental": 1
            }
        },
        "outputParams": {
            "added": {
                "mandatoryNonXp": 3,
                "mandatoryXp": 0,
                "optionalNonXp": 1,
                "optionalXp": 1
            },
            "removed": {
                "mandatoryNonXp": 0,
                "mandatoryXp": 0,
                "optionalNonXp": 0,
                "optionalXp": 0
            },
            "changed": {
                "mandatoryToOptional": 0,
                "optionalToMandatoryNonXp": 0,
                "optionalToMandatoryXp": 0,
                "noLongerExperimental": 0,
                "becameExperimental": 0
            }
        }
    },
    "eventStats": {
        "added": {
            "mandatoryNonXp": 4,
            "mandatoryXp": 4,
            "optionalNonXp": 1,
            "optionalXp": 1
        },
        "removed": {
            "mandatoryNonXp": 0,
            "mandatoryXp": 0,
            "optionalNonXp": 0,
            "optionalXp": 0
        },
        "changed": {
            "mandatoryToOptional": 1,
            "optionalToMandatoryNonXp": 0,
            "optionalToMandatoryXp": 0,
            "noLongerExperimental": 0,
            "becameExperimental": 0
        }
    }
}

Based on the details above, here is what I think we should do.

Commands with 0 parameters:

No input class, no builder
Command method with no arguments

Commands with 0 optional parameters (and at least 1 mandatory parameter)

Input class with no builder
Command method with mandatory arguments, but no lambda builder argument
Command method with input class argument (with no default value)

Commands with at least 1 optional parameter (with or without mandatory params)

Input class with builder
Command method with mandatory parameters + a lambda builder parameter with default value {} + @JvmDefaults to make sure we still have the overload without builder argument
Command method with input class argument (with no default value)


ol.extent.getArea is not in the Api

The functions ol.extent.getWidth and ol.extent.getHeight and ol.extent.isEmpty are in the api, but why not ol.extent.getArea?
Cheers,
-Polar

Can I create a PR?

@cs09g yes, please create a PR

Thanks!
Cheers,
-Polar
On Wed, May 31, 2017 at 2:25 AM, Frédéric Junod<EMAIL_ADDRESS>wrote:

@cs09g https://github.com/cs09g yes, please create a PR
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/openlayers/openlayers/issues/6854#issuecomment-305096068,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AAAlEcUYJxIpvK4EtXOyGD525rSvo6iaks5r_QfygaJpZM4NoG3C
.


d3d-interop sample update

fixed uninitialized nv12_cpu_copy surface, remove odd code

@alalek pls, take a look

:+1:


[lightbeam] replace asserts by Errors in module.rs / translate_only

Just a simple PR to replace some asserts by Errors, i have not modify the code logic.
I notice that translate_only is translating wasm module linearly. In short that means that if the import section is after the table function you will get an Error.
I think this function should be rewrite to translate all the sections whatever their order inside the module.

@sunfishcode CI failed but it's not related to this PR.

Thanks!


Improve the README by removing outdated information

Fixes #8055.
Moreover, this patch:

changes the milestones link to the projects link (as we do not use milestones anymore);
removes information about weekly public meetings (as they're not being done anymore);
contains minor text fixes.

The two removed links are now on the wiki page, and the dead link has been changed to a Web Archive link.

Trivial.


Please update pip package

Master has a few useful features. Can you update version please?

Yes will do.