[SPARK-12981][SQL] Fix Python UDF extraction for aggregation.

When Aggregate operator being applied ExtractPythonUDFs rule, it becomes a Project. This change fixes that and maintain Aggregate operator to the original type.

Can one of the admins verify this patch?

@rxin Does this fix look good to you?

cc @davies

Using these two functionally equavalent code snippets:
Scala
val data = Seq((1, "1"), (2, "2"), (3, "2"), (1, "3")).toDF("a","b")
val my_filter = sqlContext.udf.register("my_filter", (a:Int) => a==1)
data.select(col("a")).distinct().filter(my_filter(col("a")))

Python
data = sqlContext.createDataFrame([(1, "1"), (2, "2"), (3, "2"), (1, "3")], ["a", "b"])
my_filter = udf(lambda a: a == 1, BooleanType())
data.select(col("a")).distinct().filter(my_filter(col("a")))

The logical plan comes out execute(aggregateCondition) in here is as below:
https://github.com/apache/spark/blob/916fc34f98dd731f607d9b3ed657bad6cc30df2c/sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/analysis/Analyzer.scala#L801
Scala
Aggregate [a#8], [UDF(a#8) AS havingCondition#11]
+- Project [a#8]
   +- Project [_1#6 AS a#8,_2#7 AS b#9]
      +- LocalRelation [_1#6,_2#7], [[1,1],[2,2],[3,2],[1,3]]

Python
Project [havingCondition#2]
+- Aggregate [a#0L], [pythonUDF#3 AS havingCondition#2]
   +- EvaluatePython PythonUDF#<lambda>(a#0L), pythonUDF#3: boolean
      +- Project [a#0L]
         +- LogicalRDD [a#0L,b#1], MapPartitionsRDD[4] at applySchemaToPythonRDD at NativeMethodAccessorImpl.java:-2

We can see in Python's case, we inject an extra Project when execute(aggregateCondition)going through ExtractPythonUDFs, but ResolveAggregateFunctions expects an Aggregate here:
https://github.com/apache/spark/blob/916fc34f98dd731f607d9b3ed657bad6cc30df2c/sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/analysis/Analyzer.scala#L801-L805
With this fix, the logical plan generated for Python UDFs does not construct a Project if it is an Aggregate, making it consistent with its Scala counterpart, which gives correct results for ResolveAggregateFunctions to consume:
After fix, Python:
Aggregate [a#0L], [pythonUDF#3 AS havingCondition#2]
+- EvaluatePython PythonUDF#<lambda>(a#0L), pythonUDF#3: boolean
   +- Project [a#0L]
      +- LogicalRDD [a#0L,b#1], MapPartitionsRDD[4] at applySchemaToPythonRDD at NativeMethodAccessorImpl.java:-2

@xguo27 Thanks for working on this. I think the root cause here is that we extract Python UDFs too early (in analyzer), EvaluatePython is an special logical plan, many rules have no knowledge of it, which will break many things. We should extract Python UDFs later, in end of optimizer, or physical plan, I will send an PR to fix that.

Sure @davies . I will close this PR.


Add Ruby on Rails example project

I'm not sure if it belongs in this list, but someone requested if I wanted to add it to this list.

Thanks @jvanbaarsen!


golan

Please answer these questions before submitting your issue. Thanks!
What version of Go are you using (go version)? Golang Ubuntu version
Does this issue reproduce with the latest release? Yes
What operating system and processor architecture are you using (go env)?
GOARCH="amd64"
GOBIN=""
GOEXE=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOOS="linux"
GOPATH=""
GORACE=""
GOROOT="/usr/lib/go-1.7"
GOTOOLDIR="/usr/lib/go-1.7/pkg/tool/linux_amd64"
CC="gcc"
GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build279210773=/tmp/go-build -gno-record-gcc-switches"
CXX="g++"
CGO_ENABLED="1"
What did you do?
package main
import (
"fmt"
)
func main() {
fmt.Println("Hello, playground")
hello := make(chan int)
    go func() {
	hello <- 1
}()

    go f(){
    	//hello <- 2
    }()
hello_value := <- hello
fmt.Println(hello_value)

}
If possible, provide a recipe for reproducing the error.
A complete runnable program is good.
A link on play.golang.org is best.
What did you expect to see?
The code  should have compiled.
What did you see instead?
Compilation error.

package main
import (
"fmt"
)
func main() {
fmt.Println("Hello, playground")
hello := make(chan int)
    go func() {
	hello <- 1
}()

    go f(){
    	//hello <- 2
    }()
hello_value := <- hello
fmt.Println(hello_value)

}

We don't the issue tracker to ask questions. Please see https://golang.org/wiki/Questions for good places to ask. Thanks.

Hi Dave,
Not sure why this issue has been closed? It is a compilation error when it
is not supposed to be. Why did you assume this was a question?
On Mon, Sep 18, 2017 at 4:50 PM, Dave Cheney<EMAIL_ADDRESS>wrote:

Closed #21927 https://github.com/golang/go/issues/21927.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/golang/go/issues/21927#event-1254261730, or mute the
thread
https://github.com/notifications/unsubscribe-auth/ACEbbM_53Xfjws3bL4LqFRSvZsRsaF-_ks5sjteagaJpZM4PbgB1
.

It should be go func() {, not go f(){. The error message indicates the site of the problem.


Add CITATION.cff

Since the BibTex generated by GitHub seems to have been improved with CFF version 1.2.0, I thought to give it a try to add a CITATION.cff for Trixi.jl. Contents are up for debate, including, but not limited to, the information that is provided (and that is omitted).
For information on the format, see the Guide to Citation File Format schema version 1.2.0.
Closes #773.

How does the generated bibtex citation look like?
Do we really need this anymore since GitHub recognizes our existing CITATION.bib?

* How does the generated bibtex citation look like?

BibTex:
@article{Schlottke_Lakemper_A_purely_hyperbolic,
author = {Schlottke-Lakemper, Michael and Ranocha, Hendrik and Winters, Andrew R. and Gassner, Gregor J.},
doi = {10.1016/j.jcp.2021.110467},
journal = {Journal of Computational Physics},
title = {{A purely hyperbolic discontinuous Galerkin approach for self-gravitating gas dynamics}},
url = {https://github.com/trixi-framework/paper-self-gravitating-gas-dynamics},
volume = {442}
}

APA:

Schlottke-Lakemper, M., Ranocha, H., Winters, A. R., & Gassner, G. J. A purely hyperbolic discontinuous Galerkin approach for self-gravitating gas dynamics. Journal of Computational Physics, 442(). https://doi.org/10.1016/j.jcp.2021.110467

* Do we really need this anymore since GitHub [recognizes our existing CITATION.bib](https://github.com/trixi-framework/Trixi.jl/issues/773#issuecomment-901658241)?

Good question. Given that notorious but prevalent habit of people not citing software and its related publications, I thought anything that makes it easier is a good thing. I see the downside of having to maintain one additional place, but thought that for now we could have both files side by side (like Julia does). One advantage of the CITATION.cff file is that it directly gives you a copyable citation, e.g.,

I honestly don't think that having to click once more to copy a citation entry makes the difference between people citing the software or not.

The year seems to be missing from both BibTex and APA. Aargh.... Will investigate!

Page/article number is missing, too

Right now, I tend to prefer keeping only CITATION.bib without wasting time to try to fix the CITATION.cff but YMMV

Right now, I tend to prefer keeping only CITATION.bib without wasting time to try to fix the CITATION.cff but YMMV

Maybe you're right. It's too much stuff that does not "just work". We can keep in mind that I have created this here in case we want to try again in a few months.


Fix a broken link in README.md

Original link leads to 404 page

https://github.com/Mergifyio backport jazzy humble iron


Revise I2S interface to ring-buffered.

This PR addresses #3003, revising the interface of the I2S driver to a ring-buffered one, similar to the SAI driver.

I tried to make the changes as minimal as possible. This is "working" with properly configured tlv320aic32x4 codec. I have only tested with defmt and oscilloscope, but I need to do some more extensive testing because I don't have the audio jacks connected at the moment. However, I think it is ready for a preliminary review.

I confirmed that the audio playback works great with these changes.

I am trying this PR. Still working to converting my old audio project to the latest embassy version.
But I am missing the option to use this with a I2S without MCLK pin. Like on the STM32F401 SPI3.
So I added quick added new_txonly_nomclk()and new_inner_nomclk() to support this mode.
Other think I was missing is a stop()to stop the ringbuffer/put the device in low power mode.

Thanks, I will add the variants in the PR along with the overflow handling.

I tested it on a stm32F401 (Blackpill) with a PCM5102 Audio DAC.
It works fine.
I would also to see that the ringbuffer write_immediate()is also implemented so that you can prefill the buffer before starting the ringbuffer.

Added all above suggestions. Does going through the whole stop().await dance in the stop method seem like a good idea, or should we use request_stop instead?
@Dirbaio Want to weight in?

@Dirbaio  After the merge this is now very straightforwardly based on the main branch.
With the ringbuffer rework I have succesfully being using this with a 80% DSP processor load at 48k sampling rate without Overruns.
The latest update provides split functionality which enables a pattern for which I was using ping-pong buffers before:

let mut i2s = ...;
let new_buffer = Signal::<[f32 ; BUFFER_SIZE]>::new();
i2s.start();
let (mut reader, mut writer) = i2s.split();
join!(
    async {
        loop {
            let mut buffer = [0.0 ; BUFFER_SIZE];
            reader.read(&mut buffer).await;
            new_buffer.signal(buffer);
        }
    },
    async {
        loop {
            let buffer = new_buffer.wait().await;
            // process
            writer.write(&buffer).await;
        }
    }
).await;

This enables some flexibility in the case of Overruns since clearing one will not affect the timing of the other leading to cascading Overrun failures. It also enables doing parallel reads/writes.


Error - error: CreateFile /proc/self/fd/63 during coredns deletion

Terraform code fails during null_resource is getting executed. The problem is with shell substitution / Expansion of the below line:
kubectl --namespace kube-system delete deployment coredns --kubeconfig <(echo $KUBECONFIG | base64 --decode).
│ Error: local-exec provisioner error
│
│   with null_resource.remove_default_coredns_deployment,
│   on helm-provisioner.tf line 16, in resource "null_resource" "remove_default_coredns_deployment":
│   16:   provisioner "local-exec" {
│
│ Error running command 'kubectl --namespace kube-system delete deployment
│ coredns --kubeconfig <(echo $KUBECONFIG | base64 -d)
: The systematus 1. Output: error: CreateFile /proc/self/fd/63
│ cannot find the path specified.
It could  be nice if this command could modified.
BR,
Sandy

Hi Sandy - this is merely an example of how to achieve the reference architecture. Users may need to modify on their end (i.e. - if running on a Windows machine) to suite their setup


[client,sdl] move webview to static lib

move to static lib aad-view
add support for https://github.com/webview/webview (e.g. use native webview if available)

Remaining issues tracked in #9174

@freerdp-bot test please

@freerdp-bot test
@fifthdegree @bmiklautz @hardening @mfleisz @pnowack I´d like to merge this one as all is implemented in FreeRDP and the only remaining issue so far is that the add_scheme_handler currently only works with linux/gtk
any thoughts/objections?


{Compute} Add target version to warning and help message for deprecating default value for --role

Description

Refine the warning and help message introduced by #20924 to explicitly call out the breaking change schedule.
Testing Guide

History Notes

[Component Name 1] BREAKING CHANGE: az command a: Make some customer-facing breaking change.
[Component Name 2] az command b: Add some customer-facing feature.

This checklist is used to make sure that common guidelines for a pull request are followed.

[x] The PR title and description has followed the guideline in Submitting Pull Requests.

[x] I adhere to the Command Guidelines.

[x] I adhere to the Error Handling Guidelines.

Compute

/azp run


Cronjob version configurable

I'm using the latest version of EKS on AWS and wanted to deploy some jobs on benthos.
It seems to try to create a batch/v1beta1, but the latest version of EKS has batch/v1. There is any way to configure this?
Received response status [FAILED] from custom resource. Message returned: Error: b'configmap/benthos-streams configured\nerror: error retrieving RESTMappings to prune: invalid resource batch/v1beta1, Kind=CronJob, Namespaced=true: no matches for kind "CronJob" in version "batch/v1beta1"\n'

let me know if you need more information

Hey, thanks for raising this!
Could you send me an examples of the values you're using with the Helm Chart?

Hi Charlie, thanks for your answer, here is my values.yaml
deployment:
  replicaCount: 1
  podAnnotations: {}
  podLabels: {}
  annotations: {}
  terminationGracePeriodSeconds: 60
  rolloutConfigMap: true

  readinessProbe:
    failureThreshold: 1
    periodSeconds: 5
    successThreshold: 1
    timeoutSeconds: 2
    httpGet:
      path: /ready
      port: http
  livenessProbe:
    failureThreshold: 3
    periodSeconds: 5
    successThreshold: 1
    timeoutSeconds: 2
    httpGet:
      path: /ping
      port: http
commonLabels: {}

image:
  repository: 'jeffail/benthos'
  pullPolicy: IfNotPresent
  tag: ''

imagePullSecrets: []
nameOverride: ''
fullnameOverride: ''

serviceAccount:
  create: true
  annotations: {}
  name: ''

podSecurityContext:
  {}

securityContext:
  {}

service:
  name: http
  type: ClusterIP
  port: 80
  targetPort: http
  protocol: TCP

  extraPorts:

ingress:
  enabled: false
  className: ''
  annotations:
    {}
  hosts: []
  tls: []

env: []

envFrom:
  []

resources:
  {}

autoscaling:
  enabled: false
  minReplicas: 1
  maxReplicas: 12
  metrics:
    - type: Resource
      resource:
        name: cpu
        target:
          type: Utilization
          averageUtilization: 80

nodeSelector: {}

tolerations: []

affinity: {}

podDisruptionBudget:
  enabled: false

initContainers: []

updateStrategy: {}

extraVolumes:
  []

extraVolumeMounts:
  []

streams:
  enabled: false
  streamsConfigMap: 'benthos-streams' # refers to ConfigMap in streamconfig.yml
  api:
    enable: true

http:
  # Disabling HTTP server will prevent service and ingress objects from being created.
  enabled: true
  address: '<IP_ADDRESS>:4195'
  root_path: '/benthos'
  debug_endpoints: false
  cors:
    enabled: false

serviceMonitor:
  enabled: false
  interval: '10s'
  scheme: http

command: []

args: []

watch: false

topologySpreadConstraints: []

config: {}

the base example works right out of the box
input:
  generate:
    mapping: root = "woof"
    interval: 30s
    count: 0

buffer:
  memory: {}

pipeline:
  processors: []

output:
  stdout:
    codec: lines

but once we want to create a real-world processor it returns the error mentioned:
I removed the processors and outputs on this example to simplify, the error it's by just trying to setup a sqs input.
input:
  label: "raw_values_nats_sqs"
  aws_sqs:
    url: "https://sqs.ap-northeast-1.amazonaws.com/1234567890/MySqs"
    region: "ap-southeast-1"
    max_number_of_messages: 10

pipeline:
  processors: []

output:
  stdout:
    codec: lines


[Enhancement] Redirect to custom sign in page

Hi friends,
Any chance support can be added to redirect to a custom sign in page?
I'd rather use my own page instead of the Cognito UI hosted option.

Hi @wakie thanks for the suggestion.
Do you have an idea/opinion on how that should work? Will it be an externally hosted login page or within the same CloudFront distribution?
And did you consider federating Cognito to e.g. your AD or other IDP solution? Is that applicable to you? If you federate Cognito to exactly 1 IDP then the Cognito Hosted UI won't be shown even, the user would be forwarded to the IDP's login page immediately (can also make it work with multiple IDP's by the way).

Hi @ottokruse appreciate the response.
My intention is to use my own page hosted within the same CloudFront distro. My script plugs directly into the Cognito APIs so it can handle all of the authentication. This is for the purpose of maintaining a consistent UX without redirecting to a different domain with a different experience.
I don't intend on using AD or third party IDPs at this stage, but may do in the future. I suppose my custom sign in page would be it's own "IDP" of sorts, but not in the Cognito sense of the word.
Perhaps my solution would work if a custom IDP feature was implemented? I'm happy to add any requirements (oAuth, etc) into my app in order to implement the support, just so long as I maintain full control of the login flow's UX.

I just had a thought @ottokruse
If we allowed "CognitoAuthDomain" to be set via an input parameter, it may just do what I want!
Would that be tricky to implement, at least to try it out as a proof of concept?

There is a PR for that actually  #44
But... I'm inclined to not pursue that, and instead make the User Pool itself a param, not just the auth domain (read the PR comments if you wanna know why).
You could checkout that PR though and see if it does what you want.

Nice, I didn't know that existed.
I've been thinking about the custom User Pool param feature. I could potentially use that to fit my needs on the assumption that I could use Cognito's custom domain but have the DNS records for that domain to be pointed elsewhere to serve a different page with the domain.
Essentially have the edge Lambdas redirect to the custom domain set in the User Pool which is hosted elsewhere.
Does that sound like it could work?

While that could work, I think for what you are looking for it will not be the simplest solution. The lambda's are currently coded to cooperate in the OAuth2 dance of the Cognito hosted UI. You would need to build that OAuth2 dance then also in your custom sign-in page.
Other approach might be:

create custom sign-in page yourself. It can interact with Cognito API's directly, not through OAuth2
change the checkauth lambda to redirect to your own page, instead of the Cognito hosted domain
do everything you need to do for sign-in in your own page, including acquiring JWT's, and setting them in cookies. (That would replace the parseauth function.)

But of course that deviates from the solution in this repo - it is similar but different.


Question - How to wait for await page.$('selector')

I know how to use await page.waitForSelector('selector')
I want to do the same thing for await page'$('selector')
Here is what I have so far-
async getIsVisible(element) {
If (await element === null) {
return false
}
return Boolean(await element.evaluate(e => (s = window.getComputedStyle(e)) => s.display !== 'none' && s.visibility === 'visible' && s.opacity !== '0'))
}
I'd like to have it keep trying for 30 seconds.
It would be nice if I could just do this-
const element = page.$('selector')
await element.waitForSelector()
Or
await page.waitForSelector(element)
Thanks!

you can try
await page.waitForSelector(selector)
eg: await page.waitForSelector('input[type="email"]')

That's still using a string.
I don't want to use a string.
I want to use - await page'$('selector')

Use page.waitFor and pass your function that checks for visibility as the callback. https://github.com/puppeteer/puppeteer/blob/v3.3.0/docs/api.md#pagewaitforselectororfunctionortimeout-options-args

All of the examples on that page are still using a string.


fix: do not return LNClient while shutting down

Fixes #391 - This issue is actually because migrate node is not working and is giving the user a 0-byte file, hence resulting in an EOF error while reading
Description
Sometimes during backup, calls to get the LNClient information are invoked (not exactly sure why, but it happens randomly), in between the LNClient stop process (see screenshot where calls to get node info and channels are requested between LDK shutdown initiation and complete) which causes the app to panic, this PR adds an isLNClientShuttingDown var so that GetLNClient returns nil without making calls to LDK during shutdown.

Closing in favor of https://github.com/getAlby/hub/pull/605


TBI support CAP JAVA loading CDS model from maven jar

Support CAP JAVA loading CDS model from maven jar.
More details:
https://cap.cloud.sap/docs/java/building-plugins#reference-the-new-cds-model-in-an-existing-cap-java-project

May not be needed.


Minimap incorrectly synced with overlay

When overlay is enabled, minimap synced incorrectly:
https://github.com/kumquat-ir/VisualOres/assets/936618/f576183c-2e84-49ab-ab32-727fb9f9f1f8
This not happens if zoom is out
https://github.com/kumquat-ir/VisualOres/assets/936618/c25a0667-5d46-454d-8014-2c613024e366
debug.log

could have sworn i tested this... will be fixed in the next release


Sort by review count / Wilson score

sorting by review count shows how popular the game is on Steam
sorting by Wilson score is much better than simply sorting by Steam score
https://www.evanmiller.org/how-not-to-sort-by-average-rating.html

Ey @azumukupoe
What you are linking here is very interesting!
I could implement this math, but i'm not actively working on the site (just fixing bugs when they popup), so i cannot guarantee that this will be done. But if I make updates to the site at some point, i will keep in mind.
Thanks a lot


In single-project page, allow update of some project attributes

Requires:

https://github.com/fractal-analytics-platform/fractal-server/issues/562
The corresponding upcoming fractal-server release

After those are implemented, the web client should allow the user to modify the name attribute of the project in context.

The PATCH /api/v1/project/{project_id} endpoint is now available in fractal-server 1.1.0a2.

Warning: 1.1.0a2 was bugged, there is now a fixed version 1.1.0a3.


Use Fornax for documentation generation

This is ready to review/test. Keep in mind it's not publishing docs - after generation (build.sh GenerateDocs) they're in fcs\docsrc\_public.
My recommendation is using GH Actions to build and publish docs on new tag - https://github.com/SaturnFramework/Saturn/blob/master/.github/workflows/docs.yml

Thanks so much!


[BUG] fixes to BaseClassifier._predict_proba default and SklearnClassifierPipeline in case predict_proba is not implemented

This fixes some unreported bugs with BaseClassifier default methods and SklearnClassifierPipeline for predict_proba.

BaseClassifier._predict_proba worked only for certain mtypes, since n_instances was obtained as len(X) which is correct only for some mtypes. This has been replaced by len(y) which is always the same as n_instances.
SklearnClassifierPipeline._predict_proba would break if the sklearn classifier interfaced had no predict_proba. This was fixed by defaulting to the BaseClassifier._predict_proba.
SklearnClassifierPipeline had the capability:multivariate tag set exactly the wrong way, a not was missing. This did not cause a breakage but a lot of incorrect warnings.

approved as part of https://github.com/alan-turing-institute/sktime/pull/3102


Implement customized AJAX requests

Proposed fix for #50.
Adds two new public functions: customAffjax and customAffjax' which allow the underlying XHR to be inspected/manipulated before it is sent. This makes it possible to add an event listener for the progress event, for example.
To enable this, execution of the XHR was divided into three stages:

preparing,
callback wiring,
sending.

Bump; would the idea of this still be useful?
(I found this issue while trying to figure out how to get timeouts working; requests stay stuck in Pending forever in some situations. I'll ping this as related when I write it up.)

This PR would have been helpful to me. Why wasn't it merged? Just because of the CLA, or for some other reason?

I think, at the time, I was concerned about adding features that wouldn't also work correctly on Node.
Later, I wanted to do something that provided the Affjax interface and you would choose a "driver" or something for it that explicitly determined whether it was for Node or XHR. I haven't spent the time to figure that out still.
Nowadays, there's also purescript-web-xhr if you want to do things that fall outside of Affjax's capabilities.

I say we close this PR. Ideally, affjax would be built on fetch.

@garyb How does this factor into #171 and the driver split we're currently doing?

I think what I said above is still right, and it's not something we need to do here.
There's maybe something that could be done in the driver repo(s) that would allow extra capabilities (pass something in when "creating" a driver value - maybe it's like (XMLHttpRequest res -> Effect (XMLHttpRequest res)) -> AffjaxDriver or something for the web affjax driver, and then explicitly pass that into the non-driver affjax functions), but there other library options for needs outside of Affjax's interface.
I'll close this because of that.

Another option is to increase the driver interface, passing in Nothing for options not supported in that environment or options one doesn't want to use.


[Communication] - Identity and Common - Addressed final identity and common apiview comments

/azp run java - communication - tests


Fix model imports

I forgot to add the "imant-import" branch in the CI, I have restarted the build to include the appropriate branch.


Suggest to use PNPM instead of NPM in the documentation

Reasons:

Reduced disk space usage
Reduced downloads size
Reduced installation time

Closed, as the advantages are very small from a consumer point of view.


[Feature Request]: DS Projects details should support K8s view

Feature description
We have Admin supported -- Edit mostly supported (I think we have a couple issues still floating about it) but we do not support View at all. Lots of "k8s will tell them no" happening. Including Data Connections are secrets and not available in View.
We should look to support View at some point, but we may need to migrate away from Data Connection Secrets -- if possible.
Describe alternatives you've considered
No response
Anything else?
No response

This might be a tracker rather than a standalone issue (if it's only the spike to investigate the changes I'm ok with it). But as we've discussed previously, view might be a bigger change than expected.

@lucferbux @andrewballantyne we've triaged this into ds-projects, not sure if it should be in infra?

@alexcreasy Yes, this is ds-projects, permissions are self-contained in projects.

Hi @andrewballantyne @alexcreasy @lucferbux I came up with a simple design for the View permission as shown below. What do you think about that?

Furthermore, I have been working on the update of the whole permissions UI, because I've seen some drawbacks of the current UI. When I did the new designs, I had some questions about the permissions as listed below.

Can one user have multiple permissions?
Can the admin know the members of a Group?
Is it possible to select the existing users? For example, we can provide a list including all available users. At the same time, the admin can also type the user name directly to specify a user.
If a user belongs to a group, but the group and the user have different permissions. For example, the group has Admin permission and the user has View permission. Does the user have both the Admin permission and View permission?
Please take a look and share your answers. Thanks in advance!

@xianli123 I have replied inline...

Hi @andrewballantyne @alexcreasy @lucferbux I came up with a simple design for the View permission as shown below. What do you think about that?

We should look at probably sorting this from most to least permissions.
Admin => Edit (renamed to Contributor for our UI) => View
(most) => to => (least)
Each is additive in the same vein. View can just see and not modify most resources. Edit can modify most resources. Admin can do the remaining things Edit could not.
Note, "modify" in this case means the full rage of CRUD.
If you need to know the difference in what is actually allowed. K8s has decent documentation (see the table in this section), if not somewhat technical.

Furthermore, I have been working on the update of the whole permissions UI, because I've seen some drawbacks that don't fit the new requirements. When I did the new designs, I had some questions about the permissions as listed below.

Can one user have multiple permissions?

Permissions in K8s is much deeper than this basic overview... but no, they should not have more than one of these.

Can the admin know the members of a Group?

If they have the power to list groups, they have the power to go to OpenShift Console and see the contents. I know Erwan has spoke of wanting to see the grouped users in the Dashboard UI -- but currently Admins don't really have this power by their role definition. So this has not been a priority (not even sure we have an issue 🤔)

Is it possible to select the existing users? For example, we can provide a list including all available users. At the same time, the admin can also type the user name directly to specify a user.

Autocomplete of usernames was nixed (by me) during the initial development of the feature. I do not know if we have an easy way to filter on partial name value. K8s doesn't support filtering by partial resource name (User is a resource).

If a user belongs to a group, but the group and the user have different permissions. For example, the group has Admin permission and the user has View permission. Does the user have both the Admin permission and View permission?

Permissions are exclusively additive (once given a permission, you cannot remove it without removing the source). You get the most permissions of all permissions granted to you. So yes, they would be Admin foremost because it includes View by nature (if it didn't, it would aggregate the two values together).

Please take a look and share your answers. Thanks in advance!

@andrewballantyne Thanks for your answer. I will update the order according to (most) => to => (least).

K8s has decent documentation (see the table in this section), if not somewhat technical.

I have read the doc. That's very helpful. Thx!

they should not have more than one of these.

If so, we should have a mechanism to avoid specifying the existing username with a different permission. Right?

@xianli123 yes, we should definitely unique-ify the values for both user and group.

Ok. I agree. I will do that.

Hi @andrewballantyne I updated the design based on your answers and suggestions that you shared in last Thursday's meeting. Here is the design link. Please take a look. If there is any questions, please feel free to let me know.
Main updates:

Combined the user permissions table and group permissions table.
The view permission is named "Viewer"(noun) instead of "View"(verb), because "Admin" and "Contributor" are nouns. We can keep them consistent.

Sounds good... this functionality will also need to support the special set of rules behind view:

Can't create any resources
Can't edit any resources
Doesn't see Data Connections section
But should be able to use all things -- links to Workbenches, Model Serving routes/tokens for fetching (maybe? @lucferbux I assume the Token is a secret? Is this a problem?)

Hi @kaedward Could you please take a look at this design? Do you think if the button wording Assign permission is accurate? Thanks!

About View not seeing data connections section, due not not being able to list secrets
"This role does not allow viewing Secrets, since reading the contents of Secrets enables access to ServiceAccount credentials in the namespace, which would allow API access as any ServiceAccount in the namespace (a form of privilege escalation)."
This could also be important to implement with the env variable import into workbenches based on, you got it, secrets.
In terms of listing the dashboard-specific secrets in the namespace, which would be disabled, the dropdown, for View.
I think for View users, the whole Secret section would need to be disabled.
allow creating workbench env from secrets, issue 1380

@xianli123 I think "Assign permission" works :-) Was there any pushback on that phrasing?

@kaedward Thanks. Let's go ahead with the "Assign permission".

Move to RFE or get PM weigh in on this.

Migrated to: https://issues.redhat.com/browse/RHOAIENG-2754 - can track this work there.


Breadcrumbs cause OOM

When something bad happens on server and we get several exceptions per second - breadcrumbs can grow and cause process to OOM while trying to send these exceptions.
Example of mesage from raven to sentry:
https://gist.github.com/samoylovfp/29e8b863ce19bc5e999cb54ad0d0f41e
There should be some way of limiting maximum size of breadcrumbs array or size of outgoing message body.

Might be related - I looked at the breadcrumb integration for the logging module, and it seems to retain the args, kwargs arguments given to the logging call, as part of the closure for the inner processor() function in  _record_log_breadcrumb(). Kind of becomes a problem when I logged objects that are part of a large object graph, so the breadcrumb list ended up keeping big chunks of the graph in memory even after the rest of my program no longer retains them.

Interesting @codewarrior0 - that would be a particularly subtle problem if someone logs the results of XPath queries using lxml, since those act like strings, but keep the entire XML object graph in memory.


Path operations

Get-FileExtension
Rename-FileExtension
Join-PathParts

Join-PathParts needs to be reconsidered, because Join-Path is usually good enough. Others are done.


Update data source subsystem

Improve data source API by adding the _by_uid variants.
Improve data source API by adding universal datasource.get() method.
Improve Makefile and format code.

Codecov Report

Merging #18 (82b6a2f) into main (51edfc1) will decrease coverage by 1.74%.
The diff coverage is 17.64%.

@@            Coverage Diff             @@
##             main      #18      +/-   ##
==========================================
- Coverage   87.65%   85.90%   -1.75%
==========================================
  Files          17       17
  Lines         664      681      +17
==========================================
+ Hits          582      585       +3
- Misses         82       96      +14

Impacted Files
Coverage Δ

grafana_client/elements/dashboard.py
100.00% <ø> (ø)

grafana_client/elements/datasource.py
49.23% <17.64%> (-11.19%)
:arrow_down:

Continue to review full report at Codecov.

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


SuggestedActions pushes the top of the chat behind the header bar

When the div for suggested actions buttons is present, the message group content div is displaced upwards but doesn't take into account the header being there. So the top part of the first message will be hidden behind it if the user scrolls up. It returns to normal once the suggested actions have disappeared.

Before Suggested Actions, scrolled to bottom
Before Suggested Actions, scrolled to top
During Suggested Actions, scrolled to bottom
During Suggested Actions, scrolled to top (part of top message is hidden behind the header)
After Suggested Actions, scrolled to bottom
After Suggested Actions, scrolled to top

For the record, the screenshots were taken in Chrome but the same issue occurs in IE.

Hi @MRowley1, yes the top of the message scrolls behind the header, the same as when you have many messages to be scrolled.We want the bottom message to be visible when suggested are displayed.

My point is that it's stuck behind the header, it's impossible to view the top of the first message while the suggested action bar is showing. That fourth image is as far up as you can scroll, the first line is completely obscured.


Fix the "portfolio graph top line number doesn't reset after hovering on chart" bug

Now the graph calls onMouseOver(undefined) when your pointer stops hovering it, so the number correctly resets.

Oh, by the way, I think this solves a separate issue from the Linear issue.
Your other PR probably solves what I meant by the Linear issue: https://github.com/manifoldmarkets/manifold/pull/1063
The issue is if you zoom in on the portfolio page (drag a range), then the y-axis adjusts. But if you move your mouse over the graph, the y-axis jumps back to it's original scale.

Oh, by the way, I think this solves a separate issue from the Linear issue.
Your other PR probably solves what I meant by the Linear issue: #1063
The issue is if you zoom in on the portfolio page (drag a range), then the y-axis adjusts. But if you move your mouse over the graph, the y-axis jumps back to it's original scale.

Yes, this was not related to that.

Thanks for fixing! LGTM.
FYI, there's a nice flow for using Linear, if you want to try it out for future bugs:
Click the icon in the top right here: https://linear.app/manifoldmarkets/issue/MAN-15/zooming-in-on-graph-rescales-y-axis-but-resets-y-axis-on-mouse-hover
This will copy a suggested git branch name: marshall/man-15-zooming-in-on-graph-rescales-y-axis-but If you create that branch and open a PR with it, it will automatically update the Linear issue, saying in progress, in review, and done based on if the PR is open, assigned a reviewer, or merged.

This isn't going to work for me, I care about my branch names because I use them as meaningful identifiers to remember things that I have in flight, and quickly switch refer to them using fuzzy search in my editor like 500 times per day (e.g. I will check out this branch and force-push a version up to date with master by typing C-x g b b (i am now looking down at my list of recent branches) fix-por [enter] F u P - f p). So having a gigantic branch name that's hard to read and has lots of random words is unacceptable to me.


027 Add material and buzzword methods, increase some word banks

https://github.com/stympy/faker/pull/353

https://github.com/DrewMartin/faker/pull/1

Superseded by #31


Windows compatibility fix

Simple fix for simple problem causing errors on Windows machines, where Git by default converts line endings from \n to \r\n when checking out code and back to \r when checking it in.

Hi @zenflow what's the current behavior on Windows machines without this fix?

Hi @zenflow what's the current behavior on Windows machines without this fix?

Sorry for the delay.. I can answer this tomorrow probably

I remember that (on Windows) the header is parsed incorrectly as being empty, and some error is thrown later on because of that.
Reminder that it's not simply a matter of using \n line endings because Git on Windows is typically configured to change line endings to /r/n when code comes out and back to /n when it goes back in.

@yangshun I can give it a go tomorrow. But I'm a little confused.. Are the new .gitattributes and .editorconfig files in that PR copied to projects when you do $ docusaurus-init? (because that is what I'll try)

Oh hmm I was just fixing it on local development. I think you are right, this needs to be copied upon docusaurus-init too. Could you try my PR and build the site locally? If that works, then this is a feasible solution and we can add these files as into the scaffolded files when docusaurus-init-ing. Would you be interested in making a PR to do that?

@yangshun

Could you try my PR and build the Docusaurus site locally by cloning this repo?

Yeah for sure I'll give it a test and review. I think it will help for local development.
But I don't think it's a good idea to copy the files when docusaurus-init-ing.. .editorconfig doesn't always help because it will only ensure proper line endings once the individual files get opened in your IDE.. and .gitattributes needs to be in the root directory of the repo in order to work, and it's possible a project already has a file there that would be overwritten. Also we can include this in the scaffolding, but that becomes end-user-level configuration.. wouldn't it be considered more robust for Docusaurus to handle things properly without requiring more specific configuration in the app?
I've seen the /\r?\n/ pattern used a number of places (Next.js, Pino) without code comments and did not consider that it would be unfamiliar to linux-only developers.. but we can make this more clear I think... what if I extract that regex into a const with a short code comment like "this pattern matches \n (unix line endings) and \r\n (windows line endings)"?


DGB Commerce

The DGB Commerce information should be removed from the community section, since the platform will not be a part of the DigiByte ecosystem.

PR 123 resolved this.


[match] sensitive options

as https://github.com/fastlane/fastlane/pull/7169 got merged
Sensitive Options Series:

pem -> https://github.com/fastlane/fastlane/pull/7238
scan -> https://github.com/fastlane/fastlane/pull/7239
cert -> https://github.com/fastlane/fastlane/pull/7237
match -> https://github.com/fastlane/fastlane/pull/7236
fastlane (actions) -> https://github.com/fastlane/fastlane/pull/7235

tests fail because of outstanding fastlane_core release including #7169
i ll rebase once fastlane_core is released


Add subject, general and imaging metadata

Todo:

[ ]  Add keywords.
[ ] Add genetict line.
[ ] Add subject description.
[ ] Add manufacturer for the microscope device.
[ ] Add surgery
[ ] Add channel information [see error]

[ ]  Add channel information [see error]
#13

@alessandratrapani This is still not working. It is failing for the keywords. Can you fix it, check the metadata one more time and then ping me to review it again?


External Control of File Name or Path

Hello there,
The vulnerability has been verified and fixed according to the maintainer but the provided commit is not the solution of the vulnerability. This misleads Microweber users. Please provide the accurate solution.
Report:
https://huntr.dev/bounties/09218d3f-1f6a-48ae-981c-85e86ad5ed8b/
Provided commit:
https://www.github.com/microweber/microweber/commit/957d307178eb73e13fcfdffb364cee32bc6f9928

https://github.com/microweber/microweber/commit/572bdc36b5b47923790016f6b961c8df53226855
https://github.com/microweber/microweber/commit/98d025467128ecc24195dcb56c533febc3c91af6

Thanks for the fast response.

hi , the issue is fixed and new version is released


use latest Operator SDK (0.15.2)

Putting this PR here to air out a bit while we test it more.
Lots of go source files got touched in the "imports" section because of the directory name change from "pkg/apis/kubedirector.hpe.com" to "pkg/apis/kubedirector". Other changes listed below.
.gitignore
Removing "dep"-related stuff.
Some formatting changes in the autogenerated part.
.travis.yml
New golang version requirement.
Switching from dep to go modules.
Gopkg.{lock,toml} and go.{mod,sum}
Switching from dep to go modules.
Makefile
Updating the golang version requirement & adding an operator-sdk version requirement.
Removing "dep"-related stuff.
Directory name change pkg/apis/kubedirector.hpe.com -> pkg/apis/kubedirector.
Make clean should also remove configcli.tgz.
Fixes for .PHONY.
build/*
Slightly different skeleton generated by current SDK -- user setup is done at image build time. Not 100% sure this will still be fine under OpenShift strictness but it is what the SDK now recommends.
doc/*
Updating docs for changes to supported/suggested K8s platforms and changes in build process.
Adding upgrade.md to contain notes about moving to the new version.
main.go
Re-enabling leader election, but "with lease" rather than "for life"; cf. issue #265.
New Prometheus metrics stuff. Commented out for now until we can actually test this.
deployment-prebuilt.yaml and operator.yaml
No predefined metrics port anymore.
WATCH_NAMESPACE really should be empty (since we're cluster scope), even though we don't use this.
rbac-default.yaml
Adding privs for services/finalizers since the new generated role includes that. Not sure we need it but eh.
Also adding get/watch/list privs for daemonsets (again, probably don't need).
Adding privs for deployments/finalizers on our own deployment.
Adding Prometheus-related privs (monitoring.coreos.com).
cert.go
Had to pull in these functions we use that have been removed from latest client-go. We could/should move to using the tls module now provided by the SDK... however, its interface requires storing the various certs/keys in two secrets and a configmap, while our current method uses one secret. Since there are now some existing deployments of KD, we would need a migration strategy.
shared/client.go
Handling changes in the signatures for List and Delete.
Handling cases where the split client now can return ErrCacheNotStarted.
validator/util.go
For the Webhooks list element inside our MutatingWebhookConfiguration: instead of a Webhookobject we now are required to use MutatingWebhook. Even though the API version of MutatingWebhookConfiguration has not changed. I think this is a compatible change i.e. MutatingWebhook is a superset of the old Webhook.

Note that this change does not take advantage of any new capabilities of the new SDK yet. Some things to investigate: using markup to help generate validation schema, secondary resources, CR status conditions, and the metrics stuff mentioned above.


Regressions in French translations (Superset 4.0) : La connexion a fière allure !

Bug description
PR #26074 updated the .json and .po files and introduced regressions in French translations.
Solution is to revert to the previous .json and .po files, while keeping the other changes of PR #26074 regarding date range filter translations.
How to reproduce the bug

Configure French translations

BABEL_DEFAULT_LOCALE = "fr"

LANGUAGES = {
    "fr": {"flag": "fr", "name": "French"},
}

Go to the home page and observe some weird translations !
"Graphiques" => "Graphiques:"
"Backend" => "Programme dorsal"
"Jeux de données" => "Ensemble de données"
"Connection looks good" => "La connexion a fière allure"

Screenshots/recordings

Superset version
4.0.0 and master-dev
Python version
3.9
Node version
16
Browser
Chrome
Additional context
Need to run
pybabel compile -d /app/superset/translations

to compile the FAB translations.
Checklist

[ ] I have searched Superset docs and Slack and didn't find a solution to my problem.
[X] I have searched the GitHub issue tracker and didn't find a similar bug report.
[ ] I have checked Superset's logs for errors and if I found a relevant Python stacktrace, I included it here as text in the "additional context" section.

Ha! "La connection a fiere allure" FTW :) Sensationel!

I'm trying to diff to see what changed ->
git diff cc2f6f1ed9 cc2f6f1ed9^ superset/translations/fr/LC_MESSAGES/messages.po

but the git differ isn't anchoring in the right places to show the differences properly, so it's hard to assess whether the edits are all bad or only a subset
leaving a trace here:
# checkout the after file
git checkout cc2f6f1ed9 && cp superset/translations/fr/LC_MESSAGES/messages.json /tmp/after.json
# checkout the before file
git checkout cc2f6f1ed9^ && cp superset/translations/fr/LC_MESSAGES/messages.json /tmp/before.json

compare the before/after
import json

# Load JSON data from files
def load_json(filename):
    with open(filename, 'r', encoding='utf-8') as file:
        return json.load(file)

# Compare the translations in two JSON objects
def compare_translations(data1, data2):
    results = []
    for key in data1["locale_data"]["superset"]:
        if key and key in data2["locale_data"]["superset"]:
            translation1 = data1["locale_data"]["superset"][key][0]
            translation2 = data2["locale_data"]["superset"][key][0]
            if translation1 != translation2:
                results.append({
                    "english_source_sentence": key,
                    "french_from_file1": translation1,
                    "french_from_file2": translation2
                })
    return results

# Main function to run the comparison
def main():
    file1_data = load_json('before.json')
    file2_data = load_json('after.json')
    differences = compare_translations(file1_data, file2_data)
    print(json.dumps(differences, ensure_ascii=False, indent=2))

if __name__ == "__main__":
    main()

sample of the output:
  {
    "english_source_sentence": "You are importing one or more saved queries that already exist. Overwriting might cause you to lose some of your work. Are y
ou sure you want to overwrite?",
    "french_from_file1": "Vous importez une ou plusieurs requêtes sauvegardées qui existent déjà. L'écrasement peut vous conduire à perdre une partie de vot
re travail. Etes-vous sûr de vouloir ce remplacement ?",
    "french_from_file2": "Vous importez une ou plusieurs requêtes enregistrées qui existent déjà. L'écrasement pourrait vous faire perdre une partie de votr
e travail. Êtes-vous sûr de vouloir les écraser?"
  },
  {
    "english_source_sentence": "Link Copied!",
    "french_from_file1": "Lien copié !",
    "french_from_file2": "Lien copié!"
  },
  {
    "english_source_sentence": "There was an issue deleting the selected queries: %s",
    "french_from_file1": "Il y a eu un problème lors de la suppression de requêtes sélectionnées : %s",
    "french_from_file2": "Il y a eu un problème lors de la suppression des requêtes sélectionnées : %s"
  },
  {
    "english_source_sentence": "Delete query",
    "french_from_file1": "Effacer la requête",
    "french_from_file2": "Supprimer la requête"
  },
  {
    "english_source_sentence": "Are you sure you want to delete the selected queries?",
    "french_from_file1": "Ete-vous sûr de vouloir supprimer les requêtes sélectionnées ?",
    "french_from_file2": "Voulez-vous vraiment supprimer les requêtes sélectionnées?"
  },

Overall seemed good to me. I'd hate to revert the whole thing.

Looks like there are close to 2 thousand edits here and mostly looks much better than what was there before, though I spent more time writing the code than reviewing the french.
Tagging @Ralkion for input


Every event firing twice?

I've written a dummy plugin that subscribes to every event in the api and sends its name to the logger - not programmatically, but explicitly:

I know that most events will trigger multiple ways due to player being a human being a living etc, so I expect to see a lot of events for each action.  Some events I have commented out (playerEvent, livingEvent, etc, due to genericness of them and console spam when moving around, OR due to crashing the server on start-up due to missing entirely), just to get an idea of what events are triggered AT THIS TIME for particular actions
What I found shocking is that everything seems to fire each event TWICE,  I have posted a file on pastebin showing the output to console/log for various actions -- user types in chat, types a command, logs in, breaks a dirt block, drops from inventory, places a furnace block, places a chest, opens a chest, opens a furnace block...
See Pastebin link for these examples:  http://pastebin.com/V5xNgPbF
In all cases, every event in the 'chain' logs itself twice in a row, such as for example here
=- drag away item from inventory
PlayerDropItemEvent
PlayerDropItemEvent
HumanDropItemEvent
HumanDropItemEvent
LivingDropItemEvent
LivingDropItemEvent
EntityDropItemEvent
EntityDropItemEvent
ItemDropEvent
ItemDropEvent
==============
Currently using:
Forge forge-1.8-<IP_ADDRESS>7-universal.jar
Sponge file sponge-1.8-1446-2.1DEV-482.jar
maven-repo/dependancies
Doubled behavior was seen with older sponge jars as well.

Were you testing in SinglePlayer by chance?

Forge version doesn't match the version sponge was built for

On Jun 17, 2015, at 3:03 AM, theboomer<EMAIL_ADDRESS>wrote:
I've written a dummy plugin that subscribes to every event in the api and sends its name to the logger - not programmatically, but explicitly:
I know that most events will trigger multiple ways due to player being a human being a living etc, so I expect to see a lot of events for each action. Some events I have commented out (playerEvent, livingEvent, etc, due to genericness of them and console spam when moving around, OR due to crashing the server on start-up due to missing entirely), just to get an idea of what events are triggered AT THIS TIME for particular actions
What I found shocking is that everything seems to fire each event TWICE, I have posted a file on pastebin showing the output to console/log for various actions -- user types in chat, types a command, logs in, breaks a dirt block, drops from inventory, places a furnace block, places a chest, opens a chest, opens a furnace block...
See Pastebin link for these examples: http://pastebin.com/V5xNgPbF
In all cases, every event in the 'chain' logs itself twice in a row, such as for example here
=- drag away item from inventory
PlayerDropItemEvent
PlayerDropItemEvent
HumanDropItemEvent
HumanDropItemEvent
LivingDropItemEvent
LivingDropItemEvent
EntityDropItemEvent
EntityDropItemEvent
ItemDropEvent
ItemDropEvent
Currently using:
Forge forge-1.8-<IP_ADDRESS>7-universal.jar
Sponge file sponge-1.8-1446-2.1DEV-482.jar
maven-repo/dependancies
Doubled behavior was seen with older sponge jars as well.
—
Reply to this email directly or view it on GitHub.

Okay, kinda dumb on my part posting the versions and not noticing the mismatch :)
However, I just got the 1446 forge version now, deleted the old one, and am using it.
I still get the exact same thing happening with forge-1.8-<IP_ADDRESS>6-universal.jar - each event logging twice

http://pastebin.com/AUxYECpM
My entire single-class code is in this pastebin.  I would really like to know if I'm hallucinating badly somehow, or if someone else gets the same result.

You're going to be annoyed because I spotted the problem in 10 seconds.
You call game.getEventManager().register(this, this);
But the plugin main class is already registered on the event bus, so effectively each handler is getting called twice.
Remove that registration, it's needed only for other classes, not the main (@Plugin) class.

ah, excellent :)
Not annoyed at all - relieved.

Shouldn't we prevent multi registration because this is an invalid state?

Hi
I have the same issue and I do not call the service to register the plugin class. As you can see in my code I have worked around the bug with a boolean flag for now. @theboomer did the solution fix your issue?
package com.whippy.sponge.guard.main;
import java.io.IOException;

import org.json.simple.parser.ParseException;
import org.slf4j.Logger;
import org.spongepowered.api.Game;
import org.spongepowered.api.entity.EntityInteractionTypes;
import org.spongepowered.api.event.Subscribe;
import org.spongepowered.api.event.entity.player.PlayerBreakBlockEvent;
import org.spongepowered.api.event.entity.player.PlayerInteractEvent;
import org.spongepowered.api.event.state.ServerStartingEvent;
import org.spongepowered.api.item.inventory.ItemStack;
import org.spongepowered.api.plugin.Plugin;
import org.spongepowered.api.service.command.CommandService;
import org.spongepowered.api.text.Texts;
import org.spongepowered.api.text.format.TextColors;

import com.flowpowered.math.vector.Vector3d;
import com.google.common.base.Optional;
import com.google.inject.Inject;
import com.whippy.sponge.guard.beans.StaticsHandler;
import com.whippy.sponge.guard.beans.WorldLocation;
import com.whippy.sponge.guard.commands.FinaliseCommand;
import com.whippy.sponge.guard.orchestrator.ClickHandler;

@Plugin(id = "WhippyGuard", name = "WhippyGuard")
public class WhippyGuard {

	private static final String WAND_ID = "minecraft:bone";
	private static final boolean RIGHT_CLICK_BUG=true;
	private boolean inRightClick = false;

	@Inject
	Game game;

	@Inject
	Logger logger;

	@Subscribe
    public void onServerStarting(ServerStartingEvent event) throws IOException, ParseException  {
		StaticsHandler.setClickHandler(new ClickHandler());
		StaticsHandler.setGame(game);
		StaticsHandler.setLogger(logger);
    }

	@Subscribe
	public void onPreInitializationEvent(ServerStartingEvent event) {
		CommandService cmdService = game.getCommandDispatcher();
		cmdService.register(this, new FinaliseCommand(), "areaCommit");
	}

	@Subscribe
	public void onPlayerBreakBlockEvent(PlayerBreakBlockEvent event){

	}

	@Subscribe
	public void onPlayerInteractEvent(PlayerInteractEvent event){
		Optional<ItemStack> itemInHand = event.getEntity().getItemInHand();
		if(itemInHand.isPresent()){
			if(itemInHand.get().getItem().getId().equals(WAND_ID)){
				if(event.getInteractionType().equals(EntityInteractionTypes.USE)){
					if((RIGHT_CLICK_BUG && !inRightClick) || !RIGHT_CLICK_BUG){
						inRightClick = true;
						if(event.getClickedPosition().isPresent()){
							Vector3d vectorPoint = event.getClickedPosition().get();
							WorldLocation point = new WorldLocation(event.getPlayer().getWorld().getName(), vectorPoint.getX(), vectorPoint.getY(), vectorPoint.getZ());
							StaticsHandler.getClickHandler().playerAreaDefineClick( event.getEntity(), point);
						}
					}else if (RIGHT_CLICK_BUG){
						inRightClick = false;
					}
				}else if(event.getInteractionType().equals(EntityInteractionTypes.ATTACK)){
					event.getEntity().sendMessage(Texts.builder("leftclicked").color(TextColors.RED).build());
				}
				event.setCancelled(true);
			}
		}
	}

}

@WhippyCleric that is not the same bug afaict, it's a bug with that specific event which I believe is related to Forge.

Hi
Thanks for the pointer to the correct issue, I will live with my hack for now and just flip the boolean when forge is fixed

Getting right click's twice looks to be a separate bug from receiving all events twice.


Implement price lookup for vesting assets

FDT
VSTA
pKLIMA
pBTRFLY

Awaiting feedback from json and relwyn about the priority level of this

Current vested assets:
- FDT (5M tokens)
- pBTRFLY (10% of supply)
- pKLIMA (either 3% or 3.3% of supply would need to confirm)

We have decided that until the vesting assets hit the treasury (as real, liquid tokens), they will not be listed.


[BugFix] Fix fencing failed when a new leader is elected

What type of PR is this：

[x] BugFix
[ ] Feature
[ ] Enhancement
[ ] Refactor
[ ] UT
[ ] Doc
[ ] Tool

Which issues of this PR fixes ：

Fixes #12136
Problem Summary(Required) ：

Because of consistency bug in bdb(may arise when all node restart continuously), the data in epochDB may be discontinuous, so the epochDB.count() + 1 can be an existing value, which will cause epochDb.putNoOverwrite failed. To fix bdb bug is difficulty, so we define the new epoch by the largest value in epochDB + 1.
Checklist:

[ ] I have added test cases for my bug fix or my new feature
[ ] I have added user document for my new feature or new function

[FE PR Coverage Check]
:disappointed: fail : 7 / 9 (77.78%)
file detail

path
covered_line
new_line
coverage
not_covered_line_detail

:large_blue_circle:
com/starrocks/ha/BDBHA.java
7
9
77.78%
[121, 122]

[FE PR Coverage Check]
:disappointed: fail : 7 / 11 (63.64%)
file detail

path
covered_line
new_line
coverage
not_covered_line_detail

:large_blue_circle:
com/starrocks/ha/BDBHA.java
7
11
63.64%
[122, 123, 124, 125]

run starrocks_admit_test

@Mergify backport-branch-2.2 backport-branch-2.3 backport-branch-2.4


Provide instructions and demo how to successfully run dhcp server on Linux Ubuntu

Hi,
This could be a source for information:
https://stackoverflow.com/questions/74940771/not-receiving-broadcast-udp-messages-when-binding-to-specific-address

Binding to <IP_ADDRESS> is a bad idea for a DHCP server, it will start handing out IP leases on all your subnets.
From here https://stackoverflow.com/questions/13666789/receiving-udp-broadcast-packets-on-linux it seems I may have to bind another socket to the subnet broadcast address (e.g. <IP_ADDRESS>) to receive broadcast packets on Linux.

@n-ice-ch I've created a test setup with ubuntu in virtualbox, indeed it seems broadcast packets are dropped somewhere. Disabling ufw doesn't help. I suspected my router, but the broadcasts arrive fine when I send them from ubuntu to windows. .To be continued..

Here's the issue: https://github.com/dotnet/runtime/issues/83525.
The workaround looks clunky, will try it tomorrow.

Update: got it working on Ubuntu , so the trick is to bind to <IP_ADDRESS>:67 but before that do a SO_BINDTODEVICE (bind to a specific nic) so it will only act as a DHCP server on that nic's subnet.
see https://github.com/jpmikkers/DHCPServer/blob/netcore/DHCPServer/Library/UDPSocketLinux.cs
Meanwhile, in that branch I've refactored the code a lot to use async/await, still needs some work in the main app though.

Sounds promising.
I've worked with IPAddress.Any for meanwhile. In my case it does not matter which subnet to serve as I use it as simple PXE.
But on Linux I can serve BIOS requests only. For EFI it does not work with IPAddress.Any.
So I'm very interested on your research.

Update: got it working on Ubuntu , so the trick is to bind to <IP_ADDRESS>:67 but before that do a SO_BINDTODEVICE (bind to a specific nic) so it will only act as a DHCP server on that nic's subnet.
see https://github.com/jpmikkers/DHCPServer/blob/netcore/DHCPServer/Library/UDPSocketLinux.cs
Meanwhile, in that branch I've refactored the code a lot to use async/await, still needs some work in the main app though.

Did you get any update for the issue on Linux?


codegen for new workflow interface

We can create a specific codegen tool for the above interface.
Procedure might look something like:

run meshing
call watertight()
walk the hierarchy of the returned object using help() and type queries etc to fill in all the details.

We will obviously do this as part of the forthcoming refactor. @prmukherj


tech(test): Change testing library

Resolves #354.
Note to reviewers: I'm deeply sorry about the size of this PR. I didn't see a way to break these changes into smaller bits. I hope it's not too painful 😬
Purpose
Enzyme has had a lot of problems keeping up with React and enables/encourages bad testing practices. We've been successfully testing (no pun intended) react-testing-library in some of our applications. It has two main benefits:

It's a thin wrapper around React's built-in test utils, so keeping up with React is much easier and faster.
It encourages better testing practices as it forces you to test the public API rather than the implementation. This makes our tests more robust and stable.

Approach and changes

Install react-testing-library and related libs and remove Enzyme & co.
Add new global testing functions:

render: render a component and do things with it
create: renders a pure DOM representation of a component for snapshots. Basically just synthetic sugar for render -> container.firstChild / container.children.
fireEvent and userEvent: interact with a component like a user would.
act: util function from React to wrap interactions that cause a state update or rerender in the component. This makes your test run closer to how React works in the browser.

Refactor all tests that used mount and shallow
Unify the input component APIs: they all accept a consistent onChange callback now. The old props (e.g. onToggle) still work and are marked as deprecated.
Smaller improvements to the implementation here and there, e.g. for better readability or accessibility.

Definition of done

[x] Development completed
[x] Reviewers assigned
[x] Unit and integration tests
[x] Meets minimum browser support
[x] Meets accessibility requirements

:tada: This PR is included in version 1.1.1-canary.14 :tada:
The release is available on:

npm package (@canary dist-tag)
GitHub release

Your semantic-release bot :package::rocket:

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

npm package (@latest dist-tag)
GitHub release

Your semantic-release bot :package::rocket:


core: move project to golang

starting migration from bash to go, starting with
basic ceph commands and getting mons endpoint
Signed-off-by: subhamkrai<EMAIL_ADDRESS>

btw this how ci is executing commands,  not sure why
kubectl rook-ceph ceph status
ceph status --connect-timeout=10 --conf=/var/lib/rook/rook-ceph/rook-ceph.config

+ kubectl rook-ceph mons
a=<IP_ADDRESS>:67[8](https://github.com/rook/kubectl-rook-ceph/actions/runs/3870952267/jobs/6598314558#step:5:9)[9](https://github.com/rook/kubectl-rook-ceph/actions/runs/3870952267/jobs/6598314558#step:5:10),b=[10](https://github.com/rook/kubectl-rook-ceph/actions/runs/3870952267/jobs/6598314558#step:5:11).107.55.17:6789,c=<IP_ADDRESS>:6789

In the future we may also want to unit test commands where we can mock K8s and the exec commands, like we do in the Rook core. So I'd suggest that this method should take the kubeconfig as a parameter, then the core implementation takes parameters for the context that can be mocked. The kubeconfig would likely be initialized at the top layer under the cmd package.

now, I'm returning the rest and client from GetKubeClient only.
I'm not sure about second part could you refer some example

Rook has a method to create the context, which initializes most of the context here. By default, it will create types that will exec real commands and expect a real k8s cluster. But then the unit tests can mock the exec and k8s methods by passing a different context, for example as created here for the K8s tests, or search for MockExecutor for mocking the commands. This can all be done in a separate PR though.

I think I'm not very much confident about how that's works, may be discussed in call will make it clear.

LGTM!


Some test hanging in feature/triggers branch.

At least one test is causing builds to hang indefinitely in the feature/triggers branch.
See the following builds as examples:

https://dev.azure.com/dnceng/public/_build/results?buildId=1364346&view=logs&j=65f10494-31fe-52d1-5fe1-01a23f2be03d&t=420d1cf9-3f30-5020-98bb-a81ab34c6723
https://dev.azure.com/dnceng/public/_build/results?buildId=1364594&view=logs&j=8ea7f87c-df53-50f1-0540-f2769981835e

This is not caused by PR #853 since it is also repros with PR #854.

Seems to be some test in the Microsoft.Diagnostics.Monitoring.Tool.UnitTests assembly.

Seems to be the Microsoft.Diagnostics.Monitoring.Tool.UnitTests.CollectionRulePipelineTests.CollectionRulePipeline_EventCounterTriggerTest that hangs on occasion.


github-runner: 2.319.1 -> 2.320.0

https://github.com/actions/runner/releases/tag/v2.320.0
one patch failed to apply, replaced with substituteInPlace
happy to drop formatting changes
Things done

Built on platform(s)

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

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

[ ] sandbox = relaxed
[ ] sandbox = true

[ ] Tested, as applicable:

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

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

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

[ ] Fits CONTRIBUTING.md.

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

The release notes contain:

Add jq, git, unzip and curl to default packages installed actions/runner#3056

Upstream added those packages to their Dockerfile. Shouldn't we also pass in those packages?

after reading comments in https://github.com/actions/runner/pull/3056, I am leaning towards no, but I will let maintainers decide

I am not strictly against it, but as far as I understand the Dockerfile has nothing to do with the VM images of the GitHub-hosted runners. They include tons of preinstalled software and we obviously don't want to include all that software for the NixOS module. If we add the tools mentioned, the question immediately arises as to why other programs are not important as well. Therefore, I'd rather refer people to services.github-runners.<name>.extraPackages.

This needs backporting  as Github Actions will block runners that are out of date

Unfortunately the formatting patches makes the backport not apply cleanly


HTML and CSS Waypoint: Prioritize One Style Over Another is not accepting the solution

Challenge http://www.freecodecamp.com/challenges/waypoint-prioritize-one-style-over-another has an issue.
Steps for replication:
Meet all the expectation of the challenge "HTML and CSS  Waypoint: Prioritize One Style Over Another" Exercise. It'll not accept the answer.
Screenshots:

Thanks and Regards,
Sandeep Lakka

I'm afraid the CSS class name it asked to create was "pink-text", but i did it with "pink-test".
Sorry for the inconvenience.


feat: bump android dependency & clean up scanner widgets

This PR:

fixes an odd bug in the iOS / MacOS implementation
updates API documentation
updates the barcode overlay / scan window overlay with extra styling properties

TODO: fix flickering bug with the overlay in the scanner overlay painter
TODO: fix barcode painter not repainting with no square when the barcode is no longer within the camera view

Thanks!


Add initial xray implementation

README.md should have all info needed to review

Looking at the plot we get 3 top right empty subgraphs:
Is this intended?

Yes and no. The intention was to have one column of the graph for csv analysis and one for pcap analysis, so the intention was that they might have different number of graphs, but matplotlib apparently populates it with empty graphs so both sides have the same number of graphs. I changed it so it will distribute all defined graphs evenly. There might still be one empty graph going forward if the number of defined graphs is odd

I fell that at some point it would actualy be a good idea to have bidirectional testing.

I was thinking about that before too but didn't implement it. I created LLT-5844 for it


Added the Data Preprocessing and EDA part in the main file, and done oversampling to handle class imbalance

Fixes Issue🛠

Closes #
Description👨💻

Type of change📄

[] Bug fix (non-breaking change which fixes an issue)
[] New feature (non-breaking change which adds functionality)

How this has been tested✅

Checklist✅

[] My code follows the style guidelines of this project
[] I have performed a self-review of my own code
[] I have commented my code, particularly in hard-to-understand areas
[] I have added demonstration in the form of GIF/video file
[] I am an Open Source Contributor

Screenshots/GIF📷

Pls don't change tsv to csv file. Work on the provided dataset.
Don't change the path of the file.

Do check this https://github.com/Rakesh9100/ML-Project-Drug-Review-Dataset/pull/71/files. The csv files are added and path of the file is showing of your PC.

Oh sorry I missed it. I am correcting it now.

I have corrected it now, Please check


ToPretext work

I'm ready to help the unifiedLatexToPretext  part get working.  Currently, if I try I get an error about not knowing what to do with the node "instruction".
I feel pretty good about working with the unified asts in general, although know less about the abstracted unified()-strung together commands and how that works.  Where would a good place be for me to get started getting my hands dirty?

What exactly are you calling when you get that error?

I was calling this from inside a function in pretext-tools, but it was just running the code snippet from the example in the readme.

Happy to report that I have this successfully working in pretext-tools now.  I'll start adding some more environments soon.


Document AI framework

The documentation for the AI framework is lacking, currently only giving an example of enumerate without giving much context about how to use it.  I had to dig into the code to see how and when the bots were instantiated, and what their API was.

I'm happy to do this, I just wanted to make sure noone else had anything in progress before I started.

Ah, this is actually deliberate because the AI "framework" (if it is a framework) is still a young experiment and I'm sure that the API will change many times before it is ready for wider reception.

But perhaps having some documentation will help increase adoption which will further help shape the API.  So, I'm not fundamentally opposed to having a page about the AI in either the Guides or the Reference section.

That's fair, but in the limited scenarios I've put it through what's there seems to work pretty well.  I think it's ok for the documentation to change and mature with the API.  More importantly, documentation might get more people using it and more feedback as to what the API should be?


'bits/unique_ptr.h' file not found

Hello ,
Please help me I am getting below issue
Build command failed.
Error while executing process /Users/smscountry-imac/Library/Android/sdk/ndk-bundle/ndk-build with arguments {NDK_PROJECT_PATH=null APP_BUILD_SCRIPT=/Users/smscountry-imac/Documents/Telegram/TMessagesProj/jni/Android.mk NDK_APPLICATION_MK=/Users/smscountry-imac/Documents/Telegram/TMessagesProj/jni/Application.mk APP_ABI=arm64-v8a NDK_ALL_ABIS=arm64-v8a NDK_DEBUG=1 APP_PLATFORM=android-21 NDK_OUT=/Users/smscountry-imac/Documents/Telegram/TMessagesProj/build/intermediates/ndkBuild/afat/debug/obj NDK_LIBS_OUT=/Users/smscountry-imac/Documents/Telegram/TMessagesProj/build/intermediates/ndkBuild/afat/debug/lib NDK_APPLICATION_MK:=jni/Application.mk APP_PLATFORM:=android-16 -j8 /Users/smscountry-imac/Documents/Telegram/TMessagesProj/build/intermediates/ndkBuild/afat/debug/obj/local/arm64-v8a/libtmessages.30.so}
Android NDK: WARNING:/Users/smscountry-imac/Documents/Telegram/TMessagesProj/jni/libtgvoip/Android.mk:flac: LOCAL_LDLIBS is always ignored for static libraries
Android NDK: WARNING: Unsupported source file extensions in /Users/smscountry-imac/Documents/Telegram/TMessagesProj/jni/libtgvoip/Android.mk for module flac
Android NDK:   ./exoplayer/libFLAC/windows_unicode_filenames
[arm64-v8a] Compile++      : tmessages.30 <= gifvideo.cpp
[arm64-v8a] Compile++      : tmessages.30 <= TgNetWrapper.cpp
[arm64-v8a] Prebuilt       : libc++_shared.so <= /sources/cxx-stl/llvm-libc++/libs/arm64-v8a/
[arm64-v8a] Compile        : webp <= alpha.c
[arm64-v8a] Compile        : webp <= buffer.c
[arm64-v8a] Compile        : webp <= frame.c
[arm64-v8a] Compile        : webp <= idec.c
[arm64-v8a] Compile        : webp <= io.c
[arm64-v8a] Compile        : webp <= quant.c
[arm64-v8a] Compile        : webp <= vp8.c
[arm64-v8a] Compile        : webp <= vp8l.c
[arm64-v8a] Compile        : webp <= tree.c
[arm64-v8a] Compile        : webp <= webp.c
In file included from /Users/smscountry-imac/Documents/Telegram/TMessagesProj/jni/./TgNetWrapper.cpp:2:
/Users/smscountry-imac/Documents/Telegram/TMessagesProj/jni/tgnet/ApiScheme.h:14:10: fatal error: 'bits/unique_ptr.h' file not found
#include <bits/unique_ptr.h>
^~~~~~~~~~~~~~~~~~~
[arm64-v8a] Compile        : webp <= alpha_processing.c
[arm64-v8a] Compile        : webp <= alpha_processing_sse2.c
[arm64-v8a] Compile        : webp <= cpu.c
In file included from /Users/smscountry-imac/Documents/Telegram/TMessagesProj/jni/./gifvideo.cpp:11:
/Users/smscountry-imac/Documents/Telegram/TMessagesProj/jni/tgnet/ConnectionsManager.h:18:10: fatal error: 'bits/unique_ptr.h' file not found
#include <bits/unique_ptr.h>
^~~~~~~~~~~~~~~~~~~
[arm64-v8a] Compile        : webp <= dec.c
[arm64-v8a] Compile        : webp <= dec_clip_tables.c
[arm64-v8a] Compile        : webp <= dec_mips32.c
[arm64-v8a] Compile        : webp <= dec_neon.c
[arm64-v8a] Compile        : webp <= dec_sse2.c
[arm64-v8a] Compile        : webp <= enc.c
[arm64-v8a] Compile        : webp <= enc_avx2.c
[arm64-v8a] Compile        : webp <= enc_mips32.c
[arm64-v8a] Compile        : webp <= enc_neon.c
[arm64-v8a] Compile        : webp <= enc_sse2.c
[arm64-v8a] Compile        : webp <= lossless.c
[arm64-v8a] Compile        : webp <= lossless_mips32.c
[arm64-v8a] Compile        : webp <= lossless_neon.c
[arm64-v8a] Compile        : webp <= lossless_sse2.c
[arm64-v8a] Compile        : webp <= upsampling.c
[arm64-v8a] Compile        : webp <= upsampling_neon.c
[arm64-v8a] Compile        : webp <= upsampling_sse2.c
[arm64-v8a] Compile        : webp <= yuv.c
1 error generated.
1 error generated.
[arm64-v8a] Compile        : webp <= yuv_mips32.c
[arm64-v8a] Compile        : webp <= yuv_sse2.c
make: *** [/Users/smscountry-imac/Documents/Telegram/TMessagesProj/build/intermediates/ndkBuild/afat/debug/obj/local/arm64-v8a/objs-debug/tmessages.30/./TgNetWrapper.o] Error 1
make: *** Waiting for unfinished jobs....
make: *** [/Users/smscountry-imac/Documents/Telegram/TMessagesProj/build/intermediates/ndkBuild/afat/debug/obj/local/arm64-v8a/objs-debug/tmessages.30/./gifvideo.o] Error 1

this might be NDK related things, that header file belongs to GCC,  you might have to use gcc (set it in TMessagesProj/jni/Application.mk, google "NDK_TOOLCHAIN_VERSION") to build module TMessagesProj.  probably refer to their documentation about how to build that module(I would ndk-build on that module first to get it through then move on). I like to dig to it, but too tied to other things at the moment.


Compatible with Sway?

I don't know if this only works with Hyperland or not. I'll try it on Sway if that's possible. I don't know what conflicts or disasters might arise.
I also wanted to say that this is a really cool project. My cat approves. meow

Afaik, hyprlock styling doesn't have anything to do with which WM you use. Also, I'm fairly sure that hyprlock works on Sway as well.


AKS Baseline Architecture suggest adding NSG to azure firewall subnet

[Enter feedback here]
It is not possible to add an NSG to a AzureFirewallSubnet, recommendation is to highlight this in the documentation and visually illustrate it in the solution diagram where AzureFirewall does not have an NSG associated to its subnet.

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

ID: 46723a24-75ac-f6e2-c172-d3827ca0b7d6
Version Independent ID: c975744e-e594-5667-14b3-c38824bbe24c
Content: Baseline architecture for an AKS cluster - Azure Architecture Center
Content Source: docs/reference-architectures/containers/aks/baseline-aks.yml
Service: architecture-center
Sub-service: reference-architecture
GitHub Login: @PageWriter-MSFT
Microsoft Alias: prwilk

@abengtss-max
Thanks for your feedback! We will investigate and update as appropriate.

That is a really good catch.  I don't know how that got onto the diagram.
@CAC1127 can you queue up an editor task to remove the NSG logo from the image here on the Azure Firewall subnet.

@ckittel @CAC1127 brought this to my attention. I've opened up a work item with Beyondsoft for them to edit the diagram.

Addressed in the following PR: https://github.com/MicrosoftDocs/architecture-center-pr/pull/11183.


level=warn ts=2023-06-21T05:55:13.450305925Z caller=shipper.go:239 msg="reading meta file failed, will override it" err="failed to read /prometheus/thanos.shipper.json: open /prometheus/thanos.shipper.json: no such file or directory"

This is the yaml I use：
apiVersion: monitoring.coreos.com/v1
kind: Prometheus
metadata:
  labels:
    app.kubernetes.io/component: prometheus
    app.kubernetes.io/instance: k8s
    app.kubernetes.io/name: prometheus
    app.kubernetes.io/part-of: kube-prometheus
    app.kubernetes.io/version: 2.44.0
  name: k8s
  namespace: monitoring
spec:
  alerting:
    alertmanagers:
    - apiVersion: v2
      name: alertmanager-main
      namespace: monitoring
      port: web
  enableFeatures: []
  externalLabels: {}
  image: quay.io/prometheus/prometheus:v2.44.0
  nodeSelector:
    kubernetes.io/os: linux
  podMetadata:
    labels:
      app.kubernetes.io/component: prometheus
      app.kubernetes.io/instance: k8s
      app.kubernetes.io/name: prometheus
      app.kubernetes.io/part-of: kube-prometheus
      app.kubernetes.io/version: 2.44.0
  podMonitorNamespaceSelector: {}
  podMonitorSelector: {}
  probeNamespaceSelector: {}
  probeSelector: {}
  replicas: 1
  resources:
    requests:
      memory: 400Mi
  ruleNamespaceSelector: {}
  ruleSelector: {}

  serviceAccountName: prometheus-k8s
  serviceMonitorNamespaceSelector: {}
  serviceMonitorSelector: {}
  version: 2.44.0
  logLevel: info
  volumes:
  - name: localtime
    hostPath:
      path: /etc/localtime
  volumeMounts:
  - mountPath: "/etc/localtime"
    name: localtime
  retention: 10d

  storage:
    volumeClaimTemplate:
      metadata:
        annotations:
          volume.beta.kubernetes.io/storage-class: "nfs-storageclass"
      spec:
        storageClassName: nfs-storageclass
        accessModes: [ "ReadWriteMany" ]
        resources:
          requests:
            storage: 10Gi

  thanos:
    image: quay.io/thanos/thanos:v0.31.0
    objectStorageConfig:
      key: objectstorage.yaml
      name: thanos-objectstorage

After starting according to this configuration, the log prompt from thanos sidecar
level=warn ts=2023-06-21T05:55:13.450305925Z caller=shipper.go:239 msg="reading meta file failed, will override it" err="failed to read /prometheus/thanos.shipper.json: open /prometheus/thanos.shipper.json: no such file or directory"
I checked the /prometheus directory, and this file exists. After I gave 777 permissions to the persistent directory, the sidecar log did not prompt this error. Obviously this is a file permission problem. When the thanos.shipper.json file is generated, Does not take into account that sidecar containers are unreadable

hi, does anyone know any fix or workaround for this?

I have the same issue


Add MinGW support

This PR introduces preliminary Windows support via MinGW.
The functionality is added in steps, so it is recommended to review the changes commit by commit.
The Windows/MinGW-specific changes are done in the "Port network layer to Winsock"-commit, which adds a simple socket compatibility layer (sockcompat), that essentially:

Uses platform specific socket file descriptor types (int for POSIX, SOCKET for Windows).
Includes platform specific headers (regular Unix/socket headers for POSIX, and winsock for Windows).
Replaces selected POSIX socket API calls with Win32 wrappers that:

Handle type/signature conversions.
Transparently call WSAStartup() (once).
Update errno with the return value of WSAGetLastError() upon errors (so that the hiredis code can continue to use errno for its logic).

Still missing is a MinGW builder for travis or appveyor, but the branch builds under Ubuntu Linux using CMake + MinGW cross-compilation like so:
$ CC=x86_64-w64-mingw32-gcc CXX=x86_64-w64-mingw32-g++ cmake -G Ninja -DCMAKE_BUILD_TYPE=Release -DCMAKE_BUILD_WITH_INSTALL_RPATH=on bath/to/source
$ ninja

I didn't know what copyright owner/notice to use in the new source files sockcompat.c & sockcompat.h, so I just wrote my name there. I'll gladly replace it with whatever copyright you'd like (i.e. I have no interest in being the copyright owner).

This looks very nice! I'm heading to redisconf tomorrow so I don't know if I'll have time to look at the TODO (ENOENT on ioctlsocket) this week, but I'd like to get that resolved before merging.

I'll give it another try soon. I also noticed that I forgot to wrap connect() (which mostly means that errno may be wrong if connect fails), so I'll fix that too.

Current findings: Using connect() on a non-blocking socket results in WSAGetLastError() == WSAEWOULDBLOCK under Windows. Since the socket always starts out as non-blocking in net.c, this is a problem. I'll continue investigating.

I fixed the problem and removed the TODO: When connect() on non-blocking sockets results in EWOULDBLOCK on Windows, it is the same thing as EINPROGRESS on POSIX.
I did a special case conversion in the Win32 wrapper function for connect() (and I also rewrote the sockcompat layer to get more correct errno handling on Windows).

Interesting work. Do you know which actions for supporing MSVC17 or clang on windows?

It would be awesome if we could have appveyor or whatever test this in CI. I can't guarantee that a future change won't just end up breaking this again.

@giorgiozoppi I don't know, but it should not be prohibitively difficult. I think the gist of the work is to solve #599 (e.g. struct packing in the sds lib). I see it as a separate task.

@mnunberg I agree. I took a quick look at your Travis file, but the way it is structured (as a matrix of compiler/OS/bitwidth), adding MinGW didn't feel straight forward (e.g. what does 32-bit MinGW on macOS mean?), so I think that it needs to be refactored.
The way I do it in BuildCache is this: https://github.com/mbitsnbites/buildcache/blob/master/.travis.yml#L39
I'm not sure how it would fit in your current Travis setup.


Low power setting too high

The low power setting is way too high. Can that be modified in firmware?

Technically yes, but I don't think it can go much lower.


去除cancelFunc避免退出之前关闭mysqlConn导致数据获取不完整

该取消函数会导致设置QueryTimeout后通过gdb拿到的数据不完整。因为函数退出的时候关闭了rowsi的mysqlConn。

#1116

Codecov Report

Merging #1183 (0e6cddb) into master (a69aec9) will increase coverage by 0.01%.
The diff coverage is 0.00%.

@@            Coverage Diff             @@
##           master    #1183      +/-   ##
==========================================
+ Coverage   69.11%   69.12%   +0.01%
==========================================
  Files         366      366
  Lines       25962    25960       -2
==========================================
+ Hits        17944    17946       +2
+ Misses       6534     6529       -5
- Partials     1484     1485       +1

Impacted Files
Coverage Δ

database/gdb/gdb_core.go
63.13% <0.00%> (+0.24%)
:arrow_up:

net/ghttp/ghttp_server_error_logger.go
0.00% <0.00%> (-100.00%)
:arrow_down:

os/gspath/gspath_cache.go
83.78% <0.00%> (-8.11%)
:arrow_down:

os/gtimer/gtimer_entry.go
88.37% <0.00%> (-1.17%)
:arrow_down:

container/gtree/gtree_redblacktree.go
87.89% <0.00%> (-0.42%)
:arrow_down:

net/gtcp/gtcp_conn.go
32.82% <0.00%> (+2.29%)
:arrow_up:

net/gtcp/gtcp_pool.go
39.39% <0.00%> (+10.60%)
:arrow_up:

Continue to review full report at Codecov.

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


Multi-part examples in rustdoc

@arifd
Co-authored-by: Arif Driessen<EMAIL_ADDRESS>

I personally don't think this is a needed addition: it seems to be a bit too much specific to be really useful (or used).
I'm interested to see what the others in the @rust-lang/rustdoc team think about it though.

I personally don't think this is a needed addition: it seems to be a bit too much specific to be really useful (or used).

I think this is useful, although it does stretch the scope of rustdoc a bit. I'd like to hear from library authors, since they'll be the ones using it - @darksonn @BurntSushi @dtolnay would you be interested in this?

I do sometimes write things in this style, but I have not found the need to do so in our API reference. The examples there are not really complicated enough to warrant it in my experience.
Maybe it would be more useful in mdBook?

I would love to have this for Bevy! Actually demonstrating functionality can involve quite lengthy, multipart code, and we rely heavily on our stand-alone and docs-integrated examples as integration tests.

I wonder what @carols10cents thinks of this RFC. I have not read it yet, but this feature in general feels like something that we may want to take advantage of in the book. I know at various times I've wanted something like this in long-form writing about Rust.

This is a really nice-to-have feature.
I especially like the idea of adding arguments to ``` for special behaviors, which resembles RMarkdown.

I have not read it yet, but this feature in general feels like something that we may want to take advantage of in the book. I know at various times I've wanted something like this in long-form writing about Rust.

Doesn't the Book use mdBook though?

@camelid unless something has changed, mdbook calls out to rustdoc.

@camelid unless something has changed (or i am 1000% misremembering), mdbook calls out to rustdoc.

Ah, I forgot that mdBook uses rustdoc for tests 👍

So yes, the book does use mdBook, and mdBook takes Rust code blocks from the markdown files and then runs rustdoc test on them. So it's kind of backwards from library documentation.
When we have long examples in the book that we explain in pieces, I'm using the rustdoc_include feature with anchors. The code actually lives in separate files so that we can provide complete, standalone Cargo projects for each code listing (and can run rustfmt on them, save the output of running them to include in the text as well, and do other stuff that I doubt is relevant to library documentation).
I believe there are a few cases where one code file has multiple anchors in it, so that we are accomplishing the same goal that is here of having text interleaved with multiple parts of one long code example. But most of the time, in the book, we're helping the reader to build up an example from nothing, and it's not often straightforward like "add lines 3 and 4, then add lines 5, 6, and 7". Usually it's "we're going to write a function that returns a static value, ok now we're going to take an argument, ok now we're going to change the return type, and now we have to change the call sites too". So it's more applying changes to one example to build it up, rather than explaining it line-by-line.
So I don't think this feature as written would be relevant to the book, is what I'm trying to get at.
Now, for library documentation, I personally find it very difficult to write long doc comments anyway, to get them to show up where I think people would look for them in the moment they need them. And writing markdown inside /// lines isn't a great experience, writing Rust code within Markdown within doc comments even more so. If I provide an example in a doc comment, it's going to be very short and something to just give the general idea of how you'd call something as reference, not a tutorial with lots of text around it. I think mdBook or other tools are better for the tutorial kind of documentation, at this point (I'm not sure what the best tool for writing tutorials is, but I'm familiar with mdBook and it integrates with Rust code well enough, so it's what I'd currently use in this case).
So overall, I'm not sure that adding this feature to rustdoc would be useful. I do, however, appreciate the thought that has gone into this RFC and appreciate the desire to make docs better!

As a library author that writes lots of examples, I'm not sure I would have much use for something like this personally. While I'm not quite as pessimistic about writing code inside of /// comments as @carols10cents (perhaps because I've done it so much that my brain has adapted to it haha), I do not often find myself in situations where I have drawn out examples that would require something like this. In cases where I do, I often find it better to find a way to simplify the example somehow. When that's not possible, putting comments inside the code block is usually good enough for me. It's likely I would continue doing that in most cases even if this feature were present, since I think splitting up examples into multiple chunks can be a bit disorienting unless the situation really calls for it. But maybe this is a feature where if it were present, I'd find more use cases for it.
With respect to the UI mockup, I have two comments/questions:

What does the "run" button do on each of the snippets? I would guess that the "run" button does the same thing for each snippet in an entire example: it runs the whole thing. Where does the output get displayed?
Is there a way to copy the entire code block stitched together? Otherwise, users will have to copy each individual block if they want to copy an example into their project.

Prompted by @carols10cents' comment, I realized that I would be much more inclined to write longer form documentation1 if the effort involved with publishing a book was reduced. To that end, I'm suggesting that docs.rs build and host mdBook content. That may be a complete alternative to this RFC.

1 — And I already try to write longer form documentation inside of my more user-facing crates. For example, SNAFU has an entire guide module that is only documentation.

think this is useful, although it does stretch the scope of rustdoc a bit. I'd like to hear from library authors, since they'll be the ones using it - @Darksonn @BurntSushi @dtolnay would you be interested in this?

I've been missing this a lot: I come from Python where doctests are widely supported. Doctests in Python allow you to save state between code blocks and this is very useful to be able to show a continued worked examples. Here is a random example from Scipy where they first define a matrix and then verify some property of it in the next code block:

Note how the second code block uses a defined in the first. I hope to write similar documentation in Rust where I only need to import modules once per docstring.


some devfs tests fail locally

I see a devfs test failure when run locally (cd packages/flutter_tools; dart test/devfs_test.dart):
devfs modify existing file on local file system
  Expected: true
    Actual: <false>

  package:test                                       expect
  test/devfs_test.dart 46:7                          main.<fn>.<fn>.<async>
  dart:async                                         _SyncCompleter.complete
  package:flutter_tools/src/devfs.dart 433:3         DevFS.update.<async>
  dart:async                                         _SyncCompleter.complete
  package:flutter_tools/src/devfs.dart 555:5         DevFS._scanDirectory.<async>
  ===== asynchronous gap ===========================
  dart:async                                         _Completer.completeError
  test/devfs_test.dart 47:6                          main.<fn>.<fn>.<async>
  dart:async                                         _SyncCompleter.complete
  package:flutter_tools/src/devfs.dart 433:3         DevFS.update.<async>
  dart:async                                         _SyncCompleter.complete
  package:flutter_tools/src/devfs.dart 555:5         DevFS._scanDirectory.<async>
  ===== asynchronous gap ===========================
  dart:async                                         _asyncThenWrapperHelper
  test/devfs_test.dart                               main.<fn>.<fn>
  package:flutter_tools/src/base/context.dart 75:26  AppContext._run.<async>
  ===== asynchronous gap ===========================
  dart:async                                         Future.Future.microtask
  package:flutter_tools/src/base/context.dart        AppContext._run
  package:flutter_tools/src/base/context.dart 66:13  AppContext.runInZone.<fn>
  dart:async                                         runZoned
  package:flutter_tools/src/base/context.dart 65:12  AppContext.runInZone
  test/src/context.dart 68:24                        testUsingContext.<fn>

I think state from one test is interfered with that in another. It looks like the tests share a common  MockDevFSOperations object, and one test is clearing out the state (via MockDevFSOperations.contains()) that another depends on.
These tests should probably be reworked so that all test setup happens in a setUp method and there's no dependencies on tests running in a certain order.
/cc @johnmccutchan

Is this still happening?

Assuming this is being run on a mac. This was a bug that only affected the unit test and @lukechurch fixed it recently.

These tests should probably be reworked so that all test setup happens in a setUp method and there's no dependencies on tests running in a certain order.

This is still an issue - unless these tests have been re-written, they depend on running in a certain order. They should be changed so that they tests can run in any order, or some run and not others, without seeing failures.

package:test guarantees tests run in the order they are registered and these DevFS tests are specifically ordered. The DevFS tests could be trivially refactored to not depend on each other but that doesn't seem high priority. Maybe @lukechurch has cycles.

I'm not sure it has any such guarantee - @nex3 would know. You are able to run specific tests by name, which in this case, the tests would fail.

The DevFS tests could be trivially refactored to not depend on each other

That would be great, and what this bug is tracking.

test doesn't provide any guarantee about test ordering. In practice currently we do run tests within a given suite in-order, but this could change in the future—for example, we've talked about splitting up large suites to run in parallel across multiple isolates.
In general, every test should be able to run in isolation from any other test. If you're not in a world where running each test individually succeeds, you're off the happy path and test may break you.

@nex3 It would be good to make the test framework randomise the order, because otherwise people will assume the order is guaranteed regardless of what the documentation says.

I think that would cause more pain than it would be worth. I'm not interested in making people's tests more flaky just to prove a point.

In that case, I am afraid the test package does guarantee the test execution order, whether you intended it to or not, because test suites now depend on that order and so it can't be changed without breaking them.

FYI @tvolkert who is working on wiring up these flutter_tool tests in Google's internal test running system and may hit this.

@tvolkert has switched these tests over to the memory filesystem. Closing as old.


Check coveralls build

The test coverage seems to hang which should be fixed.

I tried out a few approaches and it seems a kcov issue that coverage upload is currently not possible.


Finish readthedocs setup

I haven't been able to get the readthedocs build to work for this package yet. Most builds just die without a proper error message (e.g. https://readthedocs.org/projects/intake-stac/builds/9123555/).

Looks like maybe a temporary conda problem, dead repo server etc. Has this been the case for a while?

conda was serving bad repodata up until ~10 minutes ago.
On Fri, May 24, 2019 at 2:46 PM Martin Durant<EMAIL_ADDRESS>wrote:

Looks like maybe a temporary conda problem, dead repo server etc. Has this
been the case for a while?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/pangeo-data/intake-stac/issues/10?email_source=notifications&email_token=AAKAOISCSZUH5L5FWK3WILLPXBAXZA5CNFSM4HPSH5YKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODWGNBIQ#issuecomment-495767714,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AAKAOIV3JEKMFC7WDERQSGLPXBAXZANCNFSM4HPSH5YA
.

closed by #27