text:
[now-build-utils] Discontinue Node 8

This PR adds a discontinueDate to Node 8 and prints a warning if the current deployment is using it.
Warning: Node 8.10.x will be discontinued on 2020-01-01.
Deployments created on or after 2020-01-01 will fail to build.
Please use one of the following supported `engines` in `package.json`: ["12.x","10.x"]

Starting January 2020, Node 8 deployments will fail to build and print an error.
Found `engines` in `package.json` with an unsupported node range: 8.10.x
Please use one of the following supported ranges: ["12.x","10.x"]

Codecov Report

Merging #3406 into master will decrease coverage by 0.06%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##           master    #3406      +/-   ##
==========================================
- Coverage   11.74%   11.67%   -0.07%
==========================================
  Files         267      267
  Lines       10180    10172       -8
  Branches     1349     1356       +7
==========================================
- Hits         1196     1188       -8
+ Misses       8888     8887       -1
- Partials       96       97       +1

Impacted Files
Coverage Δ

src/util/dev/router.ts
69.38% <0%> (-4.3%)
:arrow_down:

Continue to review full report at Codecov.

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

authors: codecov-io styfle

repo: zeit/now


text:
[frameworks][now-static-build] Add support for Scully

Add support for Scully.

Codecov Report

Merging #3469 into master will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master    #3469   +/-   ##
=======================================
  Coverage   14.58%   14.58%
=======================================
  Files         267      267
  Lines       10791    10791
  Branches     1484     1484
=======================================
  Hits         1574     1574
  Misses       9050     9050
  Partials      167      167

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 f598f65...f0ad615. Read the comment docs.

source: gharchive/pull-request

authors: AndyBitz codecov-io

license_type: permissive

license_source: github-api


text:
Link to vercel.com

We should add a link to vercel.com in the header section of the README — it'll direct readers to our website.

The readme in packages/now-cli should be updated as well.

authors: TooTallNate sarupbanskota


text:
version prefix

Not sure if this is intended or a bug, but npm version .... creates a version with the v prefix ( eg: v0.2.0) while release creates a separate one without the prefix (eg: 0.2.0).

Yea, we noticed that. Try creating the tag by yourself!

source: gharchive/issue

authors: leo vutran

repo: zeit/release

license: MIT


text:
Add ‘--prefix-tag’ flag to prefix tag names

Allow to prefix the release tag name with “v”, i.e. with a version “1.2.3”, release -t draft a release based on the “v1.2.3” tag. This is the format npm version uses by default.
To not affect the release name itself, it set the release “name” to the prefix-less version.
related to #30 and #35

@aesopwolf yes it does

Closed in favor of https://github.com/zeit/release/issues/41

authors: dinoboff leo


text:
Inconsistent pulls from the sorted items

Hey there,
Wonderful multi-select. Interface works perfectly, however, after I re-sort items and attempt to pull the values, I get inconsistent sorting order. This is my code for pulling and adding to an array:
	var rollUps = [];
	var rawRollUps = $('#rollUpSelect').val();
	for (var key in rawRollUps)
	{
		rollUps.push(rawRollUps[key]);
	}

Follow up:
I think I've narrowed it down to the following:
Adding a once-removed option doesn't re-add it to the array of selected objects.

I don't understand your issue, if you need an array just do
$('#tokenize').val();

Both of those work. The problem I'm having is when I unselect one value and select it again, it does not appear in the array. For example:
Selectable values: 1, 2, 3, 4, 5
Selected values: 1, 2, 3
If I unselect 3, selected values becomes 1, 2.
If I select 3 again, selected values are still 1, 2.

See screenshot. I selected 3 values, spit out the array to the console. I unselected 1 value, spit out the array to the console. I re-selected the same value I unselected and spit out the array and it's not back.

OK I think a see the problem I will check on that

I have do some fix with the last commit, can you try on your code ?

Absolutely!

Same issue :/

I noticed now that when you unselect an item, it's not put back in in the same place. It's put back in on top of the list.

The behavior with the selected item is normal, I need so to add a sorting when displaying dropdown.
BTW can you send me your code, so I can reproduce more easly your problem ?

Here is the code for declaring:
	<select id="rollUpSelect" multiple="multiple" class="tokenize-sample">
	    <option value="{FUNNEL}">Funnel</option>
	    <option value="{TRAFFIC_SOURCE}">Traffic Source</option>
	    <option value="{CAMPAIGN}">Campaign</option>
	    <option value="{OFFER}">Offer</option>
	    <option value="{LANDER}">Lander</option>
	    <option value="{GEO}">Country</option>
	    <option value="{DEVICE_TYPE}">Device Type</option>
	    <option value="{OS}">Operating System</option>
	    <option value="{HOUR}">Hour</option>
	    <option value="{DAY}">Day</option>
	</select>
	<script type="text/javascript"> $('#rollUpSelect').tokenize({displayDropdownOnFocus:true,sortable:true,maxElements:5,newElements:false});
	</script>

Here's the code for getting the value:
           var rollUps = $('#rollUpSelect').data('tokenize').toArray();
           console.log(rollUps);

Ok I have reproduce the problem (it's only with Firefox) I will try to fix it !

Can you try with the last commit ?

Worked like a charm! Thanks!!!

authors: stangsdado zellerda

repo: zellerda/Tokenize

license_source: bigquery


text:
Unable to generate csv programatically.

I'm unable to generate a CSV from a JSON file. My app.js is below. I'm using the code provided on the homepage. json2csv is installed as a dependency and also installed globally on my system. The CLI works fine.

json2csv version 5.0.5
Nodejs v14.15.4
node app.js
Sample and original file verified at jsonlint.com

[{
  "ParticipantID": "a3d040db",
  "TrialType": 1,
  "TrialDuration": 1000,
  "Clicks": 3
}, {
  "ParticipantID": "a3d040db",
  "TrialType": 2,
  "TrialDuration": 1000,
  "Clicks": 0
}]

When I run the app it just outputs "ParticipantID","TrialType", nothing more. It doesn't generate CSV data the way the CLI does.

My app.js
const myFile = '/path/txxQhnxdo.json';
const fs = require('fs');

const myData = fs.readFileSync(myFile, 'utf8');
console.log(myData) // This displays file contents correctly.

const { Parser } = require('json2csv');

const fields = ['ParticipantID', 'TrialType'];
const opts = { fields };

try {
  const parser = new Parser(opts);
  const csv = parser.parse(myData);
  console.log(csv);
} catch (err) {
  console.error(err);
}

Hi @bassamanator ,
You are trying to use the synchronous API which expects a JSON object but you are passing a string.
To get it to work you just have to convert myData to JSON using JSON.parse(myData).
A much better approach would be to use the async API which parses the array and processes the JSON one object at a time. In the latest v5 that would be something like this (code not tested, it's just an example and it might contain some mistakes):
const myFile = '/path/txxQhnxdo.json';
const fs = require('fs');

const myData = fs.createReadStream(myFile, 'utf8');

const { AsyncParser } = require('json2csv');

const fields = ['ParticipantID', 'TrialType'];
const opts = { fields };

try {
  const parser = new Parser(opts);
  const csv = await parser.fromInput(myData).promise();
  console.log(csv);
} catch (err) {
  console.error(err);
}

Hi @bassamanator ,
You are trying to use the synchronous API which expects a JSON object but you are passing a string.
To get it to work you just have to convert myData to JSON using JSON.parse(myData).
A much better approach would be to use the async API which parses the array and processes the JSON one object at a time. In the latest v5 that would be something like this (code not tested, it's just an example and it might contain some mistakes):
const myFile = '/path/txxQhnxdo.json';
const fs = require('fs');

const myData = fs.createReadStream(myFile, 'utf8');

const { AsyncParser } = require('json2csv');

const fields = ['ParticipantID', 'TrialType'];
const opts = { fields };

try {
  const parser = new Parser(opts);
  const csv = await parser.fromInput(myData).promise();
  console.log(csv);
} catch (err) {
  console.error(err);
}

Hi @juanjoDiaz ,
Parsing the string into JSON worked. Thank you so much.
I don't think I need the async API in my use case but I will read into it. The program that I'm writing is a standalone program. I just need to batch convert all my .json files into .csv files.
One serious issue that I do have at the moment is that I'm having to specify the fields. I don't want to do that because I want all the fields (there will be more than 60 of them). In the CLI I don't have to specify the fields (json2csv -i input.json -o output.csv ). Can I accomplish the same in my app.js?
Thanks again!

Hi @juanjoDiaz ,
Parsing the string into JSON worked. Thank you so much.
I don't think I need the async API in my use case but I will read into it. The program that I'm writing is a standalone program. I just need to batch convert all my .json files into .csv files.
One serious issue that I do have at the moment is that I'm having to specify the fields. I don't want to do that because I want all the fields (there will be more than 60 of them). In the CLI I don't have to specify the fields (json2csv -i input.json -o output.csv ). Can I accomplish the same in my app.js?
Thanks again!

You don't have to specify them either if you use the sync API. All the fields will be used automatically.

You don't have to specify them either if you use the sync API. All the fields will be used automatically.

Brilliant! Thanks again!

Brilliant! Thanks again!

authors: bassamanator juanjoDiaz

license: mit


text:
When using the filterSave method, the zs-client.phar sends an HTTP method error

I've tried to use a method to import a filter rule from one server to other, but when using the filterSave method, it requires a POST method:
php zs-client.phar filterSave --type=issue --target=zst --name=CLIQueryAllEvents --data={"applicationIds":[29]}
2015-04-30T16:24:43-03:00 ERR (3): This action requires a HTTP POST method

zendcmd
filterSave

unexpectedHttpMethod
This action requires a HTTP POST method

The application has thrown an exception!
ZendServerWebApi\Model\Exception\ApiException
This action requires a HTTP POST method

I think that the FilterSave method and POST, that would refer to the chroot with a shroot(shell_root); all in php
but the SaveTarget is a new theory "zst", try "zst_POST"
use unexpected throw method zst_POST would be a " prototype_protocall_callback_POST( )"
under file_target_"zst_POST{}" raise shroot && cmd chroot in file_target_POST{};
Regards Kenny
 On Thursday, 30 April 2015, 20:26, ericovasconcelos <notifications@github.com> wrote:

I've tried to use a method to import a filter rule from one server to other, but when using the filterSave method, it requires a POST method:php zs-client.phar filterSave --type=issue --target=zst --name=CLIQueryAllEvents --data={"applicationIds":[29]}
2015-04-30T16:24:43-03:00 ERR (3): This action requires a HTTP POST method
zendcmd
filterSave
unexpectedHttpMethod
This action requires a HTTP POST method
The application has thrown an exception!
ZendServerWebApi\Model\Exception\ApiException
This action requires a HTTP POST method—
Reply to this email directly or view it on GitHub.

@ericovasconcelos The issue is fixed in the latest phar ( https://github.com/zend-patterns/ZendServerSDK/raw/master/bin/zs-client.phar ) version. Make sure also to use query string formatting for passing the data and not json formatting. The correct way to test the filterSave with the data that you have provided will be:
php zs-client.phar filterSave --type=issue --target=zst --name=CLIQueryAllEvents --data="applicationIds[]=29"

authors: ericovasconcelos slaff wrightkennethj

repo: zend-patterns/ZendServerSDK


text:
Provide access to the list of messages failed in DeliveryFailed

In our application, we are consuming messages from an internal queueing system and attempting to publish them to Kafka through ruby-kafka.  If only a subset of those messages succeed, then we need to make sure that only those messages get deleted from our queueing system.  Since we have multiple processes running on this internal queue, we want to know which messages are still remaining (i.e. which ones failed) so that we don't delete those from our internal queue.
As an example, Amazon SQS consumers must explicitly mark messages as successful and any messages that failed will get picked up by another consumer at some point in the future.
There are a few ways we could address this:
(1) Change deliver_messages to return the list of messages that were successfully delivered. This doesn't really align with how the current API behaves and raises exceptions on partial failures.
(2) Provide access to the list of remaining messages that need to get sent after deliver_messages is invoked. e.g.
begin
  producer.produce("hello1", topic: "greetings", partition: 0)
  producer.produce("hello1", topic: "greetings", partition: 1)
  producer.deliver_messages
rescue Kafka::DeliveryFailed
  producer.buffer_messages # Only failed messages will be here
end

(3) Provide access to the list of remaining messages that need to get sent in DeliveryFailed exceptions.  e.g.
For example:
begin
  producer.produce("hello1", topic: "greetings", partition: 0)
  producer.produce("hello1", topic: "greetings", partition: 1)
  producer.deliver_messages
rescue Kafka::DeliveryFailed => ex
  ex.failed_messages
end

Since failures are the exceptional case, supporting a new API on Producer doesn't make quite as much sense -- we really only want to expose lists of failed messages when a failure has actually occurred.  Additionally, exposing the list of buffer messages when delivery hasn't even been attempted might result in misuse of the feature.  For these reasons, (3) seems like the most appropriate option.
In order to support this feature, 2 additional changes were made:

Kafka::PendingMessage now supports equality checks with other pending messages.  This is the object that's returned from Kafka::DeliveryFailed#failed_messages and providing equality checks helps us write specs against it.  If we would prefer to move that functionality into the spec itself, we can do that as well.  Open to thoughts / feedback here.

Kafka::Producer#deliver_messages had scenarios in which it could raise a Kafka::ConnectionError instead of Kafka::DeliveryFailed exception which would make it impossible to get the list of failed messages.  #deliver_messages will now always raise a Kafka::DeliveryFailed exception.

An alternative would be to include the still-buffered messages in the DeliveryFailed exception. I'd rather have that, since I don't particularly want people messing with the internal buffer too much.

@dasch Sure that's something I can explore.  In that scenario (where we're including it in the exception), do you think we'd still need to have a message object as part of the public API?  If so, is that something you're open to?

@dasch i would strongly advise against using exceptions as it will force users to design their workflow based on exceptions (exceptions should not be used for flow control and should not be expected). Also from the ruby perspective, they are heavy as they contain stack trace and other data.

@mensfeld This is exceptional flow, though – it only happens when delivery fails. The exception is already raised in this case. As such, I think it makes sense to include the list of failed messages in the exception itself.
@obrie PendingMessage (https://github.com/zendesk/ruby-kafka/blob/master/lib/kafka/pending_message.rb) is currently being used in the pending message queue, but Protocol::Message is being used in the buffer. I think the former is the closest thing to a publicly consumable API we have, so maybe casting the buffer messages back to PendingMessage?

Are there cases where we the producer does not raise a DeliveryFailed exception even if it successfully produced some messages.  For example, I'm specifically looking at this line:
https://github.com/zendesk/ruby-kafka/blob/e9b220b9099f73d126fab90d9f9c241685e8fe77/lib/kafka/producer.rb#L297
If I'm not mistaken, the following can happen:

On first loop, some messages succeed, some fail
From failed messages, cluster gets marked as stale
On second loop, refresh_metadata_if_necessary! gets called
If refresh_metadata_if_necessary! fails, then a ConnectionError exception gets raised

I'll validate that scenario, but if someone else more familiar with the library is able to verify that, that'd be great.  If that scenario is valid, then I think we'd either need to expose the failed messages as-is in the current PR or we would need to catch ConnectionError in Producer#deliver_messages_with_retries and raise DeliveryFailed instead.

Those are good points. It would be great if you could keep investigating.
Note that I'll be travelling the next three weeks and will be without access to my laptop, so I won't be able to merge anything during that time.

I probably won't check in here too much, either. I think the best course of action would be for you to write a patch and deploy that version to production (using e.g. a git ref in your Gemfile). If it works I'll take a look when I'm back.

Good timing -- I'll also be out for the next 3 weeks :smile:
Will likely update the PR today and chat more when you're back

Have a nice one, then! ⛱

I've updated the PR to include the failed messages on the DeliveryFailed exception and to ensure that DeliveryFailed exceptions are always raised when calling Producer#deliver_messages with a partial failure.
I'll update the PR description to reflect the approaches taken and the current iteration of this feature.

PR description updated.  Ready for another round of feedback :smile:

This looks good! I’ll do a more thorough review when I’m back.

Looks good! 👍

:heart: Thanks @dasch! (and welcome back)

Thanks!

authors: dasch mensfeld obrie

repo: zendesk/ruby-kafka


text:
Explanation of installation choices

Summary: explain the pros/cons, speed and other differences between the choices we have.
When I first looked at zend expressive I was impressed but confused, It looked nice, but I didn't know what happened with mvc nor the difference between these two choices, and I also looked at all the choices I had when it came to view, routing etc. And did not know what to pick or what the difference was. A Routing choices page where the differences are listed, as well as a template choices page in the getting started section.

When I first looked at zend expressive I was impressed but confused, It looked nice, but I didn't know what happened with mvc nor the difference between these two choices,

https://docs.zendframework.com/zend-expressive/why-expressive/#should-you-choose-zend-expressive-over-zend-mvc

and I also looked at all the choices I had when it came to view, routing etc. And did not know what to pick or what the difference was.

I'm not sure how you want to do this. Those are different packages with different solution for the same problem. I don't think it's our task to list all the differences, that also means you need to maintain that comparison. If there are new features added we would need to update the docs.
I guess for the internals you need to do a little investigation yourself. I suggest you read the docs of those packages anyway so you know how to use each package before you start. e.g. you might like the plates coding style over twig, and they both have an extension system to add missing features.

A Routing choices page where the differences are listed,

For routing the main difference is the configuration and the way the regex is used. They do work different internally but besides the different config you won't notice it. I know FastRoute is a favorite for many users and it's the default choice because it's fast, especially when its caching system is used.

https://docs.zendframework.com/zend-expressive/features/router/aura/#using-aurarouter
https://docs.zendframework.com/zend-expressive/features/router/fast-route/#using-fastroute
https://docs.zendframework.com/zend-expressive/features/router/zf2/#using-the-zf2-router

as well as a template choices page in the getting started section.

Plates and zend-view use the php language directly where twig use its own parser which translates to php code (it's extra overhead, but with its caching system it's still fast). Twig automatically escapes output for you, plates is really fast and zend-view has a lot of extra features.

https://docs.zendframework.com/zend-expressive/features/template/plates/#using-plates
https://docs.zendframework.com/zend-expressive/features/template/twig/#using-twig
https://docs.zendframework.com/zend-expressive/features/template/zend-view/#using-zend-view

I guess we could add a short introduction, something like I wrote above. But I think anything more is in the package docs.

Sorry for not knowing excactly how this works here. Should I put my question I put on  #283 rather here?

@frankx Try our forum and slack for questions.

This repository has been closed and moved to mezzio/mezzio; a new issue has been opened at https://github.com/mezzio/mezzio/issues/12.

authors: AndersMadsen frankx weierophinney xtreamwayz

repo: zendframework/zend-expressive


text:
Will there be a content-validation component in the future?

I think  zfcampus/zf-content-validation is a good components. But it is not a PSR7 component.
I tried create the same component  zfegg/content-validation.  But my team is not strong enough.
Is there a roadmap to create a PSR7 content-validation component.

Yes, there will, but it requires changes to existing components and/or needs new components to accomplish. (Validators and input filters need to be stateless to ensure error messages are not incorrectly propagated.) We've already started work, and the roadmap is on our forums: https://discourse.zendframework.com/t/rfc-new-validation-component/208

authors: Moln weierophinney


text:
Client, Socket adapter: compressed responses not decompressed when streaming

The default Client pathways that use the Socket adapter automatically handle gzipped and deflated response bodies, and therefore include them in the Accept-Encoding header outgoing on responses as long as the zlib extension is present.
This automatic handling doesn't extend to the streaming support, however. In addition, the Client doesn't account for this fact and will still send an Accept-Encoding header indicating deflate and zlib are acceptable. The result is that the server will obey the Accept-Encoding header and send a compressed response, none of the Client, the Adapter, or the Response will decompress it, and it will be streamed as-is, in compressed form.
Because of the workflow involved in using the client, calling code can't know to add a decompression stream filter, as it would have to inspect headers to determine if the response was in fact compressed, but by the time those headers are available, send() has already been called and the data has already been streamed to its destination. The best available workaround is to manually set an Accept-Encoding header to tell servers that compression is not supported when using streams.
The Client should either not send the Accept-Encoding header when setStream has been called, or the Client or Adapter should automatically attach an appropriate stream filter to decompress the response according to the response headers.
This appears to be the same issue as the longstanding ZF1-era issue ZF-10878. I'm not sure how or if it's related to #89 which is Curl-specific and doesn't require streaming.

@zerocrates I've tried to replicate it and what I can see is:

$response->getContent() is empty,
$response->getBody() contains decoded response

What is the issue with this approach?
        $uri = 'http://server_with_gzip/file.txt';

        $config = [
            'adapter' => Client\Adapter\Curl::class,
            'storeresponse' => false,
        ];
        $client = new Client($uri, $config);
        $client->setStream('response.txt');
        $client->send();
        $response = $client->getResponse();

        $content = $response->getContent();
        $body = $response->getBody();

It's been quite a while since I filed this, so I'm a little hazy on the details, but a couple things, if I'm reading your response correctly:

This issue is specific to the Socket adapter.
When streaming the response, the response data isn't available from $response->getContent() or $response->getBody(), as it's been directly sent to the specified stream/destination.

I'm fairly certain this is still an issue.

@zerocrates
I've tested it again:
$client = new \Zend\Http\Client('test/url/with/compression', [
    'adapter' => \Zend\Http\Client\Adapter\Curl::class,
]);
$client->setStream('test-output-curl.txt');
$client->send();

and
$client = new \Zend\Http\Client('test/url/with/compression', [
    'adapter' => \Zend\Http\Client\Adapter\Socket::class,
]);
$client->setStream('test-output-socket.txt');
$client->send();

in both cases I am getting decoded content in txt files, as I would expect.
I checked also without stream and then $client->getResponse()->getContent() is gzipped, and $client->getResponse()->getBody() is decoded content.
I can't see any issue. Would you be able to test it again and confirm, or provide failing test case? Thanks!

Okay so here's my exact test, using zend-http 2.10.0 installed with Composer:
<?php

require 'vendor/autoload.php';

$client = new \Zend\Http\Client('https://www.gnu.org/licenses/gpl-3.0.txt');
$client->setStream('test.txt');
$client->send();

$response = $client->getResponse();

echo "body\n\n";
var_dump($response->getBody());

echo "\n\ncontent\n\n";
var_dump($response->getContent());

echo "\n\nfile\n\n";
var_dump(file_get_contents('test.txt'));

And the output (truncated):
body

string(35149) "                    GNU GENERAL PUBLIC LICENSE

content

string(12130) "^_<8B>^H^@^@^@^@^@^@^C<C5>}[s<92><EE>{<FD><8A>

file

string(12130) "^_<8B>^H^@^@^@^@^@^@^C<C5>}[s<92><EE>{<FD><8A>

authors: webimpress zerocrates

repo: zendframework/zend-http


text:
Trigger user deprecated error on deprecated classes

It should help with migrations. Not sure why it was not added here, maybe there is some reasoning not to adding it?

Not sure why it was not added here, maybe there is some reasoning not to adding it?

We go back and forth on whether or not to include these; a lot of folks complain when they see them, but we also get a fair number of folks happy to get provided the information they need for migration.
I mainly didn't do it because testing these is always such a pain, and we then have to remove the tests in the next version; I was being lazy. :smile:
I've rebased off of current develop, and referenced this patch in the CHANGELOG section indicating deprecations.

authors: webimpress weierophinney

repo: zendframework/zend-hydrator


text:
Soapenv:Header in request

Is there a way to accept soapenv:Header data in a request to a soap server?
We are receiving an header data and the server is returning an error because of this header.
<soapenv:Header> <esb:header> <esb:message_type>AddNewOrder</esb:message_type> <esb:version>01.80</esb:version> <esb:source_entity>LPRO</esb:source_entity> <esb:source_application>NOLS</esb:source_application> <esb:destination_entity>KEIT</esb:destination_entity> <esb:destination_application>TIRE</esb:destination_application> </esb:header> </soapenv:Header>
Do we need to define it in the wsdls and if yes how can we do that as we are not able to find it in the documentation.

This repository has been closed and moved to laminas/laminas-soap; a new issue has been opened at https://github.com/laminas/laminas-soap/issues/2.

authors: hypemedia weierophinney

repo: zendframework/zend-soap


text:
A bug in mysqli adapter

beginTransaction has several lines of code that would possibly trigger an exception.
public function beginTransaction()
{
$this->_connect();
$q = $this->_profiler->queryStart('begin', Zend_Db_Profiler::TRANSACTION);
$this->_beginTransaction();
$this->_profiler->queryEnd($q);
return $this;
}
The internal function _beginTransaction() has this, setting autocommit to false:
protected function _beginTransaction()
{
$this->_connect();
$this->_connection->autocommit(false);
}
If this line of code "$this->_profiler->queryEnd($q);" trigger an exception for sure "autocommit"
would not be reverted to "true".

This repository no longer contains any code for the Zend Framework packages.  Could you please re-open this issue over on the zend-db repository?

authors: adamlundrigan stevekim

repo: zendframework/zendframework


text:
A fix for ZF2016-04

I applied the fix from: https://framework.zend.com/security/advisory/ZF2016-04 to the ZF1 code. Should be double checked by somebody else.

ZF1 is EOL, so there's no chance this will get merged anyhow, but for reference, I don't believe ZF1 is vulnerable to this attack vector because the name and email portions of the "From" header are filtered before they reach this section of code. Here are the filter functions:
https://github.com/zendframework/zf1/blob/master/library/Zend/Mail.php#L1212
https://github.com/zendframework/zf1/blob/master/library/Zend/Mail.php#L1232
And where they're called from (in the setFrom method):
https://github.com/zendframework/zf1/blob/master/library/Zend/Mail.php#L687
I tried implementing your fix in a fork of this project, along with an adapted version of the two tests from this commit:
https://github.com/zendframework/zend-mail/commit/8d18478b40fdeef7239fb7ea203e072edcadbe54
But the tests don't pass because the double quotes are removed before Zend_Mail_Transport_Sendmail::_prepareHeaders is called.
Here's a dump of the "From" key when these two tests are run:
Array
(
    [0] => Sender's name <AAA\ code injection@domain>
    [append] => 1
)

Array
(
    [0] => Foo Bar <foo-bar@domain>
    [append] => 1
)

Hi Jay,
Thanks for the feedback.
--
Freundliche Grüße / Best regards
ppa. Dirk Schwarz
Director Technology & Projects
Magento Certified Developer PLUS & ZEND Certified PHP 5.3 Engineer

PHOENIX MEDIA GmbH
Industriestraße 4, 70565 Stuttgart-Vaihingen
Registergericht: AG Stuttgart, HRB 721777; Sitz: Stuttgart;
Geschäftsführer: Daniel Gärtner
PHOENIX MEDIA ist Magento Enterprise Solutions Partner in Deutschland und Österreich
From: Jay Klehr notifications@github.com
Reply-To: zendframework/zf1 reply@reply.github.com
Date: Thursday, 26 January 2017 at 21:38
To: zendframework/zf1 zf1@noreply.github.com
Cc: Dirk Schwarz dirk.schwarz@phoenix-media.eu, Author author@noreply.github.com
Subject: Re: [zendframework/zf1] A fix for ZF2016-04 (#733)
ZF1 is EOL, so there's no chance this will get merged anyhow, but for reference, I don't believe ZF1 is vulnerable to this attack vector because the name and email portions of the "From" header are filtered before they reach this section of code. Here are the filter functions:
https://github.com/zendframework/zf1/blob/master/library/Zend/Mail.php#L1212
https://github.com/zendframework/zf1/blob/master/library/Zend/Mail.php#L1232
And where they're called from (in the setFrom method):
https://github.com/zendframework/zf1/blob/master/library/Zend/Mail.php#L687
I tried implementing your fix in a fork of this project, along with an adapted version of the two tests from this commit:
zendframework/zend-mail@8d18478https://github.com/zendframework/zend-mail/commit/8d18478b40fdeef7239fb7ea203e072edcadbe54
But the tests don't pass because the double quotes are removed before Zend_Mail_Transport_Sendmail::_prepareHeaders is called.
Here's a dump of the "From" key when these two tests are run:
Array
(
[0] => Sender's name <AAA\ code injection@domain>

[append] => 1

)
Array
(
[0] => Foo Bar <foo-bar@domain>

[append] => 1

)
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHubhttps://github.com/zendframework/zf1/pull/733#issuecomment-275506612, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AJwokOcx1rvLKig4nJSILcifwJid676kks5rWQRVgaJpZM4LuEc8.

authors: jaydiablo phoenix-schwarz


text:
Tidy up project toml files

Removes non-mandatory attributes and text entries.

Bumps all depepdencies except:

jsonwebtoken (as @funbringer was willing to bump it later)
rust-tls + webpki + rustls-split crate circle. Agreed to remove rustls-split first from the workspace separately.

Removes parking_lot from the project due to https://github.com/zenithdb/zenith/issues/956

Moves routerify behind zenith_utils to the rest of the generic http server code

I'm late yet again, but I can't help but to notice that in my opinion commit https://github.com/zenithdb/zenith/commit/c5b5905ed36490bbaaca4081236b7f205afdb68c does more harm than good. The proposed reasoning mostly covers rwlocks, however, the patch itself removes mutex from a place where it fits quite well (come on, we're doing a bunch of inserts to a hash table, what could possibly go wrong?). The fairness guarantees are also beneficial here; ideally we wouldn't want to starve any threads, especially if we could get this behavior for free. Finally, the commit message is misleading: our dependencies still rely upon parking_lot, so we didn't actually remove it from our workspace.
That is to say, unless there's some serious concern regarding parking_lot that hasn't been brought up yet, I'm going to use it in proxy as necessary.

authors: SomeoneToIgnore funbringer

repo: zenithdb/zenith


text:
Fixed argilla

Describe changes
Registering argilla with port not specified failed everytime. The instructions where also wrong.
Pre-requisites
Please ensure you have done the following:

[ ] I have read the CONTRIBUTING.md document.
[ ] If my change requires a change to docs, I have updated the documentation accordingly.
[ ] I have added tests to cover my changes.
[ ] I have based my new branch on develop and the open PR is targeting develop. If your branch wasn't based on develop read Contribution guide on rebasing branch to develop.
[ ] If my changes require changes to the dashboard, these changes are communicated/requested.

Types of changes

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

closing as https://github.com/zenml-io/zenml/pull/2915 already contains the necessary fixes

repo: zenml-io/zenml


text:
Include deployment in azureml docker build

Describe changes
I implemented/fixed _ to achieve _.
Pre-requisites
Please ensure you have done the following:

[ ] I have read the CONTRIBUTING.md document.
[ ] If my change requires a change to docs, I have updated the documentation accordingly.
[ ] If I have added an integration, I have updated the integrations table and the corresponding website section.
[ ] I have added tests to cover my changes.

Types of changes

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

@htahir1 I think we don't have a convention for this case yet (this is guaranteed to be a local path -> fileio is not necessary) and I've seen both fileio as well as the default python method being used. Fine with whatever we decide though, I guess not using fileio signals that this is a local path which is why I've used it in these cases before


text:
Can't put model into sub-folder

Having the datatable models in the root of the model folder is a bit unclean, though it doesn't seem to work if you put the model into a sub folder, unless I'm missing something

Hi @zepernick
i have same problem when i change into subfolders on models

Hi, check this PR
#18

Hi @pingwiniasty Thanks :)

authors: jojoalmost nmjbhoffmann pingwiniasty

repo: zepernick/Codeigniter-DataTables


text:
webhook for packagist

Bitte webhook für packagist adden, kann die packagist version nicht updaten.

Webhook ist eingerichtet.

Danke

authors: nadar tbreuss

repo: zephir/luya-kickstarter


text:
Footprint Enhancements

Identify footprint (ram/rom) enhancement opportunities:

[x] Create a reliable footprint tracking benchmark [#15855]
[x] Document how to reduce footprint and list all options and optional features that can be disabled to win more ram/rom

addressed

repo: zephyrproject-rtos/zephyr


text:
Bluetooth: can't close bt_driver log output

Describe the bug
When set BT_DEBUG_NONE and BT_LOG_LEVEL_OFF, Log module bt_driver still print out "bt_driver: TX interrupt but no pending buffer!".
PS: LOG_OVERRIDE_LEVEL was set as 0.
To Reproduce
Steps to reproduce the behavior:

set BT_DEBUG_NONE and BT_LOG_LEVEL_OFF in menuconfig
build and flash
See bt_driver output error logs

Expected behavior
No bt related log should be printed out no matter it's error, warning or info.
Impact
A lot of "bt_driver: TX interrupt but no pending buffer!" messed up terminal.
Screenshots or console output
[00:09:31.039,000]  bt_driver: TX interrupt but no pending buffer!
[00:09:31.039,000]  bt_driver: TX interrupt but no pending buffer!
[00:09:31.274,000]  bt_driver: TX interrupt but no pending buffer!
[00:09:31.274,000]  bt_driver: TX interrupt but no pending buffer!
[00:09:31.274,000]  bt_driver: TX interrupt but no pending buffer!
[00:09:31.275,000]  bt_driver: TX interrupt but no pending buffer!
Environment (please complete the following information):

OS: Linux
Toolchain: Zephyr SDK
Zephyr version 2.0.99

Additional context
If enabled shell, bt log can be turned off by log disable bt_driver

I'd like to add additional question here that why bt still functional although those "TX interrupt but no pending buffer" keeping jumping out, it will be great if someone can answer me, thanks

I'd be more concerned about this error than the logging behaviour. It looks like the UART driver on your platform (which is it btw?) is misbehaving, i.e. it's generating interrupts even though uart_irq_tx_disable() was called. Btw, you can turn off all logging with CONFIG_BT_DEBUG_LOG=n however that will turn it off for all Bluetooth modules, i.e. not just the driver.

@jhedberg Thanks for your quick answer, but I already set CONFIG_BT_DEBUG_LOG to n, this message still pump out.
CONFIG_BT=y
CONFIG_BT_HCI=y
CONFIG_BT_CONN=y
CONFIG_BT_CENTRAL=y
CONFIG_BT_LOG_LEVEL_OFF=y
CONFIG_BT_DEBUG_LOG=n

If you are interesting in the UART misbehaving, here are some details:
Issue was happened on STM32L451, it's quite confusing me since BT HCI is still functional. Blow parts is our related dts:
&usart3 {
	current-speed = <1000000>;
	label = "UART_BLE";
	status = "okay";
	hw-flow-control;
};

As I said it confused me a lot since BT functions works normal, I can successfully bt_enable and bt_le_scan_start.

Hi,
I understand that this issue is about incorrect logging behavior,
but it is also almost the only result about "TX interrupt but no pending buffer".
@codingspirit  How were you getting this issue? Could you fix it?
We are implement streaming app (audio input to BLE), first several minutes it works fine, but then only this error comes (and not more messages are sent).

Hi,
I understand that this issue is about incorrect logging behavior,
but it is also almost the only result about "TX interrupt but no pending buffer".
@codingspirit How were you getting this issue? Could you fix it?
We are implement streaming app (audio input to BLE), first several minutes it works fine, but then only this error comes (and not more messages are sent).

@AndreyDodonov-EH
Hi, we met this issue when we trying to use zephyr based MCU(STM32) as HCI host. We knew that Log level wasn't root cause, but #20961 did help us to get rid of endless "TX interrupt but no pending buffer!".

@codingspirit
Thanks for the info! You are right,with this change log becomes configurable.
Were you able to solve your original issue?
P.S. We are using though Nordic Thingy 91 (https://www.nordicsemi.com/Software-and-tools/Prototyping-platforms/Nordic-Thingy-91, both host and controller use zephyr)
This fix partially improved the situation https://github.com/zephyrproject-rtos/zephyr/issues/25904
But not completely, these look also relevant, may be they will also be of interest to you
https://github.com/zephyrproject-rtos/zephyr/pull/25954
https://github.com/zephyrproject-rtos/zephyr/issues/23364

@codingspirit @AndreyDodonov-EH
I have the same issue using Nordic PCA10090, the BLE stopped with this loop error. Were you able to solve the issue?

authors: AndreyDodonov-EH albdom codingspirit jhedberg


text:
Release Notes v3 review - Kernel

Looking for a sign off on the v3.0.0 release notes

Not sure what the process is here, exactly.  I gave it a check in the linked list (also one for the Xtensa architecture).  Is that sufficient or do I need to do something else?

authors: andyross dkalowsk


text:
Change 0-length arrays to flexible arrays

Is your enhancement proposal related to a problem? Please describe.
Searching for  \w+\[0\];\n\} in Zephyr yields 195 results (as of 8c6a3dbe37abd9b905ac89a375b97a811470dcbd) of arrays defied with [0], which is not a valid C array as per https://www.open-std.org/jtc1/sc22/WG14/www/docs/n1256.pdf section 6.7.5.2 Array declarators which state:

In addition to optional type qualifiers and the keyword static, the [ and ] may delimit an expression or *. If they delimit an expression (which specifies the size of an array), the expression shall have an integer type. If the expression is a constant expression, it shall have a value greater than zero

The [0] is in fact a compiler extension, and since it is used to denote an element with a variable length (as per https://gcc.gnu.org/onlinedocs/gcc/Zero-Length.html), we should be able to replace all [0] with [].
Alternatively, we could also look into bounded flexible arrays that they Linux kernel is currently working on implementing: https://people.kernel.org/kees/bounded-flexible-arrays-in-c
Describe the solution you'd like
Replace all [0] with [] to be compliant with C99 and newer standards, instead of relying on a compiler extension.
Describe alternatives you've considered
Bounded flexible arrays may be a better solution overall, and would replace most current non-bounded flexible arrays.
Additional context
The majority of these [0] arrays seems to be in the Bluetooth subsystem.

There is a recent warning added to GCC that can help check if there are any flexible array members in the middle of a struct, which is a big no-go: https://gcc.gnu.org/onlinedocs/gcc-14.1.0/gcc/Warning-Options.html#index-Wflex-array-member-not-at-end

See also https://embeddedor.com/slides/2024/eo/eo2024.pdf

For coincidence I was looking into it. I was looking for ways to improve buffer checking to avoid overflows and that is something that can help. There are some really neat compiler features, unfortunately some of them are not available in our SDK. But they rely on proper arrays declaration.
I am working on it.

Among all usages, this one is the weirdest and it seems very error  prone https://github.com/zephyrproject-rtos/zephyr/blob/main/tests/bluetooth/tester/src/btp/btp_mesh.h#L117-L118

https://github.com/zephyrproject-rtos/zephyr/pull/75192 to start :)

Among all usages, this one is the weirdest and it seems very error prone https://github.com/zephyrproject-rtos/zephyr/blob/main/tests/bluetooth/tester/src/btp/btp_mesh.h#L117-L118

That is actively disallowed in C. Empty/zero-length arrays are only ever allowed if it is the last value in a struct IIRC (and then that struct shall always be the last field if embedded in other structs).
Luckily it's just for a test application, but should definitely be fixed (ping @sjanc )

yeah, I'll fix that

fix https://github.com/zephyrproject-rtos/zephyr/pull/75242

authors: Thalley ceolin sjanc


text:
tests: driver: drivers.uart.async_api.lpuart: mimxrt10xx_evk: hardfault

This issue list is only for bugs in the main Zephyr code base
(https://github.com/zephyrproject-rtos/zephyr/). If the bug is for a project
fork (such as NCS) specific feature, please open an issue in the fork project
instead.
Describe the bug
tests/drivers/uart/uart_async_api meet hardfault
Please also mention any information which could help others to understand
the problem you're facing:

What target platform are you using?
mimxrt1010_evk
What have you tried to diagnose or workaround this issue?
NA
Is this a regression? If yes, have you been able to "git bisect" it to a
specific commit?

a5cf757c9ecbaa562a4f31b58bf133a4b978da8a is the first bad commit
commit a5cf757c9ecbaa562a4f31b58bf133a4b978da8a
Author: Dat Nguyen Duy <dat.nguyenduy@nxp.com>
Date:   Wed Jun 14 09:38:41 2023 +0700

    drivers: dma_mcux_edma: improve interrupt handling

    The current implementation iterates over all channels
    even if only several channels share the same irq. This
    introduces one more dt property to describe an offset
    between two channels share the same interrupt id.

    Beside that, the error interrupt must be put as last
    element of "interrupt" dt property.

    Signed-off-by: Dat Nguyen Duy <dat.nguyenduy@nxp.com>

 drivers/dma/dma_mcux_edma.c         | 105 ++++++++++++++++++------------------
 dts/arm/nxp/nxp_rt10xx.dtsi         |   1 +
 dts/arm/nxp/nxp_rt11xx.dtsi         |   2 +
 dts/bindings/dma/nxp,mcux-edma.yaml |   7 +++
 4 files changed, 61 insertions(+), 54 deletions(-)

To Reproduce
Steps to reproduce the behavior:
west twister -p mimxrt1010_evk -T tests/drivers/uart/uart_async_api
Expected behavior
PASS
Impact
DMA issue iwth lpuart in this platform. (other RT series is ok including RT1015)
Logs and console output
*** Booting Zephyr OS build v3.6.0-3046-g78150c8e1b2c ***
Running TESTSUITE uart_async_chain_read
===================================================================
E: No buffers to release from RX DMA!
E: No buffers to release from RX DMA!
START - test_chained_read
E: 0x60011a50 used before initialization
E: syscall z_vrfy_uart_rx_enable failed check: access denied
E: r0/a1:  0x00000000  r1/a2:  0x00000000  r2/a3:  0x00000000
E: r3/a4:  0x00000000 r12/ip:  0x00000000 r14/lr:  0x00000000
E:  xpsr:  0x00000000
E: Faulting instruction address (r15/pc): 0x3f750880
E: >>> ZEPHYR FATAL ERROR 3: Kernel oops on CPU 0
E: Current thread: 0x20002840 (test_chained_read)
E: Halting system

Environment (please complete the following information):

OS: (e.g. Linux, MacOS, Windows)
Toolchain (e.g Zephyr SDK, ...)
Commit SHA or Version used: v3.6.0-3046-g78150c8e1b2c

this is a long missing issue, I misjudge rt1015 and rt1010 use the same ip, and rt1015 is ok which misleading me as my board settings issue. but after some analysis, this is a dma issue.

I confirmed that it fails on all the other RT10xx boards as well.

ping @EmilioCBen

Hi @hakehuang, i have fixed an DMA issue on imxrt 1010 recently via https://github.com/zephyrproject-rtos/zephyr/pull/77140.
Could you pls run the test against latest main? I expect that it should work

Could you pls run the test against latest main? I expect that it should work

@Dat-NguyenDuy I tested it is PASS on all RT10xx series.

authors: Dat-NguyenDuy decsny dleach02 hakehuang


text:
dts: nxp: Add sram_l node to k64 dtsi

Adds a second sram node to the k64 device tree to acknowledge that the
additional sram is present in hardware, but deliberately not used in
zephyr until an outstanding issue is solved. The upper and lower sram
nodes are contiguous in the memory map, however the Cortex-M4
architecture does not support misaligned accesses across the boundary
between the two nodes.
Fixes #2984
Signed-off-by: Maureen Helm maureen.helm@nxp.com

Codecov Report

Merging #12081 into master will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master   #12081   +/-   ##
=======================================
  Coverage   48.05%   48.05%
=======================================
  Files         281      281
  Lines       43416    43416
  Branches    10406    10406
=======================================
  Hits        20864    20864
  Misses      18403    18403
  Partials     4149     4149

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 523932c...78479a4. Read the comment docs.

authors: MaureenHelm codecov-io


text:
bluetooth: fix unchecked return from lll_clk_off in ll_test_end

Inside ll_test_end(), result of lll_clk_off() is not checked
which might result in releasing resources acquired for radio.
Coverity-CID: 190954
Fixes: #13861
Signed-off-by: Maksim Masalski maxxliferobot@gmail.com

Codecov Report

Merging #14020 into master will decrease coverage by 0.03%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##           master   #14020      +/-   ##
==========================================
- Coverage   52.27%   52.24%   -0.04%
==========================================
  Files         307      307
  Lines       45467    45467
  Branches    10525    10525
==========================================
- Hits        23768    23752      -16
- Misses      16901    16913      +12
- Partials     4798     4802       +4

Impacted Files
Coverage Δ

subsys/testsuite/ztest/include/ztest_assert.h
38.88% <0%> (-38.89%)
:arrow_down:

subsys/testsuite/ztest/src/ztest.c
65.28% <0%> (-7.44%)
:arrow_down:

Continue to review full report at Codecov.

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

Hey @maxxlife , thanks for your patch. I think you committed the changes in separate commits by mistake. To correct this you can squash your commits doing:
git rebase -i upstream/master
and then following the instructions given by Git.
Once you have rebased you can force-push to your branch with:
git push -f origin

Should it be an assert though, or propagate the error upwards by returning error?

authors: carlescufi codecov-io maxxlife mped-oticon


text:
sntp_client for cc3220sf_launchxl

This PR adds support for cc3220sf_launchxl to the sntp_client sample.
Some modifications are made to the example to make IPv6 and NET_CONFIG_SETTINGS optional, since these are not currently working in the cc3220sf wifi driver implementation.

Codecov Report

Merging #14548 into master will decrease coverage by 0.03%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##           master   #14548      +/-   ##
==========================================
- Coverage   52.02%   51.99%   -0.04%
==========================================
  Files         309      309
  Lines       45574    45574
  Branches    10555    10555
==========================================
- Hits        23711    23695      -16
- Misses      17057    17069      +12
- Partials     4806     4810       +4

Impacted Files
Coverage Δ

subsys/testsuite/ztest/include/ztest_assert.h
38.88% <0%> (-38.89%)
:arrow_down:

subsys/testsuite/ztest/src/ztest.c
65.28% <0%> (-7.44%)
:arrow_down:

Continue to review full report at Codecov.

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

NET_CONFIG_SETTINGS optional, since these are not currently working in the cc3220sf wifi driver implementation.

NET_CONFIG_SETTINGS isn't supported on cc3220? But that's one of the most basic networking sub-subsystems in general, and for samples in particular. Almost every sample uses it, do you intend to patch them all? Why the choice is on making such patches instead of implementing NET_CONFIG_SETTINGS support?
The specific commit message:

In this commit, a config.h header file is added to support the case
when the NET_CONFIG_SETTINGS is not used

should mention that this is being done to allow cc3220 support. Actually, I'm a bit proponent of detailed, well-separated changes, but here I'd say it might be better to squash the two commits together.

but here I'd say it might be better to squash the two commits together.

Please do not squash the patches, there is now two different changes which is ok in this case.

NET_CONFIG_SETTINGS isn't supported on cc3220? But that's one of the most basic networking sub-subsystems in general, and for samples in particular. Almost every sample uses it, do you intend to patch them all? Why the choice is on making such patches instead of implementing NET_CONFIG_SETTINGS support?

@pfalcon Implementing NET_CONFIG_SETTINGS fully is non-trivial, as far as I understand. As @GAnthony mentioned in #11889, NET_CONFIG_SETTINGS forces hardcoded values for IP address, which is not desired for an offload driver which already handles DHCP, and brings in other unnecessary functions. It is a current limitation in the SimpleLink driver where we do not support static IP addresses that are set via NET_CONFIG_SETTINGS. So you are right, I'd have to patch the samples that are supported on cc3220xl_launchxl. Fortunately some of them were already following this model where NET_CONFIG_SETTINGS may or may not be defined (e.g. mqtt_publisher), so I am simply following suit.

Updated commit message per comment from @pfalcon, and fixed a build issue in config.h.

authors: codecov-io jukkar pfalcon vanti


text:
tests/drivers/ipm: Enable on (uniprocessor) x86_64

[Let's just skip the SMP work in #14619 and commit the obvious workaround for now.   There's a giant task for 1.15 to make all the tests and subsystems SMP-safe anyway, there's no need to jump through different hoops for IPM of all things.]
This test was having trouble earlier (at least with some toolchains),
but whatever was causing that seems to have been fixed.  The only
remaining issue is that neither the IPM console code nor the test are
SMP-safe.  There's a bug (#14639) tracking the need to get these
working, but for now the straightforward workaround is just to disable
SMP.
And even long term, IPM is an oddball interprocessor communication
mechanism designed for asymmetric multiprocessing devices like Quark
SE and doesn't seem like an obvious fit for a SMP machine.
Fixes #12478
Signed-off-by: Andy Ross andrew.j.ross@intel.com

Ran this on both my dev machine and an only-slightly-stale CI docker image and it worked for 30 runs each without failure.  Should be OK in the actual CI, but note that the earliest version of this bug was weirdly spurious and from an era before SMP became default, so..


text:
drivers: improve the arcv2_timer driver to update cycles correctly

referring the ARM's Systick driver, we did the following improvements:

use 31 bits of 32-bit counter to avoid the rare but possible
overflow of elapsed(). If 32 bits val are used, elpased() may
return a wrong value. then wrong HW cycles.

two ways to update the correct cycles

through systick timer irq
when systick timer irq cann't be handled because of irq
locked/disabled, call z_timer_cycle_get_32->elapsed to update
the correct cylces. no more than one counter-wrap is allowed.

if elapsed() is not called too long (more than one counter-wrap) from
systick tiemr irq or from z_timer_cycle_get_32. The lost of HW cycles
is unavoidable.

some detailed discussion can be found in #24332

Signed-off-by: Wayne Ren wei.ren@synopsys.com
Fixes #23476

@ruuddw please approve if happy as-is

@ruuddw @andyross I changed the place of clearing counter in z_clock_set_timeout to reduce the cycles loss as few as possible. However didn't find a 0 loss solution by only changing LIMIT not COUNT.  Any ideas?

(with this location, the drift is likely lower than the timer accuracy anyway...)
The original implementation didn't touch count - but was less robust against long interrupt disable.
ARC has multiple timers (configurable HW IP, depending on the silicon design configuration), a combination of timer0 + RTC or timer1 (like for SMP) would likely be much simpler.
Not for this PR, but something to consider adding in the future.

I'm OK with establishing an upper bound on how long you can busy-wait for. I don't know what that value should specifically be, but I agree that in practice people busy-wait for very short time periods.

@abrodkin , my understanding is your concern is about pulse trigger of ARC internal timer. Although it was rarely used before, and not clearly documented in ARCv2 ISA,  the pulse trigger of ARC internal timer should be supported,  nsim works, what we need to do is make a double check on hardware.  The self-clear of timer irq also avoids re-setting CTRL/clearing IP bit in isr, makes codes more generic. I don't think it's a trick.
The IP bit of CTRL takes two roles, COUNTER overflow and IP pending.  If in hardware two different bits for two different roles. Even pulse trigger is not supported, we also can separately clear IP pending bit in timer ISR.
For k_busy_wait ,  i don't mind whether a limit check is added, because in other places, drivers, application  etc. because of poor codes, poor design,  the irq can still be locked for long time although we all know it's not right.  But current cycle based k_busy_wait can update the total cycles correctly, so when irq is unlocked , we can get the correct cycles and ticks.
And even a limit is added in k_busy_wait, this PR still works. In fact, this PR includes a fix of bugs found through k_busy_wait but not limited.
Again,
the core concern of this PR is whether we can use pulse trigger for timer irq.   If really can't work because of hardware limitation ,  i will move clear of IP bit out of elapsed() , and into timer isr.
With this PR and some my previous PRs,  i got a clean sanitycheck results of test/kernel

@abrodkin I think the implementation is acceptable now. Similar to CM systick, and the drift is minimal. Losing ticks due to long interrupt disable times (also during busy wait) would not be normal, regular use (interrupt disable/busy waiting should normally be less than 2 tick periods).
I believe there is or has been some discussion on a counter api vs timer api - using a separate RTC / timer1 could be something to do for supporting the RTC/counter driver and not timer for _cycle_get_32.

ping for merge, as the merge window is closing.

ping for merge, as the merge window is closing.

@vonhust need @abrodkin to re-visit his current -1 review for that

@abrodkin I think the implementation is acceptable now. Similar to CM systick, and the drift is minimal. Losing ticks due to long interrupt disable times (also during busy wait) would not be normal, regular use (interrupt disable/busy waiting should normally be less than 2 tick periods).

@ruuddw if you approve of the patch....can you please approve it in GitHub?

authors: andrewboie carlescufi ruuddw vonhust


text:
Bluetooth: L2CAP: Document behavior of alloc_buf

Channel that requires segmentation must set alloc_buf in order for the
stack to be able to reassemble segments of an SDU.
If this happens at runtime warn the user and truncate the MTU to
force segmentation to be disabled.
Fixed #28384
Signed-off-by: Luiz Augusto von Dentz luiz.von.dentz@intel.com

..or alternatively split this into two commits: one that updates alloc_buf documentation and another which does the code change

..or alternatively split this into two commits: one that updates alloc_buf documentation and another which does the code change

Done.

authors: Vudentz jhedberg


text:
driver: timer: npcx: fix dead code flow for K_TICKS_FOREVER.

Fix dead code flow if ticks is K_TICKS_FOREVER. Please refer issue 33018 for more detail.
Fixes #33018
Signed-off-by: Mulin Chao mlchao@nuvoton.com

Hi All:
This PR is fixing the coverity issue related to dead code. Any comment is appreciated. Thanks.


text:
cmake: CMake compile features support

Fixes: #36558 #32577
This commit introduces CMAKE_C_COMPILE_FEATURES and
CMAKE_CXX_COMPILE_FEATURES.
This allows users to use the target_compile_features() in their own
code.
In Zephyr, the CMAKE_C/CXX_COMPILE_FEATURES are defined based on the
compiler and the Kconfig / CSTD setting.
Doing so ensures that a user compiling Zephyr with c99 and specifies
target_compile_features(<target> ... c_std_11) will get an error.
And similar if building Zephyr with C++ support and c++11, but testing
for target_compile_features(<target> ... cxx_std_17).
For example in the C++ case, the user must ensure that Zephyr is
compiled with C++17, that is: CPLUSPLUS=y and STD_CPP17=y, in which case
the CMAKE_CXX_COMPILE_FEATURES will contain support for C++17 and thus
the target_compile_features(<target> ... cxx_std_17) will succeed.
Signed-off-by: Torsten Rasmussen Torsten.Rasmussen@nordicsemi.no

I don't think it is necessary to document everything that should NOT be done. That statespace is too big.
We state that the user should start with a CMakeLists.txt that looks like this:
# Find Zephyr. This also loads Zephyr's build system.
cmake_minimum_required(VERSION 3.13.1)
find_package(Zephyr)
project(my_zephyr_app)

# Add your source file to the "app" target. This must come after
# find_package(Zephyr) which defines the target.
target_sources(app PRIVATE src/main.c)

IMHO that is enough documentation.

@SebastianBoe, we are talking about uses who know CMake much more than the Zephyr build system.  If we don't say, "project() must be called after find_package(Zephyr)", they assume they can.  The following change isn't "too big", since this section is the first time a new Zephyr user is exposed to the line-by-line explanation of a Zephyr application CMakeLists.txt.
diff --git a/doc/application/index.rst b/doc/application/index.rst
index 73d6b2e40a..824cedb3a1 100644
--- a/doc/application/index.rst
+++ b/doc/application/index.rst
@@ -219,22 +219,30 @@ Zephyr.)

    .. code-block:: cmake

-      # Find Zephyr. This also loads Zephyr's build system.
-      cmake_minimum_required(VERSION 3.13.1)
+      cmake_minimum_required(VERSION 3.20.0)
+
       find_package(Zephyr)
       project(my_zephyr_app)

-      # Add your source file to the "app" target. This must come after
-      # find_package(Zephyr) which defines the target.
       target_sources(app PRIVATE src/main.c)

-   ``find_package(Zephyr)`` sets the minimum CMake version and pulls in the
-   Zephyr build system, which creates a CMake target named ``app`` (see
-   :ref:`cmake_pkg`). Adding sources to this target is how you include them in
-   the build.
+   ``cmake_minimum_required()`` is required to be in your
+   :file:`CMakeListst.txt` by CMake. It is also invoked by the Zephyr
+   package. The most recent of the two versions will be enforced by
+   CMake.
+
+   ``find_package(Zephyr)`` pulls in the Zephyr build system, which
+   creates a CMake target named ``app`` (see :ref:`cmake_pkg`). Adding
+   sources to this target is how you include them in the build.
+
+   ``project(my_zephyr_app)`` must be called after
+   ``find_package(Zephyr)`` in order to let the Zephyr package perform
+   its own toolchain testing and presetting variables before CMake
+   does.

-   .. note:: ``cmake_minimum_required()`` is also invoked by the Zephyr package.
-              The most recent of the two versions will be enforced by CMake.
+   ``target_sources(app PRIVATE src/main.c)`` is to add your source
+   file to the "app" target. This must come after
+   ``find_package(Zephyr)`` which defines the target.

 #. Set Kconfig configuration options. See :ref:`application-kconfig`.

If anyone find it useful, I'll make a PR.

authors: SebastianBoe tejlmand yashi


text:
tests: net: socket: websocket move to new ztest API

Move net/socket/websocket tests to use new ztest API
Signed-off-by: Hu Zhenyu zhenyu.hu@intel.com

CONFIG_ZTEST_SHUFFLE=y can be turned on

@nashif Thanks to review and +1, so that the PR can be merged into the mainline.

@enjiamai  the numbers in the function name is not added by me, it was there before.
@nashif Thank to review and +1, so that the patch can be merged to mainline.

@nashif can we merge this PR?


text:
ARM: nxp_imx: rt10xx: migrate ARM, AHB and IPG dividers to DT

Those dividers were configured in Kconfig so far. Add 'arm-podf',
'ahb-podf' and 'ipg-podf' "fixed-factor-clock" compatible DT child nodes
under 'ccm' (Clock Control Module) and use configured 'clock-div' values
instead of Kconfig equivalents.

Can we represent these as compatible = "fixed-factor-clock"?

@galak I reworked PR to use "fixed-factor-clock". Looks cleaner now, I think.

Rebased and added BUILD_ASSERT_PODF_IN_RANGE helper macro with build-time verification of arm-podf, ahb-podf and ipg-podf.
As an example if ipg-podf is set to 5 (which is out of 1-4 range), then following error occurs during build:
In file included from /zephyr/include/zephyr/toolchain.h:50,
                 from /zephyr/include/zephyr/kernel_includes.h:19,
                 from /zephyr/include/zephyr/kernel.h:17,
                 from /zephyr/soc/arm/nxp_imx/rt/soc_rt10xx.c:7:
/zephyr/soc/arm/nxp_imx/rt/soc_rt10xx.c: In function 'clock_init':
/zephyr/include/zephyr/toolchain/gcc.h:77:36: error: static assertion failed: "ipg_podf is out of supported range (1, 4)"
   77 | #define BUILD_ASSERT(EXPR, MSG...) _Static_assert(EXPR, "" MSG)
      |                                    ^~~~~~~~~~~~~~
/zephyr/soc/arm/nxp_imx/rt/soc_rt10xx.c:27:9: note: in expansion of macro 'BUILD_ASSERT'
   27 |         BUILD_ASSERT(DT_PROP(DT_CHILD(CCM_NODE, podf), clock_div) >= (a) && \
      |         ^~~~~~~~~~~~
/zephyr/soc/arm/nxp_imx/rt/soc_rt10xx.c:152:9: note: in expansion of macro 'BUILD_ASSERT_PODF_IN_RANGE'
  152 |         BUILD_ASSERT_PODF_IN_RANGE(ipg_podf, 1, 4);
      |         ^~~~~~~~~~~~~~~~~~~~~~~~~~
[81/160] Building C object zephyr/arch/arch/arm/core/aarch32/cortex_m/CMakeFiles/arch__arm__core__aarch32__cortex_m.dir/fault.c.obj


text:
Improved SAMD20/SAMD21/SAMR21 clocking mechanism

Signed-off-by: Ionut Catalin Pavel iocapa@iocapa.com
There are some issues with the current version of the code, mainly the improper use of the internal OSC8M as a source for the DFLL48m  without division. The DFLL48M is designed to accept a maximum of ~33KHz at it's input, as higher values will bring the multiplier down, leading to instability.
Since there were also some missing features, I've added the following:

Support for external HF oscillator (XOSC) with user selectable frequency
Support for choosing between crystal/external oscillators on XOSC32K/XOSC
Automatic dividers/multiplier computation based on DT cpu frequency
Support for user configurable NVM wait states
Added option to skip clock (re)initialization. Useful in case of chain loading from a bootloader

Tests were performed on a custom SAMD20G18 board using different clock sources and cpu frequencies.
According to the datasheet, architecture is identical on D21/R21.
Clocks were routed to GPIO and observed on a scope.
Due to the nature of the internal architecture and the fact that DFLL48M is not really meant to output anything other than 48MHZ some combinations of requested DT cpu frequency and source frequency will not result in a perfect match.
Mostly insipred by the SAML21 implementation.
First PR on zephyr. Hope I didn't miss anything.

Thanks for the contribution. Please take a look at the Contribution Guidelines and update the commit title and description accordingly.

Thanks for the contribution. Please take a look at the Contribution Guidelines and update the commit title and description accordingly.

Yes, I see now that there are some issues.
Will address them and update the branch.

Seems there still was a TRAILING_WHITESPACE issue left.
Fixed it. Checks should pass now.

authors: iocapa stephanosio


text:
tests bsim: Change folder structure

Bsim won't be limited anymore to BT tests.
In preparation for adding more tests in network areas swap the tests/bluetooth/bsim with tests/bsim/bluetooth
There is no other changes in this commit beyond that.

A reminder to myself that the bluetooth-tests workflow needs to be renamed to bsim-tests after this is merged.

authors: aescolar stephanosio


text:
Share MCUboot mode to app and use it in MCUmgr for basic DirectXIP support

Three commits:

introducing Kconfig options that allow to inform application regarding MCUboot mode the application will be boot with;
disabling MCUmgr image management when MCUboot has been configured for single application mode;
disabling setting of image state, to confirm or test, when MCUboot has been configured for DirectXIP

@de-nordic, is Kconfig.zephyr the best place to add options on how mcuboot has been configured ?

@de-nordic, is Kconfig.zephyr the best place to add options on how mcuboot has been configured ?

I think other MCUBOOT options are already there, that is why I have landed those here.
And answering your question: probably not, goto 1)

Puts on build system hat this is an interesting proposal, but from the point of view of the future and sysbuild, is something that sysbuild should control #53126 @tejlmand

Puts on desperate developer hat you can have them and control them, I just need them.

@de-nordic, is Kconfig.zephyr the best place to add options on how mcuboot has been configured ?

I think other MCUBOOT options are already there, that is why I have landed those here.
And answering your question: probably not, goto 1)

:disappointed:

@Laczen Separated Kconfig file.
@MarekPieta Renamed Kconfigs to MCUBOOT_BOOTLOADER_MODE_ and added name for choice
@nordicjm Please re-review.

authors: Laczen de-nordic


text:
drivers: sensor: ms5837: Use devicetree property to identify MS5837 type and correct MS5837-30BA conversion

The current device type determination using the factory ID is unable to differentiate MS5837-02BA01 and MS5837-30BA01 devices resulting in the 02BA compensation being used for a 30BA device. In addition, the 30BA conversion units don't match 02BA and the resulting pressure value is off by a factor of 10.
A submodel enum property is added to devicetree that is used to specify which specific device type is in use, "02ba" (default) or "30ba".
In addition, ms5837_compensate_30's pressure result now matches the units of ms5837_compensate_02 so the read pressure is as expected.
Refer to #60950 for more context.

After reviewing the guidelines from the bot, I realized I need to revise my commit messages. I will need to open a new PR.


text:
drivers: sensor: lsm6dsl: fix precision on gyro and acc measurements

Following #63980, I suggest a fix to allow for more than 3 decimal digits on gyroscope and accelerations measurements from the LSM6DSL sensor.

This should instead use sensor_value_from_double(), which also includes bounds checking.

@Alessio-Parmeggiani can you pls rebase this commit? We are very close to finish it. Thanks

@Alessio-Parmeggiani can you pls rebase this commit? We are very close to finish it. Thanks

Sorry, what do you mean? I am not an expert in this kind of git stuff

@Alessio-Parmeggiani can you pls rebase this commit? We are very close to finish it. Thanks

Sorry, what do you mean? I am not an expert in this kind of git stuff

I see now that you are using your main branch. You may want to create a new branch for this work from main (e.g. git checkout -b lsm6dsl-fix). Then come back to main and git pull all the work. Then switch back to your work branch and rebase it interactively on main (i.e. git rebase -i main). Please take a look at documentation if this is new stuff. But it is something required for a zephyr contributor.

@Alessio-Parmeggiani can you pls rebase this commit? We are very close to finish it. Thanks

Sorry, what do you mean? I am not an expert in this kind of git stuff

It is required to solve the conflicts below

You have to rebase, not merge

Needs a rebase, also a commit message description and sign-off-by, see https://docs.zephyrproject.org/latest/contribute/guidelines.html#contribution-workflow (or ask for help on discord)

replaced  by #72367

authors: Alessio-Parmeggiani arbrauns avisconti fabiobaltieri


text:
boards: phytec: Remove Messtechnik GmbH

PHYTEC has multiple offices in different locations like the US, France, India and China. The headquarter is located in Germany. Since now 50% of the PHYTEC boards are from the US office, we should drop 'Messtechnik GmbH', which is the offical title of the German office, and keep the name more general.

@tejlmand can you help me to simplify our company name? I saw you changed to hw v2 but we there is no maintainer for this file.


text:
kconfig: sca: Add Kconfig for SCA tools

Add the possibility to use Kconfig for SCA tools.
Sometimes SCA tools can have a different or complex setups to run or outputs to generate.
The implemented cmake sca mechanism right now only allows configuration of the tools by using env variables or passing parameters to the build command. Which makes the integration and configuration seems very hidden and undocumented for everyone else as well.
The first Kconfig options for a SCA tool would be introduced with https://github.com/zephyrproject-rtos/zephyr/pull/68324

Adding this without any contents doesn't seem to be the right approach though. You should at least add one of the SCA tools to begin with IMO.

Adding this without any contents doesn't seem to be the right approach though. You should at least add one of the SCA tools to begin with IMO.

Good point, thought about the same thing after I opened it yesterday.
I will close this PR and will add it with my PR https://github.com/zephyrproject-rtos/zephyr/pull/68324 where the first tool would use this

authors: pdgendt simhein


text:
misc: add a section to store kernel version information

A section in linker is created to store the kernel version information .This feature is enabled based on CONFIG_VERSION_HEADER. This change make a provision to access the version information from the zephyr elf.
Signed-off-by: Savinay Dharmappa savinay.dharmappa@intel.com

No issue with this, but any particular reasons to add this?

@andrewboie @galak  to detect any changes of symbols names in future Zephyr releases in an debug environment.

@nashif  we already have test tests/kernel/common/src/main.c test_version() wouldn't that be suffice.

recheck

@galak @andyross  version header will be part of both binary and ELF. The idea is to have version_header structure object as part of ELF and binary ,even though this object is not referenced by the code(override linker optimization).  This structure object information can be filled externally as this object is part of special section.

Can anyone help me on why I failed to get the required version in the test case please?

I am having problems running tests/kernel/version_header.
Assertion failed at
./tests/kernel/version_header/src/main.c:20: test_version: (version_header.major == KERNEL_VERSION_MAJOR ) major version mismatch

After I add printk() statement in main.c:
printk("EXPECTED=%d.%d.%d\n", KERNEL_VERSION_MAJOR, KERNEL_VERSION_MINOR, KERNEL_PATCHLEVEL);
printk("GOT     =%d.%d.%d\n", version_header.major, version_header.minor, version_header.patch);

I get
EXPECTED=1.13.99
GOT     =0.0.0

I got it on multiple platforms, e.g. 'altera_max10'.
My .config file has CONFIG_VERSION_HEADER. include/generated/version.h contains the KERNEL_VERSION_XXX information which matches the result.

Given that many people have objections to this patch and the original author is no longer working on Zephyr, I think we should just close this.

@marc-hb maybe you could pick this up in a new PR

authors: SavinayDharmappa andrewboie carlescufi cinlyooi-intel galak pswarnak


text:
ZEP-1757: update uri to nz

Changed all below URI to NZ equivalent as per ZEP-1757 card description:
api.split.cash → nz.api.zepto.money (source/index.html.md & source/openapi3/split.yaml)
go.split.cash → nz.go.zepto.money (source/index.html.md & source/openapi3/split.yaml)
api.sandbox.split.cash → nz.api.sandbox.zepto.money (source/index.html.md & source/openapi3/split.yaml)
go.sandbox.split.cash → nz.go.sandbox.zepto.money (source/index.html.md & source/openapi3/split.yaml)
docs.zepto.money → nz.docs.zepto.money (source/CNAME)
Also deleted PR template message as no longer relevant (current NZ repo was not forked from slate repo)

Thanks @friendlyantz will follow this convention moving forward

repo: zeptofs/nz-api-documentation


text:
#38 the between in Award must not give anything when too small value

To implement task #38, I modified the part for :between. Also the test test_some_terms was changed. This case is similar to (award (give (between -2 -10 -30))) and the expected value should be zero

@yegor256 please, review it

@rultor merge

@rultor merge

@yegor256 OK, I'll try to merge now. You can check the progress of the merge here

@rultor merge

@yegor256 Done! FYI, the full log is here (took me 8min)

@Suban05 thanks!

@Suban05 Thanks for the contribution! You've earned +20 points for this: +30 as a basis; -10 for too few (3) comments. Please, keep them coming. Your running balance is +50.

@yegor256 Thanks for the review! You've earned +20 points for this: +25 as a basis; -10 for too few (5) comments; +5 for the 5 comment(s) that you have made.  Your running balance is -356.

repo: zerocracy/fbe


text:
fix Replacer suffix match, and add test case

In current Replace method, the following test case won't pass, but it should pass.

func TestReplacer_ReplaceSuffixMatch(t *testing.T) {
 // case1
 {
  keywords := map[string]string{
   "abcde": "ABCDE",
   "bcde":  "BCDE",
   "bcd":   "BCD",
  }
  assert.Equal(t, "aBCDf", NewReplacer(keywords).Replace("abcdf"))
 }
 // case2
 {
  keywords := map[string]string{
   "abcde": "ABCDE",
   "bcde":  "BCDE",
   "cde":   "CDE",
   "c":     "C",
   "cd":    "CD",
  }
  assert.Equal(t, "abCDf", NewReplacer(keywords).Replace("abcdf"))
 }
}

It's not only used here. also in trie.go

It's not only used here. also in trie.go

@kevwan  node.go 的修改不会影响 trie.go。trie主要使用find就可以把全部范围设置成*， 即使多处匹配中间有重叠也不影响。而Replace在有重叠的时候，会按照两个条件选择

在两处匹配有重叠的情况下，两处匹配开始位置在前面的优先匹配。比如[1, 3)和[2, 4)， 应该优先匹配[1, 3)
如果两处匹配的开始位置相同，那么按照长度较长的来匹配替换。比如[1, 3) 和[1, 4), 应该优先匹配[1, 4)

authors: dahaihu kevwan

repo: zeromicro/go-zero


text:
Labelling has no effect on one_of()?

hey! i was trying to apply some labels on a .one_of(Range) parser but it didn't work, so i decided to try a few other cases:
type E = extra::Err<Rich<'static, char>>;
println!("one_of(range): {:?}", one_of::<_, _, E>('a'..='c').labelled("abc").parse("x"));
println!("one_of(str): {:?}", one_of::<_, _, E>("abc").labelled("abc").parse("x"));
println!("just().or(): {:?}", just::<_, _, E>('a').or(just('b').or(just('c'))).labelled("abc").parse("x"));
println!("choice(just()): {:?}", choice((just::<_, _, E>('a'), just('b'), just('c'))).labelled("abc").parse("x"));
println!("ident(): {:?}", text::unicode::ident::<_, _, E>().labelled("abc").parse("!"));
println!("none_of(): {:?}", none_of::<_, _, E>("def").labelled("abc").parse("e"));

one_of(range): ParseResult { output: None, errs: [found 'x' at 0..1 expected ''a'', ''b'', or ''c''] } // bad
one_of(str): ParseResult { output: None, errs: [found 'x' at 0..1 expected ''a'', ''b'', or ''c''] } // bad
just().or(): ParseResult { output: None, errs: [found 'x' at 0..1 expected "abc"] }
choice(just()): ParseResult { output: None, errs: [found 'x' at 0..1 expected "abc"] }
ident(): ParseResult { output: None, errs: [found '!' at 0..1 expected "abc"] }
none_of(): ParseResult { output: None, errs: [found 'e' at 0..1 expected something else] }

as you can see the label does not show up in cases where one_of() is used. let me know if i'm doing something wrong!

Is this using the latest main? If so, I have an inkling...

hey, nope this is on alpha.7

What's the error, out of interest?
I think I know what's causing this, but resolving it in the general case is... a little finickey, I think.

ha, i was trying to build with the nightly feature on stable, so that's what the error was.
sounds interesting, if you could explain it a little bit that would be cool, maybe someone can help

So when a parser succeeds, it leaves the input pointing at the next token after whatever it parsed. But when a parser fails, the state it leaves the parser in is unspecified (as in: that's how chumsky behaves right now).
The problem is that labelled depends on the input being left in a specific place, since it determines whether to treat the label as a pattern (i.e: expected foo) or context (i.e: error occurred while parsing foo).
The reason this works with just and not one_of is because the former rewinds the input on failure, while the latter does not. Fixing this is as simple as making the two consistent, but to really fix it chumsky probably needs to take a clearer stance on what state the input should be left in on failure - which also means building that stance into the extension API and so on.
I can give more information tomorrow.

authors: cAttte zesterer

repo: zesterer/chumsky


text:
final changes to /ppc/explore landing page

Please see below

:

@Katiemoser

Approved! LMK when it's merged in the next PR and I'll send over any mobile edits. Thanks!

repo: zesty-io/nextjs-website

license: Unlicense


text:
New page - CDN hosting

https://www.figma.com/file/iETaF6c8BJGKKvbFuy3NV9/ZESTY-PAGES-DESIGNS?node-id=0%3A1
https://8-aaeffee09b-7w6v22.manager.zesty.io/content/6-ca81d1fdf3-vf07cl/7-d8c2c59ff7-qcpmlc

https://www.zesty.io/features/cdn-hosting/

authors: Katiemoser jeromeZestyIO

repo: zesty-io/website


text:
Marketing layouts component integration

Layouts components mapping on dev branch:
https://zesty-dev-website-m3rbwjxm5q-uc.a.run.app/layouts-test-page/

Updated screenshot


text:
ci: fixing smoketest runners

Description
Fixes the smoke test workflow to work on public runners, removed a bunch of unused actions, and disabled the Discord token based release notification. We can do it much more safely with webhooks for a specific channel vs using a Discord bot token.
Type of change

[ ] Bug fix (non-breaking change which fixes an issue)
[ ] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
[ ] This change requires a documentation update

How Has This Been Tested?
Please describe the tests that you ran to verify your changes. Include instructions and any relevant details so others can reproduce.

[ ] Tested CCTX in localnet
[ ] Tested in development environment
[ ] Go unit tests
[ ] Go integration tests
[ ] Tested via GitHub Actions

Checklist:

[ ] I have added unit tests that prove my fix feature works

This looks good to me, I'm just wondering about one thing. make zetanode step seems to take one additional minute to complete compared to before: https://github.com/zeta-chain/node/actions/runs/7410644201/job/20163410705?pr=1436 https://github.com/zeta-chain/node/actions/runs/7414576117/job/20175927185?pr=1525 Any known reason for this?

Likely do to a change in runners. Our private runners make have had higher performance or a faster network connection but I not sure about that.
We can do testing in another PR and compare the speed across different sized runners.

repo: zeta-chain/node


text:
UV Messed up

My baked lightmap uses wrong uv after optimize

House_Test_Opt.zip

I'm not sure which viewer you're using but it's likely a problem with your viewer:

three.js based viewer (https://gltf-viewer.donmccurdy.com/) has broken UVs on both models
Babylon.js based viewer (https://sandbox.babylonjs.com/) has correct UVs on both models

When using three.js, note that the standard material setup assumes that AO map uses UV1 and all other maps use UV0. Your model has the lightmap mapped to emissiveTexture instead of occlusionTexture, so the viewers can't display it; fixing the material setup results in correct rendering for three.js viewer, again before and other optimization.

authors: LorenzWieseke zeux

repo: zeux/meshoptimizer


text:
Typescript error with example code

Hello,
I installed the latest version, I copy / paste the example code and there is a Typescript error.
The example code :
// ...
// using async/await
try {
  const response = await client.createNotification(notification);
  console.log(response.body.id); // <-- HERE
} catch (e) {
  if (e instanceof OneSignal.HTTPError) {
    // When status code of HTTP response is not 2xx, HTTPError is thrown.
    console.log(e.statusCode);
    console.log(e.body);
  }

The Typescript error:
Property 'id' does not exist on type '{}'

Why there is this error? Because of this in index.d.ts:
export interface ClientResponse {
    statusCode: number;
    body: {};
    headers: {
        [key: string]: any;
    };
}

Hey @lludol ,
This is just a sample code and not meant to execute correctly for every situation. The exception  basically says that there is no id property on body. You might try to log body itself and see the content: console.log(response.body);

Yes I know that can check what is inside. But what's the point of having Typescript types defininitions if there are incomplete?

My bad, I overlooked the error details you provided. I will open a bug-fix request for this ticket. Thanks for opening an issue.

Fixed on https://github.com/zeyneloz/onesignal-node/pull/47
Released as v3.0.2

authors: lludol zeyneloz

repo: zeyneloz/onesignal-node


text:
PatchKey uses ReplaceKey

The function patchKey does not actually patch a key.  It uses replaceKey to do the heavy lifting:
https://github.com/zfcampus/zf-configuration/blob/master/src/ConfigResource.php#L118
I submit patchKey should read the current key and merge the arrays.

This is still a big issue for zf-apigility-doctrine users because the query_create_filters and query_providers are all lost.  These are a major source of security information for an app.
This issue was closed for 1.3.1 which was reverted to 1.3.2 and remains unfixed today.  Will you please re-open this issue and prioritize it high.

Seeing this fixed is a priority to me so I'll dig through it to see about fixing the library and fixing the admin.  I (should) have down time in a couple weeks in SF to investigate.

This repository has been closed and moved to laminas-api-tools/api-tools-configuration; a new issue has been opened at https://github.com/laminas-api-tools/api-tools-configuration/issues/2.

authors: TomHAnderson weierophinney

repo: zfcampus/zf-configuration


text:
OAuth2ServerFactory is not returning instance of OAuth2\Server

The ZF\OAuth2\Factory\OAuth2ServerFactory is no longer returning a OAuth2\Server instance?
https://github.com/zfcampus/zf-oauth2/blob/master/src/Factory/OAuth2ServerFactory.php
The file has been changed in the latest version and it returns a closure (Factory!?) now. My code is broken since I simply used $serviceLocator->get('ZF\OAuth2\Service\OAuth2Server'); elsewhere to get the OAuth2\Server instance from the server manager.
The documentation has also not been updated accordingly and is no longer up to date since it still states it will give me an OAuth\Server.
Is returning another factory from a factory really the way to go? How should I now get my oauth server instance? Is it maybe possible to separate the keys so getting the server is still possible?

My code editor also doesn't agree on a closure being returned by ServiceManager :)
Deep down in the ZF2 ServiceLocatorInterface the return values from a service manager should be either an object or an array:
    /**
     * Retrieve a registered instance
     *
     * @param  string  $name
     * @throws Exception\ServiceNotFoundException
     * @return object|array
     */
    public function get($name);

In the ZF\MvcAuth\Factory\DefaultAuthenticationListenerFactory the following is done:
return new OAuth2Adapter($factory()); (https://github.com/zfcampus/zf-mvc-auth/blob/master/src/Factory/DefaultAuthenticationListenerFactory.php#L105)
return new OAuth2Adapter($serverFactory(null)); (https://github.com/zfcampus/zf-mvc-auth/blob/master/src/Factory/DefaultAuthenticationListenerFactory.php#L128)
Because of this my code editor puts big fat red lines under my classes :)
All because it doesn't expect a closure and we cannot instantiate a array or an object.
I think it would be better to return the OAuth2\Server instead of the factory here.

@Wilt PR ? :)

@jguittard I was awaiting response from someone working on this repository to get some feedback on how to improve this...
@weierophinney Do you have time to take a quick look and make a suggestion on how to deal with this in a PR?

@Wilt This was done due to issues with the design of oauth2-server. Essentially, the OAuth2\Server instance does work on initialization that can lead to issues with the HTTP request, database connections, and more. We had to provide a way to lazy-load it to solve the problems.
We can maybe solve the IDE issues with typehints, and some of these may be solved now (I did some work on the AuthControllerFactory earlier today). But I'm not sure we can make any other changes unless we change out the oauth2 server infrastructure or get changes pushed upstream to oauth2-server-php.

@weierophinney Thanks for the explanation. I am not sure wha
Would it be possible to use a Lazy Services pattern for this instead of this invokable factory? Or is this not sufficient to solve those issues you refer to?

This repository has been closed and moved to laminas-api-tools/api-tools-oauth2; a new issue has been opened at https://github.com/laminas-api-tools/api-tools-oauth2/issues/14.

authors: Wilt jguittard weierophinney


text:
camera become chaos when autorotating

The main demo has separated  allowsLandscape and take a picture
functions which will omit the chaos when both are invoked. When I set
the allowsLandscape = true and take a photo, the camera would rotate
automatically to cause the performance wrong and part of the camera view is
covered underground to have no way to take a photo.
My solution is getting rid of the Camera sourceType when trying to
autorotate. It seems work fine.
Hope to help someone. And I have learned a lot from author.

Thanks for your patch!!!


text:
Localization NL

Dutch language

Thanks for your PR!!!


text:
消息模板建议使用freemarkder

版本号：
2.2.1
问题描述：
当前的消息模板中只能通过 ${variableName} 方式插入简单的值，这一块建议可以使用模板引擎，例如freemarker，如果使用freemarker，则可以兼容之前的写法，修改的也很少，经过测试也是ok的
截图&代码：

+import java.io.IOException;
+import java.io.StringWriter;
+import java.util.Date;
+import java.util.List;
+import java.util.Map;
+import com.alibaba.fastjson.JSONObject;
 import org.jeecg.modules.message.entity.SysMessage;
 import org.jeecg.modules.message.entity.SysMessageTemplate;
 import org.jeecg.modules.message.handle.enums.SendMsgStatusEnum;
@@ -7,12 +13,9 @@ import org.jeecg.modules.message.service.ISysMessageService;
 import org.jeecg.modules.message.service.ISysMessageTemplateService;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Component;
-
-import com.alibaba.fastjson.JSONObject;
-
-import java.util.Date;
-import java.util.List;
-import java.util.Map;
+import freemarker.template.Configuration;
+import freemarker.template.Template;
+import freemarker.template.TemplateException;

+    @Autowired
+    private Configuration freemarkerConfig;

-            if(map!=null) {
-                for (Map.Entry<String, String> entry : map.entrySet()) {
-                     String str = "${" + entry.getKey() + "}";
-                     title = title.replace(str, entry.getValue());
-                     content = content.replace(str, entry.getValue());
-                 }
+            StringWriter stringWriter = new StringWriter();
+            Template template = null;
+            try {
+                template = new Template("SysMessageTemplate", content, freemarkerConfig);
+                template.process(map, stringWriter);
+            } catch (IOException e) {
+                e.printStackTrace();
+                return false;
+            } catch (TemplateException e) {
+                e.printStackTrace();
+                return false;
             }
+            content = stringWriter.toString();

ok

已经处理，下个版本发布

repo: zhangdaiscott/jeecg-boot


text:
cloud微服务版本什么时候发布

版本号：
2.1.2
问题描述：
请问作者大大，cloud微服务版本什么时候发布
截图&代码：
友情提示： 未按格式要求发帖，会直接删掉。

春节后吧


text:
🛑 ZY is down

In 1843686, ZY (https://ziyuan.baidu.com) was down:

HTTP code: 0
Response time: 0 ms

Resolved: ZY is back up in 8165485.

repo: zhaodylan/uptime-ziyuan


text:
🛑 ZY is down

In 2d12d5b, ZY (https://ziyuan.baidu.com) was down:

HTTP code: 0
Response time: 0 ms

Resolved: ZY is back up in 1184f7b.


text:
feat: 天翼云盘 有机会加进去吗?

概述
现在天翼云盘的市场用户也不少了，很多朋友都有十几年的云盘会员账号，如果能支持天翼云盘，就完美了。毕竟下载速度比百度好多了。

@eluotao  不会支持，因为没有官方 API，但我知道有其他项目支持了，你可以考虑使用那些项目来搭建天翼云的环境。


text:
大家别费劲接bing了，基本没法用

大家别费劲接bing了，基本没法用，正常接通回个消息要20S以上，，，，

我这边刚开始二十多秒，用了一会直接一分钟以上了，难顶

我接了一直回复网络错误。。

repo: zhayujie/bot-on-anything


text:
多次尝试，工具从openai换成claude，微信显示登陆成功，也触发关键词回复，但是不能回复信息，运行日志显示get other_user_id failed: 'NickName'

前置确认

[X] 我确认我运行的是最新版本的代码，并且安装了所需的依赖，在FAQS中也未找到类似问题。

⚠ 搜索issues中是否已存在类似问题

[X] 我已经搜索过issues和disscussions，没有跟我遇到的问题相关的issue

操作系统类型?
Windows
运行的python版本是?
python 3.10
使用的chatgpt-on-wechat版本是?
Latest Release
运行的channel类型是?
wx(个人微信, itchat)
复现步骤 🕹
先尝试openai的3.5模型，显示get other_user_id failed: 'NickName'。以为网络问题，换成claude模型，显示网络连接问题，443接口出错，设置了proxy，问题解决，再次运行，还是显示get other_user_id failed。于是在config.json里将channel_type从wx设置成itchat，显示raise RuntimeError
问题描述 😯
根据以上问题，已在群内咨询AI助手，已检查config.json配置，按照要求设置。已经采用最新的代码，对于获取用户信息的部分不知如何处理。
终端日志 📒
[INFO][2024-06-14 14:02:35][config.py:293] - [INIT] load config: {'channel_type': 'wx', 'model': 'claude', 'open_ai_api_key': '', 'claude_api_key': '', 'text_to_image': 'dall-e-2', 'voice_to_text': 'claude', 'text_to_voice': 'claude', 'proxy': 'http://127.0.0.1:7890', 'hot_reload': False, 'single_chat_prefix': ['Jeo', '方平'], 'single_chat_reply_prefix': '我在，', 'group_chat_prefix': ['@方平'], 'group_name_white_list': [], 'image_create_prefix': ['画'], 'speech_recognition': True, 'group_speech_recognition': False, 'voice_reply_voice': False, 'conversation_max_tokens': 2500, 'expires_in_seconds': 3600, 'character_desc': '你是基于大语言模型的AI智能助手，旨在回答并解决人们的任何问题，并且可以使用多种语言与人交流。', 'temperature': 0.7, 'subscribe_msg': '感谢您的关注！\n这里是AI智能助手，可以自由对话。\n支持语音对话。\n支持图片输入。\n支持图片输出，画字开头的消息将按要求创作图片。\n支持tool、角色扮演和文字冒险等丰富的插件。\n输入{trigger_prefix}#help 查看详细指令。', 'use_linkai': False, 'linkai_api_key': '***', 'linkai_app_code': ''}
[INFO][2024-06-14 14:02:35][config.py:219] - [Config] User datas file not found, ignore.
[INFO][2024-06-14 14:02:35][plugin_manager.py:50] - Loading plugins config...
[INFO][2024-06-14 14:02:35][plugin_manager.py:88] - Scaning plugins ...
[INFO][2024-06-14 14:02:35][plugin_manager.py:41] - Plugin Banwords_v1.0 registered, path=./plugins\banwords
[INFO][2024-06-14 14:02:35][plugin_manager.py:41] - Plugin BDunit_v0.1 registered, path=./plugins\bdunit
[INFO][2024-06-14 14:02:35][plugin_manager.py:41] - Plugin Dungeon_v1.0 registered, path=./plugins\dungeon
[INFO][2024-06-14 14:02:35][plugin_manager.py:41] - Plugin Finish_v1.0 registered, path=./plugins\finish
[INFO][2024-06-14 14:02:35][plugin_manager.py:41] - Plugin Godcmd_v1.0 registered, path=./plugins\godcmd
[INFO][2024-06-14 14:02:35][plugin_manager.py:41] - Plugin Hello_v0.1 registered, path=./plugins\hello
[INFO][2024-06-14 14:02:35][plugin_manager.py:41] - Plugin Keyword_v0.1 registered, path=./plugins\keyword
[INFO][2024-06-14 14:02:35][plugin_manager.py:41] - Plugin linkai_v0.1.0 registered, path=./plugins\linkai
[INFO][2024-06-14 14:02:35][plugin_manager.py:41] - Plugin Role_v1.0 registered, path=./plugins\role
[INFO][2024-06-14 14:02:35][plugin_manager.py:41] - Plugin tool_v0.5 registered, path=./plugins\tool
[INFO][2024-06-14 14:02:35][godcmd.py:194] - [Godcmd] 因未设置口令，本次的临时口令为7268。
[INFO][2024-06-14 14:02:35][godcmd.py:210] - [Godcmd] inited
[INFO][2024-06-14 14:02:35][keyword.py:40] - [keyword] {}
[INFO][2024-06-14 14:02:35][keyword.py:42] - [keyword] inited.
[INFO][2024-06-14 14:02:35][linkai.py:35] - [LinkAI] inited, config={'group_app_map': {'测试群名1': 'default', '测试群名2': 'Kv2fXJcH'}, 'midjourney': {'enabled': False, 'auto_translate': True, 'img_proxy': True, 'max_tasks': 3, 'max_tasks_per_user': 1, 'use_image_create_prefix': True}, 'summary': {'enabled': False, 'group_enabled': True, 'max_file_size': 5000, 'type': ['FILE', 'SHARING']}}
[INFO][2024-06-14 14:02:38][tool.py:28] - [tool] inited
[INFO][2024-06-14 14:02:38][role.py:69] - [Role] inited
[INFO][2024-06-14 14:02:38][dungeon.py:56] - [Dungeon] inited
[INFO][2024-06-14 14:02:38][hello.py:38] - [Hello] inited
[INFO][2024-06-14 14:02:38][finish.py:23] - [Finish] inited
[INFO][2024-06-14 14:03:01][wechat_channel.py:131] - Wechat login success, user_id: @642eefb27bebfa9aac2ebc00369d8b24c9cfc304637705540da64392bb4849e9, nickname: 🌚
[WARNING][2024-06-14 14:03:11][wechat_message.py:92] - [WX]get other_user_id failed: 'NickName'

换个微信号试试

换个微信号试试

换过微信号了，同样的bug

这个应该是陌生人发来的消息，拿不到信息，应该不影响正常好友的回复，检查配置文件，触发前缀，群白名单等看看

repo: zhayujie/chatgpt-on-wechat


text:
apply preview button layout problem

my phone is a right to left language

[ ] tell me how to fix the problem with my library fork in my app

Same issue here.
Please solve this issue..

authors: Khayrabadi adapana

repo: zhihu/Matisse


text:
🛑 腾讯云 COS 节点 is down

In 993c73d, 腾讯云 COS 节点 (https://lisz.ink) was down:

HTTP code: 0
Response time: 0 ms

Resolved: 腾讯云 COS 节点 is back up in b5f1e13.

repo: zhonger/upptime


text:
调整参数

您好！使用自定义数据集时，怎么调整top_k ， window_size 这两个参数

您好，感谢关注，您想问的是使用自定义数据集时如何找到最优的参数配置吗？如果是的话可以网格搜索，但搜索范围需要根据数据集的特性来确定。


text:
Add some example usage code to README

Also, I've bumped the dependency version in the document.
@zhyu , thanks for this project!

Thx!

authors: brain-geek zhyu

repo: zhyu/nadia