New behavior of --feature + --package combination

A tracking issue for #5353 and #5351. Historically, --feature and related flags applied to the current package, and not to the package, specified via --package. This is a bug, but fixing it could break someone's code, so currently new behavior exists under -Z package-features opt-in. We need to check if it breaks code in the wild to see what we should do next.

https://github.com/rust-lang/cargo/issues/5362 is I think the manifestation of the old odd behavior.

Announcement on irlo: https://internals.rust-lang.org/t/help-us-test-the-breaking-bug-fix-to-cargo-features/7317

I think https://github.com/rust-lang/cargo/issues/4942 is also this issue.

And https://github.com/rust-lang/cargo/issues/4753 as well

(typo in the issue description: --pacakge)

This broke Servo unfortunately, so we probably would need to back this out, at least in this, maximally aggressive, form.
However, I wonder what we plan to do with feature-selection problems in general?
I assume that we want to eventually fix the main problem with features. Currently, features are global per compilation, and that means that features bleed from dev-deps to normal deps and that cargo build -p foo and cargo build -p foo -p bar build the foo package differently.
Fixing that, however, would be a breaking change: suddenly, Cargo would select a smaller set of features :-(
But, if we do fix that, then behavior of the combination of --package and --features would necessary change as well. In other words, this PR is sort of a subset of that larger issue.
The core question I think is do we feel comfortable with eventually changing the set of activated features? If we are, then I think we can modify current fix to not flatly error-out, but to ignore the features argument for several packages, printing a warning like "this was accepted in previous versions of Cargo and activated features in surprising way, and not it is ignored".

$ cargo +stable test --all --features xyz

Used to work. And expectation was "Enable the specified futures for crates that support it".

$ cargo +nightly test --all --features xyz
error: cannot specify features for more than one package

Now we see this (thanks to CI to catch it soon and not after Rust release) and it does not matter whether all of workspace members have xyz or not, error is the same.
#5390 wasn't a good idea without a compatibility explanation (what is it? how to fix that mystical error? how it will work in future?). That error must have contained at least the issue number (since it is a breaking future and it is in nightly (i.e. unstable) anyway).

And expectation was "Enable the specified set of futures for crates that support it".

Not that this expectation is wrong. What actually happens is that the feature is enabled only for the package in the current working directory. In other words, it is irrelevant whether all members have the xyz feature, because this applies only to a single member, and not the one that is specified via the -p argument.

That error must have contained at least the issue number

That was definitely an oversight on my part :(

has affected builds without --package?

--all is a shorthand for --package member1 --package member2 --package member3 etc, and suffers the same problem: --feature flag does not apply to the selected packages. I've extended the example at https://github.com/matklad/features-behavior to show how this affects --all.

Breaking changes to stable functionality are not acceptable. Please revert and find a way to make this opt-in.
However weird and subjectively broken the old behavior is, it has been around for more than long enough that many large projects have built work-arounds that came to rely on it. It’s easy to say this in hindsight, but I think it shouldn’t be surprising that a change like this is definitely gonna break some builds.
https://github.com/rust-lang/cargo/pull/5390, the PR that enable this change by default, says:

So far, the feedback on https://internals.rust-lang.org/t/help-us-test-the-breaking-bug-fix-to-cargo-features/7317 has been positive

At the time of that writing, that forum thread was 2 days old and had responses from three individuals, one of them saying their build is broken. How is this "positive" enough?
But even if that discussion had received community-wide attention, breakage like this without opt-in is still unacceptable IMO. The projects most likely to be affected are those with complex build system that involve many crates. They may or may not be involved in the day-to-day development of Rust and Cargo.

Now if we are going to make a change around feature selection, in addition to being opt-in (possibly through edition = "2018" in the root crate or workspace?) I think we should spent a lot more time and involve more people to consider what the new behavior should be. In particular, fixing https://github.com/rust-lang/cargo/issues/4463. And possibly separating the notions of “Choosing which of the several 'root' artifacts in a workspace (each with its dependency graph and feature selection)” and “Choosing a subset of one dependency graph”.

Because of this cargo bug stdsimd has been silently not testing some feature combinations (https://github.com/rust-lang-nursery/stdsimd/pull/569). That this produces no warnings whatsoever worries me.

Breaking changes to stable functionality are not acceptable.

This is incorrect. Breaking changes to stable functionality are acceptable if the functionality was broken, otherwise we couldn't ever fix any bugs.
The question that we have to resolve here is whether this functionality is broken.

but in this particular case it is clear that a number of projects have been negatively impacted

After going through this and related issues, including the servo one, the only thing that's clear to me is that this change has broken the build of some projects. But I haven't been able to find anything about why did the build broke, was it an error in how the build was set up? was the previous behavior intended ?
This change would have broken the build of stdsimd too, and in doing so it would have discovered a bug in stdsimd's CI that we would have long fixed.

Just to not get things mixed up:

The “new behavior” mentioned in this issue’s title is the one enabled in https://github.com/rust-lang/cargo/pull/5353 and reverted in https://github.com/rust-lang/cargo/pull/5430.
The “current behavior” is the one that has existed for as long as workspaces and feature flags have both existed, and is the same in today’s Stable and Nightly.

Breaking the build in a way unrelated to unstable features is negative impact. I don’t remember the details at this point, but we had found work-arounds for the current behavior’s weirdness, and in applying those work-arounds had come to rely on the current behavior.
The new behavior was present in Nightly for about two weeks (between https://github.com/rust-lang/rust/pull/49939 and https://github.com/rust-lang/rust/pull/50344). I don’t know why the stdsimd bug was not discovered during that time. For Servo we have a daily Travis-CI job that overrides the pinned rust-toolchain file in the repo and tries to build with the latest Nightly, notifying a few people if that fails.

a proper fix probably will cause some breakage […] IMHO it is worth suffering some breakage here.

Breakage and fix v.s. neither are not the only options! We can have a configuration in the workspace’s root Cargo.toml to make the behavior change opt-in.

Note also that the breakage will mostly only affect continuous integration testing, and not users building/testing packages manually and depending on them transitively.

IIRC this was not the case with Servo, we could build at all. I’m not sure why you make this distinction by the way, CI is designed to be as close as possible to other usage.

We are at an impasse here.
If we make this change opt-in, we don't break any code in the wild. This is good because it does not break code in the wild that's correctly working as intended. At the same time, this is bad because there is code in the wild that's silently broken, and this change does neither fix it nor alert the maintainers of this code that it needs fixing. If we make this opt-out, we break the broken code, which is good, but we also break the correct code, which is bad.
Honestly, we are here because the current behavior is too implicit, different people expected it to behave differently, and things just silently happened to work.
A compromise solution to this problem might be to just fix the implicitness. We could just add two flags, that enable the different behaviors, and just start warning that all projects should explicitly specify which behavior they want. That will be better than what we currently have, it does not break any code, and it does let people with broken code know that their code might be broken.
Whether we ever turn this warning into an error or not, and how we would do that, is the most controversial part of this issue, and something that we don't really have to discuss right now.

Then I assumed wrong about Servo... why are you using --package with multiple packages for any other reason than testing? Is this easy to change to mitigate the breakage caused by #5353? I tried following the links above but didn't find much information.

We can have a configuration in the workspace’s root Cargo.toml to make the behavior change opt-in.

IMO this is an ugly solution — many users will forget or not know about this, then be surprised when down the road they find thing doesn't work with feature foo despite cargo test --package thing --feature foo being in their CI.
Cargo's configuration and usage is already complex with significant documentation users need to read to understand various features. Adding further configuration options should not be a preferred option IMO.

A compromise solution ... We could just add two flags

At least this doesn't implicitly do the wrong thing for anyone, and if it only shows up when using --feature with --package / --all then it doesn't affect everyone else. Acceptable, but I'd still prefer that this is just "fixed" for everyone (with easy solutions for those affected).

Okay it's incredibly frustrating that combining --package with --features is completely broken and does not produce any warnings or errors at all. Anyone assuming that cargo implements the reasonable expected behaviour here will see CI feature tests pass without issue, having no indication that crates are simply being built without the features enabled.
It's frustrating to see that there was a fix made and then suddenly reverted, with no other mitigation or progress since. This seems to be a pretty obvious footgun where most cases seem to be people using --all or -p X and not realising the interactions/implications, with parts of code silently just not being built or tested. It happens to work when a root crate has feature = ["child_crate/feature"]. With no root crate, using --features should probably error to indicate it's broken (#5849) or otherwise just use the fixed behaviour.

Breaking the build in a way unrelated to unstable features is negative impact. I don’t remember the details at this point, but we had found work-arounds for the current behavior’s weirdness, and in applying those work-arounds had come to rely on the current behavior.

Relying on obviously broken and weird behaviour, considering it to be a workaround in build scripts, not using other workarounds that rely on more established reasonable behaviour (like changing CWD rather than using -p/--all), and never expecting it to be fixed seems kind of unreasonable? There are solutions that could be employed to cause less breakage or even be partially or fully compatible with the old behaviour, but it seems unclear from this issue and the surrounding discussion why or how the old behaviour was relied on in the first place.

@arcnmx breaking changes, whether they're fixing bugs or not, take care when approaching. We can't apply this change and then say "y'all deal with the fallout, it's a change for the better anyway". Our policy is that we would slowly roll out this change, providing warnings and such along the way. For example we would need to:

Add a configuration switch to enable the new beahvior
Add warnings today when the new behavior and the current behavior differ
Push to the ecosystem, evaluate fallout
Eventually, when ready, change the defaults.

This takes a lot of work and no one has been sufficiently motivated to drive it to completion.

Apologies if this has already been covered upthread, but would it be possible to make this change for virtual workspaces specifically? In that case, there is no current package, so it seems less likely to break the world.

Yeah, my intention is to revive the discussion here and determine what intermediate steps and migration plans are possible, it's just quite frustrating that the proper behaviour is inaccessbily stuck gated behind an unstable/nightly flag. My main points of concern are:

Considering that virtual workspaces are completely broken to my knowledge when combined with feature flags, straight-up enabling the expected/fixed behaviour there would be a good way to address #5849. Otherwise it really should error outright to prevent confusion by the current false assurance that everything is just fine.

as long as there's agreement that the new behaviour is correct (considering the original PR was approved, presumably is)

Identifying why the change broke things in the first place, as I'm unable to find explanations of how and why the broken behaviour is currently relied on by existing projects. Most of the outcry doesn't seem to articulate why the revert was necessary, and...

whether there's a more conservative or backwards-compatible approach that could be used here?
otherwise / irrespective of the above going ahead with such a config/flag warning cycle plan is quite reasonable, with some agreement on a rough approach to follow

Perhaps switching the defaults (i.e hard fail rather than just warn) could also have an "opt-back" option (mentioned in the error message) for builds that need a second before migrating.  Then we can drop the opt-back option.

Is @dhardy 's workaround able to reuse the workspace target directory, and resolve to the same versions of dependencies as it would when building the root crate?

...to be honest, neither the current nor proposed semantics sound right to me.  Here's what I would want --all --no-default-features --features blah,blip to do:

Apply all feature options (in this case, --all --no-default-features --features blah,blip) to the root package.
Resolve the set of features to be enabled for each subcrate as if we were building the root package.

After all, crates in a workspace already have the responsibility of controlling each others' features (e.g. almost all dependencies on internal or "implementation detail" crates should be using default-features = false).  And this way, cargo test --all would build every crate exactly the same way as cargo test would, except it would also build and run test cases for workspace members.

@ExpHP we're talking about workspaces here. What do you mean by "root package"?

I mean the one whose Cargo.toml contains the workspace table, and whose path dependencies define the workspace members.
For workspaces with no root package that rely on an explicit [members] table, I'm not sure if --all even makes sense.  I guess the proposed behavior may make sense here (though it feels like duck-typing)... but I also feel that such workspaces would benefit from having a root package to act as an authority on what features mean when cargo is used in the workspace root directory.

Clarification: when I say "proposed behavior" I refer to the idea where feature flags are applied to all crates (and ignored on ones that don't have it) for --all.  I think I may gotten confused about where I was after following a linkback X_X

I'm not sure if --all with features even makes sense.

I think you should be able to specify package/feature as a feature in that case.

I'm not sure if --all with features even makes sense.

I think you should be able to specify package/feature as a feature in that case.

I would use something like that for things I want enabled on a different profile, i.e.
cargo test --all --features testing

to enable certain features when testing but not in release or development modes. Or better yet, if cargo could support feature flags in its profiles section, that'd be preferable.

For me, it would be enough to have something like:
cargo build -C subcrate --features ...
Which behaves like:
cd subcrate
cargo build --features ...
cd ..

cargo build --features ... --manifest-path subcrate/Cargo.toml.

I am making a proposal to change the behavior of -Zpackage-features in #8074. I would appreciate any feedback from anyone following this issue.
The intent is to cover more use cases that people have expressed interest in, and to push this towards stabilization.  The new behavior is summarized in the docs.  Compared to the old -Zpackage-features behavior, it changes:

You can specify features for multiple packages at once. Not all packages need to define every feature, Cargo only enables matching features.
Adds --features member_name/feature_name syntax for setting features on specific members.

I think it is possible to stabilize the new behavior as-is except for the one backwards-incompatible change of -p foo --features … inside a member's directory. I can't think of a good transition plan for that, so I think a solution is to make the new behavior opt-in.  We are planning an opt-in mechanism for the new feature resolver, so I'm thinking it could just ride on that same option (probably a flag specified in the [workspace] definition).

@ehuss I like that proposal a lot!


Build Metadata XML

Create Web-Service XML

Will do this by introducing xml-snippets.

Here is a snippet
https://github.com/megel/AL/blob/TenantWebSeviceSnippet/snippets/tenantwebservice.xml.json


Set User-Agent of Wget to Chrome or Custom Value

Some websites do not properly permit wget to crawl the entire site, they block with a 403 or empty webpages.
For this it would be useful to set the --user-agent parameter of wget to another value.
A good default would be the chrome user-agent, which would make websites show as-in-browser instead of how they treat wget's default.
Alternatively the User-Agent Lynx can be used, websites that are aware of Lynx will reduce JS and CSS contents, making it easier to archive the page.

I thought about this actually, and I'd rather respect site's desires to not be crawled unless explicitly overridden.
I'm happy adding a user agent change, but I want to stick it behind a configuration variable like WGET_USER_AGENT or something, and leave the default as wget.  If people want to change it they can.

Done: acf59fa


Fixed implementation contract verification issues and added support for other testnets and mainnets!

Not able to verify Box.sol (first implementation contract) on testnets and mainnets.
Reason
In 01-deploy-box.js see the following verification code:
    // Verify the deployment
    if (!developmentChains.includes(network.name) && process.env.ETHERSCAN_API_KEY) {
        log("Verifying...")
        await verify(box.address, [])
    }

Here, box.address gives address of proxy contract OpenZeppelinTransparentProxy instead of box.sol, due to delegate call in proxy contract.
Possible fix
    // Verify the deployment
    if (!developmentChains.includes(network.name) && process.env.ETHERSCAN_API_KEY) {
        log("Verifying...")
        const boxAddress = (await ethers.getContract("Box_Implementation")).address;
        await verify(boxAddress, arguments)
    }

Thanks! So it looks like you made a lot of other changes as well, could we remove those changes and just add the changes associated with the issue?


Jesse: Blacklist marie[\W_]*+consultancy

Jesse requests the blacklist of the keyword marie[\W_]*+consultancy. See the MS search here and the Stack Exchange search in text, in URLs, and in code.

We should unwatch Marie_consultancy and Marieconsultancyoz(?:@gmail\.com)? along with this blacklist entry.

Rejected by cocomac in Charcoal HQ. Reason: 'Lacks bookending, see also these messages in CHQ'


add faceting in some registry endpts

http://www.gbif.org/developer/registry

done in dc28bc17d1a86914d20647d1d14b3f70ecdb352d


Update README example for passing custom credentials

I am having a problem connecting my Vercel hosted back end to my cloudSQL instance when I use GoogleAuth instance as credentials with cloud-sql-connector.
I have posted on stack overflow however it was suggested I post here by Jack Wotherspoon. Here is the question on SO for background.
When I set the GOOGLE_APPLICATION_CREDENTIALS env variable to the path where the service credentials JSON is stored, and use :
const connector = new Connector({
});

I can connect.
However, I need to be able to load the service credentials JSON directly from environment variable (not from the path).
When I try this:
const connector = new Connector({
auth: new GoogleAuth.fromJSON(keys),
});

I can't make a connection. Am I missing something?
Here is my full DB.js file:
import mysql from 'mysql2/promise';
import {Connector} from '@google-cloud/cloud-sql-connector';
import {GoogleAuth} from 'google-auth-library';

let pool;

// load the environment variable with our keys
const keysEnvVar = process.env.CREDENTIALS_JSON
if (!keysEnvVar) {
  throw new Error('The CREDENTIALS_JSON environment variable was not found!');
}
const keys = JSON.parse(keysEnvVar);
console.log("keys=",keys)

const connector = new Connector({
auth: new GoogleAuth.fromJSON(keys),
});

const clientOpts = await connector.getOptions({
instanceConnectionName: 'survey-engine-301112:australia-southeast2:database-australia',
ipType: 'PUBLIC',
scope: ['https://www.googleapis.com/auth/cloud-platform'],
});

if (!pool){
pool = await mysql.createPool({
...clientOpts,
user: process.env.DBUSER,
password: process.env.DBPASSWORD,
});
}

const conn = await pool.getConnection();
const [result] = await conn.query( `SELECT NOW();`);
console.table(result); // prints returned time value from server
conn.release();

export default pool

Here is my output from console.log("keys=",keys). I have hashed out some of the details.
keys= {
  type: 'service_account',
  project_id: 'survey-engine-301112',
  private_key_id: 'd65599b32daaa8d9d59f6e6221a16e62d6c2ae9f',
  private_key: '-----BEGIN PRIVATE KEY-----\n' +
    'MIIEvwIBADANBgkqhkiG9w0BAQEFAASCBKkwggSlAgEAAoIBAQDkYpkZMXRJQfp+\n' +
    '#########################\n'+
    'cnTc7caSvsgRFpeLCMxV5REeQw==\n' +
    '-----END PRIVATE KEY-----\n',
  client_email<EMAIL_ADDRESS>  client_id: '10#################22',
  auth_uri: 'https://accounts.google.com/o/oauth2/auth',
  token_uri: 'https://oauth2.googleapis.com/token',
  auth_provider_x509_cert_url: 'https://www.googleapis.com/oauth2/v1/certs',
  client_x509_cert_url: 'https://www.googleapis.com/robot/v1/metadata/x509/backend-to-db%40survey-engine-301112.iam.gserviceaccount.com',
  universe_domain: 'googleapis.com'
}

I am using cloud-sql-connector version 1.2.0, google-auth-library version 9.2.0, mysql2 version 3.6.2 and node version 20.10.0

Hi @TerenceSweeneyP Thanks for opening this issue! 😄
I will update our README example and get you a better example to showcase passing custom credentials to the Node Connector. As you have pointed out, the sample we showcase in our README doesn't really showcase the intended use-case very well at all. We should have a better example that showcases actually specifying a service account that differs from the Application Default Credentials.

Also @TerenceSweeneyP do you mind sharing the actual error you are getting? 😄 Will help to reproduce and debug

Hi @jackwotherspoon. Updating the readme would probably be helpful. I am not sure whether my use is correct.
Currently I am trying:
  const auth = new GoogleAuth({
    credentials: keys,
    scope: ['https://www.googleapis.com/auth/cloud-platform'],
});
const connector = new Connector({
    auth:auth
});

This doesn't throw an error, but I am only getting a connection when I have GOOGLE_APPLICATION_CREDENTIALS set in my .env, so it isn't using the credentials from the GoogleAuth instance.

@TerenceSweeneyP
I believe the issue is the following. You are passing loginAuth: GoogleAuth, so the first branch executes, which uses default GoogleAuth (and thus tries to load your GOOGLE_APPLICATION_CREDENTIALS). See the code here:
https://github.com/GoogleCloudPlatform/cloud-sql-nodejs-connector/blob/c84e20aae0053404ab0e1778ea858e027d545e8b/src/sqladmin-fetcher.ts#L83-L91
To fix the issue, I believe you should pass loginAuth: AuthClient, for example:
const auth = new GoogleAuth({
    credentials: keys,
    scope: ['https://www.googleapis.com/auth/cloud-platform'],
});

const authClient = await auth.getClient();

const connector = new Connector({
    auth: authClient
});

@edosrecki I have tried this out and I get the following error:
- error Error: error:1E08010C:DECODER routines::unsupported
    at Sign.sign (node:internal/crypto/sig:131:29)
    at Object.sign (/Users/terencesweeney/Coding/Back End/nextbe/node_modules/jwa/index.js:152:45)
    at Object.jwsSign [as sign] (/Users/terencesweeney/Coding/Back End/nextbe/node_modules/jws/lib/sign-stream.js:32:24)
    at JWTAccess.getRequestHeaders (/Users/terencesweeney/Coding/Back End/nextbe/node_modules/google-auth-library/build/src/auth/jwtaccess.js:123:31)
    at JWT.getRequestMetadataAsync (/Users/terencesweeney/Coding/Back End/nextbe/node_modules/google-auth-library/build/src/auth/jwtclient.js:79:51)
    at JWT.requestAsync (/Users/terencesweeney/Coding/Back End/nextbe/node_modules/google-auth-library/build/src/auth/oauth2client.js:368:34)
    at JWT.request (/Users/terencesweeney/Coding/Back End/nextbe/node_modules/google-auth-library/build/src/auth/oauth2client.js:362:25)
    at GoogleAuth.request (/Users/terencesweeney/Coding/Back End/nextbe/node_modules/google-auth-library/build/src/auth/googleauth.js:697:23) {
  digest: undefined

I get where you are coming from though. When I look at the code from cloud-sql-nodejs-connector/src/sqladmin-fetcher.ts it seems I have to pass in an AuthClient instance (if I want to provide actual credentials).
I have played around and tried numerous options from the docs including:
const authClient = new auth.fromJSON(keys);
const connector = new Connector({
    auth: authClient
});

I cant get anything to work though.

@edosrecki Thanks. I need to load the actual credentials themselves from environment variables though, not from the path. That is why I am going down this route.
I tried:
  const authClient = auth.fromJSON(keys) // As keys has already been parsed
  const connector = new Connector({ auth: authClient })

But it gives:
- error Error: error:1E08010C:DECODER routines::unsupported
I went back at tried from the path with your code (as a test) however it also wouldn't connect- it doesn't give an error it just doesn't connect. This is strange because when I add the same path as GOOGLE_APPLICATION_CREDENTIALS and just use:
 const connector = new Connector()
It works fine.

@TerenceSweeneyP

But it gives: - error Error: error:1E08010C:DECODER routines::unsupported

This has to be an issue with private key formatting in your keys variables. Can you try Base64-encoding your JSON key and storing it as such in environment variables. Then Base64-decode it before passing it to auth.fromJSON().

@TerenceSweeneyP I can confirm that I just got the following working which is what I think you are looking for and builds on what @edosrecki mentioned above 😄 , just adding the scopes:
import mysql from 'mysql2/promise';
import {Connector} from '@google-cloud/cloud-sql-connector';
import {auth} from 'google-auth-library';

// load the environment variable with our keys
const keysEnvVar = process.env.CREDENTIALS_JSON
if (!keysEnvVar) {
  throw new Error('The CREDENTIALS_JSON environment variable was not found!');
}
const keys = JSON.parse(keysEnvVar);
console.log("keys=",keys);

const authClient = auth.fromJSON(keys);
authClient.scopes = ['https://www.googleapis.com/auth/cloud-platform'];

const connector = new Connector({
    auth: authClient,
});

const clientOpts = await connector.getOptions({
    instanceConnectionName: 'my-project:my-region:my-instance',
    ipType: 'PUBLIC',
});

const pool = await mysql.createPool({
    ...clientOpts,
    user: process.env.DBUSER,
    password: process.env.DBPASSWORD,
    database: '',
});

const conn = await pool.getConnection();
const [result] = await conn.query( `SELECT NOW();`);
console.table(result); // prints returned time value from server

await pool.end()
connector.close()

just adding the scopes:

I would like to point out that adding scopes does not seem to be necessary since they are added in SQLAdminFetcher.
On additional note, I would like to share my opinion that Connector's constructor API is extremely confusing, given that loginAuth can be an instance of 2 different types (GoogleAuth, AuthClient), and that depending on the provided type, connector chooses between two very different execution paths.

I would like to point out that adding scopes does not seem to be necessary since they are added in SQLAdminFetcher.

Interesting, if I remove the scopes from my sample I get an unauthorized error... @ruyadorno does this sound like a bug to you? If I am passing in a custom AuthClient should i be granting it the proper scopes in my code or should the Connector be applying the scopes?

I would like to point out that adding scopes does not seem to be necessary since they are added in SQLAdminFetcher.

Interesting, if I remove the scopes from my sample I get an unauthorized error... @ruyadorno does this sound like a bug to you? If I am passing in a custom AuthClient should i be granting it the proper scopes in my code or should the Connector be applying the scopes?

My bad, after checking the google-auth-library code, scopes which are passed to GoogleAuth constructor are only applied if authClient is NOT passed to it. So yes, they need to be set, I stand corrected 👍

@danielbankhead is there a design reason we want to support both types GoogleAuth and AuthClient instead of just supporting one of the types?

@danielbankhead is there a design reason we want to support both types GoogleAuth and AuthClient instead of just supporting one of the types?

Yep, customers can use GoogleAuth if they have a shared/general configuration they would like to use throughout their application and don't have a preference for which auth client to use. AuthClient is useful for customers that would like to fine-tune their credentials configuration, or even pass in a custom auth client, to satisfy their unique needs.

Hi Guys
I finally got this working.
@edosrecki In regards to "- error Error: error:1E08010C:DECODER routines::unsupported" you are right. This is an error with private-key format (can't believe I didn't google this earlier).
@jackwotherspoon
Yes. Both of your examples work.
In retrospect, not passing the credentials in the correct format (as a string) is what was causing me the biggest problem. It is obvious now (given that the code includes JSON.parse()) however it took me a lot of trial and error to get this in my bones.
Thanks a lot for your help.

As an aside, I don't think the credentials in the example here will work with the code snippet given there. JSON.parse() will not work with the contents of this environment variable. Before adding the credentials to an environment variable, the credentials first need to be either:

Turned into a string
or
Turned into a string then base 64 encoded (as per some recommendations)

I think this example needs to be changed.
I am open to being corrected if I have missed something though.

As an aside, I don't think the credentials in the example here will work with the code snippet given there. JSON.parse() will not work with the contents of this environment variable. Before adding the credentials to an environment variable, the credentials first need to be either:

Turned into a string
or
Turned into a string then base 64 encoded (as per some recommendations)

I think this example needs to be changed. I am open to being corrected if I have missed something though.

@TerenceSweeneyP the credentials in the example you linked actually are a string 😉 They sneakily have single quotes around the JSON when they run $ export CREDS='{...}' so I think it does work, I used that example and it worked for me.

however the example infers that if you take the JSON from the service key file, wrap it in single quotes, then it becomes a string that you can apply JSON.parse to.

If I may join the conversation... I don't think that example suggest that. It just shows one way (in the shell) to set the environment variable which contains service account JSON credentials. This is typical throughout documentation, it doesn't try to cover every possible environment (that would be rather complicated) in which users might deploy their code.
Typical issue when loading JSON credentials in the environment is the formatting of the private_key, which contains newlines, which can then wrongly get copied as a literal \n string, and this will in turn cause parsing of the key to fail.
That's why the best practice is to Base64-encode the key and store it like that in your environment variable:
cat service_account_key.json | base64 -w0

@edosrecki Okay. I get where you are coming from.
I have read over my last comment and realized it probably reads as brusque, and not relevant. I apologize for that.
It took some time for me to work out how to get the credentials in the right format and I found the way credentials were shown in the example confusing. I think it would have been clearer for me if the environment variable was not shown in the example, and there was a paragraph explaining that the environment variable needed to be stored as a string( and possibly base64 encoded). Then I could have researched how to do that in my environment.
This may be just me. Others may find it clearer. If I can save someone else work though, it would be worthwhile.
I am happy to leave the conversation and get back to focussing on my project.
Thanks for your support. Are you fine with my closing the question as completed?


Initial YouTube Video Downloader project with yt-dlp integration

This pull request introduces the initial implementation of the YouTube Video Downloader project, featuring the integration of the yt-dlp library for downloading YouTube videos.
Key Features:

Ability to download videos in the highest available resolution or a user-specified resolution (e.g., 720p).
Simple input prompts for YouTube URL and resolution.
Error handling for invalid URLs or resolution mismatches.
Includes configuration files:

requirements.txt for project dependencies (yt-dlp).
runtime.txt specifying the Python version (Python 3.10.12).

This setup ensures a smooth installation of dependencies and correct runtime environment for the project.
Please review and suggest any necessary changes or improvements.
#2

Great job on implementing the YouTube Video Downloader project. Adding a README will significantly improve the project's accessibility and clarity.

Hi @king04aman ,
I've added the README as requested to improve the project's documentation. Let me know if anything else is needed!

I had done the  required changes please review


ci: added JSOnLoad4_Spec test to limited tests

Description

EE PR: https://github.com/appsmithorg/appsmith-ee/pull/4768

Fixes #35135
or
Fixes Issue URL

[!WARNING]
If no issue exists, please create an issue first, and check with the maintainers if the issue is valid.

Automation
/ok-to-test tags=""
:mag: Cypress test results

[!CAUTION]
If you modify the content in this section, you are likely to disrupt the CI result for your PR.

Communication
Should the DevRel and Marketing teams inform users about this change?

[ ] Yes
[ ] No

/ci-test-limit

/ci-test-limit

/ci-test-limit

/ci-test-limit

/ci-test-limit

/ci-test-limit

/ci-test-limit

Closing the PR as the issue has been closed.


Errors on --generate (I have no \projects or \repo\Azure directories)

My repo is in C:\repo. I don't have a C:\repo\Azure path. I also don't have a C:\projects path. Should I be rebuilding Snowflaqe from source so that it has the right dependency paths?
`PS C:\repo\GitHubGraphQL> snowflaqe --generate
 _____                      __ _
/  ___|                    / _| |
\ `--. _ __   _____      _| |_| | __ _  __ _  ___
 `--. \ '_ \ / _ \ \ /\ / /  _| |/ _` |/ _` |/ _ \
/\__/ / | | | (_) \ V  V /| | | | (_| | (_| |  __/
\____/|_| |_|\___/ \_/\_/ |_| |_|\__,_|\__, |\___|
                                          | |
                                          |_|

❤  Open source https://www.github.com/Zaid-Ajaj/Snowflaqe
⚖  MIT LICENSE

⏳ Loading GraphQL schema from ./schema.docs2.json
Unhandled exception. System.UnauthorizedAccessException: Access to the path 'c:\repo\Azure\CosmosDB\azure-cosmos-db-graph-gremlindotnet-getting-started.git\objects\pack\pack-c96e57ccb981e79d47f974f04a19c0b27d2911de.idx' is denied.
at System.IO.FileSystem.DeleteFile(String fullPath)
at System.IO.File.Delete(String path)
at Program.deleteFilesAndFolders(String directory, Boolean isRoot) in C:\projects\Snowflaqe\src\Program.fs:line 219
at Program.deleteFilesAndFolders(String directory, Boolean isRoot) in C:\projects\Snowflaqe\src\Program.fs:line 222
at Program.deleteFilesAndFolders(String directory, Boolean isRoot) in C:\projects\Snowflaqe\src\Program.fs:line 222
at Program.deleteFilesAndFolders(String directory, Boolean isRoot) in C:\projects\Snowflaqe\src\Program.fs:line 222
at Program.deleteFilesAndFolders(String directory, Boolean isRoot) in C:\projects\Snowflaqe\src\Program.fs:line 222
at Program.deleteFilesAndFolders(String directory, Boolean isRoot) in C:\projects\Snowflaqe\src\Program.fs:line 222
at Program.deleteFilesAndFolders(String directory, Boolean isRoot) in C:\projects\Snowflaqe\src\Program.fs:line 222
at Program.generate(String configFile) in C:\projects\Snowflaqe\src\Program.fs:line 280
at Program.main(String[] argv) in C:\projects\Snowflaqe\src\Program.fs:line 435
PS C:\repo\GitHubGraphQL>`

My snowflaqe.json
{     "schema": "./schema.docs2.json",     "queries": "./queries",     "project": "GitHubGQL",     "output": "c:/repo/",     "target": "fsharp" }

When you generate the code into a directory, Snowflaqe cleans the directory if it is not empty. So you basically tried to delete c:/repo/ and everything inside. I suggest you use an empty directory relative to the project you are working on:
{
  "schema": "./schema.docs2.json",
  "queries": "./queries",
  "project": "GitHubGQL",
  "output": "./output",  <-- see here
  "target": "fsharp"
 }

oh yeah that would have been bad (though most things are sync'd up) 😁😲🎭


Feature/registration backend

PR for IAP-10. This PR successfully closes the sub-task.
Some useful notes:
Register requests should be made to: "localhost:3000/api/v1/register"
An example of a successful request would be:
{     "user": {         "username": "teste6",         "email"<EMAIL_ADDRESS>        "password": "password5!",         "location": "Portugal"     } }
With the response being:
{     "message": "Successfully created a new user." }
And, most importantly, the http status code would be "201" indicating successful resource creation.
An example of an unsuccessful request would be:
{     "user": {         "username": "teste4",         "email": "teste4.com",         "password": "password",         "location": "Portugal"     } }
With the response being:
{     "email": [         "has already been taken",         "is invalid"     ],     "username": [         "has already been taken"     ],     "password": [         "is too short (minimum is 10 characters)",         "is invalid"     ] }
And, most importantly, the http status code would be "422" meaning unprocessable content.

LGTM

LGTM

Pull request is for wrong branch. Feature branches should be merged into development. Please consult CONTRIBUTING md document.


why I have this error?

when I use laravel-excel  it comes a error
ReflectionException in E:\demospace\laravel\vendor\laravel\framework\src\Illuminate\Container\Container.php line 741:
Class excel does not exist
the code view is follwing:
use Maatwebsite\Excel\Facades\Excel;

Please provide sample code.

@lpm0205
You may haven't added Excel facade to app.php

Hi, I currently have the same error and can confirm that I've added the Facade reference in config/app.php.
Turns out that the reference to the Excel class inside the Excel facade is not resolving on Windows.
    /**
     * Return facade accessor
     * @return string
     */
    protected static function getFacadeAccessor()
    {
        return \Maatwebsite\Excel\Excel::class; // instead of: return 'excel';
    }

I'll make a pull request

Did you do php artisan config:cache to save facade to cache?

Will try later today, had to take care of something else atm. I haven't tried it.

Hope you doing well!

Got it. Turns out I already had a cached config file which I completely forgot about it. I don't know why it would work after my previous suggestion...
It currently works, I will close the PR as it now became unnecessary.


Add support for array metadata block

Is your feature request related to a problem? Please describe.
currently it is not possible to specify multiple values for the same metadata, for example to create several <meta ... > tags.
for the Tags, this is hard coded, by splitting the value by ,.
suggestion A: use list
+--------------------------------------+
| Metadata                             |
+------------------+-------------------+
| Author           | - John Doe        |
|                  | - Jane Doe        |
+------------------+-------------------+

advantage: intuitive
disadvantage: breaking, because the list is currently converted to a coma separated value

suggestion B: duplicate row
+--------------------------------------+
| Metadata                             |
+------------------+-------------------+
| Author           | John Doe          |
+------------------+-------------------+
| Author           | Jane Doe          |
+------------------+-------------------+

advantage: not breaking (expect where people have wrong metadata), works probably better for images
disadvantage: less intuitive

Furter notes
Metadata from the metadata.json should probably not be merged with the page local metadata, if the value exists in both,
but the page metadata should win.

they want to have several <meta property="author" content="..." > tags in the document.

Thanks, @tripodsan
Yes, @rofe , they have documents with multiple authors. Right now, they use the indexer's match to split the comma-separated list into an array, but this approach would be more intuitive.
/cc: @sdmcraft

@davidnuescheler what is your take on this?

I think until this problem has come up a couple more times in projects, I don't see a downside to simply leaving the comma-separated string in the index and do the splitting on the client/project side.

I think until this problem has come up a couple more times in projects, I don't see a downside to simply leaving the comma-separated string in the index and do the splitting on the client/project side.

I thought this is a problem for SEO ?

i agree with @rofe... @tripodsan there is definitely no SEO impact, google uses the DOM not HTML markup.

article:tag as per OpenGraph's definition is an array of strings, and we wanted to make it easy for blog authors to just provide a comma-separated list of tags in the metadata block.
By contrast, author is a custom metadata property. If we want to treat author the same as tags, we would have to turn author into an array of standard article:author tags, but unfortunately, that would be a breaking change now.

we would have to turn author into an array of standard article:author tags

but this is the idea, afaiu.  the project wants to have multiple article:author elements. it can do it client side, but it is clumsy.

but unfortunately, that would be a breaking change now.

by using suggestion B, I don't think this is very breaking. the chance that a document has a duplicate row by mistake is very low.

but this is the idea, afaiu. the project wants to have multiple article:author elements

Ah, then I misunderstood your earlier comment.

by using suggestion B, I don't think this is very breaking. the chance that a document has a duplicate row by mistake is very low.

Yes, but the current pipeline renders an author key in the metadata block as
<meta name="author" content="..." >

and your proposal would be to change that to
<meta property="article:author" content="..." >

if I understood your comment above correctly.
Or is your suggestion more generic and not tied to the author case specifically?
If there is flexibility in the project to use article:author as the key in the metadata block instead of just author, then we wouldn't have to "magically" transform the meta name to a property, and collisions with existing content could be avoided.

no, there is no article:author property in the current rendering. I never said that it should be that.
the only change, as provided in the PR #148 from @dominique-pfister is, that if the metadata block has multiple rows with the same key, the respective meta property element gets added multiple time.
so:
+--------------------------------------+
| Metadata                             |
+------------------+-------------------+
| Author           | John Doe          |
+------------------+-------------------+
| Author           | Jane Doe          |
+------------------+-------------------+

becomes:
<meta name="author" content="John Doe">
<meta name="author" content="Jane Doe">

currently the last one wins, and only this shows up:
<meta name="author" content="Jane Doe">

Ok. There was some confusion around the desired tag output in the above discussion, and I only brought up article:author and equivalent to article:tag which, as you pointed out above, we do have special handling for. Anyway I think I understand what you mean now :)
Obviously this use case can't be achieved on the client side, and the pipeline change in #148 seems benign. But I'm not sure if this justifies an execption to the projects-first rule for product features...
@davidnuescheler wdyt?

This issue came in context of a requirement in Alexander Forbes blogs where a blog article could have several authors. Linking to the issue https://github.com/alexander-forbes/aem-blogs/issues/9 . Alexander Forbes blogs is modelled around Adobe blogs so I am wondering if a similar requirement may come there if there are multiple authors of an article.  Right now its tackled by specifying a delimiter in the author names and then spitting it up by the delimiter while indexing and also on the client side. The problem is that this would not work if the delimiter is legitimately present in a metadata value. For e.g. a , in author name.
I am wondering that rather than attaching a special treatment to a metadata key like  article:author , would it still be helpful to have the ability to specify multi-values for metadata attributes ? Right now there does not seem to be a way to do so.

would it still be helpful to have the ability to specify multi-values for metadata attributes

this is what this issue is about. currently, there is not need to implement this on the product level. we can reconsider it, when we prepare the next breaking change..

We have a use case in Milo where we would need to define several authors, and for each author, a name and a URL, to be able to generate Google-compliant JSON-LD schema for an article news:
<html>
  <head>
    <title>Title of a News Article</title>
    <script type="application/ld+json">
    {
      "@context": "https://schema.org",
      "@type": "NewsArticle",
      "headline": "Title of a News Article",
      "image": [
        "https://example.com/photos/1x1/photo.jpg",
        "https://example.com/photos/4x3/photo.jpg",
        "https://example.com/photos/16x9/photo.jpg"
       ],
      "datePublished": "2015-02-05T08:00:00+08:00",
      "dateModified": "2015-02-05T09:20:00+08:00",
      "author": [{
          "@type": "Person",
          "name": "Jane Doe",
          "url": "http://example.com/profile/janedoe123"
        },{
          "@type": "Person",
          "name": "John Doe",
          "url": "http://example.com/profile/johndoe123"
      }]
    }
    </script>
  </head>
  <body>
  </body>
</html>

as defined at https://developers.google.com/search/docs/appearance/structured-data/article.
More details in (internal ticket) MWPW-114236.

Netcentric project is a new use case where we see this, they have blog posts with 2 authors, like https://www.netcentric.biz/insights/2022/06/optimizing-workflows-workfront.html.
My current approach for mapping in the importer is to:
+-------------------------------+
| Metadata                      |
+-----------+-------------------+
| Author    | Author 1, Author2 |
+-----------+-------------------+


Yourapprovals : distinguish categ referee vs general referee

Categ refree  is considered as General Referee via Approval interface (your approvals)
Redefine __isReferee() function without asterisk "*" as default value for categ parameter, resolve the issue ==> def __isReferee(req, doctype="", categ="")
Invenio 1.1.6

cc @inveniosoftware/triagers

@ludmilamarian @egabancho Have you observed this on CDS?

I'm not sure I understand the problem. @BessemAamira is this just a display problem, or is it more in-depth (the category referee can referee more documents, even outside his/hers category)?

@ludmilamarian yes, it's a display problem.


Fix two eager Regex creations in rules which may lead to confusing error messages on wrong config properties

@arturbosch do you have samples for that?

which may lead to confusing error messages on wrong config properties

@arturbosch do you have samples for that?

which may lead to confusing error messages on wrong config properties

It prevents cases like mentioned in https://github.com/detekt/detekt/issues/1064


standalone_2/out_of_memory_slow_growth_test/0 fails with runtime error

On https://ci.chromium.org/p/dart/builders/ci.sandbox/vm-kernel-win-debug-x64/10056
The tests
standalone_2/out_of_memory_slow_growth_test/0 RuntimeError (expected Pass)

are failing on configurations
dartk-win-debug-x64

--- Command "vm" (took 31.000281s):
set DART_CONFIGURATION=DebugX64 & set DART_SUPPRESS_WER=1 & set DART_CRASHPAD_HANDLER=C:\b\s\w\ir\out\DebugX64\crashpad_handler.exe & out\DebugX64\dart.exe --old_gen_heap_size=20 --ignore-unrecognized-flags --packages=C:\b\s\w\ir\.packages C:\b\s\w\ir\tests\standalone_2\out_of_memory_slow_growth_test.dart

exit code:
255

stderr:
Exhausted heap space, trying to allocate 32 bytes.
Exhausted heap space, trying to allocate 80 bytes.
Unhandled exception:
Out of Memory
#0      main (file:///C:/b/s/w/ir/tests/standalone_2/out_of_memory_slow_growth_test.dart:18:5)
#1      _startIsolate.<anonymous closure> (dart:isolate-patch/isolate_patch.dart:301:19)
#2      _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:168:12)
#3      _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:168:12)

--- Re-run this test:
python tools/test.py -n dartk-win-debug-x64 standalone_2/out_of_memory_slow_growth_test/0

cc @rmacnak-google

The underlying problem in this test failure seems to be addressed by https://dart-review.googlesource.com/c/sdk/+/165862 and is more generally tracked in https://github.com/dart-lang/sdk/issues/43543 and https://github.com/dart-lang/sdk/issues/43642.

Similar issue on https://ci.chromium.org/p/dart/builders/ci.sandbox/vm-kernel-mac-debug-x64/9640

Also went from flaky to RTE in the /1 configuration today on mac-debug (log).

I also observed crashes on Windows IA32 (log). These show up as purple because archiving core dumps fails.

standalone/out_of_memory_slow_growth_test/0 went flaky -> RuntimeError on dartk-strong-linux-release-x64.

c8dea19836d95c0cc548def26a20b9e6a79d3ba2


As a QA, I want to write testcases manually of transaction history and report the defects, if any.

In this task, the goal is to manually design and execute test cases for the Transaction History feature. Primary responsibility is to thoroughly test the functionality of the Transaction History, ensuring that it meets the specified requirements. During the testing process, and objective is to identify and document any defects or anomalies encountered. This includes meticulously recording steps taken, expected outcomes, and actual results for each test case.


License should be displayed more prominent

the problem is: in this screenshot it is visible that a user has to scroll down to see the license. That should not be. Therefore the license information should be put more prominently. Maybe as a badge or somewhere else, we have to discuss where it is the best place by creating some screenshots with different solutions. improve #98

@utnapischtim  is this still open issue for you?

@utnapischtim  is this still open issue for you?


Collapse mobile nav after user interaction.

Had to revert it. It glitches the navbar.

Emm... Let's try once more. If this will not work I will stop wasting Your time at this question. Deal? Check next PR.


tests/ceph: bluestore, dmcrypt, and IPv6 test

Description of changes

Added a Ceph test incorporating both bluestore on top of dmcrypt as well as the ceph-volume tooling, and explicit IPv6.
This should cover the breakage of #334975 and in turn depends on #335684 being merged, otherwise the tests will fail.
Things done

Built on platform(s)

[x] x86_64-linux
[ ] aarch64-linux
[ ] x86_64-darwin
[ ] aarch64-darwin

For non-Linux: Is sandboxing enabled in nix.conf? (See Nix manual)

[ ] sandbox = relaxed
[ ] sandbox = true

[x] Tested, as applicable:

NixOS test(s) (look inside nixos/tests)
and/or package tests
or, for functions and "core" functionality, tests in lib/tests or pkgs/test
made sure NixOS tests are linked to the relevant packages

[ ] Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
[ ] Tested basic functionality of all binary files (usually in ./result/bin/)
24.11 Release Notes (or backporting 23.11 and 24.05 Release notes)

[ ] (Package updates) Added a release notes entry if the change is major or breaking
[ ] (Module updates) Added a release notes entry if the change is significant
[ ] (Module addition) Added a release notes entry if adding a new NixOS module

[x] Fits CONTRIBUTING.md.

Add a :+1: reaction to pull requests you find important.

Incorporated in https://github.com/NixOS/nixpkgs/pull/335684#issuecomment-2322864461, closing.

I'll add you @benaryorg here as well since I'm not using dmcrypt in Ceph myself.

@benaryorg I wanted to add you as maintainer to the test but it didn't work because you don't seem to be in the mainterners list yet:
https://github.com/NixOS/nixpkgs/pull/338619
Could you add yourself as maintainer in another PR?


creds.json db.json structure

Can someone give details about the creds.json and db.json structure.
And how to run this application.

That shouldn't be too tricky to do; go for it!
This bot too posted about such issues, but the support for them was removed after a discussion here: https://github.com/musically-ut/first-timers-only-bot/pull/3
However, it was agreed (see the last comment) that having such a bot would also be a good idea.

Well I agree with the discussion there. It's correct merging alot of labels in single bot is not a good idea. But having separate bots would be fine I guess.
As when I started with opensource, I used first-timers-only bot but after I was done with it, I needed a good-first-issue bot too.
I think any other label bot doesn't makes much sense, but having first-timers and good-first-issue bot is not a bad idea.
What do you think? Any thoughts?
I am planning on forking this repo and create a good-first-issue bot.

Yup, you have a green light from me!

Cool. Just wanted to know, where do you host your bot? Any suggestions for that?

I host it on a personal Vultur server.
I can host your bot too if in a pinch. :)

I host it on a personal Vultur server.
I can host your bot too if in a pinch. :)

@musically-ut I got my bot setup.
I am low on funds to buy my own server to run the bot.
Can I host my bot on your servers.
I am trying to get some donators/backers for server costs.

Great!
Sure, I'll just need the creds.json (over e-mail), and I'll be happy to keep the bot running!
Have you tested out your bot on a local machine by creating an account on Twitter and creating the necessary access/Oauth tokens?
If so, just drop me an e-mail and we'll continue the conversation there.

Thanks.
I tested the bot locally.
I will draft an email and send it to you. Can you share your email id?

I'm @musically_ut on Twitter, DM me there and I'll share my e-mail.

@musically-ut I know this is really old issue.
I was thinking we can add a how-to-use doc in the repository and close the bug.
I have created a how to use doc for first issues which I forked from this.
https://github.com/arshadkazmi42/first-issues/blob/master/HOW_TO_USE.md
I can send a PR with this doc. Any thoughts?

Yes, the HOW_TO looks good, please do create a PR with it.
Also, include a link to first-issue (GitHub repository as well as the Twitter bot) in the README while you are at it. :)
Thanks!


[DOC]

Documentation issue
Why has the refine.dev website been non-functional for the last 48 hours?
Describe the thing to improve
Why has the refine.dev website been non-functional for the last 48 hours?
Describe the solution (optional)
No response

Hey @Ramprits, we've checked the status of the website from different services but looks like all okay. 🤔 Can you check the connection and the connectivity issues on your end? Feel free to re-open 🙏


"ionic cordova run android" ignores ANDROID_HOME set in path

Bug Report
Ionic version:
4.10.2
(same behavior on 4.9.0)
Current behavior:
When running $ ionic cordova run android --verbose, build fails with output:
...
Wrote out android application name "MyApp" to /home/paul/Documents/code/ionic/assistance_app/platforms/android/app/src/main/res/values/strings.xml
android-versionCode not found in config.xml. Generating a code based on version in config.xml (0.0.1): 1
Wrote out Android package name "io.ionic.starter" to /home/paul/Documents/code/ionic/assistance_app/platforms/android/app/src/main/java/io/ionic/starter/MainActivity.java
Updating icons at platforms/android/app/src/main/res
Updating splash screens at platforms/android/app/src/main/res
This app does not have additional resource files defined
Prepared android project successfully
No scripts found for hook "after_prepare".
ANDROID_HOME=/usr/lib/android-sdk
JAVA_HOME=/usr/lib/jvm/java-8-oracle
studio
Subproject Path: CordovaLib
Subproject Path: app
Running command: /home/paul/Documents/code/ionic/assistance_app/platforms/android/gradlew cdvBuildDebug -b /home/paul/Documents/code/ionic/assistance_app/platforms/android/build.gradle -Dorg.gradle.daemon=true -Dorg.gradle.jvmargs=-Xmx2048m
Starting a Gradle Daemon, 1 incompatible and 1 stopped Daemons could not be reused, use --status for details

FAILURE: Build failed with an exception.

* Where:
Script '/home/paul/Documents/code/ionic/assistance_app/platforms/android/CordovaLib/cordova.gradle' line: 68

* What went wrong:
A problem occurred evaluating project ':CordovaLib'.
> No installed build tools found. Install the Android build tools version 19.1.0 or higher.

(displayed path ANDROID_HOME is not the one set in PATH in ~/.bashrc (Cf. lower), which leads to Cordova not finding the installed SDK build-tools)
Expected behavior:
Output in --verbose : ANDROID_HOME=/home/paul/Android/Sdk
Build success.
Steps to reproduce:
Add SdK path to ~/.bashrc, compile ionic project with $ ionic cordova run android --verbose
Related code:
~/.bashrc
...
export JAVA_HOME=/usr/lib/jvm/java-8-oracle
export ANDROID_SDK_ROOT=/home/paul/Android/Sdk
export ANDROID_HOME=/home/paul/Android/Sdk
export PATH=$PATH:/home/paul/Android/Sdk/tools
export PATH=$PATH:/home/paul/Android/Sdk/platform-tools

(SdK installed in /home/paul/Android/Sdk)
$ echo $ANDROID_HOME returns:
/home/paul/Android/Sdk

Other information:
Current fix : specify the ANDROID_HOME path in the command leads to build success:
$ ANDROID_HOME=/home/paul/Android/Sdk ionic cordova run android --verbose
Tried reinstalling Android Studio and Gradle : same behavior
Ionic info:
Ionic:

   ionic (Ionic CLI)             : 4.10.2 (/usr/local/lib/node_modules/ionic)
   Ionic Framework               : @ionic/angular 4.0.0
   @angular-devkit/build-angular : 0.12.3
   @angular-devkit/schematics    : 7.2.3
   @angular/cli                  : 7.2.3
   @ionic/angular-toolkit        : 1.2.3

Cordova:

   cordova (Cordova CLI) : 8.1.2<EMAIL_ADDRESS>   Cordova Platforms     : android 7.1.4
   Cordova Plugins       : cordova-plugin-ionic-keyboard 2.1.3, cordova-plugin-ionic-webview 3.1.1, (and 5 other plugins)

System:

   NodeJS : v8.10.0 (/usr/bin/node)
   npm    : 6.7.0
   OS     : Linux 4.15

cordova requirements
Android Studio project detected

Requirements check results for android:
Java JDK: installed 1.8.0
Android SDK: installed true
Android target: installed android-28,android-27
Gradle: installed /usr/share/gradle/bin/gradle

Ok, I found the issue.
ANDROID_HOME was not set in /etc/environment
For some reason, I had to execute the command as sudo and the path reset.
Added the line:
ANDROID_HOME="<pathToSdk>"

And it worked.

Ok, I found the issue.
ANDROID_HOME was not set in /etc/environment
For some reason, I had to execute the command as sudo and the path reset.
Added the line:
ANDROID_HOME="<pathToSdk>"

And it worked.


If using system ruby, and json isn't installed, do the right thing

use quirks mode for strings/bools/ints
Fixes #11276

@ohayon


Update template.py

Typo

Coverage remained the same at 100.0% when pulling 1e707d91a2d649809e0b653ba04c976d2f8c0ed0 on Warvito:patch-1 into e860daa91cc7271089324f5fe4efdfe699c1679a on scikit-learn-contrib:master.


Refresh NuGet get started articles for VS 2022 #1

Refresh NuGet get started articles for VS 2022
This work is in accordance with User Story 1973817.

Docs Build status updates of commit c595a06:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

docs/quickstart/install-and-use-a-package-in-visual-studio.md
:white_check_mark:Succeeded
View

docs/quickstart/media/QS_Use-02-ManageNuGetPackages.png
:white_check_mark:Succeeded

docs/quickstart/media/QS_Use-03-NewtonsoftJson.png
:white_check_mark:Succeeded

docs/quickstart/media/QS_Use-08-Console1.png
:white_check_mark:Succeeded

docs/quickstart/media/qs-use-01-manage-nuget-packages.png
:white_check_mark:Succeeded
View

docs/quickstart/media/qs-use-02-install-package.png
:white_check_mark:Succeeded
View

docs/quickstart/media/qs-use-03-package-management-format.png
:white_check_mark:Succeeded
View

docs/quickstart/media/qs-use-04-package-manager-console.png
:white_check_mark:Succeeded
View

docs/quickstart/media/qs-use-05-wpf-app-start.png
:white_check_mark:Succeeded
View

docs/quickstart/media/qs-use-06-wpf-app-end.png
:white_check_mark:Succeeded
View

For more details, please refer to the build report.
Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report.
For any questions, please:Try searching the docs.microsoft.com contributor guidesPost your question in the Docs support channel

Docs Build status updates of commit 9e9e288:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

docs/quickstart/install-and-use-a-package-in-visual-studio.md
:white_check_mark:Succeeded
View

docs/quickstart/media/QS_Use-02-ManageNuGetPackages.png
:white_check_mark:Succeeded

docs/quickstart/media/QS_Use-03-NewtonsoftJson.png
:white_check_mark:Succeeded

docs/quickstart/media/QS_Use-08-Console1.png
:white_check_mark:Succeeded

docs/quickstart/media/qs-use-01-manage-nuget-packages.png
:white_check_mark:Succeeded
View

docs/quickstart/media/qs-use-02-install-package.png
:white_check_mark:Succeeded
View

docs/quickstart/media/qs-use-03-package-management-format.png
:white_check_mark:Succeeded
View

docs/quickstart/media/qs-use-04-package-manager-console.png
:white_check_mark:Succeeded
View

docs/quickstart/media/qs-use-05-wpf-app-start.png
:white_check_mark:Succeeded
View

docs/quickstart/media/qs-use-06-wpf-app-end.png
:white_check_mark:Succeeded
View

For more details, please refer to the build report.
Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report.
For any questions, please:Try searching the docs.microsoft.com contributor guidesPost your question in the Docs support channel

#assign-reviewer: @Mikejo5000

Docs Build status updates of commit e6137ca:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

docs/quickstart/install-and-use-a-package-in-visual-studio.md
:white_check_mark:Succeeded
View

docs/quickstart/media/QS_Use-02-ManageNuGetPackages.png
:white_check_mark:Succeeded

docs/quickstart/media/QS_Use-03-NewtonsoftJson.png
:white_check_mark:Succeeded

docs/quickstart/media/QS_Use-08-Console1.png
:white_check_mark:Succeeded

docs/quickstart/media/qs-use-01-manage-nuget-packages.png
:white_check_mark:Succeeded
View

docs/quickstart/media/qs-use-02-install-package.png
:white_check_mark:Succeeded
View

docs/quickstart/media/qs-use-03-package-management-format.png
:white_check_mark:Succeeded
View

docs/quickstart/media/qs-use-04-package-manager-console.png
:white_check_mark:Succeeded
View

docs/quickstart/media/qs-use-05-wpf-app-start.png
:white_check_mark:Succeeded
View

docs/quickstart/media/qs-use-06-wpf-app-end.png
:white_check_mark:Succeeded
View

For more details, please refer to the build report.
Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report.
For any questions, please:Try searching the docs.microsoft.com contributor guidesPost your question in the Docs support channel

Thank you so much @dksimpson for starting this work. It's very appreciated! 🎉 I'll have a quick review later this week and add some comments.

Docs Build status updates of commit 247b1e2:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

docs/quickstart/install-and-use-a-package-in-visual-studio.md
:white_check_mark:Succeeded
View

docs/quickstart/media/QS_Use-02-ManageNuGetPackages.png
:white_check_mark:Succeeded

docs/quickstart/media/QS_Use-03-NewtonsoftJson.png
:white_check_mark:Succeeded

docs/quickstart/media/QS_Use-06-AppStart.png
:white_check_mark:Succeeded

docs/quickstart/media/QS_Use-07-AppEnd.png
:white_check_mark:Succeeded

docs/quickstart/media/QS_Use-08-Console1.png
:white_check_mark:Succeeded

docs/quickstart/media/qs-use-02-install-package.png
:white_check_mark:Succeeded
View

docs/quickstart/media/qs-use-03-package-management-format.png
:white_check_mark:Succeeded
View

docs/quickstart/media/qs-use-04-package-manager-console.png
:white_check_mark:Succeeded
View

docs/quickstart/media/qs-use-05-wpf-app-start.png
:white_check_mark:Succeeded
View

docs/quickstart/media/qs-use-06-wpf-app-end.png
:white_check_mark:Succeeded
View

For more details, please refer to the build report.
Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report.
For any questions, please:Try searching the docs.microsoft.com contributor guidesPost your question in the Docs support channel

@nkolev92 @donnie-msft @Mikejo5000 @JonDouglas Thank you everyone for your review comments. I've uploaded the edited article - let me know what you think.

@nkolev92, I was using WPF App (.NET Framework) before, now I I'm using WPF Application, which I think is the newer one, but I never got confirmation.

@dksimpson Did it prompt you to select the framework such as .NET 6.0 or somethig?
If it did, then customers would never get the prompt to choose PackageReference and the guide would need to potentially call out a different workload.

@nkolev92 Yes, it asks for the framework to select. The default is .NET 6.0. I'm not getting a prompt to select PackageReference.

Cool. Maybe we remove the can remove the prompt part now?
Curious what others think.

@nkolev92 I didn't get the prompt for WPF App (.NET Framework). For the framework, should the user select .NET 6.0 or .NET Core 3.1? It defaults to whatever was selected previously in the dropdown.

My bad, I should have clarified which prompt I am referring to.
The prompt that I was talking about is the packages.config or PackageReference prompt.
For WPF Application on .NET 6.0 or .NET COre 3.1, there's no choice, PackageReference is the default and only format.

@nkolev92 No, I knew what prompt you were referring to, but I was also wondering which framework we should tell the user to select. So it looks like WPF apps never get the PackageReference prompt, and we can remove it?

Let's do net6.0 It's ok to do latest.

Docs Build status updates of commit a02d1ab:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

docs/quickstart/install-and-use-a-package-in-visual-studio.md
:white_check_mark:Succeeded
View

docs/quickstart/media/QS_Use-02-ManageNuGetPackages.png
:white_check_mark:Succeeded

docs/quickstart/media/QS_Use-03b-SelectFormat.png
:white_check_mark:Succeeded

docs/quickstart/media/QS_Use-03-NewtonsoftJson.png
:white_check_mark:Succeeded

docs/quickstart/media/QS_Use-06-AppStart.png
:white_check_mark:Succeeded

docs/quickstart/media/QS_Use-07-AppEnd.png
:white_check_mark:Succeeded

docs/quickstart/media/QS_Use-08-Console1.png
:white_check_mark:Succeeded

docs/quickstart/media/qs-use-install-package.png
:white_check_mark:Succeeded
View

docs/quickstart/media/qs-use-package-manager-console.png
:white_check_mark:Succeeded
View

docs/quickstart/media/qs-use-wpf-app-end.png
:white_check_mark:Succeeded
View

docs/quickstart/media/qs-use-wpf-app-start.png
:white_check_mark:Succeeded
View

For more details, please refer to the build report.
Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report.
For any questions, please:Try searching the docs.microsoft.com contributor guidesPost your question in the Docs support channel

@nkolev92 Thanks for your help! I've made the changes.

Looked at the tracepoints article. (Some of the screenshots near the beginning are small text and a bit hard to read, but that was the case in the previous version of the article, too.)

Hi @Mikejo5000, I haven't been assigned to work on that article, but perhaps in a future user story?

@dksimpson Sorry, I must have switched browser windows :-). That comment was mean for another PR.

@JonDouglas Looks like this one is ready to merge

Thanks everyone for your comments!
#sign-off


(Very) strict extension naming

Following:

microsoft/vscode-vsce#682
microsoft/vscode-vsce#761

I got the mentioned issue today while trying to publish (first release of) an extension with an ID (publisher + name) of igordvlpr.emojifier just to get the error of:

Indeed, there is an extension with the same name but not under the same publisher (me). Upon searching for this issue's solution I did find and read https://github.com/microsoft/vscode-docs/issues/5584.

Even though I personally don't understand the reasoning for that decision, it gets even worse unfortunately.

To circumvent that I decided to prefix the extension name with my publisher name, i.e.:
emojifier -> igordvlpr-emojifier
while of course keeping the publisher set to igordvlpr as well so that I don't take anyone's extension ID.

But then another issue appeared:

Even the displayName is restricted? 😐

(I am assuming that) Both decisions were made to keep the Marketplace with not much duplicate extensions but it actually does not provide that, one can call an extension xyz and it can do anything that another extension already does.
Also, both of the decisions could potentially lock developers out of publishing extensions with the desired ID/name to the Marketplace, imagine someone taking the displayName of C# Dev Kit before the original developer(s) [= Microsoft] did?

Can we bring back that (at least) the displayName is not used as a candidate for duplicates matching?

@igorskyflyer thanks for opening the issue. I like the change that the Marketplace did to make the displayName unique. This is one of the security changes we did which makes a lot of sense for me - but I do understand that it sometimes makes publishing harder.
As for your case that igordvlpr-emojifier display name is taken - that sounds weird to me, and potentially a bug.
@seaniyer should be able to help here.

@igorskyflyer thanks for opening the issue. I like the change that the Marketplace did to make the displayName unique. This is one of the security changes we did which makes a lot of sense for me - but I do understand that it sometimes makes publishing harder.
As for your case that igordvlpr-emojifier display name is taken - that sounds weird to me, and potentially a bug.
@seaniyer should be able to help here.

Thank you for the response and apologies, I was a bit ambiguous in my comment, to clarify:
"name": "igordvlpr-emojifier",
"publisher": "igordvlpr",
"displayName": "Emojifier"

The displayName is Emojifier which is already taken.
The name was also emojifier (which is taken as well), prefixing it with igordvlpr- worked but the issue with the displayName remains.

Thanks for clarifying. I do not think there are plans to loosen these restrictions. But @seaniyer can correct me, since he owns the Marketplace from the Product side.

(I am assuming that) Both decisions were made to keep the Marketplace with not much duplicate extensions but it actually does not provide that, one can call an extension xyz and it can do anything that another extension already does.

@igorskyflyer Display name duplicates have been disallowed to reduce name confusion, particularly in extensions search results. Although we strive to minimize restrictions, this is a security measure to stop name confusion from being used for impersonation.

(I am assuming that) Both decisions were made to keep the Marketplace with not much duplicate extensions but it actually does not provide that, one can call an extension xyz and it can do anything that another extension already does.

@igorskyflyer Display name duplicates have been disallowed to reduce name confusion, particularly in extensions search results. Although we strive to minimize restrictions, this is a security measure to stop name confusion from being used for impersonation.

Thank you for clarifying that, @seaniyer!

Understood, closing, as it won't be addressed any time soon.


Add external traffic policy for proxy service

Description
When using the Kubernetes Gateway API, the provisioned proxy service external traffic policy is now configurable via the GatewayParameters fields spec.kube.service.externalTrafficPolicy
This values can also be set on the default GatewayParameters during install/upgrade using the Helm value kubeGateway.gatewayParameters.glooGateway.service.externalTrafficPolicy
Code changes
Update  gw params to expose external traffic policy
Add test
Context
Fixes https://github.com/k8sgateway/k8sgateway/issues/9879
Isers need to be able to change the external traffic policy so that source client IPs are preserved for features like WAF and ext auth.
API changes
Added fields to GatewayParameters:
spec.kube.service.externalTrafficPolicy
Helm changes
Added Helm value:
kubeGateway.gatewayParameters.glooGateway.service.externalTrafficPolicy
Testing
helm unit tests
deployer unit tests
deployer e2e test
Checklist:

[x] I have performed a self-review of my own code
[x] I have commented my code, particularly in hard-to-understand areas
[x] I have made corresponding changes to the documentation
[x] I have added tests that prove my fix is effective or that my feature works

Flake https://github.com/k8sgateway/k8sgateway/issues/10375


Better GPU producing worse results for cifar10

Hi,
I have a K20c GPU and a Titan Z GPU. The Titan Z GPU is faster in running all other networks except for training cifar10 with mlp or lenet network. I can see from profiler that two systems uses different sgemm kernels for the same application.
Why is this happening?

The version of cuda and cudnn are same between two systems?

@Ujjalbuet consider using the diagnose script to report the system environments of your machines to avoid dealing with the back-and-forth questions. It's really simple to use.
What to do:

Download the diagnosis script from https://raw.githubusercontent.com/apache/incubator-mxnet/master/tools/diagnose.py
Run the script using python diagnose.py and paste its output here.

No. I have to use docker image for one system and have standard installation with cuda 8.0 and cudnn 6 for the other. I think the docker image uses cudnn 5.  Is there any docker image for R available with cudnn 6?

@Ujjalbuet could you please update the issue/ resolve it if its not persisting anymore?


incorrect final balances

Gist: accd2826d83e7ce345f8417c06cb7cdd
The final balance of wallet #4 should be (1000, 10), (1005, 30), (1006, 15)  but it is (1000, 10), (1005, 30) and the 1006 currency went to wallets 1 and 2.

The blockchain looks correct though:

This only seems to occur when you add new currencies to the wallets. The bars depicting the balance of those currencies always seem to be associated with Wallet #1 and Wallet #2, regardless of which Wallet 'actually' has the funds.

I think this is, at least initially, a backend problem.
If I run this command:
curl 'https://localhost:8009/api/evaluate' -H 'Origin: https://localhost:8009' -H 'Accept-Encoding: gzip, deflate, br' -H 'Accept-Language: en-US,en;q=0.9'  -H 'content-type: application/json' -H 'Accept: application/json' -H 'Referer: https://localhost:8009/' --data-binary $'{"wallets":[{"simulatorWalletWallet":{"getWallet":1},"simulatorWalletBalance":{"getValue":[[0,4]]}}],"sourceCode":"-- Contract endpoints that generate different kinds of errors for the log:\\n-- logAMessage produces a log message from a wallet\\n-- submitInvalidTxn submits an invalid txn which should result in a \\"Validation failed\\" message\\n-- throwWalletAPIError throws an error from a wallet (client)\\nimport qualified Data.Set                     as Set\\nimport           Data.Text                    (Text)\\n\\nimport           Ledger\\nimport qualified Ledger.Ada                   as Ada\\nimport           Ledger.Validation\\nimport           Wallet\\nimport           Playground.Contract\\n\\nlogAMessage :: MonadWallet m => m ()\\nlogAMessage = logMsg \\"wallet log\\"\\n\\nsubmitInvalidTxn :: MonadWallet m => m ()\\nsubmitInvalidTxn = do\\n    logMsg \\"Preparing to submit an invalid transaction\\"\\n    let tx = Tx\\n            { txInputs = Set.empty\\n            , txOutputs = []\\n            , txForge = Ada.adaValueOf 2\\n            , txFee = 0\\n            , txValidRange = defaultSlotRange\\n            }\\n    submitTxn tx\\n\\nthrowWalletAPIError :: MonadWallet m => Text -> m ()\\nthrowWalletAPIError = throwOtherError\\n\\n$(mkFunctions [\'logAMessage, \'submitInvalidTxn, \'throwWalletAPIError])\\n","program":[],"blockchain":[]}' --compressed --insecure | jq .fundsDistribution

I get:
[
  {
    "simulatorWalletBalance": {
      "getValue": [
        [
          0,
          4
        ]
      ]
    },
    "simulatorWalletWallet": {
      "getWallet": 1
    }
  }
]

...but if I just change the getWallet ID from 1 to 2:
curl 'https://localhost:8009/api/evaluate' -H 'Origin: https://localhost:8009' -H 'Accept-Encoding: gzip, deflate, br' -H 'Accept-Language: en-US,en;q=0.9'  -H 'content-type: application/json' -H 'Accept: application/json' -H 'Referer: https://localhost:8009/' --data-binary $'{"wallets":[{"simulatorWalletWallet":{"getWallet":2},"simulatorWalletBalance":{"getValue":[[0,4]]}}],"sourceCode":"-- Contract endpoints that generate different kinds of errors for the log:\\n-- logAMessage produces a log message from a wallet\\n-- submitInvalidTxn submits an invalid txn which should result in a \\"Validation failed\\" message\\n-- throwWalletAPIError throws an error from a wallet (client)\\nimport qualified Data.Set                     as Set\\nimport           Data.Text                    (Text)\\n\\nimport           Ledger\\nimport qualified Ledger.Ada                   as Ada\\nimport           Ledger.Validation\\nimport           Wallet\\nimport           Playground.Contract\\n\\nlogAMessage :: MonadWallet m => m ()\\nlogAMessage = logMsg \\"wallet log\\"\\n\\nsubmitInvalidTxn :: MonadWallet m => m ()\\nsubmitInvalidTxn = do\\n    logMsg \\"Preparing to submit an invalid transaction\\"\\n    let tx = Tx\\n            { txInputs = Set.empty\\n            , txOutputs = []\\n            , txForge = Ada.adaValueOf 2\\n            , txFee = 0\\n            , txValidRange = defaultSlotRange\\n            }\\n    submitTxn tx\\n\\nthrowWalletAPIError :: MonadWallet m => Text -> m ()\\nthrowWalletAPIError = throwOtherError\\n\\n$(mkFunctions [\'logAMessage, \'submitInvalidTxn, \'throwWalletAPIError])\\n","program":[],"blockchain":[]}' --compressed --insecure | jq .fundsDistribution

I get:
[
  {
    "simulatorWalletBalance": {
      "getValue": []
    },
    "simulatorWalletWallet": {
      "getWallet": 1
    }
  }
]

ie. Wallet 1 exists, despite not being specified, and wallet 2 doesn't, despite supplying an initial balance.

Jann, can I ask you to take a look at this, in the first instance?

(Ignore an earlier comment I put on this issue. It should have been posted against #828.)
This is fixed by PR #831:


Pass user specified destination type to UpdateSchemaDestination

Fixes #22543
When using multiple partitions for a BigQuery FILE_LOADS write, the user's dynamic destination type isn't properly passed into UpdateSchemaDestination. This leads to a ClassCastException when attempting to get the table and schema using the dynamic destination object.
The user's dynamic destination object is configured with a particular parameter type (represented by DestinationT) for getTable() and getSchema (see here). The current implementation from #17365 doesn't respect this user type and instead passes in a fixed TableDestination argument.

Run PostCommit_Java_DataflowV2

R: @johnjcasey

Run PostCommit_Java_DataflowV2

This LGTM. Have you retried the original failing custom dynamic destinations?

Yup, left a comment in #22543


adj

Description

Related links, issue #, if available: n/a
How has this been tested?

Review checklist
The following items are to be evaluated by the author(s) and the reviewer(s).
Correctness

Changes include appropriate documentation updates.
Changes are backward-compatible if not indicated, see CONTRIBUTING.md.
Changes do not include unsupported browser features, see CONTRIBUTING.md.
Changes were manually tested for accessibility, see accessibility guidelines.

Security

If the code handles URLs: all URLs are validated through the checkSafeUrl function.

Testing

Changes are covered with new/existing unit tests?
Changes are covered with new/existing integration tests?

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Thank you for the pull request but this does not seem to add anything that is not already tested in the existing test.


Mobile safari

Preview image not working on mobile safari most likely due to this:
https://github.com/stomita/ios-imagefile-megapixel
please check demo http://jsfiddle.net/alexk111/rw6q9/ in phone4/5/6 to confirm

I think the problem is related to orientation. I've checked the demo you posted (and one made by me) and if I upload an horizontal picture it works great (also with pictures of instagram with 1:1 ratio).
I don't know why this is affecting in mobile...
anyone has any clues?

someone discovered the reason?

The problem also exist in Safari for PC


Issue when freezing Embedding Layer

Hi Guys,
I need to feed custom weights to my embedding layer, so I do it using this line of code:
model.add(Embedding(47747, embedding_vecor_length, input_length=500, weights = [weights],dropout=0.2))
However, I need to prevent the embedding layer from changing these weights, so when I add trainable = False to the code:
Embedding(47747, embedding_vecor_length, input_length=500, weights = [weights],dropout=0.2, trainable = False)
I get the following error:
You called set_weights(weights) on layer "embedding_1" with a  weight list of length 1, but the layer was expecting 0 weights. Provided weights: [array([[-2.07139611,  0.38602829, -0.56659412, .....
Kindly help me correct the issue. Thanks in advance.

Hello,
Can't reproduce :
import numpy as np
from keras.layers import Input, Dense,Embedding
from keras.models import Model,Sequential

embedding_vecor_length = 100

nbvector = 47747
weights = np.random.randn(nbvector,embedding_vecor_length)

model = Sequential()
model.add(Embedding(nbvector, embedding_vecor_length, input_length=500, weights = [weights],trainable=False))

model.compile( loss="mse",optimizer="adam")

print model.predict(np.random.randint(0,nbvector,(32,500))).shape
model.fit( np.random.randint(0,nbvector,(32,500)),np.random.randn(32,500,100) )

@unrealwill
I run your code, and I get the same error:
ValueError: You called set_weights(weights) on layer "embedding_1" with a  weight list of length 1, but the layer was expecting 0 weights. Provided weights: [array([[-0.34739672, -1.25501704,  0.32280885, .....
I run it at keras1.2.0

@KiranBaktha
Did you have fixed this?

Hello,
I have not upgraded to keras 2 yet.
It worked fine on theano at the time.
But you can try to construct the layer with trainable = True,
and then set the layer to trainable=False on the next line.
emb=Embedding(47747, embedding_vecor_length, input_length=500, weights = [weights],dropout=0.2, trainable = True)
emb.trainable = False

Upgrade to the latest Keras and proceed this manner....
    inputs = Input(shape = (100,) , dtype = 'int32')
    Embs = Embedding(87510, embedding_vecor_length, input_length=50, weights =   [w1],mask_zero=True,dropout=0.2,trainable=False)
    Embsyo = Embs(inputs)


Update trainer.py

Delete progress_bar_refresh_rate in trainer.py

Description

delete  progress_bar_refresh_rate=5, since this keyword argument is no longer supported by the latest version (1.7.0) of PyTorch.Lightning.Trainer module
Motivation and Context

having this argument fails the training process

How Has This Been Tested?

Ran key to text on the custom dataset before and after August 2nd, 2022. Changes in the new version of Pytorch Lightning's Trainer were put into effect on that date where the above argument was removed and hence, the custom training failed since that day.

Screenshots (if appropriate):
Types of changes

[x] Bug fix (non-breaking change which fixes an issue)
[ ] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

[x] My code follows the code style of this project.
[x] My change requires a change to the documentation.
[ ] I have updated the documentation accordingly.
[ ] I have read the CONTRIBUTING document.

please attend to this PR about deleting progress_bar_refresh_rate in trainer.py


[QUESTION] How to know if a transaction incude mint action?

I'm trying to get the list of normal transactions, and then find transactions which include mint action in it. But I'm stuck on the second part.
for example, this transaction page include "Transaction Action" section which include "Mint" section.
https://etherscan.io/tx/0x7d47e77707dee45dff42e4857dcf53e957d37ca3249242838edb897f7da0ad88
seems that I can use method ID (4 bytes signature) to know what is the transaction about, but there are too many signatures. I don't think it's a reliable way to do this.
Is there any API call that I didn't notice include such info? Or I missed some point?
Sorry this is not an issue but just a question, I couldn't find other places to ask for help.

I found and checked the API Pro documentation and can't find an endpoint to get "Transaction Action" info either. Asked the question on Etherscan and got the answer

We unfortunately do not have an endpoint that returns the "Transaction Action" information at this point of time.
It is a popular one by request, and we will definitely consider to add it in a future update.


Issues with formatting of testimonials on home page.

Ticket 31: Is the guy at the bottom left the one who says "I stopped breathing...?" If so, the text is too far from his picture or it needs a bubble.
Ticket 14: Text is still overlapped on the photos w the testimonials.

Closed with landing page redesign in 3.0 release


Add support url-args for safari push notifications

@Blaze34 Thank you!

@dankimio when will new version with this feature be available?

Published the latest version to RubyGems!


Missing the symbol of "bitwise inclusive OR" in the "Operator precedence" section

[Enter feedback here]
The operator name of the 3rd row of the "Operator precedence" is "additive, bitwise inclusive OR". The corresponding syntax should be "+ - |", while currently it is displayed as "+ -". The symbol for the inclusive OR operator (|) is missing.

Document Details
⚠ Do not edit this section. It is required for learn.microsoft.com ➟ GitHub issue linking.

ID: dcd01709-02ec-2345-3e11-b404b2c8023f
Version Independent ID: 04233315-0218-bd79-454d-5e98a75e95a6
Content: X++ operators - Finance & Operations | Dynamics 365
Content Source: articles/fin-ops-core/dev-itpro/dev-ref/xpp-operators.md
Service: dynamics-365-cross-app
GitHub Login: @josaw1
Microsoft Alias: josaw

Bug 822992 has been logged to address this issue.

Fixed. Will be published today.


Theme does not work when Angular Material is used

I'm submitting a ...  (check one with "x")
[ ] bug report => search github for a similar issue or PR before submitting
[ ] feature request
[x] support request => Please do not submit support request here, post on Stackoverflow or Gitter

Current behavior

Table is not themed correctly if Angular Material is used. CellClass is not respected.
Expected behavior

Have the same appearance of the examples.
Reproduction of the problem

Create a project using angular cli, add angular material and create a table using ngx-datatable.
What is the motivation / use case for changing the behavior?

Please tell us about your environment:

Table version: 0.9.x

Angular version: 4.1.x

Browser: all

Language: TypeScript 2.X

Can you post a demo plz?

Hey @emauro,
Make sure you import the css in one of your parent components:
@import<EMAIL_ADDRESS>

@Ricardo Varanda
Thank You! You saved my day!

I noticed that when I put these imports into the .css file for the component, they only partially work. WebPack recognizes them, but for example with "Dark", the background of the table turns dark, but none of the other things are applied. When I moved the CSS imports to styles.css at the application level, it works. Is there something I'm doing wrong, or something I don't understand about CSS?

I noticed that when I put these imports into the .css file for the component, they only partially work. WebPack recognizes them, but for example with "Dark", the background of the table turns dark, but none of the other things are applied. When I moved the CSS imports to styles.css at the application level, it works. Is there something I'm doing wrong, or something I don't understand about CSS?

A bit late, but in case someone needs it:
Hey @dannychase2004
This is typically caused by the style encapsulation of the component. When using the style.css, the style apply to the project. But when you declare or import styles in a component, by default it will apply only to the current component, not his parent, nor his childs (ngx-datatable in your case).
You can either deactivate the encapsulation in you component directive, or use ::ng-deep in your component style file:
in your component style.scss
::ng-deep {
  @import<EMAIL_ADDRESS>  @import<EMAIL_ADDRESS>  @import<EMAIL_ADDRESS>}

or in your component.ts
import { Component, ViewEncapsulation } from '@angular/core';

@Component({
  selector: 'app-component',
  templateUrl: './component.html',
  styleUrls: ['./component.scss'],
  encapsulation: ViewEncapsulation.None  // This is the important part
})
export class Component { ... }

Caution with this. It may break other view.

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 7 days.

The same issue persists even with the solutions mentioned above. Is there a solution which someone has already found other than the above mentioned ones ?

adding the following in the global scss will take care of the above mentioned problem.  @import<EMAIL_ADDRESS>


[FEATURE] support for certificate signed by unknown authority

Hello
I like the idea of cattlectl very much.
I was follow the example on this post: https://medium.com/bitgrip/boosting-up-your-rancher-and-build-infrastructure-as-code-with-cattlectl-66ef7ea920eb
Rancher: v2.2.2
Result:
root@server-01:~# cattlectl apply
ERRO[0000] Failed to create management client            error="Get https://<IP_ADDRESS>/v3: x509: certificate signed by unknown authority" rancher.url="https://<IP_ADDRESS>"
FATA[0000] Error creating rancher client                 error="Failed to create management client, Get https://<IP_ADDRESS>/v3: x509: certificate signed by unknown authority"
I am not sure for the reason of this ERROR but I don't have a trusted certificate for my local Rancher Server with the local IP: <IP_ADDRESS>
Comes this ERROR from the self signed ssl certificate?
If yes how I can use cattlectl in this case?
Thanks in advance

Hallo,
This case is not yet supported. But I guess this feature is needed quite often.
For the implementation see clientbase. ClientOpts. Insecure
Add to 1.1.0

Hello
Thanks a lott.
Yes it would be very useful if you can implement it in the next version.
Have a nice day.

@ManCon This feature is now available starting with v1.1.0-rc1
Any feat back is welcome.


[wip] b/nddata

This patch works but it didn't provide any speedups as I would have hoped it would. Closing.


Add support for extracting key moments

Test:
from pytubefix import YouTube

yt = YouTube("https://www.youtube.com/watch?v=-xNR_1WJQ-E")
print(yt.key_moments)

Output:
[
    <KeyMoment: Time Query | 0:00:12>,
    <KeyMoment: Constructing Space | 0:00:15>,
    <KeyMoment: Loosing / recovering the ball | 0:00:20>
]

I noticed that self.initial_data['frameworkUpdates']['entityBatchUpdate']['mutations'][1]['payload']['macroMarkersListEntity']['markersList']['markers'] can sometimes be used to store "Most Replayed" data. I'll improve the logic later so please don't merge now.

I added support for both key moments (markerType == MARKER_TYPE_TIMESTAMPS) and the most reviewed heatmap (markerType == MARKER_TYPE_HEATMAP).
Example:
from pytubefix import YouTube

yt = YouTube("https://www.youtube.com/watch?v=rSKMYc1CQHE")
print(yt.replayed_heatmap)

Output:
[
 {'start_seconds': 0.0,
  'duration': 28.72,
  'norm_intensity': 0.7744516981592584},
 {'start_seconds': 28.72,
  'duration': 28.72,
  'norm_intensity': 0.5055251629407894},
 {'start_seconds': 57.44,
  'duration': 28.72,
  'norm_intensity': 0.3365084886794003},
......
]

Here I use float for start time and duration because I think they need to be more precise.


Define a custom user claim as the group extractor claim

Description:
Nipuni Chandrasoma reported as follows:
Need to add information on defining a custom user claim as the group extractor claim based on the WUM update.
WSO2-CARBON-PATCH-4.4.0-4428
https://github.com/wso2/product-apim/issues/3355
https://github.com/wso2-support/carbon-apimgt/pull/1420
Affected Product Version:
2.6.0

This information was added in APIM 2.6.0.
[1] https://docs.wso2.com/display/AM260/Sharing+Applications#SharingApplications-Definingacustomuserclaimasthegroupextractorclaim


contrib/quantization: Do not open dot file in binary mode

The Python 3 documentation states:
Since printed arguments are converted to text strings,
print() cannot be used with binary mode file objects.

Can one of the admins verify this patch?

@tensorflow-jenkins test this please.

Thanks @olesalscheider !


<EMAIL_ADDRESS>hash check failed

Installing 'babelpad' (<IP_ADDRESS>) [64bit]
Starting download with aria2 ...
Download: [#554d37 2.3MiB/5.9MiB(40%) CN:1 DL:7.5MiB]
Download: Download Results:
Download: gid   |stat|avg speed  |path/URI
Download: ======+====+===========+=======================================================
Download: 554d37|OK  |   9.0MiB/s|C:/Users/teddue/scoop/cache/babelpad#<IP_ADDRESS>#http_www.babelstone.co.uk_Software_Download_BabelPad.zip
Download: Status Legend:
Download: (OK):download completed.
Checking hash of BabelPad.zip ... ERROR Hash check failed!
App:         rasa/babelpad
URL:         http://www.babelstone.co.uk/Software/Download/BabelPad.zip
First bytes: 50 4B 03 04 14 00 00 00
Expected:    cdff383adb345bd6febdefd0dde276f277f3e6f7a9fd5cbf25029ba3ed8221ff
Actual:      82c0f9e7ad2295ad51d44a4b93e31b18fae3e46fa6e6d8eca40a464824510082

Fixed in https://github.com/rasa/scoops/commit/8dab51e8336a58bca2c36cf78de3733f02671ff6


Bioconda

Hi,
Would you be interested in creating a Bioconda for companion?
Michal

This looks like it could probably be easily done, but as I am not working full-time on Companion any more (nor do I use it) at the moment, I'm not sure I would be able to support/maintain it indefinitely. I'll see whether I can find the time to do it.


Disconnect listeners being removed can cause compatibility issues

Currently it seems socket.on('disconnect', ... listeners are being removed. This causes compatibility issues if the socket.io instance is being used by other services that listen to disconnect.
Workaround: for now, using socket.on('disconnecting', ... is a quick fix for most use cases.
I would propose not removing the other listeners and instead issuing a console warning if there are other listeners present.

Fixed in<EMAIL_ADDRESS>