Problem with Vector2.move_toward

Godot version
3.3.2 stable official
System information
w10 64
Issue description
move_toward seems to work fine and the scale reaches its 1.4 value correctly, however the if is never true.
The value print shows "1.4" so apparently there are no decimals, however someone advises me to use "is_equal_approx" but then if it is for that approximation reason, shouldn't the decimals be shown in the text?

Steps to reproduce
run the project
Minimal reproduction project
testToward.zip

Don't trust the value print. It sometimes does a little rounding (at least in 3.3.2)
In general, with floats is_equal_approx should ALWAYS be used.

move towards should use is_equals internally

move towards should use is_equal internally

Vector2.move_toward is implemented properly:
https://github.com/godotengine/godot/blob/7610409b8a14b8499763efa76578795c755a846d/core/math/vector2.cpp#L180-L185

The problem here seems to be that floating-point number literal (like 1.4) in GDScript is being a double:
https://github.com/godotengine/godot/blob/7610409b8a14b8499763efa76578795c755a846d/modules/gdscript/gdscript_tokenizer.cpp#L957-L959
Meanwhile Vector2.x, Vector2.y are of type real_t:
https://github.com/godotengine/godot/blob/7610409b8a14b8499763efa76578795c755a846d/core/math/vector2.h#L46-L53
which can be either float or double:
https://github.com/godotengine/godot/blob/7610409b8a14b8499763efa76578795c755a846d/core/math/math_defs.h#L104-L113
and they seem to be float indeed. Surprisingly, Godot's float seems to be double no matter what (otherwise it would be as precise as Vector2.x in the snippet below):
var f: float = 1.4
var v: Vector2 = Vector2(1.4, 1.4)
print("%.20f" % [ 1.4 ]) # 1.39999999999999990000
print("%.20f" % [ f ]) # 1.39999999999999990000
print("%.20f" % [ v.x ]) # 1.39999997615814210000

So the real problem is that Vector2 claims (e.g. in the docs) that its x, y properties are of type Godot float but it's not neccesarily true. Just by looking at the docs it's perfectly valid to assume that such assert should hold:
var f: float = 1.4
assert(Vector2(f, f).x == f)

so it clearly needs to be fixed somehow.

This is not a problem with move_toward but a problem with floating point comparison in general. As kleonc shows above, the problem lies in the fact that Vector2 always uses single precision floating point while GDScript uses double precision.
While this is annoying, it isn't a bug. The solution is to use is_equal_approx when comparing floating point (or double) values. You should almost never use == on two floating point values. Even comparing two floats of the same precision is a problem, for example:
float a = 0.15 + 0.15
float b = 0.1 + 0.2
if(a == b) // can be false!
if(a >= b) // can also be false!

(Example taken from the floating point guide)

@clayjohn Floating point precision is not the problem here. The real issue is the mismatch between "declared" and "used" types. Looking at the master branch I bet the same issue is present in Vector2i (which is exposed to GDScript in there):

in GDScript int is being said to be a signed 64-bit integer,
in GDScript Vec2i.x, Vec2i.y are claimed to be int,
in C++ Vec2i.x, Vec2i.y are int32_t.

So this probably fails on master too (didn't test it):
var i: int = 1 << 32
assert(Vector2i(i, i).x == i)

and concluding that "it's a problem with integer comparison in general" would be obviously wrong.

however someone advises me to use "is_equal_approx"

Yes, you should usually use this when comparing floats.

but then if it is for that approximation reason, shouldn't the decimals be shown in the text?

Not by default, but try this (you may need to increase the "16" for small numbers):
print("%.16f" % your_value_here)

The problem here seems to be that floating-point number literal (like 1.4) in GDScript is being a double:
Meanwhile Vector2.x, Vector2.y are of type real_t:
which can be either float or double:
and they seem to be float indeed.
The real issue is the mismatch between "declared" and "used" types.

Yes, and changing / fixing this is a well-known feature request: https://github.com/godotengine/godot-proposals/issues/892
Closing because this is not a bug, it's working as intended. For vectors using doubles, see proposal 892. For float comparison, use the is_equal_approx helper method instead of == in most situations.


Package.getActivationCommands is deprecated.

All deprecated APIs will be removed on June 1st
Use activationCommands instead of activationEvents in your package.json
Commands should be grouped by selector as follows:
  "activationCommands": {
    "atom-workspace": ["foo:bar", "foo:baz"],
    "atom-text-editor": ["foo:quux"]
  }

Package.getActivationCommands (/Applications/Atom.app/Contents/Resources/app.asar/src/package.js:808:9)
Package.hasActivationCommands (/Applications/Atom.app/Contents/Resources/app.asar/src/package.js:733:20)
<unknown> (/Applications/Atom.app/Contents/Resources/app.asar/src/package.js:185:24)
Package.measure (/Applications/Atom.app/Contents/Resources/app.asar/src/package.js:163:15)
Package.load (/Applications/Atom.app/Contents/Resources/app.asar/src/package.js:177:12)
PackageManager.loadPackage (/Applications/Atom.app/Contents/Resources/app.asar/src/package-manager.js:355:14)

Oops, this was already reported


modified js files - according to new changes in popup.html

Description
added save links for bitbucket and blog.
Fixes #18
Type of change
Please delete options that are not relevant.

[x] New feature (non-breaking change which adds functionality)

How Has This Been Tested?
the fields are working I have checked them
Checklist:

[x] My code follows the style guidelines of this project
[x] I have performed a self-review of my own code
[x] My changes generate no new warnings

I am closing this pull request and making a new one as this was missing license and contributing template.


Unable to override postgres schema_name as "conductor" in conductor 3.7.3

Describe the bug
I am trying to upgrade conductor 3.7.3 version but after upgrade conductor server not starting because in this version schema as "public" is hardcoded in PostgresConfiguration which not allowing to override any other schema name like "conductor" etc.
For my project need ,I have use only different schema name thats why this issue need to fix so that I can override db schema.
Suggested Fix
I spend some time on this conductor repo to fixed the issue so that anyone can override conductor schema property but I am unable to raise PR  against tag v3.7.3 so that this fix can review and merge. Fixed present in below fork .
https://github.com/Netflix/conductor/compare/main...trivedishalini:conductor-v3.7.3
Please take a look and suggest further as I have project release coming up in next 2 weeks .
Note
Fix needed in v3.7.3  conductor tag
Details
Conductor-Server version: 3.7.3
Persistence implementation: Postgress
Queue implementation: Postgres
Postgres_schema_name: conductor
Postgres_database_name: conductor
Postgres_database_user: conductor
Lock: Redis
Workflow definition: N/A
Task definition: N/A
Event handler definition: N/A
Below Screenshots for conductor PostgresConfiguration class which have schema hardcoded as public

All,
Could you please merge this to community schema. It is impacting our production and we are not able to upgrade condcutor from 3.4 to 3.11. We are worried.
could you please merge this to community version to latest


⚠ prefetch is a production only feature ⚠

I was wondering why I couldn't see the prefetch network request.
Turns out I wasn't forwarding the property to the next router nor I was running the application in production.

best commit I've ever seen.


Compatibility with microPython to control microcontrollers with artnet

This makes stupidArtnet compatible with microPython, so it can be used to build artnet controlled microcontrollers like ESP32-based Lamps. Feedback welcome!

wow, that was fast! I'll try to reply appropriately :)

@LukeLR do you mind also rebasing master so that the tests can run?

What do I need to do for that? :)

What do I need to do for that? :)

Just git rebase origin/master
It will just add a commit to your tree that bumps the python version in CI so that the tests can run

Thanks, I'll try!

Tried the rebase, did it work?

Hi @LukeLR , asides from the thread exit, this all looks good to me.
Do you happen to know if we will need to bump the python version from 3.6?
It seems to still have a pretty high usage rate at 30%
At least according to this https://w3techs.com/technologies/history_details/pl-python/3 , unsure of the validity of this source


missing title field in ContractForOwner

[REQUIRED] Environment

Alchemy SDK version: 2.6.0

[REQUIRED] Describe the problem
There is the field title in json of response. But there is no title field inside of ContractForOwner in SDK.

@taeguk Thanks for catching this! This will go out in the next release.


Upgrade serialport dependency

Description
Latest version of Serialport does not work with this library. Not sure if serialport end or stk500v2 end or avrgirl-arduino end.
Going to investigate and fix this as soon as possible! This issue is tracking this work.

So I figured out what was going on.  It's that SerialPort.list returns a promise.  I created a fix for it on fork, but I could not fix the tests.
https://github.com/phptuts/avrgirl-arduino/blob/master/lib/connection.js#L186

Hope this helps, sorry could not fix the tests.

closing as we have upgraded to serialport 8 at this stage


Add event for mob 'feeding'

Can an event be created that is thrown when an animal consumes a bone/fish/seeds/carrot/etc whichever is appropriate to make it happy-heart particle spawn?  This is more than just an interact-entity event, as it involves consuming the correct item out of inventory, for the mob which must be adult and not  during the post-coitus/breeding.
Basically, whatever condition results in spawning the heart particles, throw the event there.

What is the status of this issue?


Improve library documentation

Re-opening the PR since I accidentally deleted the old branch by renaming it.
The PR will,

Fix minor grammatical errors.
Capitalize terms such as Commands, Modules and such, as the context is specific to the lib.
Wrap methods and properties in code blocks.
Fix broken samples and cross-reference links.
Clarify ambiguous terms or lines.

The current documentation suffers from several minor issues here and there; the PR aims to improve upon sections of the docs and add clarifications to ambiguous parts of the docs.
Below are several issues that remain to be fixed or need to be clarified.
Migration from 0.9
Sidebar linking doesn't work at all. Should we remove it altogether or fix it?
Getting Started
Installation

Should UDPClient still be referenced in installation?

Your First Bot

Connection logic is incomplete as of the current build. Events will soon be added to indicate when the client's state is ready for use (rewrite this section when possible).

Referring to the Ready event?
Update: Removed in 95935de.

Handling a 'ping'...

Perhaps we should put a warning or info tooltip here telling the users that if they want to create a command, they should use CommandService?
Update: Added in b68528b.
Command Service

This article is out of date and has not been rewritten yet.
Information is not guaranteed to be accurate.

The docs doesn't necessarily seem "out of date" as the warning claims. The basics seem pretty relevant to the latest version of the lib. This warning turns off newcomers, as they might think that the official guide is unusable because of it being "outdated."
Update: Removed in f89aecb7.

“To manually load a module, invoke [CommandService.AddModuleAsync], by passing in the generic type of your module and optionally, a dependency map.”

The latter part of the sentence seems unclear. Where should the user pass the dependency map to?

“First, you need to create an @System.IServiceProvider You may create your own IServiceProvider if you wish.”

Any mention of @System.IServiceProvider are currently broken on the docs.

“Submodules are Modules that reside within another one. Typically, submodules are used to create nested groups (although not required to create nested groups).”

Clarification on the part after "although?"

“Finally, pass the map into the LoadAssembly method. Your modules will automatically be loaded with this dependency map.”

Where is this LoadAssembly method?

Preconditions can be applied to Modules, Groups, or Commands.

The docs should mention ParameterPreconditionAttribute's existence.
Update: Resolved in 4449a05.

- >Preconditions can be applied to Modules, Groups, or Commands.
+ >There are two types of Preconditions. [PreconditionAttribute] can be applied to Modules, Groups, or Commands; [ParameterPreconditionAttribute] can be applied to Parameters.

- To write your own precondition, create a new class that inherits from @Discord.Commands.PreconditionAttribute.
+ To write your own Precondition, create a new class that inherits from either [PreconditionAttribute] or [ParameterPreconditionAttribute] depending on your use.

- In order for your precondition to function, you will need to override the [CheckPermissions] method.
+ In order for your Precondition to function, you will need to override the [CheckPermissions] method.

I propose this change to fix mention the use of ParameterPreconditionAttribute.

Should we break out async Main across all sample codes? @AntiTcb suggested that one of the samples should use async Main like static Task Main(string[] args) => new Program().StartAsync();. At the moment there are 8 other files that still use static void Main.

I'd prefer it as it means exceptions will be displayed normally instead of just being bubbled up to GetAwaiter().GetResult() and needing to explain that and how to enable breaking on all CLR exceptions.
Fair point though, C#7.1 features are still off by default in VS projects currently.

I propose this change to mention the use of ParameterPreconditionAttribute.

I would say to not wrap the class names in brackets when also adding the Attribute part of it.

Oops, that's definitely an oversight on my part. Will fix. @Joe4evr

There are still several issues that remain to be fixed with the docs that require some discussion. I wasn't expecting the PR to be merged already.

For future reference, you should denote that in the PR, to prevent this.


feat(api): Return 404 for invalid table names

This PR enhances the API's error handling by returning a 404 Not Found error when user requests a table that doesn't exist. This provides a clearer and more informative response compared to the previous 500 error, improving the overall user experience and making it easier to debug API requests.

Sorry, I mischecked it, closing this PR, I'll provide appropriate changes in new PR


Migrate from AWS PostgreSQL 12.5 version to Azure PostgreSQL 11

As per the pre-requisites: The target Azure Database for PostgreSQL version must be equal to or later than the RDS PostgreSQL version. One of my customers has a AWS PostgreSQL version 12.5 and they want to migrate to Azure where the max version supported is 11 in Single Server mode. Please advise how to migrate in the above scenario
Can you also share an ETA when would the version 12 would be GA'd in Azure PostgreSQL?
Thanks,
--Mayur

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

ID: 258e62a7-a977-1cdf-7dbf-b94ab034e918
Version Independent ID: 509124d0-7f20-3a1e-237e-d6d047d096a4
Content: Tutorial: Migrate RDS PostgreSQL online to Azure Database for PostgreSQL - Azure Database Migration Service
Content Source: articles/dms/tutorial-rds-postgresql-server-azure-db-for-postgresql-online.md
Service: dms
GitHub Login: @arunkumarthiags
Microsoft Alias: arthiaga

@mayurpuli We are looking into this and will get back to you.


az interactive fails on OSX CLI

This is autogenerated. Please review and update as needed.
Describe the bug
Command Name
az interactive
Errors:
No module named 'prompt_toolkit.interface'
Traceback (most recent call last):
python3.7/site-packages/knack/cli.py, ln 206, in invoke
    cmd_result = self.invocation.execute(args)
cli/core/commands/__init__.py, ln 603, in execute
    raise ex
cli/core/commands/__init__.py, ln 661, in _run_jobs_serially
    results.append(self._run_job(expanded_arg, cmd_copy))
cli/core/commands/__init__.py, ln 654, in _run_job
    six.reraise(*sys.exc_info())
...
cli/command_modules/interactive/custom.py, ln 41, in start_shell
    azext_interactive.start_shell(cmd, style=style)
cliextensions/interactive/azext_interactive/__init__.py, ln 10, in start_shell
    from .azclishell.app import AzInteractiveShell
interactive/azext_interactive/azclishell/app.py, ln 27, in <module>
    from prompt_toolkit.interface import Application, CommandLineInterface
ModuleNotFoundError: No module named 'prompt_toolkit.interface'

To Reproduce:
Steps to reproduce the behavior. Note that argument values have been redacted, as they may contain sensitive information.

Put any pre-requisite steps here...
az interactive

Expected Behavior
Environment Summary
Darwin-18.6.0-x86_64-i386-64bit
Python 3.7.4
Shell: bash

azure-cli 2.0.70

Extensions:
interactive 0.4.3

Additional Context

Also failing from cloud shell with the same error (version azure-cli 2.0.70)

dupe of #10088, which has the workaround you can use till Aug 13


Container Duplication Networkselection gets appended instead of replaced

Description
If you try to recreate or duplicate a container and select another bridge Network (not sure if this only happens for bridge-networks) the selected network will be appended instead of replaced
Steps to reproduce the issue:

Create a new bridge Network
Open an existing container attached to a Bridge
Select Duplicate/Edit
Under Network select the newly created Bridge
Creation will fail because container can only be attached to one bridge

Technical details:

Portainer version:  1.14.3
Target Docker version (the host/cluster you manage):  17.09.0-ce, build afdb6d4
Platform (windows/linux): Centos7
Command used to start Portainer (docker run -p 9000:9000 portainer/portainer):   docker run -d -p 9000:9000 --restart always -v /var/run/docker.sock:/var/run/docker.sock -v /opt/portainer:/data portainer/portainer
Target Swarm version (if applicable):
Browser: Chrome 61.0.3163.100

Hey @vidschofelix
Thanks for the report, I was able to reproduce this.


Support MySQL RAND and SIGN function.

What would you like to be added:
Why is this needed:
official document:
https://dev.mysql.com/doc/refman/5.6/en/mathematical-functions.html#function_rand
https://dev.mysql.com/doc/refman/5.6/en/mathematical-functions.html#function_sign
reference code:
https://github.com/arana-db/arana/tree/master/pkg/runtime/function2/abs.go

@BuYu-Wang

ref #454


style prop must be an object

I was using the boilerplate available for debugging purpose provided in this package. when I did
npm start
compiled with warnings.
Line 20: Style prop must be an object   react/style-prop-object

The map loads fine but why is this warning is shown?

@alex3165 What if this were a change in v4? Since airbnb's eslint config is pretty popular and is on that tells you not to use strings for the style prop, what if we changed it so that style were the container style, and mapStyle were the style for the map?
That might be a bit confusing for anyone upgrading to v4 though, so maybe even just disable the style prop altogether and warn users that it's now called mapStyle.

Ok, I would go for:

mapStyle: for mapbox style
style: for container style.

In v4 branch and explain this correctly in a breaking changes section for the v4 release.
PR against v4 branch welcome 👍

If no one has got a PR for this yet, I can make one.

@arunstan there was some confusion at one point - since this was a breaking change it went into a v4 branch, but those changes got lost when v4 was actually released. This would still be a breaking change so I think it would need to go into v5, but not sure the best way to coordinate that this time.
I would imagine there would be some conflicts with pulling in the same code, but if you wanted to make a new PR you could use https://github.com/alex3165/react-mapbox-gl/pull/533 as a reference.

Thanks for your reply @redbmk I would try to come up with for PR for v5 based on #533


weave launch and weave connect should result in same init-peer-count

weave launch host1 host2 host3... hostn

should result in the same init-peer-count as
weave launch host1
weave connect host2
weave connect host3 ... hostn

i.e. the peer count for consensus should be based on the number of direct targets at the time the consensus is initiated.
This behaviour is less surprising than the current one, making the creation of a network with weave launch and weave connect equivalent, provided no IP address allocation occurs before all connects have been issued.
We should also consider reducing the init-peer-count of any pending consensus when weave disconnect is invoked.

To be clear, all this should only apply in the absence of a specified --init-peer-count.

This looks relatively straightforward. The condition to check in the allocator for whether it's safe (i.e. not too late) to update the quorum is !paxosActive && paxos != nil.


CommonJS Support (with refactored internals)

I've always wanted to express internal dependencies in a more formal way while
preserving the ability to test the source files directly (i.e. no build step,
no testing built files). AMD was the clear choice here, but at the time, it was
difficult to package library code that used define without running into
problems when consumer code also used AMD.
@tbranyen and I made a few good runs at a solution, but we never finalized a
tool that we felt was production-ready. In the time since, the Webpack project
has been released with support for exactly this use case.
A nice side-effect is that we get CommonJS support (previously proposed in
gh-110) for free.
At first, I thought this change would require a minor version increase, but I'm
not so sure of that anymore. There are a couple minor differences for
developers consuming d3.chart from AMD-enabled environments, but neither can
really be considered "breaking":

Previously, the AMD "shim" config was necessary to properly load d3.chart.
This patch makes existing configurations superfluous.
Previously, the library did not export a value. This patch exports the more
useful function attached to the d3 API as d3.chart.

...but it's been so long since our last minor release, it might be best to play
it safe and publish this as 0.3.0. @tbranyen: if you have a minute, could you
let me know if that sounds right to you?
I've split this work into two separate commits: the first refactors internals,
and the second tests CommonJS support. I'm hoping this will help with code
review because testing CommonJS support was not trivial, so a distinct commit
more clearly delineates my efforts towards those ends.
As always, I'd love from feedback from any of the project's consumers. In this
case, I'm particularly interested in respondents to gh-113. @JMStewart,
@nicksrandall, @aharris88, @wvengen: Does this look good to you folks?

Thanks! Looking good at first glance. Using the exported value (instead of d3.chart) feels more natural. I'll start testing it in a real-world project in the next week.

I think it would be a good idea to include an example for a depending chart (like a barchart module based on d3.chart). With webpack, I had to declare my dependencies something like this (haven't  tested all types yet):
// webpack.config.js
// ...
module.exports = {
  // ...
  externals: {
    'd3': true,
    'd3.chart': {
      'root': ['d3', 'chart'],
      'commonjs': ['d3', 'chart'],
      'commonjs2': ['d3', 'chart'],
      'amd': 'd3.chart'
     }
  }
};

@wvengen Thanks for kicking the tires here!
While I'm happy to include general usage guidelines for AMD and CommonJS, I'm reluctant to document usage for specific tools. There are a lot of module loaders out there, and I want to avoid having to make subjective decisions about which ones need documentation. More than that, I don't want to be in a situation where d3.chart's documentation of another tool falls out-of-date. If d3.chart exposes a package that conforms to the (semi) standards, then I think it's fair to expect consumers to refer to the documentation of their module loader of choice.
That said, the configuration you've shared seems kind of heavy for such a fundamental use case. I'm not very experienced with Webpack, though; can you advise if there is anything we could change about this patch to make d3.chart more readily consumable with that tool?

This looks pretty good to me. I pulled it into some of my projects and it is working great. I like having the exported value for creating new charts, as @wvengen showed above. I played around with this a bit, and found I can also instantiate a chart like this:
var d3 = require('d3');
var Chart = require('d3.chart');
var MyChart = require('MyChart');

var g = d3.select('svg')
  .append('g');

var myChart = new MyChart(g);

As for the webpack configuration, the only thing making it complicated is that d3.chart attaches itself to d3, and doesn't create it's own global variable on the root when pulled in without a loader. I think the only way to make it simpler would be to add a global variable when not used with a loader, although it would still have to be the same as the CommonJS and AMD name. So in this case you would probably have to add a 'd3.chart' global to the window, which is possible, but super weird. The only was to access it would be window['d3.chart']  so I really don't think it would make sense to do it. My opinion is that the way it is now is fine, and actually just requires the same amount of configuration as libraries like lodash and underscore.

@jugglinmike sounds good; not being too familiar with webpack exports configuration, it took me quite a while to figure out what to use exactly. Some general pointers like you suggest are fine.
This webpack definition is for chart libraries depending on webpack. Apps generally use just a single loading type, so should be fine with either d3.chart or ['d3', 'chart']. I think (not being too familiar with webpack either). @JMStewart sums it up quite nicely, I think. I have no better ideas.
:+1: for using creating charts using a chart's require value MyChart(g).

I'm afraid there's still a problem with defining new charts in this way. I've put together a basic example that shows the error at https://gist.github.com/wvengen/5789e5b2a295156ea48e.
Error: TypeError: selection.layer is not a function
Defined in: layer-extensions.js
That's because we're using d3 without d3.chart to get the element.

@wvengen It took me quite a while, but I finally figured out what was happening in your gist. The problem was that when you built d3.chart you installed it's dependencies, including d3. This resulted in your final webpack build including 2 copies of d3, with d3.chart only attached to one of them. Here's my fork of your gist with a couple changes, and it is working great for me. https://gist.github.com/JMStewart/3bc33e9c455581cf0f57

Bravo, @JMStewart! The "build d3.chart yourself" step will go away when we release the next version and re-build the d3.chart.js file located in the root of the project.
As for removing node_modules, I'm not sure why this is necessary. This project does not specify any "production" dependencies of its own, so npm install npm install d3.chart@git://github.com/jugglinmike/d3.chart#amd-3 (or one day, just npm install d3.chart) should produce

...a node_modules/d3.chart/ directory without a node_modules/ directory of its own. Can you share how you are installing d3.chart? And maybe also the version npm you are using?

Yeah everything should work fine when this goes to production and we don't have to run the build step. npm install d3.chart will produce exactly what you describe, without a node_modules/d3.chart/node_modules/ folder. @wvengen's gist had this line to build d3.chart: cd node_modules/d3.chart && npm install && grunt build && cd - which installed all dev dependencies, including d3, into the local node_modules folder. I just changed that line to cd node_modules/d3.chart && npm install && grunt build && rm -rf node_modules && cd - to clean up after the build.

Ah, got it.

That was tricky. Thanks, @JMStewart, for tackling it!

I really like the direction this is going. One small question, if we're using Webpack to bunlde d3.chart as a UMD module, is there a reason we're not setting the "output.library" and "output.umdNamedDefine" settings?

@nicksrandall sounds like a good idea, I suppose something like this in webpack.config.js:
output: {
    libraryTarget: "umd",
    library: "d3.chart",
    umdNamedDefine: true
}

right?

@wvengen Yes. This comes down to preference but I would set the libarary property as d3_chart so that it could be used as a global without having to access it like window['d3.chart'] as @JMStewart mentioned above. It's not a huge issue because most people won't use it that way.
FWIW, D3 v4's modules are following a similar pattern. For example,  d3-shape module exports a d3_shape variable to the global scope. https://github.com/d3/d3-shape#installing

Thanks for explaining! @jugglinmike would you care to add this? And perhaps then it's close to being ready for merging?

Thanks for the feedback, you two! I think those changes make sense. I'm not opposed to renaming the browser global to d3_chart, either. The fact that it matches a convention in the up-and-coming major release of D3.js is nice, but I'm reluctant to put too much confidence in that convention until version 4 is officially released. I think the argument against window['d3.chart'] is more compelling. I very much want to promote the use of a module system, but I don't want to needlessly punish those using browser globals, either. (Though the exported value in those contexts is less important because d3 will be defined globally, making the "traditional" d3.chart the easiest choice.)
This is an straightforward change, but I'm a little swamped at the moment. I'll try to report back by this coming Friday.

:+1: thanks!

Alrighty. I've pushed up a few changes. This differs a bit from what I planned
on in that the browser global is exposed as window["d3.chart"]. As far as I
can tell, WebPack does not expose dedicated configuration values for a
package's name as an AMD module and its name as a browser global. Although
require("d3_chart") isn't as awkward as window["d3.chart"], I think using
d3_chart in AMD is sufficiently confusing to warrant the unfortunate window
property name. So this may be a "punishment" for users relying on global
variables, the "needlessly" part of my first statement doesn't apply.
We could resolve this with a patch to Webpack itself, but I think there's
good reason to keep names consistent. And remember: the preferred reference in
those contexts, d3.chart, is ergonomic.
Seem fair to you folks?

Great! I don't really mind the browser global name, and see both being used. I'd be happy with this. We can always add a d3_chart export when this settles in with d3js v4 (the other way around is less smooth).
I've tested 35cc230 with the gist and d3.chart.sankey succesfully.

Sounds good to me! I don't think think the global name is important enough to really worry about it.

Looks good to me and window["d3.chart"] seems fine to me. I'm excited to see this in a release soon! @jugglinmike Thanks for working on this!

Sounds good to me! @jugglinmike when can we expect you to cut a release? Thanks again for you help on this.

I just spoke with @iros about this, and she spotted some tweaks that I looked over. You can review the most recent commits in this pull request if you're curious, but basically:

Update source code indentation to respect the AMD factory function
Remove the hasOwnProp module in favor of accessing the built-in directly
Update the project's readme.md file to document the newly-supported usage scenarios

I think these improvements are pretty non-controversial, but I'm still loathe to publish anything late at night. I'll be rebasing, merging, and releasing by Saturday (barring any objection from you folks).
Thanks for sticking with me!

+1 to merge!

No objections from me. Thanks!

Looks good to me.

Alrighty: I've squashed these changes, merged them to master, tagged a new release (updating the changelog and migration guide as well), and published to npm.
Thanks for the help, everybody!

Works like a charm. Thanks!!

:clap: nice work!


SIMSBIOHUB-587 API: Bulk Captures

Links to Jira Tickets

SIMSBIOHUB-587

Description of Changes (only backend)

Bulk import Critterbase captures via CSV
importCSV strategy function
updated columnValidator spec
import services now implement shared interface (to be injected into importCSV)
column validator now handles optional properties

Testing Notes

Should be able to import capture CSV file with postman

Regarding the csvFileSchema allowed mime types enum [text/csv]:
I'm encountering an interesting issue, where the mime type, despite the extension being .csv, is parsed as application/vnd.ms-excel.
This blog post actually mentions the same issue: https://christianwood.net/posts/csv-file-upload-validation/
Their conclusion that they just have to add more mime types to the allowed list.
The issue doesn't seem to happen through postman.

Regarding the csvFileSchema allowed mime types enum [text/csv]:
I'm encountering an interesting issue, where the mime type, despite the extension being .csv, is parsed as application/vnd.ms-excel.
This blog post actually mentions the same issue: https://christianwood.net/posts/csv-file-upload-validation/
Their conclusion that they just have to add more mime types to the allowed list.
The issue doesn't seem to happen through postman.
(Everything else downstream works, I just had to add that extra mime type to the openapi schema)

I have updated the file schema to include all of these. I can remove some if we think they are not needed.


Improve performance of List.foldr

This PR takes the same idea presented in #707 and applies it to List.foldr. I see performance improvements of 30-40% on my machine (Safari and Chrome). Since foldr is used by many other list functions, this gives a nice performance boost across the board.
I tested each level of "unrollment" individually. 9 seemed to be the magic number.
I tried the same thing with foldl. It gave a modest improvement in Chrome (8-10%), but reduced performance in Safari (10-14%).
I have not tested if #707 still provides a performance improvement over a map fn using this foldr implementation.

Two questions:

Instead of having branches for every single scenario, what if you only had 0, 1, and 9? Or 0, 1, 2, 4, 8? Or some other pattern for reducing the number of branches? How much does that reduce the size of generated code? How much perf does it cost?

Can you use f a (f b (f c ...)) instead of using |>? No reason to require a compiler optimization to trigger if we do not need to.

Won't compile without branches for every single scenario.
Sure
Not only did nested case-statements reduce generated code size with about 550 bytes (2500bytes -> 1950bytes). It also increased performance. We're now in the 40-45% range of performance improvements (Chrome & Safari). Good call :)

Another interesting thing, for future reference, is that I consistently get 50+% performance improvement when inlining the ctr > 500 line in the compiled code. By that I mean changing the compiled code from ...Util.cmp(ctr, 500) > 0 -> ctr > 500.

Neat! I want to do some thinking about whether this has implications on how pattern matching code is generated.
About it not compiling, you need to change it from a :: b :: [] to a :: b :: _ and do a recursive call.
Can you share the code that is doing the performance comparison? I would like to run it myself and see the numbers. With that ability, I can take a look at this on my own in the next few days.
And yeah, this is one of the first optimizations we can do if type information is kept all the way until code generation. Swapping in === and < for String, Int, etc. will surely make things faster.

Sure: https://github.com/Skinney/elm-list-exploration

I merged it in, but it did not register here for some reason.
I ended up reducing the unrolling to 4 to make things a bit smaller without huge perf losses. Not sure if it's the right trade, but it seemed like a reasonable compromise.
Anyway, thanks for looking into this!


Fix image issues

Allow insert image in empty block such as "note" and "blockquote"
Fix delete image priority issue in "note" and "blockquote"

@pftom God of re-arranging.


python311Packages.boschshcpy: 0.2.65 -> 0.2.66

Diff: https://github.com/tschamm/boschshcpy/compare/0.2.65...0.2.66
Description of changes

Things done

Built on platform(s)

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

[ ] For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
[ ] Tested, as applicable:

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

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

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

[ ] Fits CONTRIBUTING.md.

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

5 packages built:

home-assistant-component-tests.bosch_shc
python310Packages.boschshcpy
python310Packages.boschshcpy.dist
python311Packages.boschshcpy
python311Packages.boschshcpy.dist


Swift 2.3 conversion

Update project settings and convert syntax.

Never mind. I hadn't noticed that master is compatible already. 😶


Removing reaction removes you from mass party

🚀 Feature Proposal
When removing the 'join' reaction on an upcoming mass party it should remove you from the members who have entered.
Sometimes you want to join a different one or change your mind entirely.
That being said, some measures may need to be put in place to prevent griefing.

Existing functionality, must have missed it due to spam-prevention.


Allow customizing Button type

Also: Button should use InteractiveViewStyleSheet
Fixes #98
Add a type to the Button component and allow this to be configured by the user. This allows using the .custom type, which is the only way to customize the button highlighted background colour without having a system fade applied.
This was the actual cause of #98, not the incorrect style sheet type, but I fixed that also, just to be correct.

@andersio comments addressed.

Comments addressed @andersio


Async payment cancellation

Related to https://github.com/lightningnetwork/lnd/issues/4518
After we made the payment lifecycle reliable (https://github.com/lightningnetwork/lnd/pull/2761) a natural follow-up was to introduce a cancel payment API for payments. This would let a payment be attempted with a very high payment timeout, and pathfinding would run in the background until canceled, failure or success.
What needs to be done is to signal the payment lifecycle that the payment should be canceled, and handle this signal here with a new failure reason (could also reuse the timeout one): https://github.com/lightningnetwork/lnd/blob/cc37485432741194c7f59320d4807af03d9e4698/routing/payment_lifecycle.go#L189

Bumping this issue as this can be helpful to fix the stuck payment issue.


How can i download a file over cell tcp socket

I want to download a file for Over The Air Update (OTA) over TCP socket.
e.g. http://xxx.xxx.xxx.x:8100/file.md
Is there an example?

Is it like this?
const char socket_message[] = "GET /esp.bin HTTP/1.0\r\n"
uSockSendTo(sock, &address, socket_message, sizeof(socket_message));

Hi Alex: we've just pushed HTTP support here, which uses the HTTP client in the module to do all the work.  You can see an example of how to use it here and the full API is in u_http_client.h.
Otherwise, if you want to do it directly yourself by forming the correct string having opened a TCP socket connection to the server, then yes you want something like that, see maybe this Stack Overflow question as a good example.

have now first switched to v4.4.
I'll deal with that later.
I have to take care of another problem now.
https://github.com/u-blox/ubxlib/issues/60

Closing this one: please re-open if necessary.


Create NPC Objects / Generic Lovelace Students x1-4

Spritesheets and art already exist for these students, but they are not yet objects in Base.
NPC Images & Spritesheets

1-4 generic students
And Heads of Houses for Lovelace, von Neumann, and Hopper

All Lovelace students and heads of houses have been added to the object tileset and objects folder in base.


Sample error

This is an extremely interesting concept and a really encouraging implementation.  So thanks.
Both when I build then run the samples project vs2017 Windows 10P, and when I follow the steps in the intro demo, I get the following error posted every 5 seconds:
http://*:8080/ error: Access is denied. Trying again in 5 seconds...
I thought this might be something simple you see often so I should ask.
Thank you.
P.S. It seems that the Navigation Bug listed in issues would be really important as proof of concept, since without internal navigation it's reduced to a one page demo not perhaps really selling the concept for typical web development.

Make sure it is running as administrator.

Gosh Windows blocks everything. :-( Sorry, you'll have to ask clippy how to enable networking in apps.
Also you could try a different port that perhaps Windows would allow.
Yep yep I hear you about Navigation! It keeps me awake at nights :-) I believe I have a couple solutions - I just need to test them to find out which is best.

Is there a better way than running as administrator?


Update everything to ES6 and adopt a code style

This PR is a big one, it changes pretty much all of the JavaScript files, since it updates everything to ES6, plus adopts airbnb/javascript as a code style (with a few tweaks, like using require instead of ES6 modules).
Done so far:

[x] js/*.js
[x] js/component

[x] js/component/dns-client

[x] js/core

[x] js/core/*.js
[x] js/core/debug
[x] js/core/keyboard
[x] js/core/net
[x] js/core/pci
[x] js/core/ps2
[x] js/core/random
[x] js/core/stdio
[x] js/core/tty

[x] js/driver

[x] js/driver/ps2
[x] js/driver/virtio

[x] js/driver/virtio/vring
[x] js/driver/virtio/*.js

[x] js/modules
[x] js/service

[x] js/service/dhcp-client
[x] js/service/dns-resolver
[x] js/service/shell

[x] js/test

[x] js/test/unit

[x] js/test/unit/buffers
[x] js/test/unit/lib
[x] js/test/unit/net
[x] js/test/unit/platform
[x] js/test/unit/random
[x] js/test/unit/script
[x] js/test/unit/timers
[x] js/test/unit/virtio

[x] js/utils

Good buy commit history :)

Also added guidelines for contributing, plus a list of exceptions to Airbnb's style guide.

How do we update runtime with npm.

This is done and ready for review/merge, the only thing I'm not really confident about is the CONTRIBUTING.md. I've got some more node compatibility fixes, but I'd prefer to add them in another PR after this has been merged to avoid any conflicts.

This is awesome, I'll do some tests too, to make sure everything works.

Ok, I've update the code to only use arrow functions for property functions and callbacks and function declarations for everything else, I've run the code through a beautifier, removed the newlines in js/__loader.js, used spaces instead of newlines in js/core/pci/scan.js, readded eslint-plugin-runtime-internal, disabled no-use-before-define for functions, and fixed the other issues you mentioned.

Convert IIFE functions to arrow functions, and fixed the minor style issues. Sorry, most of these little things are because of the beautifier I ran it through.

@facekapow left couple of places where there are a few statements on the single line.

@iefserge Well, that's the last time I use a beautifier 😄

LGTM
great work 👍

wow. Amazing.

Great, then I'll just do a quick once-over on the code and merge.

Everything looks ok, I tried to run the JS tests, but those are definitely broken (more specifically, tape kept complaining about Stream), but I did some manual feature testing and everything looks fine. Merge?

bye-bye diff :)

@facekapow yeah, I've been looking into tests issue, should be fine, going to fix it afterwards.
@vitkarpov yeah, but consistent and nice code style is good :)


Provide means to utilize the entire 16-byte string

It is unexpected that the current set of functions is unable to utilize the type in its entirety.
One solution would be to allow extracting timestamptz alongside with the remainder of 100ns intervals:
uuid_v1_get_timestamptz_ex(in u uuid, out t timestamptz, out gns int2) where gns is the number of remaining 100ns intervals that didn't make it into the timestamp.
Accordingly, the uuid_v1_create_from function must be enhanced to accept gns as an argument.
Naming is a subject to change.

Alternatively one could return an int64 instead of the timestamp. Since the timestamp encoded within UUID v1 is only 60bits, it fits safely inside the pg's int8 SQL type. This further enables the user to use various strategies to populate these fields, including using a sequence.


The diff coverage is 0.00%.

@@            Coverage Diff             @@
##           master     #679      +/-   ##
==========================================
- Coverage   81.36%   81.20%   -0.16%
==========================================
  Files         100      100
  Lines        8423     8439      +16
==========================================
  Hits         6853     6853
- Misses       1570     1586      +16

Impacted Files
Coverage Δ

crates/cli/src/args.rs
0.00% <0.00%> (ø)

crates/cli/src/context.rs
0.00% <0.00%> (ø)

crates/cli/src/main.rs
0.00% <0.00%> (ø)

:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more


Update @bazel_toolchains to v3.2.0

#61 fixes the (unrelated) linter errors.

(added the archive to bazel-mirror, and realized I cannot approve here anymore :)

https://github.com/bazelbuild/rules_proto/pull/64

Closing in favor of #64. Thanks @keith!


Flesh out the std::sync::Arc mock implementation

This PR adds the following APIs to loom::sync::Arc<T>:

Arc::ptr_eq
Arc::strong_count
Default
From<T>

It also adds some basic docs (the current docs just say "TODO").
Unresolved questions:

Should we add support for weak refcounting?
Should we add some tests for this Arc?
How do we implement the methods that std uses fences for (try_unwrap etc.)?

Hm, seems a CI build got lost, there's nothing for me to "restart" it. Could you force push to trigger CI again?

I triggered CI again, but it still gets stuck. I believe this is an instance of [travis-ci/#10204]](https://github.com/travis-ci/travis-ci/issues/10204), as #12 is stuck at the same check.

Fun fun... we should migrate to azure pipelines.

I tried restarting travis. If that doesn't work, I will force the merge.


Watchdog does not kill and idle sentencetransformer backend

Environment, Container Image, Hardware
LocalAI version: 2.14.0
Container Image:  	localai/localai:v2.14.0-cublas-cuda12-ffmpeg
nvidia CUDA 12, intel x86_64, Ubuntu 22.04 LTS.
Linux makinota08 6.5.0-28-generic 29~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Thu Apr  4 14:39:20 UTC 2 x86_64 x86_64 x86_64 GNU/Linux
16G RAM, Nvidia 1660Ti 6G, Acer Nitro Laptop
Describe the bug
I have localAI deployed in a docker container. I load a sentence transformer embeddings model, and test it succesfully using curl. Then I wait for 5 minutes, and check in the log that the watchdog tries to kill the process. The log shows that the process is succesfully killed, it no longer detects the idle connection.
However, if I issue a nvidia-smi, I can see the python process stuck and loaded into the memory of the GPU.
+---------------------------------------------------------------------------------------+
| NVIDIA-SMI 545.29.06              Driver Version: 545.29.06    CUDA Version: 12.3     |
|-----------------------------------------+----------------------+----------------------+
| GPU  Name                 Persistence-M | Bus-Id        Disp.A | Volatile Uncorr. ECC |
| Fan  Temp   Perf          Pwr:Usage/Cap |         Memory-Usage | GPU-Util  Compute M. |
|                                         |                      |               MIG M. |
|=========================================+======================+======================|
|   0  NVIDIA GeForce GTX 1660 Ti     Off | 00000000:01:00.0 Off |                  N/A |
| N/A   45C    P8               3W /  80W |   2268MiB /  6144MiB |      0%      Default |
|                                         |                      |                  N/A |
+-----------------------------------------+----------------------+----------------------+
+---------------------------------------------------------------------------------------+
| Processes:                                                                            |
|  GPU   GI   CI        PID   Type   Process name                            GPU Memory |
|        ID   ID                                                             Usage      |
|=======================================================================================|
|    0   N/A  N/A      5574      G   /usr/lib/xorg/Xorg                            4MiB |
|    0   N/A  N/A     25660      C   python                                     2260MiB |
+---------------------------------------------------------------------------------------+
also, with ps -fe you can see the process still there:
root       25660   24649  0 11:33 pts/0    00:00:09 python /build/backend/python/sentencetransformers/sentencetransformers.py --addr <IP_ADDRESS>:39807
To Reproduce
Activate Watchdog using ENV variables.
WATCHDOG_BUSY | true
WATCHDOG_BUSY_TIMEOUT | 30m
WATCHDOG_IDLE | true
WATCHDOG_IDLE_TIMEOUT | 5m
Test sentencetransformers model with the following yaml config:
name: e5-large
backend: sentencetransformers
embeddings: true
parameters:
model: intfloat/multilingual-e5-large
context_size: 1024
Wait for 5 minutes.
Expected behavior
The sentencetransformers backend should have been killed by the watchdog after 5 minutes, so the GPU memory is cleared.
Logs
test of embeddings model.txt

I have tested as well the watchdog with a chat model ('mistral-openorca') and it works fine, the process is cleared after 5 minutes.

same issue when use vllm backend


update to use TLSv1.2

cloudant will not allow TLS 1 connections any more

Forgive me for asking a non-TLS question on this PR, but is the Ektorp project still active? Last commit seems to be Nov 2017; last PR was accepted late 2018.

Hi @seanlaval could you please explain why you think this is necessary?
TLS 1.2 is enabled by default in Oracle JDK 8 since b122 (March 2014)
So you should have TLS 1.2 enabled already.

@chrisinmtown The project is not in active development, meaning no big change is expected to be merged, but PR on existing features may be merged when necessary. It turns out that most PR are not strictly necessary. Also you can extend or replace most of the component by your own for specific needs.

@YannRobert it seems that the problem we saw might be due to using IBM java which has different default behaviour to Oracle java wrt Default SSL Context .. see https://www.ibm.com/support/knowledgecenter/en/SSYKE2_8.0.0/com.ibm.java.security.component.80.doc/security-component/jsse2Docs/matchsslcontext_tls.html


charry-pick support text hive

Proposed changes
pick from master:
https://github.com/apache/doris/pull/40315
https://github.com/apache/doris/pull/40291
https://github.com/apache/doris/pull/40183
https://github.com/apache/doris/pull/38549

run buildall


Why self.condition_mean is put after self.q_sample during training?

The IK guidance during generation process is clear.
But I'm confused why the training process is like below:
x_t = self.q_sample(x_start, t, noise=noise)
x_t = self.condition_mean_bfgs(x_t, num_condition)
Could you explain why you put self.condition_mean_bfgs here?
Is that a theoretical approach or empirical approach?
Wait for your reply. Thanks

It is an empirical approach. It is the implementation of the formula of $\mu$ (posterior) in equation (2) of our paper. If we remove this, it is the implementation of $x_0$ (clean motion).


Proposal: Suport createSelector

Create hooks for calculated store values:
Example:
const usePriceWithIva = createSelector(
  () => useStore.cart.price,
  (val) => val + (val * 0.21)
);

The val + (val * 0.21) calc only will be executed once for all the components that use the usePriceWithIva(); hook. It only will be calculated again when cart.price change and is going to do a rerender for all these components that use this hook.
For this simple calculation, it does not make any sense to use the createSelector, but it can be useful for very complex calculations.
And is also possible to do the same with helpers:
const getPriceWithIva = createSelector(
  () => getStore.cart.price,
  (val) => val + (val * 0.21)
);

Example of complete example:
import createStore from "teaful";
import createSelector from "teaful/createSelector";

const initialState = {
  username: "Aral",
  age: 31,
  cart: {
    price: 3,
    items: []
  }
};

export const { useStore, getStore, withStore } = createStore(initialState);

const usePriceWithIva = createSelector(
  () => useStore.cart.price,
  (val) => val + (val * 0.21)
);

export default function CartPriceWithIva() {
  const price = usePriceWithIva();
  const price2 = usePriceWithIva();
  const price3 = usePriceWithIva();
  const price4 = usePriceWithIva();
  const price5 = usePriceWithIva();

  return (

{price}

{price2}

{price3}

{price4}

{price5}

  );
}

And an example of createSelector:
export default function createSelector(getProxy, calc) {
  let last;

  return () => {
    const [value] = getProxy()();

    if (!last || last.value !== value) {
      last = {
        calculated: calc(value),
        value
      };
    }

    return last.calculated;
  };
}

this seems to be a good idea if I want to customize some basic primitive types, some uses cases I can think of are like formatting a store value for UI, like showing price with currency or adding discount oven name concatenation.  But one thing which is not clear is what's the bigger use case, since teaful already gives us fragmented access to store and we can do the memoization in React easily(assuming its same for other framework), why do this selector thing which is just basic primitive value check

@Chetan-unbounce In fact it would be very similar to useMemo with a calculated store value but with a small difference: the hook that returns the createStore makes only 1 calculation even if this hook is at the same time in many components. With useMemo it would do 1 calculation per component.
An example:
const useExpensiveCalc = createSelector(
  () => useStore.items,
  (val) => expensiveCalc(val)
);

function Component1() {
  const val = useExpensiveCalc()
  // ...
}

function Component2() {
  const val = useExpensiveCalc()
  // ...
}

function Component3() {
  const [items] = useStore.items()
  const val = useMemo(() => expensiveCalc(items), [items])
  // ...
}

function Component4() {
  const [items] = useStore.items()
  const val = useMemo(() => expensiveCalc(items), [items])
  // ...
}

export default function App() {
    return (
     <>
        <Component1 />
        <Component2 />
        <Component3 />
        <Component4 />
     </>
    )
}

At the first render:

with createStore:

Component 1: It's doing the expensive calc
Component 2: It's using a cached value. It's not using an expensive value.

with useMemo:

Component 3: It's doing the expensive calc
Component 4: It's doing the expensive calc

In other rerenders for other things:

All Components (with createStore and with useMemo) are using the cached expensive value. No calculation in this step.

After a re-render for items update:

with createStore:

Component 1: It's doing the expensive calc again
Component 2: It's using a cached value. It's not using an expensive value.

with useMemo:

Component 3: It's doing the expensive calc again
Component 4: It's doing the expensive calc again

This is a very specific case and only makes sense for very complex calculations and heavy applications. So it does not make the createStore totally necessary. In order not to increase the size of the library since many people would not use it if anything I would upload it in a separate package.
However, for the moment it's only a proposal, it would be necessary to do several tests and to be totally sure of the results.

Perhaps the createSelector could be renamed to memoStoreCalc or something like that.

I've modified it a little bit to accept as many proxy entries as you want to consume:
Examples:
const useExpensiveCalc = createSelector(
  () => useStore.items,
  (items) => expensiveCalc(items)
);

const useExpensiveCalc = createSelector(
  () => useStore.items,
  () => useStore.user,
  (items, user) => expensiveCalc(items, user)
);

const useExpensiveCalc = createSelector(
  () => useStore.items,
  () => useStore.user,
  () => useStore.cart.price,
  (items, user, price) => expensiveCalc(items, user, price)
);

Example of createSelector (or with another name):
function createSelector(...proxies) {
  const calc = proxies.pop();
  const cache = new Map();
  let calculated;

  return () => {
    let inCache = true;

    const values = proxies.map((p) => {
      const [value] = p()();
      inCache &= cache.has(p) && cache.get(p) === value;
      return value;
    });

    if (!inCache) {
      calculated = calc(...values);
      proxies.forEach((p, index) => cache.set(p, values[index]));
    }

    return calculated;
  };
}

The example works, because we are using the same instance of the function returned from createSelector. But if we try to make the logic generic and move it to a new file like
`
const useSelector = (stateFun, cb) => {
return createSelector(stateFun, cb); // same function we have just takes in custom state val and callback
};
export default useSelector;
`
now if we try to import this in two different files we would get different instance of the returned function and the lexical scope will be different and the caching won't work.
@aralroca can u add an example with the above use case too, where we make it generic and import it from a  different file into different components in different files.

@Chetan-unbounce I did a little modification to support to define the stateFun & cb to useSelector:
export const useSelector = createSelector();

And to use the selector:
useSelector(
    () => useStore.cart.price,
    () => useStore.username,
    (price, username) => `${username} - ${price * 3}`
 );

createSelector:
function createSelector(...proxiesCreateSelector) {
  const cache = new Map();
  let calculated;

  return (...proxiesSelector) => {
    const proxies = proxiesCreateSelector.length
      ? proxiesCreateSelector
      : proxiesSelector;

    const calc = proxies.pop();
    let inCache = true;

    const values = proxies.map((p) => {
      const [value] = p()();
      inCache &= cache.has(p) && cache.get(p) === value;
      return value;
    });

    if (!inCache) {
      calculated = calc(...values);
      proxies.forEach((p, index) => cache.set(p, values[index]));
    }

    return calculated;
  };
}

I hope this works for you, if not we will look for a better way to implement it. At the moment it is just a draft.

I think it is better to create the hooks directly with the createSelector. Why do you need a separate useSelector?


Testing update

This is a continuation of #782 by @kane-c, it seems like we need to update some tests! I've started the initial work, would appreciate others looking at the coverage report and finding the places we haven't tested :+1:

Coverage decreased (-3.4%) to 94.972% when pulling 15ceadc547bf4a7fc815af16d113b290ebaee10b on testing-update into 17f85a1c8cf304d67ca919b63ec5c402614c1e22 on master.

Deploy preview ready!
Built with commit 380ade09da574f4b0330d5427dfdda9a3f7631ba
http://deploy-preview-795.react-boilerplate.netlify.com

Coverage increased (+0.5%) to 98.942% when pulling dcd14f779a6fd56d5e9e4b136bd60281ee3d9d24 on testing-update into 62b904b2932273ff61d5ed57c61dda671f107fe1 on dev.

Hell yeah 99% coverage 😎

Awesome :ok_hand:

Coverage increased (+0.5%) to 98.942% when pulling 66b8ceb5a8b2339a342089a23ee3af8814fce4f5 on testing-update into 62b904b2932273ff61d5ed57c61dda671f107fe1 on dev.

Hell yeah! :shipit:


golang filter: parse plugin config in the golang side while initializing golang filter

it will reject the config when failed to parse plugin config in the golang side.
fix https://github.com/envoyproxy/envoy/issues/25369
Commit Message:
Additional Description:
Risk Level:
Testing:
Docs Changes:
Release Notes:
Platform Specific Features:
[Optional Runtime guard:]
[Optional Fixes #Issue]
[Optional Fixes commit #PR or SHA]
[Optional Deprecated:]
[Optional API Considerations:]

/retest

oh, seems the coverage failure is introduce in https://github.com/envoyproxy/envoy/pull/27822
I can see the master branch also have such failure, but https://github.com/envoyproxy/envoy/pull/27822 is passed, so I'm a bit confused.
@alyssawilk could you please take a look? thanks!

thanks for the report.  tracking on https://github.com/envoyproxy/envoy/issues/27844 - I'll try to get a fix or revert landed today

Will wait for CI to be sorted.
/wait


Charmrun: Check for program existence/path using POSIX standard "command" instead of "which"

Charm4py and Multicore Darwin tracing failures are both spurious, in the chkpt test (#3296, #3295). UCX failed when trying to build libucx's Java bindings.

UCX has a new failure that I've seen twice now:
make[5]: Entering directory '/home/runner/work/charm/charm/ucx-linux-x86_64-openpmix/examples/charm++/zerocopy/entry_method_post_api/reg/multiplePostedBuffers'
../../../../../../bin/testrun  +p4 ./multiplePostedBuffers 32 +balancer RotateLB

Running on 4 processors:  ./multiplePostedBuffers 32 +balancer RotateLB
charmrun>  /usr/bin/setarch x86_64 -R  mpirun -np 4  ./multiplePostedBuffers 32 +balancer RotateLB
Charm++> Running in non-SMP mode: 4 processes (PEs)
Converse/Charm++ Commit ID: v6.11.0-beta1-137-g9fb5dcc10
Isomalloc> Synchronized global address space.
CharmLB> Load balancer assumes all CPUs are same.
Charm++> Running on 1 hosts (1 sockets x 2 cores x 1 PUs = 2-way SMP)
Charm++> cpu topology info is gathered in 0.020 seconds.
[0] TreeLB in LEGACY MODE support
[0] TreeLB: Using PE_Root tree with: Rotate
sdagRun: Iteration 1 completed
sdagRun: Iteration 2 completed
sdagRun: Iteration 3 completed
sdagRun: Iteration 4 completed
sdagRun: Iteration 5 completed
sdagRun: Iteration 6 completed
sdagRun: Iteration 7 completed
sdagRun: Iteration 8 completed
sdagRun: Iteration 9 completed
sdagRun: Iteration 10 completed
sdagRun: Iteration 11 completed
sdagRun: Iteration 12 completed
sdagRun: Iteration 13 completed
sdagRun: Iteration 14 completed
sdagRun: Iteration 15 completed
sdagRun: Iteration 16 completed
sdagRun: Iteration 17 completed
sdagRun: Iteration 18 completed
sdagRun: Iteration 19 completed
sdagRun: Iteration 20 completed
sdagRun: Iteration 21 completed
sdagRun: Iteration 22 completed
sdagRun: Iteration 23 completed
sdagRun: Iteration 24 completed
sdagRun: Iteration 25 completed
sdagRun: Iteration 26 completed
sdagRun: Iteration 27 completed
sdagRun: Iteration 28 completed
sdagRun: Iteration 29 completed
sdagRun: Iteration 30 completed
sdagRun: Iteration 31 completed
sdagRun: Iteration 32 completed
sdagRun: Iteration 33 completed
sdagRun: Iteration 34 completed
sdagRun: Iteration 35 completed
sdagRun: Iteration 36 completed
sdagRun: Iteration 37 completed
sdagRun: Iteration 38 completed
sdagRun: Iteration 39 completed
sdagRun: Iteration 40 completed
[fv-az180-662:400395:0:400395] Caught signal 11 (Segmentation fault: address not mapped to object at address 0x55555718eb78)
==== backtrace (tid: 400395) ====
 0  /lib/libucs.so.0(ucs_handle_error+0x2a4) [0x7ffff7f241c4]
 1  /lib/libucs.so.0(+0x2639f) [0x7ffff7f2439f]
 2  /lib/libucs.so.0(+0x266d4) [0x7ffff7f246d4]
 3  /lib/x86_64-linux-gnu/libc.so.6(+0x46210) [0x7ffff78fd210]
 4  ./multiplePostedBuffers(_Z12LrtsSendFunciiiPci+0x29) [0x5555557b1ce9]
 5  ./multiplePostedBuffers(CldEnqueue+0x111) [0x5555557ee0b1]
 6  ./multiplePostedBuffers(_ZNK10CkCallback4sendEPv+0x474) [0x555555705204]
 7  ./multiplePostedBuffers(_ZN14CkReductionMgr15finishReductionEv+0x3e1) [0x5555557649d1]
 8  ./multiplePostedBuffers(CkDeliverMessageFree+0x2e) [0x5555556dc48e]
 9  ./multiplePostedBuffers(_Z15_processHandlerPvP11CkCoreState+0x1a30) [0x5555556e51e0]
10  ./multiplePostedBuffers(CsdScheduleForever+0xcd) [0x5555557885dd]
11  ./multiplePostedBuffers(CsdScheduler+0x35) [0x555555788935]
12  ./multiplePostedBuffers(ConverseInit+0x542) [0x5555557b33c2]
13  ./multiplePostedBuffers(charm_main+0x2d) [0x55555576dfad]
14  /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xf3) [0x7ffff78de0b3]
15  ./multiplePostedBuffers(_start+0x2e) [0x55555564201e]
=================================

I tried debugging the ucx failure with tmate and I am getting the following stack trace: (the destPe/destNode is suspicious as seen in frame 0 and frame 1).
(gdb) bt
#0  0x00005555557d6aa9 in UcxSendMsg (
    cb=0x5555557d47e0 <UcxTxReqCompleted(void*, ucs_status_t)>, tag=0,
    msg=0x555555bf5820 “\300”, size=192, destPE=<optimized out>,
    destNode=<optimized out>)
    at /home/runner/work/charm/charm/src/arch/ucx/machine.C:553
#1  LrtsSendFunc (destNode=1435891840, destPE=<optimized out>, size=192,
    msg=0x555555bf5820 “\300", mode=1)
    at /home/runner/work/charm/charm/src/arch/ucx/machine.C:553
#2  0x0000555555812e71 in CldEnqueue (pe=1435891840, msg=<optimized out>,
    infofn=37) at /home/runner/work/charm/charm/src/conv-ldb/cldb.rand.C:129
#3  0x0000555555729eb4 in CkCallback::send (this=0x555555bf5898,
    msg=0x555555bf5860)
    at /home/runner/work/charm/charm/src/ck-core/ckcallback.C:364
#4  0x0000555555789661 in CkReductionMgr::finishReduction (this=0x555555bd05f0)
    at /home/runner/work/charm/charm/src/ck-core/ckreduction.C:682
#5  0x0000555555788f08 in CkReductionMgr::addContribution (
    this=0x555555bd05f0, m=0x555555bf5940)
#6  0x0000555555666391 in zerocopyObject::nextStep (this=0x555555bd9410)
    at multiplePostedBuffers.C:163
#7  0x00005555556661c3 in zerocopyObject::sdagZeroCopySent (
    this=0x555555bd9410, m=0x555555be2900) at multiplePostedBuffers.C:143
#8  0x000055555565f455 in CkIndex_zerocopyObject::_call_sdagZeroCopySent_CkDataM
sg (impl_msg=0x555555be2900, impl_obj_void=0x555555bd9410)
    at simpleZeroCopy.def.h:724
#9  0x00005555557011fe in CkDeliverMessageFree (epIdx=149, msg=0x555555be2900,
    obj=<optimized out>) at /home/runner/work/charm/charm/src/ck-core/ck.C:549
#10 0x0000555555742abc in CkLocRec::invokeEntry (this=0x555555bd95f0,
    obj=0x555555bd9410, msg=0x555555be2900, epIdx=149, doFree=<optimized out>)
    at /home/runner/work/charm/charm/src/ck-core/cklocation.C:2246
#11 0x0000555555709912 in CkMigratable::ckInvokeEntry (doFree=<optimized out>,
    msg=<optimized out>, epIdx=<optimized out>, this=<optimized out>)
    at /home/runner/work/charm/charm/src/ck-core/ckmigratable.h:79
#12 _processArrayEltMsg (env=0x555555be28c0, ck=0x555555bb0500)
    at /home/runner/work/charm/charm/src/ck-core/ck.C:1177
#13 _processHandler (converseMsg=<optimized out>, ck=0x555555bb0500)
    at /home/runner/work/charm/charm/src/ck-core/ck.C:1270
#14 0x00005555557ad44d in CmiHandleMessage (msg=<optimized out>)
    at /home/runner/work/charm/charm/src/conv-core/convcore.C:1695
#15 CsdScheduleForever ()
    at /home/runner/work/charm/charm/src/conv-core/convcore.C:1942
#16 0x00005555557ad7a5 in CsdScheduler (maxmsgs=maxmsgs@entry=-1)
    at /home/runner/work/charm/charm/src/conv-core/convcore.C:1881
#17 0x00005555557d8182 in ConverseRunPE (everReturn=0)
    at /home/runner/work/charm/charm/src/arch/util/machine-common-core.C:1609
#18 ConverseInit (argc=<optimized out>, argv=<optimized out>,
fn=fn@entry=0x5555--Type <RET> for more, q to quit, c to continue without paging--
    55792e90 <_initCharm(int, char**)>,
    usched=usched@entry=0, initret=initret@entry=0)
    at /home/runner/work/charm/charm/src/arch/util/machine-common-core.C:1524
#19 0x0000555555792c3d in charm_main (argc=<optimized out>,
    argv=<optimized out>)
    at /home/runner/work/charm/charm/src/ck-core/init.C:1739
#20 0x00007ffff78dd0b3 in __libc_start_main (
    main=0x55555565c7e0 <main(int, char**)>, argc=4, argv=0x7fffffffc968,
    init=<optimized out>, fini=<optimized out>, rtld_fini=<optimized out>,
    stack_end=0x7fffffffc958) at ../csu/libc-start.c:308
#21 0x000055555565d39e in _start ()
    at /home/runner/work/charm/charm/src/ck-core/ck.C:32

Basically, the contribute(compReductionCb); call in nextStep() triggers the segfault because in frame 3 of the stack trace, when the chare PE is to be determined, there's some garbage value in d.chare.onPE, which goes onto cause the crash in UcxSendMsg.
(gdb) frame 3
#3  0x0000555555729eb4 in CkCallback::send (this=0x555555bf5898,
    msg=0x555555bf5860)
    at /home/runner/work/charm/charm/src/ck-core/ckcallback.C:364
364                     CkSendMsg(d.chare.ep, msg, &d.chare.id);
(gdb) print d.chare.ep
$1 = 144
(gdb) print d.chare
$2 = {ep = 144, id = {onPE =<PHONE_NUMBER>, objPtr = 0x0}, refnum = 0,
  hasRefnum = false}

The compReductionCb is set to reduction target Main::done, which doesn't even migrate, so I'm wondering where the incorrect PE is being populated from.

I can reproduce the segfault locally and it happens as least as far back as 4e15c48d1499a038a414849b3fc548b3a21b0ac8. ASan does not help.


Crash Using Alamofire Within App Clip

[ * ] I've read, understood, and done my best to follow the *CONTRIBUTING guidelines.
What did you do?
Added the Alamofire to my App Clip target using Cocapods
What did you expect to happen?
It to work as per other targets.
What happened instead?
I get an on-launch crash with the error:
dyld: Library not loaded: @rpath/Alamofire.framework/Alamofire
  Referenced from: /private/var/containers/Bundle/Application/53C78E93-79E0-438F-AA1C-11324FE1B0D4/SleepiestAppClip.app/SleepiestAppClip
  Reason: image not found
dyld: launch, loading dependent libraries
DYLD_LIBRARY_PATH=/usr/lib/system/introspection
DYLD_INSERT_LIBRARIES=/Developer/usr/lib/libBacktraceRecording.dylib:/Developer/usr/lib/libMainThreadChecker.dylib:/Developer/Library/PrivateFrameworks/DTDDISupport.framework/libViewDebuggerSupport.dylib
(lldb)

Pod File:
use_frameworks!

target 'Sleepiest' do
platform :ios, '11.0'
pod 'Alamofire', '~> 5.2'
end

target 'SleepiestAppClip' do
platform :ios, '14.0'
pod 'Alamofire', '~> 5.2'
end

Alamofire Environment
**Alamofire version: 5.2
**Xcode version: 12.0 beta 2
**Swift version: 5
**Platform(s) running Alamofire: iOS App Clip
**macOS version running Xcode: 10.15.4
Demo Project
Seems to happen with any empty project with an App Clip target.

This is an issue with CocoaPods which is fixed on their master branch. In the mean time you could try their prerelease version or use SPM through Xcode to integrate your dependencies.

CocoaPods has released their first 1.10 beta, which officially supports AppClips.


Keystore Randomization

Description
We can improve keystore security by generating a unique one in every SE-2 application.
When yarn-generate is called, it will create a unique name and private key for the user.
I will try to improve the documentation but would appreciate help with updating it!
Additional Information

[X] I have read the contributing docs (if this is your first contribution)
[X] This is not a duplicate of any existing pull request

Your ENS/address: JacobHomanics.eth

https://github.com/scaffold-eth/scaffold-eth-2/blob/25f23f62e260ffa580887b2f2557b1e5db2dfa8b/.github/pull_request_template.md?plain=1#L14
Hey Jacob, I think its really important that you make discussions/issue first rather than jumping directly into PR's also looking into different PR's, issues and discussions before creating your own discussion might also give you and us more context on things.
Closing this for now, not rejecting PR but maybe first we should discuss/brainstorm a bit.


Bug: Goto line opens intermediary code folds

Prerequisites

[x] Put an X between the brackets on this line if you have done all of the following:

Reproduced the problem in Safe Mode: https://flight-manual.atom.io/hacking-atom/sections/debugging/#using-safe-mode
Followed all applicable steps in the debugging guide: https://flight-manual.atom.io/hacking-atom/sections/debugging/
Checked the FAQs on the message board for common solutions: https://discuss.atom.io/c/faq
Checked that your issue isn't already filed: https://github.com/issues?utf8=✓&q=is%3Aissue+user%3Aatom
Checked that there is not already an Atom package that provides the described functionality: https://atom.io/packages

Description
When using atom's Goto line feature it currently goes to every line after each new number is typed. In doing so it opens any code folds which is really annoying.
Steps to Reproduce

Have code folded on line 13
Start going to line 134
Once Goto 13 has been typed observe that the code fold is opened

Expected behavior: Not opened until enter is hit (or the dialogue is closed)
Actual behavior: code fold opens
Edit by @rsese to add a GIF (fold at line 26, trying to go to line 265, code at line 26 unfolds):

Reproduces how often: Everytime
Versions:
Recent

Thanks for opening a separate issue for this @Nokel81 - reproduced on macOS 10.12.6 with 1.34.0.

Thanks for the report.
This was a consequence of the recent incremental search change. Because we feel that this was a beneficial change, we aren't going to revert it to fix this behavior. However, we would be open to a well-written pull request that refolds the unfolded section if it is navigated away from as part of an incremental search. For that, I'll mark this help-wanted so that it is easily searchable.
Thanks again for the well-written issue!

Would it be possible to instead have an option that doesn't unfold the code until the goto dialog is closed?

I'm much less sure about something like that because with incremental search, we can't know if 13 is where you intend to stop and what if you're not sure if it is 13, 14, or 15 until the code is unfolded?

#response_container_BBPPID{font-family: initial; font-size:initial; color: initial;} I generally use 'goto line' after receiving an error from the runtime or compiler. So I don't generally look at the unfolded code as it goes along.                                                                                From<EMAIL_ADDRESS>February 26, 2019 7:40 PMTo<EMAIL_ADDRESS>to<EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS>Re: [atom/atom] Bug: Goto line opens intermediary code folds  (#18901)  I'm much less sure about something like that because with incremental search, we can't know if 13 is where you intend to stop and what if you're not sure if it is 13, 14, or 15 until the code is unfolded?
—You are receiving this because you were mentioned.Reply to this email directly, view it on GitHub, or mute the thread.

Unfortunately, you're not the only person that uses this feature. We have to consider all the other users too. If you want something that's completely tailored for your use case, you can feel free to fork the original https://github.com/atom/go-to-line package and modify it to work however you want.


Quick sort algorithm in C++

I want to add an algorithm of Quick sort.
@Kumar-laxmi sir please assign me this issue.

refer #120

ok sir


Circular references in the storage cache when using observeOpenAI

Bug description
So, I've been using traces successfully within an application, all traces and spans get stored correctly and it works great.
However, I recently added the langfuse error handler and started logging errors from it, and noticed that every time traces occur I see the following errors being logged:
2024-05-23 22:26:31 Error while flushing Langfuse TypeError: Converting circular structure to JSON
2024-05-23 22:26:31     --> starting at object with constructor 'Object'
2024-05-23 22:26:31     |     property 'queue' -> object with constructor 'Array'
2024-05-23 22:26:31     |     index 2 -> object with constructor 'Object'
2024-05-23 22:26:31     |     ...
2024-05-23 22:26:31     |     property 'client' -> object with constructor 'Langfuse'
2024-05-23 22:26:31     --- property '_storageCache' closes the circle
2024-05-23 22:26:31     at JSON.stringify (<anonymous>)
2024-05-23 22:26:31     at Langfuse.setPersistedProperty (file:///usr/src/app/node_modules/langfuse/lib/index.mjs:177:50)
2024-05-23 22:26:31     at Langfuse.flush (file:///usr/src/app/node_modules/langfuse-core/lib/index.mjs:598:10)
2024-05-23 22:26:31     at file:///usr/src/app/node_modules/langfuse-core/lib/index.mjs:574:14
2024-05-23 22:26:31     at new Promise (<anonymous>)
2024-05-23 22:26:31     at Langfuse.flushAsync (file:///usr/src/app/node_modules/langfuse-core/lib/index.mjs:572:12)

I don't see what I might be doing wrong that is causing a circular reference to end up in the storage cache, since I'm just either manually creating a trace or a span just with a name and some input and output (which get shown correctly in langfuse), plus the observeOpenAI wrapper for OpenAI completions.
How to reproduce
Traces that are manually created don't trigger the error, neither do spans.
The error appears as soon as it's a Generation automatically created by the observeOpenAI wrapped openAI client.
Related sub-libraries

[ ] All of them
[X ] langfuse
[ ] langfuse-node

Additional context
Completions in my case are mostly done as streams. Not sure if that info helps. Even completions with tools, since I'm running an Agent with tools with streamed responses.
I'm using langfuse version 3.11.1 from npm.
Thank you for your bug report – we love squashing them!

I've just noticed that once this error starts occurring it appears that future traces stop working, so the issues seems more serious than i initially thought. Any idea what might be going here?


Minimum password strength

This one is tricky.
Need to add some type of check to make sure that the user is using a password that isn't complete junk. miniLock uses zxcvbn, which is great for them, as it's in JS, but for us, we don't have a well accepted library that we can use.
There is a .NET "port" of zxcvbn, but it's actually executing the JS behind the scenes - the last thing I want to do in a security focused application is add that kind of attack / review / audit surface. So it's not an option.
So, options:

Do a real port of zxcvbn to C# - Could be useful, but time consuming, time I don't think I have.
Write something similar, but simpler. Also time consuming.

I think this needs to happen for the first real release, but there's going to be some time investment required.

I use this: https://github.com/mickford/zxcvbn-cs in one of my projects.
But i don`t see any javascript in it. :)

I found that one after I opened this ticket, but I have seriously mixed feelings. One, seems it was written then left untouched - where zxcvbn has been under active development. Next, it add a lot of non-standard (i.e. not part of the framework, or well known open source) to the mix. Which means it'll be harder to take a quick look at determine there's nothing funny going on.
This would be the easy way, and this is the major blocker to 0.1, but I don't want to make it harder to review than necessary.

I only use it to indicate the quality of the password and show the estimated crack time. I don`t restrict any passwords. In my opinion there no perfect way to clear this problem.
The weakest factor will be the user, if he forget his password (maybe because its hard to remember or he dont use any password manager), he can`t recover it and the encrypted files are lost.

@adamcaudill  I use zxcvbn-cs now also in: https://github.com/bitbeans/NaclKeys/blob/master/NaclKeys/KeyGenerator.cs#L110

I went ahead and used zxcvbn-cs - it's not enforcing any minimum at this point, but it does use the entropy calculation to provide a score. For now, I think it's good enough. May revisit later, but this was the big hold-up to getting 0.1 released.


Split state transition package (2nd attempt)

@mpetrunic please can you fix the tests yourself please :pray: I've done the bulk of the work but can't get the tests working after many attempts. If you agree on splitting the package help me get the PR green asap before it gets unsalvagable again due to conflicts.

I need to think about it more.
I wouldn't separate fast state transition into separate package. I think that would be really bad in terms of future planned hardforks. We would new package for every planned hardfork then
I think best way forward would be following directory structure in current state transition:

phase0

fast

index.ts - export * as fast from

original

index.ts - export * from

utils (shared things between fast and original)
index.ts - exports utils, fast and original

lightclient

index.ts - export * as lightclient

index.ts - export phase0 and lightclient

That way everything will be namespaced and we can map epoch => hardfork namespace.
In code it would be much clearer since we would write:
phase0.fast.processBlock or phase0.processBlock
cc @wemeetagain I will put this in that issue you created as well

It seems @dapplion is suggesting something like this (I only see 2 packages):

naive/

index.ts
phase0/
lightclient/
utils/

fast/

index.ts
phase0/
utils/

Closing in favor of reorganizing beacon state transition package (as mentioned in planning meeting / standup)


Added support for .NET Standard 2.1

Description

Added support for .NET Standard 2.1
Added culture specific GetHashCode implementation (required by Validation)
Modernized syntax in updated files

Closed issues

fixes #1324
Checklist

[x] Reviewed the contribution guidelines
[x] Linked the issue(s) the PR closes
[x] Implemented automated tests and checked coverage
[x] Provided inline documentation comments for new public API
[x] Ran the full solution build and validation locally

Closing in favor of #1331


fingerprint warning missing after new install

Issue Type: Bug
After installing vscode new on a machine where the known_hosts was not initialized sync does not go through without a warning.
Steps:
Opening a git controlled folder
Hit Source Control Pull or the sync symbol on the statusbar
behaviour:
Nothing happens, vscode seems to sync (rotating statusbar icon)
expected:
Authenticity prompt or error message
Output from git pull:
The authenticity of host 'github.com (<IP_ADDRESS>)' can't be established.
ECDSA key fingerprint is SHA256:p2QAMXNIC1TJYWEIOttrVc98/R1BUFWu3/LiyKgUfQM.
Are you sure you want to continue connecting (yes/no/[fingerprint])?
 Are you still able to reproduce this issue? We have added support for SSH keys with a passphrase in the September 2022 release. I will go ahead and optimistically close this issue but please feel free to reopen it in case you are still having issues. Thanks!

Yes

12 dec. 2022 16:55:31 Ladislau Szomoru @.***>:

@theking2[https://github.com/theking2], apologies for not getting back to you on this until now. Are you still able to reproduce this issue? We have added support for SSH keys with a passphrase in the September 2022 release[https://code.visualstudio.com/updates/v1_72#_add-support-for-ssh-keys-with-a-passphrase]. I will go ahead and optimistically close this issue but please feel free to reopen it in case you are still having issues. Thanks!
—
Reply to this email directly, view it on GitHub[https://github.com/microsoft/vscode/issues/144668#issuecomment-1346776426], or unsubscribe[https://github.com/notifications/unsubscribe-auth/AAMJS6DPGQEYWII42DYIG63WM5DG7ANCNFSM5QF762WA].
You are receiving this because you were mentioned.[Tracking afbeelding][https://github.com/notifications/beacon/AAMJS6CLYZAQFPVNMC6BDKTWM5DG7A5CNFSM5QF762WKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOKBDC22Q.gif]

Same problem here.


For loop parsing

Let me know if I'm barking up the wrong tree. Still working on this one.

Broken up into separate PRs


something wrong with project structure

this is confusing...
when i go to main project url https://github.com/mullwar/telebot there are lots of things missing (plugins, examples, etc.)
but when i go to latest version url https://github.com/mullwar/telebot/tree/v1.2.3 i see them all.
can you fix this?

Reverted examples and plugins in v1.2.5


nixos/fetchFromGitHub: fix error where specifying leaveDotFile causes…

Motivation for this change
Fix bug #107556
I definitely would appreciate some eyes on this, given how basic and extremely common the function I am modifying is.
Things done

[ ] Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
Built on platform(s)

[ ] NixOS
[ ] macOS
[ ] other Linux distributions

[ ] Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
[x] Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
[ ] Tested execution of all binary files (usually in ./result/bin/)
[ ] Determined the impact on package closure size (by running nix path-info -S before and after)
[ ] Ensured that relevant documentation is up to date
[x] Fits CONTRIBUTING.md.

Hi! It seems we have attempted to fix the same problem independently of each other: #107322
I think you need to pass through deepClone as well and treat leaveDotGit specially as:

deepClone defaults to false
leaveDotGit defaults to deepClone

https://github.com/NixOS/nixpkgs/blob/351f3c043d80009569d646a332025f7870b11cf3/pkgs/build-support/fetchgit/default.nix#L15-L16
With your solution the following snippet would result in leaveDotGit = false although it should default to deepClone which is true in this case:
fetchFromGitHub {
  # …
  fetchSubModules = true;
  deepClone = true;
}

Your commit seems far better thought out.  So I'll close this.


snappy library not found.

Attempting to compile under Cygwin,  I get the following error:
CMake Error: The following variables are used in this project, but they are set to NOTFOUND.
Please set them or make sure they are set and tested correctly in the CMake files:
SNAPPY_LIBRARIES (ADVANCED)
    linked by target "avro-shared" in directory /home/<usernaeme>/json2avro/avro-c/src
    linked by target "avro-static" in directory /home/<usernaeme>/json2avro/avro-c/src

This contraticts the text found under json2avro/avro-c/INSTALL:
Avro uses CMake [1] as its build manager.  You must have this installed,
along with a C compiler (such as gcc) to build the library.

Avro doesn't depend on any other libraries, but you need asciidoc [2]
and source-highlight [3] installed to build Avro's documentation.  The
build scripts will automatically detect whether these tools are
installed, and will skip the documentation if they're not.

Under Cygwin, I could not find any library with "snappy" in the name.  Not sure what this library is about.  If the dependency can become optional, the better.  Else, please document the dependency in json2avro/avro-c/INSTALL.

I have the same issue in my machine as well

brew install snappy (macos)
However, it was still not able to reference snappy-c.h file, which I manually added in src. After that the make was successful.

Not able to make the application... due to json2avro/avro-c/src/codec.c:20:10: fatal error: 'snappy-c.h' file not found. Installed snappy using brew. Any other option other than manually placing the file inside source folder?

You're probably missing a dev package, I'm not familiar with brew, but on Linux distros  it would be called something like snappy-dev or snappy-devel and would have the headers necessary for compilation included.

brew install snappy
Then:
cd avro-c/src
ln -s /usr/local/Cellar/snappy/1.1.9/include/snappy-c.h .
cd ../..
make

Works.
However, it was still not able to reference snappy-c.h file, which I manually added in src. After that the make was successful.


Update request: nut 2.8.0 → 2.8.2

Package name: nixpkgs.nut
Latest released version: 2.8.2

Current version on the unstable channel: 2.8.0
Current version on the stable/release channel: 2.8.0

[X] Checked the nixpkgs pull requests

Notify maintainers
@nbp
NUT version 2.8.0 contains a critical bug: If the UPS autonomously switches to calibration mode, then NUT never updates its state once calibration is done. This means it will never take any action on loss of power, i.e. the UPS will run out its battery, likely damaging the hardware.
This was reported as https://github.com/networkupstools/nut/issues/2168, and is fixed in 2.8.2.
I believe this should be backported to stable.

Note for maintainers: Please tag this issue in your PR.

Add a :+1: reaction to issues you find important.

I am having this error, @nbp or anyone wanna take a look?
        > Makefile.am: installing './INSTALL'
       > Makefile.am: error: required file './NEWS' not found
       > Makefile.am: error: required file './README' not found
       > clients/Makefile.am: installing './depcomp'
       > configure.ac:4981: error: required file 'scripts/augeas/nutupsconf.aug.in' not found
       > configure.ac:4981: error: required file 'scripts/devd/nut-usb.conf.in' not found
       > configure.ac:4873: error: required file 'scripts/systemd/nut-common-tmpfiles.conf.in' not found
       > configure.ac:4981: error: required file 'scripts/udev/nut-usbups.rules.in' not found
       > parallel-tests: installing './test-driver'
       > autoreconf: error: automake failed with exit status: 1

All these overrides fixed the bump for me: https://github.com/chaotic-cx/nyx/blob/b126c4b34775b9717a4076489617ef7d53f53ea9/pkgs/nut-git/default.nix#L16-L44
Can use my UPS now that uses the sms_ser which became available in 2.8.1.

NUT version 2.8.0 contains a critical bug: If the UPS autonomously switches to calibration mode, then NUT never updates its state once calibration is done. This means it will never take any action on loss of power, i.e. the UPS will run out its battery, likely damaging the hardware.

Should we backport https://github.com/NixOS/nixpkgs/pull/334807 ("nut: 2.8.0 -> 2.8.2") to NixOS 24.05?

Yes, everything that does not have a breakage of NixOS' modules usage, or breakage of the apps' own configurations/usage can be backported. Feel free to add the label for the bot to do its magic.


howto install apsystems_ecur on home assistant core

Hi,
I would like to install this component on home-assistant core and got stuck.
The problem: I have an installation on my router where home-assistant is installed via pip. (I think this is the "core" version)
Somehow my setup looks different compared to the instructions given in the readme. Basically I do not have the HACS thing and I am reluctant trying to add that too, as the router is quite resource constrained already.
I have here:
homeassistant@home-assistant:/srv/homeassistant$ ./bin/pip list | grep assis
home-assistant-frontend 20220504.1
homeassistant           2022.5.5
and an ECU-B at <IP_ADDRESS>:
$ nc -v <IP_ADDRESS> 8899
Connection to <IP_ADDRESS> 8899 port [tcp/*] succeeded!
APS1100160001END
APS11009400012163000678320110012ECU_B_1.2.26009Etc/GMT-8        VEND

What I tried:
I cloned the https://github.com/ksheumaker/homeassistant-apsystems_ecur repo and
copied the  folder homeassistant-apsystems_ecur/custom_components/apsystems_ecur to the custom_components folder below the config_dir of hass (that is  here /home/homeassistant/.homeassistant/custom_components/apsystems_ecur).
Then I  changed configurations.yaml:
apsystems_ecur:
    host: <IP_ADDRESS>
    scan_interval: 60

and started hass from the shell:
 /srv/homeassistant/bin/python3 /srv/homeassistant/bin/hass -c /home/homeassistant/.homeassistant -v --debug --log-file=./hass.log
I see in the log some apsystems_ecur related messages, but somehow I expected sensors to appear:
2023-04-15 07:44:32 INFO (SyncWorker_0) [homeassistant.loader] Loaded apsystems_ecur from custom_components.apsystems_ecur
2023-04-15 07:44:32 WARNING (SyncWorker_0) [homeassistant.loader] We found a custom integration apsystems_ecur which has not been tested by Home Assistant. This component might cause stability problems, be sure to disable it if you experience issues with Home Assistant
...
2023-04-15 07:44:37 INFO (MainThread) [homeassistant.setup] Setting up apsystems_ecur
2023-04-15 07:44:37 INFO (MainThread) [homeassistant.setup] Setup of domain apsystems_ecur took 0.0 seconds
2023-04-15 07:44:37 DEBUG (MainThread) [homeassistant.core] Bus:Handling <Event component_loaded[L]: component=apsystems_ecur>
...
2023-04-15 07:44:44 DEBUG (Recorder) [homeassistant.components.recorder] Processing task: EventTask(event=<Event component_loaded[L]: component=apsystems_ecur>)

Is it possible to run this extension with the homeassistant core version?

Looks like you're missing the integration config entries which are stored in /config/.storage/core.config_entries. Normally after (manual/HACS) installation you add the integration to enable the integration to initialize and store discovered entities. I'm not sure how you can add them in your case. Here is an example of how it looks like in the core.config_entries file:

Thank you. I tried adding this by hand, but no luck.
[root@home-assistant:/home/homeassistant/.homeassistant/.storage#](mailto:root@home-assistant:/home/homeassistant/.homeassistant/.storage#)  diff -Naur core.config_entries-178 core.config_entries
--- core.config_entries-178     2023-04-16 06:58:10.744025482 +0000
+++ core.config_entries 2023-04-16 07:03:53.056587843 +0000
@@ -250,7 +250,23 @@
                 "source": "ignore",
                 "disabled_by": null
+            },
+            {
+                "entry_id": "abcdefab41295b7164df4f04ca51dc7f",
+                "version": 1,
+                "domain": "apsystems_ecur",
+                "title": "ECU",
+                "data": {
+                        "host": "<IP_ADDRESS>",
+                        "scan_interval": 400
+                },
+                "options": {},
+                "pref_disable_new_entities": false,
+                "pref_disable_polling": false,
+                "source": "ignore",
+                "unique_id": null,
+                "disabled_by": null
             }
         ]
     }
}

If I compare the apsystems_ecur code to this:
https://developers.home-assistant.io/docs/creating_platform_index
especially:
https://github.com/home-assistant/example-custom-config/blob/master/custom_components/example_light/light.py
I think a function like the setup_platform() is missing in apsystems_ecur.
When I tried adding some years ago a beckhoff/ twincat component to home_assistant, there was a setup() function required.
I have to investigate howto do this nowadays with the modern async style.
Part/all of the setup_plattform() functionality is probably done by this HACS component if it is present. I have to check...

I was not able to add a similarly structured example from the example repo either.
I have opened this:  https://github.com/home-assistant/example-custom-config/issues/43#issue-1671220141

I managed now to start the integration. I used latest from git for home-assistant core and latest for apsystems_ecur.
So I guess  homeassistant 2022.5.5 is too old for latest apsystems_ecur.


Added Stylus Mixin

To support the largest CSS pre-processors, I added the mixin for the Stylus.

How can I fix this,? WHy is there new issues?

@Lori1072 This isn't a Issue. This is a pull request with the insertion of stylus mixin.

ok thank You....I appreciate. A question I am trying to make website quicker,, WHat can I do as Far as compresssion..

@Lori1072, these are issues specifically related to retina.js and not the appropriate place for your questions. You apparently are watching this repository so you will get all the messages that are posted - some are issues, some are pull or merge requests.
There are tons of resources available online with information on speeding up your site but this is not the place to go for support for this.


dataset taxonomy missing

dataset taxonomy missing
the old site has a taxonomy browser on the dataset page.
we have something very similar on the species pages now, but there is no linkage from the dataset

fbitem-dataset66dd0960-2d7d-46ee-a491-87b9adcfe7b1
Reported by: @mortenhofft
System: Chrome 59.0.3071 / Mac OS X 10.11.6
Referer: https://www.gbif-uat.org/dataset/66dd0960-2d7d-46ee-a491-87b9adcfe7b1
Window size: width 1921 - height 1080
API log
Site log

closed by https://github.com/gbif/portal16/commit/d811888a88badf79b013f5337a5dd6adb04b50a0


Dark Mode Improvement

Hey, I've resolved issue #76 under JWOC. Kindly review

@mrbhatt2348 hey, please let me know if any changes are required or it's good to merge


poor top_image results (improve when dimension check on og:image added)

 Issue by rahulbot
Thu Jun  3 15:29:15 2021
Originally opened as https://github.com/codelucas/newspaper/issues/894

We found that the top_image for a noticeable number of stories in a sample of news we were working on returned favicons. This happened on stories from popular and large websites like BBC News. After some trial I found that by changing the logic to only use og:image if it is large improves the results. Noting this here for anyone else that runs into this, and as a suggested change.
After investigating a bit more I found the algorithm seems to work like this psuedocode:
"
If og:image is set: use that as the top image no matter what
else if the first image is big use that as a the top image
else pick the largest dimensional image
"
The problem we faced is that the first clause was picking small images in many articles, because they were set as the og:image. It appears that this change was made years ago (https://github.com/codelucas/newspaper/issues/96) due to some findings from German news sources.
I recommend changing the set_meta_img call from set_top_img_no_check to set_top_img (so it runs the satisfies_requirements dimensional check). We found this improves top_image results noticeably.

improved in v0.9.1


Share QR:QR is not visible while sending the Gift via QR

"Scan the QR and receive bitcoin in your Bitcoin Tribe bitcoin wallet.
Getting only this while sending the gift via Share QR option.
Sending QR as an image is not visible

Verified this issue on Tribe app v 2.3.0(619)

Completed