Proposal: "collect": dealing the error handling boilerplate from another angle

Introduction
While there sure is boilerplate about current error handling in Go, there are many things that many people like about it - Go forces programmer to think about and handle errors manually; Go treat errors as value and there is no magic about them (so exit point and flow control are very visible). That makes me think that if err != nil is not boilerplate, instead, they are needed in a lot of cases. So it occurs to me that it is not if err != nil being too much becomes boilerplate, but rather, them being too frequent is the problem.
So, what if we handle error the same way before, but just less frequently? It sounds weird, but we already has that in some idioms. In the Official Go Blog post errors are values, Rob Pike promotes an idiom where errors are collected - but not handled until all other "steps" statements. The steps are simply skipped if there is an error collected before. It seems to me a good solution to many boilerplate caused by too frequently appearing if err != nil. However, it has limited uses since "steps" may not have the same signature and writing a helper wrapper type might as well be boilerplate.
But with help of built-in magic, I think the idea of the idiom can be applied and thus improving much more cases. And I propose so.
Proposal
I propose a new built-in function called collect. The collect built-in takes three arguments: a pointer to an error, a function call, and an error wrapper. If the error held by the pointer is nil, it returns what the function call returns except the last error, which is wrapped by error wrapper and then collected to the error pointer; otherwise, it returns zero values matches the signature of function call.  collect cannot be nested - which means that collect appearing in another collect will trigger a compiler error.
An error wrapper is a function with signature func(error) error - it takes in an error and returns the wrapped error. If the wrapper is nil, the error is collected without wrapping. If in rare case that the wrapper decides to return nil, nil is collected.
In psedu-code, collect can be written like:
func collect(err *error, f func(...) ..., w func(error) error) ... {
	if *err != nil {
		return _,... // zero values
	}

	v1, v2, ..., _err := f()
	if _err != nil {
		if w != nil {
			_err = w(_err)
		}
		*err = _err
	}
	return v1, v2, ...
}

To avoid bugs from recycling error pointers, consecutive uses of collect should be considered as declaration to the errors, so it can trigger declared and not used error from the compiler.
To reduce boilerplate of writing wrapper helper function, standard library (preferably errors package) should provide factories to wrappers, such as:
func Wrapperf(format string, args ...interface{}) func(error) error {
	return func(err error) error {
		a := append(args,err)
		return fmt.Errorf(format,a...)
	}
}

Example
The example from draft design overview:
func CopyFile(src, dst string) (err error) {
	wf := Wrapperf("copy %s %s: %v", src, dst)
	var err error

        r := collect(&err,os.Open(src),wf)
        defer r.Close()

        w := collect(&err,os.Create(dst),wf)
        if err == nil {
            defer os.Remove(dst)
        }

        collect(&err,io.Copy(w, r),wf)
        collect(&err,w.Close(),wf)
        return err
}

The example of printing sum:
func printSum(a, b string) error {
        var err error
        x := collect(&err,strconv.Atoi(a),Wrapper("a"))
        y := collect(&err,strconv.Atoi(b),Wrapper("b"))
        collect(&err, fmt.Println("result:", x + y), nil)
        return err
}

As for the example using nested try,  collect shall not be nested.
The main function from rsc's unhex program can be simplified without splitting:
func main() {
    hex := collect(&err, ioutil.ReadAll(os.Stdin), nil)
    data := collect(&err, parseHexdump(string(hex)), nil)
    if err != nil {
	    log.Fatal(err)
    }
    os.Stdout.Write(data)
}

Since collect does not handle errors, language tools to deal with errors can still work well:
n := collect(&err,src.Read(buf),nil)
if err == io.EOF {
        err = nil
        break
}
collect(&err,otherStuff(),nil)

Pros and Cons

Pros:

collect does not interfere control flows (of the callers). Thus exit point remains very visible.
collect does not handle errors. Code still needs to do that to avoid compile errors. So the language still encourages (or forces) people to think about errors and handle them gracefully.
collect collects error so error handling may happen in a concentrated or unified way, which will make the happy path cleaner and more visible, and what happens to errors remain clear.
collect does only minimal work, so errors remain values and language tools to program around values can still work well.

Cons:

It does not help at all if there is only one if err != nil
It might hinder performance since there might be another function call. I am not sure whether it can be optimized by the compiler or not.

Discussion

name
Naming things is hard and I don't seem to be good at it. While collect reflects the fact that it collects error, it does not reflect the more important part: skipping function calls when error has already occured. However, how to summarize that and form a better name is beyond me.

defer and go
It is quite obvious that defer collect(...) makes no senses at all. Therefore, I think it is best to ban this kind of usage. On the other hand, go collect(...) might be valid, but it is prone to (if not always leads to) data races (on &err). Hence, I would suggest to ban this kind of use too.
One interesting case to note is needs for cases like collect(&err, defer f(), w). While it is invalid go syntax, I can think of many cases that would need it. I haven't decided whether or not to allow such uses.
If allowed, the previous example can be written as:
func CopyFile(src, dst string) (err error) {
wf := Wrapperf("copy %s %s: %v", src, dst)
var err error
      r := collect(&err,os.Open(src),wf)
      defer r.Close()

      w := collect(&err,os.Create(dst),wf)
      collect(&err,defer os.Remove(dst),wf)

      collect(&err,io.Copy(w, r),wf)
      collect(&err,w.Close(),wf)
      return err

}

for
While it is easy to use collect in a loop, there is two problems.
The first problem is that collect can only help to skip a loop if you wrap the loop into a function literal. It sure looks ugly, but maybe it is better to check errors manually before entering a loop.
The second problem is that careless use of collect might create a busy loop. Vet should handle this case.

chaining / nesting
There are two problems about chaining / nesting.
First problem is that since collect enables chaining in places like os.Open(file), it is prone to less visible need to write defer statement. But unlike try, there is at least a trace that an error is collected, which might remind the programmer to deal with it more carefully.
The second problems is that nesting/chaining obscures control flow in a hidden way - the reader (or even writer) of the code has to decide which error gets collected first since order of collecting can change behavior.
Therefore, to avoid confusing behavior, nested collect should be disabled. However, chaining, on the other hand, might be ok.

performance
It is unsure to me whether using collect would hinder performance of function calls or the compiler can optimize it.

See also #25626

Though sharing name with #25626, I would argue they are very different. This proposal does not include anything like goto, and does not require collected errors being in the same block.

This is a good use case for hygienic macros: #32620

This is an interesting proposal, but I note that it doesn't support what is by far the most common case when an error occurs: returning from the function.  It's true that if your function is all top-level calls to collect then this doesn't matter, since collect will skip execution of everything after an error occurs.  But most functions have conditionals and loops, and using those with collect will require lots of function literals, which is simply too awkward and is in fact almost like a continuation passing language.  To me those seem like fatal problems with this idea.

@ianlancetaylor Yes, it does not support returing from the function, and I deliberately propose so, since the biggest issue all error handling proposal I've seen so far has a common problem of obscuring control flow and exit points.
I am aware of collect, being a builtin and a non-returner, would not cope well with things other than basic expressions; it is not designed to do so. I justify this by saying: collect is not meant to handle error, rather, it only collects them. If there is a loop or an conditions, it would be a case that the code requires better and more dedicated error handling - by that, if err != nil and other language stuff comes to play. I would say this is a good side effects - it forces programmer to think about errors when entering more complex code blocks.
And on the other hand, I would argue that error handling before loops or conditions are unlikely boilerplate code to begin with.
However, like opionions I presented on the proposal, all these are based on experience of my own and those who are close to me, which by no means can match up the Go society; but I do not have ability to get more datas and opionions on them, so I am unclear about whether they are widely accepted or not.

Since collect returns the zeros of the function calls but does return from the function wouldn't this mean that if there is an error the flow would continue but with zeros?
Meaning if os.Open returned an error, then r would be a zero. Meaning the defer r.Close() would attempt to close a zero, maybe nil. Then io.Copy would try to copy from a zero?
r := collect(&err,os.Open(src),wf)
defer r.Close()
...
collect(&err,io.Copy(w, r),wf)

Since collect returns the zeros of the function calls but does return from the function wouldn't this mean that if there is an error the flow would continue but with zeros?

No, it skips if err is not nil. But if you stop using collect, but with the error-prone valuable, yes, it continue with zero value.

Meaning if os.Open returned an error, then r would be a zero. Meaning the defer r.Close() would attempt to close a zero, maybe nil. Then io.Copy would try to copy from a zero?
r := collect(&err,os.Open(src),wf)
defer r.Close()
...
collect(&err,io.Copy(w, r),wf)

Yes, in current form, defer r.Close() run as defer nil.Close() while the nil is a typed nil. While this is ok in os.File case, it is not very desirable. So I write in the proposal to discuss maybe it is better to allow collect(&err, defer r.Close(), wf).
And No, if r is nil, it means there is an error collected, so err is not nil - thus, there will be NO attempt to run io.Copy(w, r), so io.Copy will NOT try to copy from zero.

@leafbebop thanks for that clarification. What worries me is that after the first collect all other functions would also need a collect because if the if err != nil { skip }.  It would even be necessary on functions that cannot return an error because of the zero values.

@mvndaai I understand that. But as I say in the proposal, collect only collects error. If the logic becomes too complex to be written in collect, I think it is time to actually handle the error.
Unlike other proposals (try or others), collect does not aim to replace if err != nil, rather, it aims to accompany it.

In order to use this, essentially everything after the first call to collect has to be a call to collect.  Or has to check err != nil in which case collect didn't help us at all.
Although collect does not itself return or cause any control flow, in effect it completely obscures the control flow, because when err becomes non-nil, all future function calls do not occur, even though it seems that they do.  This will also likely cause execution to be somewhat slower.
Even in the base case, in practice every line will start will collect, making it harder to see what the function does.
If you accidentally forget a second or subsequent collect, and just call a function directly, any number of errors could occur.
-- for @golang/proposal-review


Appstudio update test-component-pac-ssct

Pipelines as Code configuration proposal

Pipelines as Code CI/test-component-pac-ssct-on-pull-request has successfully validated your commit.

StatusDurationName

✅ Succeeded
7 seconds
init

✅ Succeeded
24 seconds
clone-repository

✅ Succeeded
1 minute
build-container

✅ Succeeded
19 seconds
sanity-inspect-image

✅ Succeeded
30 seconds
deprecated-base-image-check

✅ Succeeded
3 minutes
clair-scan

✅ Succeeded
51 seconds
clamav-scan

✅ Succeeded
15 seconds
sbom-json-check

✅ Succeeded
7 seconds
sanity-label-check

✅ Succeeded
7 seconds
sanity-optional-label-check

✅ Succeeded
4 seconds
show-summary

Pipelines as Code CI/test-component-pac-ssct-on-pull-request has successfully validated your commit.

StatusDurationName

✅ Succeeded
6 seconds
init

✅ Succeeded
16 seconds
clone-repository

✅ Succeeded
30 seconds
build-container

✅ Succeeded
21 seconds
sanity-inspect-image

✅ Succeeded
20 seconds
deprecated-base-image-check

✅ Succeeded
9 seconds
clair-scan

✅ Succeeded
12 seconds
sbom-json-check

✅ Succeeded
36 seconds
clamav-scan

✅ Succeeded
11 seconds
sanity-optional-label-check

✅ Succeeded
11 seconds
sanity-label-check

✅ Succeeded
6 seconds
show-summary


irrlicht: 1.8.4 -> 1.8.5

Description of changes
Fixes #321031
Changelog: https://irrlicht.sourceforge.io/forum/viewtopic.php?f=2&t=52775

Things done

Built on platform(s)

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

For non-Linux: Is sandboxing enabled in nix.conf? (See Nix manual)

[ ] sandbox = relaxed
[ ] sandbox = true

[x] 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

[x] 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
[x] Tested basic functionality of all binary files (usually in ./result/bin/)
24.11 Release Notes (or backporting 23.11 and 24.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

[x] Fits CONTRIBUTING.md.

Add a :+1: reaction to pull requests you find important.

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

2 packages built:

irrlicht
voxelands

This pull request has been mentioned on NixOS Discourse. There might be relevant details there:
https://discourse.nixos.org/t/prs-already-reviewed/2617/1775

https://hydra.nixos.org/build/265430711
https://hydra.nixos.org/build/265390839
please mark broken on darwin

Hi, why close this PR?

I do not have a darwin machine, and thus I do not want to keep trying to fix darwin build failures. If you would like to take the work here and make it work on darwin, feel free, but I will not be doing that myself.

I neither have darwin, and consider the slow darwin CI a major obstacle to nixpkgs. The fact that i have to leave PRs alone for several days before safely merging them simply infuriates me. This is why i am so quick to suggest marking darwin broken and leaving it for others to solve.
The final suggestion i came with is to properly stop darwin builds. meta.broken expects a boolean, not a list of system strings. meta.badPlatforms on the other hand accepts a list of system strings. Yours was thing in the middle, hence why i suggested both options.

Again, feel free to submit a pr yourself using this code. I'm not saying don't merge, I'm saying that I will not deal with darwin problems when I have enough to deal with elsewhere in nixpkgs and my life. Feel free to pick this up or mark it as broken, or don't. I was doing this since I was interested in updating it, but I have no more interest in doing so, so I've closed the PR.


feat: arbitrary length tuples

BREAKING CHANGE: the various Tuple2, Tuple3, ... types have all been replaced with a single Tuple type that takes a tuple of Runtype validators.

Coverage increased (+0.002%) to 99.102% when pulling 51caa14b950f26659b23329d8610b7a87a678321 on ForbesLindesay:feat/upstream/arbitrary-length-tuples into 69b8724302ebe780270ded2b7cb94e24f3259e70 on pelotom:master.


chayang: fix typo pkgsBuildBuild -> depsBuildBuild, fix cross compila…

…tion
Description of changes

Things done

Built on platform(s)

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

For non-Linux: Is sandboxing enabled in nix.conf? (See Nix manual)

[ ] sandbox = relaxed
[ ] sandbox = true

[ ] 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.

Change was included in https://github.com/NixOS/nixpkgs/pull/260175, prolly in staging still.


connectsample command fails sending email

Sample flask command allows for connection but fails sending email returning a 404.
Also, warning issued by urllib3 about unverified https request being made.
 * Running on http://localhost:5000/ (Press CTRL+C to quit)
 * Restarting with stat
 * Debugger is active!
 * Debugger PIN: 194-413-547
<IP_ADDRESS> - - [14/Jun/2017 16:43:02] "GET / HTTP/1.1" 200 -
<IP_ADDRESS> - - [14/Jun/2017 16:43:03] "GET /login HTTP/1.1" 302 -
<IP_ADDRESS> - - [14/Jun/2017 16:43:06] "GET /login/authorized?code=OAQABAAIAAABnfiG-...969d4c517eae HTTP/1.1" 302 -
<IP_ADDRESS> - - [14/Jun/2017 16:43:06] "GET /main HTTP/1.1" 200 -
/home/pchartrand/Envs/msgraph/lib/python3.5/site-packages/urllib3/connectionpool.py:852: InsecureRequestWarning: Unverified HTTPS request is being made. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings
  InsecureRequestWarning)
404: {
  "error": {
    "code": "ResourceNotFound",
    "message": "Resource could not be discovered.",
    "innerError": {
      "request-id": "33de9b29-299f-4c48-a3b1-641d1efaa8c4",
      "date": "2017-06-14T20:43:22"
    }
  }
}
<IP_ADDRESS> - - [14/Jun/2017 16:43:23] "GET /send_mail?emailAddress=xxx%40xxx.ca HTTP/1.1" 200 -

Thanks for the feedback on this sample. The InsecureRequestWarning is due to running the sample locally over HTTP instead of HTTPS, and we didn't include instructions on configuring HTTPS locally because that would add some configuration complexity and the sample is intended to be run locally. Note that if you deploy the sample to a site with HTTPS you can configure your app with an HTTPS redirect URI (which is the recommended practice for production use) and then the error won't occur.
I've also made a change that suppresses the warning. Can you pull that latest change to connectsample.py and see if you still have an issue? FYI, I am not able to reproduce the 404 error you experienced - the sample works for me with or without that change. So if you're still having the 404 error, it would be useful to know what type of Microsoft identity you're using when you connect - i.e., whether it's an AAD work/school organization account, live.com, Hotmail.com, etc.

Thanks for the explanation. I will pull and test and then try the app over https and see if it works for me.
As for the 404 error, it does not occur when I try it with another account, so it must be related to my identity and maybe my profile settings. I normally use IMAPS with a local domain account.

The insecure warning has indeed been suppressed.
I tried again using https certificates on local flask app and by defining an https redirection url instead of a plain one in the app registration page and it works.


Validator does not consider type aliasing with structs in interface blocks

When writing structs to an SSBO this validation error triggers:
error: 196: OpStore Pointer <id> '10's type does not match Object <id> '11's type.

SPIR-V:
; SPIR-V
; Version: 1.0
; Generator: Khronos Glslang Reference Front End; 1
; Bound: 25
; Schema: 0
               OpCapability Shader
          %1 = OpExtInstImport "GLSL.std.450"
               OpMemoryModel Logical GLSL450
               OpEntryPoint GLCompute %4 "main"
               OpExecutionMode %4 LocalSize 1 1 1
               OpSource ESSL 310
               OpName %4 "main"
               OpName %8 "MyStruct"
               OpMemberName %8 0 "foo"
               OpName %10 "bar"
               OpName %11 "MyStruct"
               OpMemberName %11 0 "foo"
               OpName %12 "SSBO0"
               OpMemberName %12 0 "foo_std430"
               OpName %14 ""
               OpName %20 "SSBO1"
               OpMemberName %20 0 "foo_std430_out"
               OpName %22 ""
               OpMemberDecorate %11 0 Offset 0
               OpMemberDecorate %12 0 Offset 0
               OpDecorate %12 BufferBlock
               OpDecorate %14 DescriptorSet 0
               OpDecorate %14 Binding 0
               OpMemberDecorate %20 0 Offset 0
               OpDecorate %20 BufferBlock
               OpDecorate %22 DescriptorSet 0
               OpDecorate %22 Binding 1
          %2 = OpTypeVoid
          %3 = OpTypeFunction %2
          %6 = OpTypeFloat 32
          %7 = OpTypeVector %6 4
          %8 = OpTypeStruct %7
          %9 = OpTypePointer Function %8
         %11 = OpTypeStruct %7
         %12 = OpTypeStruct %11
         %13 = OpTypePointer Uniform %12
         %14 = OpVariable %13 Uniform
         %15 = OpTypeInt 32 1
         %16 = OpConstant %15 0
         %17 = OpTypePointer Uniform %11
         %20 = OpTypeStruct %11
         %21 = OpTypePointer Uniform %20
         %22 = OpVariable %21 Uniform
          %4 = OpFunction %2 None %3
          %5 = OpLabel
         %10 = OpVariable %9 Function
         %18 = OpAccessChain %17 %14 %16
         %19 = OpLoad %11 %18
               OpStore %10 %19
         %23 = OpLoad %8 %10
         %24 = OpAccessChain %17 %22 %16
               OpStore %24 %23
               OpReturn
               OpFunctionEnd

Generated from this glslang output:
#version 310 es
layout(local_size_x = 1) in;

struct MyStruct
{
	vec4 foo;
};

layout(binding = 0, std430) buffer SSBO0
{
	MyStruct foo_std430;
};

layout(binding = 1, std430) buffer SSBO1
{
	MyStruct foo_std430_out;
};

void main()
{
	MyStruct bar = foo_std430;
	foo_std430_out = bar;
}

The validation might be correct due to this wording
Pointer is the pointer to store through. Its type must be an OpTypePointer whose Type operand is the same as the
type of Object.

but I'm not sure how this would interact with everything else.

Not a bug -- this is the spec's intent. %11 and %8 are different types, despite having the same structure.
Note that type IDs must be unique for non-structure types.

Hm, my previous comment got lost. 😕
This is not a validator bug -- %11 and %8 are different types, despite having identical members.

I am not sure how storing structs to SSBO would be possible in this case though. Or perhaps that is defined to not be possible ... At any rate, I have opened a glslang ticket about this instead.

I agree this is a glslang bug -- it should simply reuse a single struct type for foo* and bar.  I can't think of a reason why it couldn't. That would generate valid SPIR-V functionally equivalent to the GLSL above.

I agree this is a glslang bug -- it should simply reuse a single struct type for foo* and bar.  I can't think of a reason why it couldn't.

In this case it might be okay, but in the general case, the struct has two different layouts, one for each block it is in.
So, it is the same type at the GLSL level, but not at the SPIR-V level, which means a full implementation of GLSL->SPIR-V needs to copy member-by-member, not as a whole object.

Ah, good point -- thanks, @johnkslang.


I hope I can do not need to mybatis XML configuration file database operation, simply by javaBeanannotations.

I hope I can do not need to mybatis XML configuration file database operation, simply by javaBean annotations.
You can refer to the following framework:https://github.com/nutzam/nutz

Hi @TonyYule, like JPA ?

Yes, I want the framework can provide CRUD operation; As well as the paging; Custom SQL does not require XML configuration file defines methods to SQL

Hi @TonyYule ,
Actually you can definitely use Java base configuration, please refer to this, where I use pure Java based way as Mybatis configuration

@Rugal I just want a framework,Web Framework(Mvc/Ioc/Aop/Dao/Json) for ALL Java developerlike nutz

@TonyYule so go for it. Or Play might be another choice.

What you are looking for is a full stack framework.
MyBatis is a SQL mapper framework.

why MyBatis  must use mapper XML?Why MyBatis  is no DAO batch add, delete, modify, query?

@TonyYule ,
Your question is 'Why MyBatis does not generate SQL automatically', I presume.
It is because MyBatis is taking a different approach for managing SQL.
Instead of auto-generating SQLs under the hood, MyBatis is designed to allow developers to manage their SQLs transparently (it would be obvious, but the design decision was made by the founders, not by me).
p.s.
There is MyBatis Genrator that can generate CRUD SQLs.


Create new workitem page takes too long to appear

Steps to reproduce -

Click on create work item button
Select any work item type
Wait for 3 secs

1.. 2.. 3.. Tada!! The new work creation page appears after 3 sec.

Tracking via https://openshift.io/openshiftio/openshiftio/plan/detail/1548


Spikeextractors interfaces deprecation warnings

Motivation
Adding DeprecationWarnings to all interfaces.
Checklist

[X] Have you thoroughly read our Developer Guide?
[X] Have you ensured the PR description clearly describes the problem and solutions?
[X] Have you checked to ensure that there aren't other open or previously closed Pull Requests for the same change?
[X] If this PR fixes an issue, is the first line of the PR description fix #XXX where XXX is the issue number?
[X] Did you update the CHANGLOG.md file on your branch to describe your changes?

Looks like this and anything else will need #268 merged beforehand


pom.xml:373-377: Upgrade qulice to latest 0.17.x and if...

The puzzle 837-241b1372 from #837 has to be resolved:
https://github.com/yegor256/takes/blob/c8f3ef2740506815b9c6398f50fb968462ee17d4/pom.xml#L373-L377
The puzzle was created by Victor Noël on 28-Nov-18.
If you have any technical questions, don't ask me, submit new tickets instead. The task will be "done" when the problem is fixed and the text of the puzzle is removed from the source code. Here is more about PDD and about me.

@paulodamaso/z please, pay attention to this issue

Job #880 is now in scope, role is DEV

The job #880 assigned to @victornoel/z, here is why; the budget is 30 minutes, see §4; please, read §8 and §9; if the task is not clear, read this and this; there will be a monetary reward for this job

@0crat wait for teamed/qulice#953 to be fixed

@0crat wait for teamed/qulice#953 to be fixed (here)

@victornoel The impediment for #880 was registered successfully by @victornoel/z

@victornoel You can exceptionally set checkstyle @checkstyle <check> (n lines) annotation to ignore some check in the next lines, so you should set this if you want to get your ticket moving before https://github.com/teamed/qulice/issues/953 is fixed.

@paulodamaso good point, I completely forgot about that :) thanks!

@paulodamaso the PR is #886, teamed/qulice#953 was fixed :)

The puzzle 837-241b1372 has disappeared from the source code, that's why I closed this issue.

@0pdd the puzzle #894 is still not solved.

The job #880 is now out of scope

@0crat quality good

@0crat quality good (here)

@ypshenychka The project doesn't have enough funds, can't make a payment

@0crat quality good (here)

@ypshenychka The project doesn't have enough funds, can't make a payment

Order was finished, quality is "good": +35 point(s) just awarded to @victornoel/z

Quality review completed: +8 point(s) just awarded to @ypshenychka/z

@0crat quality good (here)

@ypshenychka The project doesn't have enough funds, can't make a payment

@0pdd the puzzle #unknown is still not solved; solved: #1128.


Could not load libMaxPayne.so

Hi
I followed your instructions but I have this error when I try to start to game from hbmenu
Here is the maxpayne folder on my switch sdcard
https://imgur.com/a/MTNyAcJ

That libMaxPayne.so is extremely small. Should be around 13MB, yours is closer to 1MB. You sure it didn't get corrupted during transfer or something?

You were right about libMaxPayne.so although I keep having the same error.
How can I provide a useful log ?

What's the size of it now?

14,3MB

The exact size should be 14 314 072 bytes. That error can only indicate one of three things:

it can't find the .so file;
the .so file is corrupted;
you got the wrong version of the .so file.
If you were copying files from OSX or something, try unsetting the archive flag on all the files inside the folder.

I downloaded the apk from here https://apkvision.com/download/?item=52962&to=files_url so it should be the right version
Let's assume it's not corrupted, the correct path for the file is /switch/maxpayne/libMaxPayne.so right ?

Please don't post links to copyrighted material. The path is correct. I don't know what to tell you then. exfat memes?

Here, try this. It should produce a log file called debug.log in the game folder.
max_nx.zip

I tried starting all over again but still no luck
Here's what's inside the debug file
screen mode: 1280x720
heap size = 524288 KB
lib base = 0xa07800000
lib max = 0 KB

Are you running the game from the album?

It's not even showing in the album, the only way to run the game I have for now is through hbmenu
Wouldn't it solve things to place the nro file in /switch and let it browse files from /switch/maxpayne ?

The log is literally reporting that you have 0KB free memory after the newlib heap is allocated. I've only had this happen when running the game through the album override. What are you using to run hbmenu?

SXOS ?

I have no idea how exactly it's set up in SX OS, but it would seem that it runs in applet mode. Does it provide game override functionality? Like "hold R while launching a game to enter hbmenu"? You should use that if it does. If it doesn't, maybe try this.

Ok so I install hbmenu from your link, ran it while holding R and I get the same error except that this time debug.log shows this
screen mode: 1280x720
heap size = 524288 KB
lib base = 0x1ff1a9000
lib max = 2826588 KB

Here, this should give a bit more debug info. Nuke the old log and try running this NRO.
max_nx2.zip

ok I finally got it working !!!
thanks a lot for your help, you made my weekend :)

Well, that's weird. What was the problem?

libMaxPayne.so got deleted at some point for no reason


About separation models &  image to video

hi
I have looked at the model and it is a really powerful model
But the problem is in merging the models together, this consumes a lot of gpu power.
If it is possible to separate the models from each other, such as the image generator alone and the video alone When you separate  the models, they can even be used in regular devices such as the RTX 4090 24GB.
And I hope to add a separate model from image to video, this model is in high demand, but all the models available so far are somewhat weak and not of high quality and stable in the movement of people or physics

We currently release models for image generation and vision language understanding separately. The model shards (model-00001-of-00007 to model-00007-of-00007) are split by transformers automatically.
Our model contains 8B parameters and can run on a 40GB device with bfloat16 precision. The VL model can be deployed across multiple devices using the multi-GPU deployment feature provided by the transformers. However, the image generation model still has device mismatch issues due to the use of Classifier-Free Guidance (CFG) when using multi-device deployment and we are still working on it.
Besides, our Emu3 paradigm natively support image to video tasks since we predict the video frame by frame, token by token and we'll release the video generation model in the future. Please stay tuned for updates.


Fixing BelongsToThrough Error

After integrating \Znck\Eloquent\Relations\BelongsToThrough to support this relation when saving a form, an error arises if this relationship is utilized in the form.
The error specifically pertains to a 'Call to undefined method Znck\Eloquent\Relations\BelongsToThrough::associate().' Some individuals in the Discord community have also reported encountering this problem.
In my opinion, the best suggestion would be to examine the saveRelationshipsUsing() method. It seems that there is no method to prevent this incorrect association, as this relation does not require an 'associate' or 'sync' method, similar to belongsToMany. To resolve this issue, I added some lines in select.php, and since then, the problem has not recurred.

Description

[ ] Visual changes (if any) are shown using screenshots/recordings of before and after.

Code style

[ ] composer cs command has been run.

Testing

[ ] Changes have been tested.

Documentation

[ ] Documentation is up-to-date.

Could you please open a bug report with a reproduction repository, so I can double check this is the correct approach?

Okay, I've had a think about this, I think you're right. Thanks


[Redmine] Allow to explicitly set "assignee"

Extension
https://www.raycast.com/jwickers/redmine
Description
Currently, the extension uses the <<me>> assignee value. However, some companies (mine included) assign people to groups that act as triage/backlog for available issues to work on next. In these situation, <<me>> also includes the issues in those groups. I would like to be able to specify the assignee value to be my name so that I only see the tickets I am actively assigned.
Who will benefit from this feature?
Anyone whose companie abuses Redmine in this way (which is currently 100% of the companies that I have worked for that use Redmine)
Anything else?

If I did the development and submitted it as a PR, would it be looked at for potential merging? I am willing to do it, but don't want to have it sit around.

If I did the development and submitted it as a PR, would it be looked at for potential merging?

Sure, it shouldn't be too hard to do as well.


Display mode minimal doesn't work in PaneDisplayMode.auto🐛

Describe the bug
When the displayMode: PaneDisplayMode.auto in Navigation Pane is used and the window becomes very narrow, the display mode should actually be switched to minimal. The burger button disappears.
When the  displayMode: PaneDisplayMode.minimal is used, everything is fine.
To Reproduce
pane: NavigationPane(
header: Padding(
padding: const EdgeInsets.only(left: 20),
child: DefaultTextStyle(
style: FluentTheme.of(context).typography.title!,
child: const Text('Flutter Desktop'),
),
),
items: [
....
],
selected: _currentIdex,
displayMode: PaneDisplayMode.auto,
...
),
Expected behavior
The hamburger button appears and the menu can be folded out.
Screenshots
With  displayMode: PaneDisplayMode.auto:

This is how it should be:

Sorry I've found the solution in 4.0.0-pre0


Use Vectorized Flags for all as Release with Intel

This PR makes the Release flags of GEOS using the Intel compiler the same as the Vectorized flags currently used for FV3. In testing this has been shown to (miraculously?) be zero-diff and faster! Testing shows about 10% faster. Looking at the instantaneous run throughput timer of the 19:45:00 step (in model days/wall day):

Resolution
Stock Release
Vect Everywhere

C90 L72
264.9
285.0

C90 L181
110.7
122.2

C360
150.2
162.9

C720
62.2
67.6

I'm doing a few more tests, but it seems interesting. That said, I'm not sure I can guarantee zero-diff, but so far it seems to be for the GCM.
CC @aoloso @sdrabenh @wmputman @gmao-rreichle

@mathomp4, I can't pretend to understand any of the details here, but I'm intrigued by "0-diff and faster".  I assume this hasn't been tested for GEOSldas yet.  Please work with @biljanaorescanin to see what this might do to GEOSldas.  Thanks.

@mathomp4, I can't pretend to understand any of the details here, but I'm intrigued by "0-diff and faster". I assume this hasn't been tested for GEOSldas yet. Please work with @biljanaorescanin to see what this might do to GEOSldas. Thanks.

@gmao-rreichle Indeed. I'm still testing with the GCM. But I can work with @biljanaorescanin do some tests with it. Maybe see  what happens!


Question: does it reads only PR titles or also commit text?

Hi! I didn't understand if this action reads only PR titles or also commit text? Consider the scenario where I work alone and I don't make PR to my main branch, but just push everything directly.
Thanks.

You can benefit the most when having PRs for this action. Given PRs offer labels and more.
That being said. There is a commitMode (please find it int he README) - which will use the commits instead.
Please be aware that various features won't be available for the commit mode, as that information will not be available for commits.
There's for example a test case using emojis to categorize commits instead:
https://github.com/mikepenz/release-changelog-builder-action/blob/a048629d81890c1416f94f8a3d8879780a1758a7/__tests__/releaseNotesBuilder.test.ts#L221-L246
(using a label extractor to get a label based on the commit: https://github.com/mikepenz/release-changelog-builder-action/blob/a048629d81890c1416f94f8a3d8879780a1758a7/configs_test/configuration_commits_emoji.json#L25-L30)


Avoid registering generated interfaces as a rosidl_interfaces resource

Fixes ros2/rmw_dds_common#8.
Depends on https://github.com/ros2/rosidl/pull/454.
It avoids registering the generated interfaces as an ament roidl_interfaces resource.
SKIP_INSTALL option can't be used, as rmw_fastrtps_cpp and rmw_fastrtps_dynamic_cpp need to use the generated interfaces.
See https://github.com/ros2/ros1_bridge/pull/252.

An introspection tool might just want enumerate all installed / registered interfaces. With this change these interfaces would be hidden which I don't think is the right approach.

An introspection tool might just want enumerate all installed / registered interfaces.

I think it's better if it's not listed.
The interface is only intended to be used by a rmw implementation and not by the end user.

Moreover, typesupports for only some rmw implementations are being generated --the ones that use rmw_dds_common: rmw_fastrtps_cpp and rmw_fastrtps_dynamic_cpp--.
If an user would try to use these messages above rcl with a different rmw_implementation, they will have a problem.

Closing in favor of https://github.com/ros2/rosidl_typesupport/issues/50#issuecomment-611657663


Autoloading Strategy for AWS SDK Ruby

What are we trying to accomplish?
Ref: https://github.com/Shopify/rails-infra/issues/735#issuecomment-2278170882
This PR introduces an autoloading strategy for the top-level service modules in the AWS SDK for Ruby. Specifically, we're updating the service_class template, which generates the main entry point for each AWS service module. Our goal is to significantly improve performance by reducing memory footprint and speeding up gem require times.
Key Changes:

service_class.rb and service_class.mustache are updated to use autoload instead of require_relative. Other templates that are explicitly loaded in service_class.mustache also are updated.
Updated codegen to implicitly require customizations directly into resources if the file exists.
Implemented autoloading within services' customizations.rb, which is directly required in all service classes.

The PR is structured in two commits to facilitate review:

Core changes to implement autoloading
Resulting codegen updates

Benchmarks
Require Time

Metric
Before
After
Improvement

require 'aws-sdk-core'
346.2ms
69.6ms
5x faster

Benchmark Script
require 'benchmark'

Benchmark.bm do |x|
  x.report "require 'aws-sdk-core'" do
    require 'aws-sdk-core'
  end
end

Memory Allocation

Metric
Before
After
Improvement

Allocated memory
7,358,751
102,755
98.6% reduction

Allocated objects
65,949
978
98.5% reduction

Memory Profiler Script
require 'memory_profiler'

report = MemoryProfiler.report do
  require 'aws-sdk-core'
end

puts report.pretty_print

Impact and Next Steps
We've tested these changes against the Shopify codebase to ensure compatibility and performance gains.

Shopify-related context ‼ This will not be included in the upstream PR ‼
Performance
Shopify/shopify require times on boot

Perf Script
# typed: true
# frozen_string_literal: true

require "benchmark"

original_require = Kernel.method(:require)

$require_times = {}

Kernel.define_method(:require) do |name|
  result = nil
  time = Benchmark.measure do
    result = original_require.call(name)
  end
  $require_times[name] = time.real * 1000 if result
  result
end

require_relative "config/environment"

puts "slowest requires:"
$require_times.sort_by { |_, time| -time }.each do |name, time|
  next unless name.include?("aws")

  puts format("%-60s %10.4f", name, time)
end

(filtered to match 'aws' string in path)
Before upstream changes:
slowest requires:
.gem/ruby/3.3.4/gems/aws-sdk-s3-1.156.0/lib/aws-sdk-s3.rb   116.2510
.gem/ruby/3.3.4/gems/aws-sdk-kms-1.88.0/lib/aws-sdk-kms.rb    87.8880
.gem/ruby/3.3.4/gems/aws-sdk-core-3.201.3/lib/aws-sdk-core.rb    81.8630
.gem/ruby/3.3.4/gems/aws-sdk-core-3.201.3/lib/seahorse.rb    11.7600
.gem/ruby/3.3.4/gems/aws-sigv4-1.9.1/lib/aws-sigv4.rb     5.4330
.gem/ruby/3.3.4/gems/aws-sdk-s3-1.156.0/lib/aws-sdk-s3/plugins/access_grants.rb     5.1740
.gem/ruby/3.3.4/gems/aws-sdk-core-3.201.3/lib/aws-sdk-core/json/oj_engine.rb     4.0130

After upstream changes:
slowest requires:
.gem/ruby/3.3.4/bundler/gems/aws-sdk-ruby-bc9465c04b90/gems/aws-sdk-s3/lib/aws-sdk-s3.rb    14.4170
.gem/ruby/3.3.4/bundler/gems/aws-sdk-ruby-bc9465c04b90/gems/aws-sdk-kms/lib/aws-sdk-kms.rb    13.9460
.gem/ruby/3.3.4/bundler/gems/aws-sdk-ruby-bc9465c04b90/gems/aws-sdk-core/lib/aws-sdk-core.rb     7.1620
.gem/ruby/3.3.4/gems/aws-sigv4-1.9.1/lib/aws-sigv4.rb     6.3620
.gem/ruby/3.3.4/gems/aws-partitions-1.963.0/lib/aws-partitions.rb     1.6260
.gem/ruby/3.3.4/gems/googleauth-1.11.0/lib/googleauth/external_account/aws_credentials.rb     0.7160
.gem/ruby/3.3.4/gems/aws-eventstream-1.3.0/lib/aws-eventstream.rb     0.6840
.gem/ruby/3.3.4/bundler/gems/aws-sdk-ruby-bc9465c04b90/gems/aws-sdk-core/lib/seahorse.rb     0.2430

Speedscope
~250ms average improvement
Before:
~3.69s, GC ~465ms
(Avg, max is ~4.5s)

After:
~3.42s, GC ~435ms

These changes have passed CI

I just paired with @gmcgibbon on this. Here's my next steps in the morning:

Speedscope screenshots are okay to go in the upstream description
Propose as part of the PR a railtie (if Rails is defined) that will allow eager_loading AWS still in production environments or when it's turned on

@gmcgibbon  I split the commits up, but I do see your point that the first commit has the code directly linked to generation tied in with other manual fixes like customizations.rb, which I suppose could be a separate commit too

code for generation
generated code

I'll also make the naming explicit - bundle exec rake build (the command to autogenerate) could more directly be Autogenerated code

I mainly meant the last commit had template edits and generated code. That could be split in two because it adds a lot of railties.

cc @gmcgibbon

https://github.com/Shopify/aws-sdk-ruby/pull/2/commits/95be602ae5ee6fb2132836f43027815300f7ae8d

Just looked through the commits again. Really like this improvement.


Muzei Archive site does not load: No 'Access-Control-Allow-Origin' header

When going to http://muzeiapi.appspot.com/archive/2016/8
I receive the following errors in the Console and nothing loads:
XMLHttpRequest cannot load http://storage.googleapis.com/muzeifeaturedart/archivemeta/20160819.txt. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://muzeiapi.appspot.com' is therefore not allowed access.
XMLHttpRequest cannot load http://storage.googleapis.com/muzeifeaturedart/archivemeta/201607.txt. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://muzeiapi.appspot.com' is therefore not allowed access.

No pictures on the web still :(

Whoops, I wonder what happened there :-/ Will look into it asap.

Oh, that's the problem, you need to access it from muzei.co instead of muzeiapi.appspot.com... http://www.muzei.co/archive/


Cannot Get Window Unit In App

I'm not sure if you can help with this or not but I've been trying to get my window unit to install in the GE or SmartHQ apps and neither will install. It adds it to the network but then says that it cannot find the device in the cloud and to try and relaunch the app. I have it in  Home and it's functional but with minimal settings. Do you know of a way to get it to pull install it into the app or possibly another way of installing it into home assistant? I was thinking it was a blocked port but I set it in my DMZ just to make sure and it still fails. Thanks for any help and for putting out good code! No issues installing it into HACS and getting it integrated. Just don't have anything in the app for it to integrate.

Only thing I ran into was that it didn't really like having a 5g and 2.4g network named the same thing, so I isolated all my devices onto a 2.4g network and it's been pretty stable.  I don't really have another way to get it integrated, we're leveraging their device management infrastructure unfortunately.

Isn't complete so shouldn't be closed

This is outside the scope of this integration.  Once you can get your appliances added to the official app, it should work with the integration.  If the integration doesn't work after adding to the official app, please open a new issue.


v0.9.0 broke my CI , needed to revert to 0.8.4

Hi folks,
First of all, thanks so much for your amazing software.
Today, I got completely puzzled because my CI stop working with tox giving me this error:
/tmp/tmpo4js6lp2: 1: export: .: bad variable name , you can see it here in the github actions.
I needed to go dep by dep looking for which one of it had been updated in the last week because everything was working until some days ago. Finally, I found tox-conda had been updated during these days to 0.9.0.
This commit was working 6 days ago.
I am now merging this PR
to reproduce the error:
# clone the repo
conda create --name sometestenv python=3.9 pip setuptools wheel tox=3.24.4
tox -e py39

After that, you can change the line in tox.ini removing the version number
requires=tox-conda==0.8.4 to requires=tox-conda
Hope this helps,
Cheers,

Duplicate of #115.


Carousel View requires FrameLayout has parent

When calling setIndicatorMarginVertical() it crashes with the following exception. It does not happen when setting the indicator margin attributes in the layout file.
Caused by: java.lang.ClassCastException: android.widget.RelativeLayout$LayoutParams cannot be cast to android.widget.FrameLayout$LayoutParams
at com.synnapps.carouselview.CarouselView.setIndicatorMarginVertical(CarouselView.java:450)

Here's the stack trace when using version 0.1.4:
java.lang.ClassCastException: android.widget.RelativeLayout$LayoutParams cannot be cast to android.widget.FrameLayout$LayoutParams at com.synnapps.carouselview.CarouselView.setIndicatorMarginVertical(CarouselView.java:456)


Continue processing even if one process is crashing

Because of https://github.com/courtois-neuromod/anat-processing/issues/17, every time i run the pipeline it eventually crashes, which makes the addition of processes difficult: i cannot test them because the pipeline crashes before...
@agahkarakuzu is there a way to ignore crashes of a process/subject?

for now my workaround is to rename the problematic subject as "_sub-06_ses-002_rec-dis2d_bp-cspine_T2w.nii.gz" so it is ignored...

@jcohenadad you can see the error handling strategies here.
errorStrategy 'ignore'

Adding this directive to the process description (i.e. in a module) could achieve that.

SCT is no longer using Nextflow, closing the issue.


README link includes incorrect domain

Great project!
Just noticed the README has a link that's broken. I would've opened a PR but it'd be a bogus reason for me to show up under Contributors.
- # [web3 is going just great](https://web3isgoingjustgreat.com)
+ # [web3 is going just great](https://web3isgoinggreat.com)

Cheers!

Resolved in 9fcee989e12b070299de0ef22c1b2da3be36dbf5, thanks Nick! 👋


In admin pannel create a option for create blog

http://localhost:3000/admin opens an admin dashboard there needs a  create blogs option.
on click to this option should open an editor

#9  also related to this issue

Changes Required:

In Left hand sidebar need a create Blog Option


Create bundle for bundle-community target

bundle-community target was only appending info to the bundle

/test 4.13-openshift-e2e
/test 4.14-openshift-e2e

pressed enter too fast
/lgtm
Giving others a chance to review as well, feel free to unhold
/hold

/retest


Add TS1 mechanism configuraiton and initial condtions

Add TS1.zip as an example that can be retrieved by the API
Acceptance criteria

in interactive/api/static/examples a new folder for TS1 is created with the proper mechanism and conditions
api/load-example?example=TS1 returns the TS1 configuration

Here is the test URL on my Docker installation:
http://localhost:8000/api/load-example?example=TS1
You should see some JSON that is the contents of the files I have placed in:
C:\2024\MusicBox\music-box-interactive-api\interactive\api\static\examples\TS1>

Branch add-TS1 is pushed, merged, and pruned.
https://github.com/NCAR/music-box-interactive-api/pull/421
TS1 runs to completion with MusicBox and produces CSV output. We temporarily removed the initial conditions, and the output values are all zeros (except for temp 206.6374 and press 6152.05).


Blurry thumbnail on blog listing

This image looks good on the homepage:

But on the blog listing page it looks blurry:

It's especially bad at narrower viewport widths:

OK fixed.

do we need to regenerate thumbnails again?


K3S 0.8.1: Server log level seems to default to TRACE level

Describe the bug
The syslog logfile on my master node is flooded with TRACE log files from K3S.
I don't know how to change it back to WARN or INFO. I tried the k3s SERVER -v 0 value, but this doesn't seem to affect the logging verbosity. -  It turned out that when i started Prometheus, the logging starts, however i still would like to know how to stop logging TRACE messages :-)
To Reproduce
I upgraded from 0.6.1 to 0.8.1
Expected behavior
Log level is default (info or warn), or an instruction is required on https://rancher.com/docs/k3s/latest/en/configuration/ how to change the logging to something less chatty.
Screenshots
A part of my log file:

Aug 24 22:25:17 domotica-04 k3s[32334]: E0824 22:25:17.596207   32334 status.go:71] apiserver received an error that is not an metav1.Status: &errors.errorString{s:"context canceled"}
Aug 24 22:25:17 domotica-04 k3s[32334]: I0824 22:25:17.597873   32334 trace.go:81] Trace[2048830714]: "Patch /api/v1/nodes/domotica-07/status" (started: 2019-08-24 22:25:09.248662863 +0200 CEST m=+559.935042797) (total time: 8.349088647s):
Aug 24 22:25:17 domotica-04 k3s[32334]: Trace[2048830714]: [522.13879ms] [515.912678ms] About to check admission control
Aug 24 22:25:17 domotica-04 k3s[32334]: Trace[2048830714]: [8.349088647s] [7.826949857s] END
Aug 24 22:25:17 domotica-04 k3s[32334]: I0824 22:25:17.756231   32334 trace.go:81] Trace[162800240]: "SQL DB QueryContext query: SELECT id, name, value, old_value, old_revision, create_revision, revision, ttl, version, del FROM key_value WHERE name = ? ORDER BY revision DESC limit ? keys: [/registry/masterleases/<IP_ADDRESS> 1]" (started: 2019-08-24 22:25:16.19860096 +0200 CEST m=+566.884981769) (total time: 1.556530473s):
Aug 24 22:25:17 domotica-04 k3s[32334]: Trace[162800240]: [1.556530473s] [1.556530473s] END
Aug 24 22:25:17 domotica-04 k3s[32334]: I0824 22:25:17.883792   32334 trace.go:81] Trace[210670162]: "SQL DB QueryContext query: SELECT id, name, value, old_value, old_revision, create_revision, revision, ttl, version, del FROM key_value WHERE name = ? ORDER BY revision DESC limit ? keys: [/registry/minions/domotica-07 1]" (started: 2019-08-24 22:25:15.967138441 +0200 CEST m=+566.653518167) (total time: 1.916338725s):
Aug 24 22:25:17 domotica-04 k3s[32334]: Trace[210670162]: [1.916338725s] [1.916338725s] END
Aug 24 22:25:17 domotica-04 k3s[32334]: I0824 22:25:17.989664   32334 trace.go:81] Trace[1931520310]: "SQL DB QueryContext query: \nSELECT kv.id, kv.name, kv.value, kv.old_value, kv.old_revision, kv.create_revision, kv.revision, kv.ttl, kv.version, kv.del\nFROM key_value kv\n  INNER JOIN\n    (\n      SELECT MAX(revision) revision, kvi.name\n      FROM key_value kvi\n\t\t\n        GROUP BY kvi.name\n    ) AS r\n    ON r.name = kv.name AND r.revision = kv.revision\nWHERE kv.name like ?  ORDER BY kv.name ASC limit ?\n keys: [/registry/controllers% 1000000]" (started: 2019-08-24 22:25:17.050754189 +0200 CEST m=+567.737134706) (total time: 937.489635ms):
Aug 24 22:25:17 domotica-04 k3s[32334]: Trace[1931520310]: [937.489635ms] [937.489635ms] END
Aug 24 22:25:18 domotica-04 k3s[32334]: I0824 22:25:18.001996   32334 trace.go:81] Trace[9223029]: "SQL Commit" (started: 2019-08-24 22:25:13.900250862 +0200 CEST m=+564.586630379) (total time: 4.10128006s):
Aug 24 22:25:18 domotica-04 k3s[32334]: Trace[9223029]: [883.954788ms] [883.786955ms] condition key /registry/leases/kube-node-lease/domotica-05 good true
Aug 24 22:25:18 domotica-04 k3s[32334]: Trace[9223029]: [4.10111381s] [3.217159022s] op key /registry/leases/kube-node-lease/domotica-05 op 2
Aug 24 22:25:18 domotica-04 k3s[32334]: I0824 22:25:18.003170   32334 trace.go:81] Trace[1314769145]: "GuaranteedUpdate etcd3: *coordination.Lease" (started: 2019-08-24 22:25:13.89485854 +0200 CEST m=+564.581238640) (total time: 4.107967046s):
Aug 24 22:25:18 domotica-04 k3s[32334]: Trace[1314769145]: [4.107316547s] [4.102048683s] Transaction committed
Aug 24 22:25:18 domotica-04 k3s[32334]: E0824 22:25:18.003538   32334 status.go:71] apiserver received an error that is not an metav1.Status: &errors.errorString{s:"context canceled"}
Aug 24 22:25:18 domotica-04 k3s[32334]: I0824 22:25:18.005602   32334 trace.go:81] Trace[1067664194]: "Update /apis/coordination.k8s.io/v1beta1/namespaces/kube-node-lease/leases/domotica-05" (started: 2019-08-24 22:25:13.892844711 +0200 CEST m=+564.579224436) (total time: 4.112388495s):
Aug 24 22:25:18 domotica-04 k3s[32334]: Trace[1067664194]: [4.110649165s] [4.10911346s] Object stored in database
Aug 24 22:25:18 domotica-04 k3s[32334]: I0824 22:25:18.007225   32334 trace.go:81] Trace[1052773052]: "SQL DB QueryContext query: SELECT id, name, value, old_value, old_revision, create_revision, revision, ttl, version, del FROM key_value WHERE name = ? ORDER BY revision DESC limit ? keys: [/registry/minions/domotica-07 1]" (started: 2019-08-24 22:25:15.967801315 +0200 CEST m=+566.654180915) (total time: 2.039033138s):
Aug 24 22:25:18 domotica-04 k3s[32334]: Trace[1052773052]: [2.039033138s] [2.039033138s] END
Aug 24 22:25:18 domotica-04 k3s[32334]: E0824 22:25:18.124080   32334 watch.go:233] unable to encode watch object *v1.WatchEvent: write tcp <IP_ADDRESS>:6443-><IP_ADDRESS>:39678: write: broken pipe (&streaming.encoder{writer:(*framer.lengthDelimitedFrameWriter)(0xc444d60), encoder:(*versioning.codec)(0x9644050), buf:(*bytes.Buffer)(0xe138e00)})
Aug 24 22:25:18 domotica-04 k3s[32334]: I0824 22:25:18.354409   32334 trace.go:81] Trace[1650250852]: "SQL DB QueryContext query: SELECT id, name, value, old_value, old_revision, create_revision, revision, ttl, version, del FROM key_value WHERE name = ? ORDER BY revision DESC limit ? keys: [/registry/minions/domotica-01 1]" (started: 2019-08-24 22:25:15.356237002 +0200 CEST m=+566.042616603) (total time: 2.997912811s):
Aug 24 22:25:18 domotica-04 k3s[32334]: Trace[1650250852]: [2.997912811s] [2.997912811s] END
Aug 24 22:25:18 domotica-04 k3s[32334]: I0824 22:25:18.358516   32334 trace.go:81] Trace[1224956611]: "SQL DB QueryContext query: SELECT id, name, value, old_value, old_revision, create_revision, revision, ttl, version, del FROM key_value WHERE name = ? ORDER BY revision DESC limit ? keys: [/registry/minions/domotica-02 1]" (started: 2019-08-24 22:25:15.959612165 +0200 CEST m=+566.645993099) (total time: 2.398633223s):
Aug 24 22:25:18 domotica-04 k3s[32334]: Trace[1224956611]: [2.398633223s] [2.398633223s] END

Additional context
The architecture this system is running is ARMhf.

I haven't personally seen this behavior so I'm guessing something in your environment is triggering it to go trace.  What are the environment variables set on the process?

Yes i think so too.  I checked the global environment variables as well, and i can't spot anything special.

I have got the same behavior as well, I don't know how to reduce the verbosity and -v 0 does not seem to help.
I'm on version v1.17.2+k3s1 on a Centos 8 Vagrant box and starting the k3s with the following command:
K3S_TOKEN=superrandompassword /usr/local/bin/k3s server --cluster-init --node-ip <IP_ADDRESS> -v 0

Have you been able to workaround this, @Rick-Jongbloed ?

How did you install k3s to begin with? Are there any environment variables that might be influencing this behavior?

No i havent been able to work around this issue unfortunately.

Can you provide a full listing of the environment variables for your k3s server process?

I wil do this this weekend and will update this post.

I'm facing the same behavior as well, I installed k3s with the following command :
curl -sfL https://get.k3s.io | sh -s - server --datastore-endpoint="mysql://user:password@tcp(ip:3306)/k3s" --log /var/log/k3s.log

In file /var/log/k3s.log, I can see the following output :
Trace[1691121332]: [9.976763219s] [232.807µs] Transaction prepared
Trace[1691121332]: [9.984781277s] [8.018058ms] Transaction committed
Trace[1691121332]: [9.985086084s] [255.129µs] Transaction prepared
Trace[1691121332]: [9.993509663s] [8.423579ms] Transaction committed
Trace[1691121332]: [9.993818646s] [273.106µs] Transaction prepared
Trace[1691121332]: [9.998879099s] [5.060453ms] END
I0420 11:20:48.213953    1590 trace.go:116] Trace[1092196218]: "Update" url:/api/v1/namespaces/kube-system/endpoints/kube-scheduler,user-agent:k3s/v1.17.4+k3s1 (linux/amd64) kubernetes/3eee8ac/leader-election,client:<IP_ADDRESS> (started: 2020-04-20 11:20:38.212566061 +0200 CEST m=+610.467951821) (total time: 10.001340905s):
Trace[1092196218]: [10.001340905s] [10.001264141s] END
W0420 11:20:48.285716    1590 garbagecollector.go:639] failed to discover some groups: map[metrics.k8s.io/v1beta1:the server is currently unable to handle the request]
E0420 11:20:48.643149    1590 node_lifecycle_controller.go:1152] Error updating node rancher1: Operation cannot be fulfilled on nodes "rancher1": the object has been modified; please apply your changes to the latest version and try again
E0420 11:20:48.673407    1590 node_lifecycle_controller.go:1152] Error updating node rancher2: Operation cannot be fulfilled on nodes "rancher2": the object has been modified; please apply your changes to the latest version and try again
E0420 11:20:51.297134    1590 pod_workers.go:191] Error syncing pod 92c0d88d-5729-454d-a166-92cb9850a0fd ("helm-install-traefik-snzq9_kube-system(92c0d88d-5729-454d-a166-92cb9850a0fd)"), skipping: failed to "StartContainer" for "helm" with CrashLoopBackOff: "back-off 5m0s restarting failed container=helm pod=helm-install-traefik-snzq9_kube-system(92c0d88d-5729-454d-a166-92cb9850a0fd)"
E0420 11:20:52.094317    1590 node_controller.go:245] Error getting node addresses for node "rancher1": error fetching node by provider ID: unimplemented, and error by node name: Failed to find node rancher1: node "rancher1" not found
E0420 11:20:52.094791    1590 node_controller.go:245] Error getting node addresses for node "rancher2": error fetching node by provider ID: unimplemented, and error by node name: Failed to find node rancher2: node "rancher2" not found
E0420 11:21:01.878530    1590 leaderelection.go:367] Failed to update lock: Put https://<IP_ADDRESS>:6444/api/v1/namespaces/kube-system/endpoints/kube-scheduler?timeout=10s: net/http: request canceled (Client.Timeout exceeded while awaiting headers)
time="2020-04-20T11:21:01.879045722+02:00" level=error msg="error in txn: context canceled"
I0420 11:21:01.879671    1590 trace.go:116] Trace[1962836807]: "Update" url:/api/v1/namespaces/kube-system/endpoints/kube-scheduler,user-agent:k3s/v1.17.4+k3s1 (linux/amd64) kubernetes/3eee8ac/leader-election,client:<IP_ADDRESS> (started: 2020-04-20 11:20:51.879228016 +0200 CEST m=+624.134613724) (total time: 10.000403113s):
Trace[1962836807]: [10.000403113s] [10.000310964s] END
I0420 11:21:01.881311    1590 trace.go:116] Trace[1185887788]: "GuaranteedUpdate etcd3" type:*core.Endpoints (started: 2020-04-20 11:20:51.879365396 +0200 CEST m=+624.134751290) (total time: 9.999308159s):
Trace[1185887788]: [319.246µs] [295.958µs] Transaction prepared
Trace[1185887788]: [6.154816ms] [5.83557ms] Transaction committed
Trace[1185887788]: [6.369838ms] [191.198µs] Transaction prepared
Trace[1185887788]: [13.983552ms] [7.613714ms] Transaction committed
Trace[1185887788]: [14.191984ms] [187.93µs] Transaction prepared
Trace[1185887788]: [19.192077ms] [5.000093ms] Transaction committed
Trace[1185887788]: [19.402218ms] [187.732µs] Transaction prepared

My environment variables are :
ps -ef | grep k3s
root      1306     1  0 11:10 ?        00:00:00 /usr/local/bin/k3s server --datastore-endpoint=mysql://user:password@tcp(ip:3306)/k3s --log /var/log/k3s.log
root      1590  1306 40 11:10 ?        00:02:00 k3s server --datastore-endpoint=mysql://user:password@tcp(ip:3306)/k3s --log /var/log/k3s.log
root      1819  1590  0 11:10 ?        00:00:02 containerd -c /var/lib/rancher/k3s/agent/etc/containerd/config.toml -a /run/k3s/containerd/containerd.sock --state /run/k3s/containerd --root /var/lib/rancher/k3s/agent/containerd
root      2250     1  0 11:10 ?        00:00:00 /var/lib/rancher/k3s/data/6a3098e6644f5f0dbfe14e5efa99bb8fdf60d63cae89fdffd71b7de11a1f1430/bin/containerd-shim-runc-v2 -namespace k8s.io -id 274e4fb9a437f5ebb52cf196dc806e4830d958caae8ce976ed94d08a356c2830 -address /run/k3s/containerd/containerd.sock
root      2251     1  0 11:10 ?        00:00:00 /var/lib/rancher/k3s/data/6a3098e6644f5f0dbfe14e5efa99bb8fdf60d63cae89fdffd71b7de11a1f1430/bin/containerd-shim-runc-v2 -namespace k8s.io -id eb1944d2b7b83f48d6798bc8884843d8d16ce75961e244eb8aca149cee81bf27 -address /run/k3s/containerd/containerd.sock

cat /proc/1306/environ | tr '\0' '\n'
LANG=en_US.UTF-8
LANGUAGE=en_US:en
PATH=/var/lib/rancher/k3s/data/6a3098e6644f5f0dbfe14e5efa99bb8fdf60d63cae89fdffd71b7de11a1f1430/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/snap/bin:/var/lib/rancher/k3s/data/6a3098e6644f5f0dbfe14e5efa99bb8fdf60d63cae89fdffd71b7de11a1f1430/bin/aux
NOTIFY_SOCKET=/run/systemd/notify
INVOCATION_ID=673a633c4ba24b148886feeaf01e060f
JOURNAL_STREAM=9:22596
RES_OPTIONS=
K3S_DATA_DIR=/var/lib/rancher/k3s/data/6a3098e6644f5f0dbfe14e5efa99bb8fdf60d63cae89fdffd71b7de11a1f1430

cat /proc/1590/environ | tr '\0' '\n'
LANG=en_US.UTF-8
LANGUAGE=en_US:en
PATH=/var/lib/rancher/k3s/data/6a3098e6644f5f0dbfe14e5efa99bb8fdf60d63cae89fdffd71b7de11a1f1430/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/snap/bin:/var/lib/rancher/k3s/data/6a3098e6644f5f0dbfe14e5efa99bb8fdf60d63cae89fdffd71b7de11a1f1430/bin/aux
NOTIFY_SOCKET=/run/systemd/notify
INVOCATION_ID=673a633c4ba24b148886feeaf01e060f
JOURNAL_STREAM=9:22596
RES_OPTIONS=
K3S_DATA_DIR=/var/lib/rancher/k3s/data/6a3098e6644f5f0dbfe14e5efa99bb8fdf60d63cae89fdffd71b7de11a1f1430
_K3S_LOG_REEXEC_=true

Thanks for your help.

Same problem for on on  v1.18.9+k3s1
systemd config
[Unit]
Description=Lightweight Kubernetes
Documentation=https://k3s.io
Wants=network-online.target

[Install]
WantedBy=multi-user.target

[Service]
Type=notify
EnvironmentFile=/etc/systemd/system/k3s.service.env
KillMode=process
Delegate=yes
# Having non-zero Limit*s causes performance problems due to accounting overhead
# in the kernel. We recommend using cgroups to do container-local accounting.
LimitNOFILE=1048576
LimitNPROC=infinity
LimitCORE=infinity
TasksMax=infinity
TimeoutStartSec=0
Restart=always
RestartSec=5s
ExecStartPre=-/sbin/modprobe br_netfilter
ExecStartPre=-/sbin/modprobe overlay
ExecStart=/usr/local/bin/k3s \
    server \
        '--disable=traefik' \
        '--node-label' \
        'role=ingress-controller' \
        '-v=0' \

cat /var/log/messages | grep k3s
Oct 28 10:39:20 xx k3s[3519308]: I1028 10:39:20.319883 3519308 trace.go:116] Trace[964924759]: "List" url:/api/v1/events,user-agent:rancher/v0.0.0 (linux/amd64) kubernetes/$Format cluster c-b8p8t,client:<IP_ADDRESS> (started: 2020-10-28 10:39:19.527878812 +0000 UTC m=+93.459566966) (total time: 791.950661ms):
Oct 28 10:39:20 xx k3s[3519308]: Trace[964924759]: [783.333787ms] [783.291805ms] Listing from storage done
Oct 28 10:39:20 xx k3s[3519308]: I1028 10:39:20.902945 3519308 trace.go:116] Trace[358696718]: "List etcd3" key:/events,resourceVersion:,limit:500,continue:eyJ2IjoibWV0YS5rOHMuaW8vdjEiLCJydiI6MTcxNTA2NjMsInN0YXJ0IjoiZGVmYXVsdC9wcm9kLWhjbG91ZC1pbm4tbWFzdGVyMC1mc24xLjE2MmQyMmI3Y2Y1NzI5ZGFcdTAwMDAifQ (started: 2020-10-28 10:39:20.363423701 +0000 UTC m=+94.295111757) (total time: 539.491307ms):
Oct 28 10:39:20 xx k3s[3519308]: Trace[358696718]: [539.491307ms] [539.491307ms] END
Oct 28 10:39:20 xx k3s[3519308]: I1028 10:39:20.912733 3519308 trace.go:116] Trace[344039666]: "List" url:/api/v1/events,user-agent:rancher/v0.0.0 (linux/amd64) kubernetes/$Format cluster c-b8p8t,client:<IP_ADDRESS> (started: 2020-10-28 10:39:20.363391906 +0000 UTC m=+94.295079948) (total time: 549.299957ms):
Oct 28 10:39:20 xx k3s[3519308]: Trace[344039666]: [539.576034ms] [539.551281ms] Listing from storage done

You will see these TRACE level messages when datastore operations take an excessive amount of time. Generally this indicates that your node is CPU or IO bound and is not performing to the apiserver's expectations.

Good to know the cause and that this indicates (potentially) a problem, thanks.
Would it not make sense to rather output a single line such as
"WARNING: datastore operation -List etcd3...- took longer than expected 501ms (threshold 500ms)"
This gives the operator a change to turn up the logging level (e.g. to Trace).

This is all upstream Kubernetes code, not k3s code. Feel free to open an issue there.

Thanks. Looks like it (or similar problems) are on the radar
https://github.com/kubernetes/kubernetes/issues/95568
https://github.com/kubernetes/kubernetes/issues/87126

Closing due to age.


bug:  incompatible types when using implicit returns

Bug Report
Cairo version:
1.0
Current behavior:
Getting errors when using implicit returns:
⠉ Testing exercises/options/options1.cairo...
error: If blocks have incompatible types: "core::option::Option::<?1>" and "()"
--> options1.cairo:25:5
if time_of_day < 22_usize {
^*************************^
error: If blocks have incompatible types: "core::option::Option::<?3>" and "()"
--> options1.cairo:28:5
if time_of_day < 24_usize {
^*************************^
⠒ Testing exercises/structs/structs3.cairo...
error: If blocks have incompatible types: "core::bool" and "()"
--> structs3.cairo:36:9
if self.sender_country != self.recipient_country {
^************************************************^
Sample code on this commit.
https://github.com/shramee/starklings-cairo1/commit/ee4dced03c681dda04cd27359c57798ca0f6e8c5
I was working on the starklings   and I noticed this strange behavior only when using implicit returns within if statements.
As far as I can tell this is an issue with not having explicitly the return keyword.
Expected behavior:
Implicit returns should work no mater if inside or outside conditional statements
Steps to reproduce:

Clone repo https://github.com/ccolorado/starklings-cairo1/
Checkout branch https://github.com/ccolorado/starklings-cairo1/tree/head_scratching
Include the comment // I AM NOT DONE on the error to reproduce
run cargo run --bin starklings watch

Related code:

I don't understand the issue. Please provide a minimal code sample that reproduces the issue

    if time_of_day < 24_usize {
        Option::Some(0_usize)
    }

note that this code example is the same as:
    if time_of_day < 24_usize {
        Option::Some(0_usize)
    } else {
        ()
    }

So the types are actually incompatible.
In this case you probably want:
    if time_of_day < 24_usize {
        return Option::Some(0_usize);
    }

The code samples on the commit are these.
@orizi I think the behavior might be different.
  // Example 1
  // [ works ]
  if self.sender_country == self.recipient_country {
      return false;
  }
  return true;

  // [ doesn't work ]
  // if self.sender_country != self.recipient_country {
  //     true
  // }
  // false

  // Example 2
  // [ works ]
  if time_of_day < 22_usize {
      Option::Some(5_usize)
  } else if time_of_day < 24_usize {
      Option::Some(0_usize)
  } else {
      Option::None(())
  }

  // [ doesn't work ]
  // if time_of_day < 22_usize {
  //     Option::Some(5_usize)
  // }
  // if time_of_day < 24_usize {
  //     Option::Some(0_usize)
  // }
  // Option::None(())

the examples you gave that didn't work - also shouldn't work.
you should look at every if statement as if it has an empty else clause.
Since if and else must return the same type (as they are the same block) - in this case the if block must return the unit type (), so it should end with ;.
Note that generally - an implicit return just means that the function returns the return value of the functions block, not just any line without a ;

Thanks for the explanation. This wasn't clear to me.


Update Nuget name and version to WindowsAppSDK preview version

I noticed many of the samples here were using nuget packages with the name ProjectReunion, when we should be using WindowsAppSDK instead.
this PR updates the nuget packages to use WindowsAppSDK version 1.0.0-preview1.
Luckily, were in a good time as well because WindowsAppSDK version 1.0.0-preview1 also removes the need of adding the Foundation, WinUI, DWriteCore, and InteractiveExperiences nuget packages.
To update, I used the visual studio UI and uninstalled the unneeded packages and installed the latest WindowsAppSDK package.
Due to a renaming decision of ApplicationModel, I had to do a slight rename in some of the includes and namespaces, but after that the samples built correctly for all platforms and all configurations (Debug, Release, x64, x86 and ARM)
Unfortunately though, for the samples under the Windowing folder, I wasn't able to udpate the nuget packages, as it seems that it brings more functional errors and not just package related errors. I'll open an issue to fix these samples.

Thanks for updating the Samples @erik0686! :)
(nit: Probably want to update the PR description on GitHub).

Would you please add a How Verified section to your PR description? It would help the reviewers to know which cases have been verified, if there are any gaps, etc.

// Take a dependency on Project Reunion v0.8 preview.

still 0.8

Refers to: Samples/ResourceManagement/cpp-console-unpackaged/console_unpackaged_app.cpp:19 in c45ca8c. [](commit_id = c45ca8c5ede0c506837cba4492bb114dbe411597, deletion_comment = False)


Add AdminLTE style for Login/SignUp pages

The default login page (with vegas) looks impressive. However, it seems that the AdminLTE login box is more suitable for business application I think. I've added AdminLTE style for Login / SignUp / ForgotPassword / ResetPassword pages. This is optional and developer can switch from default login style to AdminLTE style easily just by changing this static variable of the class AccountController
public static bool UseAdminLTELoginBox = true;

Add dynamic navigation sample

Thanks @DucThanhNguyen for another good contribution.


imp: add source credentials

closes: #18
@nlewo this works on multi-user install, not sure if it works the same way on daemon install or if it depends on a special nix.conf, though.

this works on multi-user install

Do you mean mono-user install?
On multiuser installs, you would need to provide these variables to the deamon. The netrc file is often used for this purpose (see https://nixos.wiki/wiki/Enterprise). The pullImage derivation would then have to parse this file (which needs to be bindmounted in the sandbox with sandbox-paths).
On NixOS, providing environment variables to the Nix deamon may be tricky because the nix.conf file is in the store and we don't want to put secrets in the store. In this context, i think the netrc implementation would be required.
I think we could however start with environment variables, and iterate later when needed.

I'll do a quick&simple bash netrc parser. This is the way to go.
Caveat: will be a single line parser.

So netrc is too low-level, instead let's simply work with the scopeo-native auth.json or $HOME/.docker/config.json:
void builtinFetchurl(const BasicDerivation & drv, const std::string & netrcData)
{
    /* Make the host's netrc data available. Too bad curl requires
       this to be stored in a file. It would be nice if we could just
       pass a pointer to the data. */
    if (netrcData != "") {
        settings.netrcFile = "netrc";
        writeFile(settings.netrcFile, netrcData, 0600);
    }

Refactored & force-pushed and now it works like so:
sandbox-paths = /etc/skopeo/auth.json=/home/blaggacao/.docker/config.json

@blaggacao neat!
Would it be possible to add a piece of doc  (in the pullImagefunction docstring  for instance)?
Otherwise, lgtm.

Thank you!


Small change: explain the use of keys in JS documentation

URL.
Text sections:

Let's assume that you have stringified public & private keys (more on that later)

const keyPair = crypto.KeyPair.fromJSON({
  public_key: 'ed0120e555d194e8822da35ac541ce9eec8b45058f4d294d9426ef97ba92698766f7d3',
  private_key: {
    digest_function: 'ed25519',
    payload:
      'de757bcb79f4c63e8fa0795edc26f86dfdba189b846e903d0b732bb644607720e555d194e8822da35ac541ce9eec8b45058f4d294d9426ef97ba92698766f7d3',
  },
})

Denis Kitaev requested the documentation update because it looks inconsistent for new users, specifically how keys were obtained for this code section.
I believe this key pair is taken from the Iroha JSON configuration file, but if it's more elaborate here, that'll greatly help the users.

I could add another issue for this code, but I feel those topics are intertwined.
import { cryptoTypes } from '@iroha2/crypto-core'
import { Signer } from '@iroha2/client'
import { AccountId, DomainId } from '@iroha2/data-model'

// Key pair from previous step
declare const keyPair: cryptoTypes.KeyPair

const accountId = AccountId({
  // Account name
  name: 'alice',
  // The domain where this account is registered
  domain_id: DomainId({
    name: 'wonderland',
  }),
})

const signer = new Signer(accountId, keyPair)

Denis Kitaev also requested this information to be added to the JS SDK docs:

Where does the alice account name come from?
Is alice pre-set in the container peers?
What about the wonderland domain?
What about the key pair?

Yes it would be great if the documentation would explain step by step what to do... how to make requests from Node.js/JavaScript environment... Exactly step by step...


fix: missing application id in comment threads API

Description
Fixes the error toast message that says "Please enter a valid applicationId".
This has to do with the comments component mounted and it the fetch threads API being called before the applicationId is retrieved. This PR delays the comments component mount in the application header.
Fixes #13489
Type of change

Bug fix (non-breaking change which fixes an issue)

How Has This Been Tested?

Manual

Checklist:

[x] My code follows the style guidelines of this project
[x] I have performed a self-review of my own code
[ ] 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

Test coverage results :test_tube:
:white_circle: Total coverage has not changed
// Code coverage diff between base branch:release and head branch: fix/missing-app-id

Status
File
% Stmts
% Branch
% Funcs
% Lines

:red_circle:
app/client/src/pages/Editor/EditorHeader.tsx
86.99 (-0.26)
53.09 (-0.48)
62.5 (0)
86.33 (-0.29)

:green_circle:
app/client/src/pages/Editor/ToggleModeButton.tsx
38.73 (1.32)
11.49 (-0.71)
17.24 (0)
38.17 (1.45)

:green_circle:
app/client/src/reducers/uiReducers/appViewReducer.tsx
50 (4.55)
100 (0)
14.29 (14.29)
50 (4.55)

:green_circle:
app/client/src/utils/autocomplete/TernServer.ts
52.94 (0.23)
41.67 (0.84)
36.21 (0)
56.99 (0.25)

@Parthvi12 Can you please test out the DP ?

/ok-to-test sha=5217a6e

@arunvjn For existing app its working fine but I am seeing this toast message on creating new app

/ok-to-test sha=53ddb8d

Tested the dp and its working as expected @arunvjn


[core] Decompilation of loop failed #2

Hi,
in the following example the method "loopTest" can not be decompiled. I tested this class with latest git version fef3e21 and openjdk8. My example is already minimized and may be used for a unit test.
public class LoopTest2 {

  public void loopTest(int mode) {
    int val = 0;
    switch (mode) {
    case 1:
      for (;;) {
        val = getValue();

        if (val == -1 || val == 1) {
          doSomething();
          break;
        }

        if (checkValue(val)) {
          continue;
        }

        break;
      }
      doSomething();
      break;
    default:
      break;
    }
  }

  private int getValue() {
	return 0;
  }

  private boolean checkValue(int val) {
	return false;
  }

  private void doSomething() {
  }
}

Update: Form b5720bd to eedf32d the issue changed from bad blocks to behaviour change. In decompiled code the second invocation of doSomething() is also part of the loop. I would like to update my sample (different methods) without changing the cause:
public class LoopTest2 {

  public void loopTest(int mode) {
    int val = 0;
    switch (mode) {
    case 1:
      for (;;) {
        val = getValue();

        if (val == -1 || val == 1) {
          doSomething();
          break;
        }

        if (checkValue(val)) {
          continue;
        }

        break;
      }
      doSomething2();
      break;
    default:
      break;
    }
  }

  private int getValue() {
	return 0;
  }

  private boolean checkValue(int val) {
	return false;
  }

  private void doSomething() {
  }

  private void doSomething2() {
  }
}

In decompiled code doSomething2() is called inside and outside the loop.


chore(package): update @kronos-integration/service to version 7.1.20

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

npm package (@latest dist-tag)
GitHub release

Your semantic-release bot :package::rocket:


await BackgroundService.start(veryIntensiveTask, options); Not starting the task in android. No notification and No error messages at all

        useEffect(() => {
        const options = {
          taskName: 'Example',
          taskTitle: 'ExampleTask title',
          taskDesc: 'ExampleTask description',
          taskIcon: {
            name: 'ic_launcher',
            type: 'mipmap',
          },
          color: '#ff00ff',
          parameters: {
            delay: 1000,
          },
        };

  const sleep = (time) => new Promise((resolve) => setTimeout(() => resolve(), time));

  const startService = async () => {

    const veryIntensiveTask = async (taskDataArguments) => {
      // Example of an infinite loop task
      const { delay } = taskDataArguments;
      await new Promise(async (resolve) => {
        for (let i = 0; BackgroundService.isRunning(); i++) {
          console.log(i);
          await sleep(delay);
        }
      });
    };

    console.log("Starting service with notification");
    await BackgroundService.start(veryIntensiveTask, options);
    console.log("Service started");
  }
  startService();

}, [startService])
FYI: Debugged the code task is not executed at all

Its my cache issue. I just cleared everything and run it, its started working.


Name changed

Worth noting that this has now been re-named to DataTransfer https://github.com/xamarin/Essentials/tree/master/Xamarin.Essentials/Share

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

ID: e86cfbdf-277d-29ae-3999-33f73d91efc6
Version Independent ID: cf9bfb50-9d1e-3c5d-139f-392dfc9550eb
Content: Xamarin.Essentials: Share - Xamarin
Content Source: docs/essentials/share.md
Product: xamarin
GitHub Login: @jamesmontemagno
Microsoft Alias: jamont

DataTransfer was the old name, it was changed to Share in version 1.0


I don't want to use the CGO.

go get -u github.com/glycerine/zygomys/cmd/zygo
package github.com/glycerine/tmframe/vendor/github.com/codahale/blake2: C source files not allowed when not using cgo or SWIG: blake2b.c

Recommend the use of "github.com/dchest/blake2b"

fixed with 23bc74770c945f51a2a1ea4cfc9823cca7d0ff5e


Fix bug in views and models.

Title: Fix bugs and logic in views and models.
Summary
This pull request will add conditions in views and fix bugs in models
Changes Made
Added Condition:
In Event views add a valid date condition.
In Ticket views add conditions for apply event.

Good work.


Issue 29 Ending slash in s3Client -> ServiceURL should not be mandatory #

fixed as requested....

@davidbirchwork, this branch has commits from other branches. We have two options here:

Wait for the other branches to be merged and then merge this.
Rebase this PR and remove the invalid commits.

I'm happy to walk you through the second option if you want to, because I'm unable to do that using my computer as it may replace the author of the commit.

Thank you a cleaner implementation is now provided


#Fixes Enable users to write custom alert messages #5

Description
adds the functionality for users to set custom messages for reminders

added the functionality in setting/options area to avoid the extension being too big in ui
Please include a summary of the changes and the related issue. Please also include relevant motivation and context. List any dependencies that are required for this change.
Related Issue

Fixes # (issue)
Type of change

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

Motivation and Context

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration
Screenshots (if appropriate):
Checklist:

[x] I have registered myself at Contrihub website.
[ x] My code follows the code style of this project.
[ x] I have commented my code, particularly in hard-to-understand areas
[ x] My changes generate no new warnings
[ x] My change requires a change to the documentation.
[ x] I have updated the documentation accordingly.
[ x] I have read the CONTRIBUTING document.
[ x] Any dependent changes have been merged and published in downstream modules
[ ] I have added tests to cover my changes.
[ x] All new and existing tests passed.

Test Configuration:

Firmware version:
Hardware:
Toolchain:
SDK:

Add the issue number in the PR description.


Pipeline Improvements (Test)

Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:

Comparison is base (9bc3905) 98.47% compared to head (fa6645d) 98.47%.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #4158   +/-   ##
=======================================
  Coverage   98.47%   98.47%
=======================================
  Files          43       43
  Lines        4068     4068
=======================================
  Hits         4006     4006
  Misses         62       62

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


-Ymacro-classpath / Global.close() / Reference counted FileBasedCache

Submitted as https://github.com/scala/scala/pull/7366


Weapon attachment question

So, we have some custom weapons, and we are trying to figure out where we have to define their attachments. On your "weapons" page there is a minimal amount of information regarding this topic. We've got them all in the items lua, we've tried placing them independently in the weapons lua, so on and so forth, I would GREATLY appreciate it if you guys could reach out and let me know how exactly to do this. Searching the default repo that is given when you setup a base qbox server the attachments for the default weapons are only defined in the items lua after doing a search, and they seem to work just fine.

These are all defined in ox_inventory/data/weapons.lua. The weapons.lua has a note at the top pointing you to the correct location

Thank you!


Bug 1131074

There are some unrelated commits shall be removed.

Yeah. I fixed the commit history because pull request 19 contained bad commits. These commits are now in all pull requests that have been created before the fix. I'll update accordingly.


Pass viz type to GET requests

SUMMARY

We need to pass the visualization type to the initial GET request in the Explore view, since the payload is dependent on it.

TEST PLAN

We had a problem where:

User would create a new chart in Explore, using table view.
User would switch to a different visualization type.
Client would run a GET based only on the slice id, returning the wrong payload type. In our case, the Mapbox API key was not sent.

I changed the GET request to pass the visualization type. Another alternative might be to not use GET requests in the Explore view, at the cost of the initial load being slow. I'll monitor this during the first days of GA.
ADDITIONAL INFORMATION

[ ] Has associated issue:
[ ] Changes UI
[ ] Requires DB Migration. Confirm DB Migration upgrade and downgrade tested.
[ ] Introduces new feature or API
[ ] Removes existing feature or API
[X] Fixes bug
[ ] Refactors code
[ ] Adds test(s)

REVIEWERS
@xtinec

Codecov Report

Merging #7255 into lyftga will increase coverage by 0.04%.
The diff coverage is 66.66%.

@@            Coverage Diff            @@
##           lyftga   #7255      +/-   ##
=========================================
+ Coverage   64.55%   64.6%   +0.04%
=========================================
  Files         425     425
  Lines       20870   20891      +21
  Branches     2282    2296      +14
=========================================
+ Hits        13472   13496      +24
+ Misses       7272    7269       -3
  Partials      126     126

Impacted Files
Coverage Δ

superset/views/utils.py
88.09% <100%> (ø)
:arrow_up:

superset/assets/src/explore/exploreUtils.js
75.72% <50%> (-0.75%)
:arrow_down:

...assets/src/visualizations/deckgl/layers/common.jsx
62.29% <0%> (+28.14%)
:arrow_up:

Continue to review full report at Codecov.

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


Store the memory in a more efficient way.

If this rule engine is going to be used on local computer, the bottle neck is going to be the memory handling.
Maybe we need to create one file that is optimize for the jvm and another for JavaScript.

This has been done as a byproduct of other efforts, so I'm going to go ahead and mark it as closed. The working memory now uses CLJC with optimizations for both the JVM and JavaScript. We can open new issues for further memory optimizations.


For another editor?

Good theme, thanks. I like many settings.
Can you make analog for CudaText editor, please?
http://wiki.freepascal.org/CudaText#Color_themes

Hi @Alexey-T maybe in the future. I don't know CudaText.


Scrolling using a Surface Dial will only ever scroll in one editor group.

Issue Type: Bug
The Surface Dial seems to only work on one editor group. If you have two or more editor groups, the dial will only scroll in one of them. Even if you switch focus to another editor group, the first group is the only editor group that will scroll. It should follow the focus.
Steps to reproduce

Open a file in the editor.
Open a second file in a new editor group. So you have two files open side by side.
Focus the first file, and then use a Surface Dial to scroll up and down.
Focus the second file, and then use a Surface Dial to scroll up and down.

Expected Result:

When the first file is focused, scrolling with the Surface Dial should scroll the first file up and down.
When the second file is focused, scrolling with the Surface Dial should scroll the second file up and down.

Actual Result:

When the first file is focused, scrolling with the Surface Dial scrolls the first file.
When the second file is focused, scrolling with the Surface Dial still scrolls the first file.
You can only scroll the first file using the dial. It's not respecting the focus.

Happens with --disable-extensions.
VS Code version: Code 1.23.0 (7c7da59c2333a1306c41e6e7b68d7f0caa7b3d45, 2018-05-03T16:44:55.614Z)
OS version: Windows_NT x64 10.0.17134

System Info

Item
Value

CPUs
Intel(R) Core(TM) i7-6650U CPU @ 2.20GHz (4 x 2208)

GPU Status
2d_canvas: enabledflash_3d: enabledflash_stage3d: enabledflash_stage3d_baseline: enabledgpu_compositing: enabledmultiple_raster_threads: enabled_onnative_gpu_memory_buffers: disabled_softwarerasterization: disabled_softwarevideo_decode: enabledvideo_encode: enabledvpx_decode: unavailable_softwarewebgl: enabledwebgl2: enabled

Memory (System)
7.93GB (1.38GB free)

Process Argv
C:\Program Files\Microsoft VS Code\Code.exe

Screen Reader
no

VM
0%

Extensions (4)

Extension
Author (truncated)
Version

better-toml
bun
0.3.2

vetur
oct
0.11.7

rust
rus
0.4.2

language-stylus
sys
1.9.2

We are building exploration builds that use a much newer version of our UI framework (Electron version 6.0.x). I wonder if this issue reproduces with one of these builds, could you try? Download:

macOS: Download
Linux (DEB): Download
Linux (RPM): Download
Windows: Download


Can't Set Permissions for Fukihimo Takayama

After installing the lastest version of Elements and running it, I get a screen saying I have to adjust Security and Privacy by adding the developer, Fukihimo Takayama, to allowed devs.
How do we do this? Clicking on Open Security and Privacy doesn't work. Opening it from the Apple menu also doesnt work.
As seen in the screen shot, when you open the preferences you are not given the option of adding the dev. Any ideas on how to fix this?
Thank you.
Env:
ProductName:	Mac OS X
ProductVersion:	10.13.6
BuildVersion:	17G7024
yarn version: 1.16.0
node version: v11.14.0

I have also add Karabiner-Elements to apps allowed to control your computer:

After doing the above. The program works after restarting. I will report back if it stops working again.


Set DATAPLANE_GROWVOLS_ARGS for baremetal job

Now that DATAPLANE_GROWVOLS_ARGS is a variable the current value should be set in the job, since the value is specific to the BMAAS_INSTANCE_DISK_SIZE in this job.
The value in install_yamls[1] can be set to an empty string after this is merged, so that developers can install with the default.
[1] https://github.com/openstack-k8s-operators/install_yamls/blob/main/devsetup/Makefile#L34
As a pull request owner and reviewers, I checked that:

[ ] Appropriate testing is done and actually running
[ ] Appropriate documentation exists and/or is up-to-date:

[ ] README in the role
[ ] Content of the docs/source is reflecting the changes

/approve

recheck


KeyError: 'graf'

Hi guys,
I'd like to use pytextrank for keywords extraction from single sentences (questions).
After the installation and downloading a language model I ran pytextrank in IPython with success.
Next, I decided to ran Stage 2 from your example.ipynb with normalize_key_phrases feature.
After that I received KeyError: 'graf' exception.
Details:
In [4]: graph, ranks = pytextrank.text_rank('mih.json')
---------------------------------------------------------------------------
KeyError                                  Traceback (most recent call last)
<ipython-input-4-ce8762751470> in <module>()
----> 1 graph, ranks = pytextrank.text_rank('mih.json')

/Users/katharsis/workspace/keywords_extractor/src/pytextrank.pyc in text_rank(path)
    349     run the TextRank algorithm
    350     """
--> 351     graph = build_graph(json_iter(path))
    352     ranks = nx.pagerank(graph)
    353

/Users/katharsis/workspace/keywords_extractor/src/pytextrank.pyc in build_graph(json_iter)
    299         print meta.keys()
    300
--> 301         for pair in get_tiles(map(WordNode._make, meta["graf"])):
    302             if DEBUG:
    303                 print(pair)

KeyError: 'graf'

I saw that mih.json not contains "graf" key.
It includes "id" and "text" only.
Is it related somehow?
PS. I'm using Python 2.7 on Mac OSx.

Thank you for feedback @Katharsis -- did you run the "Stage 1" example first?  Output from "Stage 1" is used as input for "Stage 2".
I did find an error in the notebook, but in a later step. Am committing that update now.

Stage 1 worked.
But I am interesting only about keywords extraction from the question. Would you like to insert this kind of example in your notebook? On input question / sentence example, but as an output extracted keywords with scoring values.

@ceteri
We can close that issue. The example works now.

@Katharsis : Could you please tell me the input json format for the stage1.py. I have documents in text(.txt) format. Trying to extract key phrases as output with this tool. So if you could tell how to pass the sentences or the list of sentenses as input for this tool it would be of great help. Thanks in advance.


Provide a branch based on the latest Zig release

Hi @MasterQ32 !
When Zig 0.7 will be released, I plan to use zig-network in combination with h11 to try to build an HTTP client library.
Zig is young and move fast so I understand the value of compiling zig-network with Zig master branch.
As we get closer to Zig 1.0, would it be possible to provide a branch for zig-network that compile with the latest release of Zig ?
Maybe something like:

The master branch compile with the latest Zig release (0.7, 0.8, etc...), in order to provide stability to the users.
A develop branch compile with Zig master branch, in order to provide the latest language benefits but also feedbacks for the Zig compiler.

What do you think ?
Have a nice day 🌴

I think this scheme makes sense, I'm planning to do this for zls as well.

I think it's better to have tags that come along with zig releases. These would be old snapshots and not be backported when new features come, as it's too much work for a "deprecated" version, but just have a tag zig-0.7.0 which you can check out should be enough

Thanks for you replies !
Does using tags makes it easy to add a bugfix ?
For example, when Zig 0.7 is released you will make a zig-0.7.0 tag.
Then, Zig master branch add a breaking change or a new API that you use in zig-network master branch.
Someone find a small bug in the zig-0.7.0 tag, which is fixed in the master branch.
In this situation, can I provide a bug fix for zig-0.7.0 or should I wait for the next zig-0.8.0 ?

No, it would not be possible. And imho i don't see much sense in providing backports of bugfixes to earlier versions, it's just twice the work (i consider it maintaining two, three, four, … libraries, depending on how much zig versions will come until 1.0)

Fine then !
I am looking forward to see this zig-0.7.0 tag :)


Remove usage of embedded ActiveMQ broker

CrossRef: https://github.com/wildfly-extras/wildfly-camel/issues/1766


Evaluate (example and fix)

Reference Issues/PRs

#657 #622
What does this implement/fix? Explain your changes.

Added example in notebook. Fix minor tqdm issue.

Thanks @aiwalter - the n_split fix is related to https://github.com/alan-turing-institute/sktime/issues/632 - probably best to fix this in the CV class.

from my side, this can be merged

How do we handle the tqdm dependency now?

I have removed it, no?

Sry seems I didnt push 🙄

should be fine now :) sry for confusion


Renaming of key name

The documentation of PyTestLog2DB contains the following example:
"component" {
            "Testsuite1" : "test-data.test_tsclass.TestSuite1",
            "Testsuite2" : "test-data.test_tsclass.TestSuite2",
            "Others" : [
                       "test-data.test_ts1",
                       "test-data.test_ts2"
                       ]
            },

But beneath "component" more than one component can be defined. Therefore I propose to add a plural 's'.
It's "components", not "component".

Works properly with renamed key.
(retest with latest available feature branches / 28.02.2023)


Add a bind() bench to compare perf gain

Add a bind(this) bench in the arrow function suite to keep in mind the perf gain with bind

                      define a function with inherited this
       9,587,064 op/s » function statement with self = this
         291,491 op/s » function statement with bind
       6,865,705 op/s » arrow function () =>

:+1:


[E2E] Log executed commands using scrubber in host and docker

What does this PR do?

Use the agent scrubber to log executed commands in e2e tests without risking leaking secrets.
Motivation

Help with debugging e2e tests.
Additional Notes

I added an explicit test that the scrubber will properly work on commands with env vars for API and APP keys.
Possible Drawbacks / Trade-offs

Describe how to test/QA your changes

/merge