eth_syncing endpoint returns false when execution client is not synced

Description
As a node operator, I want the eth_syncing endpoint to be consistent with the specification so that I can write integration tests against the client.
Acceptance Criteria
Return the non-false value when the besu has not been synced yet (not started/stalled/etc.). Return false only when in sync with the network.
(Based on the definition of execution API spec)
Edit: I have confused the execution and beacon API spec, false does not indicate synced status.
However, other clients do return non-false when not synced.
Steps to Reproduce (Bug)

Start besu

besu  --rpc-http-enabled --data-path=$HOME/.run-a-node/sepolia --network=SEPOLIA --engine-jwt-secret=$HOME/.run-a-node/sepolia/jwt.hex --rpc-http-api=ETH --rpc-http-port=8545

Start any of these clients of lodestar/nimbus-eth2/teku
Starting lodestar

lodestar beacon  --rest --checkpointSyncUrl https://beaconstate-sepolia.chainsafe.io --rest.port 5052 --execution.urls http://localhost:8551 --jwtSecret $HOME/.run-a-node/sepolia/jwt.hex --dataDir $HOME/.run-a-node/sepolia --network sepolia

Starting nimbus-eth2
curl -o $HOME/.run-a-node/sepolia/state.finalized.ssz   -H 'Accept: application/octet-stream' https://beaconstate-sepolia.chainsafe.io/eth/v2/debug/beacon/states/finalized

nimbus_beacon_node --network=sepolia --data-dir=$HOME/.run-a-node/sepolia --web3-url=http://localhost:8551 --jwt-secret=$HOME/.run-a-node/sepolia/jwt.hex --external-beacon-api-url=https://beaconstate-sepolia.chainsafe.io --finalized-checkpoint-state=$HOME/.run-a-node/sepolia/state.finalized.ssz --rest=true --rest-port=5052

Starting teku
teku --checkpoint-sync-url https://beaconstate-sepolia.chainsafe.io --network sepolia --ee-endpoint http://localhost:8551 --ee-jwt-secret-file $HOME/.run-a-node/sepolia/jwt.hex --data-path $HOME/.run-a-node/sepolia --rest-api-enabled true --rest-api-port 5052

Wait a couple of minutes (4-5 minutes)
Check endpoint result

curl -s -X POST --data '{"jsonrpc":"2.0","method":"eth_syncing","params":[],"id":0}' -H Content-Type: application/json http://localhost:8545
{"jsonrpc":"2.0","id":0,"result":false}

Alternate behavior, where it returns non-false

Start besu

besu  --rpc-http-enabled --data-path=$HOME/.run-a-node/sepolia --network=SEPOLIA --engine-jwt-secret=$HOME/.run-a-node/sepolia/jwt.hex --rpc-http-api=ETH --rpc-http-port=8545

Start any of these clients of lighthouse/prysm
Starting lighthouse

lighthouse beacon_node  --disable-deposit-contract-sync --http --checkpoint-sync-url=https://beaconstate-sepolia.chainsafe.io --datadir=$HOME/.run-a-node/sepolia --execution-endpoint=http://localhost:8551 --execution-jwt=$HOME/.run-a-node/sepolia/jwt.hex --http-allow-origin='*' --http-port=5052 --network=sepolia

Starting prysm
beacon-chain  --accept-terms-of-use --sepolia --datadir=$HOME/.run-a-node/sepolia --checkpoint-sync-url=https://beaconstate-sepolia.chainsafe.io --disable-grpc-gateway=false --execution-endpoint=http://localhost:8551 --genesis-beacon-api-url=https://beaconstate.info --grpc-gateway-port=5052 --http-modules=eth --jwt-secret=$HOME/.run-a-node/sepolia/jwt.hex

Wait a couple of minutes (4-5 minutes)
Check endpoint result

curl -s -X POST --data '{"jsonrpc":"2.0","method":"eth_syncing","params":[],"id":0}' -H Content-Type: application/json http://localhost:8545
{"jsonrpc":"2.0","id":0,"result":{"startingBlock":"0x0","currentBlock":"0x190","highestBlock":"0x6087a7"}}

** Expected behavior: ** Return a non-false value. The spec needs to be clarified on what it should return when sync is not started, but it does indicate when to return a false value.
Actual behavior: The current behavior is pretty random; it's inconsistent between CL clients.
Frequency: Always.
Logs (if a bug)
It's reproducible; I don't want to include 10 logs for brevity. If it is needed, let me know; I can provide it.
Versions (Add all that apply)

Software version: besu/v24.6.0/linux-x86_64/oracle-java-21
Java version: java 21.0.2 2024-01-16 LTS Java(TM) SE Runtime Environment (build 21.0.2+13-LTS-58) Java HotSpot(TM) 64-Bit Server VM (build 21.0.2+13-LTS-58, mixed mode, sharing)
OS Name & Version:

PRETTY_NAME="Debian GNU/Linux 12 (bookworm)"
NAME="Debian GNU/Linux"
VERSION_ID="12"
VERSION="12 (bookworm)"
VERSION_CODENAME=bookworm
ID=debian
HOME_URL="https://www.debian.org/"
SUPPORT_URL="https://www.debian.org/support"
BUG_REPORT_URL="https://bugs.debian.org/"

Kernel Version: Linux debian 6.1.0-22-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.94-1 (2024-06-21) x86_64 GNU/Linux
Consensus Client & Version if using Proof of Stake: latest consensus clients

Additional information
geth/nethermind/erigon will always return non-false for not synced clients against the same settings provided for (lighthouse/lodestar/nimbus-eth2/prysm/teku). reth has a similar issue returning false when not synced on a network where peers are slow to show up.

Hi @eenagy, I'm not able to reproduce this with the latest code on Besu/Teku main branches. Can you provide the logs from when you saw this issue? Just the Besu and Teku logs for now.

This morning, I tried again with Besu 24.6.0 and found that syncing appeared to stall, after which the eth_syncing endpoint would return false.
2024-08-21 10:15:23.182+10:00 | EthScheduler-Services-42 (importBlock) | INFO  | ImportBlocksStep | Block import progress: 3643797 of 6535007 (55%), Peer count: 1
2024-08-21 10:16:54.904+10:00 | EthScheduler-Services-1 (checkNewPivotBlock-Account) | INFO  | WaitForPeersTask | Waiting for 1 total peers to connect. 0 peers currently connected.
2024-08-21 10:17:26.836+10:00 | EthScheduler-Timer-0 | INFO  | SyncTargetManager | Unable to find sync target. Currently checking 0 peers for usefulness.

Hi there. I'm currently implementing sync status in NiceNode, and I'm also seeing the difference in eth_syncing response behavior compared to other clients, where they usually return an object in the beginning stages of syncing.
Geth
{
    "currentBlock": "0x0",
    "healedBytecodeBytes": "0x0",
    "healedBytecodes": "0x0",
    "healedTrienodeBytes": "0x0",
    "healedTrienodes": "0x0",
    "healingBytecode": "0x0",
    "healingTrienodes": "0x0",
    "highestBlock": "0x0",
    "startingBlock": "0x0",
    "syncedAccountBytes": "0x0",
    "syncedAccounts": "0x0",
    "syncedBytecodeBytes": "0x0",
    "syncedBytecodes": "0x0",
    "syncedStorage": "0x0",
    "syncedStorageBytes": "0x0",
    "txIndexFinishedBlocks": "0x0",
    "txIndexRemainingBlocks": "0x1"
}

Nethermind:
{
     "startingBlock": "0x0",
     "currentBlock": "0x0",
     "highestBlock": "0x0"
}


Fix lint error in common.go file

File: common.go
Line 26: warning: exported var StartingTime should have comment or be unexported (golint)

@rbo13 Sure, you can take this


remove link to rewards page on website

this page does not exist any more

Replacing with a different PR because of unrelated build issues


Support dedicated Tenancy when create instances at AWS?

According to this Amazon documentation http://docs.aws.amazon.com/AmazonVPC/latest/UserGuide/dedicated-instance.html, AWS users can  launch instances into a VPC with a tenancy attribute ('default' for running on shared hardware and 'dedicated' for running on single-tenant hardware).
Will vagrant-aws provide attribute to set the tenancy when create instances at AWS?
E.g. in the Vagrantfile,
aws.tenancy=default    (for instance runs on shared hardware)
or
aws.tenancy=dedicated (for instance runs on single-tenant hardware)

I just supplied #395  that adds this functionality.  Fairly simple since the library the plugin uses, fog, already had support for this feature.


swapping Usage content to not be header links

this is for #1306
Unless I'm missing something Usage links but the Examples subheaders are being pulled into sidebar when they shouldn't be?
screen recording of Usage working as expected
closes #1306

So I think this will fix but I think maybe the title I used for that issue caused some confusion. By "Link Usage" I meant using links in headers shouldn't display the actual markdown in the sidebar:

@skipjack totally agree on the header links thing. we'll see how it shakes out re:

we'll be updating our whole markdown parsing process soon anyway (see webpack-contrib/webpack-defaults#73).

But doc linking to a linked header could be as simple as adding the link title twice, once as an id as well as href when processed? Just a suggestion as I'm sure that'd probably have unintended implications in other parts of the documentation.


Add step to filter final SV calls based on stitchPositions

Within the callSV module, add step to filter SMAP based on input stitchPositions BED file.
Take final _merged_inversions_filter.smap and create new smap that contains additional classifications for insertions, deletions, and inversions that overlap categories or names in the input BED file. Idea being that the "names" of the input BED could change or be added to and new categorizes would automatically be created. For example, if a deletion overlapping a TypeI stitchPosition would be output with name deletion_TypeI in the new smap.

also output updated SV Summary


primechecker in java

java code, which runs in O(sqrt(n)), to check if the entered number is prime or not

@bhaveshlohana apparently your repo is not eligible for hacktoberfest, can you add a hacktoberfest-accepted label to my PR?

check #1429


fix: adapt to simplified code response

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

Comparison is base (9b50817) 2.42% compared to head (d8019d2) 2.42%.

:exclamation: Current head d8019d2 differs from pull request most recent head a97300f. Consider uploading reports for the commit a97300f to get more accurate results

Files
Patch %
Lines

...service/completion/JavaSdkCompletionContributor.kt
0.00%
26 Missing :warning:

Additional details and impacted files
@@          Coverage Diff           @@
##           master     #27   +/-   ##
======================================
  Coverage    2.42%   2.42%
======================================
  Files          25      25
  Lines        2187    2187
  Branches      300     300
======================================
  Hits           53      53
  Misses       2122    2122
  Partials       12      12

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


⚠ NCAA has degraded performance

In e354996, NCAA (https://www.ncaa.com) experienced degraded performance:

HTTP code: 200
Response time: 1233 ms

Resolved: NCAA performance has improved in cb72aab.


Tiny Spelling Mistake

On the "Authorise your Twitch account..." tab, you've written

This is the only way that Twitch Leecher can verify that your are subscribed to the channel...

"your are"
It should be:
"you are"
or
"you're"
As I'm sure you are aware.
It's only tiny, but it is in fact an error.

Whops... must have been late when I wrote it :P
I do not download sub-only VODs myself, thx for the info!


KNOWN ISSUE: Error immediately on startup

I am aware of the error that happens immediately on startup. It slipped under the radar of the testing suite due to not being encountered. Please use npm i<EMAIL_ADDRESS>until 1.2.4 is released.

This has been resolved in 1.2.4


Proposal: Improve CI runtime

The build-and-test jobs are taking more than 10 minutes.  Here some proposals to speed this up:

Configure sccache on the self-hosted runners:
We run on self-hosted runners but use SCCACHE_GHA_ENABLED.  We should instead set a SCCACHE_CACHE_SIZE=80G and use the (default) local cache mechanism.

Reduce the number of steps:
We do not need a separate check step, it achieves nothing.  Instead run test straight away.

Split default-features and no-features into separate jobs
Because these jobs are compiling iroh with  different feature flags we can parallelise these more by moving the tests to two jobs: test-default-features, test-no-features.  Only worth it if we have enough runners.  Maybe we should get more runners if that's needed.

Switch to cargo-nextest

Yeah we've discussed this a couple weeks back.
Think this will need some testing, but correctly configuring sccache should get it to work.
Some caveats to the above proposal:

sccache is not installed on the windows boxes afaik rn (and on the x86_64 mac runner) - I can remedy this
we generally want a system configured sccache for this to work propperly but might be worth just setting the env vars for sccache, might be enough
the check step is necessary cause it does the full matrix of features individually which doesn't suffer from feature unifying when mashing them together (it does add about 3-4 min to the total runtime sadly)
doing cargo nextest alone will not automatically speed things up, but as discussed will allow us to start splitting jobs up further to do them in parallel by testing in chunks
splitting into more jobs brings a little bit of overhead to each job (caches aren't shared) which would be perfectly fine given we have enough nodes running, but we don't so all the parallel jobs will just get scheduled sequentially + overhead for now, we're already maxing out runners and cross and regular builds wait for each other in a single PR
release jobs take a lot longer anyways since they run builds with LTO which adds like 10 min to the whole thing out of the box and you can't split it off further, which hogs runners when merging a lot to main.

Either way I wholly support the cause.

sccache will help regardless (given proper setup)
we need more runners
nextest is a good stepping stone

Yeah we've discussed this a couple weeks back. Think this will need some testing, but correctly configuring sccache should get it to work. Some caveats to the above proposal:
* sccache is not installed on the windows boxes afaik rn (and on the x86_64 mac runner) - I can remedy this

I think we can keep using the action to install it.  Maybe I'm wrong but I'll try it.

* we generally want a system configured sccache for this to work propperly but might be worth just setting the env vars for sccache, might be enough

Same answer

* the check step is necessary cause it does the full matrix of features individually which doesn't suffer from feature unifying when mashing them together (it does add about 3-4 min to the total runtime sadly)

oh, it runs a check job separately for each package in the workspace.  Does this really make a difference to the features enabled for each crate on the test runs later?
A summary of all the crates with features and their deps on each other:
iroh

default: cli, metrics
cli: (non-iroh deps)
metrics: iroh-metrics
flat-db: iroh-bytes/flat-db
test:

iroh-base

default: hash, base32
hash: (non-iroh deps)
base32: (non-iroh deps)

iroh-bytes

default: flat-db
flat-db: (non-iroh deps)

iroh-gossip

default: net
net: iroh-net, (non-iroh deps)

iroh-metrics

default: metrics
metrics: prometheus-client

iroh-net

default: metrics
derper: (non-iroh deps)
metrics: iroh-metrics/metrics

iroh-sync

default: net, fs-store, metrics
net: iorh-net, (non-iroh deps)
fs-store: (non-iroh deps)
metrics: iroh-metrics

from this i think the --no-default-features run will not change between doing this per-package or on the workspace.
For default features this is also true, since no default feature on one crate enables a non-default feature in another crate.
Finally reasoning through the --all-features case we also end up with  the same deps in each crate when we do it per-crate or for workspace.
So, as far as I understand this would not change things?  I had to write this down to get to that conclusion though.

* doing cargo nextest alone will not automatically speed things up, but as discussed will allow us to start splitting jobs up further to do them in parallel by testing in chunks

Running nextest does speed things up on my local machine, even without any other changes.  Unless the runners are single-core machines I expect this to also speed up on CI?  Did I get this wrong?

* splitting into more jobs brings a little bit of overhead to each job (caches aren't shared) which would be perfectly fine given we have enough nodes running, but we don't so all the parallel jobs will just get scheduled sequentially + overhead for now, we're already maxing out runners and cross and regular builds wait for each other in a single PR

Once we have a working sccache setup the caches for all the dependencies will be shared.  Crucially IIUC currently the target directory stomps over itself between the different feature combination runs.  By strategically splitting up the steps into jobs so each job sticks to one feature combination we avoid that stomping over each other in the target directory while getting cache benefits of the deps still via sccache.
At least that is my understanding currently.

* release jobs take a lot longer anyways since they run builds with LTO which adds like 10 min to the whole thing out of the box and you can't split it off further, which hogs runners when merging a lot to main.

I had not yet looked at release builds, I only looked at improving PR iteration in this issue.  But we can totally improve release builds using our learnings from this here if this all works out.

I still suspect we'll catch most issues without having the duplicate cargo check runs, though could be convinced to leave them for now.

you are welcome to change them for test calls, but we need for each feature and each crate to have an individual execution, there is no way around this. before we had this, I was regularly running into issues when doing releases, because feature unification hid a dependency/inclusion issue.

Another option if you can set it up is to use a Redis cache with sccache. We had very good results with a single Redis and multiple build runners (on gitlab if that matters).

We run on self-hosted runners but use SCCACHE_GHA_ENABLED. We should instead set a SCCACHE_CACHE_SIZE=80G and use the (default) local cache mechanism.

There is an Earthly blog post about speeding up Rust compilation by using a local cache: https://earthly.dev/blog/incremental-rust-builds/ Main idea is to use Rust local caching with persistent build runners and not try to upload/download the cache anywhere at all. Reduction from 22.5 minutes to 2.5 minutes looks strange, looks like baseline did not cache dependency builds at all: expressvpn/wolfssl-rs#44 But otherwise the idea of not trying to upload/download Rust cache and simply keeping the target/ folder on the runner makes sense.

The approach I suggest here (and implemented in https://github.com/n0-computer/iroh/pull/1865) takes this approach as well: it uses sccache with the (default) local storage.  This means once each local runner has seen all our builds, they will all have a local cache of the dependencies available, significantly speeding up future builds.  In the PR above this results in compilation time improvements across the board.
This takes a little longer to fill up the local caches than the shared cache like you tried with WebDAV, but if your number of projects is proportionally low to the number of runners this works well I think, and has less overhead than using WebDAV (which is interesting, thanks for teaching me about it, but surprised you didn't find it worked for you).  I think the local cache is a good solution for our current situation.  We can improve with webdav or redis once we really need a shared cache.

using WebDAV (which is interesting, thanks for teaching me about it, but surprised you didn't find it worked for you)

It works and stored 3.3 G on WebDAV already. But sccache does not add anything to https://github.com/Swatinem/rust-cache/, i.e. just storing a target/ folder in GitHub actions cache. The only problem is that GHA cache is maximum 10 G. cargo is better at caching than sccache because sccache only caches full compilations of dependencies (i.e. rustc invocations) while cargo has incremental compilation support. If you have a choice between 1) always losing target/ and using sccache for caching 2) using no sccache, but keep target/, second variant is going to win. Earthly simply mount the target/ and .cargo folders into build containers and use no sccache at all.

makes sense, thanks for the explanation.
I was sort of considering incremental compilation to not be very interesting for CI times, but I guess it could have an impact on the iroh crates itself as PRs rarely touch everything.
I think the main reason sccache tends to be faster than rust-cache is that the latter has to download all the cache files from the last run up-front, including plenty of files that might not be used.  While sccache only fetches cache hits.


Include run time to create/build factories in ActiveSupport::Notifications

Problem this feature will solve
Currently only 'factory_bot.run_factory' is instrumented. This doesn't include any of the time it takes to setup associations. In our project this is by far the slowest part by multiple magnitudes, and would be nice to have instrumented.
Desired solution
Include ActiveSupport::Notifications for build, build_stubbed, and create.
Ideally this would include object allocations to help debug highly nested factories.

Notice that test-prof needs to monkey patch factory_bot to add Notification for create manually

Oh and we'd need the after block.
eg) after(:build) { |user| user.big_object = create(:slow_factory)

Maybe all i need is for factory_bot to include the after hooks.. I added this in my user factory:
after(:create) do
  sleep(2)
end

But the event duration shows < 50 µs for run_factory

This also measures 4 µs instead of 2 s, even when I put the sleep call inside after(:build)
module FactoryBot::Syntax::Methods
  old_create = instance_method(:create)

  define_method(:create) do |name, *traits_and_overrides, &block|
    ActiveSupport::Notifications.instrument('factory_bot.create') do
      old_create.bind(self).call(name, *traits_and_overrides, &block)
    end
  end
end

RSpec.configure do |config|
  config.include FactoryBot::Syntax::Methods
end

So given a completely clean environment with only this, I am not able to reproduce this issue:
require 'active_support'

ActiveSupport::Notifications.subscribe(/.*/) do |event|
    puts '*' * 20
    puts "Received event: #{event.name}"
    puts "      duration: #{event.duration}"
    puts "   allocations: #{event.allocations}"
    puts '*' * 20
end

class User
  attr_accessor :first_name
end

require 'factory_bot'

FactoryBot.define do
  factory :user do
    first_name { "John" }
    after(:build) { sleep(1) }
  end
end

require 'rspec'

RSpec.configure do
  include FactoryBot::Syntax::Methods
end

describe User do
  it 'builds a user' do
    expect(build(:user).first_name).to eq("John")
  end
end

Output:
$ rspec test.rb
********************
Received event: factory_bot.run_factory
      duration: 1001.3912379999965
   allocations: 362
********************

There must be some kind of configuration issue in my other project. Going to close this and update if I learn what caused it..


docs(secretstore): add a new TencentCloud SSM (Secrets Manager)

https://github.com/dapr/dapr/pull/5026
https://github.com/dapr/components-contrib/pull/1973

/cc @msfussell

/keep-alive

/cc @yaron2 @msfussell @artursouza

/keep-alive


Roll engine da78549e9476..05365c4c3279 (1 commits)

https://github.com/flutter/engine/compare/da78549e9476...05365c4c3279
git log da78549e947649b0c82734f67871f7203b4c2882..05365c4c32798005deebc859c1e239bff5a885e4 --no-merges --oneline
05365c4c3 Revert change by mistake: extract resources (flutter/engine#9180)
The AutoRoll server is located here: https://autoroll.skia.org/r/flutter-engine-flutter-autoroll
Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+/master/autoroll/README.md
If the roll is causing failures, please contact the current sheriff (bmparr@google.com), and stop
the roller if necessary.

Trybots failed. These were the failed builds: https://cirrus-ci.com/task/4578566038093824

Commit queue failed; closing this roll.


Add cellranger.wdl

Add a WDL that runs the cellranger count command, and a Dockerfile that builds cellranger from the source code and installs all of its requirements.
Addresses ticket: https://github.com/HumanCellAtlas/secondary-analysis/issues/245
Please ensure the following when opening a PR:

[ ] Added or updated tests
[ ] Updated documentation
[ ] Applied style guidelines
[ ] Considered generalizability beyond our own use case

Thanks for the comments @dshiga and @mckinsel! Let me know if these changes look good to you!

Yep looks good. Thanks!


NDAInit and malloc...

I noticed NDAClose() (by way of NDAInit) was sometimes trying to close an invalid window.  It turns out that the compiler-generated glue code calls ~DAID before calling your NDAInit.  When starting up, it generates a new User ID for mallocs.  When shutting down, it disposes that ID (effectively free()-ing everything that's been malloced). This happens before NDAInit is called.
The main issue though is that NDAInit(0) can be called multiple times without an intervening NDAInit($ffff) and the globals variable isn't nulled out unless globals->ndaActive is true, so there's dangling memory.   If someone else happens to NewHandle it and starts writing data into it, NDAInit()/NDAClose() will try to close something that isn't a window which can crash hard.
https://github.com/byteworksinc/SysLib/blob/4ff5bdbc7ceb0f46e6756d2dd4f3efc730de4f1b/cd.asm#L506-L571
https://github.com/jeremysrand/Listener/blob/0071f3d4ebfe11e4dc347b3bb7c070842e5aa957/Listener/main.c#L237C1-L254C2

I think my latest commit should address the problem.  I have decided to move all memory allocation/deallocation to the NDAOpen() and NDAClose() routines.  The only thing I am doing in NDAInit() is save the userid now.
Does this look good to you?  Any feedback greatly appreciated.  If this is good, I will issue a v1.0.1 update.  Thanks!

That looks good to me.  Thanks!


Optimise main function to remove dependency on data loading for each file

Currently the main function instantiates all days and stores it into a dictionary even if the command requires to run one day.
There are 2 solutions to this

Rework all files to not load data in new() rather create an empty struct in new and have a special load() that loads that data during run part
Rework main.rs > main() to not instantiate all days rather store the reference to the Day struct and instantiate before the run part.

Reworked main function to only instantiate the day required


Empty media type

Hello, nifty little lib you got here!
I have a problem with mediaType property. At first couple of actions it is set to 'infinity', but soon becomes an empty object.
I've tracked the problem down to createResponsiveStateReducer.getMediaType and the call to transform, it does some weird reassigns instead of mutating the result.
It is easy to quickfix:
return transform(mediaQueries, (result, query, type) => {
    // if the browser matches the media query
    if (matchMedia(query).matches) {
        // use the current media type
        /* eslint-disable no-param-reassign */
        result.type = type
        /* eslint-enable no-param-reassign */
    }
}).type

The real question is, why use media queries in the first place? Other properties are calculated based  solely on breakpoints, it is very simple and intuitive. This whole media matching stuff just seems like an unnecessary complexity

Thanks for taking the time to make an issue!
I think you're right that the use of mediaQueries is unnecessary. If you wanted to make the change in a PR I would be happy to merge it. Otherwise I could do it later tonight.

Ahh yes, good catch!  And thanks for making the issue!
I think the fix we are after is very close to what you have, but more along the lines of
// there is a window, so compute the true media type
return transform(mediaQueries, (result, query, type) => {
    // if the browser matches the media query
    if (matchMedia(query).matches) {
        // use the current media type
        return type
    }
    // otherwise the browser does not match the query
    // so return the previous result
    return result
// start off the accumulator with the default value
}, defaultMediaType)

Hey @tstavinoha, the reason we want to use mediaquery is because it will match against different media types like portrait or landscape.
Regardless, I think you have found a bug in the reducer that we are investigating now.

I'm not sure I'll catch the time to do a PR, especially because i cant write tests :)
However, what i would do is the following regarding dropping the media queries:

In the reducer factory, ditch the media queries and create an internal array of breakpoint data, sorted by width, e.g. var sortedBreakpoints = Object.keys(breakpoints).map(bp => {return {value: breakpoints[bp], mediaType: bp}}).sort((a,b) => {return a-b})

pass the width and sorted breakpoints to:
 function getMediaType(width = Infinity, sortedBreakpoints = []) {
     for (var i = 0; i < sortedBreakpoints.length; i++) {
     if (width < sortedBreakpoints[i].value) {
         return sortedBreakpoints[i].mediaType;
     }
 }

 return 'infinity';

}
let sortedBreakpoints = Object.keys(breakpoints).map(bp => {return {value: breakpoints[bp], mediaType: bp}}).sort((a,b) => {return a-b});

And yes, as @aaivazis notes, the use of the mediaquery library allows users to specify custom (non-numerical) media queries (such as @media all and (color-index)).  This article on MDN explains some of the other more exotic uses of media queries that do not quite fit into the more simple use case only involving screen widths.

Alright, you guys know better than me what needs to be done with this lib :)
Glad i could point out a bug

No don't doubt yourself! :smiley:
You bring up a great point and we are only discussing the relative merits of including / excluding the use of mediaquery.
Thanks for the tips, and feel free to (or not) continue to be a part of the discussion!

@tstavinoha I just pushed a fixed for your bug. Please let me know if you run into any more problems

For further discussion regarding the current implementation's design choice to

allow for non-numerical breakpoints in the the mediaType property
return false for any non-numerical breakpoint in the greaterThan and lessThan properties

see #4.


strip script and style tags from parsed html

currently the contents of the <script> tag is present in the plaintext "value" of a property parsed from an e- class. adds failing test to demonstrate that.
removes script and style tags before parsing http://microformats.org/wiki/microformats2-parsing-issues#exclude_style_elements_before_parsing
fixes the URL resolving test in 5.4 by accepting that result

@barnabywalters Care to review this change? Between this PR and the last one (#82) I'd love to get a new release published.

Thanks for the PR! I’m strongly in favour of removing these elements from plaintext properties, but strongly against removing them from raw html properties. I mentioned this objection in IRC and on http://microformats.org/wiki/microformats2-parsing-issues#exclude_style_elements_before_parsing, awaiting feedback from other implementors.

@barnabywalters agreed! Feel free to revise this PR.

Revised and merged! Thanks for you work on this issue @aaronpk!


add stencil manufacturers

Thanks, would you be able to add some others besides Aisler, e.g. OSH Stencils?

Yes, would still be good to list stencil manufacturers though.


Why Substring matching?

The * column gridclasses use substring matching to determine the coulmn width: *= "five column"
I'd prefer to have fiv.column.gridfor that, because substring matching as is defines the position. When using frameworks like angular the new class always is the last -> ui column grid fivewhich is a problem atm, but the class selectors would work anyways.
Why is substring matching used and would it be possible to change that?

See #396


Explorer eval and gambits should not be visible on running games (like correspondence)

On correspondence games, lichess authorizes the opening explorer. but on lichess tools there is a features which allowed people to see next to the moves the cloud evaluation and/or the engine evaluation. I was wondering if it's allowed by the rules of lichess to see that on the opening explorer during a correspondence game and could be considering as cheating

Fixed in v2.2.5


Using for a GitHub Project

How can it be used for a Public GitHub repository to find bug-fixing commits and the modified code [for any release]?

If you mean to track issues to commits you should be able to use Githubs own api. Unfortunately the current script that finds bug fixes doesn't support github, only JIRA at the moment.

I suggest closing this issue. Anyone would be welcome to submit a pull request with support for additional issue trackers.


Support Carthage

I supported install use Carthage.
Please Review.
Thanks.

Thanks @rizumi! I'm not too familiar with Carthage, so is anything else needed for compatibility or is this setup sufficient?

@xoudini Thanks for merge.
Please add new tag from current master branch.
Then you're done Carthage support is complete!

Thanks! Tagged 0.9.7.


feat(ui-watt): copy to clipboard directive

Description
This is a relatively low-level directive for adding "copy to clipboard" functionality to any element. The reasoning for keeping it at this level is that it is going to be used in a variety of ways, so adding styles to it would not make much sense. It also requires translations (which cannot be provided by watt), so this encourages the consuming teams to create their own abstraction on top of this directive.
References

#924

praise: looks great 🌟
question: do you think we should configure DH to replace WattClipboardIntlService and work with changing language, etc. so it's ready for other developers to just use? It can also be a follow up PR.

question: what about tests? Should we add some as well?


Contact us page is not reponsive

@codervivek5 contact us page is not responsive and gets cluttered on resize
Assign me this issue so I can resolve it

@codervivek5 I want to work on this project please assign it to me

Kindly share your changes before PR so that I can atleast view tham make PR for code review...

Suree


Remove leftover directories during rpm uninstall

Now that the Presto lib directories
are modified outside of rpm install (we create symlinks in
/usr/lib/presto/lib and plugin location), a rpm uninstall
leaves these empty directories behind if not explicitly
cleaned up in "postremove" step.

Merged, thanks!


Changing Transaction::V1 json serialization

TransactionV1Payload::fields from now will be serialized as a human-readable JSON. Uptill now it was a map of <u16, Bytes>, currently it will be serialized as <String, serde_json::Value>. An example Transaction::V1 json representation will look like:
{
  "Version1": {
    "hash": "5e8d4e9ad52a4aad34515fc4a8620166e37de362054b7916ea5d01c671217101",
    "payload": {
      "initiator_addr": {
        "PublicKey": "0126c6506b6e200c8a5501571bbed5de32c44b979a8f1fb36f36f585d823562935"
      },
      "timestamp": "2020-08-07T01:31:28.867Z",
      "ttl": "5m 1s 253ms",
      "chain_name": "cjain-1",
      "pricing_mode": {
        "Fixed": {
          "additional_computation_factor": 0,
          "gas_price_tolerance": 5
        }
      },
      "fields": {
        "args": {
          "Named": [
            [
              "xyz",
              {
                "bytes": "0d0000001af81d860f238f832b8f8e648c",
                "cl_type": {
                  "List": "U8"
                }
              }
            ]
          ]
        },
        "entry_point": "AddBid",
        "scheduling": {
          "FutureEra": 195120
        },
        "target": "Native"
      }
    },
    "approvals": [
      {
        "signer": "0126c6506b6e200c8a5501571bbed5de32c44b979a8f1fb36f36f585d823562935",
        "signature": "015d5c48f6dbc44ba6ca7202fc5bc9cf9861586f1762343fe29812bac0b96b63b89f4daa97ff37423e75a127cef163bcd9f6fcbe94e3743160814b12a8407fa107"
      }
    ]
  }
}

bors r+


import ReactPlayer from 'react-player/lazy' fails with vite

Current Behavior
The app crashes with the following error:

Uncaught Error: Element type is invalid. Received a promise that resolves to: [object Object]. Lazy element type must resolve to a class or function.
at mountLazyComponent (react-dom_client.js?v=53134127:14671:17)
at beginWork (react-dom_client.js?v=53134127:15653:22)
at beginWork$1 (react-dom_client.js?v=53134127:18882:22)
at performUnitOfWork (react-dom_client.js?v=53134127:18358:20)
at workLoopSync (react-dom_client.js?v=53134127:18298:13)
at renderRootSync (react-dom_client.js?v=53134127:18277:15)
at recoverFromConcurrentError (react-dom_client.js?v=53134127:17900:28)
at performConcurrentWorkOnRoot (react-dom_client.js?v=53134127:17848:30)
at workLoop (react-dom_client.js?v=53134127:195:42)
at flushWork (react-dom_client.js?v=53134127:174:22)
mountLazyComponent @ react-dom_client.js?v=53134127:14671
beginWork @ react-dom_client.js?v=53134127:15653
beginWork$1 @ react-dom_client.js?v=53134127:18882
performUnitOfWork @ react-dom_client.js?v=53134127:18358
workLoopSync @ react-dom_client.js?v=53134127:18298
renderRootSync @ react-dom_client.js?v=53134127:18277
recoverFromConcurrentError @ react-dom_client.js?v=53134127:17900
performConcurrentWorkOnRoot @ react-dom_client.js?v=53134127:17848
workLoop @ react-dom_client.js?v=53134127:195
flushWork @ react-dom_client.js?v=53134127:174
performWorkUntilDeadline @ react-dom_client.js?v=53134127:382
Show 11 more frames

Expected Behavior
I expect the video to load
Steps to Reproduce

Download my minimal example: https://github.com/DouglasDev/vite-react-player-bug
run npm i
run npm run dev
The app will crash

Environment

URL attempting to play: any
Browser: chrome v 100
Operating system: mac

It seems like my implementation of lazy loading players is prone to errors. I am open to better suggestions.
Would it be better to just have a component that accepts a players array and you just import anything that you need? eg:
import ReactPlayerCustom from 'react-player/custom'
import Youtube from 'react-player/youtube'
import Facebook from 'react-player/facebook'

<ReactPlayerCustom players={[Youtube, Facebook]} etc etc />

I think the current api is good. I have an app where a user can enter any video url so it would be good if react player could automatically figure out which player to load (like it's doing now) since I can't know in advance. If I have time today, maybe I can figure out what the actual cause of the error is and open a PR.

@cookpete That looks great. We import everything cause of that problem, but only use file with hls at radio.net.

@cmaerz I have to ask… why not just use hls.js directly instead of importing this whole library?

@cookpete We mostly play radio streams i guess that mostly uses either just the file player or the hls player. I had problems with just importing the file player, but tbh I don't really know why.

If it may help, problem stems from dynamic imports of players/index
var _default = [{
  key: "youtube",
  name: "YouTube",
  canPlay: _patterns.canPlay.youtube,
  lazyPlayer: (0, _react.lazy)(function() {
    return import(
      /* webpackChunkName: 'reactPlayerYouTube' */
      "./YouTube-PILJPAEI.js"
    ).then(m => {
      console.log('lazy vite')
      /*
        Here in vite, m is a module
        m.default contains { default: fn, __esModule: true }

        in wp, returning m is ok, in vite it is not
      */
      // below fix for vite
      return m.default
    });
  })
}

A workaround would be e.g to lazyPlayer: lazy(() => import(/* webpackChunkName: 'reactPlayerYouTube' */'./YouTube').then(m => m.default.default ? m.default : m))
pretty much what does
function _interopRequireDefault(obj) {
  return obj && obj.__esModule ? obj : { "default": obj };
}

This feels a lot intrusive in source code so I guess an esm export would be preferrable (as @DouglasDev suggested)?

We are also facing the same issue with Vite in dev (esbuild). I think an ESM export would be the best way forward too.

I'm getting the same error. Anyone with a solution?

I am not getting an error but it is not working with vite in dev mode either, though is fine with the prod build. @cookpete , is it confirmed that simply adding an untransformed ESM version to the npm package would fix the bug?

I'm still having this issue using ReactPLayer for loading Reddit videos in an app that builds with Vite. Is there a workaround for this?

Hi @cookpete! Do you think we could reopen this issue (at least for clarity sake)? Thank you so much!

I also have this issue. For now, we're not using lazy but we definitely experienced the crash after moving to Vite from CRA.

Maybe it's a little bit too late but in my case the import of lazy component throw general error about not found the start template. I realizied the solution:
import { Suspense, lazy, useEffect, useState } from 'react' import { BaseReactPlayerProps } from 'react-player/base'
const Loader = () => {     return (

     ) }
const VideoPlayer = (props: BaseReactPlayerProps) => {
    const [Component, setComponent] = useState<React.ComponentType<BaseReactPlayerProps> | null>(null);
useEffect(() => {
    setComponent(() => lazy(() => import('react-player/lazy')))
}, [])

if (!Component) {
    return <Loader />;
}

return (
    <Suspense fallback={<Loader />}>
        <Component {...props} />
    </Suspense>
)

}
export default VideoPlayer;
I've used node 20.x, vite 5.0, react 18.2, react-player 2.16.0, together with the Laravel / Inertia stack. Hope this would help someone.

this should be fixed in v3.0.0-canary.1
https://www.npmjs.com/package/react-player/v/3.0.0-canary.1
https://codesandbox.io/p/devbox/react-player-vite-6n78q7
note that this version has only ESM builds for now, testing if CJS or IIFE is actually still needed


Tab with icon instead of text and... Navigation drawer please!

Is it possible? since im still brand new with react native.

#38


docs: Add info about client side certificate rotation best practices.

Hi and Happy New Year All!
Thanks for great product. We use it on production for long time, but we want to focus to improve automation and avoid manual intervention during certificate renewal for our services. How to ensure Pod's server will actually reload certificate? Particuraly:

Certificate is close to expiry time.
Cert-manager renews and updates Kubernetes secret.
Kubernetes refresh Secret in desired pods, but they are still using the old certificate.

It's definitely not cert-manager issue, but it would be nice for cert-manager to incldue potential solutions to this problem as best practices.
There are multiple options like:
A) Ensure application can reload it "hitless"/non-distruptive. E.g you can implement that for Golang HTTP server, or hope that your service you use allows that (mostly they don't). For example envoy recently added that option: https://github.com/envoyproxy/envoy/issues/1194
B) Some generic cert-rotate operator that will rolling restart stateless deployments to load new certificates? Maybe logic like this in cert-manager makes sense?
C) Have your rollout tools handle that? (ensure pods are restarted frequently)
What is common way of solving this problem? I guess A for less distruptive rotation possible, but what if it's 3rd party tool that does not support hot reload? I have searched gh issues, but haven't found relevant response.
Do you agree that some docs for best practices for this would be suitable in cert-manager documention?
Environment details (if applicable):

Kubernetes version (e.g. v1.10.2): v1.9+
Cloud-provider/provisioner (e.g. GKE, kops AWS, etc): GKE

/kind feature

This is one of those subtle issues that isn't apparent from reading the intro docs, and will cause a full outage when it bites you. I think it's worth at least calling out as a "here be dragons" kind of message; whatever your chosen solution, if you haven't picked one, then you are probably going to have an outage at some point (usually coinciding with when your team is all on vacation, since that's when the code/deploy velocity will have dropped off).
(Not being overly-specific because this is exactly what happened to me or anything like that...) :)

I don't get @paultiplady what is the actual outcome of your comment (: Are you just ranting about fact that nothing works for 100%? Sure but can we focus on fixing this issue, to recommend or explain solution that will be closer to 100% than others?

I'm adding a user use-case emphasizing that this is important to document, as it produces outages if it's not handled.

So I just found this https://github.com/pusher/wave. It will watch for changes on configmaps and secrets for deployments and perform a rolling deploy when they get updated. So to go off of the example from the initial issue the following would happen:

Create a Certificate
Create a deployment with the wave annotation and use the certificate's secret in the deployment
Cert-manager renews and updates Kubernetes secret
Wave sees that the secret was update and performs a rolling deployment.

Nice, if that is production rdy then it looks really promising!

Currently have to implement a solution for this as well and saw the recommendation for Wave above. I also ran into https://github.com/stakater/Reloader which does the same things but has more stars and looks easier to install.

/reopen
/remove-lifecycle rotten
/lifecycle frozen


[Model Update]: SerialPart fix key exampleValue

Update Reason
Example value of property key has a mistake in camel casing resulting in wrong JSON example.
Currently: PartInstanceId --> should be: partInstanceId
MS1 Criteria

[ ] The model that should be updated exists
[ ] The referenced use case exists
[ ] The potential updates are discussed with all stakeholders
[ ] A decision on versioning was made in consensus with the affected parties according to the guidelines.
[ ] The potential update will be either

[ ] backward compatible or
[ ] a (chain of) migration strategy(-ies) from all non-deprecated previous versions to the new model will be developed

Modeling_Team

small fix in line
https://github.com/eclipse-tractusx/sldt-semantic-models/blob/57c33e4a51ad808be8ff58456838256a6d895373/io.catenax.serial_part/1.0.0/SerialPart.ttl#L114
patch release as it fixes example value -> 1.0.1


Remove ref from git cache path

When using bundle cache --all with git dependencies, bundler includes the ref as part of the path in vendor/cache. When bundle update is run, the old cache is removed and the new cache is added, making diffs very noisy. This is a proposal to remove the ref from the path and store it in .bundlercache.
This is potentially a breaking change, so it might be best to put it behind a config option.

This seems like a lot of overhead, including a magic file that could easily be deleted without deleting the files themselves, for a very edge case. Can you tell me why you feel like this is a good idea?

Can you tell me why you feel like this is a good idea?

We quit using cache --all at GitHub because every time we updated a dependency the diff would be unreadable. With this change, the diff clearly shows what changed in the dependency, which makes it extremely convenient to do reviews.

So, two things: first, why are you caching git repos? Do your dependencies have really high churn that means you're not able to release them as gems with versions? Second, if you're going to cache your dependencies in your repos, we strongly recommend using a submodule, so that the primary repo isn't bloated by the .gem files or the dependency files themselves. As an example, you can check out how RubyGems.org uses a submodule for that.

first, why are you caching git repos?

Because we need to be able to deploy GitHub if GitHub is down, so we have all our external dependencies vendored. Other people should really be doing this as well. Having deploy dependencies on external services is not a good idea for any service.

Do your dependencies have really high churn that means you're not able to release them as gems with versions?

Yes, two frequent use cases:

a new feature that is in heavy development
using a fork of a repository that we don't manage releases for, which we do often.

Second, if you're going to cache your dependencies in your repos, we strongly recommend using a submodule…

Same reason as the first question. We need to be able to deploy without any external dependencies.

…so that the primary repo isn't bloated by the .gem files or the dependency files themselves.

cache --all with git repos doesn't include the .gem files, which is one of the reasons I think it would be really nice if we could just use :git dependencies in bundler.
Maybe it would make sense to deprecate support for caching Git repos with cache --all if use of this feature is discouraged?

we have all our external dependencies vendored. Other people should really be doing this as well

Your assertion that GitHub's decisions about how to handle tradeoffs are the Only Possible One True Way™ makes me really unhappy. What makes sense for GitHub may or may not make sense for other people who have different needs, and you don't know what their needs are. Please don't do that, it's patronizing and can be very misleading.

Maybe it would make sense to deprecate support for caching Git repos with cache --all if use of this feature is discouraged?

Since I haven't said anything to discourage use of this feature, in this ticket or anywhere else, this comes across as both passive-aggressive and smarmy. No, we're not going to deprecate a perfectly good feature that people already use and are happy with because it doesn't meet your precise needs.
To the actual point:
I don't think it makes sense to sit here and argue back and forth about the relative merits of all the possible options, so I'm just going to summarize the current results of the core team's discussions about this.
As for this particular pull request, using a dotfile to effectively re-implement git submodules is not a sufficiently robust solution for the core team to be comfortable agreeing to merge it and support it for the next five years or more.
In general, we'd like to come up with a good solution for deploying without external service dependencies that is both robust and flexible enough to satisfy the needs of people using both regular gems and git gems. The best results that I've heard so far about have used regular gems over git gems whenever possible, and involved either a repo or a build artifact that corresponded to each commit in the main repo rather than full-on vendoring everything directly.

I have a lot of respect for bundler and specifically your work on it, so sorry that I have offended you.

Your assertion that GitHub's decisions about how to handle tradeoffs are the Only Possible One True Way™ makes me really unhappy.

Sorry, you are right. I re-read what I wrote and it did come off as rather prescriptive. In my experience, it's really painful when you need to deploy and an external service is unavailable.

As for this particular pull request, using a dotfile to effectively re-implement git submodules…

I'm curious how this is different than the current approach of using the directory name. This proposal just moves it from the directory name to the existing .bundlecache . It doesn't change the functionality of the feature.

No, we're not going to deprecate a perfectly good feature that people already use and are happy with because it doesn't meet your precise needs.

There are 1.7 million Gemfiles in public repositories on GitHub, and almost 1/3 of them have a git or github dependency. There are 191,000 repos that have vendor/cache/rack-1.6.0.gem (the latest release of the most popular gem), but only 183 .bundlecache files in public repositories on GitHub, which is present when a git dependency is cached.
This suggests to me that people care about vendoring their gem dependencies, but don't vendor git dependencies for one reason or another. This could just be because they don't know about the --all flag. In my experience, it's because updating the git dependency makes the diff on updates unnecessarily noisy.
I think bundler's caching is a great feature and want to make it so GitHub is not a single point of failure for everyone deploying ruby applications.

This proposal just moves it from the directory name to the existing .bundlecache. It doesn't change the functionality of the feature.

This is a really good point. I went back and looked at your pull request again, and it's much simpler than I thought it was while writing my last response—I think I was confusing this pull request with another PR to do the same thing with a much more complicated implementation. Regardless of how it happened, I was judging your PR much more harshly than it actually deserves, and I'm sorry about that.

This suggests to me that people care about vendoring their gem dependencies, but don't vendor git dependencies for one reason or another.

Yeah, that seems true. The reason that --all isn't the default is because we were trying to maintain backwards compatibility with 1.x releases. Bundler 2.0 will remove the --all option and simply do that all the time.
I think I'm now convinced that this PR is an overall improvement. Assuming that I go back to the core team and they agree with me, there are some new concerns about merging this. :) The first issue is that this change completely breaks compatibility—previously cached git gems will no longer work, and git gems cached in the future will not be readable by older versions of Bundler. That makes this change a candidate for Bundler 2.0, but not possible to merge immediately.
Are you willing to implement code that reads existing caches and migrates old git gems to the new cache format? If so, we can possibly merge and release this in Bundler 1.10.

Regardless of how it happened, I was judging your PR much more harshly than it actually deserves, and I'm sorry about that.

:beers: No problem, I wasn't communicating very effectively either.

Are you willing to implement code that reads existing caches and migrates old git gems to the new cache format?

:+1:, but this could be tricky. If I'm running 1.10.x and migrate to the new cache format, but my co-workers are running 1.9.2, then they won't get the cache.
How do you typically handle changes like this? Is it ok to assume that everyone on the project is using a compatible bundler version, or would it make more sense to put this behind a config that is disabled by default for 1.x?

We've just merged a PR that tracks the current Bundler version in the lockfile, so this will get easier in the future (since it will print a warning that you're out of date when you bundle).
With cache migration this change will only break forwards compatibility, so maybe we can just add a warning to Bundler 1.9.3 that explains that the cache format requires 1.10 or newer?

:heart: just dropping this here, because I love open source and bundler :smile_cat: (good job communicating back-and-forth both of you)


Not able to configure transparent gateway

I configured a transparent edge gateway (Eflow with Edge 1.1 LTS on Windows 11). The initial installation and configuration of Edge Gateway (SAS or self-signed X.509 device identity cert) worked well, gateway successfully connects to IoT Hub.
When I am trying to configure the (self-signed) root CA and edge CA certificate and the key needed for transparent gateway setup by manually editing the certificates section of the YAML file the daemon mgmt endpoint stopped working after restart.
iotedge check shows the following error:
× config.yaml has correct URIs for daemon mgmt endpoint - Error
    SocketError - SocketErrorCode (ConnectionRefused) : Connection refused /var/lib/iotedge/mgmt.sock
    One or more errors occurred. (Got bad response: )
        caused by: docker returned exit code: 1, stderr = SocketError - SocketErrorCode (ConnectionRefused) : Connection refused /var/lib/iotedge/mgmt.sock
                   One or more errors occurred. (Got bad response: )

As soon as I remove the certificates section from the YAML file everything is working fine again.

The files (certificates and keys) copied using the Copy-EflowVmFile command sets the owning user and group to user 'iotedge-user'. However the iotedge security domain is accessing the files using the user 'iotedge' and is therefore not able to access the files.
By running sudo chown iotedge:iotedge /home/iotedge-user/certs/<filename>.pem for Root CA, Device CA and Device PK files the daemon is able to start successfully.
Device identity certificates and key (X509 self-signed device identity certs) configured through the Provision-EflowVm -provisioningType ManualX509 ... command are automatically set to the correct user ('iotedge').

Hi @mpoeckl.
Thanks for your detailed information.  I'm glad to hear you were able to fix your issue. By default, the Copy-EflowVmFile will always set the ownership of the copied files/folders to iotedge-user.
We have some sample PS functions for Get/Set IoT Edge certificates: EFLOW-Util.
Thanks,
Francisco

Hi @fcabrera23 ,
It would be great to add a link to these additional PS scripts to the official MS docs site for Eflow PS commands: https://docs.microsoft.com/en-us/azure/iot-edge/reference-iot-edge-for-linux-on-windows-functions?view=iotedge-2018-06. That would help to avoid misconfiguration of the YAML file and and ownership/access related issues.


Pasting + Enter race condition

When I paste and press enter in succession really fast, the command executed is the one as if I haven't pasted.
For example if I have typed this in my shell
$ git show

then i paste a sha (say 398c4ca) with cmd+v and press enter really quicky, the command that actually gets ran is just git show and not git show 398c4ca.
This does not happen on iTerm2.

I'm also experiencing this. Is there an easy way to ensure a paste is completed before the return keypress is handled?

I'm also experiencing it 😕

Can't reproduce.
If I press enter really quickly after a paste, it is discarded.
Feel free to reopen

discarded?
anyway just tested and this seems to have been fixed

Yes: I tried and Enter key is ignored if it is pressed to quickly after a paste.


Miningpool module

@lukechampine @alexfreska @eddiewang @ChrisSchinnerl @Didrole hey folks, any miningpool module for sia? There used to be toastpool repo that would work with mining pool but that's outdated already. Any clue where I can get siad working with p flag?

Hi there. I spent some time trying to bring the toastpool repo up to date, but unfortunately they made a number of changes to the core packages, so the code has diverged a lot and the merge is horrendous; it would take quite a long time just to get it compiling again, let alone working properly. :/
Perhaps someday we can dedicate Foundation resources towards developing an official mining pool implementation. In the meantime, the only advice I can give is to ask around in the Sia Discord. There might be someone there who can point you towards an actively-maintained implementation.

@lukechampine thanks man for the response.

How one can solo mining directly with the node?
What's sia's discord link?

For solo mining, you can use the /miner API endpoints: https://api.sia.tech/#miner-header-get
Our Discord is https://discord.gg/sia. I recommend asking around in the #mining channel. 👍🏻

How to  structure a trascation and send it  to chain ? is there a rpc ?  i use the post request "/tpool/raw" but i get the err: 400 bad request,


Client assertion should be recreated if authority is overridden on API level

Client assertion is initialized when client application object is created.
if Authority is overridden client assertion created during client application initialization should not be used,
instead new one should be created and used for this particular API call.

Assertions should never be cached, as we cache the tokens.


Improve Result-chaining documentation

This PR updates the documentation to clarify how to chain functions that return a Result.

Added a note about the upcoming syntax sugar for that (i.e., the ? operator) in the roc-for-elm-programmers.md page, at the start of the backpassing section (since backpassing will be replaced, IIUC). The note links to #6828.
Added a Result-chaining example in the tutorial, as well as a note that some syntax sugar for this is coming.

@ageron could you sign your commit please? The CONTRIBUTING.md doc tells us how to do that for existing commits.

Sure, will do that. 👍


Reference to Easter Island in section 3. Execution is racist and contradicts the name 'DemocracyEarth'

In the Pacific, Easter Island, more authentically known as Rapanui, is not a far away land. Of course colloquially it might be nicknamed a "far away land" due to its other name Te Pito o Te Henua which more or less translates to "The End of The Earth", however today such statements are false and no longer true.
Internet media is omnipresent to every place on Earth and viewers of this GitHub account that reside on Rapanui have direct and immediate access to this living document at the instant that it is updated, and are therefore not "far away". Rapanui is not an exotic fairyland idea to be bandied about by the whims of people that have most probably never had any true connection to the place. It is a real place with real human beings with living history that are working right now every day to live real lives.

I strongly agree with @willscire and attempted to fix this with #383.


[sql_lab]Create export functionality for saved queries

Is your feature request related to a problem? Please describe.
We have the backend api for saved queries, and would like to add a button next to each query in the list so that the user can export their saved queries and download a zip file that can be imported later.
Describe the solution you'd like
Add an export button on the saved queries page with a tooltip, similar to the charts list page:

charts example

current saved queries page
Additional context
The api exists at api/v1/saved_query/export/

I have someone to work on this.

I have someone to work on this.

@lyndsiWilliams there's a feature flag for the imports and exports called VERSIONED_EXPORT that you'll need to set to True to see the exports for dashboards, charts, datasets, and databases


[BUG] flagd (transposeEvaluators fn) doesn't understand json without indentations

Observed behavior
transposeEvaluators doesn't behave correctly if the json passed to it doesn't have the right indentation.
Expected Behavior
transposeEvaluators should handle cases where the json passed to it doesn't have the right indentation.
Steps to reproduce

Check out this PR's branch
Put fmt.Println statements just after this line and after this line.
Use json.Marshal instead of json.MarshalIndent here
From flagd root directory run (example_flags.yaml can be found here):

go run main.go  start -f file:./config/samples/example_flags.yaml -e=yaml
{"level":"info","ts":1672807996.7619019,"caller":"service/connect_service.go:108","msg":"metrics listening at 8014","component":"service"}
evalValue before {"in":["@faas.com",{"var":["email"]}]}
evalValue after "in":["@faas.com",{"var":["email"]}
{"level":"fatal","ts":1672807996.762957,"caller":"cmd/start.go:116","msg":"set state: unmarshal new state: invalid character '}' after array element","component":"start","stacktrace":"github.com/open-feature/flagd/cmd.glob..func1\n\t/home/suraj/sandbox/flagd/cmd/start.go:116\ngithub.com/spf13/cobra.(*Command).execute\n\t/home/suraj/go/pkg/mod/github.com/spf13/cobra@v1.4.0/command.go:860\ngithub.com/spf13/cobra.(*Command).ExecuteC\n\t/home/suraj/go/pkg/mod/github.com/spf13/cobra@v1.4.0/command.go:974\ngithub.com/spf13/cobra.(*Command).Execute\n\t/home/suraj/go/pkg/mod/github.com/spf13/cobra@v1.4.0/command.go:902\ngithub.com/open-feature/flagd/cmd.Execute\n\t/home/suraj/sandbox/flagd/cmd/root.go:38\nmain.main\n\t/home/suraj/sandbox/flagd/main.go:30\nruntime.main\n\t/usr/local/go/src/runtime/proc.go:250"}
exit status 1

If you check the above log,
evalValue before {"in":["@faas.com",{"var":["email"]}]}
evalValue after "in":["@faas.com",{"var":["email"]}

Because the trailing brackets are not on newline, flagd trims the last two trailing brackets which makes the json invalid. This problem doesn't happen if you use json.MarshalIndent like this
To contrast this with using a json config file,
{"level":"info","ts":1672808353.423182,"caller":"service/connect_service.go:108","msg":"metrics listening at 8014","component":"service"}
evalValue before {
          "in"<EMAIL_ADDRESS>{
            "var": ["email"]
          }]
    }
evalValue after
          "in"<EMAIL_ADDRESS>{
            "var": ["email"]
          }]

{"level":"info","ts":1672808353.4240851,"caller":"runtime/runtime.go:84","msg":"configuration change (write) for flagKey myBoolFlag (./config/samples/example_flags.json)","component":"runtime"}
...

There is no error. Looking at the log above,
evalValue before {
          "in"<EMAIL_ADDRESS>{
            "var": ["email"]
          }]
    }
evalValue after
          "in"<EMAIL_ADDRESS>{
            "var": ["email"]
          }]

Notice how only the trailing bracket on newline is removed (with the opening bracket on the first line). This works as expected.

I am not sure if we want to fix this now or even fix this at all because we ran into this issue when we tried converting yaml to json (we might not have to do this anytime soon in the future) and we have a way to work around the issue using json.MarshalIndent instead of json.Marshal. I have created this issue for future reference in case anyone runs into a similar issue in the future.


Fix concatenation of FilePath for concurrent "."

Fixes #1003
Change

Disallow duplicate "." when concatenating paths use the "/" operator.
This means that we no longer have a  mismatch between "./" and "././" as they are both the same paths
but just happen to hold different path strings. New test added for this.

CI (Windows 2022 run)
- Set up CMS ...
- Set up Units ...
- Shader output path: D:\a\MaterialX\MaterialX\resources\Materials\Examples\StandardSurface
-- Generate code for node: SR_marble1
--- Wrote pixel shader to: D:\a\MaterialX\MaterialX\resources\Materials\Examples\StandardSurfaceSR_marble1.glsl.frag
----- Run: glslangValidator.exe D:\a\MaterialX\MaterialX\resources\Materials\Examples\StandardSurfaceSR_marble1.glsl.frag -V --aml
--- Wrote vertex shader to: D:\a\MaterialX\MaterialX\resources\Materials\Examples\StandardSurfaceSR_marble1.glsl.vert
----- Run: glslangValidator.exe D:\a\MaterialX\MaterialX\resources\Materials\Examples\StandardSurfaceSR_marble1.glsl.vert -V --aml
Validation passed for shader:  SR_marble1
- Set up CMS ...
- Set up Units ...
- Shader output path: D:\a\MaterialX\MaterialX\resources\Materials\Examples\StandardSurface
-- Generate code for node: SR_marble1
--- Wrote pixel shader to: D:\a\MaterialX\MaterialX\resources\Materials\Examples\StandardSurfaceSR_marble1.essl.frag
----- Run: glslangValidator.exe D:\a\MaterialX\MaterialX\resources\Materials\Examples\StandardSurfaceSR_marble1.essl.frag
--- Wrote vertex shader to: D:\a\MaterialX\MaterialX\resources\Materials\Examples\StandardSurfaceSR_marble1.essl.vert
----- Run: glslangValidator.exe D:\a\MaterialX\MaterialX\resources\Materials\Examples\StandardSurfaceSR_marble1.essl.vert
Validation passed for shader:  SR_marble1

@kwokcb Thanks for this changelist, and it's definitely a step in the right direction.
Instead of modifying the rules for FilePath concatenation, though, I would recommend that we create an initial FilePath::normalize method that merges all sequential . paths, and we can then call this method in the context of deduplicating shader includes.  This would make for a better separation between FilePath concatenation (which a user wouldn't expect to apply contextual rules to the original path), and FilePath normalization, which is expected to understand and apply those rules on demand.
This FilePath::normalize method could then be extended over time to handle common cases such as .. parent paths, with the same understanding that the user needs to invoke this method when they want contextual rules to be applied.

@kwokcb Thanks for this changelist, and it's definitely a step in the right direction.
Instead of modifying the rules for FilePath concatenation, though, I would recommend that we create an initial FilePath::normalize method that merges all sequential . paths, and we can then call this method in the context of deduplicating shader includes. This would make for a better separation between FilePath concatenation (which a user wouldn't expect to apply contextual rules to the original path), and FilePath normalization, which is expected to understand and apply those rules on demand.
This FilePath::normalize method could then be extended over time to handle common cases such as .. parent paths, with the same understanding that the user needs to invoke this method when they want contextual rules to be applied.

@jstone-lucasfilm,
I was wondering which approach you'd prefer. Let's go with this. I'm wondering if "resolve" would be a be better
interface name, or "flatten". I think these match other places where path resolution is handled ?
Also for the method, I assume it can follow the same signature of returning a new FilePath instead of working in-place.

Reading through canonical, and normpath (from Python)
I think normalize() is a good fit for what it does. When absolute path conversion is supported then canonical could be normalize + absolute path conversion.


test(dm): add a test to make sure there's no problem :P

Signed-off-by: lance6716<EMAIL_ADDRESS>
What problem does this PR solve?

Issue Number: ref #7493
What is changed and how it works?
simply add a test, no code change
Check List
Tests

Unit test

Questions
Will it cause performance regression or break compatibility?
Do you need to update user documentation, design documentation or monitoring documentation?
Release note
`None`.

Codecov Report

Merging #7495 (e1329a5) into master (6b48846) will decrease coverage by 6.1265%.
The diff coverage is 65.7142%.

Additional details and impacted files

Flag
Coverage Δ

dm
51.9783% <50.0000%> (?)

engine
61.1692% <66.6666%> (-0.0146%)
:arrow_down:

Flags with carried forward coverage won't be shown. Click here to find out more.
@@               Coverage Diff                @@
##             master      #7495        +/-   ##
================================================
- Coverage   65.9877%   59.8611%   -6.1266%
================================================
  Files           564        803       +239
  Lines         52337      92337     +40000
================================================
+ Hits          34536      55274     +20738
- Misses        15129      32249     +17120
- Partials       2672       4814      +2142

/merge

/run-engine-integration-test


🔨 relax commit convention restrictions

Current dependencies on/for this PR:

main

PR #19   👈

This comment was auto-generated by Graphite.


oushadhavana-base Setup the base structure for oushadhavana page with separate data and script files

Go to http://[root]/oushadhavana
data.js is the data file
Each plant page show some dummy data like a, b and c for now

This PR is to a different branch from main branch as we don't want this to be deployed before completion.


Proxy For IOT Stack Edge Device

Hi,
Following this link:
https://docs.microsoft.com/en-us/azure/iot-edge/how-to-configure-proxy-support?view=iotedge-2018-06
We have an IOT Stack Edge device that we have procured. We intent to set this up but being in a secure network it will need to use a proxy. We follow the documentation above to setup this, but the documentation doesnt throw much details on what kind of proxy we are talking about and anything that is recommended . Believe this is a Web HTTP Forward Proxy, and do you have any recommendations as well as any guidelines when we set this up? Any additional inputs will be great for us to setup this device and connect to IOT Hub.
Thanks,
Praveen

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

ID: 69c0d8c2-ea63-1b11-d855-bc1f6108cf62
Version Independent ID: 7c2c7ceb-ed80-f507-0c63-280720e9768d
Content: Configure devices for network proxies - Azure IoT Edge
Content Source: articles/iot-edge/how-to-configure-proxy-support.md
Service: iot-edge
GitHub Login: @kgremban
Microsoft Alias: kgremban

@ramakrpr Thanks for the feedback! We are currently investigating and will update you shortly.

@ramakrpr Thanks for the feedback! We are currently investigating and will update you shortly.

Hello @ramakrpr Thanks for the query, may we know what kind of IoT Edge device/Make/Model you are using here? I believe you are not looking for any reverse proxy over here and the only intent is a forward proxy[in generally called proxy], right? Please comment in the below section...

Hello @ramakrpr Thanks for the query, may we know what kind of IoT Edge device/Make/Model you are using here? I believe you are not looking for any reverse proxy over here and the only intent is a forward proxy[in generally called proxy], right? Please comment in the below section...

@SatishBoddu-MSFT
we have procured Azure Stack Edge Pro - 2 GPU
I believe it should be forward proxy, to help the device connect via proxy to the internet. Any recommended proxies with which this has been tested will suffice for us, for example Apache?

@SatishBoddu-MSFT
we have procured Azure Stack Edge Pro - 2 GPU
I believe it should be forward proxy, to help the device connect via proxy to the internet. Any recommended proxies with which this has been tested will suffice for us, for example Apache?

Hello @ramakrpr Thanks for the additional info.
Let me check on this.

Hello @ramakrpr Thanks for the additional info.
Let me check on this.

Hello @ramakrpr
We want to be sure we can help you in the proper place and leverage the community as well. For that reason, I kindly ask that you post your question in Microsoft Q&A. Please use a tag.
We will now proceed to close this thread. If there are further questions regarding this matter, please tag me in your reply. We will gladly continue the discussion and will reopen the issue.
Thank you so much!
Please let us know if you need further help in this matter or if we are good to close this issue.

Hello @ramakrpr
We want to be sure we can help you in the proper place and leverage the community as well. For that reason, I kindly ask that you post your question in Microsoft Q&A. Please use a tag.
We will now proceed to close this thread. If there are further questions regarding this matter, please tag me in your reply. We will gladly continue the discussion and will reopen the issue.
Thank you so much!
Please let us know if you need further help in this matter or if we are good to close this issue.

Hi @ramakrpr we are checking with our team, please ignore the previous comment [as of now] and stay tuned for further updates. Reason: It is too early to redirect this query. We are exploring a better way to help Azure Stack Hub Customers.

Hi @ramakrpr we are checking with our team, please ignore the previous comment [as of now] and stay tuned for further updates. Reason: It is too early to redirect this query. We are exploring a better way to help Azure Stack Hub Customers.

Hello @ramakrpr  information about web proxy configuration: https://docs.microsoft.com/en-us/azure/databox-online/azure-stack-edge-gpu-deploy-configure-network-compute-web-proxy#configure-web-proxy, which may be helpful. Please let us know if you need further help in this matter.

Hello @ramakrpr  information about web proxy configuration: https://docs.microsoft.com/en-us/azure/databox-online/azure-stack-edge-gpu-deploy-configure-network-compute-web-proxy#configure-web-proxy, which may be helpful. Please let us know if you need further help in this matter.

Hello @ramakrpr Just checking back on this, please let us know if you need further help in this matter.

Hello @ramakrpr Just checking back on this, please let us know if you need further help in this matter.

Hello @ramakrpr
We will now proceed to close this thread. If there are further questions regarding this matter, please tag me in your reply. We will gladly continue the discussion and we will reopen the issue.
Please also do visit Microsoft Q&A the home for technical questions and answers at Microsoft.


DBZ-4107 Incremental snapshot doesn't work without primary key

fix parse charset "gb18030" issue

close this pr for mismatch commit message


Unable to run docker image

On running the docker command I am getting
sh: 1: modprobe: not found
Unable to find kernel headers. Try rebuilding kernel with CONFIG_IKHEADERS=m (module)
chdir(/lib/modules/4.14.138-89.102.amzn1.x86_64/build): No such file or directory
Traceback (most recent call last):
  File "/usr/bin/http-statistics.py", line 294, in <module>
    kernel_inspector = KernelInspector()
  File "/usr/bin/http-statistics.py", line 57, in __init__
    self.bpf = bcc.BPF(EBPF_PROGRAM)
  File "/usr/lib/python2.7/dist-packages/bcc/__init__.py", line 343, in __init__
    raise Exception("Failed to compile BPF module %s" % (src_file or "<text>"))
Exception: Failed to compile BPF module /usr/bin/ebpf-http-statistics.c

Please see the note at the top of the README:

Note: This plugin needs a recent kernel version with eBPF support. It will not compile on current dlite and boot2docker hosts. You need /sys/kernel/debug/ in order to be able to build the eBPF program generated by the plugin.


Add whitenoise for heroku static files

Instructions:
https://github.com/codingforentrepreneurs/Guides/blob/master/all/Heroku_Django_Deployment_Guide.md

Hello @mariamera
Is this already handle?

@oscarpolanco Hey Oscar, they are on the settings file as well as the Procfile for heroku.


Proxy addon issue - when trying to open frigate menu you get 404

I am running frigate 14.0-beta1 via docker-compose.
On a separate container I am running home assistant with frigate proxy addon - version 1.5.
when trying to open frigate from the homeassistant side menu on the left I get frigate new UI loaded but showing 404 error:

If I try to navigate by using new frigate menu all works fine and I can access all the functions. it is just when you navigate between home assistant menus it opens this page with 404 initially.
browser hard reload and empty cache cleanup done, home assistant restarted after installation of beta version.
nginx: log entries when navigating:

proxy addon config:
server: http://<IP_ADDRESS>:5000
proxy_pass_host: true
proxy_pass_real_ip: true

p.s. new version is really amazing I am thriled how nice that is!!!!!!!!!!!!!!!!!!!!!!!!! super amazing job guys!!

Same here. Wait for fix

Confirm with 14.beta2 fixed.


fix: exclude acorn.js from node bundle

Description
I found vite has bundled both acorn.mjs and acorn.js.
Plugins use it as fallback when parser instance is not passed.
du -ck dist/node
before: 12260 kB
after: 11612 kB
Additional context

What is the purpose of this pull request?

[x] Bug fix
[ ] New Feature
[ ] Documentation update
[ ] Other

Before submitting the PR, please make sure you do the following

[ ] Read the Contributing Guidelines.
[ ] Read the Pull Request Guidelines and follow the Commit Convention.
[ ] Check that there isn't already a PR that solves the problem the same way to avoid creating a duplicate.
[ ] Provide a description in this PR that addresses what the PR is solving, or reference the issue that it solves (e.g. fixes #123).
[ ] Ideally, include relevant tests that fail without this PR but pass with it.

Hmm, this would require acorn to be present as a peer dep for Vite and will fail if using strict package managers like pnpm.

@yyx990803 Not really. See https://github.com/acornjs/acorn-class-fields/blob/master/index.js#L6
Acorn already passes own instance when invoking plugins. We don't need to resolve import in plugins.
https://github.com/acornjs/acorn/blob/master/acorn/src/index.js#L56

Ah I see. So the runtime require() actually never gets called. Makes sense 👍

Let's merge this one once we start the 2.8 beta period


Changing Calendar ID doesn't kill old update timer.

After changing calendarID, keeps re-writing old events (probably pulling from the old JSON file in memory the old "timer" ?).
Need to add clearInterval. More likely an indicator that everything really needs to be moved to an SQL database.

this should have been fixed as part of the fallout of #109

this should have been fixed as part of the fallout of #109


Changes to enable SSL/TLS connections and authentication options

Added options --auth_user, --auth_password for authentication so that we can pass username/password to Cassandra
Added options --enableSSL, --ssl_truststore, ssl_truststorepassword so that we can pass JKS store and it's password to enable SSL/TLS connections to Cassandra

I'd find this feature useful; while testing a newly provisioned cluster I needed to pass auth user and password, but couldn't do so without checking out this PR and building against that. Just sharing a usecase 👍

Is there a way to connect to universes through basic auth?


NEXT: Introduce the skeleton-a11y package

Goal
After reviewing with @Hugos68 we've decided it may be beneficial to create framework agnostic tooling for component a11y. This will provide a shared and reusable centralized package and allow us to cover use cases such as:

Common keyboard interactions (ex: up/down, home/end)
As well as give us a way to inject common ARIA APG attribute patterns

It will be loosely modeled after Zag, but likely much more limited in scope and purpose built for our needs.
Package
This should be introduced as a new monorepo workspace:
/packages/skeleton-a11y

Within the package we can subdivide by:

interactions - keyboard interactions or anything related to event listeners
aria - ARIA attributes or anything related to templates

This component will only be promoted in-house for now, but we may open it to the public in the future.
Updating Components
Once in place, we should begin retrofitting our existing components to utilize these new tools. We can utilize the Accordion as our initial test case. Then bring this to Listbox, Tabs, etc
See Also

https://www.w3.org/WAI/ARIA/apg/patterns/
https://zagjs.com/

We just ended up implementing Zag directly :)


DETECT US_DRIVERS_LICENSE

Description
A US_DRIVERS_LICENSE is an important PII type. A US driver's license is an official document issued by a state’s Department of Motor Vehicles (DMV) or an equivalent agency, granting permission to an individual to operate a motor vehicle. It serves as one of the most widely accepted forms of identification in the United States. Detecting and protecting US driver's license information is critical due to the sensitive nature of the data it contains.
Detection Steps

Pattern Matching
Keyword and Contextual Analysis
Optical Character Recognition (OCR) for Images
Data Fingerprinting
Cross-Reference with State-Specific Databases
Data Loss Prevention (DLP) Rules

@cgboyce this assignment will be mostly text based so (3) will be out of scope but is a good idea.  Not sure what you were intending by (4) and (6) and we won't have access to (5) - Nice ideas just beyond scope of this assignment


Implement NodePathValidTypes typehint annotation

Annotation already existing in: PropertyTypeHintAnnotation.kt (already there, needs to be uncommented.
Add typehint and typelimiting support in PropertyHintTypeMapper.kt

Closing in favor of #155


Support scope in admin-generator

this is probably not needed and only a temporary backup as existing project-code requires this. project can't be refactored until beginning of april.

@Ben-Ho should we really review and merge this? Or is this only here for you to use in your project until you've got time to refactor?

@Ben-Ho should we really review and merge this? Or is this only here for you to use in your project until you've got time to refactor?

currently I think I'll close this pull-request later on.


No bug, just happy my old favorite clock app is coming back

Keep up the good work

Thank you a ton for your kind words. I am happy to work on your favorite clock app.


rPackages.reticulate: fallback to python3 from nixpkgs

Motivation for this change
Reticulate sources it's python from the PATH, falling back to a set of
default search locations. This patch changes one of the search locations
to python3 from nixpkgs, guaranteeing that a suitable python will be
found. It also allows overriding to point to specific python wrappers,
e.g.,:
  rPackages.reticulate.overrideAttrs (_: {
    python = python3.withPackages (ps: [numpy]);
  })

@bcdarwin I'm not sure this is better than #244576.
@b-rodrigues fyi
Things done

Built on platform(s)

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

[ ] For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
[ ] Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
[ ] Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
[x] Tested execution of all binary files (usually in ./result/bin/)
21.11 Release Notes (or backporting 21.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.

I think this approach is overall right, but I wonder if defaulting to pkgs.python3 is useful or if it will ultimately lead to confusion via various no package named ... whereas no python found might be better.  Perhaps a null default might be better?
Also, your approach seems like it still allows dynamically overriding via RETICULATE_PYTHON, in which case this isn't incompatible at all with #244576.

I'm unsure what's the least surprising. At the moment, a nix-shell -p R rPackages.reticulate python3Packages.numpy works fine, with reticulate being able to find a python through the numpy in the environment, yet nix-shell -p R rPackages.reticulate fails to function at all as it can't find a python. If we fallback to a python as in this patch, then the latter also works with a plain python.
You're right, this is not incompatible with your patch.

reticulate does not source its python from PATH in general, the reticulate rendered docs appear to be out of date, but the python resolution notes here seem correct referred against the code: https://github.com/rstudio/reticulate/blob/main/vignettes/versions.Rmd
This patch will pick up the wrong python if the user has conda or virtual envs around (say from working on a shared system or simply having a directory named e.g. venv)
the RETICULATE_PYTHON env var is the highest priority specification location, setting it to an explicit binary would be useful. @kupac found precedent for setting this in the package's .onLoad function for sparklyr https://github.com/NixOS/nixpkgs/blob/master/pkgs/development/r-modules/default.nix#L1291-L1299, a similar approach could be done for reticulate.
Because of the automatic derivation generation used by r-modules/default.nix, there's no easy way to override the python version (or point to a python.withPackages as I would like to do). It would be nice if we used the sparklyr trick to set RETICULATE_PYTHON to ${python3}/bin/python so that we could
nix-shell -p 'rPackages.reticulate.override (_: {python3 = python.withPackages (ps: [ ps.numpy ]);})'

and get a nice controlled python environment by default

The motivation was to set a fallback not a default so that reticulate doesn't deviate too much from expected behaviour. If the environment is pure then by definition it is the only python picked up so it works as you wish. We seem to at least agree the interface is right, just need to discuss what priority is reasonable for the bundled python.
I note that with this patch since the python isn't forced, the following works nicely:
nix-shell -p R rPackages.reticulate python3Packages.numpy

Even if the environment is pure in the standard sense, if you start that nix shell in a directory that contains a conda or virtual environment (things that happen regularly especially to non-NixOS users) then you will get the wrong python using this approach. I tried to demonstrate the issue but the PR that introduced this landed July 25th, so it will be in the next version. https://github.com/rstudio/reticulate/commit/029aa2c430dcf5904a6ab4172277759dc7199dd6.
@Kupac's demonstration involved having previously used reticulate before nix in which case reticulate's created venvs take precedence over a python found on PATH. Again it can happen if you are either new to nix or work with others who don't use nix and periodically need to reproduce things their way. This could lead to counterintuitive behaviour.
Another thing to note is that this PR does not allow reticulate to find numpy. You can demonstrate using the current version of nixpkgs with:
nix-shell -p R rPackages.reticulate python3 #this equivalently puts python on the PATH
R
library(reticulate)
x <- matrix(1:5)
py_run_string("print(r.x)")

yields an error
Error: RuntimeError: Required version of NumPy not available: installation of Numpy >= 1.6 not found
Run `reticulate::py_last_error()` for details.

It looks like it all comes down to what is "expected behaviour". I understand there are two scenarios

I run something with Nix, and I would expect that it will not pick up pythons from any folder on my computer, but use a nix-wrapped python (optionally with some add-on packages)
You want to reproduce something that was done by a non-nix user (conda, venv, virtualenv, vanilla python, others?). In that case, you'd expect it to pick up a python from the system on which you run it.

Is this correct?  I know which one I'd expect, but most people may not agree.

Essenstially yes, there are users who only supply part of their software chain with nix and then rely on other tooling. To me it would be surprising if the working project directory had state that was not being reflected in my shell. I'm not a reticulate user though so I might have different expectations.

My two cents: in my opinion, I would say that a version of Python and packages provided through Nix should always take precedence over any other Pythons installed, as the default behaviour, regardless of where the Shell gets started. That is personally what I expect, and is likely the least surprising.
If I nix-build a shell and listed Python and Python packages, if I then run reticulate::py_config(), I would expect, 100% of the time, to see that version of Python and packages.
If a user, however, simply installs reticulate and no Python or Python packages, then previously-installed Pythons should get used, with the priority that reticulate usually uses.

Updated to force python if supplied, no fallback now.

Thanks @jbedo!
Where is $python coming from in the new version? I would have expected it would need to be an argument to mkDeriv for that to work? I was thinking we'd need something like
overrideAttrs (_: rec {python = pkgs.python3.withPackages (ps: [ps.numpy]); ... })

then users can overrideAttrs themselves to change the python, for example adding extra packages to the withPackages. If this doesn't work (because the recursiveness of the attrSet disappears by the time it gets to the user), I think your idea of a more significant refactor would be necessary.

Where is $python coming from in the new version? I would have expected it would need to be an argument to mkDeriv for that to work? I was thinking we'd need something like

Same as the original draft, e.g.,:

nixpkgs-reticulate on  reticulate [?]
❯ nix-shell --pure -p strace 'rWrapper.override {packages = with rPackages; [(reticulate.overrideAttrs (_: {python = python3.withPackages (ps: with ps; [numpy]);}))];}' --command 'echo "reticulate::py_config()" | R --vanilla'  -I nixpkgs=.

R version 4.3.1 (2023-06-16) -- "Beagle Scouts"
Copyright (C) 2023 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> reticulate::py_config()
python:         /nix/store/sqk3jv48is9979x4qdiily83xiirrpdw-python3-3.10.12-env/bin/python
libpython:      /nix/store/9c03r86hcdn43dm3hsgjirifvyzfkhwh-python3-3.10.12/lib/libpython3.10.so
pythonhome:     /nix/store/sqk3jv48is9979x4qdiily83xiirrpdw-python3-3.10.12-env:/nix/store/sqk3jv48is9979x4qdiily83xiirrpdw-python3-3.10.12-env
version:        3.10.12 (main, Jun  6 2023, 22:43:10) [GCC 12.3.0]
numpy:          /nix/store/sqk3jv48is9979x4qdiily83xiirrpdw-python3-3.10.12-env/lib/python3.10/site-packages/numpy
numpy_version:  1.24.2

NOTE: Python version was forced by RETICULATE_PYTHON
>

then users can overrideAttrs themselves to change the python, for example adding extra packages to the withPackages. If this doesn't work (because the recursiveness of the attrSet disappears by the time it gets to the user), I think your idea of a more significant refactor would be necessary.

It certainly doesn't compose, so it doesn't solve the problem of dependencies needing specific python packages availble. It also isn't a fallback now so it is also non-functional in the native state. I'm a bit dubious it's any better than expecting the user to manage RETICULATE_PYTHON.

Sounds like we got to a consensus in the end? Shall we or shall we not undraft this PR?

Hi all, how does this look like? are we good?

There are 195 reverse dependencies of reticulate on CRAN today (there are probably some more on Bioconductor).  Most of these wrap useful python libraries for R users. I'm thinking that this would warrant a new type of override in our beloved default.nix, where we could add py packages to a growing python environment, which would then be collected and linked to reticulate as described above.
You can check the rev deps like so:
(crandep::get_dep("reticulate", type = paste("Reverse", c("imports", "depends",  "linking to"), sep = " "), scrape = TRUE))


initial commit package skeleton

@aappling-usgs can you review and merge if appropriate?

Looks good. And we're off and running!


withStyle selected style is not applied

Material UI v4 - I am trying to set selected style like so:
const MyBottomNavigationAction = withStyles({
    root: {
        color: 'white'
    },
    selected: {
        color: 'black !important'
    }
})(BottomNavigationAction);

The problem is the specificity of the selected class that gets added to the BottomNavigationAction. The base Mui adds .MuiBottomNavigationAction-root.Mui-selected
and thus has higher specificity than the withStyles version.

My expectation is that I should be able to set selected and the styles that I am added would have greater specificity.
PS - I have confirmed that the withStyles

You need to use a selector with higher specificity e.g. https://codesandbox.io/s/9t45t https://material-ui.com/customization/components/#pseudo-classes


Clarity stops working when bootstrap is included

Select one ...  (check one with "x")
[x ] bug
[ ] feature request
[ ] enhancement

Using Clarity along with Bootstrap 4 is causing both the css frameworks to stop working.
I know it is not the best to use multiple css frameworks but was curious as to why it is not working.
https://plnkr.co/edit/2WDxlc?p=preview
Environment details

Angular version: 2..X

@learnuser521: I just switched the order in which bootstrap is loaded. I moved it to load before Clarity since Clarity depends on Bootstrap for a few things and it started to work.
https://plnkr.co/edit/v7KgOz?p=preview

Please note that we do not guarantee that things will work as expected because you are loading both the frameworks because there a lot of classnames which are similar in both of them.

@adityarb88  thanks for the quick reply.
Clarity is working but bootstrap is not https://plnkr.co/edit/lICBxTy77rgx0tPYrBxE?p=preview

@adityarb88 : Clarity does not work either. It worked for the modal but for the dropdown it is not - https://plnkr.co/edit/YSSSIGxYZf9xTOWmeKYg?p=preview

@learnuser521: We are not sure why bootstrap is not working. Your clarity dropdown on the other hand had the top-left direction and the screen was clipping off the menu. Updated plunker with a working solution:
https://plnkr.co/edit/CNIgfV5Vyyifr3UqwEXu?p=preview
Please refer to the layout and dropdown sections on our documentation for more information:
https://vmware.github.io/clarity/documentation/app-layout
https://vmware.github.io/clarity/documentation/dropdowns
Again, we don't recommend & wont be able to support requests for issues using both the frameworks together because of the number of conflicts you will face.

@adityarb88 : thanks again. That was a mistake from my side about the position. Should have noticed it, sorry, my bad.
I hear you, was just curious.