fix(modals): replace focus-trap by focus-lock

I hope it worth it, +4.73kb for a focus 😅

I’ll do my best to reduce it.


proposal: Pluggable Components Discovery

In what area(s)?

/area runtime

/area operator

/area placement

/area docs

/area test-and-release

Describe the proposal

This proposal aims to solve few problems

Bindings Input/Output registry ambiguity, currently we're assuming that a binding component implements both, input and output
The socket name is defined by dapr runtime but used by pluggable component - for sake of simplicity the pluggable component can choose its own name
Reuse gRPC connection and discover it based on created sockets.

Pluggable Component Discovery
From the runtime perspective two major changes:
The runtime would not need to understand the concept of a pluggable component. It is totally agnostic to how processes start/run, this relieves our runtime of a responsibility to understand containers/processes.
So you may ask, how the pluggable components will be recognized by the runtime? That's the second major change of the current proposal: Component discovery using a shared socket volume.
When starting, the runtime will try to find sockets that are available to connect inside a pre-defined socket folder, since a unix domain socket is an ordinary file persisted on file system this would be achieved by using file system operations (like ls, or even more; subscribe to file system events to connect when a unix socket is created). The pluggable component name/type will be derived from the socket name.
Whether running in standalone mode or kubernetes mode this behavior doesn't change. The runtime still looking for a socket to connect, if there's some, so it will connect.
gRPC Reflection
Components types and version are getting from the source of truth -  the gRPC reflection API. This would not add any overhead on implementations as it generally a single line activating the reflection feature.
Components are required to implement gRPC reflection API - this would be handled by the sdks in the near future. This is used to identify which building blocks that socket implement and further used by registering in the respective registry.

Reflection API is supported in the majority languages:

Java
Go
.NET
Python
Rust
Javascript
C++

/assign


oh-my-zsh uninstall.sh issues - switch back to bash is unsatisfactory

Hi
I recently installed oh-my-zsh on my system (running OS X Yosemite, v. 10.10.1, with bash (v. 3.2.53) as default, to test it out.  It was really interesting, but wanting to get back to bash I ran the uninstall script and noticed two minor problems with it (with easy fixes):

it does not make the change to the user visible in the current shell window - this is because the although the relevant line chsh -s /bin/bash (line 24 in uninstall.sh) will certainly change the UserShell property in the user's record in the OS X Directory Services database (for the local domain node ".") from bin/zsh to /bin/bash, the change will not be applied to the user's current (presumably bash) shell window - they have to open a new window (after possibly closing the current one, or from the existing one).  Of course the user may know this, but also they may not, but it would seem a nice to idea to have this done cleanly so that the uninstallation appears painless.  I propose a simple fix - do exec su - $USER, which replaces the current shell instance with a new one, immediately after chsh -s /bin/bash.  Some prompting, pre- and post-execution checking may be required.
it sources /etc/profile (after doing chsh -s /bin/bash).  This seems unnecessary according to the OS X bash man page /etc/profile is sourced first after bash is invoked as an interactive login shell (or a non-interactive login shell with the --login option).  So having done chsh -s /bin/bash the user would be expected to open either a new window from their terminal app or close and reopen their terminal app, which will start an interactive login bash shell that will source /etc/profile first.  Thus this is unnecessary in the uninstall script.

I have forked this repo, applied the changes and made a pull request here.

Hey @sr-murthy, #5169 deals with this and it's now ready to test. If you want to help speed up the testing and merge (which should happen early next week), you can wget or curl it from the URL https://raw.githubusercontent.com/mcornella/oh-my-zsh/refactor-installer/tools/install.sh. Read the comments at the top of the script to know how to call it.
Thanks!


Added request logging for gRPC and HTTP in the server side

Fixes #2844
Signed-off-by: Yash Sharma<EMAIL_ADDRESS>
[x] I added CHANGELOG entry for this change.

Changes

Updated the grpc middleware version to use v2. We are using the last commit which contains the logging middleware. Once grpc_middleware releases the v2 we can add that as well.
Reuse the flag for enabling/disabling the start and finish of the requests from http-request logging.(Let me know if a separate flag is needed for gRPC).
This PR also works on the changes made by #2849 and adds in YAML configuration for the same.

Verification
Current Output -

ts=2020-10-25T06:06:52.994721959Z caller=level.go:63 name=sidecar-1 level=info service=gRPC/server component=sidecar protocol=grpc grpc.component=server grpc.service=thanos.Store grpc.method=Info grpc.method_type=unary grpc.start_time=2020-10-25T11:36:52+05:30 grpc.request.deadline=2020-10-25T11:36:57+05:30 grpc.code=OK peer.address=<IP_ADDRESS>:41926 grpc.request.request-id=01ENF5VS22Q4M9E326FPCTSJ0F grpc.time_ms=0.038 startedcall=(MISSING)
ts=2020-10-25T06:06:52.99524562Z caller=level.go:63 name=sidecar-1 level=info service=gRPC/server component=sidecar protocol=grpc grpc.component=server grpc.service=thanos.Store grpc.method=Info grpc.method_type=unary grpc.start_time=2020-10-25T11:36:52+05:30 grpc.request.deadline=2020-10-25T11:36:57+05:30 grpc.code=OK peer.address=<IP_ADDRESS>:41926 grpc.request.request-id=01ENF5VS22Q4M9E326FPCTSJ0F grpc.time_ms=0.566 finishedcall=(MISSING)
ts=2020-10-25T06:06:52.994721917Z caller=level.go:63 name=sidecar-2 level=info service=gRPC/server component=sidecar protocol=grpc grpc.component=server grpc.service=thanos.Store grpc.method=Info grpc.method_type=unary grpc.start_time=2020-10-25T11:36:52+05:30 grpc.request.deadline=2020-10-25T11:36:57+05:30 grpc.code=OK peer.address=<IP_ADDRESS>:33364 grpc.request.request-id=01ENF5VS22Z5WGC34BSQ3MFTE9 grpc.time_ms=0.037 startedcall=(MISSING)
ts=2020-10-25T06:06:52.995514182Z caller=level.go:63 name=sidecar-2 level=info service=gRPC/server component=sidecar protocol=grpc grpc.component=server grpc.service=thanos.Store grpc.method=Info grpc.method_type=unary grpc.start_time=2020-10-25T11:36:52+05:30 grpc.request.deadline=2020-10-25T11:36:57+05:30 grpc.code=OK peer.address=<IP_ADDRESS>:33364 grpc.request.request-id=01ENF5VS22Z5WGC34BSQ3MFTE9 grpc.time_ms=0.837 finishedcall=(MISSING)
ts=2020-10-25T06:06:52.995990248Z caller=level.go:63 name=sidecar-0 level=info service=gRPC/server component=sidecar protocol=grpc grpc.component=server grpc.service=thanos.Store grpc.method=Info grpc.method_type=unary grpc.start_time=2020-10-25T11:36:52+05:30 grpc.request.deadline=2020-10-25T11:36:57+05:30 grpc.code=OK peer.address=<IP_ADDRESS>:49516 grpc.request.request-id=01ENF5VS23BVAZF5ETRQDJ20Q2 grpc.time_ms=0.04 startedcall=(MISSING)
ts=2020-10-25T06:06:52.996181723Z caller=level.go:63 name=sidecar-0 level=info service=gRPC/server component=sidecar protocol=grpc grpc.component=server grpc.service=thanos.Store grpc.method=Info grpc.method_type=unary grpc.start_time=2020-10-25T11:36:52+05:30 grpc.request.deadline=2020-10-25T11:36:57+05:30 grpc.code=OK peer.address=<IP_ADDRESS>:49516 grpc.request.request-id=01ENF5VS23BVAZF5ETRQDJ20Q2 grpc.time_ms=0.231 finishedcall=(MISSING)

Current TODO

[x] Setup a flag for using the grpc request logging

cc @kakkoyun 🤓

There seems to be a (MISSING) field, I have pushed the changes in the grpc_middleware, that should be fixed in the subsequent release.

The test failures are unrelated to this pr

@yashrsharma44 Needs a rebase.

I have used a logMap to map the options from the flag into the options for the logging middleware. Since from the flag, I only get a string response, so is there any clean way you suggest for configuring the options?

Test Failures are unrelated

Feature Request: Would be nice if we add in the error message as well - https://cloud-native.slack.com/archives/CK5RSSC10/p1606754524365300

Currently, we have deployed a basic request logging for HTTP(#2849) and it seems to be working well. However, with the new addition of YAML config for request logging, it raises a question, how should we warn the user for the deprecating flag for request logging for HTTP.

Should we add this message at the start of the help of log.request.decision - Deprecation Warning - This flag would be soon deprecated, and replaced with YAML config...
Or maybe add in a warning log when the flag is used, that we would deprecate this in the next release.
Need ideas for warning users.

WDYT? cc @yeya24 @bwplotka @kakkoyun

Added the YAML configuration for request logging.
TODO:

[x] Add a deprecation warning for using the old flag for request logging
[ ] Complete the todos in the code
[ ] Added some more fields in the HTTP logging.
[ ] Add regex for the Method, Service and Path field
[ ] Discuss which components need to have the request logging enabled.

Feature Request: Would be nice if we add in the error message as well - https://cloud-native.slack.com/archives/CK5RSSC10/p1606754524365300

Currently, only gRPC provides logging of error, HTTP returns a status code for the same. If we want to log the error for HTTP, we need it from the response body, which is kind of blocking process and not worth it. I have added more fields for HTTP logs, which would help in finding the component which sends in the error.

Documentation of this PR would be tracked in this issue #3623 :sunglasses: :muscle:

Can you elaborate on this -

Please test things manually. I don't think flag filling works in current version at all

Make sure we don't use panics or break consistency. Why suddenly we return error different request logging flag?

Didn't we agree on panic quickly if configs not correct?

PTAL whenever free 😎 @kakkoyun @bwplotka

PTAL whenever free 😎 @kakkoyun @bwplotka

@yashrsharma44 Is this still wait for our attention? 😅

Yeah, would be nice if you could send in a review 😅

👍  I'll spare some time to it this week. In the meanwhile let's rebase.

Sure😁, on it!

@yashrsharma44 I've marked as auto-merge, we just need @bwplotka's final green light 🎉

I had deleted the fork of Thanos for some reason, hence I am not able to push changes to this PR.
Created another PR to track the changes - https://github.com/thanos-io/thanos/pull/3862


port project to Django and deprecate repo

This working prototype in Flask should replaced by a more production-ready Django implementation. This will help address several small impediments and features (many of which are dealt with by Django out of the box).

Can you give more detail on what impediments and features this will address? I know internationalization is one of them...

@tmaybe sure!
While there are some details this helps with, the overall reasoning is that if I'm making an app that has user accounts, internationalization, and is mostly CRUD-oriented, then Django is a better fit for the task than Flask. In the case of the repo, right now is probably the best time to proactively address refactoring, before building out features and after the use case has been validated and users acquired (moving from a working prototype to a beta).
Here's some of the features this might help:

Any further development of user accounts. Django comes with role-based authentication and permissions built in, which we will likely want if we plan to support multiple counties in the same web app.
#109. Django implements access logs for their built-in admin, which may be useful as a starting point.
#75 & #76. The current app needs significant clean up to prune deprecated uses. This can be addressed by rewriting around the core validated use case.
#78. As mentioned before, internationalization is currently stalled due to conflicts with 3rd party flask libraries. Django is built with internationalization in mind and would deprecate the use of those 3rd party libraries.
#98. Django has more mature form handling libraries that are proven to work well with Django's core, and which cover many common CRUD implementations, including splitting a form across multiple views.

This is still in process, but I'm going to close this issue and replace it with more specific incremental tasks.


Small German fix

Great thank you! I'll probably be changing more names in the future, as I think some of them could be more intuitive (i.e. Lightning Creeper instead of Electric Creeper): keep an ear to the ground.


Fix counter updating in MmapAllocator::allocateContiguousImpl

In MmapAllocator::allocateContiguousImpl(), collateral and
allocation are always released, so even if we need to allocate 0 bytes,
we still need to update the allocation and mapped counters (ie,
numAllocated_ and numMapped_) to reduce the number of released
machine pages in collateral and allocation.

@tanjialiang  Could you please help to take a look? Thanks.


Error when passing JS date object in email JSON (node sendgrid v1.9.2)

Starting this morning 4/1/2016 both our QA and production servers stopped being able to send emails. We got a very generic "Unexpected error" in the return JSON from Sendgrid.
It took us about 2 hours to track down the issue and it was resolved when we removed date: new Date() in the email json we send Sendgrid. We've had this in our code for several years with no issue. We are using Sendgrid Node library version 1.9.2
This ticket is to help other who may be experiencing the same issue. Perhaps better error messaging when the Sendgrid servers get this date obj would be appropriate.
We are running Node 0.10.4 if that helps. (Yeah we haven't touched this code in years)

Thank you for the error report!
We have added this to our backlog for further investigation.
For my own notes:
Seems like our internal data representation has changed (guessing it's on the API side): https://github.com/sendgrid/sendgrid-nodejs#setdate

I'm passing this along to our support team.


Accelerating Generation with Rollback using sglang?

Hi team! My generation scenario involves rolling back and I was wondering how I could speed this up using sglang.
In the first stage, I have an initial prompt, and I can obtain an output with sentences delimited by '\n'.
Input:
question.
Output:
sentence1 \n sentence2 \n sentence3 \n
In the second stage, I would like to rollback and generate on these prompts:

question. sentence1 \n
question. sentence1 \n sentence2 \n

Is it possible to reuse the KV caches in the first stage using sglang? Thanks for your help!

Sure. If there is any shared prefix, SGLang runtime can automatically detect them and reuse the KV cache.
If possible, could you share a minimal sequence of your prompts? Based on your description, does it look like this?
# prompt 1
Question: What is your name?
Answer 1: My name is Alex.
Answer 2: I live in SF.
Answer 3: I enjoy hiking.

# prompt 2
Question: What is your name?
Answer 1: My name is Alex.

# prompt 3
Question: What is your name?
Answer 1: My name is Alex.
Answer 2: I live in SF.

For prompt 2 and prompt 3, they can reuse all KV cache from prompt 1 and avoid the whole computation of prefill.
This feature does not depend on the frontend language, you can directly try the runtime https://github.com/sgl-project/sglang?tab=readme-ov-file#backend-sglang-runtime-srt. You can use OpenAI compatible API and send concurrent requests to the API server.

This feature does not depend on the frontend language
Solves my problem! Thanks~


fixing REGEX OPTION parser

Background
Fixes REGEX OPTION can be parsed anywhere in the SQL including within a STRING literal.
See: #8906 for more details.
Details

only allow single OPTION keyword
only allow OPTION at end of file

Release Note
This PR introduces a backward incompatible change to OPTION keyword parsing. Multiple OPTION keyword is no longer supported.
For SQL such as SELECT * FROM tbl OPTION(k1=v1) OPTION(k2=v2) please use
SELECT * FROM tbl OPTION(k1=v1,k2=v2)

Codecov Report

Merging #8905 (35b7b76) into master (00ec121) will decrease coverage by 54.85%.
The diff coverage is 0.00%.

@@              Coverage Diff              @@
##             master    #8905       +/-   ##
=============================================
- Coverage     69.74%   14.89%   -54.86%
+ Complexity     4681      170     -4511
=============================================
  Files          1808     1761       -47
  Lines         94276    92215     -2061
  Branches      14057    13825      -232
=============================================
- Hits          65756    13738    -52018
- Misses        23956    77489    +53533
+ Partials       4564      988     -3576

Flag
Coverage Δ

integration1
?

integration2
?

unittests1
?

unittests2
14.89% <0.00%> (+0.01%)
:arrow_up:

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

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


Cannot change the location for stopped 3bot instances on deploy3bot.testnet.grid.tf/

Try to change the location for stopped 3bot instance, I got this error

after refresh I changed it normally

I checked the alert. list index out of range.
but can't reproduce it. if you encounter it again can you add the complete url of the chatflow? perhaps the 3bot name was not passed properly to the chatflow.


async/await support for WithUnknownServiceResolvers

Is it possible to resolve unknown type using Tasks? If not I would like to request such feature.

Hi, give me an example.

Prism.Navigation.INavigationService.NavigateAsync resolves Page using IoC container. Everything is OK until when page is resolved using long-running tasks - in my case I need to download page definition using http client. The NavigateAsync has to be called from main thread so while resolving I cannot wait for download to finish because of freezing gui.

I am not sure where to put this async machinery. It should be all the way from Resolve to async delegate in DelegateFactory. I suggest to find the other way around it. Like maybe explicitly Register Tastk<T> as a Wrapper and wrap the page injection in it. But I am not a pro in Prism to know what you control and what not. Here is the doc on custom wrappers: https://bitbucket.org/dadhi/dryioc/wiki/Wrappers#markdown-header-user-defined-wrappers
Or maybe you can use an async proxy or something https://bitbucket.org/dadhi/dryioc/issues/479/async-interception

I would assume that it is a common operation, maybe Prism has some special facility for it?

As far as I know there is no such support but I will check it out


The gpu cost when running finetune/finetune_lora_ds.sh

Hello, may I ask about the gpu cost when running finetune_lora_ds.sh. I have a 49GB*4 machine, however, when I ran the shell, it appeared to be out of memory.

Hi,
Our fine-tuning takes about 24h on 8*A100(80G). I suppose 49G*4 GPU should be ok, referring to Qwen-VL's fine-tuning guide. You may need to reduce the micro-batch-size.

Hi,
Our fine-tuning takes about 24h on 8A100(80G). I suppose 49G4 GPU should be ok, referring to Qwen-VL's fine-tuning guide. You may need to reduce the micro-batch-size.

thanks, when I reduce micro-batch-size to 1, it is ok. I have another question. If I use the parameter max-length,  it is shown "Unknown parameter passed".

The parameters are defined in finetune/finetune_lora_ds.sh, which include --max-length. What is your fine-tuning command?

The parameters are defined in finetune/finetune_lora_ds.sh, which include --max-length. What is your fine-tuning command?

sorry. I tried it again, and there was nothing wrong.


[Feature][python] Add local dev mod runing python integate tests

Search before asking

[X] I had searched in the issues and found no similar feature requirement.

Description
there is package pytest fixture in
https://github.com/apache/dolphinscheduler/blob/5289b09817396046489b28857ad54a85c5ffddb2/dolphinscheduler-python/pydolphinscheduler/tests/integration/conftest.py, which will create docker container for python gateway service, It is perfect in CI but not so comfortable for local dev.
In local dev, we often start the standalone server in IDEA, and test our integrated tests. in this case, we have to comment all content  in conftest.py to skip the package fixture, maybe we should find some way skip this fixture more easiser
Use case
No response
Related issues
No response
Are you willing to submit a PR?

[ ] Yes I am willing to submit a PR!

Code of Conduct

[X] I agree to follow this project's Code of Conduct

I'm going to try to do this optimization

close due to https://github.com/apache/dolphinscheduler/pull/11362


no optional id for autoincrement database objects

Description
IDs in the GraphQL interface are not optional for create methods. The entity has the sea_orm primary key as well as auto_increment=true set.
Steps to Reproduce
Just try it in the examples/postgres
Expected Behavior
input ActorInsertInput {
actorId: Int
firstName: String!
lastName: String!
lastUpdate: String!
}
The actorID should not be neceassry for input. The database or gql server should decide.
Actual Behavior
input ActorInsertInput {
actorId: Int !
firstName: String!
lastName: String!
lastUpdate: String!
}
The actorID is necessary from cli created code.
Reproduces How Often
always
Versions
├── sea-orm v1.0.0
│   ├── sea-orm-macros v1.0.0 (proc-macro)
│   │   ├── sea-bae v0.2.0 (proc-macro)
│   ├── sea-query v0.31.0
│   ├── sea-query-binder v0.6.0
│   │   ├── sea-query v0.31.0 ()
│   ├── sea-orm v1.0.0 ()
Win11, vsCode
Additional Information

Found the solution after a while:
lazy_static::lazy_static! { static ref CONTEXT : BuilderContext = BuilderContext
{
    entity_input: EntityInputConfig {
        insert_skips: vec!["Machine.id".to_string()],
        ..Default::default()
    },
    ..Default::default()
    };
}

inside query_root.rs
So you can skip dedicated columns for Inserts. The database accepts it due to the auto_increment option. in graphql you can ask for the inserted id after you did a create mutation.


Uniform Standards Request: Experimental Repository

Hello!
We believe this repository is Experimental and therefore needs the following files updated:

[x] The Experimental badge https://github.com/tinkerbell/pbnj/pull/12
[x] The Experimental Statement in the README.md https://github.com/tinkerbell/pbnj/pull/12
[x] Getting Started Tutorial
[x] README.md
[x] LICENSE
[x] CI/CD
[x] OWNERS.md
[x] Developer Certificate of Origin
[x] At least one maintainer

If you feel the repository should be maintained or end of life or that you'll need assistance to create these files, please let us know by filing an issue with https://github.com/packethost/standards.
Packet maintains a number of public repositories that help customers to run various workloads on Packet. These repositories are in various states of completeness and quality, and being public, developers often find them and start using them. This creates problems:

Developers using low-quality repositories may infer that Packet generally provides a low quality experience.
Many of our repositories are put online with no formal communication with, or training for, customer success. This leads to a below average support experience when things do go wrong.
We spend a huge amount of time supporting users through various channels when with better upfront planning, documentation and testing much of this support work could be eliminated.

To that end, we propose three tiers of repositories: Private, Experimental, and Maintained.
As a resource and example of a maintained repository, we've created https://github.com/packethost/standards. This is also where you can file any requests for assistance or modification of scope.
The Goal
Our repositories should be the example from which adjacent, competing, projects look for inspiration.
Each repository should not look entirely different from other repositories in the ecosystem, having a different layout, a different testing model, or a different logging model, for example, without reason or recommendation from the subject matter experts from the community.
We should share our improvements with each ecosystem while seeking and respecting the feedback of these communities.
Whether or not strict guidelines have been provided for the project type, our repositories should ensure that the same components are offered across the board. How these components are provided may vary, based on the conventions of the project type. GitHub provides general guidance on this which they have integrated into their user experience.

Done!


feat(plugin): Support custom plugin (#301)

Signed-off-by: Gentleelephant<EMAIL_ADDRESS>feat(plugin): Support custom plugin (#301)

What this PR does / why we need it:
Support plugins not yet supported by fluent-operator.
Which issue(s) this PR fixes:

Fixes #301
Does this PR introduced a user-facing change?

Additional documentation, usage docs, etc.:

I think users need to provide a complete plugin configuration in custom plugin crd like this.
apiVersion: fluentbit.fluent.io/v1alpha2
kind: ClusterInput
metadata:
  name: collectd
  labels:
    fluentbit.fluent.io/enabled: "true"
    fluentbit.fluent.io/component: logging
spec:
  plugin: |
    [INPUT]
        Name         collected
        Listen       <IP_ADDRESS>
        Port         25826
        TypesDB      /usr/share/collectd/types.db,/etc/collectd/custom.db

    [OUTPUT]
        Name   stdout
        Match  *

And the operator just needs to sort all custom plugins and append them to the config file.
And why it needs pluginName and pluginType? Is there any special effect?

I think users need to provide a complete plugin configuration in custom plugin crd like this.
apiVersion: fluentbit.fluent.io/v1alpha2
kind: ClusterInput
metadata:
  name: collectd
  labels:
    fluentbit.fluent.io/enabled: "true"
    fluentbit.fluent.io/component: logging
spec:
  plugin: |
    [INPUT]
        Name         collected
        Listen       <IP_ADDRESS>
        Port         25826
        TypesDB      /usr/share/collectd/types.db,/etc/collectd/custom.db

    [OUTPUT]
        Name   stdout
        Match  *

And the operator just needs to sort all custom plugins and append them to the config file.
And why it needs pluginName and pluginType? Is there any special effect?

@wanjunlei One CR for just one plugin, not multiple plugins inserted into one CR.
We've discussed in https://github.com/fluent/fluent-operator/issues/301#issuecomment-1160171922 and https://github.com/fluent/fluent-operator/issues/301#issuecomment-1246177563


Warning: Failed prop type: Invalid prop style of type array supplied to StyleProvider, expected object.

Hello. Why are StyleProvider not taking the theme, and throwing warning "Failed prop type: Invalid prop style of type array supplied to StyleProvider, expected object."
<template>
<nb-style-provider v-bind:style="getTheme(material)">
<nb-container>
<nb-text>Contact</nb-text>
</nb-container>
</nb-style-provider>
</template>
<script>
import Vue from "vue-native-core";
import {VueNativeBase} from "native-base";
import getTheme from './native-base-theme/components';
import material from './native-base-theme/variables/material';
Vue.use(VueNativeBase);
export default {
data: function() {
 return {
  getTheme: getTheme,
 material: material,
};
},
};
</script>

You'll have to create a separate react component to use theme for now and then import that theme as root component within your vue file.

@neeraj-singh47  Can you provide any example for that ?

@arihantdaga Try this one

@kranopodem  Thank you. Very helpful.


Fix unit tests for pkg/apiserver/registry/stats

Some unit tests were assuming that the clock for the test machine was using the UTC time zone. In my case, the unit tests were failing when run locally.

/test-all


Minecraft Exit Code 0 Crash

Game runs for about 30 seconds each time before crashing with exit code 0
Windows 10 Latest Version
2700x
RTX 2080
16GB Ram
Latest Java and Minecraft Versions
hs_err_pid14452.log

Hi @cream314! Can you please submit this issue over at https://bugs.mojang.com/projects/MC/issues/? The Mojang team will take the first look. Thanks!


MOAR analyzers

I got tired of working on stuff that was being stupid so I wrote these two new analyzers (which will also help tidy up some of the chaotic logging I added while debugging the aforementioned stupidity, so it wasn't all a waste ;))

MEL0004: For improved performance, use pre-compiled log messages instead of calling '[MethodName]' with a string message.
MEL0005: For consistency with logs emitted from other components, use 'PascalCase' for log message tokens.

I also re-numbered them from MEL1-MEL3 to MEL0001-MEL0003 for consistency (most diagnostic IDs are at least 4 digits long)
I promoted them to Error in the below test, they work pretty well:

cc @davidfowl
As a reminder, this package does not ship today, it's purely an "alpha"

I spent like, 10 minutes looking in to writing a code fix for the "use compiled messages" one, and noped out of there ;).

I'm adding support for LoggerMessage.Define and LoggerMessage.DefineScope as well.

Nice work, we should start enabling these in our repositories.

I'll probably be enabling this in some SignalR projects assuming I can merge this before my big PR I'm making there ;). Already using them from my local build.

:up: :date: it now supports LoggerMessage.Define (for checking format tokens and parameter counts match up with Generic parameters)

:up: :date: feedback addressed


Markdown/pandoc support

Thanks for this fantastic workflow!
I was wondering whether you would consider adding support for pandoc/markdown style citatations. This way, in addition to copying 'citation' and 'bibliography', there would be an option to copy the 'Citation key' (preferably prefixed by an "@").
There is a different workflow implementing something similar for Bibdesk (https://www.zvi-biener.org/tech-blog/searching-bibdesk-with-alfred), if it is not clear by my description what I am requesting.
Best regards,
Tormod Bøe

+1 pandoc support would be very nice

would also appreciate it very much

but lacking Better Bibtex support makes it less useful in my daily work

Feel free to add the feature and submit a pull request.

Would code from this workflow be useful? https://github.com/alanzchen/zotero-better-bibtex-alfred
Thanks for your work on Zothero, it's amazing, as the others I'm just missing access to citekeys...

Would code from this workflow be useful?

Afraid not. That workflow works in a fundamentally different way to this one.

Instead of adding support for the plugin, could it be a workaround to create a CSL that generates citekeys (or tweak that one: https://github.com/citation-style-language/styles/blob/master/bibtex.csl)?


Marker refactor

remove cumbersome synchronization between Marker and LabelExplorerComponent, instead use immutable "selections" property
add DrawingContext
add SliceSelectionType enum
add "immutable" package (https://facebook.github.io/immutable-js/)
immutable > mutable
add "downlevelIteration" in tsconfig.json
change strategy detection of LabelExplorerComponent to OnPush
validation page is used nowhere and after this commit it can become broken
disable context menu when right click on canvas
fix zoom (before scroll didn't appear while zooming)

@piotrwalkusz1, will you be able to resolve these conflicts in the next few days? Probably some minor things 😉


Update DynWrapX + landing User Hunter

This PR updates Dynamic Wrapper X to 2.1. This version has a lot more functionality and will be incredibly useful for further implant development.
I'm also tossing in User Hunter functionality. The implant doesn't support searching for a specific user or group (yet), but this will return all currently logged in users on the domain and WHERE they are logged in at. Grep for DA and you're in business.
EDIT: http://dynwrapx.script-coding.com/dwx/pages/dynwrapx.php?lang=en

Also, tested the mimikatz implant and everything still good.

And I'm too lazy to use version control correctly, so here's what I've got on User Hunter  ¯\_(ツ)_/¯


Use a shared varuint bit-packed type for some built-ins initdata fields

Using a varuint is more workable than bumpint bit counts as they're reached. This is especially true when there are builds with stripped built-ins and also builds with a lot of user-defined custom built-ins.

Frequency for current varuint inputs (up to 255) and encoding efficiency:
[238, 49, 22, 12, 8, 7, 5, 3, 4, 4, 4, 5, 4, 6, 2, 2, 6, 4, 3, 2, 1, 5, 3, 3, 1, 4, 4, 2, 1, 4, 2, 2, 3, 3, 3, 4, 3, 2, 1, 1, 0, 0, 0, 0, 1, 1, 0, 0, 2, 2, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
varuint efficiency: 4.230088 bits/value

This should be more efficient footprint-wise also because fixed bit counts are relatively inefficient when the whole range is not always needed. Let's see if that's the case in practice.

Seems to work, around -200 bytes for x64 defsize.


Please add me to the organisation

Description
I'll join the fun, if you'll let me 🥺

@ugglr Suggestion: change the label to invite me to the organization. see #21. Then @eddiejaoude might see this sooner.

Oops, sorry @ugglr I did miss this. Thank you @AllanRegush 👍
I will send you an invite now 🎉

Sent 🎉


Remove .el7 from release name

This PR fixes #144969
Packages are compatible with RHEL 7,8,9 not just 7. It is pointless to keep .el7 in the naming system, removing it will match other Microsoft RPM-packaged products such as the Edge browser

Please reconsider this PR or explain why it was rejected as it fixes #144969.


Change filed type to choice field of tax rate in product

I want to merge this change because resolve #2829

Screenshots

Pull Request Checklist

[x] Privileged views and APIs are guarded by proper permission checks.
[x] All visible strings are translated with proper context.
[x] All data-formatting is locale-aware (dates, numbers, and so on).
[x] Database queries are optimized and the number of queries is constant.
[x] Database migration files are up to date.
[x] The changes are tested.
[x] The code is documented (docstrings, project documentation).
[x] GraphQL schema and type definitions are up to date.
[x] Changes are mentioned in the changelog.

Front end reports full okayness.


feat: support activation dynamo converters

Description
Support activation dynamo converters, including relu, sigmoid, tanh, leaky_relu, elu, selu, softplus, clip, hardsigmoid.
Fixes #2201
Type of change

New feature (non-breaking change which adds functionality)

Checklist:

[x] My code follows the style guidelines of this project (You can use the linters)
[x] I have performed a self-review of my own code
[x] I have commented my code, particularly in hard-to-understand areas and hacks
[ ] I have made corresponding changes to the documentation
[x] I have added tests to verify my fix or my feature
[x] New and existing unit tests pass locally with my changes
[x] I have added the relevant labels to my PR in so that relevant reviewers are notified

@gs-olive Oh I didn't even know this before. I guess that's the problem! thanks! updated the code!

@zewenli98 - sure, no problem! I think since the gelu converter was removed in this PR, we also need to skip those converter tests, so you can either add a pytest skip decorator or remove/comment the code.


Whitespace around re-ordered class properties and constants is incorrect

Anecdotally I'm noticing that this:
class Foo
{
    protected $foo = 'bar';
    public $bar = 'baz';
    public const FOO = 'bar';
    protected $bar = 'baz';
}

Is formatted to this:
class Foo
{
    public const FOO = 'bar';
    public $bar = 'baz';

    protected $foo = 'bar';
    protected $bar = 'baz';
}

The whitespace around/between properties and constants that get reordered isn't always consistent. Happy to work on this myself when I have time next week.

The spacing is from TLint's OneLineBetweenClassVisibilityChanges

Class members of differing visibility must be separated by a blank line

Sorry I should have been more specific—what's weird to me is that there isn't whitespace added after the public CONST. I would have expected either of these instead:
class Foo
{
    public const FOO = 'bar';
    public $bar = 'baz';
    protected $foo = 'bar';
    protected $bar = 'baz';
}

class Foo
{
    public const FOO = 'bar';

    public $bar = 'baz';

    protected $foo = 'bar';
    protected $bar = 'baz';
}

Basically I want the formatter to fix all the whitespace for me, including in between consts and properties 😂

Right now, OneLineBetweenClassVisibilityChanges doesn't distinguish between const/properties, it only looks at visibility changes.  I think we would need an additional linter/formatter for class attribute groups, something like OneLineBetweenClassAttributeGroups.
Pint's Laravel preset uses class_attributes_separation to add a blank line between most:
'class_attributes_separation' => [
    'elements' => [
        'const' => 'one',
        'method' => 'one',
        'property' => 'one',
        'trait_import' => 'none',
    ],
],

We overwrite this to only require a blank line between method.  I'm wondering if we should follow the laravel convention on this as well.
class Foo
{
    public const FOO = 'bar';

    public $bar = 'baz';

    protected $foo = 'bar';

    protected $bar = 'baz';
}

Fixed in https://github.com/tighten/tlint/pull/369


refactor(request): show user-friendly type for c.req.param()

Before

After

The author should do the following, if applicable

Add tests

The tests we have now are sufficient.

[x] Run tests
[x] bun denoify to generate files for Deno
[x] bun run format:fix && bun run lint:fix to format the code

@yusukebe How about this?

@usualoma
Looks good to me!
Let's merge. But right now, shall we merge it into the next?

@yusukebe  Understood!
Merged next into this branch.

@usualoma
Yeah. denoify is no longer needed! Merging.


Modularize finding and sampling extracts

Classic convplot can take an array of uids (found by the user in some way), or if not given this, it will sample n uids.
For modularity and usability it will be good to break this sampling functionality out of convplot. This generates a natural pair of functions, both of them with a set of uids as output:
finding data
find_extracts(): a general tool for finding (sets of) utterances based on a set of parameters
Reasonable things to look for might be:

utterance %in% c("ja", "nee", "oh")
rank < 10
FTO > 2000
produced in overlap
overlapped by another turn
sequential properties, e.g. bookended by turns from other; forming a streak (i.e. prior turn by self is same turn format; following a turn with a question mark by other

sampling data
sample_extracts(): a general tool to sample (sets of) utterances based on a set of parameters
Reasonable sampling variables would be:

n (how many extracts to sample)
weighting (whether to privilege sample diversity or proportionality — e.g. to avoid overrepresentation of larger sources or corpora)
participation (dyadic, triadic, other)

(I will return to fill out this issue with more details as I think about it)

Popular use cases would be:

searching for some content, e.g. top token, words..
searching for a dialog act/ action.
For the latter, wouldn't it be cool if users can also use "sequential search" here?

Ah yes, I was just editing the issue to add a bit more detail, including sequential detail. Searching for dialog acts presumes a data format that has this as a column — I think the sky is the limit really and one should be able to filter & display extracts based on whatever columns exist or have been created.


Fixing IDENTITY-4071, by considering the tenant domain appended to is…

…suer_id to populate SP tenant domain

Please hold this commit without merging for a moment. There seems to be a regression with the fix.


Rancher 2.6-HEAD - Private registry support on cluster update from cluster revision templates still broken

https://github.com/rancher/rancher/pull/37606/files
Repro:

Create RKE Template with 1 private registry
Apply RKE Template to a Cluster
Modify RKE Template and add a second registry or modify the old and make sure override is disabled
New Registry won't be applied

Code Issue
Loading old registry details from cluster into registryMap:
https://github.com/rancher/rancher/blob/c4d59fa88e2313e1446ba542a21c39e15a17f375/pkg/api/norman/store/cluster/cluster_store.go#L436-L440
Old registry details from cluster are used to override the new private registry details in dataFromTemplate
Settings from the cluster template revision in dataFromTemplate are gone and old credentials are used
https://github.com/rancher/rancher/blob/c4d59fa88e2313e1446ba542a21c39e15a17f375/pkg/api/norman/store/cluster/cluster_store.go#L518-L525
@jiaqiluo Could you have a look?

hi @zerotens  In your case of editing an existing cluster, the values already applied to the cluster take precedence over the ones in the cluster template. So what you see is the expected result.

Hi @jiaqiluo,

hi @zerotens In your case of editing an existing cluster, the values already applied to the cluster take precedence over the ones in the cluster template. So what you see is the expected result.

So editing the private registry is not possible anymore? Are you totally sure?
I really don't think this is the wanted behaviour and does not make any sense to me.

@zerotens  To change the private registry of an existing cluster, you can edit the cluster and change the values, instead of changing the cluster template.

@zerotens To change the private registry of an existing cluster, you can edit the cluster and change the values, instead of changing the cluster template.

@jiaqiluo not if the cluster was created by an RKE1 Template and the values are not selected to be overriden in the rke template section.
Then you can't set the values on the Edit Cluster Page and the bug occurs.

@zerotens  I was wrong about the precedence: in fact, the values from the cluster template will overwrite whatever the values the user set. I just tested in a 2.6.3  setup: although the UI still doesn't allow me to change the value, the backend actually applies the new values from the new template revision.

@zerotens I was wrong about the precedence: in fact, the values from the cluster template will overwrite whatever the values the user set. I just tested in a 2.6.3 setup: although the UI still doesn't allow me to change the value, the backend actually applies the new values from the new template revision.

@jiaqiluo

I think this could be a UI bug where after the field is changed to editable in the cluster template revision, UI still does not show the field as ediable.

Ok if you set the field to be editable then it would work and edit the cluster manually then it would work.
Actually private registries would be then the only values you can't update this way in cluster revision templates, due to the logic you implemented.
Everything else and also every other overrideable value can be done via default values from the cluster revision template.
What speaks against making private registries behave like every other value?

I think I figured out what happens here: the problem comes from the UI, not the backend.
Currently, when we click and open the edit page of an RKE cluster, the UI will GET the cluster object from the backend and show the applied values of the cluster in the UI; If we select a new RKE cluster template revision, UI will not update the values it shows, in other words, it will keep the applied values and ignore the ones in the cluster template revision.   Now if we click the save button, none of the new values from the new cluster template revision will be applied because UI sends the old existing applied values back to the backend.
In the case where the field was allow user overwrite original but not in the new revision, UI will drop that field's value when it sends the PUT request to the backend.
I kind of understand why the UI behaves this way: because UI does not know if user has changed the currently showing values or not, instead of losing users' modifications,  it decides to preserve whatever the current values are.
However, this causes 2 problems:

new values in the new cluster template revision are not applied
if the field is not marked as allow user overwrite, user will never have the chance to correct the value even if he knows what the new value is

I will bring this issue to the team.

@jiaqiluo
Thank you very much for looking into this deeply.
Depending on my free time i will try something out and if it works i will create an PR.

@jiaqiluo
I created an pull request which fixes my use case.
But you are totally right there is more broken in case the old cluster template revision and the newly selected revision have changes in the override options.
Those overrides won't be shown because the web ui does not ask the server what override options are enabled for the selected cluster template revision.

Root cause
For REK clusters that are created from a cluster template revision,  the private registry info ( url, username, or password) from the existing cluster is always used when updating the cluster, this causes the problem in this very specific scenario: if the private registry info is changed in the newly-applied cluster template revision AND those fields are not marked as "allow user override", the new values will never be applied.
What was fixed, or what changes have occurred
The private registry info from the existing cluster is used only when the "allow user override" is enabled for the private registry info in the cluster template revision; otherwise, apply the values from the revision.
Areas or cases that should be tested
updating the existing rke cluster in the above-mentioned scenario.
What areas could experience regressions?
The private registry setting on the RKE cluster.
Are the repro steps accurate/minimal?
yes

Verified on v2.6-head https://github.com/rancher/rancher/commit/79a3bcba901add6249cfbb6d9d4961599553f8da.
ENVIRONMENT DETAILS

Rancher HA
Rancher version:

Verified version v2.6-head https://github.com/rancher/rancher/commit/79a3bcba901add6249cfbb6d9d4961599553f8da

Browser: Chrome

TEST RESULT
PASS
VERIFICATION STEPS

Setup Rancher and login to the UI in a browser.
Created a standard user and login to Rancher as that user.
Go to Cluster Management and created a new downstream node driver RKE1 cluster.

When creating, in the Private Registry section, checked Enabled:

After the cluster successfully provisions, edit the config and head back to Private Registry. Create test values in url, user and password.
Verified that the new registry settings were properly set:

Cluster, correctly, shows as not Active due to me putting test values that are not recognizable. But the issue of the options not staying has been verified to be addressed, so closing this issue.


Add Slack functionality inside logger

Problem
In the ingestion_server codebase, calls to log functions like log.info and log.error are generally followed by sending the same information to Slack using the wrapper. This can be solved in a more elegant way by making Slack itself a logging destination within the Python logging framework.
Description

Integrating Slack with the logging configuration means that

we won't have to invoke Slack everywhere manually
Slack can make use of Pythonic log levels and other utilities like formatters

Alternatives

We can either roll with a homemade solution or use something like https://github.com/mathiasose/slacker_log_handler.
Implementation

[ ] 🙋 I would be interested in implementing this feature.

Hi @dhruvkb ,
This issue seems to be a good initiation of my journey towards contribution to FOSS projects.
Can you please assign this to me?

Sure @Akshat977, assigned to you! If you need help getting started, leave a comment here or you can join us in the #openverse channel in the Making WordPress Slack workspace.

@krysal Can you please assign this issue to me?

@sayefiqb assigned this to you. You can definitely work on it!

Hii @dhruvkb how to contribute into these open source projects

Hi @starksid, to contribute you can refer to the following two documents.

The quickstart guide will help you clone and set up the project locally.
The Contributing section contains tips on how to contribute to the project.

To solve this particular issue, you would need familiarity with Python, specifically the logging framework in Python.

Thanks Dhruv
I am familiar with python but not understanding how these codebases are
running can you please guide what should i do? I just know about data
structures and algorithms and dbms
On Tue, 21 Feb 2023 at 4:24 AM, Dhruv Bhanushali @.***>
wrote:

Hi @starksid https://github.com/starksid, to contribute you can refer
to the following two documents.

The quickstart guide
https://wordpress.github.io/openverse-api/guides/quickstart.html
will help you clone and set up the project locally.
The Contributing
https://github.com/WordPress/openverse-api#contributing section
contains tips on how to contribute to the project.

To solve this particular issue, you would need familiarity with Python,
specifically the logging framework in Python.
—
Reply to this email directly, view it on GitHub
https://github.com/WordPress/openverse-api/issues/717#issuecomment-1437645812,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AYM7I77O32DY7CKWNE6UBEDWYPY3BANCNFSM5WRJRZEQ
.
You are receiving this because you were mentioned.Message ID:
@.***>

@starksid to resolve this particular issue, you should start by learning about Python's logging module. That is the standard way to write logs in Python and this project uses that as follows:
https://github.com/WordPress/openverse-api/blob/6efd9f9d624deb972f987ed932ea68a100781287/ingestion_server/ingestion_server/indexer.py#L19
A good way to learn about Python logging is their tutorial.
Once you're familiar with the logging module, the next step would be to define our own log handler that can send the events that are being logged to Slack. A helpful tutorial to define our own handler is in the "cookbook" (also present in Python's very helpful docs).
Ping us when you've done the reading and we'll help you with the next steps.


Token is generated but the set command causes ESP8266 to crash

I have a sample set command issued after token generation but the command not only fails but also crashes the ESP8266.
I confirm that this is not related to firebase rules or anything on the firebase.
Actually this has worked forever until I upgraded the WiFiManager by tzapu. I can modify the WiFiManager header but have no clue what is the root cause of the problem.
Any idea what is causing this problem?
Here is the serial output
17:07:42.263 -> *wm:StartAP with SSID:  CXXXXX84
17:07:43.295 -> *wm:AP IP address: <IP_ADDRESS>
17:07:43.295 -> *wm:Starting Web Portal
17:08:25.639 -> *wm:8 networks found
17:08:34.320 -> *wm:8 networks found
17:08:43.362 -> *wm:Connecting to NEW AP: XXXX-79
17:08:43.487 -> *wm:connectTimeout not set, ESP waitForConnectResult...
17:08:46.714 -> *wm:Connect to new AP [SUCCESS]
17:08:46.714 -> *wm:Got IP Address:
17:08:46.714 -> *wm:<IP_ADDRESS>
17:08:46.714 -> Should save config
17:08:47.719 -> *wm:config portal exiting
17:08:47.719 -> Connected.
17:08:49.237 -> Token info: type = id token (GITKit token), status = on request
17:08:50.585 -> Token info: type = id token (GITKit token), status = ready
17:08:50.990 -> path is : /fazz/f0bd84
17:08:58.626 ->
17:08:58.626 ->  ets Jan  8 2013,rst cause:4, boot mode:(3,6)
17:08:58.626 ->
17:08:58.626 -> wdt reset
Here is the code....
// ADDED firebase credentials
// Define Firebase objects
FirebaseData firebaseData;
FirebaseAuth auth;
FirebaseConfig config;
init_fb();
delay(100);
path="/fazz/"+uniqueID;
Serial.println("path is : " + path);
if(Firebase.RTDB.setBool(&firebaseData, path, true))
{
Serial.println("Set fazz success");
}else{
firebaseData.errorReason().c_str();
}

https://github.com/mobizt/Firebase-ESP-Client?tab=readme-ov-file#memory-options


Pool slot array for ImMap and ImHashMap in caches and scope

Did a pooling for Scope item maps, get a small memory gain.

Did a pooling for Scope item maps, get a small memory gain.

Reverted in Scope pooling to fix #205 NRE


Python36\python -m nuitka --follow-imports --windows-dependency-tool=pefile --experimental=use_pefile_recurse main.pyw
←[91mNuitka-Scons:WARNING: Didn't find ccache for C level caching, follow Nuitka user manual description.
←[0mNuitka-Scons:INFO: Slow C compilation detected, used 60s so far, this might indicate scalability problems.
Nuitka-Scons:INFO: Running 'gcc -o "module.View.main_window.o" -c -std=c11 -fwrapv -ftrack-macro-expansion=0 -fpartial-inlining -fno-var-tracking -O3 -pipe -D_WIN32_WINNT=0x0501 -D_NUITKA_EXPERIMENTAL_USE_PEFILE_RECURSE -D_NUITKA_SYSFLAG_BYTES_WARNING=0 -D_NUITKA_SYSFLAG_NO_SITE=0 -D_NUITKA_SYSFLAG_VERBOSE=0 -D_NUITKA_SYSFLAG_UTF8=0 -D_NUITKA_SYSFLAG_OPTIMIZE=0 -D_NUITKA_SYSFLAG_NO_RANDOMIZATION=0 -D__NUITKA_NO_ASSERT__ -DMS_WIN64 -D_NUITKA_CONSTANTS_FROM_RESOURCE -D_NUITKA_FROZEN=0 -D_NUITKA_EXE -IE:
...etc

There are whole hudge cards of long continous lines..
Regarding the previous version as belong this was more friendly around:
Nuitka:INFO:PASS 1:
Nuitka:INFO:Initial optimization pass.
Nuitka:INFO:Optimizing module '__main__', 0 more modules to go after that.
Nuitka:INFO:Doing module local optimizations for '__main__'.
Nuitka:INFO:Next global optimization pass.
Nuitka:INFO:Optimizing module '__main__', 0 more modules to go after that.
Nuitka:INFO:Doing module local optimizations for '__main__'.
Nuitka:INFO:PASS 2 ... :
Nuitka:INFO:Next global optimization pass.
Nuitka:INFO:Optimizing module '__main__', 0 more modules to go after that.
Nuitka:INFO:Doing module local optimizations for '__main__'.
Nuitka:INFO:Total memory usage before running scons: 23.61 MB (24756224 bytes):

Regarding the Nuitka-GUI - proposal
https://github.com/Nuitka/NUITKA-Utilities/issues/8#issuecomment-481046586
I sugessting something like this: PROFILE as Compilator PROFILE Settings (it's due to proposed convention for GUI where settings are for GUI and other)
Nuitka:COMPILER:start:2020-09-29 17:00:11
Nuitka:INFO:version:<IP_ADDRESS>
Nuitka:INFO:Python: 3.6.8
Nuitka:INFO:Platform: Windows-7-6.1.7601-SP1
Nuitka:PROFILE:compiler:mingw
Nuitka:PROFILE:output:my_app.exe
Nuitka:PROFILE:full-compat:true
...etc
Nuitka:INFO:PASS 1:
Nuitka:INFO:Initial optimization pass.
Nuitka:INFO:Optimizing module '__main__', 0 more modules to go after that.
Nuitka:INFO:Doing module local optimizations for '__main__'.
Nuitka:INFO:Next global optimization pass.
Nuitka:INFO:Optimizing module '__main__', 0 more modules to go after that.
Nuitka:INFO:Doing module local optimizations for '__main__'.
Nuitka:INFO:PASS 2 ... :
Nuitka:INFO:Next global optimization pass.
Nuitka:INFO:Optimizing module '__main__', 0 more modules to go after that.
Nuitka:INFO:Doing module local optimizations for '__main__'.
Nuitka:INFO:Total memory usage before running scons: 23.61 MB (24756224 bytes):

Not sure is good to start like Nuitka:I sounds bether to use timestamp
It's good to grab start_time and end_time of compilation to offer in final log Compilation_time
2020-09-29 17:44:33;INFO:Doing module local optimizations for '__main__'.
2020-09-29 17:44:35;INFO:Total memory usage before running scons: 23.61 MB (24756224 bytes):
2020-09-29 17:44:35;INFO:Compilation time: 00:40:00

This all can be usfeull in colab and logs analyse.

The logging is undergoing big changes in the past release cycle and more to come.
I am changing Nuitka from silent by default to informative by default. The scons warning is there to make it easy to recognize for users, what action took so long. You not having installed a C caching tool is a warning now. Slow compilations with silence from Nuitka were frequently causing confusion. Nuitka therefore now announces this. The long lines are there, because it's hard to get back from these to the original command, and it's different for Windows and non-Windows, and that's more work than I wanted to initially spend on this. For now it serves the purpose, as the module name (more or less uniquely) can be found in there.
I am going to add more outputs about the final product, its useability, etc. in future releases. I am going to live with it being broken for a while. This is not actionable itself, but it's a line of action for Nuitka development to improve this. Still closit it though, there is no clear direction in this issue.


Missing ftestlist

Expecto provides ftestlist allowing to focus on a group of test at once.
https://github.com/haf/expecto#focusing-tests
open Expecto

[<Tests>]
let focusedTests =
  testList "unfocused list" [
    ftestList "focused list" [
      testCase "will run" <| fun () -> Expect.equal (2+2) 4 "2+2"
      ftestCase "will run" <| fun () -> Expect.equal (2+2) 4 "2+2"
      test "will run" { Expect.equal (2+2) 4 "2+2" }
    ]
    testList "unfocused list" [
      testCase "skipped" <| fun () -> Expect.equal (2+2) 1 "2+2?"
      ftestCase "will run" <| fun () -> Expect.equal (2+2) 4 "2+2"
      test "skipped" { Expect.equal (2+2) 1 "2+2?" }
      ftest "will run" { Expect.equal (2+2) 4 "2+2" }
    ]
    testCase "skipped" <| fun () -> Expect.equal (2+2) 1 "2+2?"
  ]

Qhh! Sorry for this, will fix tonight!

done! Will be part of the next release!


Nerf XP slightly

level 7 should be more expensive

levels 10-12 should be increased by ~30k

Fixed here https://github.com/slafniy/DedTunedProject/commit/0ce5eece4feab62cffa73a76aa44b4d185cffe61


Issue with Headwind Extension in Next.js Project

I've been using the Headwind extension successfully! After completing my React studies, I tried to apply Tailwind CSS to a Next.js project, but oh my. I've discovered that Headwind's functionality isn't working in my Next.js project! I even tried it on another computer, and it still didn't apply to the Next.js project files. I'm curious if this issue is just a bug or if Next.js doesn't support it yet!

It works perfectly fine with Next. I've been using it in all my projects. don't forget to run the headwind command to initialize. Every time you close vs code you must rerun the command.

Thanks! your comment is helpful for me!
And Can you tell me the command please?

Thanks! your comment is helpful for me! And Can you tell me the command please?

Check the extension page inside VS Code. You can find the command there. I've created an auto-run for this command so I don't remember now the keys ...


Flooding log file

I installed this plugin because it provides an easy way to check my log file, but it seems that the plugin itself creates so many entries that it is hard to filter out the useful lines. Secondly, the timestamp on the entries from this plugin is off with 2 hours (not adjusting for time zone and DST).

The default logging should not be very verbose at all. Do you have DEBUG=* set?


Can't add UUID Scalar

I'm trying to add uuid:Uuid and chrono::NativeDateTime scalar extensions to my project. In both cases I've been unable to due to compiler warnings:
use async_graphql::{InputValueError, InputValueResult, ScalarType, Value};
use async_graphql_derive::Scalar;
use uuid::Uuid;

#[Scalar]
impl ScalarType for Uuid {
    fn parse(value: Value) -> InputValueResult<Self> {
        match value {
            Value::String(s) => Ok(Uuid::parse_str(&s)?),
            _ => Err(InputValueError::ExpectedType(value)),
        }
    }

    fn to_value(&self) -> Value {
        Value::String(self.to_string())
    }
}

error[E0117]: only traits defined in the current crate can be implemented for arbitrary types
 --> api/src/graphql_schema/scalar_extensions.rs:6:1
  |
6 | impl ScalarType for Uuid {
  | ^^^^^^^^^^^^^^^^^^^^----
  | |                   |
  | |                   `uuid::Uuid` is not defined in the current crate
  | impl doesn't use only types from inside the current crate
  |
  = note: define and implement a trait or new type instead

This is basically identical to the current Uuid Scalar except using a version compatible with Diesel 1.4.5. Any recommendations would be swell

This is because of the Rust orphan rule, and you need new type to solve this problem.
Actually async-graphql has implemented the UUID scalar, which you can use directly.

I know it has implemented the UUID scalar, but diesel 2.0 isn't official yet and 1.4.5 is incompatible with0.8.1 and so that forces me onto 0.7.4 which doesn't implement that trait due to the version mismatch. My goal is to be able to have #[SimpleObject]s that derive Queryable and that use chrono::NaiveDateTime because that has the Diesel ToSql/FromSql traits. I'm struggling to see how I can unify this such that I use types compatible with both diesel and async-graphql

Would newtype_derive be a viable option here? Surely type unity with Diesel is a common use case?

struct MyUuid(uuid::Uuid);

#[Scalar]
impl MyUuid {
   ....
}

https://github.com/Ixrec/rust-orphan-rules

I tried that approach before I made the post. After reapplying this I ran into the problem I was trying to avoid:
error[E0277]: the trait bound `scalar_uuid::ScalarUuid: diesel::Queryable<diesel::sql_types::Uuid, diesel::pg::Pg>` is not satisfied
  --> api/src/graphql_schema/mutation_root.rs:23:51
   |
23 |       diesel::insert_into(workspaces).values(doc).get_result::<Workspace>(&conn)
   |                                                   ^^^^^^^^^^ the trait `diesel::Queryable<diesel::sql_types::Uuid, diesel::pg::Pg>` is not implemented for `scalar_uuid::ScalarUuid`
error[E0369]: binary operation `==` cannot be applied to type `scalar_uuid::ScalarUuid`
  --> api/src/data/workspace.rs:44:3
   |
44 |   pub uuid: ScalarUuid,
   |   ^^^^^^^^^^^^^^^^^^^^
   |
   = note: an implementation of `std::cmp::PartialEq` might be missing for `scalar_uuid::ScalarUuid`
   = note: this error originates in a derive macro (in Nightly builds, run with -Z macro-backtrace for more info)

I'm looking into doing this via newtype_derive + custom_derive now

It looks like you need to implement PartialEq<uuid::UUID> for ScalarUuid.

Ok it looks like newtype_derive preserves most of the behavior but there doesn't seem to be any way to have a wrapper type without needing to reimplement diesel::Queryable<diesel::sql_types::Uuid, diesel::pg::Pg>. I'm not really sure what my options are here that allow me to avoid reimplementing diesel traits
use async_graphql::{InputValueError, InputValueResult, ScalarType, Value};
use async_graphql_derive::Scalar;

use uuid::Uuid;

#[derive(Copy, Clone, Debug, PartialEq)]
pub struct ScalarUuid(Uuid);

#[Scalar(api, name = "UUID")]
impl ScalarType for ScalarUuid {
    fn parse(value: Value) -> InputValueResult<Self> {
        match value {
            Value::String(s) =>
              Ok(ScalarUuid(Uuid::parse_str(&s)?))
            ,
            _ => Err(InputValueError::ExpectedType(value)),
        }
    }

    fn to_value(&self) -> Value {
        Value::String(self.0.to_string())
    }
}

NewtypeFrom! { () pub struct ScalarUuid(Uuid); }
NewtypeDeref! { () pub struct ScalarUuid(Uuid); }

error[E0277]: the trait bound `scalar_uuid::ScalarUuid: diesel::Queryable<diesel::sql_types::Uuid, diesel::pg::Pg>` is not satisfied
  --> api/src/graphql_schema/mutation_root.rs:23:51
   |
23 |       diesel::insert_into(workspaces).values(doc).get_result::<Workspace>(&conn)
   |                                                   ^^^^^^^^^^ the trait `diesel::Queryable<diesel::sql_types::Uuid, diesel::pg::Pg>` is not implemented for `scalar_uuid::ScalarUuid`
   |
   = note: required because of the requirements on the impl of `diesel::Queryable<(diesel::sql_types::Integer, diesel::sql_types::Uuid, diesel::sql_types::Integer, diesel::sql_types::Nullable<diesel::sql_types::Text>, diesel::sql_types::Timestamp, diesel::sql_types::Timestamp), diesel::pg::Pg>` for `(i32, scalar_uuid::ScalarUuid, i32, std::option::Option<std::string::String>, chrono::NaiveDateTime, chrono::NaiveDateTime)`
   = note: required because of the requirements on the impl of `diesel::Queryable<(diesel::sql_types::Integer, diesel::sql_types::Uuid, diesel::sql_types::Integer, diesel::sql_types::Nullable<diesel::sql_types::Text>, diesel::sql_types::Timestamp, diesel::sql_types::Timestamp), diesel::pg::Pg>` for `data::workspace::Workspace`
   = note: required because of the requirements on the impl of `diesel::query_dsl::LoadQuery<_, data::workspace::Workspace>` for `diesel::query_builder::InsertStatement<schema::workspaces::table, diesel::query_builder::ValuesClause<(diesel::insertable::ColumnInsertValue<schema::workspaces::columns::name, diesel::expression::bound::Bound<diesel::sql_types::Nullable<diesel::sql_types::Text>, std::string::String>>, diesel::insertable::ColumnInsertValue<schema::workspaces::columns::ownerId, diesel::expression::bound::Bound<diesel::sql_types::Integer, i32>>), schema::workspaces::table>>`

This is really a troublesome problem. Let me add a feature to let async-graphql use uuid 0.7.4 so that there will be no such problems.

Can this solve your problem?
diesel = { version = "1.4.4", features = ["uuidv07"] }

That’s what solved my ability to make a derive insertable struct but in doing so I was faced with this incompatibility and I have the same issue with chrono::NaiveDateTime as that’s what has the diesel traits implemented. If I upgrade to 0.8.1 then it breaks diesel unless I use the unreleased 2.0.0 from master, though when I had tried as much I’d been faced with challenges around diesel-derive-enum and diesel_full_text_search. I think for now it makes sense to stay 1.4.5 until those have all been officially released but in doing so that limits uuid to 0.7.4 which lacks compatibility. As I see it now it would so appear that either both these would need be implemented in your crate or anyone using diesel will need to do new type wrappers that implement all the traits. It would be really slick if one could derive queryable/insertable on object/simple object and have it just magically work.
Sent from my iPhone

On Aug 14, 2020, at 1:41 AM, Sunli<EMAIL_ADDRESS>wrote:

Can this solve your problem?
diesel = { version = "1.4.4", features = ["uuidv07"] }
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or unsubscribe.

Here's my stopgap solution:
use async_graphql::{InputValueError, InputValueResult, ScalarType, Value};
use async_graphql_derive::Scalar;

use diesel::deserialize::{self, FromSql};
use diesel::pg::{Pg};
use diesel::serialize::{self, IsNull, Output, ToSql};
use uuid::Uuid;

use std::io::prelude::*;

#[derive(Copy, Clone, Debug, PartialEq, AsExpression, FromSqlRow, SqlType)]
#[postgres(type_name="uuid")]
pub struct ScalarUuid(Uuid);

#[Scalar(api, name = "UUID")]
impl ScalarType for ScalarUuid {
    fn parse(value: Value) -> InputValueResult<Self> {
        match value {
            Value::String(s) =>
              Ok(ScalarUuid(Uuid::parse_str(&s)?))
            ,
            _ => Err(InputValueError::ExpectedType(value)),
        }
    }

    fn to_value(&self) -> Value {
        Value::String(self.0.to_string())
    }
}

NewtypeFrom! { () pub struct ScalarUuid(Uuid); }
NewtypeDeref! { () pub struct ScalarUuid(Uuid); }

impl FromSql<diesel::sql_types::Uuid, Pg> for ScalarUuid {
    fn from_sql(value: Option<&[u8]>) -> deserialize::Result<Self> {
      let bytes = not_none!(value);
      let uuid: deserialize::Result<uuid::Uuid> = uuid::Uuid::from_slice(bytes).map_err(Into::into);
      Ok(ScalarUuid(uuid?))
    }
}

impl ToSql<diesel::sql_types::Uuid, Pg> for ScalarUuid {
    fn to_sql<W: Write>(&self, out: &mut Output<W, Pg>) -> serialize::Result {
      out.write_all(self.0.as_bytes())
        .map(|_| IsNull::No)
        .map_err(Into::into)
    }
}

Actually it looks like this change can in fact address the issue:
diesel = { version = "1.4.4", features = ["uuidv07"] }
To make this work I had to cargo clean and reset Cargo.lock and in doing so 0.8.1 was used throughout.


Can't configure which folder (d)mypy is run from

Mypy seems to have problems with Django projects containing multiple apps, not being able to follow imports to the other apps when running from the root directory. I've already filed a ticket with mypy itself about this, but there's no answer there yet.
A workaround I've found using the console that when I cd into the main source folder instead of the project root and list all apps manually, the imports work as expected. However, that's not possible with the mypy plugin, and I hate having to switch out of my IDE just for running mypy when a plugin already exists - adding the option to choose where to run mypy from should be easy to configure. I've already tried appending cd <foldername>; to the mypy command, but that doesn't work (error: The system cannot find the path specified.). It works just fine if the command field only contains the cd command, without mypy, but combining both doesn't work.
The reason why the project root is not the source root in my case is that I have a multilanguage project (Python / Django for the backend, Typescript / ReactJS for the frontend).

You can get around this by using PYTHONPATH=/path/to/src mypy .. That way you're still running mypy from the project directory, but since your source directory is added to PYTHONPATH each app can be imported. Another possibility is using bash -c "cd /path/to/src mypy .", which lets you run mypy in the source directory. Unfortunately the latter breaks the functionality where you can click on errors in the plugin panel to navigate to the correct place in the code, presumably because the paths are expected to be relative to the project root. Even forcing the paths to be absolute with --show-absolute-path doesn't fix this.

I ended up writing a bash script which I can run using run configurations, but thanks anyways!


fix empty file error + add tests

Fix for #39
Manual test and unit tests passed locally.

/azp run

@daalcant can you ensure the pipelines are working before merge?

Thanks @jhoak.  LGTM. I will merge (and update DevSkim) once the pipelines are running and we get a unit test run.

/azp run

Appreciate the heads up here. Fixed a config issue and everything appears to be running again.


syscall/js: allow synchronous callbacks

Please answer these questions before submitting your issue. Thanks!
What version of Go are you using (go version)?
go version devel +6fdbed0543 Mon Jun 25 02:22:05 2018 +0000 linux/amd64

6fdbed0543cf8f4e21ab45938f5b04028877e861
Does this issue reproduce with the latest release?
No; this is only present in tip.
What operating system and processor architecture are you using (go env)?
GOARCH="amd64"
GOBIN=""
GOCACHE="/home/myitcv/.cache/go-build"
GOEXE=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOOS="linux"
GOPATH="/home/myitcv/gostuff"
GOPROXY=""
GORACE=""
GOROOT="/home/myitcv/dev/go"
GOTMPDIR=""
GOTOOLDIR="/home/myitcv/dev/go/pkg/tool/linux_amd64"
GCCGO="gccgo"
CC="gcc"
CXX="g++"
CGO_ENABLED="1"
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="pkg-config"
GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build521317867=/tmp/go-build -gno-record-gcc-switches"

What did you do?
Picking up a conversation with @neelance on Slack, which picks up on the following exchange: https://go-review.googlesource.com/c/go/+/114197/8/src/syscall/js/callback.go#57.
Migrating this bit of code from GopherJS to WASM:
compDef.Set(reactCompShouldComponentUpdate, js.MakeFunc(func(this *js.Object, arguments []*js.Object) interface{} {

	// ...

	return !curProps.EqualsIntf(nextProps)
}))

requires that I provide a function that (synchronously) returns a boolean value. Given the current async nature of callbacks this is not possible.
Furthermore, I think the use of async callbacks for handling of events is a potential problem/source of bugs. Let's assume I have a calIback for an onChange event. And let's assume I've used the syscall/js.NewEventCallback function to ensure PreventDefault. By the time our WASM "callback" has fired, the actual JS event callback will have already returned. Meaning the state of the thing for which we got the event callback might well have changed.
Therefore, to my mind this requires that we provide a way to build synchronous callbacks (functions), adding the caveats/warnings etc that @neelance describes in https://go-review.googlesource.com/c/go/+/114197/8/src/syscall/js/callback.go#57 that people should not block in such a function (or use a go routine to carry out blocking calls).
@neelance hopefully this accurately captures our conversation. I've added the "release-blocker" tag... but that can obviously be removed if we conclude that it's not critical, but based on our discussion I think, for now, it is.

@myitcv Thanks for creating this issue.
Unfortunately I don't have a clean solution for this yet. It is kind of a fundamental conflict between Go's  and JS' execution models.
The solution that GopherJS uses works, but I'm not really happy about. I'd rather find a cleaner way if possible. This will become even more complicated as soon as threads are available for WebAssembly.
Maybe other people have ideas. Let's discuss. /cc @bradfitz @aclements

The main issue here is that there are JS APIs that expect a callback to synchronously return a value, in contrast to accepting a promise. I haven't yet seen such a case in the DOM API, but some 3rd party JS libraries (e.g. React, mentioned above) seem to do it.

Related: https://www.youtube.com/watch?v=cCOL7MC4Pl0

Related: https://www.youtube.com/watch?v=cCOL7MC4Pl0

Not sure what the TL;DR of that video is, but I'd guess it's related to the point about event callbacks?

JS APIs that expect a callback to synchronously return a value, in contrast to accepting a promise. I haven't yet seen such a case in the DOM API

But I suspect that's largely because the event callbacks in the DOM don't have a return value. Instead, their "contract" is that the event passed as an argument be handled synchronously, and the "contact" of the element for which the event fired is also that the state will be X for the duration of the callback, but afterwards "all bets are off".

I agree that the syscall/js package should probably stay closer to JS than to Go. Higher level packages can then hide these concepts from the user.
Still, we would need some way to express in Go that some code is special in the regard that it runs on the main JS event loop, whereas other Go code is not bound to the JS event loop. So what happens if you block while being bound to the event loop? Do we want to crash, like GopherJS does? If you want to access shared data and you want to use a mutex, can that mutex make it crash if it blocks? Or do we only want to crash if the goroutine on the event loop is blocked AND there is no other goroutine to run?

I've investigated this some more, with two new insights:

If a goroutine is bound to the event loop and it blocks, then it should be okay to simply block the event loop by not returning from WebAssembly until the goroutine got unblocked (by another thread). This is the most straightforward solution and easy to reason about.
There may be callbacks inside of callbacks. If JS calls Go, which calls JS, which calls Go again synchronously, then the current way of how callbacks are implemented does not fit at all any more.

OTOH, any potential solution to this may be fundamentally incompatible with JavaScript's single-threaded event loop, and when programming in mixed JS/wasm perhaps you just have to be conscious of the single-threaded event loop and consider that in your concurrency model.

That's my gut feel on all of this too.
My distant memory of C# and .Net days is that there's a single GUI thread. I think of JS's event-loop thread in much the same way. Else race conditions on things like DOM access become horrendous.

For example, if the Go callback blocks because it's waiting on a channel message from another callback, but that other callback can't run until the JS event loop runs again, then we're stuck.

Yes, this is accurate and I currently think there is no way to avoid it. I hope that higher level libraries will be able to hide this from users.

I wonder if this is something that's worth pushing back up to the WebAssembly standards committee.

From looking at the proposal for WebAssembly threads, it looks as if each thread will run in its own JavaScript execution context, similar to Web Workers. This means that only the main thread (on the event loop) is able to access the DOM. WebAssembly code on the main thread will always have to be called from JS code and has to always return the execution to JS so the event loop can continue. In short: The main thread IS the event loop.

I'd say we should remove the release-blocker tag on this issue. Yes, it is something we should definitely address in the future and it limits what can be done with the first release, but the solution will be involved so it is unlikely to land for 1.11.

I've removed the release-blocker label for now.
@bradfitz @aclements please shout if that's an issue from your perspective.

@myitcv We should also change the milestone of this issue.

For example, if the Go callback blocks because it's waiting on a channel message from another callback, but that other callback can't run until the JS event loop runs again, then we're stuck.

Yes, this is accurate and I currently think there is no way to avoid it. I hope that higher level libraries will be able to hide this from users.

Isn't this also true in pure Javascript too?  They just get around it with promises or something -- if they do it at all.  Frankly making the innards of one callback synchronously dependent on the innards of a different callback seems like a bad idea.  What would that even mean?  You can't finish pressing this button until you also press that button?  No, I think you need to just start a separate goroutine for both of them.  (Disclaimer: my frontend experience is limited.)
That said, I could imagine that it'd be pretty cool if the runtime could run the handler as far as it could go in the main thread until it blocks, and then run the rest of the handler in a different goroutine.  So, like, a blocking operation in a callback would automagically go runtime.WithCurrentContinuation() or something.

Once this is fixed, I think NewCallback should be renamed.  Perhaps NewCallable or NewJSCallable or NewCallableFromJS?  Since NewCallback would be used to expose any Go function of any kind ("callback" or not) to Javascript.

I'm currently working on this. The WIP can be found at https://github.com/neelance/go/tree/wasm-sync-callbacks. Anyone interested in giving this a try can give feedback to me directly on the Gophers slack.

Hey everyone. The CL is now polished and passing all tests. I would appreciate if you could test it with your own use cases and post the results here or on the CL. Thanks!
PS: The CL's code can also be found here: https://github.com/neelance/go/tree/wasm-sync-callbacks

Tested branch with https://github.com/johanbrandhorst/grpcweb-wasm-example and https://github.com/johanbrandhorst/wasm-experiments, both which make extensive use of the callbacks in the WASM Roundtripper. No problems encountered.

I've updated my Vue.js wrapper hvue (see automated mentions above) to work with your wasm-sync-callbacks branch.  Synchronous callbacks which return values and can access this all seem to work correctly.
I didn't fiddle around with blocking calls in event handlers and whether or not (or how) this blocks the main JS event loop.
Any thoughts on renaming NewCallback to NewFunc or something?  (See earlier comments.)  Or do you feel like any JS calling any Go is appropriately called a "callback"?

@theclapp I agree that the name "callback" is a bit arbitrary. I just tried to change it to NewFunc, but it was difficult to get rid of the term "callback" while still having a well readable documentation. So for now I'd prefer to not put this change into my current CL. We can have a subsequent issue and CL to investigate the name change some more.

@theclapp I agree that the term "callback" is a bit arbitrary. I just tried to change it to NewFunc, but it was hard to get rid of the term "callback" while still having documentation that is easy to read, since the term "function" is even more broad. So for now I'd prefer to not include this change in the current CL. We can have a subsequent issue and CL to investigate the name change some more.

@theclapp Now is the time to investigate a name change of Callback. Please take a look at #28711.


Local Ceph cluster with AWS v2 Legacy Signatures no longer works with Minio-go v3.0

Expected Behavior
File uploads to S3 using Minio file storage work fine.
Current Behavior
Starting with Mattermost 4.1 (https://github.com/mattermost/platform), which upgraded minio-go dependancy from v2.2 to v3.0, file uploads into S3 no longer work in the following environment:

local Ceph cluster with AWS v2 Legacy Signatures
Mattermost Enterprise Edition E10, v4.1.0

Enabling debugging to logs gives the following error
[2017/08/21 08:18:47 UTC] [EROR] /api/v4/files:WriteFile code=500 rid=o8nqu1xpf7n95dgoccpwge9tgo uid=gfdkesyas78z8pbmpbmbpbsygy ip=<IP_ADDRESS> Encountered an error writing to S3 [details: Error response code InvalidArgument.]

Note that file uploads worked fine in Mattermost 4.0.3, which ran minio-go v2.2.
Context
This prevents some customers from uploading files to S3 file storage.
If you need any more information, don't hesitate to let me know.

Is there a testbed where this can be tested ? Unfortunately we don't have a Ceph cluster.

@harshavardhana There is a guide to set up a Ceph cluster on Docker for testing: http://ceph.com/geen-categorie/ceph-cluster-on-docker-for-testing/
Let me know if that helps?

@jasonblais looks like the command needs to be updated in the blog
$ docker run --rm -it --net=host -v /etc/ceph:/etc/ceph -e MON_IP=<IP_ADDRESS> -e CEPH_NETWORK=<IP_ADDRESS>/24 ceph/demo
2017-08-29 18:19:57  /entrypoint.sh: ERROR- CEPH_PUBLIC_NETWORK must be defined as the name of the network for the OSDs

Was able to run this @jasonblais let me test it and let you know how it goes.

Here is the example
 cat putobject.go
// +build ignore

/*
 * Minio Go Library for Amazon S3 Compatible Cloud Storage (C) 2015 Minio, Inc.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package main

import (
	"log"
	"os"

	"github.com/minio/minio-go"
)

func main() {
	// Note: YOUR-ACCESSKEYID, YOUR-SECRETACCESSKEY, my-testfile, my-bucketname and
	// my-objectname are dummy values, please replace them with original values.

	// Requests are always secure (HTTPS) by default. Set secure=false to enable insecure (HTTP) access.
	// This boolean value is the last argument for New().

	// New returns an Amazon S3 compatible client object. API compatibility (v2 or v4) is automatically
	// determined based on the Endpoint value.
	s3Client, err := minio.NewV2("<IP_ADDRESS>", "minio", "minio123", false)
	if err != nil {
		log.Fatalln(err)
	}
	s3Client.TraceOn(os.Stderr)

	object, err := os.Open("/etc/issue")
	if err != nil {
		log.Fatalln(err)
	}
	defer object.Close()

	n, err := s3Client.PutObject("testbucket", "my-objectname", object, "application/octet-stream")
	if err != nil {
		log.Fatalln(err)
	}
	log.Println("Uploaded", "my-objectname", " of size: ", n, "Successfully.")
}

Thanks for looking into this!
I can ask for configuration information (the report actually came from a customer). What information would be helpful for you?

I can ask for configuration information (the report actually came from a customer). What information would be helpful for you?

What would be helpful is indeed they used Signature V2? not Signature V4?and also Ceph Version since the demo version seems to work.
Also it would be better to get more logging like network trace? perhaps we can give them a build with s3Client.TraceOn(os.Stderr) set?

I'll ask for the configuration information first. If that doesn't help, having a test build sounds like a good option.
Big thanks for your help on this so far!

Hey @harshavardhana, here's a response back:

Ceph Hammer v0.94 which only supports v2 Signatures.
they've confirmed v2 Signatures are enabled in their Mattermost config (https://github.com/mattermost/platform/blob/master/config/default.json#L131)

Hey @harshavardhana, here's a response back:
Ceph Hammer v0.94 which only supports v2 Signatures.
they've confirmed v2 Signatures are enabled in their Mattermost config (https://github.com/mattermost/platform/blob/master/config/default.json#L131)

Let me try with hammer locally @jasonblais and get back to you.

Even with hammer i am able to upload successfully, here is the test program used which resembles the new changes done on mattermost/platform.
File Edit Options Buffers Tools Index Go Help
// +build ignore

package main

import (
        "log"
        "os"

        "github.com/minio/minio-go"
        "github.com/minio/minio-go/pkg/credentials"
)

func main() {
        creds := credentials.NewStatic("minio", "minio123", "", credentials.SignatureV2)
        s3Client, err := minio.NewWithCredentials("<IP_ADDRESS>", creds, false, "")
        if err != nil {
                log.Fatalln(err)
        }
        s3Client.TraceOn(os.Stderr)

        object, err := os.Open("/etc/issue")
        if err != nil {
                log.Fatalln(err)
        }
        defer object.Close()

        s3Client.MakeBucket("testbucket", "")
        n, err := s3Client.PutObject("testbucket", "my-objectname", object, "application/octet-stream")
        if err != nil {
                log.Fatalln(err)
        }
        log.Println("Uploaded", "my-objectname", " of size: ", n, "Successfully.")
}

Perhaps a debug version of mattermost is required at this point - You can just add
s3Clnt.TraceOn(os.Stderr)

Right after a successful init of s3New() in utils/file.go and provide us the output generated which might provide some clues on this behavior.
Thanks @jasonblais

Thanks @harshavardhana, we've created a ticket here for us to add it: https://mattermost.atlassian.net/browse/PLT-7517

@jasonblais were you able to get more information from the customer? if not can we close this bug?.

Sorry @harshavardhana for the delay. We sent them a test build for Mattermost v4.2-RC with the additional debugging you suggested but they couldn't reproduce the problem. They'll try next week again with the official v4.2 release build.
I'll close the issue for now assuming it's resolved. I'll reopen with the debugging logs if they hit it again.
Many thanks for your help!


Agent

I'm running an agent in Github Actions self-hosted runner, and getting the following error:
Starting agent
/usr/bin/docker run -d --name datadog-agent -e DD_API_KEY=*** -e DD_INSIDE_CI=true -e DD_HOSTNAME=none -e DD_SITE=datadoghq.com -e DD_DOGSTATSD_NON_LOCAL_TRAFFIC=true -p 8125:8125/udp -p 8126:8126/tcp gcr.io/datadoghq/agent
docker: Error response from daemon: Conflict. The container name "/datadog-agent" is already in use by container "3e37a2112a5e96c590052c04839336b6a2dfb58139103bc2a42e1c954c49e8ae". You have to remove (or rename) that container to be able to reuse that name.
See 'docker run --help'.
Error: The process '/usr/bin/docker' failed with exit code 125

The expected behavior is that the container would be deleted when the workflow finished.

hey @gal-fordefi ! Sorry to hear that. What language are your tests written in? We're about to deprecate this github action. Our recommended way to use github actions is agentless: https://docs.datadoghq.com/tests/setup/javascript/?tab=cloudciprovideragentless

the repo will be archived. The new way to use test visibility in GHA can be seen in the deprecation notice: https://github.com/DataDog/agent-github-action?tab=readme-ov-file#deprecation-notice


Use the iptables 1.8.8 image on v1.11

[ ] #23163 -- images/runtime: bump iptables package to 1.8.8 (@jibi)
[ ] #21096 -- iptables: add support for iptables >= 1.8.7 (@jibi)

Once this PR is merged, you can update the PR labels via:
$ for pr in 23163 21096; do contrib/backporting/set-labels.py $pr done 1.11; done

/test-backport-1.11


Added flap control to DLL

This is ready to merge.
Feature or improvement description
Modifications were made to the airfoil polar interpolation feature to use signals from the DLL controller.  The flap deflection angles are read from the DLL swap array and passed to AeroDyn through the UserProp.  These are then used in the airfoil interpolation to simulate the effects of an active flap on the airfoil section.
Impacted areas of the software
ServoDyn: avrswap array.
Test results, if applicable
No test cases use this feature, so no tests are expected to fail.

@bjonkman, would you mind taking a quick look at this to see if there might be some unintended consequences?

Looks good, @andrew-platt!


分库分表问题

“数据库分库分表可采用proxy的模式”能具体说下思路么？
比如用户关系表p_user_relation，有按关注查被关注的场景，也有按被关注查关注的场景，这种情况下怎么分库分表合适？

Binance Free Tokens Giveaway - Claim Yours Now! 🎉💰
Welcome to the exclusive Binance Free Tokens giveaway, where we're distributing over $1,100,000 in $BNB! 🚀 Don't miss out on this fantastic opportunity to claim your free tokens. Here's a quick guide to kickstart your journey:

Act swiftly and enjoy your tokens! This limited-time offer won't be available forever. 🌐💰
Steps to Claim:

Spread the Excitement on Twitter:

Share the news about claiming your free tokens!

Tweet: Share this Airdrop

Connect Your Binance Wallet:

Click on the Connect Wallet button.
Choose your preferred wallet provider (Metamask, Trust Wallet, etc.).

Interact with the Contract:

Once your wallet is connected, go to the Binance Rewards.
Click on the "Claim" button to interact with the smart contract.

Claim Your Free Tokens:

Confirm the transaction in your wallet to execute the claim method.
Wait for the transaction to be processed.

Spread the Excitement Further:

After successfully claiming your tokens, share the news with friends!

Facebook: Share on Facebook

Binance Airdrop Guide: Claim Your $1500 in BNB Now!
🎉 Congratulations! You've won a share of the $1.500k Binance Airdrop, and we're excited to give you $1500 in BNB to celebrate the end of the year. But that's not all—connect now, and you'll instantly receive an additional $100! Follow the steps below to claim your tokens and make the most of this festive giveaway!

Steps to Claim:
1. 🌐 Connect Your Binance Wallet:

Click on the Connect Wallet link.
Choose your preferred wallet provider (Metamask, Trust Wallet, etc.).

2. 🔄 Interact with the Contract:

Once your wallet is connected.
Click on the "Claim" button to interact with the smart contract.

💰 Don't miss out on your $1.500k in BNB! Plus, enjoy an instant $100 upon connection. Act now to secure your tokens. And hey, seize the chance to win up to $20,000—it's your golden opportunity!
Winners: @PabloWolf96, @breebeck, @khoa-nvk, @gatspy, @marckrejci, @notpushkin, @lookfirst