proposal: spec: named check-handle pairs for error handling

After reading the proposed draft design I was very glad that there are some upcoming changes to the errorhandling in go.
I have also read a lot of similar proposals and you may argue this is a clone of some other proposal. My intention behind this is to offer my oppinion as a scriptingwise go-dependant engineer. Speed, readability and reusability are very much the things I am looking for.
The general idea behind check and handle will address the current issues with readability very well.
The example in the draft design explains the usage of check and handle:
func printSum(a, b string) error {
	handle err { return err }
	x := check strconv.Atoi(a)
	y := check strconv.Atoi(b)
	fmt.Println("result:", x + y)
	return nil
}

This adresses readablility a lot, but repetitive code not by much:

to use a different handle you would have to redefine it each time
there would be at most one default handle

Named dicts or structs are being used in various languages.
As an addition to check handle I am now proposing - similar to labled handles - named pairs of these keywords. A named pair would have the following syntax:
handle.<name>
check.<name>
Rewriting the given example you could then name the handle:
func printSum(a, b string) error {
	handle.chain err { return err }
	x := check.chain strconv.Atoi(a)
	...
}

I know that that assigning to an attribute of a keyword like handle.<name> is unwanted by most and this needs to be adressed, but this code would be very readable and very reusable. There could also be standard definitions of named pairs like check.chain, check.panic, etc. or exported handles like handle.Chain or  Handle.Chain.
I believe this would integrate very well with the current go language and would make at least my life easier.
Thanks for reading! I'm looking forward to the upcoming changes!

Please add a link for this to https://github.com/golang/go/wiki/Go2ErrorHandlingFeedback
Also, if you haven't, you might consider how your ideas fit into the broad range of possible requirements I've assembled in Requirements to Consider for Go 2 Error Handling.

That's a novel and confusing meaning for dot. I think this proposal is more likely to get a fair shake if it stays within the existing syntactical style of Go.
If you used parens, you'd stay closer to Go style, though with added noise. I'm also doing handles a little differently, making it be more like func.
func printSum(a, b string) error {
	handle chain(err) { return err }
	x := check(chain) strconv.Atoi(a)
	...
}

If you made the name required, you wouldn't need the dot-separator at all. Though simple uses of check might be better implicitly using the last unnamed handle.
func printSum(a, b string) error {
	handle chain err { return err }
	x := check chain strconv.Atoi(a)
	...
}

Thanks for the proposal.
As @tv42 says, the dot syntax used here is very unlike any other use of dot in the language.  It might be interesting to try to implement this using a more label-like syntax.
This doesn't address the issues of the earlier design: it's not clear how handlers and the defer keyword interoperate.  It's not clear how or whether handlers chain.
We don't currently expect to implement the earlier handler proposal.  Closing this one.  We can reopen this if we return to the earlier idea.
Writing for @golang/proposal-review .


Epic: IP-whitelist for proxy

Motivation
To forward traffic only from whitelisted hosts
DoD
As a user, I'm able to configure IP whitelist
As a user, I'm unable to connect to my compute instance from non-whitelisted IP through pg protocol, WebSockets, and HTTP
Implementation ideas

Extend control plane API to expose the IP-ranges
Forbid connections for endpoints from not listed IP address
If the setting is not configured, it means, that all connections must be accepted

### Tasks

Possible formats
single IP (<IP_ADDRESS>)
IP range (<IP_ADDRESS>-<IP_ADDRESS>)
IP with network mask (<IP_ADDRESS>/16)
IPv6???

Other related tasks and Epics

From the cplane side list of allowed ips could be added into ProxyWakeCompute response
https://github.com/neondatabase/cloud/blob/535a96c67d63b1b108c76e353151af7cd336ab9b/openapispec/v2/management-v2.yaml#L904-L914
Like new allowed_ips arrays of strings
Go code of this handler is placed here
https://github.com/neondatabase/cloud/blob/535a96c67d63b1b108c76e353151af7cd336ab9b/goapp/internal/controllers/managementapiv2/authproxy.go#L105
Yet, we will also need to store the actual list somewhere in the control plane metadata. I tend to do not do this on the per branch / endpoint basis, but rather keep it project-scoped, then add endpoint-scope if users will ask about it. Then we can put AllowedIPs in to DefaultEndpointSettings in the project
https://github.com/neondatabase/cloud/blob/535a96c67d63b1b108c76e353151af7cd336ab9b/goapp/internal/dto/project.go#L252-L257
And also add it to public IP so that users was able to change it
https://github.com/neondatabase/cloud/blob/535a96c67d63b1b108c76e353151af7cd336ab9b/openapispec/v2/public-v2.yaml#L3880
And the same in the internal cplane API
https://github.com/neondatabase/cloud/blob/535a96c67d63b1b108c76e353151af7cd336ab9b/goapp/internal/controlplane/apispec/v1.yaml#L3875

i'd like to flag addtional requirement, let's also add this to the issue body?
the user should be able to easily exclude the non-primary branches from the whitelisting
default to apply to all branches, but an option to only apply to the primary branch
hope this fits well into the scope of the same issue! @vadim2404 @khanova @ololobus

We discussed with @khanova where to put it and were thinking about default_endpoint_settings.

@ololobus i suspect this will be hard to manage on per branch level for the user
i like your proposal for the bool flag for excluding non primary.
@vadim2404 , not sure that default_endpoint_settings would do what's desired
let's catch up

@ololobus what do you think about adding it to ProxyGetRoleSecret instead?
It, probably, makes more sense to be the part of authentication. Also if IP doesn't match, connection will be refused earlier.

what do you think about adding it to ProxyGetRoleSecret instead?
It, probably, makes more sense to be the part of authentication.

Yes, it does, but iirc, proxy skips this call in several cases: when password hack is used https://neon.tech/docs/connect/connection-errors#d-specify-the-endpoint-id-in-the-password-field and in http and/or serverless mode. So we will whitelist some connection, but not all, which will be strange
@conradludgate can correct me, but I think that wake is the only common call for all connection options. Otherwise, yes it'd make more sense to check ip before waiking up

proxy skips this call in several cases: when password hack is used

I'm addressing this at the moment, I'm going to make password hack not wake_compute without first authenticating

this week:
@khanova
to merge control plane PR this week
to start on proxy part this week

Project settings -> Default endpoint settings -> (allowlist + exclude non-primary branches)
formats (v4-v6): single IP, mask


Garble text in my console output.

VSCode version:1.35
Windows OS:10.0.17763
output:

'g++' �����ڲ����ⲿ���Ҳ���ǿ����еĳ���
���������ļ���

My output shows garble text when my code runs. In my preference, the file-encoding option is utf-8.
Here are my steps:
1:Code in DevC++;
2:Fall love with Visual Studio Code(VSCode and code runner plugin Installed);
3:Create a file, and write some code(printf helloworld simply), save as a cpp file ;
4:Wait for surprise and keep my heartbeat 100 times per minute;
5:No doubt, show helloworld normally;
6:Uninstall DevC++, which is the key point;
7:Run my code again;
8:As step 4;
9:Some text comes to my eyes, showing garbled in my console output;
10:WTF...search the problem everywhere, by google, er...bing as well;
11:Remember that mingw uninstalled together with DevC++;
Why there is no correct msg to tell me where went wrong. I am not able to read garble text.

How are you running your code?

How are you running your code?

Ctrl+Alt+N.
Run successfully before mingw uninstalled.

This sounds related to mingw then, and would be better posted on stack overflow where some one can help you with that.

hello! Have you solved your problem?  If yes, how?


[DOCFIX] Fix broken hyperlink in HDFS.md

alluxio-bot, merge this please

alluxio-bot, cherry-pick this to branch-2.5 please


no suggestions are shown in new terminal session

I can see the suggestions only in same session, if I quit the terminal then no suggestions are shown.

Check out my comment on #405. Are you describing the same issue?

@ericbn I followed the instructions you provided in SO page. I added:
HISTFILE=~/.zsh_history
HISTSIZE=10000
SAVEHIST=10000
setopt appendhistory

in my ~/.zshrc file, but I still can't see the suggestions.

@iiison, you mentioned a different Eric, but let me give you my two cents here.  :- )
These are the history options I use (besides HISTFILE, HISTSIZE and SAVEHIST), and they work well with zsh-autosuggestions:
setopt HIST_IGNORE_ALL_DUPS # removes older command from the history if a duplicate is to be added.
setopt HIST_IGNORE_DUPS     # does not enter immediate duplicates into the history.
setopt HIST_IGNORE_SPACE    # removes commands from the history that begin with a space.
setopt HIST_SAVE_NO_DUPS    # ommits older commands that duplicate newer ones when saving.
setopt HIST_VERIFY          # doesn't execute the command directly upon history expansion.
setopt SHARE_HISTORY        # causes all terminals to share the same history 'session'.

Is history working ok otherwise? If you press the up arrow while in your the session, do you see commands you entered in the previous session?

@ericfreese the Up arrow shows history in same window, but nothing happens in new window.

@ericbn eh, I didn't see the name, I've just typed eric 😄
I added the configs you suggested in my file, but, still it's not working.

@iiison Maybe you need to add it to your list of plugins on Line 89 of your .zshrc file.

I'm going to go ahead and close this, since it seems it's not related to this plugin, but is caused by something in your config. Get history working properly and the plugin should start working as well.

@ericfreese you were right, there was nothing wrong with zsh-autosuggestions. The problem was the zsh_history file permission. I changed the ownership to my user name from root. and now it's working fine. If anybody else faces the same issue, I used this command to change the ownership:
$ sudo chown $USER $HISTFILE


Test an example _run targets in CI

Commit Message:
Test an example _run targets in CI
Additional Description:
Test an example empty_fuzz_test_run targets with a short timeout (eg 5 seconds) in CI
Testing:
CI testing and local testing.
Docs Changes: N/A
Fixes #36
Signed-off-by: tengpeng<EMAIL_ADDRESS>modified:   .github/workflows/bazel_test.yml

Have problem installing the absl-py. Since this is not in the critical path, I will pend this issue for a little while and come back to fix this later

The codes are ready to serve. PTAL!


On the server, the tooltip on java gui is not fully working.

https://github.com/Wilyicaro/Legacy-Minecraft/assets/88715280/373b21e7-afe3-436b-86f2-0e32272a7777
The items are good.

So it's works fine, if villager not using all 9+ slots for the trade.

Fixed in version 1.6.6, thanks for reporting.


Add variable command

Codecov Report

Merging #4 (1cd0492) into main (a090cab) will decrease coverage by 5.58%.
The diff coverage is 25.55%.

@@             Coverage Diff              @@
##               main       #4      +/-   ##
============================================
- Coverage     95.30%   89.72%   -5.59%
- Complexity      299      309      +10
============================================
  Files            46       49       +3
  Lines          1002     1090      +88
============================================
+ Hits            955      978      +23
- Misses           47      112      +65

Flag
Coverage Δ

unit_tests
89.72% <25.55%> (-5.59%)
:arrow_down:

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

Impacted Files
Coverage Δ

src/Application/Command/AddCommand.php
0.00% <0.00%> (ø)

src/Dump/DumpService.php
92.30% <ø> (ø)

src/Filling/EnvFileFillingService.php
92.30% <ø> (ø)

src/Specification/Reader/SpecYamlReader.php
90.00% <ø> (ø)

src/Validation/SpecValidationService.php
100.00% <ø> (ø)

src/Manager/AddNewVariableManager.php
93.33% <93.33%> (ø)

src/Manager/AddVariableCommand.php
100.00% <100.00%> (ø)

...pecification/Reader/SpecificationReaderFactory.php
100.00% <100.00%> (ø)

src/Specification/EnvVariables.php
100.00% <0.00%> (+7.40%)
:arrow_up:


Languages that the wiki says have dictionaries don't have dictionaries

In the wiki https://github.com/soimort/translate-shell/wiki/Languages it says that languages like for example german have a dictionary, but after some tests I only saw that the dictionary feature is working in English, French and Spanish

How did you test? In the interactive shell?
I have managed to get translations in the interactive shell, but not outside.

The wiki says that German for instance has dictionary. But
trans -d de:de halo
outputs
halo

halo

However for English, Spanish and French every word outputs a list with definitions, as expected.

Just to clarify, in the Wiki, Has dictionary = Has at least a "See also" part for some common words.
$ trans de:de Welt
Welt

See also
    nicht von dieser Welt, zur Welt bringen, zur Welt kommen, am Arsch der Welt

Detailed explanation of words is most likely to be found in English, French, Spanish, Portuguese and Russian. It seems German merely has some random "See also" stuff. You may verify this through https://translate.google.com.

Ok, thank you. I think it is a bit ambiguous, since for English, Spanish and French it is an actual dictionary, it gives the meaning of the words. Maybe this should be in the wiki as a separated column. Btw, since you work with this a lot, do you know if any other translator gives definitions for other languages / do you know of the existence of offline dictionaries?

Specifically for German->English, DeepL does have a dictionary (trans doesn't support retrieving its items yet). There are also bab.la, Linguee (which covered most major European languages; none of these is supported in trans though).

I see. Thank you for your reply. I use your project as a part of mine but can only provide support for the languages I have a dictionary for. I will keep an eye on the evolution of translate shell to if there are any updates regarding dictionaries. Your project is awesome, thank you!


Update environments.md

After cracking my head and looking at the source code I found out that environment files should start with env-* and not dev-*

Good catch! Thank you :)
Can you please issue this PR against the dev branch and not the master branch? This will make it easier for me.

Done in #340


fix: Honor struct tags on WriteData and avoid panic for unexported fields

Proposed Changes
In the current implementation, the WriteData function will check the tagged structure before processing it. This has the drawback that the function will error out for invalid fields even though those fields are not meant to be exported by either being tagged lp:"-" or by not being tagged at all.
Furthermore, the current code panics for unexported fields because Interface() will panic on those fields (see documentation).
This PR moves the structure checks to a point where we can be sure that the field needs to be exported. Furthermore, the PR handles tagged unexported fields without panic.
Checklist

[ ] CHANGELOG.md updated
[x] Rebased/mergeable
[x] A test has been added if appropriate
[x] Tests pass
[x] Commit messages are conventional
[x] Sign CLA (if not already signed)

@srebhan, thank you for the PR and the fix. Great job! 👍
Are you going to fix the reported check failures?

@vlastahajek, the linter is fixed and CHANGELOG.md has been updated. Please take a look for the final review.


(vcredist2008) restore environment after installing 32bit vcredist2008

(vcredist2008) When this package is a dependency, it's install script sets the environment variable to force x86 installs.  So the dependent package then only installs the 32 bit version
Description
Restore the original value of the environment variable that is being modified ($Env:chocolateyForceX86)
Motivation and Context
this fixes the ability to install packages that depend on vcredist2008 and reliably get the x64 version installed
How Has this Been Tested?
I used choco pack to build the vcredist2008 package (i added a description to the nuspec file)
I then created a chocolatey source with only my newly built vcredist2008 package and saltminion 2019.2
With my change, salt installs the x64 version.
Screenshot (if appropriate, usually isn't needed):
Types of changes

[x] Bug fix (non-breaking change which fixes an issue)
[ ] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to change)
[ ] Migrated package (a package has been migrated from another repository)

Checklist:

[x] My code follows the code style of this repository.
[ ] My change requires a change to documentation (this usually means the notes in the description of a package).
[ ] I have updated the documentation accordingly (this usually means the notes in the description of a package).
[x] All files are up to date with the latest Contributing Guidelines
[ ] The added/modified package passed install/uninstall in the chocolatey test environment.
[ ] The changes only affect a single package (not including meta package).

:white_check_mark: Package verification completed without issues. PR is now pending human review


Error thrown when running "npm install" for ng-grid project.

Following the steps in the FIRST_TIMER.md file, when attempting to run "npm install" the following error was thrown:
npm ERR! notarget No compatible version found<EMAIL_ADDRESS><5.0.0-0'
npm ERR! notarget Valid install targets:
npm ERR! notarget ["1.1.0","2.0.9","2.0.8","2.0.7","2.1.0","3.0.0","3.0.1","3.1.0","3.1.1","3.1.2","3.1.3","3.1.4","3.1.5","3.1.6","3.1.7","3.1.9","3.1.10","3.1.11","3.1.12","3.1.13","3.1.14","3.1.15","3.1.16","3.1.17","3.1.18","3.1.19","3.1.20","3.1.21","3.2.0","3.2.1","3.2.3","3.2.4","3.2.5","3.2.6","3.2.7","3.2.8","3.2.9","3.2.10","3.2.11","4.0.0","4.0.1","4.0.2","4.0.3","4.0.4","4.0.5","4.0.6","4.1.2-beta","4.1.2","4.1.3","4.1.4","4.1.5","4.1.6","4.2.0","4.2.1","4.2.2","4.3.0","4.3.1","4.3.2","4.3.3","4.3.4","4.3.5","4.4.0","4.4.1"]
npm ERR! notarget
npm ERR! notarget This is most likely not a problem with npm itself.
npm ERR! notarget In most cases you or one of your dependencies are requesting
npm ERR! notarget a package version that doesn't exist.

When you do npm info glob do you see versions that fall within that range?  5.0.2 is the latest for glob and I see v4.4.2 out there.

Nope, max version is 4.4.1 when I do npm info glob

Maybe try cleaning your npm cache?

OK, that got me closer.  Ran npm install, bower install and then grunt, but got an error:
Loading "Gruntfile.js" tasks...ERROR

TypeError: Cannot call method 'match' of null
Warning: Task "default" not found. Use --force to continue.

Aborted due to warnings.
Ran npm update and got this error:
npm ERR! fetch failed https://registry.npmjs.org/vow/-/vow-0.4.8.tgz

Are you posting to github from the same machine that you're trying to setup the project on?
Seems like network problems, perhaps?

No response in > 2 weeks. Closing.


wireguard: minor improvements

Fine-tune the integration of the recently introduced bpf_wireguard program.
I believe it makes sense to backport this due to the NATIVE_DEV_IFINDEX part.

/test

Doing a rebase to include https://github.com/cilium/cilium/pull/34274 should be enough to fix https://github.com/cilium/cilium/actions/runs/10331644667/job/28603907089

/test


Add mypy support

Description
This PR add mypy in the .pre-commit-config.yaml and the pyproject.toml files. For now the only file checked by  mypy is gymnasium/core.py and the goal to add files incrementally and to drop pyright. The configuration added in pyproject.toml is meant for mypy to run locally, but it should be removed once every errors are gone.
Besides, some changes are added to gymnasium/core.py  to pass mypy. There are some # type: ignore because the way the class Env and the wrappers class raise errors on mypy.
The two main reasons are:

ObsType/WrapperObsType and ActType/WrapperActType  conflict
Public variables in Env that become private in the wrapper classes

Type of change
Please delete options that are not relevant.

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

Checklist:

[X] I have run the pre-commit checks with pre-commit run --all-files (see CONTRIBUTING.md instructions to set it up)
[ ] I have commented my code, particularly in hard-to-understand areas
[ ] I have made corresponding changes to the documentation
[X] My changes generate no new warnings
[ ] I have added tests that prove my fix is effective or that my feature works
[X] New and existing unit tests pass locally with my changes

Second, I see what you were mentioning about WrapperObsType etc causing issues. Is there anyway that we can specify the wrapper might return alternative types to the base environment that is valid type hinting?

The problem is that the type hinting is back propagating to the Env class.
class ActionWrapper(Wrapper[ObsType, WrapperActType]):
    """Superclass of wrappers that can modify the action before :meth:`env.step`.

    If you would like to apply a function to the action before passing it to the base environment,
    you can simply inherit from :class:`ActionWrapper` and overwrite the method :meth:`action` to implement
    that transformation. The transformation defined in that method must take values in the base environment’s
    action space. However, its domain might differ from the original action space.
    In that case, you need to specify the new action space of the wrapper by setting :attr:`self.action_space` in
    the :meth:`__init__` method of your wrapper.

    Among others, Gymnasium provides the action wrappers :class:`ClipAction` and :class:`RescaleAction` for clipping and rescaling actions.
    """

    def __init__(self, env: Env[ObsType, ActType]):
        """Constructor for the action wrapper."""
        super().__init__(env)

    def step(
        self, action: WrapperActType
    ) -> tuple[ObsType, SupportsFloat, bool, bool, dict[str, Any]]:
        """Runs the :attr:`env` :meth:`env.step` using the modified ``action`` from :meth:`self.action`."""
        return self.env.step(self.action(action))

    def action(self, action: WrapperActType) -> ActType | WrapperActType:
        """Returns a modified action before :meth:`env.step` is called.

        Args:
            action: The original :meth:`step` actions

        Returns:
            The modified actions
        """
        raise NotImplementedError

For example here, with def action(self, action: WrapperActType) -> ActType | WrapperActType:, it means that:

ActionWrapper.action(action) returns ActType | WrapperActType
ActionWrapper.env.step(self.action(action)) only take ActType as type of parameters since env is Env class

I am closing this for now as we are uncertain of mypy over pyright. This PR will be reopen if we are interested in adding it over pyright


Remove hardcoded value of PVM instance id(Service instance ID) for node and controller plugin deployment files

The value for service instance id is hard coded in the deployment files of node and controller plugins.
Need to remove the hardcoded values and fetch the value automatically from the script.

Update:

Explored CSI Driver basics
Deployed PowerVS CSI Driver in a single node Kubernetes cluster and fixed deployment issues
Passed the hostname of the pod from the deployment file and got PVM instance id by using the host name

/cc

/assign

/assign

Updates:

Explored EBS CSI Driver code and added meta service for getting the metadata information about the node
Explored RBAC in Kubernetes and setup service account, cluster role and cluster role binding for node plugin
Fixed the issue by collecting service instance id from node labels
PR is submitted


Unable to run go-spacemesh program

I downloaded the source code through github, compiled the binary file directly on the running machine, and started running. At first, I thought it was my problem. Later, I found that I downloaded the official binary package and the same error was reported.
I downloaded the config file through https://configs.spacemesh.network/config.mainnet.json without modifying any parameters.
The binary command I run looks like this:
./go-spacemesh --listen /ip4/<IP_ADDRESS>/tcp/7513 --config ./tn1.json -d ./sm_data --smeshing-coinbase wallet-address --smeshing-start --smeshing-opts-datadir ./post_data
The error log is as follows:
panic: failed to start smeshing: failed to prepare post initializer: new initializer: invalid opts.NumUnits; expected: >= 4, given: 2
goroutine 1 [running]:
go.uber.org/zap/zapcore.CheckWriteAction.OnWrite(0x0?, 0x0?, {0x0?, 0x1?, 0x0?})
/root/go/pkg/mod/go.uber.org/zap@v1.25.0/zapcore/entry.go:196 +0x65
go.uber.org/zap/zapcore.(*CheckedEntry).Write(0xc000456ea0, {0x0, 0x0, 0x0})
/root/go/pkg/mod/go.uber.org/zap@v1.25.0/zapcore/entry.go:262 +0x3ec
go.uber.org/zap.(*SugaredLogger).log(0xc00099ef88, 0x4, {0x1b8e1b1?, 0x0?}, {0xc00099f160?, 0x2?, 0x2?}, {0x0, 0x0, 0x0})
/root/go/pkg/mod/go.uber.org/zap@v1.25.0/sugar.go:316 +0xee
go.uber.org/zap.(*SugaredLogger).Panicf(...)
/root/go/pkg/mod/go.uber.org/zap@v1.25.0/sugar.go:202
github.com/spacemeshos/go-spacemesh/log.Log.Panic({0xc0008ec0e0?, {0x0?, 0x187e411214f76093?}}, {0x1b8e1b1, 0x1c}, {0xc00099f160, 0x1, 0x1})
/opt/project/go-spacemesh/log/zap.go:47 +0x1bb
github.com/spacemeshos/go-spacemesh/node.(*App).startServices(0xc000372840, {0x1ed06a8?, 0xc000908f40})
/opt/project/go-spacemesh/node/node.go:1026 +0x4a7
github.com/spacemeshos/go-spacemesh/node.(*App).Start(0xc000372840, {0x1ed06a8, 0xc000908f40})
/opt/project/go-spacemesh/node/node.go:1403 +0x15f3
github.com/spacemeshos/go-spacemesh/node.GetCommand.func1.1({0x1ed06a8, 0xc000908f40})
/opt/project/go-spacemesh/node/node.go:168 +0x377
github.com/spacemeshos/go-spacemesh/node.GetCommand.func1(0xc0002ec000?, {0x19fda3f?, 0xb?, 0xb?})
/opt/project/go-spacemesh/node/node.go:189 +0x399
github.com/spf13/cobra.(*Command).execute(0xc0002ec000, {0xc00012c010, 0xb, 0xb})
/root/go/pkg/mod/github.com/spf13/cobra@v1.7.0/command.go:944 +0x847
github.com/spf13/cobra.(*Command).ExecuteC(0xc0002ec000)
/root/go/pkg/mod/github.com/spf13/cobra@v1.7.0/command.go:1068 +0x3bd
I didn't find a corresponding solution from the documentation, and tried to find a solution from the code, but I couldn't find it. I couldn't find invalid opts.NumUnits; expected: >= 4, given: 2 from the code. Where is opts.NumUnits printed in the error message.
The hardware configuration of my machine:
cpu: Intel(R) Xeon(R) CPU E5-2678 v3 @ 2.50GHz * 2
memory: ddr4 32g * 8
disk: 480G SSD
graphics card: Nvidia RTX 3060
my binary version is v1.1.1+4441f5235007c944b369b12bd22c098106d1ad0a
my OS is 	Ubuntu 22.04 LTS
my OS kernel is 5.15.0-79-generic

@ChanQ0en thanks for the reports.
please help with debugging by sharing

binary version you downloaded and compiled
the error messages, both from compiled and downloaded binary if they are different.
your OS

it's rather difficult to investigate further without more info.

The above is the problem I am currently encountering, and I have spent 2 to 3 days and can't solve it

@ChanQ0en sorry for the lack of documentation on this. we are working on improving that.
i assumed you followed this one https://github.com/spacemeshos/testnet-guide/blob/master/cli.md#go-spacemesh-node-1.
it was written for testnet participation and is a little outdated. it says --smeshing-opts-numunits defaults to 4 but that was incorrect. the code defaults to 2.
can you try setting --smeshing-opts-numunits=4 (or the actual unit you are initializing)?

I have added --smeshing-opts-numunits=4 to the command line to execute, and the program is running, thank you very much


Upgrade cyclonedx

Instead of replacing my repo, you can create a PR against my repo so if I merge it in, updates will be available to the application

OBE


feat/mifflin equation

Story Title
Story: Perform Calculations on Input Data
Changes made

Created app/src/bmr/helpers/coefficients.py, which stores equation coefficients for HarrisBenedict and Mifflin-St. Jeor equations
Added Mifflin class that uses Mifflin-St. Jeor equation to app/src/bmr/helpers/equations.py
Created tests for Mifflin class, main.py, and modified tests for Haarris-Benedict.
The default equation in app/src/bmr/model.py is now Mifflin-St. Jeor
Added sex parameter to both HarrisBenedict and Mifflin classes. Values can be 'male' or 'female'

How does the solution address the problem
This PR enables backend use of either Mifflin-St. Jeor or Harris-Benedict equations to calculate BMR.
Linked issues
Resolves #28
Resolves #29
Resolves #30
Resolves #31
Resolves #32

CI Pipeline failed by format errors.


Surge 0.3.0 beta Random stuff I noticed

I'm not sure what's causing this difference in download. Might be something weird.
2.

I added a download and deleted it right after that and this warning showed.
3.

In "file transfers", if you arrange them by file AKA filename items on page one get arranged by filename and when you switch to page 2 they get arranged by name separately and so on. All the items should be arranged by name and then presented, not just items currently on the page.
If it were up to me I'd get rid of these pages and just have one place to show all items and then just scroll up or down to see them all.
4.

This laptops CPU is certainly not fast, but 10% usage seems a bit high, while Surge isn't really doing much, zero downloads/uploads. The number is 2-3% smaller if Surge is minimized. 21 items seeding.

Thanks for the testing!

You've likely just deleted a file from surge, there will be chunks coming in up to a minute or so for chunks requests already sent, if the file is no longer present the bandwidth is only counted towards  total client bandwidth in the bottom right.
That is expected behaviour; the error describes the consequence of your action here
We will look at sorting 👍

With regards to cpu usage, the current rendering engine seems quite inefficient, there is little we can do about that right now but it should be improved a lot with wails v2 and a chromium backend (currently IE11 engine). This also ties into our paging view; performance limitations from having a web frontend.

Thanks for the testing!

You've likely just deleted a file from surge, there will be chunks coming in up to a minute or so for chunks requests already sent, if the file is no longer present the bandwidth is only counted towards  total client bandwidth in the bottom right.
That is expected behaviour; the error describes the consequence of your action here
We will look at sorting 👍

With regards to cpu usage, the current rendering engine seems quite inefficient, there is little we can do about that right now but it should be improved a lot with wails v2 and a chromium backend (currently IE11 engine). This also ties into our paging view; performance limitations from having a web frontend.

update on 1 I now see what you mean, only 1 file is showing but all three files are actually pulling bandwidth at time of that screenshot, we will investigate.

update on 1 I now see what you mean, only 1 file is showing but all three files are actually pulling bandwidth at time of that screenshot, we will investigate.

It can't say a few seconds under remaining if the download hasn't even started yet. Certain downloads are stuck, low on seeds, but it still says a few seconds under remaining.

Now that Surge has dynamic size, the amount of items displayed should also be increased or decreased dynamically.

It can't say a few seconds under remaining if the download hasn't even started yet. Certain downloads are stuck, low on seeds, but it still says a few seconds under remaining.

Now that Surge has dynamic size, the amount of items displayed should also be increased or decreased dynamically.

Thanks for all these reports, I believe we have just finished every single one of these bugs reported. Coming in 0.3.1-beta.

Thanks for all these reports, I believe we have just finished every single one of these bugs reported. Coming in 0.3.1-beta.

Thanks for all these reports, I believe we have just finished every single one of these bugs reported. Coming in 0.3.1-beta.

Can't wait.

Thanks for all these reports, I believe we have just finished every single one of these bugs reported. Coming in 0.3.1-beta.

Can't wait.


Re-adding of public/private keys and message signing to pulse

Pretty simple changes so I don't think there's a whole lot to explain here but let me know if I've missed anything.

Awesome, thanks so much for the detailed review. Let me know if it's all good to merge now after those changes.

I don't think this is a "duh lol", the Sodium API accepts a Bytes


Is it possible to control min and max depth range in c# just like in c++ post-processing exmaple?

Hi @DecreasedPower   Provided below for your reference are images of a C# script shared by a RealSense user for defining minimum and maximum values for the depth image with the Threshold Filter post-processing filter.
https://support.intelrealsense.com/hc/en-us/community/posts/360039445773/comments/360010898533

You could alternatively define a min-max 'depth clamp' by creating a json camera configuration file (also known as a Visual Preset) and loading it into your program.  Here are examples of the code to set depth clamp min-max in a json:
"aux-param-depthclampmin": "0",
"aux-param-depthclampmax": "65536",
The easiest way to generate a json is to set the desired parameters in the RealSense Viewer tool and then use the json export button on the toolbar at the top of the Viewer's options side-panel.

Hi @DecreasedPower Provided below for your reference are images of a C# script shared by a RealSense user for defining minimum and maximum values for the depth image with the Threshold Filter post-processing filter. Left-click on the images of the script to view them in full size.
https://support.intelrealsense.com/hc/en-us/community/posts/360039445773/comments/360010898533

Wow, thanks a lot. This is exactly what I needed.

I'm pleased that the script is helpful to you @DecreasedPower
I note that you re-opened your case after closing it.  Do you require further assistance please?  Thanks!

I'm pleased that the script is helpful to you @DecreasedPower
I note that you re-opened your case after closing it. Do you require further assistance please? Thanks!

Nah, just my first time doing it)


How to Set a Street to One Way?

It seems that "One Way Street" is not supported by the Complete Street Rule.
Do you have a plan to support it?

It seems that it is currently implemented by Lane_Distribution.


hls.js: upgrade to v0.8.5

I didn't see any specific docs for how to contribute. Please let me know if there are specific steps I missed.

Thanks @daxborges
In this case it's more a case of actually testing the plugin with hls.js v0.8.5 with various streams  and scenarios to at least reduce the risk of issues or regressions with the upgraded client lib in the officially recommended latest version.
I'm currently on sick leave, so this may take while.

Makes sense. No rush. I was testing for my own needs and figured I could contribute at the same time. Feel better!


uv_pipe_open/uv_read_start regression in v1.23.1 and later

Version: v1.23.1
Platform: macOS 10.14

The following few lines (added in 40498795a and pushed to v1.23.1) seem to break uv_pipe_open() for pipes created with pipe2() / pipe():
https://github.com/libuv/libuv/blob/6dd44caa35b4697d7e8c1b9fa0ba8e95d73355de/src/unix/pipe.c#L143-L148
I found this problem trying to upgrade uvloop to v1.23.2; the test_write_pipe test crashes with "[Errno 57] Socket is not connected".  With the above few lines commented out everything works as expected.

Do you have a callstack or something more minimal? Perhaps uvloop is accidentally attempting to call poll(readable) on the pipe? macOS doesn't have a pipe2 function, but I had tested pipe to check that it set these flags correctly:
julia> r = fill(Base.INVALID_OS_HANDLE, 2);
julia> @assert ccall(:uv_pipe, Cint, (Ref{RawFD}, Cint, Cint), r, 0, 0) == 0;
julia> r
2-element Array{RawFD,1}:
 RawFD(0x00000012)
 RawFD(0x00000015)

julia> const F_GETFL = 3;

julia> mode = ccall(:fcntl, Cint, (RawFD, Cint), r[1], F_GETFL)
0 # == RDONLY

julia> mode = ccall(:fcntl, Cint, (RawFD, Cint), r[2], F_GETFL)
1 # == WRONLY

Yes, you're right, it's not those few lines that cause the error, it's an attempt to start receiving on the write-end of the pipe.  IIRC receiving on write-end is useful to receive a notification of the pipe being closed, right?
P.S. That julia repl stuff is cool!

Following up on this:
The error indeed occurs when uvloop is calling uv_read_start() on the write end of the pipe.  It does so to get a signal (UV_EOF) via the uv_read_cb when the pipe is closed.  This seems to no longer work, which is a regression, and shouldn't have been committed to a bug-fix release.
What would be the next step? Should https://github.com/libuv/libuv/commit/40498795ab457dfa3a00a5aad45ba9db3bf71588 be reverted?  Or should uv_read_start() be allowed (again!) to be called on write-only FDs in 1.23.3?  Or there's some workaround for me to use in uvloop?

Ping...

We could perhaps add that functionality, but—aside from seeming like that usage would thwart flow-control—that doesn't sound like it would be a very portable assumption. If I try just a naive test, I see that the lowest-common-denominator (a simple blocking read) immediately returns with EBADF, as I would have expected (and as that commit tries to help now implement more uniformly):
julia> r = fill(Base.INVALID_OS_HANDLE, 2);

julia> @assert ccall(:uv_pipe, Cint, (Ref{RawFD}, Cint, Cint), r, 0, 0) == 0;

julia> r
2-element Array{RawFD,1}:
 RawFD(0x00000013)
 RawFD(0x00000014)

julia> ccall(:write, Cint, (Cint, Cstring, Csize_t), r[2], "abc\n", 4)
4

julia> b = "0000"; ccall(:read, Cint, (Cint, Cstring, Csize_t), r[1], b, 4), b
(4, "abc\n")

julia> b = "0000"; ccall(:read, Cint, (Cint, Cstring, Csize_t), r[2], b, 4), b, ccall(:jl_errno, Cint, ())
(-1, "0000", 9)

Sure, but I need some solution to detect if write end is disconnected, otherwise libuv is forever broken for uvloop :(

aside from seeming like that usage would thwart flow-control

Could you please elaborate on this?

that doesn't sound like it would be a very portable assumption.

But... it always worked just fine up until bugfix v1.23.1 release.  Did we have a portability issue in libuv for all these years? IMO, v1.23.1 breaks backwards compat in a big way without offering any solution to how unbreak it.
I'll copy a few other devs just in case they can help us here: @saghul @bnoordhuis

A kind ping.  I'm not sure why this issue is being ignored.  Uvloop is a critical piece of infrastructure and it's now stuck on an old version of libuv.
Please, libuv maintainers, reply to this thread.  cc @cjihrig

I don't think it's a regression. You were relying on something that was underspecified and stopped working.
Let me see if I understand your workflow correctly. You:

have a file descriptor that's O_WRONLY.
pass it to uv_pipe_open()
then call uv_read_start() to check for EOF?

Wouldn't uv_poll_start(handle, UV_READABLE|UV_DISCONNECT, cb) work?

Thank you so much for replying!

You were relying on something that was underspecified and stopped working.

Yeah, it's not documented for libuv.  But waiting for disconnect events on O_WRONLY pipes is something that's allowed by select/poll/epoll, right?  Why is this isn't allowed in uv_read_start anymore?

Let me see if I understand your workflow correctly. You:

Correct.

Wouldn't uv_poll_start(handle, UV_READABLE|UV_DISCONNECT, cb) work?

Can I pass uv_pipe_t handle to uv_poll_start?
Ideally I'd like to use stream handles for pipes because they are faster (and more convenient) than using uv_poll* APIs manually.  A lot of code in uvloop is shared between different types of streams (TCP/Unix/Pipes); using uv_poll* for pipes would require a lot of code rewrite.

I'm sorry to be that guy, but is it possible to grab attention of one of the libuv maintainers for one hour to either fix this issue or close it?  I can't update libuv in uvloop and I'm pretty much forced to fork libuv at this point.
@bnoordhuis @saghul

Wouldn't uv_poll_start(handle, UV_READABLE|UV_DISCONNECT, cb) work?

Can I pass uv_pipe_t handle to uv_poll_start?
Ideally I'd like to use stream handles for pipes because they are faster (and more convenient) than using uv_poll* APIs manually. A lot of code in uvloop is shared between different types of streams (TCP/Unix/Pipes); using uv_poll* for pipes would require a lot of code rewrite.

Have you tested it? You can get the fd out of a handle with uv_fileno and use a uv_poll_t disposable handle just for that check. I think that would work.

Have you tested it? You can get the fd out of a handle with uv_fileno and use a uv_poll_t disposable handle just for that check. I think that would work.

I remember libuv crashing in the early days of uvloop when I tried that.  I'll try again, thanks.

Looks like it's indeed working. Thanks so much @bnoordhuis and @saghul. Closing this now.

Refs MagicStack/uvloop#317, the solution @bnoordhuis and @saghul suggested is not always working. I wrote a script below for testing, with all 3 solutions, none of them worked:

A: uv_poll_start with a new uv_poll_t on the same fd
B: uv_read_start on the same uv_pipe_t (commented out)
C: uv_poll_start on the same uv_pipe_t (commented out)

#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <uv.h>

uv_loop_t *loop;

void poll_cb(uv_poll_t* handle, int status, int events) {
    printf("poll_cb status=%d events=%d\n", status, events);
}
void alloc_cb(uv_handle_t* stream, size_t suggested_size, uv_buf_t* uvbuf) {
    uvbuf->base = malloc(suggested_size);
    uvbuf->len = suggested_size;
}

void read_cb(uv_stream_t* stream, ssize_t nread, const uv_buf_t* buf) {
    printf("read_cb nread=%zd\n", nread);
}

int main() {
    loop = uv_default_loop();

    int pipefd[2];
    if (pipe(pipefd) == -1) {
        perror("pipe");
        exit(EXIT_FAILURE);
    }

    uv_pipe_t tx;
    if (uv_pipe_init(loop, &tx, 0) < 0) {
        perror("uv_pipe_init");
        exit(EXIT_FAILURE);
    }
    if (uv_pipe_open(&tx, pipefd[1]) < 0) {
        perror("uv_pipe_open");
        exit(EXIT_FAILURE);
    }

    // A: This fails with:
    // Assertion failed: (loop->watchers[w->fd] == w), function uv__io_stop, file src/unix/core.c, line 935.
    // Abort trap: 6
    uv_poll_t poll;
    if (uv_poll_init(loop, &poll, pipefd[1]) < 0) {
        perror("uv_poll_init");
        exit(EXIT_FAILURE);
    }
    if (uv_poll_start(&poll, UV_READABLE | UV_DISCONNECT, poll_cb) < 0) {
        perror("uv_poll_start");
        exit(EXIT_FAILURE);
    }

    // B: This fails with: uv_read_start: Socket operation on non-socket
    // if (uv_read_start((uv_stream_t *)&tx, alloc_cb, read_cb) < 0) {
    //     perror("uv_read_start");
    //     exit(EXIT_FAILURE);
    // }

    // C: This fails with: Segmentation fault: 11
    // if (uv_poll_start((uv_poll_t *)&tx, UV_READABLE | UV_DISCONNECT, poll_cb) < 0) {
    //     perror("uv_poll_start");
    //     exit(EXIT_FAILURE);
    // }

    int r;
    uv_buf_t buf;
    buf.base = malloc(3);
    buf.len = 3;
    for (int i = 0; i < 65536; i++) {
        r = uv_try_write((uv_stream_t *)&tx, &buf, 1);
        if (r == 3) {
            printf("%d\n", i);
        } else {
            printf("RC %d\n", r);
            break;
        }
    }

    return uv_run(loop, UV_RUN_DEFAULT);
}

I might've done something terribly wrong here, but please kindly advise or maybe there's a solution D?
cc @1st1

@fantix Polling the same fd with two different uv_poll_t handles isn't supported at the moment, see #1172. I'd be open to a pull request that adds support for it but it's not trivial to implement, see the discussion in that issue.
There's an open pull request that makes uv_poll_start() return UV_EEXIST rather than have it fail with an assert, see #2686. That will probably show up in a libuv release in the near future.

@bnoordhuis thank you so much for the response!

have a file descriptor that's O_WRONLY.
pass it to uv_pipe_open()
then call uv_read_start() to check for EOF?

Wouldn't uv_poll_start(handle, UV_READABLE|UV_DISCONNECT, cb) work?

So if uv_poll_start() doesn't work for now, should we aim for making uv_read_start() work for O_WRONLY file descriptors again, or try to implement option 2 of #1172 still? After all, the last thing we want to do I think is to develop some custom implementation in uvloop to fork libuv in certain ways.

@fantix Multiplexing support is welcome anyway so yes, please. :-)
I'm not adamantly opposed to making O_WRONLY file descriptors work again with uv_pipe_open(), provided it doesn't need too many hacks and won't cause maintenance hassle down the road.
"Too many" is somewhat subjective but if you open a conversation starter PR, we'll take it from there.

Thanks for the suggestion! I'll try to create at least the 2nd PR to continue the discussion.


Corrects memozation of HttpHandlers.

This is in response to #3850 .
One HttpHandler instance has a connection pool, that is reused for different requests.
Currently, part of the key for the Handler memoization is the request's URL. But the URL is different for basically any request. So in this PR I am truncating the URL for the memoization key to just the host part.
I could not test it, but I assume, that things like the NTLM auth do not break by this. The docs give an example where they also only provide the host part of an URL to the NetworkCredentials.
In my tests for a paket.depedencies file which results in 75 unique packages, not downloaded, only resolved, all from NuGet.org, the current implementation opened 78 TCP connection. The implementation of this PR for the same setup only four. This is the expected amount, as per the supplied configs in https://github.com/fsprojects/Paket/blob/master/src/Paket.Core/Common/NetUtils.fs#L360

Wow. Cool stuff.
@matthid what do you think?

I'd suggest using System.Uri instead of substringing, other than that there might be a small issue when a single host has multiple feeds and multiple different credentials are used (GitHub NuGet feed for example)? I guess that use-case is quite rare but still.
Question is why the url string actually differs each time, maybe we should always use the raw feed URL here somehow and propagate it through?

You can also release this and see if someone complains...

I'd suggest using System.Uri instead of substringing, other than that there might be a small issue when a single host has multiple feeds and multiple different credentials are used (GitHub NuGet feed for example)? I guess that use-case is quite rare but still.
Question is why the url string actually differs each time, maybe we should always use the raw feed URL here somehow and propagate it through?

Using System.Uri might not be the worst idea. I chose to not do it, as it would involve creating an Uri instance every time. But this is not the hottest of paths. I can try and do some measurements, if you want me to.
The issue with multiple credentials does not arise, as this will create a different key for the memoization anyway.

Ah you are right as auth is part of the key as well. Overlooked that, nice.

Noticing a problem with this version on mono 5.4.
The restoration process freezes with output like
Possible Performance degradation, blacklist '1_https://www.nuget.org/api/v2/Packages(Id='argu',Version='3.7')'
Possible Performance degradation, blacklist '1_https://www.nuget.org/api/v2/Packages(Id='servicestack.redis',Version='4.5.4')'
Possible Performance degradation, blacklist '1_https://www.nuget.org/api/v2/Packages(Id='nbuilder',Version='4.0')'
Something went wrong while downloading dbup 3.3.5
Message: Could not download dbup 3.3.5 from https://www.nuget.org/api/v2/package/dbup/3.3.5.
  ==> Trying again
Something went wrong while downloading Microsoft.AspNet.Cors 5.2.3

The problem goes away when pinning Paket to a previous version or using mono 6.

Oh noes :(
Maybe mono's implementation of the HttpHandlers are somehow different?
Can we know in the code, which mono version we are running on and the fall back to the old implementation?

@blair55 Can you please show us the output of paket with the --verbose switch?

Sure
https://s3.eu-west-2.amazonaws.com/paket-5.248.1-verbose-log/paket-restore.log

Huh – It got some response from the API in the first place, but then just … failed?!
Can you try to use v3 of the NuGet API as a source? source https://api.nuget.org/v3/index.json @blair55


ModuleNotFoundError: No module named 'constants'

Hello, I encountered an error when running the tutorials/simulate_new_control_system.ipynb notebook.
ModuleNotFoundError: No module named 'constants'

The error occurred at the line from tutorials import van_der_pol_oscillator.
Upon inspection, I found that the constants.py file was empty. After commenting out the code
from constants import *

in the generate_model.py script, I restarted the Jupyter kernel and regenerated the tutorial files. The error was no longer occurring.

Hi @cookiegg -- thank you for bringing this issue to our attention! I've reviewed it and found that it has been fixed in a previous commit. The problem should no longer occur if you pull in the latest commit, but if that is not the case please let me know.

Thanks for the quick fix! Everything's working great now.


reload method on volumes import returns None

imp = api.imports.submit_import(volume=volume_import, project=my_project, location=bucket_location)
time.sleep(30)
#Wait until the import finishes
while True:
      import_status = imp.reload().state
imp.reload() was returning None which lead to error
this is inspite of the import actually taking place
what worked for me was:
imp = api.imports.submit_import(volume=svolume_im, project=smy_project, location=sfilename)
#Wait until the import finishes
import_status = ''
time.sleep(30)
i = api.imports.get(id=imp.id)
print i.state

@sethi7ik Will be investigated promptly. If the issue is confirmed expect the resolution and a minor version update very soon.
Thank you for catching this one!

Thanks @SenadI

@sethi7ik Fixed in v0.5.3 version.


Update install script to check for login shell

If login shell is on then copy to ~/.bash_profile, else copy to ~/.bashrc.

Hey @peterjshan
Wanna follow this up?

It's been so long. Closing the PR.


[feature]: allow saving private notes for payments

Is your feature request related to a problem? Please describe.

Payee doesn't always put a good memo or any memo at all on invoices. Payer should have the ability to add their own notes for their own records to all outbound payments, whether success or failure.

Payee wants to store more detailed information or private information that can't be placed in the memo that is shared with the payer.

Describe the solution you'd like

Add an RPC command that allows me to attach a private note for any outbound payment, while sending payment and after payment.

Allow adding a private note when creating an invoice using AddInvoice and AddHoldInvoice .

Allow querying a list of inbound and outbound payments based on their private notes.

Describe alternatives you've considered
Separate databases. These are a nuisance because they require another database, daemon, network socket, and authentication setup for all users of the LND node to also manage private notes.
Additional context
Zeus has an option to store a private note, but the data does not persist on the LND node, it is only on the phone the note is written on (https://github.com/ZeusLN/zeus/issues/2410) . This is just one example.

Allow adding a private note when creating an invoice using AddInvoice and AddHoldInvoice

How will this be different from the memo that you can add along with the invoice? Trying to understand the implication of 'private'?

Well, it won't really be part of the actual BOLT 11 invoice that is shared, just part of the local database. Anyone with an invoice macaroon on the LND node will be able to read it, but it otherwise won't be shared since there is no additional BOLT11 invoice fields to even put it in.
This field could not be private too if the payee wants to share it some other way than via BOLT 11. For example, it could also be used to store data that is too long to put in the invoice itself. We have a description_hash for longer amounts of data that can't fit in BOLT 11 invoices, but there isn't anywhere in LND to actually store the longer data that is hashed.


Fix: Wiki ALZ Azure Setup Bash command

Overview/Summary
The Azure CLI command that assigns Owner role on the Tenant root to the Service Principal is not working.
This PR fixes/adds/changes/removes
Fix the command to assign Owner role to the Service Principal.
Breaking Changes
None
Testing Evidence

As part of this Pull Request I have

[x] Checked for duplicate Pull Requests
[ ] Associated it with relevant issues, for tracking and closure.
[x] Ensured my code/branch is up-to-date with the latest changes in the main branch
[x] Performed testing and provided evidence.
[ ] Ensured contribution guidance is followed.
[ ] Updated relevant and associated documentation.
[x] Updated the "What's New?" wiki page (located: /docs/wiki/whats-new.md)

@baartch great catch, and many thanks for your contribution! In line with our contribution guidance, can I ask you to please add an entry to the "Whats New.md" for this month on the change so that others can benefit from your contribution.

Alright. I added a new entry to Whats-new.md ✌


Update file to add note on site column name change

@MikePlumleyMSFT
PR has been copyedited and is ready for final review, could you please check and merge? Thanks!


Add documentation to buildables

Sorry, I only saw this today. Could you rebase your changes onto main?

@ahoppen rebased now 👍
Should we also add documentation for init?

Should we also add documentation for init?

I’d say no because it would just be repeating information. But if you think it would add value, I’m also fine with adding it.

@swift-ci Please test

Build failed
Swift Test Linux Platform
Git Sha - 4fbd1dbeb98a9bc1daf7406f4e495a0773ac5aa9

@swift-ci Please test

Build failed
Swift Test Linux Platform
Git Sha - 3de3553c6c0f885bbb1581da30c08a73962bafed

Build failed
Swift Test OS X Platform
Git Sha - 3de3553c6c0f885bbb1581da30c08a73962bafed


Add sugar for determining the database provider in use

Part of #7166
Main scenario here is conditional behavior in OnModelCreating now that we build a different model per provider.

We should add matching sugar to MigrationBuilder. (filed #8566)

Am I understanding correctly that this won't be merged for 2.0.0? Would it be possible to specify the milestone so it's easier to understand when you guys are planning to release things?

@roji It probably will be, it's just that @bricelam created the issue and completed the work before we had a chance to triage it and put it in a milestone. He's that good. 😉

@roji Or are you asking about this PR specifically? If so, then the issue is in a milestone. We put issues in milestones rather than PRs.

@ajcvickers oh ok, thanks :) Will try to get it in for Npgsql's 2.0.0 release too then!


How to get the latest configuration information without restarting the client?

Hello, when I update the configuration file of the configuration center, I need to restart the client to take effect. Therefore, I want to ask whether this function will be implemented in the future.
thankyou

I believe the link above will help you get what you need, and I don't think there's anything else you need from us for this issue, so I'm going to close it - feel free to reopen if I did not adequately answer your question!

Hi, not OP but have the same requirement.
IOptionsSnapshot doesn't work as-is - if the configuration provider reloads then it will get any updated values, but the Steeltoe configuration provider isn't reloaded automatically.
It would be good if there was some sort of option to reload configuration automatically, it also looks like Spring Config Server supports some sort of push notification mechanism, which would be ideal.

Hi @JustinPealing,
You're right, we don't support Spring Config Server initiated reloads yet, but that is on our backlog
Until then, you have a couple options for reloading config:

Steeltoe Management 2.1.0 includes an endpoint for refreshing configuration (sorry about link to staging docs, we're in a final editing pass and the updates should get to the production site in the next couple days)
Directly calling IConfigurationRoot.Reload

Perfect - Thanks


aws_apigatewayv2_api is missing from docs

just a reminder to add it along with the next resources https://docs.driftctl.com/0.17.0/providers/aws/resources/

Looks like #191 was wrong, may be the author forgot to pull before creating the new version. I'll add it manually to v0.17.


build from source, line number did not show up on linux arm.

5.3.0-rc8-0.8-MANJARO-ARM aarch64
GCC version : gcc (GCC) 9.2.0
i successfully build lite from source. but line number is missing.
and also lite allows me to scroll beyond the content.

Did you happen to install every single plugin, including the one that hides line numbers and enables boundless scrolling?

owh, thanks.
and sorry for wasting your time.


InfiniteDataAttribute

As requested by @moodmosaic in this PR.
This attribute is intended for use in conjunction with CompositeDataAttribute:
[AttributeUsage(AttributeTargets.Method, AllowMultiple = false, Inherited = true)
public class InfiniteDataAttribute : DataAttribute
{
    private readonly DataAttribute _decorated;

    public InfiniteDataAttribute(DataAttribute decorated)
    {
        _decorated = decorated;
    }

    public override IEnumerable<object[]> GetData(MethodInfo methodUnderTest, Type[] parameterTypes)
    {
        while (true)
        {
            foreach (var dataSet in _decorated.GetData(methodUnderTest, parameterTypes))
                yield return dataSet;
        }
    }
}

The idea is that you wrap an AutoDataAttribute with an InfiniteDataAttribute so that it can provide AutoData for any number of iterations of a, xUnit Theory. This allows AutoData to be used with xUnit's PropertyDataAttribute, which currently it can't (see #354 and #356):
public class PropertyAutoDataAttribute : CompositeDataAttribute
{
    public PropertyAutoDataAttribute(string propertyName)
        : base(new PropertyDataAttribute(propertyName),
               new InfiniteDataAttribute(new AutoDataAttribute(new Fixture())))
   {
   }
}

Why is it called Infinite?

Well, it generates an infinite sequence! Alternatively, RepeatDataAttribute would also describe it well, given that it repeats?

Ah, right, I didn't notice the while(true)...
RepeatDataAttribute may be a slightly better name, in that I think it better communicates what actually goes on.

That works for me. Would it be beneficial to provide the attribute with an optional parameter int? repetitions? I'm trying to think of other cases where this might be useful.

Before we do a ton of work on this feature... Do we know how it's going to work in xUnit.net 2?
AFAIK, there's going to be breaking changes in xUnit.net 2, so perhaps we should think twice before we put a lot of work into this...

That's a valid point.
xUnit v2's DataAttribute changes the type signature of the GetData method. They have removed the array of type parameters which was the second argument to the function. I assume this is because this information is easily accessible from the MethodInfo parameter, so the second argument was redundant.
So, it shouldn't be troublesome to migrate, and given that the existing attributes (Composite, Auto, InlineAuto) must be migrated anyway, I would suggest that this could simply be added to the list when the time comes. It might be nice to offer it as compatible with xUnit v1, as I guess many people won't be migrating right away.

@alexfoxgill If you don't mind, I'm closing this issue for now. This feature looks very ad-hoc and it's purpose is not clear. The unit tests you write should be stable enough to not fail depending on the auto-generated data. If you would like to perform exhaustive check, it's probably to use FsCheck or similar tools which was designed for such purpose.
This issue existed for 2 years and during this time nobody else asked about it, which makes me confident that it doesn't cover a common usage scenario. Given that it's very easy to implement this feature in your own project, let's postpone this feature for now. If later we see that it's high-demand, we can always re-open the issue.
Alex, please let me know if you have concerns.


Enable System test on x64Windows at Adopt

Enable System test on x64Windows
Signed-off-by: Mesbah Alam<EMAIL_ADDRESS>

Windows system test builds created at ci.Adopt should be enabled by upstream Windows build jobs at Adopt. https://ci.adoptopenjdk.net/view/Test_system/

Reviewer : @smlambert

Yes, missed that! Added the trigger for jdk11.


Polyfill local storage with in memory version if local storage is in a broken state.

Fixes #1289
I'm open to other suggestions too.  Long term it would be good to display a notification to the user that they should restart their browser or something.
It would also be better to stop using local storage directly and use a modeled foam service provided via context for local storage things, but this fixes a real problem we have now finding and re-writing all localstorage usages.

How does localStorage get broken?


Make k8s URL in collector installer version-dependent, fixes #3749

fixes #3749

@jingweiz2017, this should solve your issue (#3749), @mx-psi PTAL


raspberry pi, switch, xbox and ps4 export?

I was just wondering if these were going to be supported eventually?
I want to use this engine but I also want to export to these targets.
will this be possible?

If you want to run on those platforms, you need  .net runtime(C# runtime) and complied native library

raspberry pi : Depends on the operating system you have installed, debain 8+ /ubuntu14+ have .net core and it can used Nuget can be used directly. For other linux distributions, you need to manually compile love and, as well, you need . net runtime support

switch/xbox/ps4 : i hve no idea how to export them. because I don't developed on them yet. In any case, you need the .net runtime and  complied native library which you can compile it manually. But I'm not sure you'll succeed or not.

ya I know consoles requires closed source code so you would need to make Love2dcs exensions


Add Mermaid diagram to explain SDK contents

This PR uses GitHub's native Mermaid diagrams support to add an architectural diagram of the SDK. For each "box" in the diagram, a description exists below with a link to the repository relevant to that component.
Preview

Adding moar people for more visibility into this proposed documentation update. Open to suggestions about things that can be added/removed.
Also cc @robloach and @enotick -- I can create (and was planning on doing so) a similar PR for the Drupal SDK. I don't think this info overlaps with anything that you've already written (or if it does, it probably wouldn't hurt to have a visual reference in addition).

This is so cool. Didn't know it existed 👏

@RobLoach Right? I knew about Mermaid but I wasn't aware that GitHub had natively integrated it before this week.


textFilter(text) -> textFilter(text, tagName)

https://github.com/apostrophecms/sanitize-html/compare/master...slavaGanzin:textFilterTagNameAttribute?expand=1#diff-c1129c8b045390789fa8ff62f2c6b4a9R486

@boutell Is it enough?
https://github.com/apostrophecms/sanitize-html/pull/314/commits/9d1872011e717752c8b66e4820a5d6788b82f5d3

Any reason not to merge, @boutell ?

@boutell considering this has been hanging out a while and I have another linting branch, I'd be happy to take care of that clean up prior to release if you're good with merging this.

I would appreciate that Bea!
On Fri, Mar 27, 2020 at 10:06 AM Alex Bea<EMAIL_ADDRESS>wrote:

@boutell https://github.com/boutell considering this has been hanging
out a while and I have another linting branch, I'd be happy to take care of
that clean up prior to release if you're good with merging this.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/apostrophecms/sanitize-html/pull/314#issuecomment-605019364,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAAH27JOMJQAXWR6K6YKZSLRJSXHNANCNFSM4JPBQ5TQ
.

--
THOMAS BOUTELL | CHIEF TECHNOLOGY OFFICER
APOSTROPHECMS | apostrophecms.com | he/him/his

Merge away.
On Fri, Mar 27, 2020 at 11:48 AM Tom Boutell<EMAIL_ADDRESS>wrote:

I would appreciate that Bea!
On Fri, Mar 27, 2020 at 10:06 AM Alex Bea<EMAIL_ADDRESS>wrote:

@boutell https://github.com/boutell considering this has been hanging
out a while and I have another linting branch, I'd be happy to take care of
that clean up prior to release if you're good with merging this.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/apostrophecms/sanitize-html/pull/314#issuecomment-605019364,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAAH27JOMJQAXWR6K6YKZSLRJSXHNANCNFSM4JPBQ5TQ
.

--
THOMAS BOUTELL | CHIEF TECHNOLOGY OFFICER
APOSTROPHECMS | apostrophecms.com | he/him/his

--
THOMAS BOUTELL | CHIEF TECHNOLOGY OFFICER
APOSTROPHECMS | apostrophecms.com | he/him/his


Update metadata shoutcast streams (iOS and Android)

Using version 1.1.4 of the module.
I'm already asked this but it is not really clear how we need to use the update for artist and player information using a shoutcast stream.
We can do it two ways:

extract it from the stream (so everything gets updated in the app)
using a text file which contains the information and extract changes from there using the track-player module.

But neither i'm sure how this works as the title and artist are set once and never gets updated in the module.
I created a timing script to extract it from the text file but i do not manage to update the information inside the module.
Any help is welcome

You can update the track metadata through updateMetadataForTrack:
const trackId = await TrackPlayer.getCurrentTrack();
TrackPlayer.updateMetadataForTrack(trackId, {
    title: ...,
    artist: ...
});

The function accepts any type of metadata from the track object (like artist, title, genre, album, artwork, etc).
Extracting from stream only works on Android, you have to listen to the playback-metadata-received event:
TrackPlayer.addEventHandler('playback-metadata-received', async e => {

    const currentTrack = await TrackPlayer.getCurrentTrack();
    TrackPlayer.updateMetadataForTrack(currentTrack, {
        title: e.title,
        artist: e.artist
    });

});

Hopefully this clarifies a bit.

Hi, thanks. Yes that clears it up a bit.
Do you have ideas on howto do this for iOS? As that is a problem when it does not work :(

You'll have to implement some other way around not having the playback-metadata-received event, like fetching from a server from time to time.

Sure but how do i get that updated in the module? The first time iT works but after update i’m not sure how to push iT to ios

You can setup an interval inside the player service, something like this:
module.exports = async () => {

    if (Platform.OS === 'android') {
        TrackPlayer.addEventListener('playback-metadata-received', async (e) => {
            const currentTrack = await TrackPlayer.getCurrentTrack();
            TrackPlayer.updateMetadataForTrack(currentTrack, { title: e.title, artist: e.artist });
        });
    } else {
        setInterval(() => {
            fetch(....).then(r => r.json()).then(data => {
                const currentTrack = await TrackPlayer.getCurrentTrack();
                TrackPlayer.updateMetadataForTrack(currentTrack, { title: data.title, artist: data.artist });
            });
        }, 1000 * 60); // Repeat every minute
    }

};

Tried this, but the error i receive is an immutable issue.
You attempted to set the key '_65'with the value '1' on an object that is meant to be immutable and has been frozen.
Seems i cannot update the state this way.
`async function togglePlayback() {
const currentTrack = await TrackPlayer.getCurrentTrack();
if (currentTrack == null) {
await TrackPlayer.reset();
await TrackPlayer.add({
id: 'HeteHits',
url: playerSetting.playerUrl,
title: '',
artist: '',
artwork: "https://picsum.photos/200"
});
await TrackPlayer.play();
 if (Platform.OS === 'android') {
    TrackPlayer.addEventListener('playback-metadata-received', async (e) => {
        const currentTrack = await TrackPlayer.getCurrentTrack();
        TrackPlayer.updateMetadataForTrack(currentTrack, { title: e.title, artist: e.artist });
    });
} else {
    setInterval( () => {

        fetch('https://www.hetehits.nu/json.php?type=gespeeld&limiet=1')
            .then(r => r.json())
            .then(data => {
            const currentTrack = TrackPlayer.getCurrentTrack();
            TrackPlayer.updateMetadataForTrack(currentTrack,
                {
                    title: data.nowplaying[0].artist,
                    artist: data.nowplaying[0].artist });
        });
    }, 1000 * 5); // Repeat every minute
}

} else {
  if (playbackState === TrackPlayer.STATE_PAUSED) {
    await TrackPlayer.play();
  } else {
    await TrackPlayer.pause();
  }
}

}
`

Inside the fetch, you have:
const currentTrack = TrackPlayer.getCurrentTrack();, which won't return the current track, it returns a promise instead.
You'll have to make the function handling the promise async, and then run const currentTrack = await TrackPlayer.getCurrentTrack();.

That is it indeed. Overlooked that one sigh
changed it to:
if (Platform.OS === 'android') {
        TrackPlayer.addEventListener('playback-metadata-received', async (e) => {
            const currentTrack = await TrackPlayer.getCurrentTrack();
            TrackPlayer.updateMetadataForTrack(currentTrack, { title: e.title, artist: e.artist });
        });
    } else {
        setInterval( () => {
            fetch('urltojson')
                .then(r => r.json())
                .then(async (data) => {
                const currentTrack = await TrackPlayer.getCurrentTrack();
                TrackPlayer.updateMetadataForTrack(currentTrack,
                    {
                        title: data.nowplaying[0].title,
                        artist: data.nowplaying[0].artist });
            });
        }, 1000 * 5);

and that works. Although for iOS it does. Android should be tested :)
Thanks man!

Update: Android works fine too (y)

Nice!

One little question. Can i get the track and artist also back from the TrackPlayer?
I mean, when it is set, how can i read it so i can update a text field? Or do i need to parse it twice from the web? One for TrackPlayer and one for the text field (or maybe using state?)

You can use await TrackPlayer.getTrack(await TrackPlayer.getCurrentTrack()), which will give you back the track object.

Trying to display Metadata for my stream.  I have used the following code but nothing is received.  How can I make this work ?
async function togglePlayback() {     const currentTrack = await TrackPlayer.getCurrentTrack();     if (currentTrack == null) {       await TrackPlayer.reset();       await TrackPlayer.add({         id: '1111',         url: 'http://<IP_ADDRESS>:8022',         title: '',         artist: '',         artwork: require('../assets/main_logo.png'),         duration: 0,       });       await TrackPlayer.play();       if (Platform.OS === 'android') {         TrackPlayer.addEventListener('playback-metadata-received', async (e) => {             const currentTrack = await TrackPlayer.getCurrentTrack();             TrackPlayer.updateMetadataForTrack(currentTrack, { title: e.title, artist: e.artist });         });     } else {         setInterval( () => {             fetch('urltojson')                 .then(r => r.json())                 .then(async (data) => {                 console.log(data)                 const currentTrack = await TrackPlayer.getCurrentTrack();                 TrackPlayer.updateMetadataForTrack(currentTrack,                      {                          title: data.nowplaying[0].title,                          artist: data.nowplaying[0].artist });             });         }, 1000 * 5);        }     } else {       if (playbackState === TrackPlayer.STATE_PAUSED) {         await TrackPlayer.play();       } else {         await TrackPlayer.pause();       }     }   }
Thanks for any help.  Very new to React-Native :)
This is the last thing I need to do for my App.

Hi,  I cane across this as I wanted to extract shoutcast metadata.  Your suggested code to do this includes this line from above:
TrackPlayer.addEventHandler('playback-metadata-received', async e => {
It is apprent there is no 'addEventHandler' function and my react-native-track-player is fairly fresh, ony a couple weeks old install with npm install as well as the master compressed folder from your GitHub page.  Is there by any chance you mean 'addEventListener' instead of 'addEventHandler' when coding for Android?   Thanks for developing such a high quality project!


Initial PR

Reverting a temporary commit, which deleted all code, in order to open up a PR.
This reverts commit cf25dc6705411c788dad0e91f35740ae05cb2fd7.

I agree with all of your feedback, thanks! Going to make updates accordingly right now.

@scottybollinger  Ready for a second look

@scottybollinger Good call on cleaning those tests up. Ready for another look!


chore(simulator-data): updated sample configs + data

Closes #150
Signed-off-by: Lukas Mertens<EMAIL_ADDRESS>
Stack:

#164
#161
#160
#154 ⬅
#153
#140
#139
#138
#136
#148
#135
#147
#134
#132
#129
#130
#128
#127
#126
#125
#146

⚠ Part of a stack created by spr. Do not merge manually using the UI - doing so may have unexpected results.

✓ Commit merged in pull request #164


get_parameter issue

Hello. I am not fully sure whether the issue is in this bundle or in HA Core somewhere, but for get_parameter I am getting the issue:
"HomeAssistantError: expected str for dictionary value @ data['entity_id']"
Trying to get grid_export parameter. The set_parameter is working properly, see JSON payload:
{  "device_id": "xxx",  "parameter": "grid_export", "entity_id": "input_boolean.goodwe_powerlimit" }
May I ask you to check it? v.<IP_ADDRESS>

Not needed anymore as grid_export_switch exists.


If I don't want to use IBL and just want to use skybox, how should I modify the code

If I don't want to use IBL and just want to use skybox, how should I modify the code

If you mean a normal cubemap skybox (6 textures) then the engine currently doesn't have that, I think its better do it myself since the renderer code is a bit different then the one in the repository and I'm updating it soon anyway.
If you really want to modify the code, you will have to make your own "SkyboxCube" class thats loads the shader and the textures and renderers them...etc  and then use it from the renderer class in the "Renderer::RenderScene" function, though I don't encourage you to do that :)

If I want to import the model from the outside, the model itself has texture mapping, and I changed the model.cpp and mesh.cpp, I'd like to know   render.cpp how should  be changed


:sparkles: feat: new Components Snippet

还有几个需要补充

[ ] Api Doc
[ ] Bash 的 Sinki 有点奇怪
[ ] Sinki 建议从 es 包迁移到 sinkiji ，sinki-es 用的太少了，发版也不及时

@rdmclin2  Siki 的两个麻烦哥看看。

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

Comparison is base (5c2988e) 87.43% compared to head (9621cc2) 87.40%.
Report is 9 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #97      +/-   ##
==========================================
- Coverage   87.43%   87.40%   -0.04%
==========================================
  Files         339      349      +10
  Lines       21885    22397     +512
  Branches      982     1007      +25
==========================================
+ Hits        19136    19575     +439
- Misses       2749     2822      +73

Files
Coverage Δ

src/Highlight/components/CopyButton/index.tsx
87.71% <100.00%> (+0.21%)
:arrow_up:

src/Highlight/components/HighLightJS/index.tsx
96.92% <100.00%> (ø)

src/Highlight/components/HighLighter/index.tsx
85.96% <100.00%> (+2.29%)
:arrow_up:

src/Highlight/defalut.tsx
100.00% <100.00%> (ø)

src/Highlight/demos/config.js
100.00% <100.00%> (ø)

src/Highlight/hooks/useShiki.tsx
80.00% <100.00%> (+2.22%)
:arrow_up:

src/Highlight/index.tsx
100.00% <100.00%> (ø)

src/Highlight/style.ts
100.00% <100.00%> (ø)

src/Highlight/wrapper.tsx
100.00% <100.00%> (ø)

src/Snippet/demos/index.tsx
100.00% <100.00%> (ø)

... and 9 more

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


Update aws-java-sdk-core to 1.12.397

Updates com.amazonaws:aws-java-sdk-core from 1.12.393 to 1.12.397.
I'll automatically update this PR to resolve conflicts as long as you don't change it yourself.
If you'd like to skip this version, you can just close this PR. If you have any feedback, just mention me in the comments below.
Configure Scala Steward for your repository with a .scala-steward.conf file.
Have a fantastic day writing Scala!

Adjust future updates
Add this to your .scala-steward.conf file to ignore future updates of this dependency:
updates.ignore = [ { groupId = "com.amazonaws", artifactId = "aws-java-sdk-core" } ]

Or, add this to slow down future updates of this dependency:
dependencyOverrides = [{
  pullRequests = { frequency = "30 days" },
  dependency = { groupId = "com.amazonaws", artifactId = "aws-java-sdk-core" }
}]

labels: library-update, early-semver-patch, semver-spec-patch, commit-count:1

Superseded by #423.