tezos_rpc: Fetch_block_operations

Depends

[ ] #444

Problem
Similar to #444, another requirement to move away from Taquito is to be able to fetch the operations of a block, to detect interactions with consensus.mligo.
Solution
Implements Tezos_rpc.Fetch_block_operations, this API provides a way to fetch the operations from a specific chain and block_hash.
warning: the implementation is not ideal as the JSON encoded by Tezos is quite complex, so this PR just abuses of ppx_deriving_yojson to generate some simplified decoders, in the current stage this only decode transactions and internal transactions.

@anchpop There is an OCaml library, that's the tezos-client, the problem is that it pulls the entire Tezos codebase with it, that's what we're trying to avoid.


Two broadcasting auth routes for different middleware

Laravel Version: 5.3.#
PHP Version:
Database Driver & Version:

How i can define two broadcasting auth routes for web middleware and api middleware?
I can define  Broadcast::routes(); for web or  Broadcast::routes( [ 'middleware' => [ 'api', 'jwt.auth' ] ] ); for api. But it doesn't work common.

For what it add default web middleware to broadcasting auth route?
`public function routes(array $attributes = null)
{
if ($this->app->routesAreCached()) {
return;
}
    $attributes = $attributes ?: ['middleware' => ['web']];

    $this->app['router']->group($attributes, function ($router) {
        $router->post('/broadcasting/auth', BroadcastController::class.'@authenticate');
    });
}`

oK, i deleted default web middleware and added parse user from token to broadcast auth callback.
`
Broadcast::channel('App.User.*', function ($request, $userId) {
        $result = (int) $request->user()->id === (int) $userId;

		if($result) {

			return $result;

		}
		else {

			$user = \Tymon\JWTAuth::parseToken()->authenticate();

			if($user) {

				$request->setUserResolver(function () use ($user) {
					return $user;
				});

				return (int) $user->id === (int) $userId;;

			}

		}

		return false;

    });

`
`public function routes(array $attributes = null)
{
if ($this->app->routesAreCached()) {
return;
}
$attributes = [];

$this->app['router']->group($attributes, function ($router) {
    $router->post('/broadcasting/auth', BroadcastController::class.'@authenticate');
});

}`

This is not StackOverflow, this will get closed ASAP.

Note: you can edit your posts on GH so no need to post multiple times.

Oh really? The fact that I can not use Broadcasting for Api and the Web at the same time is not a bug? So it's planned?
This information is for other users. If you do not like it, do not read it.

You should ask this on the forums.


Replace Request classes with NamedTuples

In keeping with the functional style of this library, remove the classes from the library, replacing them with immutable NamedTuples.

Request class has been replaced in #141.

Closed in #141.


changed element type 'tBoundaryDefinitions': added processContents="lax"

[x] Ensure that the commit message is a good commit message
[x] Ensure to use auto format in all files
[ ] Change in CHANGELOG.md described
[ ] Tests created for changes
[ ] Screenshots added (for UI changes)

Can one of the admins verify this patch?


Changed the pressure min output and pressure max output for more accu…

…rate pressure data.

Nice, can you add some details in a comment about why those values are used?


cloudformation create_change_set fails when Tags are supplied

How to reproduce:

Using moto 1.2.0, call create_change_set and supply the Tags kwarg as a list of dicts, each dict holding a Key and Value (as defined in the AWS boto3 docs.

[This line] in moto/cloudformation/responses.py](https://github.com/spulec/moto/blob/master/moto/cloudformation/responses.py#L90) calls self._get_list_prefix("Tags.member") which correctly returns a list of dicts. However, the line in full is tags = {tag[0]: tag[1] for tag in self._get_list_prefix("Tags.member")} which appears to be trying to convert a list of tuples to a dict. This fails because the source list for the comprehension is a list of dicts, not tuples.
Expected behaviour: it should be possible to pass tags as defined in the boto3 docs.

I am seeing the same behavior.

Fixed with https://github.com/spulec/moto/commit/a0708a70fcc1b265a25fccb01ec1ca67e409a5ce


Problem implementing the "quick start" guide for version 3.0.1.

Summary
What happened/what you expected to happen?
Problem with the quick start for version 3.0.1 under GCP K8S.
I can get this to work:
helm repo add argo https://argoproj.github.io/argo-helm
helm install argo argo/argo -n argo --create-namespace --set minio.install=true
kubectl -n argo port-forward deployment/argo-server 2746:2746

after I can see the UI via <IP_ADDRESS>:2746
But if i try:
kubectl create namespace argo
kubectl apply -n argo -f https://raw.githubusercontent.com/argoproj/argo-workflows/v3.0.1/manifests/quick-start-postgres.yaml
kubectl create clusterrolebinding XXXX-cluster-admin-binding --clusterrole=cluster-admin<EMAIL_ADDRESS>kubectl -n argo port-forward deployment/argo-server 2746:2746

I can not log into the UI via <IP_ADDRESS>:2746.
All I get is "ERR_EMPTY_RESPONSE".
argo-server logs:
time="2021-04-12T08:19:20.980Z" level=info authModes="[server client]" baseHRef=/ managedNamespace=argo namespace=argo secure=true
time="2021-04-12T08:19:20.980Z" level=info msg="config map" name=workflow-controller-configmap
time="2021-04-12T08:19:20.980Z" level=info msg="SSO disabled"
time="2021-04-12T08:19:20.994Z" level=info msg="Starting Argo Server" instanceID= version=v3.0.1
time="2021-04-12T08:19:20.994Z" level=info msg="Creating DB session"
time="2021-04-12T08:19:21.016Z" level=info msg="Node status offloading config" ttl=5m0s
time="2021-04-12T08:19:21.016Z" level=info msg="Creating event controller" operationQueueSize=16 workerCount=4
time="2021-04-12T08:19:21.024Z" level=info msg="Argo Server started successfully on https://localhost:2746"

I recently tried to install the v3.0.1 on Docker-for-Mac and got ERR_EMPTY_RESPONSE. This post has been miss interpreted but the bug is there.
Current environment:

Big Sur (11.3.1 Intel)
Docker (20.10.6)
Test both on Kubernetes and Kind.
Steps to reproduce:$ kubectl create namespace argo
$ kubectl apply -n argo -f https://raw.githubusercontent.com/argoproj/argo-workflows/v3.0.6/manifests/install.yaml
$ kubectl -n argo edit svc/argo-server
# Edit ClusterIP to LoadBalancer

--> When try to access localhost:2746. This is the response:

Since v3.0, we listen on a TLS socket, you must use HTTPS in your URL.https://localhost:2746

Since v3.0, we listen on a TLS socket, you must use HTTPS in your URL.https://localhost:2746

How to map this with Ambassador?

Since v3.0, we listen on a TLS socket, you must use HTTPS in your URL.https://localhost:2746

@alexec  Can you highlight HTTPS on the Quick Start doc? We stuck on this problem for couple hours.

I think it should point out that access website by https is a must.


fix a bug on highestCurrent and similar expressions

highestCurrent and similar expressions didn't handle well a series where all elements are absent

LGTM


Move GetStartOnSystemStartup and SetStartOnSystemStartup to GUI code

Reference: https://github.com/bitcoin/bitcoin/pull/1178

Again I'll confirm Windows builds and running the wallet

This has been rebased over master @mitchellcash if you have already tested this please test it again.

Sorry I missed testing this before it conflicted again. I will await your next rebase over master and will make this the next thing I test.

@mitchellcash I hadn't even noticed it was broken lol. Rebased over master to accommodate #391

Like the Bitcoin commit it seems that shlwapi.h can be removed from util.cpp after your changes.

removed and tested (15 minutes)

Looks good to me from here.

squashed and confirmed gitian builds (50 minutes)


Resolve tough-cookie to 4.1.3

Based on recommendation by @AMoo-Miki on
https://github.com/opensearch-project/opensearch-build/issues/3856
Description
Regenerating our yarn.lock file, as done by the automation to bump version numbers with each release, downgrades our tough-cookie dependency from 4.1.3 to 2.5, because the version of Cypress that we use depends on 2.5.
To avoid the downgrade, we should update our package.json to reflect the version that we intend to use.
Issues Resolved
N/A
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

I would consider it as a temporary solution; for the long run, we will remove cypress dependency https://github.com/opensearch-project/dashboards-search-relevance/issues/266.


DL-55: Fix the apache-rat check

exclude the website directory as well as excluding docs directory
remove the .gitmodules file (it seems to not be used anyway)

LGTM +1


New errors for name / id checks in app profile constructor

Fixes #<issue_number_goes_here> (it's a good idea to open an issue first for discussion)

[ ] Tests and linter pass
[ ] Code coverage does not decrease (if any source code was changed)
[ ] Appropriate docs were updated (if necessary)

All constructor checks should be in the same PR.

Moving all constructor checks to PR#197


Missing encryption key to decrypt file with. Ask your team for your master key and write it to /rails/config/master.key or put it in the ENV['RAILS_MASTER_KEY']

Testing using MRSK 0.11.0
Please bear with me as I am working through numerous MRSK setup issues and I am new to MRSK and relatively new to Docker.
Initially started building this app using the default config/deploy.yml file, making small tweeks and re-testing each time as I worked through various issues.
Somewhere along the way, I uncommented this code in the deploy.yml file:
(1)
env:
  secret:
    - RAILS_MASTER_KEY

Note that I just uncommented the code, leaving the characters RAILS_MASTER_KEY as just a string. It is not clear to me reading the instructions and default of the file whether it should have been replaced by my real master key (or not?).
I was confused by the comment in the default file that reads: "(secrets come from .env)" which made me think that the string  RAILS_MASTER_KEY would get replaced by the secret in the .env file.
Somewhere along the way, someone on SLACK suggested this as a way to bring your Ruby version, bundler version, and secret key into the MRSK setup:
(2)
builder:
  args:
    RUBY_VERSION: "<%= Pathname.pwd.join('.ruby-version').read.strip.delete_prefix('ruby-') %>"
    BUNDLER_VERSION: "<%= Bundler::LockfileParser.new(Pathname.pwd.join('Gemfile.lock').read).bundler_version %>"
    RAILS_MASTER_KEY: "<%= ENV['RAILS_MASTER_KEY'] %>"

(Notice that these are builder args, not env secret)
Should I also do this same syntax for env secret configured in config/deploy.yml?
If I do this:
(3)
env:
  secret:
    - "<%= ENV['RAILS_MASTER_KEY'] %>"

then I can no longer do anything with MRSK  at all --it's like I'm borked now --- mrsk lock release and mrsk deploy both now tell me:
ERROR (KeyError): key not found: "f0e5e49fXXXXXXXXXXXXXXXXXXXXXX"
(rest of key has been obscured for privacy but I confirmed it matches my real secret key. )
If I use the original syntax (#1), then the lock mechanism works as expected to release the lock, but when I try to deploy, I get:
 > [linux/arm64 build 10/10] RUN SECRET_KEY_BASE_DUMMY=1 ./bin/rails assets:precompile:
#0 0.977 Missing encryption key to decrypt file with. Ask your team for your master key and write it to /rails/config/master.key or put it in the ENV['RAILS_MASTER_KEY'].
------
Dockerfile:53
--------------------
  51 |
  52 |     # Precompiling assets for production without requiring secret RAILS_MASTER_KEY
  53 | >>> RUN SECRET_KEY_BASE_DUMMY=1 ./bin/rails assets:precompile
  54 |
  55 |

Note that in production.rb this line has been UNCOMMENTED:
  config.require_master_key = true

as well, my app contains config/master.key (but it is not being copied into the container by Dockerfile), and my app also has the RAILS_MASTER_KEY set as an .env variable.
if I locally run RAILS_ENV=production rails s, I get these result:
3.1.2 :005 > Rails.application.credentials.key_file_contents
 => nil
3.1.2 :006 > Rails.application.credentials.env_key
 => "RAILS_MASTER_KEY"
3.1.2 :007 > Rails.application.credentials.key_file_contents
 => nil
3.1.2 :008 > ENV['RAILS_MASTER_KEY']
 => nil

if I instead run RAILS_ENV=development rails s, I get this:
3.1.2 :002 > Rails.application.credentials.env_key
 => "RAILS_MASTER_KEY"
3.1.2 :003 > Rails.application.credentials.key_file_contents
 => nil
3.1.2 :001 > ENV['RAILS_MASTER_KEY']
 => "f0e5e49fXXXXXXXXXXXXXXXXXXXXXXXXX"

The Dockerfile is the same Dockerfile found on https://www.driftingruby.com/episodes/deploying-with-mrsk and the line that it fails on is:
# Precompiling assets for production without requiring secret RAILS_MASTER_KEY
RUN SECRET_KEY_BASE_DUMMY=1 ./bin/rails assets:precompile

https://github.com/bkeepers/dotenv explicitly discusses that the original intention of the Gem is to be used on development + test, but not in production. It seems it CAN be used in production, but that wans't the original intention.
MRSK makes dotenv a specific dependency for all environments, changing for most of us what was once a dependency used only in development+test into dev+test+prod
What is confusing is generally, it is advised against to put your master key into source control -- this is the whole point of having environment variables separated from the source code.
So, what do I do? I could see two ways forward:
(1) put my rails master key into .env.production -- a no-no based on security, or
(2) if using a config/master.key file instead, should my Dockerfile be copying that file into the Docker image during the build steps?

cc: @driftingruby — I'm not sure if this problem is related to MRSK or the Dockerfile which I had copied from your site  https://www.driftingruby.com/episodes/deploying-with-mrsk

I tried adding this but it didn't work as expected
COPY --link config/master.key ./

ERROR: failed to solve: failed to compute cache key: failed to calculate checksum of ref iu1slb3t4migzukxu8utkd59t::wo21gohuj7e7t4qunsw6t9nfs: "/config/master.key": not found
am I going down the wrong path here?

if I have config.require_master_key = true enabled in production.rb, the error when running mrsk deploy is:
#25 0.815 Missing encryption key to decrypt file with. Ask your team for your master key and write it to /rails/config/master.key or put it in the ENV['RAILS_MASTER_KEY'].

if I COMMENT OUT `config.require_master_key = true  in production.rb, the error is instead this:
[4:17](https://rubyonrails-link.slack.com/archives/C3EEPTJHG/p1683058659069799)
#0 0.876 ArgumentError: Missing `secret_key_base` for 'production' environment, set this string with `bin/rails credentials:edit`

Either way, if I run RAILS_ENV=production rails c, there's no env setting for RAILS_MASTER_KEY:
% RAILS_ENV=production rails c
Loading production environment (Rails <IP_ADDRESS>)
irb: warn: can't alias context from irb_context.
3.1.2 :001 > ENV['RAILS_MASTER_KEY']
 => nil

tested on MRSK 0.12.0, same results

next step:

Tobias suggests :
"I'd add it at bin/rails credentials:edit --environment production"


Jaeger in istio

Hey, I want to deploy  jaeger in the production environment of istio. And in my understanding the istio sidecar will send tracing data to Jaeger collector, so it is not necessery to deploy the Jaeger agent, right? I did deploy the Jaeger collector and query, using ES as the storage backend. However there is nothing in the UI and ES.  All installation steps are referenced from https://github.com/jaegertracing/jaeger-kubernetes
My configration for istio:
tracing.zipkin.address : zipkin.:9411
My configration for jaeger:
apiVersion: v1
kind: ConfigMap
metadata:
  name: jaeger-configuration
  labels:
    app: jaeger
    app.kubernetes.io/name: jaeger
data:
  span-storage-type: elasticsearch
  collector: |
    es:
      server-urls: http://elasticsearch-logging.kube-system:9200
    collector:
      zipkin:
        http-port: 9411
  query: |
    es:
      server-urls: http://elasticsearch-logging.kube-system:9200
  agent: |
    collector:
      host-port: "jaeger-collector:14267"

My environment:
istio: 1.2.5
es:  6.6.1

Istio will create spans related to its own components, such as Proxy (ingress/egress) and Mixer checks. To be able to have a distrubuted trace, you'll need to at least propagate the context by relaying some HTTP headers from the incoming request to the outgoing request. See https://istio.io/docs/tasks/telemetry/distributed-tracing/overview/ .
In your case, you should at least be seeing the ingress spans. Could you please share how your deployment looks like? For reference, here's a working example from the Jaeger Operator repository:
apiVersion: apps/v1
kind: Deployment
metadata:
  name: myapp
  annotations:
    "sidecar.jaegertracing.io/inject": "true"
spec:
  selector:
    matchLabels:
      app: myapp
  template:
    metadata:
      labels:
        app: myapp
      annotations:
        sidecar.istio.io/inject: "true"
    spec:
      containers:
      - name: myapp
        image: jaegertracing/vertx-create-span:operator-e2e-tests
        ports:
        - containerPort: 8080
          protocol: TCP

@packyzbq Have you checked the Istio docs related to Jaeger: https://istio.io/docs/tasks/telemetry/distributed-tracing/jaeger/#before-you-begin - option B describes how to setup Istio to use an external (production) configuration - although note there is a mistake, the port should be 9411 instead of 16686, I will create a PR to fix that.

@objectiser Thanks for your reply. I'm using  https://raw.githubusercontent.com/jaegertracing/jaeger-kubernetes/master/jaeger-production-template.yml to deploy jaeger, just delete the jaeger agent daemonSet.
I don't want to use Jaeger Operator because I need to deploy Jaeger on the  mips arch node and it is not support Jaeger Operator.

@objectiser I refered this link, and I'm using 9411 port. Is this problem likely to be related to the jaeger sampling strategy?

@packyzbq No, Istio controls the sampling decision in this situation. As mentioned in the section I referenced:

When you enable tracing, you can set the sampling rate that Istio uses for tracing. Use the pilot.traceSampling option to set the sampling rate. The default sampling rate is 1%.

So you need to set the pilot.traceSampling parameter to 100.

@objectiser  I set the pilot.traceSampling parameter to 100 and it works! Thank you!


Git list impl

+1! There's a tiny merge conflict in .gitignore from (I think) when the prettier stuff was added. We'll want to run prettier at a later date I think, we've got a few branches and rebasing might be a pain lol


Rename from batdata to battdat

"batt" like battery not "bat" like batman

Pull Request Test Coverage Report for Build<PHONE_NUMBER>7
Details

44 of 49 (89.8%)  changed or added relevant lines in 15 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage decreased (-0.1%) to 89.561%

Changes Missing Coverage
Covered Lines
Changed/Added Lines
%

battdat/extractors/tIVT.py
0
5
0.0%

Totals

Change from base Build<PHONE_NUMBER>0:
-0.1%

Covered Lines:
1021

Relevant Lines:
1140

💛  - Coveralls


chore(travis): sync .travis.yml from npm-package-template

update before_script, after_script, before_install

[Current coverage][cc-pull] is 82.89%

Merging [#34][cc-pull] into [master][cc-base-branch] will increase coverage by +0.12%

2 files (not in diff) in lib/util were modified. more

Hits +4

5 files (not in diff) in lib/recordCheck were modified. more

Hits +5

3 files (not in diff) in lib were modified. more

Misses +2
Hits +6

@@           master        #34   diff @@
========================================
  Files          11         11
  Lines         579        596    +17
  Methods         0         60    +60
  Branches      181        181
========================================
+ Hits          479        494    +15
- Misses        100        102     +2
  Partials        0          0

Powered by Codecov. Last updated by [d4841da...b340499][cc-compare]
[cc-base-branch]: https://codecov.io/gh/Kronos-Integration/kronos-interceptor-object-data-processor-row/branch/master?src=pr
[cc-compare]: https://codecov.io/gh/Kronos-Integration/kronos-interceptor-object-data-processor-row/compare/d4841da1073524f7131e7ca35669e634de0810a6...b3404994cdae2834bbfdfdf9a77b391357b640dd
[cc-pull]: https://codecov.io/gh/Kronos-Integration/kronos-interceptor-object-data-processor-row/pull/34?src=pr


Quickfix: Problem if first pattern is an ignored multiline pattern

Let us consider the errorfile errors.err
info bla 3
more info
error 2

with the errorformat setting
set efm=%+Eerror\ %l,%-Winfo\ %m\ %l,%Zmore\ info

In the above errorfile, the first line is an information and is ignored (%-W), and the second line is a continuation of the first one. At the end, we expect that opening vim and calling :cg || copen shows us the error from the third line.
Instead, the quickfix window is empty.
If we replace %-W by %+W, we see the information and the error (as expected).
Similarly, if we add another error in front of the ignored information, we see both errors.
I suspect that the reason is that qfprev is not properly initalized in quickfix.c, but I am not sure.

Hi,
On Tue, Sep 27, 2016 at 1:51 PM, Gerd Wachsmuth
<EMAIL_ADDRESS>wrote:

Let us consider the errorfile errors.err
info bla 3
more info
error 2
with the errorformat setting
set efm=%+Eerror\ %l,%-Winfo\ %m\ %l,%Zmore\ info
In the above errorfile, the first line is an information and is ignored
(%-W), and the second line is a continuation of the first one. At the end,
we expect that opening vim and calling :cg || copen shows us the error from
the third line.
Instead, the quickfix window is empty.
If we replace %-W by %+W, we see the information and the error (as
expected).
Similarly, if we add another error in front of the ignored information, we
see both errors.
I suspect that the reason is that qfprev is not properly initalized in
quickfix.c, but I am not sure.

I can reproduce the problem and is reproducible even with older versions
of Vim (7.3). The issue is that the multiline error is started by %W and
ends with %Z without adding any errors. The quickfix list is also empty.
This results in an error processing the %Z line and the error entries after
that are skipped. If there is a valid error before %W or if %+W is used,
then the last error entry is set and it works as expected.

Yegappan

The issue is that the multiline error is started by %W and ends with %Z without adding any errors.
In my opinion, it is not the issue that no %C is present:
With

set efm=%+Eerror\ %l,%-Winfo\ %m\ %l,%+Ceven\ more\ %m,%Zmore\ info

(note the %C line)
and the errorfile
info bla 3
even more info
more info
error 2

we do not see error 2 in the quickfix window.

On 7 October 2016, Gerd Wachsmuth<EMAIL_ADDRESS>wrote:

The issue is that the multiline error is started by %W and ends with %Z without adding any errors.
In my opinion, it is not the issue that no %C is present:
With

set efm=%+Eerror\ %l,%-Winfo\ %m\ %l,%+Ceven\ more\ %m,%Zmore\ info

(note the %C line)
and the errorfile
info bla 3
even more info
more info
error 2

we do not see error 2 in the quickfix window.

What seems to be going on here is that the first line gets matched

as %-W and qf_parse_line() returns QF_IGNORE_LINE.  Then the
second line gets matched as %+C, it sets %m, but then it can't
find a previous line to continue since the previous line was ignored.
Consequently qf_parse_line() returns QF_FAIL, and qf_init_ext()
bails out at that point, silently ignoring any remaining input.
Possible solution:

diff --git a/src/quickfix.c b/src/quickfix.c
index 52abbeb..9139663 100644
--- a/src/quickfix.c
+++ b/src/quickfix.c
@@ -1010,6 +1010,8 @@ restofline:
 	}
 	else if (vim_strchr((char_u *)"CZ", idx) != NULL)
 	{				/* continuation of multi-line msg */
+	    if (!qi->qf_multiignore)
+	    {
 		qfline_T *qfprev = qi->qf_lists[qi->qf_curlist].qf_last;

 		if (qfprev == NULL)
@@ -1043,6 +1045,7 @@ restofline:
 			    ? fields->namebuf
 			    : qi->qf_currfile != NULL && fields->valid
 			    ? qi->qf_currfile : 0);
+	    }
 	    if (idx == 'Z')
 		qi->qf_multiline = qi->qf_multiignore = FALSE;
 	    line_breakcheck();

/lcd

Lcd wrote:
On 7 October 2016, Gerd Wachsmuth<EMAIL_ADDRESS>wrote:

The issue is that the multiline error is started by %W and ends with %Z without adding any errors.
In my opinion, it is not the issue that no %C is present:
With

set efm=%+Eerror\ %l,%-Winfo\ %m\ %l,%+Ceven\ more\ %m,%Zmore\ info

(note the %C line)
and the errorfile
info bla 3
even more info
more info
error 2

we do not see error 2 in the quickfix window.

What seems to be going on here is that the first line gets matched

as %-W and qf_parse_line() returns QF_IGNORE_LINE.  Then the
second line gets matched as %+C, it sets %m, but then it can't
find a previous line to continue since the previous line was ignored.
Consequently qf_parse_line() returns QF_FAIL, and qf_init_ext()
bails out at that point, silently ignoring any remaining input.
Possible solution:

diff --git a/src/quickfix.c b/src/quickfix.c
index 52abbeb..9139663 100644
--- a/src/quickfix.c
+++ b/src/quickfix.c
@@ -1010,6 +1010,8 @@ restofline:
 	}
 	else if (vim_strchr((char_u *)"CZ", idx) != NULL)
 	{				/* continuation of multi-line msg */
+	    if (!qi->qf_multiignore)
+	    {
 		qfline_T *qfprev = qi->qf_lists[qi->qf_curlist].qf_last;

 		if (qfprev == NULL)
@@ -1043,6 +1045,7 @@ restofline:
 			    ? fields->namebuf
 			    : qi->qf_currfile != NULL && fields->valid
 			    ? qi->qf_currfile : 0);
+	    }
 	    if (idx == 'Z')
 		qi->qf_multiline = qi->qf_multiignore = FALSE;
 	    line_breakcheck();

Could you write a test that covers this?
--
There can't be a crisis today, my schedule is already full.
/// Bram Moolenaar --<EMAIL_ADDRESS>-- http://www.Moolenaar.net   \
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \
\\  an exciting new programming language -- http://www.Zimbu.org        ///
\\            help me help AIDS victims -- http://ICCF-Holland.org    ///

On 8 October 2016, Bram Moolenaar<EMAIL_ADDRESS>wrote:

Lcd wrote:
On 7 October 2016, Gerd Wachsmuth<EMAIL_ADDRESS>wrote:

The issue is that the multiline error is started by %W and ends with %Z without adding any errors.
In my opinion, it is not the issue that no %C is present:
With

set efm=%+Eerror\ %l,%-Winfo\ %m\ %l,%+Ceven\ more\ %m,%Zmore\ info

(note the %C line)
and the errorfile
info bla 3
even more info
more info
error 2

we do not see error 2 in the quickfix window.

What seems to be going on here is that the first line gets matched

as %-W and qf_parse_line() returns QF_IGNORE_LINE.  Then the
second line gets matched as %+C, it sets %m, but then it can't
find a previous line to continue since the previous line was ignored.
Consequently qf_parse_line() returns QF_FAIL, and qf_init_ext()
bails out at that point, silently ignoring any remaining input.
Possible solution:

diff --git a/src/quickfix.c b/src/quickfix.c
index 52abbeb..9139663 100644
--- a/src/quickfix.c
+++ b/src/quickfix.c
@@ -1010,6 +1010,8 @@ restofline:
 	}
 	else if (vim_strchr((char_u *)"CZ", idx) != NULL)
 	{				/* continuation of multi-line msg */
+	    if (!qi->qf_multiignore)
+	    {
 		qfline_T *qfprev = qi->qf_lists[qi->qf_curlist].qf_last;

 		if (qfprev == NULL)
@@ -1043,6 +1045,7 @@ restofline:
 			    ? fields->namebuf
 			    : qi->qf_currfile != NULL && fields->valid
 			    ? qi->qf_currfile : 0);
+	    }
 	    if (idx == 'Z')
 		qi->qf_multiline = qi->qf_multiignore = FALSE;
 	    line_breakcheck();

Could you write a test that covers this?

Done:

https://gist.github.com/lcd047/4d4adb7e77fe29d9a8313c27fd42db25

(the diff is a lot bigger because of re-indentation).
/lcd

Lcd wrote:

On 8 October 2016, Bram Moolenaar<EMAIL_ADDRESS>wrote:

Lcd wrote:
On 7 October 2016, Gerd Wachsmuth<EMAIL_ADDRESS>wrote:

The issue is that the multiline error is started by %W and ends with %Z without adding any errors.
In my opinion, it is not the issue that no %C is present:
With

set efm=%+Eerror\ %l,%-Winfo\ %m\ %l,%+Ceven\ more\ %m,%Zmore\ info

(note the %C line)
and the errorfile
info bla 3
even more info
more info
error 2

we do not see error 2 in the quickfix window.

What seems to be going on here is that the first line gets matched

as %-W and qf_parse_line() returns QF_IGNORE_LINE.  Then the
second line gets matched as %+C, it sets %m, but then it can't
find a previous line to continue since the previous line was ignored.
Consequently qf_parse_line() returns QF_FAIL, and qf_init_ext()
bails out at that point, silently ignoring any remaining input.
Possible solution:

diff --git a/src/quickfix.c b/src/quickfix.c
index 52abbeb..9139663 100644
--- a/src/quickfix.c
+++ b/src/quickfix.c
@@ -1010,6 +1010,8 @@ restofline:
 	}
 	else if (vim_strchr((char_u *)"CZ", idx) != NULL)
 	{				/* continuation of multi-line msg */
+	    if (!qi->qf_multiignore)
+	    {
 		qfline_T *qfprev = qi->qf_lists[qi->qf_curlist].qf_last;

 		if (qfprev == NULL)
@@ -1043,6 +1045,7 @@ restofline:
 			    ? fields->namebuf
 			    : qi->qf_currfile != NULL && fields->valid
 			    ? qi->qf_currfile : 0);
+	    }
 	    if (idx == 'Z')
 		qi->qf_multiline = qi->qf_multiignore = FALSE;
 	    line_breakcheck();

Could you write a test that covers this?

Done:

https://gist.github.com/lcd047/4d4adb7e77fe29d9a8313c27fd42db25
(the diff is a lot bigger because of re-indentation).

Thanks.  I find it a bit hard to describe the problem and the fix.
Well, let's just keep it high level.
--
TALL KNIGHT: When you have found the shrubbery, then you must cut down the
mightiest tree in the forest ... with a herring.
"Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD
/// Bram Moolenaar --<EMAIL_ADDRESS>-- http://www.Moolenaar.net   \
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \
\\  an exciting new programming language -- http://www.Zimbu.org        ///
\\            help me help AIDS victims -- http://ICCF-Holland.org    ///

Fixed by patch 8.0.0026


Refactor core functionality of SimpleOpenAI to a base class and add dedicated classes for Azure and Anyscale

See discussion here:
https://github.com/sashirestela/simple-openai/issues/45
Also added demos for each of the new classes
tested on all providers OpenAI, Azure OpenAI and Anyscale.
Azure OpenAI supports blocking chat completion + functions (fails on streaming)
Anyscale         supports streaming, blocking + functions

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

Comparison is base (4c78f0d) 87.94% compared to head (4df6fd4) 85.33%.

Files
Patch %
Lines

.../github/sashirestela/openai/SimpleOpenAIAzure.java
0.00%
25 Missing :warning:

...thub/sashirestela/openai/SimpleOpenAIAnyscale.java
0.00%
5 Missing :warning:

...o/github/sashirestela/openai/BaseSimpleOpenAI.java
96.22%
0 Missing and 2 partials :warning:

:exclamation: Your organization needs to install the Codecov GitHub app to enable full functionality.
Additional details and impacted files
@@             Coverage Diff              @@
##               main      #47      +/-   ##
============================================
- Coverage     87.94%   85.33%   -2.61%
- Complexity      602      604       +2
============================================
  Files           105      108       +3
  Lines           937      975      +38
  Branches         27       33       +6
============================================
+ Hits            824      832       +8
- Misses           68       98      +30
  Partials         45       45

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

@the-gigi You have changed 95 files for this PR! Please, discard unnecessary changes and try to focus on the main goal of the Issue.

I did optimize imports in the IDE to find all unused imports. Apparently it also sorted imports in other files.  This will be a one time thing.

See discussion here: #45
Also added demos for each of the new classes
tested on all providers OpenAI, Azure OpenAI and Anyscale.
Azure OpenAI supports blocking chat completion + functions (fails on streaming) Anyscale supports streaming, blocking + functions

@the-gigi Have you verified if those providers support the vision feature? As you should know, the Chat Completion service also provides the capacity to recognize images and you can ask the model about image details. If you haven't, please verify and comment the results.

@sashirestela here is the next iteration of the PR for your review.
With the BaseSimpleOpenAI being just an interface as you requested there is a lot of duplication in all 3 implementations (lots of fields and similar logic in constructors). All this duplication can be pushed down to the base class as I did in the previous iteration. This is cleaner IMO, but in the end it's your decision.
I fixed an issue that surfaces only with Azure OpenAI in the ChatRequestclass - If tools are provided, but tools choice is null it fails on Azure OpenAI. I changed it so, if tools are provided, but no tools choice it set tools choice to AUTO.
If you have special formatting or linting rules you may consider sharing them as a pre-commit git hook. Or even better have github actions that to perform them automatically on PRs. This can save a lot of unnecessary work.
The chat completion with streaming doesn't work in AzureOpenAI (Not calling it in the AzureChatServiceDemo).
It just returns empty response. No error. blocking + function calling works fine.
I didn't test with images. I'll test and let you know the status.

@the-gigi
First, thanks for reducing the number of modified files on your PR. I'll take the task to improve the linting rules.
Regarding the main change, I understand your concerns and we could do a slight variation in order to reduce the  repeated code:
Let's turn BaseSimpleOpenAI in an abstract class, but with some variations:
abstract class BaseSimpleOpenAI {
    protected static final END_OF_STREAM = "[DONE]";

    @Getter
    protected String apiKey;
    @Getter
    protected String baseUrl;
    @Getter
    protected HttpClient httpClient;
    @Getter
    @Setter
    protected CleverClient cleverClient;

    protected Map<String, String> headers;
    protected UnaryOperator<HttpRequestData> requestInterceptor;

    protected OpenAI.Audios audioService;
    protected OpenAI.ChatCompletions chatCompletionService;
    protected OpenAI.Completions completionService;
   // etc.

    @SuperBuilder
    public BaseSimpleOpenaAI(String apiKey, String baseUrl, HttpClient httpClient) {
        this.apiKey = apiKey;
        this.baseUrl = baseUrl;
        this.httpClient = Optional.ofNullable(httpClient).orElse(HttpClient.newHttpClient());
        this.headers = new HashMap<String, String>();
        this.requestInterceptor = null;
    }

    protected void postContructor() {
        customSetup();
        this.cleverClient = CleverClient.builder()
                .httpClient(this.httpClient)
                .baseUrl(this.baseUrl)
                .headers(headers)
                .endOfStream(END_OF_STREAM)
                .requestInterceptor(requestInterceptor)
                .build();
    }

    abstract protected void customSetup();

    // Common service calls the cleverClient.create() method. Don't include this comment.
    public OpenAI.ChatCompletions chatCompletions() {
        if (chatCompletionService == null) {
            chatCompletionService = cleverClient.create(OpenAI.ChatCompletions.class);
        }
        return chatCompletionService;
    }

    // No common service throws an exception. Don't include this comment.
    public OpenAI.Audios audios() {
        throws new UnimplementedException();
    }

    // No common service throws an exception. Don't include this comment.
    public OpenAI.Completions completions() {
        throws new UnimplementedException();
    }

    // etc.
}

Now, SimpleOpenAI can add the specific parameters and overwrite the No-common services:
public class SimpleOpenAI {

    @Getter
    private String organizationId;

    @SuperBuilder
    public SimpleOpenaAI(@NonNull String apiKey, String baseUrl, HttpClient httpClient, String organizatonId) {
        super(apiKey, baseUrl, httpClient);
        this.organizationId = organizationId;
        postConstructor();
    }

    protected void customSetup() {
        baseUrl = Optional.ofNullable(baseUrl).orElse(OPENAI_BASE_URL);
        headers.put(AUTHORIZATION_HEADER, BEARER_AUTHORIZATION + apiKey);
        if (organizationId != null) {
            headers.put(ORGANIZATION_HEADER, organizationId);
        }
    }

    // Don't need to implement common services (ie: chatCompletions), but no-common, do.

    public OpenAI.Audios audios() {
        if (audioService == null) {
            audioService = cleverClient.create(OpenAI.Audios.class);
        }
        return audioService;
    }

    public OpenAI.Completions completions() {
        if (completionService == null) {
            completionService = cleverClient.create(OpenAI.Completions.class);
        }
        return completionService;
    }

    // etc.

}

Now, SimpleOpenAIAzure can add the specific parameters and doesn't need overwrite any services:
public class SimpleOpenAIAzure {

    @Getter
    private String apiVersion;

    @SuperBuilder
    public SimpleOpenaAI(@NonNull String apiKey, @NonNull String baseUrl, HttpClient httpClient, @NonNull String apiVersion) {
        super(apiKey, baseUrl, httpClient);
        this.apiVersion = apiVersion;
        postConstructor();
    }

    protected void customSetup() {
        headers.put(APIKEY_HEADER, apiKey);
        requestInterceptor = request -> {
            // modify the url to add the property 'this.apiVersion' as query param
            // modify the url to remove /v1
            // modify the body to remove the model property
            return request;
        }
    }

    // Don't need to implement any service.
}

@the-gigi
Regarding your change in the ChatRequest class, I'm afraid that is not the right place to do it. We are using constructors as an exceptional place to do special validation logic, in this case, for properties that could be one of several types. I'm thinking of replacing that special validation with annotations, so we won't need to declare explicit constructors.
The right place for your change is on the OpenAI interface on the default methods. Specifically, you should do your change here for blocking chats and here for streaming chats.
Take in account that we are working with immutable objects, so, you need to use the Lombok's @With annotation for the field that you are going to change, in this case toolChoice and you should chain it with the existing one for the field stream.

@the-gigi
I see a small improvement in the url for SimpleOpenAIAzure:
public class SimpleOpenAIAzure extends BaseSimpleOpenaAI {

    @Getter
    private String apiVersion;

    @SuperBuilder
    public SimpleOpenaAI(@NonNull String apiKey, @NonNull String baseUrl, @NonNull String resourceName, @NonNull String deploymentId, HttpClient httpClient, @NonNull String apiVersion) {
        super(apiKey, "https://"+resourceName+Optional.ofNullable(baseUrl).orElse(AZURE_BASE_URL)+deploymentId, httpClient);
        this.apiVersion = apiVersion;
        postConstructor();
    }

    ...
}

@sashirestela this all sounds good.
I'm not clear about the value that postConstructor() and customSetup() methods provide. in your sample code BaseSimpleOpenAI creates the cleverclient in the postConstructor, but it doesn't call postConstructor() at the end of  the BaseSimpleOpenaAI constructor. This means that sub-classes are now responsible for calling postConstructor() in order for the base class to have a cleverclient.
Also, postConstructor is protected, which means sub-classes can override it and do anything they want instead of creating a cleverclient.
@SuperBuilder
    public BaseSimpleOpenaAI(String apiKey, String baseUrl, HttpClient httpClient) {
        this.apiKey = apiKey;
        this.baseUrl = baseUrl;
        this.httpClient = Optional.ofNullable(httpClient).orElse(HttpClient.newHttpClient());
        this.headers = new HashMap<String, String>();
        this.requestInterceptor = null;
    }

  protected void postContructor() {
        customSetup();
        this.cleverClient = CleverClient.builder()
                .httpClient(this.httpClient)
                .baseUrl(this.baseUrl)
                .headers(headers)
                .endOfStream(END_OF_STREAM)
                .requestInterceptor(requestInterceptor)
                .build();
    }

is it possible you meant to call postConstructor() here and make it private while the protected customSetup()is where sub-classes do their customization? something like:
@SuperBuilder
    public BaseSimpleOpenaAI(String apiKey, String baseUrl, HttpClient httpClient) {
        this.apiKey = apiKey;
        this.baseUrl = baseUrl;
        this.httpClient = Optional.ofNullable(httpClient).orElse(HttpClient.newHttpClient());
        this.headers = new HashMap<String, String>();
        this.requestInterceptor = null;
        this.postConstructor();
    }

  private void postContructor() {
        customSetup();
        this.cleverClient = CleverClient.builder()
                .httpClient(this.httpClient)
                .baseUrl(this.baseUrl)
                .headers(this.headers)
                .endOfStream(END_OF_STREAM)
                .requestInterceptor(requestInterceptor)
                .build();
    }

However in this case, the postConstructor logic can just be collapsed into the constructor as in:
@SuperBuilder
    public BaseSimpleOpenaAI(String apiKey, String baseUrl, HttpClient httpClient) {
        this.apiKey = apiKey;
        this.baseUrl = baseUrl;
        this.httpClient = Optional.ofNullable(httpClient).orElse(HttpClient.newHttpClient());
        this.headers = new HashMap<String, String>();
        this.requestInterceptor = null;
        // call protected method potentially overridden by sub-class
        customSetup();
        this.cleverClient = CleverClient.builder()
                .httpClient(this.httpClient)
                .baseUrl(this.baseUrl)
                .headers(headers)
                .endOfStream(END_OF_STREAM)
                .requestInterceptor(requestInterceptor)
                .build();
    }

This workflow allows the sub-class to modify the fields of the base class used to build the clever client. However, this has some problems.
First, when looking at the constructor it's not clear what parameters are needed. it divides the parameters into 3 groups: mandatory constructor arguments.(apiKey and baseUrl), optional constructor arguments (httpClient) and "hidden" optional arguments that may be set in customSetup() like the headers and the request interceptor. Another problem is that different parameters can be set in 3 different places now.
For example, the httpClient can be passed as constructor argument or as null and then a default HttpClient is created. But, it can also be overridden in customSetup() later. Similarly, baseUrl can be passed as constructor argument, be set later in customSetup() and also be modified later in requestInterceptor. This can be very confusing when trying to troubleshoot some misbehaving sub-class.
What do you think about this alternative?
BaseSimpleOpenAi has a constructor that takes a single argument BaseSimpleOpenAiArgs.
It is now responsible for two things only:

creating the default httpClient if it wasn't provided
create the cleverclient

It is very clean now nad has a single filed for cleverClient (with a setter because of the tests)
and another one for the chat completion service.
public class BaseSimpleOpenAI {

    private static final String END_OF_STREAM = "[DONE]";

    @Setter
    protected CleverClient cleverClient;

    protected OpenAI.ChatCompletions chatCompletionService;

    BaseSimpleOpenAI(@NonNull BaseSimpleOpenAiArgs args) {
        var httpClient =
            Optional.ofNullable(args.getHttpClient()).orElse(HttpClient.newHttpClient());
        this.cleverClient = CleverClient.builder()
            .httpClient(httpClient)
            .baseUrl(args.getBaseUrl())
            .headers(args.getHeaders())
            .endOfStream(END_OF_STREAM)
            .requestInterceptor(args.getRequestInterceptor())
            .build();
    }

It also has per your suggestion the implementation of chat services and throw the
not implemented exception for all the other endpoints:
    /**
     * Throw not implemented
     */
    public OpenAI.Audios audios() {
        throw new SimpleUncheckedException("Not implemented");
    }

    /**
     * Generates an implementation of the ChatCompletions interface to handle
     * requests.
     *
     * @return An instance of the interface. It is created only once.
     */
    public OpenAI.ChatCompletions chatCompletions() {
        if (this.chatCompletionService == null) {
            this.chatCompletionService = this.cleverClient.create(OpenAI.ChatCompletions.class);
        }
        return this.chatCompletionService;

    }

// the rest of endpoint also throw "Not implemented"

BaseSimpleOpenAiArgs has all the arguments needed to build a clever client and a builder
@Getter
@Builder
public class BaseSimpleOpenAiArgs {
    @NonNull
    private final String baseUrl;
    private final Map<String, String> headers;
    private final HttpClient httpClient;
    private final UnaryOperator<HttpRequestData> requestInterceptor;
}

Note that it doesn't have an api key because the different providers will already
embed the API key in one of the headers.
Finally, the different providers are very simple too. Their constructor is just one line
calling the super() with BaseSimpleOpenAiArgs that they create in a static method called
prepareBaseSimpleOpenAiArgs().
Here SimpleOpenAI
    private static BaseSimpleOpenAiArgs prepareBaseSimpleOpenAiArgs(
        String apiKey, String organizationId, String baseUrl, HttpClient httpClient) {

        var headers = new HashMap<String, String>();
        headers.put(AUTHORIZATION_HEADER, BEARER_AUTHORIZATION + apiKey);
        if (organizationId != null) {
            headers.put(ORGANIZATION_HEADER, organizationId);
        }

        return BaseSimpleOpenAiArgs.builder()
            .baseUrl(Optional.ofNullable(baseUrl).orElse(OPENAI_BASE_URL))
            .headers(headers)
            .httpClient(httpClient)
            .build();
    }

    @Builder
    public SimpleOpenAI(@NonNull String apiKey, String organizationId, String baseUrl, HttpClient httpClient) {
        super(prepareBaseSimpleOpenAiArgs(apiKey, organizationId, baseUrl, httpClient));
    }

There is no need even for @SuperBuilder because the base class doesn't have a builder.
It just accepts in its constructor the BaseSimpleOpenAIArgs, which has a @Builder.
SimpleOpenAI also implements all the endpoints except chatServices that the base already implements:
    /**
     * Generates an implementation of the Audios interface to handle requests.
     *
     * @return An instance of the interface. It is created only once.
     */
    public OpenAI.Audios audios() {
        if (audioService == null) {
            audioService = cleverClient.create(OpenAI.Audios.class);
        }
        return audioService;
    }

    // and the rest of the endpoints

With this design we can also get rid in OpenSimpleAI from all the @Getter(AccessLevel.NONE)
annotation on all the fields as well as the overall @Getter on the class itself. There is no
need to get any field ever because it doesn't keep any fields everything goes to the base class.
SimpleOpenAIAnyscale is the simplest. Here is literally the entire class:
public class SimpleOpenAIAnyscale extends BaseSimpleOpenAI {

    private static final String AUTHORIZATION_HEADER = "Authorization";
    private static final String BEARER_AUTHORIZATION = "Bearer ";

    /**
     * Constructor used to generate a builder.
     *
     * @param apiKey         Identifier to be used for authentication. Mandatory.
     * @param baseUrl        Host's url
     * @param httpClient     A {@link java.net.http.HttpClient HttpClient} object.
     *                       One is created by default if not provided. Optional.
     */
    private static BaseSimpleOpenAiArgs prepareBaseSimpleOpenAiArgs(
        String apiKey, String baseUrl, HttpClient httpClient) {

        var headers = new HashMap<String, String>();
        headers.put(AUTHORIZATION_HEADER, BEARER_AUTHORIZATION + apiKey);

        return BaseSimpleOpenAiArgs.builder()
            .baseUrl(baseUrl)
            .headers(headers)
            .httpClient(httpClient)
            .build();
    }

    @Builder
    public SimpleOpenAIAnyscale(
        @NonNull String apiKey,
        @NonNull String baseUrl,
        HttpClient httpClient) {
        super(prepareBaseSimpleOpenAiArgs(apiKey, baseUrl, httpClient));
    }
}

SimpleOpenAiAzure is similar except it sets a request interceptor too in its prepare method:
public class SimpleOpenAIAzure extends BaseSimpleOpenAI {

    private static BaseSimpleOpenAiArgs prepareBaseSimpleOpenAiArgs(
        String apiKey, String baseUrl, String apiVersion, HttpClient httpClient) {

        var headers = Map.of("api-Key", apiKey);

        // Inline the UnaryOperator<HttpRequestData> as a lambda directly.
        var requestInterceptor = (UnaryOperator<HttpRequestData>) request -> {
            var url = request.getUrl();
            var contentType = request.getContentType();
            var body = request.getBody();

            // add a query parameter to url
            url += (url.contains("?") ? "&" : "?") + "api-version=" + apiVersion;
            // remove '/vN' or '/vN.M' from url
            url = url.replaceFirst("(\\/v\\d+\\.*\\d*)", "");
            request.setUrl(url);

            if (contentType != null) {
                if (contentType.equals(ContentType.APPLICATION_JSON)) {
                    var bodyJson = (String) request.getBody();
                    // remove a field from body (as Json)
                    bodyJson = bodyJson.replaceFirst(",?\"model\":\"[^\"]*\",?", "");
                    bodyJson = bodyJson.replaceFirst("\"\"", "\",\"");
                    body = bodyJson;
                }
                if (contentType.equals(ContentType.MULTIPART_FORMDATA)) {
                    var bodyMap = (Map<String, Object>) request.getBody();
                    // remove a field from body (as Map)
                    bodyMap.remove("model");
                    body = bodyMap;
                }
                request.setBody(body);
            }

            return request;
        };

        return BaseSimpleOpenAiArgs.builder()
            .baseUrl(baseUrl)
            .headers(headers)
            .httpClient(httpClient)
            .requestInterceptor(requestInterceptor)
            .build();
    }

    /**
     * Constructor used to generate a builder.
     *
     * @param apiKey         Identifier to be used for authentication. Mandatory.
     * @param baseUrl        The URL of the Azure OpenAI deployment.   Mandatory.
     * @param apiVersion     Azure OpeAI API version. See:
     *                       <a href="https://learn.microsoft.com/en-us/azure/ai-services/openai/reference#rest-api-versioning">Azure OpenAI API versioning</a>
     * @param httpClient     A {@link HttpClient HttpClient} object.
     *                       One is created by default if not provided. Optional.
     */
    @Builder
    public SimpleOpenAIAzure(
        @NonNull String apiKey,
        @NonNull String baseUrl,
        @NonNull String apiVersion,
        HttpClient httpClient) {
        super(prepareBaseSimpleOpenAiArgs(apiKey, baseUrl, apiVersion, httpClient));
    }
}

@the-gigi
Your proposal is not bad. Let's move in that direction. I'm going to review the code details.


timeline for code release

Hi @mlii0117 ,
Thanks for sharing the great work.
Any timeline on releasing the code?

The code has been released, thanks for your interest.


Incomplete README

In your README you say "In addition to this setting, there's a CTags.sublime-settings file", however there's no information on how to find this file or whether it should be created and placed into any specific directory (OSX).
Please add that as it's confusing for non-exerienced users.

Settings are available via Command Palette as of v0.6.0
see Preferences: CTags Settings


Bap 98 create project template for behaviour.automation

See https://quantori.atlassian.net/jira/software/projects/BAP/boards/69?selectedIssue=BAP-98 for more details

What if we change the folder structure a little bit?

Bindings
ElementWrappers
ElementStorage


[BUG] Fix misalignment in footer links

What does this PR do and why?
Fix misalignment in footer as a result of extra new language options.
Screenshots or screen recordings

Acceptance checklist

[x] I have evaluated the Approval Guidelines for this PR.
[x] I have tested this PR in all supported browsers.

@johnnyd-eth are you done with this? looks good to me!

@johnnyd-eth are you done with this? looks good to me!

@peripheralist yep all done!


Problem with building a static binary

What did I expect?
When trying to build a static library using cargo build --features v0_10_0 static I would have expected that cargo would try to link against a statically compiled LLVM.
What actually happened?
Instead cargo tried linking against a dynamically compiled LLVM. The error message I got was:
vagrant@ubuntu-bionic:~/rust-bpf/bcc-sys$ cargo build --features v0_10_0 static
   Compiling bcc-sys v0.10.3-alpha.0 (/home/vagrant/rust-bpf/bcc-sys)
error: could not find native static library 'LLVM-6.0', perhaps an -L flag is missing?

error: aborting due to previous error

error: Could not compile 'bcc-sys'.

To learn more, run the command again with --verbose.

There is no libllvm-6.0.a file and from what I understand from running llvm-config --libs --link-static you need to compile against all the static libraries that this command outputs. Adding .args(--link-static) to the build.rs fixed the issue for me. I'm happy to open a PR with this fix.
What steps can we take to reproduce the behaviour you saw?
I'm running ubuntu 18.04 with version 6.0 of the LLVM toolchain. Other steps are described above.

Thanks for opening this. The static linking is a little weird - and hard to test in CI with the long build times. When I've used the static option, I actually build all of the toolchain and some non-obvious dependencies from source. This would definitely be an area to document better.
Here's the versions that I build and install from sources: (export CFLAGS="-fPIC" before builds) I actually set the install prefix for each to a local folder to avoid system-wide install. Then I update the rustflags variable to match export RUSTFLAGS="-L ${PREFIX}/lib -L ${PREFIX}/lib64"
zlib-1.2.7.tar.bz2
xz-5.2.2.tar.gz
ncurses-6.0.tar.gz (--with-termlib)
libxml2-2.9.1.tar.gz (--without-python)
elfutils-0.170.tar.bz2
llvm-8.0.0.src.tar.xz (-DLLVM_TARGETS_TO_BUILD='BPF;X86')
cfe-8.0.0.src.tar.xz
bcc-0.10.0.tar.gz
And after bcc is built, copy the .a files to the install folders.
find . -name "*.a" -exec cp {} ${PREFIX}/lib/ \;
The current build.rs works in combination with the above. At the time, I hadn't found a much better way to deal with this - curious if we can improve the build itself, or at least just the documentation.


Added where_trailing_comma option.

The default is 'false', since a lot of the time there's only a single predicate. Resolves #588.

Thanks for the PR! Could you add some tests please? To see how to set config options in tests, see this line

I think I've covered all the places where clauses can appear.
We don't get the trailing comma in trait definitions, though, given issue #78.

Great, thank you!


handle map[*A]B better

I have a map[*MyStruct]OtherThing.  Even with SortKeys set to true, the map ordering is non-deterministic (pointers, duh).  I wonder if we could do something more heavyweight but deterministic when *MyStruct does not have a String() method?  Maybe a new config option like SpewKeys which would apply the same spew conversion to each map key, then sort the resulting strings.
I understand it's a pretty niche case, but  it would be useful in our generic "hash object" logic.
Alternatively, some way to get an error for a non-deterministic spew?

Actually, it's worse than this - even maps with structs as keys are broken.
The docs say sorted according to the reflect.Value.String() which (incorrectly) made me think that I could define String() for my struct and it would work.  This is not the case.    This obviously produces random sort order because map is random order.
Can we do better?  You already handle testing for error and Stringer in other places...

Quick hacks to convert to stringer in valueSorter.Less fixes my use case...

FWIW I can (try to) implement if you're open to something here.

ping?  I just want to know if you're open to a fix here or not - if not I have to commit my own workarounds and caveats to our tree.

@thockin: Sorry for the delay.  I've been deep in btcd/wallet stuff.  I don't mind having an option for it.

Thanks.  I'll think about a change and see if I can get you a PR.
On Tue, Mar 31, 2015 at 10:16 AM, Dave Collins<EMAIL_ADDRESS>wrote:

@thockin https://github.com/thockin: Sorry for the delay. I've been
deep in btcd/wallet stuff. I don't mind having an option for it.
—
Reply to this email directly or view it on GitHub
https://github.com/davecgh/go-spew/issues/30#issuecomment-88176174.

Implemented by #31.


test: smoke test gha

Fixes: #746
The intention behind this PR is on every push/pr run this action: https://github.com/rehearsal-js/smoke-test/blob/master/.github/workflows/run-smoke-test.yml.
The smoke-test-action will:

download the master branch zip from https://github.com/rehearsal-js/rehearsal-js/archive/refs/heads/master.zip
pack the tarball for the @rehearsal/cli from zip rather than from NPM and as file:dep
run test suite from https://github.com/rehearsal-js/smoke-test/tree/master/test
if the test suite passes this action should pass

As this is within the rehearsal-js org we shouldn't need to deal with auth tokens.
The downsides with this implementation:

we are downloading from master rather than from the PR/commit/branch. as such we will only have an integration pulse after PR merge into master (we still catch way before release)
I would like to also implement a life cycle catch to run the smoke-test on prepublish

We might need to leverage a different GHA event: https://docs.github.com/en/actions/using-workflows/events-that-trigger-workflows#repository_dispatch. TBD


Remove deprecated APIs in v0.13.0

v0.13.0 allows for breaking API changes (as long as we use the versioning compat views to keep old modules working).

[x] So we can remove the following APIs (done in https://github.com/dagger/dagger/pull/8281)

Container.WithExec's skipEntrypoint, deprecated in https://github.com/dagger/dagger/pull/7136
pipeline APIs, deprecated in https://github.com/dagger/dagger/pull/8064
GitModuleSource.cloneURL, deprecated in https://github.com/dagger/dagger/pull/7708

[ ] As well as the following python SDK functionality:

Top-level functions, deprecated in https://github.com/dagger/dagger/pull/8074
Arg, deprecated in https://github.com/dagger/dagger/pull/8109

The Python deprecations haven't been removed yet, but we can push it to 0.14.


[FLINK-28853][connector-base] Add FLIP-217 support for watermark alignment of source splits

What is the purpose of the change

The change implements FLIP-217 (https://cwiki.apache.org/confluence/display/FLINK/FLIP-217+Support+watermark+alignment+of+source+splits) to support watermark alignment of source splits.

Brief change log

Revised SplitFetcher threading model and add support to pause/resume SplitFetcher
Adds support for watermark alignment of individual source splits controlled by SourceOperator
Adds support for split watermark alignment for Kafka and Pulsar sources
Adds configuration parameter to allow unaligned splits as migration plan to support legacy sources that lack support for split alignment

Verifying this change
This change added and extended tests and can be verified as follows:

SplitFetcherTest extended to test pause/resume ofSplitFetcher
SourceOperatorSplitWatermarkAlignmentTest added to test split alignment based on split reader watermarks
SplitFetcherPauseResumeSplitReaderITCase added to test pause/resume of individual split readers

Does this pull request potentially affect one of the following parts:

Dependencies (does it add or upgrade a dependency): no
The public API, i.e., is any changed class annotated with @Public(Evolving): yes (according to FLIP-217)
The serializers: no
The runtime per-record code paths (performance sensitive): no
Anything that affects deployment or recovery: no
The S3 file system connector: no

Documentation

Does this pull request introduce a new feature? yes
If yes, how is the feature documented? docs (configuration parameter) and JavaDocs (changes of public APIs)

Any thoughts on how and when to proceed with this PR? We'd like to help to bring this over the finish line.

I wonder about the way the SourceOperator calls through the stack via pauseOrResumeSplits while also being called back with watermarks. My intuition would have been to do the pausing directly at the splits based on the current max watermark lag, e.g. by putting splits into a suspended mode where no more output is accepted from a split. I guess this could be tricky because the implementation of the source doesn't necessarily know it's paused and could timeout or otherwise misbehave. So it looks like the current implementation is simpler.

Currently Splits are just pojos, data carriers, without much logic. If I understand you correctly, what you are suggesting would require us to push some availability logic down to the splits and it would still require handling of this availability in the SourceReader - basically the same logic that we have in the current proposal. The difference would be only that SourceReader would be informed about (un)availability change of a split, from the split, instead of from the pauseOrResume call.
Given that most of the users are expected to just use SourceReaderBase, the current proposal gives them watermark alignment for free. While adding availability logic to the splits would increase exposure of this feature in the public API, without much benefit?

Any thoughts on how and when to proceed with this PR? We'd like to help to bring this over the finish line.

Indeed there is an issue now, that I think @smattheis doesn't work on Flink anymore, so he can not finish this PR. I will go through the PR myself and do a quick pass/respond to the inlined questions from you @mxm  and @mas-chen , but it would be great if someone could take over applying the actual changes after the review. Would you be up to do that @mxm ?

It looks like I will have to open a new PR because @smattheis hasn't checked the option "Allow edits by maintainers". I can't push to the branch.

The next question would be how to squash the commits? If you want to preserve authorship of your changes @mxm, without overwriting authors of the base commits, we would need either a single fixup commit from you, all one your fixup per original commit.

 IMHO there is no benefit in merging the individual commits because they are very much tight to each other. This keeps the history clean while retaining authorship. What do you think?

 IMHO there is no benefit in merging the individual commits because they are very much tight to each other. This keeps the history clean while retaining authorship. What do you think?

I wouldn't squash all commits into one. The original commits authored by Sebastian, Dawid and Arvid I think are nicely separated. But sure, squashing your fixups to those commits and co-authoring them is also perfectly fine.

@flinkbot run azure

@mxm Thanks a lot also from my side for you contributions. However, @pnowojski this PR was not orphaned! (I wrote to you that I'm on vacations.)

Thank you @pnowojski for your thoughtful comments and guidance. And of course thanks to the original authors @AHeise @dawidwys @smattheis.
Whoops @smattheis I had assumed you wouldn't continue on this PR but I think no harm has been done. Let me know if anything is open on your side. It still need to revise the code with respect to a test failure.

@mxm Thanks a lot also from my side for you contributions. However, @pnowojski this PR was not orphaned! (I wrote to you that I'm on vacations.)

Yes, sorry for the mental shortcut. There was a delay in the communication between first my vacations and then yours. Around the time @mxm was asking how to continue with this PR, you @smattheis were not responding, and I got a message from you that you can work on it only after @mxm has already volunteered to take it over. After that I didn't want to create more confusion. But sorry for my inaccurate statement that it was "orphaned" :)

@mxm @pnowojski All good. Thanks for driving it.

(Rebased)

@flinkbot run azure

There are still some related test failures:

Documented option pipeline.watermark-alignment.allow-unaligned-source-splits does not exist.

and

Sep 09 15:10:03 [ERROR] Errors:
Sep 09 15:10:03 [ERROR]   PulsarUnorderedSourceReaderTest.supportsPausingOrResumingSplits(PulsarSourceReaderBase, Boundedness, String)[1] » Timeout
Sep 09 15:10:03 [ERROR]   PulsarUnorderedSourceReaderTest.supportsPausingOrResumingSplits(PulsarSourceReaderBase, Boundedness, String)[2] » Timeout

Thanks @pnowojski. Will fix those.
On another note, do you think it makes sense to add a configuration option to disable using split alignment entirely? I'm a bit worried this feature might cause issues with the already integrated Kafka/Pulsar sources that we are not foreseeing right now. The added configuration option only allows to disable split alignments for non-compatible connectors. We could add another option to disable it entirely to retain the old behavior (disabled by default).

There are still some related test failures:

Documented option pipeline.watermark-alignment.allow-unaligned-source-splits does not exist.

I had to remove the @Deprecated flag from the configuration option. Otherwise, it will be undocumented.

@flinkbot run azure

On another note, do you think it makes sense to add a configuration option to disable using split alignment entirely? I'm a bit worried this feature might cause issues with the already integrated Kafka/Pulsar sources that we are not foreseeing right now. The added configuration option only allows to disable split alignments for non-compatible connectors. We could add another option to disable it entirely to retain the old behavior (disabled by default).

Does it make sense to use and enable watermark alignment via DataStream API to only disable it via config value? Keep in mind that user has to manually enable via WatermarkStrategy#withWatermarkAlignment call [1].
[1] https://nightlies.apache.org/flink/flink-docs-master/docs/dev/datastream/event-time/generating_watermarks/#watermark-alignment-beta

Fair point, users may modify the job to disable alignment. It doesn't make sense to override the watermark alignment settings from the config.

Fair point, users may modify the job to disable alignment. It doesn't make sense to override the watermark alignment settings from the config. But the same argument applies to the other configuration option to disable split alignment for not-ready sources. I think it would make sense to provide a transitory option to disable split alignment altogether until this feature has proven to be stable.

@flinkbot run azure

Tests are passing now.

Thank you everyone!

Thank you for taking over! @mxm

Exciting to see this make the finish line! This was a long awaited feature (we implemented alignment for the Kinesis source ~4 years ago). Let's see how it holds up in production use cases!
Thanks @mxm @pnowojski @smattheis  @dawidwys, @AHeise for your contributions!

Yes, it took longer than it should have. Good that it's finally been merged 🎉


merge latest ui_ng code in

merge latest ui_ng code in

Coverage remained the same at 54.272% when pulling e115f8b577a57e1c19ebdc78fa6d84317084d5eb on feature/update_ui_ng_code into<PHONE_NUMBER>ea4a0581051aca20846a50516a8a85 on dev.


fix heap buffer overflow in yaml_emitter_emit_flow_mapping_key and fix stack overflow in yaml_emitter_anchor_node

#226
#228

/retest

This is only treating a symptom caused by a mistake in the oss-fuzz code, which I fixed here: https://github.com/google/oss-fuzz/pull/11818


fix: KubeletConfig not defaulted properly gives invalid values for ProvisionProfile in bootstrappingclient mode

Fixes #
Description
KubeletConfig retrieved from nodeClaim doesn't seem to have a proper defaulting(?), which could returns invalid values (e.g., out of range) when populating ProvisionProfile. The logic added here should isolate non-pointer values (which cannot be "unpopulated" by being nil) and have an empty check.
How was this change tested?

Manual provisioning test
Inspecting ProvisionProfile values

Does this change impact docs?

[ ] Yes, PR includes docs updates
[ ] Yes, issue opened: #
[X] No

Release Note

NONE

Pull Request Test Coverage Report for Build<PHONE_NUMBER>8
Details

0 of 14 (0.0%)  changed or added relevant lines in 1 file are covered.
No unchanged relevant lines lost coverage.
Overall coverage decreased (-0.02%) to 94.228%

Changes Missing Coverage
Covered Lines
Changed/Added Lines
%

pkg/providers/imagefamily/customscriptsbootstrap/provisionclientbootstrap.go
0
14
0.0%

Totals

Change from base Build<PHONE_NUMBER>6:
-0.02%

Covered Lines:
37142

Relevant Lines:
39417

💛  - Coveralls


Fix statistics type (no longer collection)

Changes statistics methods return type from PaginatedList<Statistics> to Statistics and changed the Statistics type to include possible CompositeView values collection property

Codecov Report

:exclamation: No coverage uploaded for pull request base (master@d92e939). Click here to learn what that means.
The diff coverage is n/a.

@@           Coverage Diff            @@
##             master    #320   +/-   ##
========================================
  Coverage          ?   84.8%
========================================
  Files             ?      21
  Lines             ?     454
  Branches          ?      94
========================================
  Hits              ?     385
  Misses            ?      67
  Partials          ?       2

Impacted Files
Coverage Δ

packages/nexus-sdk/src/View/index.ts
82.35% <ø> (ø)

Continue to review full report at Codecov.

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


python310Packages.stumpy: 1.10.2 -> 1.11.1

Automatic update generated by nixpkgs-update tools. This update was made based on information from passthru.updateScript.
meta.description for python310Packages.stumpy is: "A powerful and scalable library that can be used for a variety of time series data mining tasks"
meta.homepage for python310Packages.stumpy is: "https://github.com/TDAmeritrade/stumpy"
meta.changelog for python310Packages.stumpy is: ""
Updates performed

Ran passthru.UpdateScript

To inspect upstream changes
Impact

Checks done (click to expand)

built on NixOS
Warning: a test defined in passthru.tests did not pass
found 1.11.1 with grep in /nix/store/1jrnfkpp7xb4qdm24jygmb9n1z9p2x39-python3.10-stumpy-1.11.1
found 1.11.1 in filename of file in /nix/store/1jrnfkpp7xb4qdm24jygmb9n1z9p2x39-python3.10-stumpy-1.11.1

Rebuild report (if merged into master) (click to expand)

4 total rebuild path(s)

2 package rebuild(s)

2 x86_64-linux rebuild(s)
2 x86_64-darwin rebuild(s)

First fifty rebuilds by attrpath
python310Packages.stumpy
python39Packages.stumpy

Instructions to test this update (click to expand)

Either download from Cachix:
nix-store -r /nix/store/1jrnfkpp7xb4qdm24jygmb9n1z9p2x39-python3.10-stumpy-1.11.1 \
  --option binary-caches 'https://cache.nixos.org/ https://nix-community.cachix.org/' \
  --option trusted-public-keys '
  nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=
  cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=
  '

(The Cachix cache is only trusted for this store-path realization.)
For the Cachix download to work, your user must be in the trusted-users list or you can use sudo since root is effectively trusted.
Or, build yourself:
nix-build -A python310Packages.stumpy https://github.com/r-ryantm/nixpkgs/archive/208b83c576aff0707744e1ec8f687b3112094662.tar.gz

After you've downloaded or built it, look at the files and if there are any, run the binaries:
ls -la /nix/store/1jrnfkpp7xb4qdm24jygmb9n1z9p2x39-python3.10-stumpy-1.11.1
ls -la /nix/store/1jrnfkpp7xb4qdm24jygmb9n1z9p2x39-python3.10-stumpy-1.11.1/bin

Pre-merge build results
We have automatically built all packages that will get rebuilt due to
this change.
This gives evidence on whether the upgrade will break dependent packages.
Note sometimes packages show up as failed to build independent of the
change, simply because they are already broken on the target branch.
Result of nixpkgs-review run on x86_64-linux 1

2 packages built:

python310Packages.stumpy
python39Packages.stumpy

Maintainer pings
cc @costrouc for testing.

Result of nixpkgs-review pr 175061 run on x86_64-linux 1

2 packages built:

python310Packages.stumpy
python39Packages.stumpy


[firestore] Shouldn't a start/end query cursor allow empty set?

var anomaly = await firestoreDB.Value.Collection("col").OrderByDescending("field").StartAt(new object[0])

This above line cause an error does not allow empty set at a start/end query cursor
But doesn't this should be allowed for query the empty array and null? Actually it should let me got the whole documents which has value of that field not an array nor object?
Is it really a limit in firestore or just this library?

Am I right in saying the error message is actually the following?
Cannot specify an empty set of values for a start/end query cursor

It's helpful if you copy/paste the exact error message - I initially searched for what you posted (with "does not" instead of "Cannot") and that's not in the repo, so it took longer to find this.
But yes, this is a deliberate restriction, and is documented. (fieldValues can't be empty.) If you created an array with a single (null) element, that would be fine. That said, I don't think the Java library has this restriction, so we may be able to remove it. I'll consult with the team.

@jskeet Yes that's the correct message

Right. I've asked internally about the intended behavior. It should be easy to fix if it should be allowed - and we'll add a conformance test either way to make sure all languages are consistent.

@Thaina I'm reopening this because we've rethought the policy across all SDKs. Previously, C# was the only SDK to validate this explicitly, although Node.js did so implicitly, throwing a not-terribly-helpful exception.
We (the Firestore team and client library developers) have decided that we should validate this and prohibit an empty set of values - reverting the previous change. We don't think many developers want this functionality (as otherwise they would have requested it in Node.js) and we'd prefer them to receive an exception if they accidentally provide no values. However, it should be easy enough for you to add an extension method to your codebase to allow you to handle your specific use case. You'd write something like:
public static class QueryExtensions
{
    public static Query MaybeStartAt(this Query query, object[] values) =>
        values.Length == 0 ? query : query.StartAt(values);
}

(You could add null validation for both query and values if you want.)
Does that sound okay? I'd like to make the change reasonably soon, but I don't want to release with the restriction in place until you've had a chance to add the workaround.

I think this should not be the case to prohibit
The reason is. The empty array value is the valid value of field in firestore
{
    "__name__" : "A",
    "field" : [] // valid and should be able to queried
}

Also what happen if we use this document as the StartOf? Suppose we query by OrderBy("field").Limit(10) and this document just happen to be the 10th and so we use the same query to OrderBy("field").Limit(10).StartAfter(results.Last())
Also in the specification of firestore, the Array, even it's empty, would be ordered after the string and before object, not null. Same go for the object, even empty will be ordered after any array. So trying to query it after null is not really correct
I think we should put that exception in js as a bug instead

It's fine to pass an empty value as "a value in the StartAt sequence". What's not fine is to post on values.
So for example, I'd expect this to work:
var emptyValue = new List<string>;
query = query.StartAt(new object[] { emptyValue });

But this shouldn't:
query = query.StartAt(new object[0]);

That's trying to start at "an empty sequence of values" rather than "a sequence of values with a single element, which is an empty list/array".

@jskeet I think in firestore we could not have array in array?
And also I think the array with 1 element would be ordered after the array with 0 element too

@jskeet My point is, suppose we have this kind of document in database
{
    "__name__" : "A",
    "field" : null
},
{
    "__name__" : "B",
    "field" : ""
},
{
    "__name__" : "C",
    "field" : []
},
{
    "__name__" : "D",
    "field" : [null]
},
{
    "__name__" : "E",
    "field" : [""]
},
{
    "__name__" : "F",
    "field" : [{}]
}

I would expect it to work like this
var result0 = await fireStoreDB.OrderBy("field").Limit(10).StartAt(null).StreamAsync().ToArray();
// A,B,C,D,E,F

var result1 = await fireStoreDB.OrderBy("field").Limit(10).StartAt(new object[0]).StreamAsync().ToArray();
// C,D,E,F

var result2 = await fireStoreDB.OrderBy("field").Limit(10).StartAfter(new object[0]).StreamAsync().ToArray();
// D,E,F

var result3 = await fireStoreDB.OrderBy("field").Limit(10).StartAfter(new object[] {
new List<object>() }).StreamAsync().ToArray();
// F << Array of 1 array should ordered after array or 1 null or array of 1 string

@jskeet Also by empty set, I think you would also mean empty object?
Empty object also ordered after every array. And it would be hard to specified the least value of object too
And also I think the firestore REST API does not prohibit the empty array or empty object isn't it? If firestore server itself permit the value, I don't think it should be any reason to prohibit it on the SDK

I think all of this is explained by StartAt accepting a parameter array. StartAt(null) doesn't try to start at a single null value - it's passing null as the sequence itself. Likewise StartAt(new object[0]) is passing the empty array as the sequence of values. That's not what you intended to do.
It's easy to fix that: just cast to object first or use an object local variable:
object value = null;
query = query.StartAt(value);

That will then be handled by the compiler as:
object value = null;
query = query.StartAt(new object[] { value });

And that's what you intended. You're trying to pass a single value - but because both the null literal and new object[0] are applicable without parameter array expansion, the compiler isn't creating a "wrapper" array for you.
This isn't specific to Firestore - here's an equivalent example just using Console.WriteLine:
// Succeeds
object value = new object[0];
Console.WriteLine("Value: {0}", value);

// Fails
Console.WriteLine("Value: {0}", new object[0]);

Empty object also ordered after every array. And it would be hard to specified the least value of object too

That's completely irrelevant, because you're not passing in an empty object as "the thing to start at". You're passing no objects as "the sequence of values to start at" and that's the problem. See my previous comment for how to get it to do what you want.

@jskeet If I understand you correctly, what you trying to say is, because firestore StartAt function (and Console.WriteLine) are using params so it ambiguously between object[0] as params or as an array itself
But then this is not related to passing empty set. It should just be solved by putting StartAt(new List<object>()) which would not ambiguous with params, without the need to wrap it with array

@jskeet If I understand you correctly, what you trying to say is, because firestore StartAt function (and Console.WriteLine) are using params so it ambiguously between object[0] as params or as an array itself

Yes.

But then this is not related to passing empty set. It should just be solved by putting StartAt(new List()) which would not ambiguous with params, without the need to wrap it with array

Yes, I'd expect that to be fine - the compiler will wrap it in an object[]. There are lots of ways of making sure that what the method receives is an array with a single element, rather than an empty array.

@jskeet I see. Thank you for your clarification

Okay - with all that sorted out, are you happy for me to revert the previous change "pretty much immediately"?

@jskeet Yes, but could you please add a test for StartAt(new List<object>()) too?

Sure, happy to. (It's effectively covered in the new conformance tests which I haven't merged yet, but I can do it more explicitly.)

@jskeet A little bit wonder
Is it possible to revise the API of StartAt(params object[] items) to StartAt(object item,params object[] additionals) ?
Because this API actually require at least one item, it would be better to design the API to reflect the requirement at compile time. And it would also solve the one argument ambiguous for both StartAt(null) and StartAt(new object[0])

@Thaina: I considered that, but then it would make it much harder to call if you already had an object[]. (You'd have to extract the first item, then create a separate array with the other items.) The various workarounds with the current design are really simple. If you find yourself wanting this frequently, you could always create your own extension method for a single item (StartAtOneValue or whatever) - you should be able to chain to StartAt very easily.


Give more precise message for corrupted stream error  in readLength()

Give more information when errors are thrown.

Thanks. Actually we had the same thought, so there's already an updated error message. With the unexpected EOF the extra data won't help - you really need to tail the last bytes of the file to see the problem and usually it will be because someone has truncated the data somewhere else.


Chapter 10 algorithm implementations

I was wondering how you expect to have implemented the PPDL definitions of the problems in chapter 10. I've implemented them in my AI nanodegree approach using aima.util expressions, but I have no clarity on what do you expect it to do in this source.
Should it be able to be run? If so, what kind of search algorithms (DFS,BFS,etc) should be used.
What I mean is that it isn't as explicit as coding an algorithm, because those definitions aren't.

@bcorfman has a good example of how to do this: https://github.com/bcorfman/aima-python/blob/master/planning.py

Thanks @norvig.
I tried running implementations found in aimacode's repo and those won't work. Conversely, just tried @bfcorfman 's code and it ran correctly, outputting the expected values. So if it is solved already, why hasn't there been a pull request already?
I'm up to solving it if necessary, but again, if it is implemented why isn't it already in the repo?


🎉 3.0.0

ℹ About this release

Version: 3.0.0
Type: major
Last Release: 2.0.8 (6/21/2022, 10:17:48 AM) [?]
Commits to merge: 26 [?]

Build System

Native ESM support (7b86a4f)

⚡ BREAKING CHANGES

Only Support for node.js ^12.20.0 || >=14.13.1

📦 Dependencies

Update @sentry/node from ^7.0.0 to ^7.7.0

📦 Development Dependencies

Update @qiwi/semantic-release-gh-pages-plugin from ^5.2.2 to ^5.2.3
Update @sentry/cli from ^2.1.0 to ^2.2.0
Update eslint from ^8.16.0 to ^8.19.0
Update eslint-plugin-jsonc from ^2.3.0 to ^2.3.1
Update rollup from ^2.75.6 to ^2.75.7

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

v3.0.0
GitHub release
Docker container (sebbo2002/ble2mqtt:3.0.0)
v3.0.0

Your semantic-release bot :package::rocket:


add groupby module

Hello, the goal here is to add a module that performs a 'for each' operation with a 'group by' on a specific key, along with an option to filter by a specific value.
I'm not sure about the use of the yield & the output properties
let me know what you think, thanks

Personally, I would have added an action_ to the sekoia module rather than creating a new top-level module.

Hello, I created a separate module because I have a small hope of using private integrations to test this out :)

Hello @squioc, can you check this PR ? How can I test it on the test platform ? Thanks


Set the codename for 9.0

http://www.ruppaner-bodensee.de/unsere-biere/

Schimmele sounds pretty good, although difficult to pronounce for english speaking people... :-)

:+1:

there's still one nice proposal by @gustavonalle  ... or is this once reserved for ISPN 10 :smile: ?

Since Konstanz has been the location for very important progress this year, the codename of 9 reflects that. As for Gustavo's proposal... :)

Spezial Export sounds like the best they have. And I like the Z :)

I was going to use the brand name alone, as we have done in the past with Starobrno, Brahma, Guiness, Mahou...

+1

👍

Rado, we missed you... :-)

👍 @rhusar, there were cigars too...

Ah, sad to miss then, but we had a great EAP meeting last week too :-) no cigars though!


Escaping non ascii characters in query continuation tokens

This PR escapes non ascii characters in query continuation tokens.
For cross partition queries with ORDER BY we generate a continuation token that serializes the state of the query. That state includes the order by item. The problem happens when a user tries to resume that query from the continuation token and we put that continuation token in an HTTP header. The gateway rejects the header and we get back some HTML file explaining that the request was invalid. The problem is when we try to parse that HTML page as JSON we get a serialization exception and the user sees: "Unexpected character encountered while parsing value: (value is lt). Path '', line 0, position 0.". Which is basically saying that the "<" character in "" is not valid JSON.
The solution was to escape all non ascii character, so that they can safely be added to headers.

Hi when is this commit going to be deployed on the production? I'm a SR case owner, which is associated with this pull request. Please let me know the answer to let the customer know the schedule.


Docs for yarn and zookeeper

Coverage decreased (-0.06%) to 51.84% when pulling 5d5ef014801ebf19981eba47f2767e65c68ef814 on zimiao/docs into 12c3b08713779972c5605688406d6bae21f36ea6 on master.


feat(integrations): Update docstrings of the Keras callbacks

Fixes WB-NNNN
Fixes #NNNN
Description
The arguments sections of the reference documentation for the Keras callbacks don't render properly. This PR will likely fix that issue.
Testing
How was this PR tested?
Checklist

[ ] Include reference to internal ticket "Fixes WB-NNNN" and/or GitHub issue "Fixes #NNNN" (if applicable)
[ ] Ensure PR title compliance with the conventional commits standards

@ayulockin can you fix up the conflicts and merge.

fixing conflict.


[DOC-522] Update Swagger-UI to v5.4.1

Scope & Purpose
Swagger-UI 5 adds support for OpenAPI 3.1, which we need for the new Hugo documentation toolchain. The PR also adds some new CSS overrides for a slightly improved look.

[x] :pizza: New feature

Checklist

[x] Tests

[x] Manually tested with server API and Foxx system service
[x] Test whether Foxx's createDocumentationRouter() works with swagger-ui.js removed

[x] :book: CHANGELOG entry made
[ ] :books: documentation written (release notes, API changes, ...)
[ ] Backports

[ ] Backport for 3.11: (Please link PR)
[ ] Backport for 3.10: (Please link PR)
[ ] Backport for 3.9: (Please link PR)

Related Information
(Please reference tickets / specification / other PRs etc)

[x] Docs PR:
[ ] Enterprise PR:
[x] GitHub issue / Jira ticket: https://arangodb.atlassian.net/browse/DOC-522
[ ] Design document:

Minimal Foxx service that serves Swagger-UI at /docs: foxx-swagger-test.zip
Install the service e.g. at /swagger, then click Show Interface. The page at http://localhost:8529/_db/_system/swagger/docs/index.html shows the Swagger UI with the endpoint docs of the service itself, confirming that swagger-ui.js was indeed unused and doesn't need to be committed to the repo.


Revert "Added 1738B - Prefix Sum Addicts"

Reverts bhagirath77/codeforces_solutions_python#2 not good enough

Ok, reassign me and I will improve the code.


Security groups destroyed after removing a Service

I suspect the openstack cloud controller manager of destroying security groups when a Service of type LoadBalancer is removed. All rules from all security groups attached to master and node instances are removed, breaking the complete cluster.
I have encountered this on multiple occasions with when the openstack-cloud-controller-manager was running with manage-security-groups=true in the cloud config secret. Whereas the problem never occurred when that parameter wasn't set. N=6, but it's the only possible system that could do this. Apart from my local environment and the openstack-cloud-controller-manager, no system or user has the credentials to modify the security groups in open stack. I'm pretty sure I didn't remove the rules myself.
I'm running multiple k8s clusters, each on a separate openstack acount. They are created using  terraform and kubespray. Nodes are all running CoreOS. I'm not using Octavia (it's not supported by my openstack provider).
The controller is installed manually, using these manifests: https://github.com/kubernetes/cloud-provider-openstack/tree/master/manifests/controller-manager (kubespray only supports the deprecated built-in cloud-controller-manager, which I've disabled / "external")

maybe you can provide some info on the version of cloud controller you are using ? as seems we have some security group fix but not sure whether it's related..
and manage-security-groups seems used in octaviaConfig.ManageSecurityGroups and you mentioned you didn't use octavia...

I'm using docker.io/k8scloudprovider/openstack-cloud-controller-manager:latest, I don't know which exact version I used. The last occurence of  this issue was on wednesday 29th using a fresh install, so presumably the most recent "latest" docker tag at that time. I haven't had manage-security-groups enabled since then.
I don't think I'm using octavia, no. Afaik it's LBaaS V2, as I still have to use neutron lbaas-loadbalancer-list (and friends) to inspect the loadbalancer.
openstack-cloud-controller-manager did set security groups on the loadbalancers when manage-security-groups was set, so even without octavia it seems to be active. The security groups it created worked fine. It only goes berserk on de security groups when the first Service of type LoadBalancer is removed.
I can try again if needed?

@GeertJohan I did some security group improvement before for octavia based load balancer, and I've never tested the sg functions for neutron-lbaas given it has been deprecated since Queens. It's highly likely that the sg functions for neutron-lbaas is not working as expected.

I'm afraid this issue has hit me as well just now. Ofcourse I can relate to octavia vs neutron-lbaas (the latter being deprecated). The real issue here is that out of 3 OpenStack-as-a-Service providers in .NL, 2 of them are on neutron-lbaas, only 1 is on octavia. Which is likely not a .NL specific thing.
Honestly I think neutron-lbaas needs some love. It works great for me when it works. But when it hits you with empty security groups cleared, all of a sudden, everything breaks down...
(For me there was no trigger at all, the cluster was not being worked on, just serving).

Think I found it. Seems to have nothing to do with neutron-lbaas(v2) vs octavia btw.
Looking at https://github.com/kubernetes/kubernetes/blob/master/pkg/cloudprovider/providers/openstack/openstack_loadbalancer.go#L1560 if you add extra logging to dump opts.SecGroupID and opts. RemoteGroupID you'll notice this is actually the node security group and the loadbalancer security group that is/should be deleted.
So far so good.
Yet if you dump secGroupRules you'll quickly notice that these rules are not part of the filter that was given to getSecurityGroupRules at all. Looks like inside that method the call to rules.List(client, opts) does not properly apply the opts filter. Which ends up in gopherclient.
What makes this even more interesting to me is that the entire block of code starting from 'Delete the rules in the Node Security Group' seems unnescessary. Nothing has been created in the node security group, everything worked fine and was accessible, so why upon deletion of the lb should it start touching the node security group?

Please remove the lifecycle label because this is still an issue. Unfortunately, I don't have much time to contribute to this project at the moment.

/remove-lifecycle stale


401 error

Hi..
I am getting 401 error on all the requests (post/get) ...wherever .... there is  "passport.authenticate('jwt', {session: false})" ... i.e on using ...passport .. jwt
Please tell.. how to debug.. @ysongh
Please NOTE:-  post request for signing up of new user successfully works .... as passport/jwt method is not used there.

hi, I ran into the same problem. Did you manage to fix this error?

hello , i am also in the same problem did anyone solved it ?  @Nikyblack , @sahiljit333

hi, how to solve this? i am a beginner

Solved!!
Update your redux dev tools from 2.16.0 to 2.16.1
OR
Remove this line from your code
window.REDUX_DEVTOOLS_EXTENSION&& window.REDUX_DEVTOOLS_EXTENSION()


Doesn't seem to work properly under

Environment
"@unhead/vue": "^1.8.9"
"vite": "^4.5.0"
"vue": "^3.3.8"

Reproduction
Neither useHead nor useSeoMeta works properly
Describe the bug
After I updated vite to 4.5.0 (I also updated many packages at the same time, I am not sure if this is the problem) neither useHead nor useSeoMeta can work properly. They can modify the head normally in dev mode. However, after building to production in SPA mode, the code no longer works properly, and no tags under the head are modified.
Additional context
No response
Logs
No errors were generated

Hi, I'll need a reproduction to help with you debug this. Unhead was working fine in Nuxt when it was using this version.

Sorry I'm using this package on a closed source project and I don't know how to reproduce the same issue on other projects

The following is the code that caused the problem (I think I used it correctly)
<script setup lang="ts">
import { useHead } from '@unhead/vue'

useHead({
	meta: [
		{ name: 'status-code', content: '404' },
	],
})
</script>

Oh, I understand, it’s because I directly executed the createHead() registration in main.ts instead of mounting it under createApp().use()

It seemed to work fine in older versions, but I don't know when it stopped working.

I have the same issue, locally it works (in chrome extension - social share preview), but on production none of the meta tags are working properly (they are there though).
"vue": "^3.2.47",
"vite": "^4.1.4",
"@unhead/vue": "^1.8.9".
I'm using the package normally as showed documentation.

I have the same issue, locally it works (in chrome extension - social share preview), but on production none of the meta tags are working properly (they are there though). "vue": "^3.2.47", "vite": "^4.1.4", "@unhead/vue": "^1.8.9".
I'm using the package normally as showed documentation.

https://unhead.unjs.io/setup/vue/installation#demos
You can refer to this step to check whether the configuration is correct.

I also have the same issue as @Pajicc. I checked the link above, but it did not fix my problem. Meta tags are there but ignored.


Added 2048 game

Description 📜
2048 game with React Js and it was mobile responsive you can play this game in 4 modes or I can say in different sizes classic (4x4), big(5x5), bigger(6x6), and huge(8x8)
Fixes #444

Type of change 📝
Please delete options that are not relevant. And in order to tick the check box just put x inside them for example [x] like this

[x] Add a new project

Domain of Contribution 📊
Please delete options that are not relevant. And in order to tick the check box just put x inside them for example [x] like this

[x] Project using ReactJs

Checklist ✅
Please delete options that are not relevant. And in order to tick the check box just put x inside them for example [x] like this

[x] I have performed a self-review of my own code or work.
[x] I have commented my code, particularly in hard-to-understand areas.
[x] My changes generates no new warnings.
[x] I'm GSSoC'22 contributor

Screenshots / Gif (Optional) 📸

@khushi-purwar @meinhoonharsh

@khushi-purwar Hello please remove the tag as this PR exits in multiple repos ! look at this


[jackett] Migrate to media-common

Contributes to #37
Special notes for your reviewer:
n/a
Checklist
[Place an '[x]' (no spaces) in all applicable fields. Please remove unrelated fields.]

[x] Chart Version bumped
[x] Variables are documented in the README.md
[x] Title of the PR starts with chart name (e.g. [radarr])

Good points! Will fix them when I get back from the weekend


Improve documentation on landing pages for prepublication submissions

Updates needed to clarify that prepublication landing pages will not display top associations until paper is published, and that they are only findable for studies not under embargo.

Edited in documentation branch:
https://github.com/EBISPOT/gwas-ui/blob/documentation/goci-interfaces/goci-ui/src/main/docs/submission-content.adoc

OK in snoopy now: http://snoopy.ebi.ac.uk:9580/gwas/docs/submission#link-15
Ready for release.