[BUG] kubectl auth can-i fails when using user impersonation (--as) for ServiceAccounts

Rancher Server Setup

Rancher version: v2.7.3
Installation option (Docker install/Helm Chart): Helm chart

If Helm Chart, Kubernetes Cluster and version (RKE1, RKE2, k3s, EKS, etc): RKE2 v1.25.9+rke2r1

Proxy/Cert Details: Not sure what information you are asking for here.

Information about the Cluster

Kubernetes version: v1.25.9+rke2r1
Cluster Type (Local/Downstream): Downstream

If downstream, what type of cluster? (Custom/Imported or specify provider for Hosted/Infrastructure Provider): Custom

User Information

What is the role of the user logged in? Admin

Describe the bug

User impersonation fails for the kubectl auth can-i command towards downstream Rancher clusters.
To Reproduce

Apply the following manifest:
---
apiVersion: v1
kind: Namespace
metadata:
  name: test
spec: {}
status: {}
---
apiVersion: v1
kind: ServiceAccount
metadata:
  name: issue
  namespace: test
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
  name: issue
rules:
- apiGroups:
  - ""
  resources:
  - namespaces
  verbs:
  - get
  - list
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRoleBinding
metadata:
  name: issue
roleRef:
  apiGroup: rbac.authorization.k8s.io
  kind: ClusterRole
  name: issue
subjects:
- kind: ServiceAccount
  name: issue
  namespace: test

Check if the new ServiceAccount can get namespaces:
kubectl --as system:serviceaccount:test:issue auth can-i get namespaces

Result
$ kubectl --as system:serviceaccount:test:issue auth can-i get namespaces
Error from server (Forbidden): {"Code":{"Code":"Forbidden","Status":403},"Message":"clusters.management.cattle.io \"c-m-qqpj5fml\" is forbidden: User \"system:serviceaccount:test:issue\" cannot get resource \"clusters\" in API group \"management.cattle.io\" at the cluster scope","Cause":null,"FieldName":""} (post selfsubjectaccessreviews.authorization.k8s.io)

Expected Result

$ kubectl --as system:serviceaccount:test:issue auth can-i get namespaces
Warning: resource 'namespaces' is not namespace scoped

yes

Additional context

It seems like the issue here lies with the Rancher proxy. Because if I bypass it things works as expected:
$ SA_TOKEN="$(kubectl -n test create token issue)"

$ kubectl --insecure-skip-tls-verify --server "https://<IP_ADDRESS>:6443" --token "${SA_TOKEN:?}" auth can-i get ns
Warning: resource 'namespaces' is not namespace scoped

yes

$ kubectl --insecure-skip-tls-verify --server "https://<IP_ADDRESS>:6443" --token "${SA_TOKEN:?}" auth can-i create ns
Warning: resource 'namespaces' is not namespace scoped

no

I detected same issue with v2.6.8. Is there any workaround?

None that I have found.

Seems it could be related to https://github.com/rancher/rancher/issues/16221

sure-7524

had (and still have) the same on 2.8.1 and 2.8.2 on downstream RKE cluster.

QA Testing
Root cause

Impersonation in downstream cluster for existing users is currently broken since the introduction of extras for auditing.
The extras for the user doing the request (not the impersonated user) are always added in the Impersonate-Extras header, which leads to the following error:

kubectl get ns --as=u-s984r

Error from server (Forbidden): userextras.authentication.k8s.io "local://u-v7dxk" is forbidden: User "system:serviceaccount:cattle-impersonation-system:cattle-impersonation-u-s984r" cannot impersonate resource "userextras/principalid" in API group "authentication.k8s.io" at the cluster scope

Impersonation in downstrean clusters for ServiceAccounts is not implemented

What was fixed, or what changes have occurred

Impersonate-Extras headers are passed only if the user is trying to impersonate extras (Impersonate-Extras header is present in the request)
Allow users to impersonate ServiceAccounts on downstream clusters:

Verify the user making the request have enough permissions to impersonate SA in the downstream cluster. Reject the request if the user doesn't have enough permissions.
Get a token for the impersonated SA using the TokenRequest api.
Use this token in the Authorization header.

Areas or cases that should be tested

Impersonate users:

User can impersonate other users and groups if he has enough permissions. To impersonate a user download a kubeconfig for the downstream cluster, and the following command can be usedkubectl get ns --as u-vj2hv #u-vj2hv is an existing user

 [impersonation docs](https://kubernetes.io/docs/reference/access-authn-authz/authentication/#user-impersonation)
- User without enough permissions can't impersonate other users or groups.

Impersonate ServiceAccount:

Steps from this issue should work if the user has permissions to impersonate ServiceAccounts.
User without impersonate ServiceAccounts permissions should not be allowed to impersonate ServiceAccounts.

All request to downstream clusters that goes through the Rancher proxy uses impersonation more info. This should keep working as before.

That's amazing! Is it already on the roadmap for the next release, you think?

@lindhe it's planned for the 2.10 release

Release Note
Impersonation in downstream clusters via the Rancher proxy is now supported, enabling users with the appropriate permissions to impersonate other users or ServiceAccounts.

We have validated all scenarios documented in the test plan with v2.10-f95d1dc120a4b4c602fcb1485b36134fc0f4a2bc-head.

#
Test Case Name
Result

1
User - Verify that impersonation works as expected when impersonating a cluster owner
Pass ✅

2
User - Verify that impersonation works as expected when impersonating a cluster member
Pass ✅

3
User - Verify that impersonation works as expected when impersonating a user without correct permissions
Pass ✅

4
User - Verify that impersonation fails as expected when impersonating a non-existent user
Pass ✅

5
User - Verify that a project owner with limited permissions cannot impersonate a cluster owner
Pass ✅

6
User - Verify that a user with view-nodes permissions can view nodes but not delete them through impersonation
Pass ✅

7
User - Verify permissions after role change
Pass ✅

8
User - Impersonate-Extras (Valid permissions) Verify that the requests go through the Impersonate-Extras header
Pass ✅

9
Basic User - Impersonate-Extras (Non-existent user) Verify that the requests go through the Impersonate-Extras header
Pass ✅

10
Group - Verify that impersonation works as expected when impersonating a cluster owner
Pass ✅

11
Group - Verify that impersonation works as expected when impersonating a cluster member
Pass ✅

12
Group - Verify that impersonation works as expected when impersonating a user without correct permissions
Pass ✅

13
Group - Verify that impersonation fails as expected when impersonating a user in a non-existent group
Pass ✅

14
Group - Verify permissions after role change
Pass ✅

15
Group Impersonation - Impersonate-Extras (Pass)
Pass ✅

16
Group Impersonation - Impersonate-Extras (Fail)
Pass ✅

17
ServiceAccounts - Verify that impersonation works as expected when impersonating a service account with correct permissions
Pass ✅

18
ServiceAccounts - Verify that impersonation fails as expected when impersonating a service account without correct permissions
Pass ✅

19
ServiceAccounts - Impersonate-Extras (Successful Request)
Pass ✅

20
ServiceAccounts - Impersonate-Extras (Unsuccessful Request)
Pass ✅

21
User - Verify that after upgrading to Rancher v2.10.0, impersonation works as expected when impersonating a cluster owner
Pass ✅

22
User - Verify that after upgrading to Rancher v2.10.0, impersonation works as expected when impersonating a cluster member
Pass ✅

23
User - Verify that after upgrading to Rancher v2.10.0, impersonation works as expected when impersonating a user without correct permissions
Pass ✅

24
Basic User - Impersonate-Extras (Pass)
Pass ✅

25
Basic User - Impersonate-Extras (Fail)
Pass ✅

26
Group - Verify that after upgrading to Rancher v2.10.0, impersonation works as expected when impersonating a cluster owner
Pass ✅

27
Group - Verify that after upgrading to Rancher v2.10.0, impersonation works as expected when impersonating a cluster member
Pass ✅

28
Group - Verify that after upgrading to Rancher v2.10.0, impersonation works as expected when impersonating a user from a group without correct permissions
Pass ✅

29
Group Impersonation - Impersonate-Extras (Pass)
Pass ✅

30
Group Impersonation - Impersonate-Extras (Fail)
Pass ✅

31
ServiceAccounts - Verify that after upgrading to Rancher v2.10.0, impersonation works as expected when impersonating a service account with correct permissions
Pass ✅

32
ServiceAccounts - Verify that after upgrading to Rancher v2.10.0, impersonation fails as expected when impersonating a service account without correct permissions
Pass ✅

33
ServiceAccounts - Impersonate-Extras (Pass)
Pass ✅

34
ServiceAccounts - Impersonate-Extras (Fail)
Pass ✅


Chore/example styling and basic examples

Adds syntax highlighting for code snippets
Adds 10+ examples

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

npm package (@latest dist-tag)
GitHub release

Your semantic-release bot :package::rocket:


New version: SymbolicNumericIntegration v1.3.4

Registering package: SymbolicNumericIntegration
Repository: https://github.com/SciML/SymbolicNumericIntegration.jl
Created by: @shahriariravanian
Version: v1.3.4
Commit: 7a42349b3096f608067d7677da2b17e07ab56226
Reviewed by: @shahriariravanian
Reference: https://github.com/SciML/SymbolicNumericIntegration.jl/issues/90
Description: SymbolicNumericIntegration.jl: Symbolic-Numerics for Solving Integrals

do not merge. will resubmit.


latest version requires global install of typescript and jshint

the latest version will throw this error
npm install do-wrapper --save
npm WARN package.json<EMAIL_ADDRESS>No README data
npm WARN prefer global<EMAIL_ADDRESS>should be installed with -g

><EMAIL_ADDRESS>postinstall /Users/diniscruz/GitHub_REPOS/TM_Docker/setup/node_modules/do-wrapper
> npm run build && npm run test

><EMAIL_ADDRESS>build /Users/diniscruz/GitHub_REPOS/TM_Docker/setup/node_modules/do-wrapper
> tsc src/*.ts --outDir dist/ --module "commonjs"

sh: tsc: command not found

this can be solved by installing type script globally
npm install -g typescript
npm install -g jshint

but that should be a requirement
related to http://superuser.com/questions/597065/os-x-permissions-when-setting-up-typescript

:+1:

@DinisCruz - this should be fixed as of 2.1.1 as I've changed them to run from the local ./node-modules directory rather than globally.
Please let me know if you have any further issues.


Index page for the patterns

We need to have an index listing of patterns on the page /patterns. Nothing too fancy at this point, just something that allows easy browsing to each of the patterns.

Added a simple index page for the patterns.


kubectl-gadget: Improve error message when the node doesn't exist

Description
As discussed in #238 (comment), the error messages when (1) the timeout happens before the gadget pod writes the result in Trace.Status and (2) a non-existent node is used as filter should be improved:
./kubectl-gadget-linux-amd64 socket-collector -n default -p my-pod --node non-existent-node
FATA[0000] Error getting traces from all nodes           args="[]" command="kubectl-gadget socket-collector"

Impact
User does not know what happened. Gadget is just failing without a proper error message.
Environment and steps to reproduce

Set-up: There is no particular requirements, it should be reproducible everywhere. In my case I was using: Kubernetes cluster created using kubeadm v1.22.0, Docker v20.10.8, Go v1.16.7 and kernel 5.13.9.
Task: Filter by a non existent node.
Action(s): Execute the socket-collector gadget with a non-existent node in the filter: kubectl gadget socket-collector -n default -p my-pod --node non-existent-node
Error: The gadget just fails without giving any information to the user.

Expected behavior
Error should describe why gadget failed.
Additional information
This improvement complements the issue https://github.com/kinvolk/inspektor-gadget/issues/251 and they should be considered together.

I'm not sure I see the difference between this issue and #251. In this one you're saying that the error message should be improved. In the other, you are saying that the case of the node not being present should be handled... Isn't handling this non-existent node the way of improving the error message? Or did you have something else in mind?

With this issue, I was trying to create a more general bug to ensure we are handling all the error cases, so far we have discovered two uncovered cases (non-existent pod and timeout) but there could be more. It means that by solving this issue we will implicitly solve #251.
In other words, you're right, they overlap so we could just keep this one given that it is more general.

Ah, I see. I'm not a fan of "general" issues, because it's hard to know when we are done improving all error messages. In that case, I think it's better to close this bug and then whenever we encounter an error message that's not helpful, make that one better.

Closing this bug as per previous discussion.


Update go.mod

🤔 What's changed?

This PR changes Go module name to github.com/cucumber/messages/go/v20.
⚡ What's your motivation?

Now that major version of this repo is v20 we need to update module path to match it.
🏷 What kind of change is this?

:bug: Bug fix (non-breaking change which fixes a defect)

(Patch release would be good to have, minor would also work).
♻ Anything particular you want feedback on?

📋 Checklist:

[x] I agree to respect and uphold the Cucumber Community Code of Conduct
[ ] I've changed the behaviour of the code

[ ] I have added/updated tests to cover my changes.

[ ] My change requires a change to the documentation.

[ ] I have updated the documentation accordingly.

[ ] Users should know about my change

[ ] I have added an entry to the "Unreleased" section of the CHANGELOG, linking to this pull request.

This text was originally generated from a template, then edited by hand. You can modify the template here.

Actually let me check for best practices of Go modules tagging in multi-language repos, maybe we can avoid this growth of major version and module name changes.

I've checked https://go.dev/ref/mod#vcs-version, and I think the best strategy for us would be to add a tag go/v19.1.5.
https://gophers.slack.com/archives/C9BMAAFFB/p1668439716487969

With that, we can keep separate version history for Go module and avoid unnecessary breaking changes (keep v19 for backwards compatible changes, regardless of the global version of the repo).
It still works for me now in clean env, although it uses a v19.0.0-x pseudo version.
go get -u github.com/cucumber/messages/go/v19

go: downloading github.com/cucumber/messages v20.0.0+incompatible
go: downloading github.com/cucumber/messages/go/v19 v19.0.0-20221114144107-23c09fbac7bf
go: downloading github.com/gofrs/uuid v4.2.0+incompatible
go: downloading github.com/gofrs/uuid v4.3.1+incompatible
go: added github.com/cucumber/messages/go/v19 v19.0.0-20221114144107-23c09fbac7bf
go: added github.com/gofrs/uuid v4.3.1+incompatible

This looks like a breaking change to me:
https://github.com/cucumber/messages/commit/3e35cc4a896ace580cab0b1547955afbbb0a5c0e#diff-eb5b86e55ac9e362d29fea7f08860b3ff35402d3aeb9baee57c4746ef629bcc9
That aside.
We're building a repository with many languages, where some of the changes are generated. We should avoid a situation where a maintainer needs to know the specifics of versioning for each language. So while keeping v19 would be optimal in these specific circumstances and we don't have to release a fix, it is not optimal in the general case.
I've made https://github.com/cucumber/polyglot-release/pull/86 to address this for future releases. This will ensure the next version of messages will be released with the v20 in the module name.

This looks like a breaking change to me:

This is indeed a breaking change, but it is unrelated to Go code.
Go library users might be annoyed by the need to upgrade their imports to sit on the latest version, while receiving no actual breaking changes. And also such import upgrades might have viral impact when another library depends on these identifiers, like for example if messages import is bumped, gherkin upgrade would also be a breaking change with new import (due to transitively exposed dependency like here).
If we could avoid unnecessary (unjustified) breaking changes, that would be kind for our users (and also maybe would make maintenance easier, as in example with gherkin).

We should avoid a situation where a maintainer needs to know the specifics of versioning for each language.

To me, this is a matter of what is more important, simplicity for maintainers or simplicity for users. As a Go library user, I really don't care about anything else that lives in this repo that isn't Go code. Go modules implementation allows having separate versioning to trade maintainer inconvenience into better user experience.

Since we don't maintain two major versions in parallel, is there a reason to version the module at all? Wouldn't the git version alone be sufficient?

I think the idea is to have it versioned from the start so that whenever you break compatibility, you are forced to also change the path:
https://github.com/golang/go/wiki/Modules#semantic-import-versioning

Ah. Thanks for the link. This was compelling:

Thus example.com/my/mod/mypkg is a different package than example.com/my/mod/v2/mypkg, and both may be imported in a single build, which among other benefits helps with diamond dependency problems and also allows a v1 module to be implemented in terms of its v2 replacement or vice versa.

@vearutop I'm considering the following scenarios:
If we don't automatically update the module name for a major version. I see the following scenarios:

A maintainer is unfamiliar the exact semantics of Go and forget to change the module name.

As a result we introduce a breaking change without changing the module name.

We notice before the next release and put in some work to roll this back. Some effort required.

Users annoyed by an unannounced breaking change

We don't notice until after the next release, now we can't roll back easily. More effort required.

Users annoyed by an unannounced breaking change
Users annoyed by having to report a breaking change + a delay to fixing

If we do automatically update the module name for a major version. I see the following scenarios:

We update the major version without breaking changes for Go

Users annoyed by a non-breaking module name change.

Unfortunately there are far fewer people able and willing to maintain and contribute to an open source project then those who want to use it. Especially one that includes 8 different languages. So if given the choice between spending the rather scarce maintainer time and running the risk of accidental breaking changes, or occasionally annoying users with a non-breaking module name change I would definitely favor the maintainers time and also avoid unannounced breaking changes.
But this doesn't mean I'm happy with the current situation. Your concerns about the viral nature of these updates is warranted. It is rather unfortunate that Gherkin has a dependency on Messages. Ideally this would not be the case. Rather the Gherkin parser would create an AST and from this AST the Messages would be created. This is a problem that I've talked about in the community before but I've just written https://github.com/cucumber/gherkin/issues/66 to make it permanent.

The module is now set to v21
https://github.com/cucumber/messages/blob/17a3298b9ba716d4c138436cb1b5dfb0dce74bfa/go/go.mod#L1

@vearutop I've just gone through the process of releasing gherkin with a changed module version in place. I think I much better understand the problem now. Going forward we'll not change the module version.

That's great, thank you!

Well, unfortunately we're not quite there yet.
We still have to check if we break the API and must upgrade the module. Does go have any automated tooling for this?


Expand .env values conversion ability of BaseConfig

Description
Initial (current):
'true' => true
'false' => false
all other strings => trimmed

Additional (proposed):
'12' => 12
'1.25' => 1.25
'null' => null
'empty' => ''

Supersedes and closes #5691
Fixes #5688
Checklist:

[x] Securely signed commits
[ ] Component(s) with PHPDoc blocks, only if necessary or adds value
[x] Unit testing, with >80% coverage
[x] User guide updated
[x] Conforms to style guide

I vote for php.
Type of variables out of the box.
No extra parsing needed.
=)

@iRedds See https://github.com/codeigniter4/CodeIgniter4/issues/5688#issuecomment-1037975842

The type cast must be inside.

What do you mean?
At least, I disagree with the current Paul's implementation, which both SimpleConfig.shortie = '12.45' and SimpleConfig.shortie = 12.45 are converted to float.

The type cast must be inside.

What do you mean?

$this->propertyExpectsInt = (int) env('property');

One other thing you may have accounted for but just to be sure, from https://www.php.net/manual/en/function.is-numeric :

8.0.0	Numeric strings ending with whitespace ("42 ") will now return true. Previously, false was return instead

The current and proposed behavior do not remove edge whitespaces, only edge quotes.
https://3v4l.org/p1At6
So, your example will have different values on php 8.

$this->propertyExpectsInt = (int) env('property');

The BaseConfig provides the feature to set properties of the object.
https://github.com/codeigniter4/CodeIgniter4/blob/968c0278a0ba4138cf3e64a2bbab5f3a800532d5/system/Config/BaseConfig.php#L72
https://github.com/codeigniter4/CodeIgniter4/blob/968c0278a0ba4138cf3e64a2bbab5f3a800532d5/system/Config/BaseConfig.php#L93

Please add test cases like these:
Foo.bar = '02471'
Foo.bar = 02471
Foo.bar = '1337e0'
Foo.bar = 1337e0
Foo.bar = ' 42'
Foo.bar = '42 '

@paulbalandan for database use case, is this will still works for password db: 123456 without quote?
database.default.password = 123456

#5779 was merged.


Problem: multi-lines separated with string

Here's my origianl note, the delimiter is ###:
Question 1.

Question 1 description.

---
Answer of question 1.

###
Question 2.

Question 2 description.

---
Answer of question 2.

When i checked on "Using content as title", the plugin responsed error of creating file. It seems like that the whole content become the title, not the first sentence.
It should creates "Question 1.md" and "Question 2.md".
Thanks.

Thanks for finding this. The markdown you posted was helpful in reproducing the issue.

Fixed in 1.1.1


std.socket: replace static this with crt_constructor

This is the only static this left in Phobos. Removing it makes for reducing need for ModuleInfo.

What's the purpose here ?

Seriously? No.

As in core.cpuid, the reason is having a static this means that a ModuleInfo will need to be generated for every object file that imports it. Since the static constructor has no dependencies on any other module, by initializing it with the C library constructor will not produce such dependencies.

It's just good engineering to eliminate unnecessary dependencies.

ModuleInfo also gets in the way of using betterC, which does not support ModuleInfo.

None of these are actually eliminating dependencies.

None of these are actually eliminating dependencies.

It eliminates the dependency on ModuleInfo and the dependency on druntime.

All pragma(crt_constructor) actually does is put a pointer to the function in a named section. Besides, std.socket relies on the existence of an operating system anyway, and that operating system will have the C standard library on board.

All pragma(crt_constructor) actually does is put a pointer to the function in a named section.

And so does shared static this.

Besides, std.socket relies on the existence of an operating system anyway, and that operating system will have the C standard library on board.

It also still relies on the existence of a D runtime, what with its use of new, exceptions, rtti, dynamic arrays, etc...
Anyway, this is not the way to do it.

Another approach to this:

https://github.com/dlang/phobos/pull/5813

#5813

108 lines of changes, abandoned as too much work

#5470

Also by Andrei, also a lot of work. Yeah, one could do lazy initialization, though one would lose the advantages of immutable variables.

And so does shared static this.

Yes, but shared static this comes with a requirement for ModuleInfo

It also still relies on the existence of a D runtime, what with its use of new, exceptions, rtti, dynamic arrays, etc...

Yes, but does not require ModuleInfo

It will possibly be using uninitialized GC, which can be catastrophic. It uses exceptions, which depends on runtime initialization anyway

The constructor does indeed throw, good catch. This can be fixed, as the error is fatal anyway.

I remember @deadalnix telling me how broken ModuleInfo is on DMD

I wish people would include bugzilla references when making statements like this.

It's also an annoying real issue I have at production code with huge inter-module dependencies.

Ironically, that's a reason for this PR.

Every time I include a module with a static this that also includes itself indirectly gets broken at runtime, on runtime initialization, and this is the biggest flaw of ModuleInfo.

Both modules have to have a static this to trigger an error. The error is:
object.Error@src/rt/minfo.d(364): Cyclic dependency between module constructors/destructors of test4x and test4

which is deliberate. With these cycles, how is the compiler to know which one gets run first? (At least D detects the error, with C one will arbitrarily get run first. If that isn't the right order, too bad.)
The solution is the user will have to specify which one comes first. The way to do that is to create a third module with just the static constructor in it that needs to run first, and have both modules import that module. That eliminates the dependency loop.
I don't know of any other way to do it that would be robust.

BTW, this static this is the last static constructor left in Phobos. Wouldn't it be nice to have it gone, too?

Every time I include a module with a static this that also includes itself indirectly gets broken at runtime, on runtime initialization, and this is the biggest flaw of ModuleInfo.

Both modules have to have a static this to trigger an error. The error is:
object.Error@src/rt/minfo.d(364): Cyclic dependency between module constructors/destructors of test4x and test4

which is deliberate. With these cycles, how is the compiler to know which one gets run first? (At least D detects the error, with C one will arbitrarily get run first. If that isn't the right order, too bad.)

Not both modules imported directly, but if they indirectly import one that has a static this, this happens. I understand the rationale of having this on the current implementation of ModuleInfo, but the thing is: we can provide alternatives, as already discussed in the forum for this problematic.

The solution is the user will have to specify which one comes first. The way to do that is to create a third module with just the static constructor in it that needs to run first, and have both modules import that module. That eliminates the dependency loop.
I don't know of any other way to do it that would be robust.

The creation of another module is the shenanigans I was talking about. And due to how ModuleInfo is designed, it potentially doesn't run. That works on one compiler invocation, but what if I compile that isolated module that doesn't get imported by anyone? Well, the linker eliminates those unused symbols.

Btw, isn't this a compiler bug, there's no nothrow attribute but it compiles?

The creation of another module is the shenanigans I was talking about.

How can the compiler determine which one should go first? Isn't it a failure of proper encapsulation for modules that each import each other? (I think some languages don't even allow that.)

The creation of another module is the shenanigans I was talking about. And due to how ModuleInfo is designed, it potentially doesn't run. That works on one compiler invocation, but what if I compile that isolated module that doesn't get imported by anyone? Well, the linker eliminates those unused symbols.

If you compile an isolated module, ~all symbols are unused. If a public section is removed, that's a compiler bug.

PR closed as stalled. If you wish to resurrect it you are welcome to do so.


Subscribing to wildcard topics with mqtt component

After subscribing to wildcard topics like sensor_a/# with mqtt.subscribe, the callback isn't triggered at all because mqtt_topic_subscriber checks if the event's topic is exactly equal to the wildcard topic passed to mqtt.subscribe. MQTT_CLIENT does actually subscribe to the wildcard topic, but mqtt_topic_subscriber prevents the appropriate callback from being called. Would it be possible to implement wildcard subscription and callbacks?

Thanks for reporting.
Merged fix 3bbeeda3acea72477d869c4b26d33add87b12ee9 into dev and master.

Thanks for the quick response.
Would it be possible to pass event.data[ATTR_TOPIC] instead of topic to callback, so the callback gets the expanded topic instead of the wildcard?
Also, there is a + wildcard that matches anything at its level (as described here). Could that be implemented? Something like:
def _match_topic(subscription, topic):
    """ Returns if topic matches subscription. """
    if subscription.endswith('#'):
        return subscription[:-2] == topic or topic.startswith(subscription[:-1])

    sub_parts = subscription.split('/')
    topic_parts = topic.split('/')

    return len(sub_parts) == len(topic_parts) and all(a == b for a, b in
        zip(sub_parts, topic_parts) if a != '+')

Thanks very much!

If you're going to write the code, opening a PR next time would be easier :wink:
Pushed your fixes for both, 6e98e55f6a88457a1a30ac8171895dc78048b59f, to master and dev. Thanks!


Let IRgen compile predicate IR modules specifically.

Previously we were just compiling scripts and predicates as the same and so predicates were compiled to script modules.
Closes #1655.

#1655 talks about ASM checks but they're managed in #2550, which was basically blocked by this.

Hrmm, shoulda probably run the tests myself instead of just :crossed_fingers: and :pray:.

instead of just 🤞 and 🙏

I thought that's what CI is for 😆


feat: esm migration

Description
This adds ESM support to js-events. ESM version will be 4.x version. So that continue updating 3.x for anything related to commonjs.
Issues Fixed

Relates to https://github.com/MatrixAI/js-async-init/pull/32

Tasks

[x] 1. Migrate
[ ] 2. Update to version 4.x.

Final checklist

[ ] Domain specific tests
[ ] Full tests
[ ] Updated inline-comment documentation
[ ] Lint fixed
[ ] Squash and rebased
[ ] Sanity check the final build

Version update to 4.x will be done in staging. @tegefaulkes @amydevs


Support for encrypted workbook

Can you please describe the scenario and what you are looking for? Feel free to reopen with more details.


XD support

awesome library, just tested on a sketch file and it magically gave all the info, just wondering if any plan to port it for adobe xd? There is already one in python https://github.com/umar-ahmed/xdtools/blob/master/xdtools/utils/parser.py

I would love to port it to Adobe XD! I would definitely need some help though, I'm not as familiar with it as Sketch. It would also be cool to have an abstraction on top of both where you could create both XD and Sketch files from the same code.

@dbanksdesign  could you please link me to a resource where all the data specifications are listed for a sketch file? like what kind of data a sktech file contains? Thanks

I don't... what I've been doing is creating sketch files, unzipping the content and inspecting the JSON.. It's not a fun process.

@RazaGR and @dbanksdesign
This may help with Sketch data specifications
https://github.com/darknoon/sketchapp-json-flow-types/blob/master/types.js
Would be great to have some documentation on what each property does, but that would be a very big job.


Missing rules

Hi! It seems like the following rules are defined in the NativeMinimumRules.ruleset file (for Visual Studio 2022) but not listed on this page:
C28308
C28309
C33001
C33010
C33020

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

ID: 7cb78651-8c5e-c4c3-e1d2-dfaeacc013cc
Version Independent ID: ee7e71b0-2d2c-e5db-d850-41a1906607df
Content: Native Minimum Rules rule set - Visual Studio (Windows)
Content Source: docs/code-quality/native-minimum-rules-rule-set.md
Product: visual-studio-windows
Technology: vs-ide-code-analysis
GitHub Login: @Mikejo5000
Microsoft Alias: mikejo

@gwtov I see those rules documented in this section for C++: https://learn.microsoft.com/en-us/cpp/code-quality/c33020?view=msvc-170
It's easy to miss, but this section is the legacy section for the .NET analyzers.


macOS app cannot connect to http://localhost:4466/config

Description
MacOS app does not get beyond "Wait while fetching clusters..." state. Cannot connect to http://localhost:4466/config.
Impact
App seems completely dysfunctional.
Environment and steps to reproduce

Set-up: macOS Big Sur v11.0.1 (20B29), Headlamp Version 0.1.0 (0.1.0)
Task: Launched the App
Action(s):
Error: See below

Expected behavior
Expected to see some clusters, kubectl context or similar.
Additional information
Screenshots

Hi @marians ! Do you have a kube config with clusters/contexts set up when you started Headlamp?
We may have a bug when no kube config is found locally and we'll be looking into this tomorrow. In the meanwhile if you can confirm whether you had a kube config set up in the default path before running Headlamp (or add it and restart Headlamp), it would be awesome!
Thank you for your help in advance!

Yes, I have a ~/.kube/config file with lots of contexts.

We will be releasing a new version hopefully today that fixes a bug in the server start up. Hopefully this will fix your issues, but if not, I will ask you to please provide more information afterwards. Stay tuned!

Hi @marians , sorry it took us a while.
We're still preparing the new release with a few bug fixes. In the meanwhile I think I may have reproduced your problem: I noticed that when we quit the application, the server is still running (ps aux|grep Headlamp).
We will obviously include a fix for this in the next release. Thanks.

I also have this issue. I have a kube config in the same location and get the same issue while attempting to load clusters.

Also @joaquimrocha that solution doesn't work for me. When I quit headlamp, there are no processes with headlamp or Headlamp showing when I ps.

Just want to mention that the problem still persists in v0.1.3

Just want to mention that the problem still persists in v0.1.3

Hi @marians thanks for reporting this, I might be asking too much but can you please give a brief details on the specific steps you followed while running headlamp.
Coz we tried it on Mac OS catalina and the app seems to work fine.

Hi @marians thanks for reporting this, I might be asking too much but can you please give a brief details on the specific steps you followed while running headlamp.
Coz we tried it on Mac OS catalina and the app seems to work fine.

It really hasn't changed from the initial comment, only that I tried headlamp v0.1.3 now.
OS: macOS Big Sur 11.1 (20C69)
$ pwd
/Applications/Headlamp.app/Contents/MacOS

$ ./Headlamp --enable-logging
09:55:28.353 › App starting...
09:55:28.471 › Checking for update
09:55:28.471 › Sending status to window: Checking for update...
[75378:0107/095529.032073:INFO:CONSOLE(1)] "[object Object]", source: file:///Applications/Headlamp.app/Contents/Resources/app.asar/build/static/js/main.d0a4d88d.chunk.js (1)
[75378:0107/095529.061476:INFO:CONSOLE(1)] "TypeError: Failed to fetch", source: file:///Applications/Headlamp.app/Contents/Resources/app.asar/build/static/js/main.d0a4d88d.chunk.js (1)
[75378:0107/095529.061624:INFO:CONSOLE(1)] "TypeError: Failed to fetch", source: file:///Applications/Headlamp.app/Contents/Resources/app.asar/build/static/js/main.d0a4d88d.chunk.js (1)
[75378:0107/095529.061866:INFO:CONSOLE(1)] "TypeError: Failed to fetch", source: file:///Applications/Headlamp.app/Contents/Resources/app.asar/build/static/js/main.d0a4d88d.chunk.js (1)
[75378:0107/095529.062125:INFO:CONSOLE(1)] "TypeError: Failed to fetch", source: file:///Applications/Headlamp.app/Contents/Resources/app.asar/build/static/js/main.d0a4d88d.chunk.js (1)
[75378:0107/095529.062296:INFO:CONSOLE(1)] "TypeError: Failed to fetch", source: file:///Applications/Headlamp.app/Contents/Resources/app.asar/build/static/js/main.d0a4d88d.chunk.js (1)
[75378:0107/095529.085540:INFO:CONSOLE(0)] "Uncaught (in promise) TypeError: Failed to fetch", source: file:///Applications/Headlamp.app/Contents/Resources/app.asar/build/index.html#/ (0)
09:55:30.120 › Update for version 0.1.3 is not available (latest version: 0.1.3, downgrade is disallowed).
09:55:30.121 › Sending status to window: Update not available.
09:55:30.121 › checkForUpdatesAndNotify called, downloadPromise is null
[75378:0107/095546.776378:VERBOSE1:CONSOLE(31)] "Main._createAppUI: 23.35009765625 ms", source: devtools://devtools/bundled/main/main.js (31)
[75378:0107/095546.786152:VERBOSE1:CONSOLE(31)] "Main._showAppUI: 9.378173828125 ms", source: devtools://devtools/bundled/main/main.js (31)
[75378:0107/095546.820768:VERBOSE1:CONSOLE(31)] "Main._initializeTarget: 5.876953125 ms", source: devtools://devtools/bundled/main/main.js (31)
[75378:0107/095546.953201:VERBOSE1:CONSOLE(31)] "Main._lateInitialization: 0.56298828125 ms", source: devtools://devtools/bundled/main/main.js (31)
2021-01-07 09:55:47.086 Headlamp[75378:1640539] Warning: Expected min height of view: (<NSPopoverTouchBarItemButton: 0x7f9f40aea1f0>) to be less than or equal to 30 but got a height of 32.000000. This error will be logged once per view in violation.
[75378:0107/095629.079740:INFO:CONSOLE(1)] "TypeError: Failed to fetch", source: file:///Applications/Headlamp.app/Contents/Resources/app.asar/build/static/js/main.d0a4d88d.chunk.js (1)
[75378:0107/095629.084842:INFO:CONSOLE(1)] "TypeError: Failed to fetch", source: file:///Applications/Headlamp.app/Contents/Resources/app.asar/build/static/js/main.d0a4d88d.chunk.js (1)
[75378:0107/095629.085725:INFO:CONSOLE(1)] "TypeError: Failed to fetch", source: file:///Applications/Headlamp.app/Contents/Resources/app.asar/build/static/js/main.d0a4d88d.chunk.js (1)
[75378:0107/095629.086158:INFO:CONSOLE(1)] "TypeError: Failed to fetch", source: file:///Applications/Headlamp.app/Contents/Resources/app.asar/build/static/js/main.d0a4d88d.chunk.js (1)
[75378:0107/095629.086782:INFO:CONSOLE(1)] "TypeError: Failed to fetch", source: file:///Applications/Headlamp.app/Contents/Resources/app.asar/build/static/js/main.d0a4d88d.chunk.js (1)
2021-01-07 09:56:49.587 Headlamp[75378:1640539] Warning: Expected min height of view: (<NSPopoverTouchBarItemButton: 0x7f9f3aff2b20>) to be less than or equal to 30 but got a height of 32.000000. This error will be logged once per view in violation.
[75379:0107/095649.594547:ERROR:gles2_cmd_decoder.cc(7062)] [.RendererMainThread-0x7fc8d6063c00]GL ERROR :GL_INVALID_OPERATION : glGetIntegerv: incomplete framebuffer
[75379:0107/095649.594896:ERROR:gles2_cmd_decoder.cc(7062)] [.RendererMainThread-0x7fc8d6063c00]GL ERROR :GL_INVALID_OPERATION : glGetIntegerv: incomplete framebuffer
[75379:0107/095649.595278:ERROR:gles2_cmd_decoder.cc(7062)] [.RendererMainThread-0x7fc8d6063c00]GL ERROR :GL_INVALID_OPERATION : glGetIntegerv: incomplete framebuffer
[75379:0107/095649.595411:ERROR:gles2_cmd_decoder.cc(7062)] [.RendererMainThread-0x7fc8d6063c00]GL ERROR :GL_INVALID_OPERATION : glGetIntegerv: incomplete framebuffer
[75379:0107/095649.600886:ERROR:gles2_cmd_decoder.cc(4968)] [.RendererMainThread-0x7fc8d6063c00]GL ERROR :GL_INVALID_FRAMEBUFFER_OPERATION : glDrawArrays: framebuffer incomplete

ps aux|grep Headlamp yields nothing, not before and not after I launch the app.
Screenshot

It really hasn't changed from the initial comment, only that I tried headlamp v0.1.3 now.
OS: macOS Big Sur 11.1 (20C69)
$ pwd
/Applications/Headlamp.app/Contents/MacOS

$ ./Headlamp --enable-logging
09:55:28.353 › App starting...
09:55:28.471 › Checking for update
09:55:28.471 › Sending status to window: Checking for update...
[75378:0107/095529.032073:INFO:CONSOLE(1)] "[object Object]", source: file:///Applications/Headlamp.app/Contents/Resources/app.asar/build/static/js/main.d0a4d88d.chunk.js (1)
[75378:0107/095529.061476:INFO:CONSOLE(1)] "TypeError: Failed to fetch", source: file:///Applications/Headlamp.app/Contents/Resources/app.asar/build/static/js/main.d0a4d88d.chunk.js (1)
[75378:0107/095529.061624:INFO:CONSOLE(1)] "TypeError: Failed to fetch", source: file:///Applications/Headlamp.app/Contents/Resources/app.asar/build/static/js/main.d0a4d88d.chunk.js (1)
[75378:0107/095529.061866:INFO:CONSOLE(1)] "TypeError: Failed to fetch", source: file:///Applications/Headlamp.app/Contents/Resources/app.asar/build/static/js/main.d0a4d88d.chunk.js (1)
[75378:0107/095529.062125:INFO:CONSOLE(1)] "TypeError: Failed to fetch", source: file:///Applications/Headlamp.app/Contents/Resources/app.asar/build/static/js/main.d0a4d88d.chunk.js (1)
[75378:0107/095529.062296:INFO:CONSOLE(1)] "TypeError: Failed to fetch", source: file:///Applications/Headlamp.app/Contents/Resources/app.asar/build/static/js/main.d0a4d88d.chunk.js (1)
[75378:0107/095529.085540:INFO:CONSOLE(0)] "Uncaught (in promise) TypeError: Failed to fetch", source: file:///Applications/Headlamp.app/Contents/Resources/app.asar/build/index.html#/ (0)
09:55:30.120 › Update for version 0.1.3 is not available (latest version: 0.1.3, downgrade is disallowed).
09:55:30.121 › Sending status to window: Update not available.
09:55:30.121 › checkForUpdatesAndNotify called, downloadPromise is null
[75378:0107/095546.776378:VERBOSE1:CONSOLE(31)] "Main._createAppUI: 23.35009765625 ms", source: devtools://devtools/bundled/main/main.js (31)
[75378:0107/095546.786152:VERBOSE1:CONSOLE(31)] "Main._showAppUI: 9.378173828125 ms", source: devtools://devtools/bundled/main/main.js (31)
[75378:0107/095546.820768:VERBOSE1:CONSOLE(31)] "Main._initializeTarget: 5.876953125 ms", source: devtools://devtools/bundled/main/main.js (31)
[75378:0107/095546.953201:VERBOSE1:CONSOLE(31)] "Main._lateInitialization: 0.56298828125 ms", source: devtools://devtools/bundled/main/main.js (31)
2021-01-07 09:55:47.086 Headlamp[75378:1640539] Warning: Expected min height of view: (<NSPopoverTouchBarItemButton: 0x7f9f40aea1f0>) to be less than or equal to 30 but got a height of 32.000000. This error will be logged once per view in violation.
[75378:0107/095629.079740:INFO:CONSOLE(1)] "TypeError: Failed to fetch", source: file:///Applications/Headlamp.app/Contents/Resources/app.asar/build/static/js/main.d0a4d88d.chunk.js (1)
[75378:0107/095629.084842:INFO:CONSOLE(1)] "TypeError: Failed to fetch", source: file:///Applications/Headlamp.app/Contents/Resources/app.asar/build/static/js/main.d0a4d88d.chunk.js (1)
[75378:0107/095629.085725:INFO:CONSOLE(1)] "TypeError: Failed to fetch", source: file:///Applications/Headlamp.app/Contents/Resources/app.asar/build/static/js/main.d0a4d88d.chunk.js (1)
[75378:0107/095629.086158:INFO:CONSOLE(1)] "TypeError: Failed to fetch", source: file:///Applications/Headlamp.app/Contents/Resources/app.asar/build/static/js/main.d0a4d88d.chunk.js (1)
[75378:0107/095629.086782:INFO:CONSOLE(1)] "TypeError: Failed to fetch", source: file:///Applications/Headlamp.app/Contents/Resources/app.asar/build/static/js/main.d0a4d88d.chunk.js (1)
2021-01-07 09:56:49.587 Headlamp[75378:1640539] Warning: Expected min height of view: (<NSPopoverTouchBarItemButton: 0x7f9f3aff2b20>) to be less than or equal to 30 but got a height of 32.000000. This error will be logged once per view in violation.
[75379:0107/095649.594547:ERROR:gles2_cmd_decoder.cc(7062)] [.RendererMainThread-0x7fc8d6063c00]GL ERROR :GL_INVALID_OPERATION : glGetIntegerv: incomplete framebuffer
[75379:0107/095649.594896:ERROR:gles2_cmd_decoder.cc(7062)] [.RendererMainThread-0x7fc8d6063c00]GL ERROR :GL_INVALID_OPERATION : glGetIntegerv: incomplete framebuffer
[75379:0107/095649.595278:ERROR:gles2_cmd_decoder.cc(7062)] [.RendererMainThread-0x7fc8d6063c00]GL ERROR :GL_INVALID_OPERATION : glGetIntegerv: incomplete framebuffer
[75379:0107/095649.595411:ERROR:gles2_cmd_decoder.cc(7062)] [.RendererMainThread-0x7fc8d6063c00]GL ERROR :GL_INVALID_OPERATION : glGetIntegerv: incomplete framebuffer
[75379:0107/095649.600886:ERROR:gles2_cmd_decoder.cc(4968)] [.RendererMainThread-0x7fc8d6063c00]GL ERROR :GL_INVALID_FRAMEBUFFER_OPERATION : glDrawArrays: framebuffer incomplete

ps aux|grep Headlamp yields nothing, not before and not after I launch the app.
Screenshot

Thanks a lot @marians . We are currently looking into this. We'll get back to you soon.

Thanks a lot @marians . We are currently looking into this. We'll get back to you soon.

Hi @marians,
I tried, but failed so far to reproduce in Catalina and Big Sur 11.1.
Looking at the connection refused tracebacks, I wonder if you can help me with these questions?

is there perhaps a firewall/IDS blocking these?
what are the localhost details? Maybe it's some sort of ipv4/v6 related thing.

dscacheutil -q host -a name localhost
ifconfig lo0

$ dscacheutil -q host -a name localhost
name: localhost
ipv6_address: ::1
ipv6_address: fe80:1::1

name: localhost
ip_address: <IP_ADDRESS>

$ ifconfig lo0
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> mtu 16384
	options=1203<RXCSUM,TXCSUM,TXSTATUS,SW_TIMESTAMP>
	inet <IP_ADDRESS> netmask 0xff000000
	inet6 ::1 prefixlen 128
	inet6 fe80::1%lo0 prefixlen 64 scopeid 0x1
	nd6 options=201<PERFORMNUD,DAD>

Hi @marians,
I tried, but failed so far to reproduce in Catalina and Big Sur 11.1.
Looking at the connection refused tracebacks, I wonder if you can help me with these questions?

is there perhaps a firewall/IDS blocking these?
what are the localhost details? Maybe it's some sort of ipv4/v6 related thing.

dscacheutil -q host -a name localhost
ifconfig lo0

$ dscacheutil -q host -a name localhost
name: localhost
ipv6_address: ::1
ipv6_address: fe80:1::1

name: localhost
ip_address: <IP_ADDRESS>

$ ifconfig lo0
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> mtu 16384
	options=1203<RXCSUM,TXCSUM,TXSTATUS,SW_TIMESTAMP>
	inet <IP_ADDRESS> netmask 0xff000000
	inet6 ::1 prefixlen 128
	inet6 fe80::1%lo0 prefixlen 64 scopeid 0x1
	nd6 options=201<PERFORMNUD,DAD>

I am not aware of any firewall running.

$ dscacheutil -q host -a name localhost
name: localhost
ipv6_address: ::1

name: localhost
ip_address: <IP_ADDRESS>

$ ifconfig lo0
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> mtu 16384
	options=1203<RXCSUM,TXCSUM,TXSTATUS,SW_TIMESTAMP>
	inet <IP_ADDRESS> netmask 0xff000000
	inet6 ::1 prefixlen 128
	inet6 fe80::1%lo0 prefixlen 64 scopeid 0x1
	nd6 options=201<PERFORMNUD,DAD>

I am not aware of any firewall running.

$ dscacheutil -q host -a name localhost
name: localhost
ipv6_address: ::1

name: localhost
ip_address: <IP_ADDRESS>

$ ifconfig lo0
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> mtu 16384
	options=1203<RXCSUM,TXCSUM,TXSTATUS,SW_TIMESTAMP>
	inet <IP_ADDRESS> netmask 0xff000000
	inet6 ::1 prefixlen 128
	inet6 fe80::1%lo0 prefixlen 64 scopeid 0x1
	nd6 options=201<PERFORMNUD,DAD>

Thanks @marians for the info.
We added some extra logging for the server errors in the new v0.2.0 release - so we should see the reason why the server process is not working. This release should give us nice stack traces in the dev console, rather than showing minimized js in the dev console too.

Thanks @marians for the info.
We added some extra logging for the server errors in the new v0.2.0 release - so we should see the reason why the server process is not working. This release should give us nice stack traces in the dev console, rather than showing minimized js in the dev console too.

Maybe the new release sheds some light on my problems.
11:21:02.761 › server process stderr: panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0xd0 pc=0x16287a5]

goroutine 1 [running]:
main.GetContextsFromKubeConfigFile(0xc0000cb0e0, 0x1a, 0x169c9c0, 0xc000238dd8, 0xc000213c38, 0xc000238dd0, 0x4c000000010651b4)
	/Users/joaquim/work/headlamp/backend/cmd/kubeconfig.go:52 +0x1c5
main.StartHeadlampServer(0xc000202700)
	/Users/joaquim/work/headlamp/backend/cmd/headlamp.go:105 +0x118b
main.main()
	/Users/joaquim/work/headlamp/backend/cmd/server.go:30 +0x4d7

11:21:02.769 › server process process exited with code:2 signal:null

Maybe the new release sheds some light on my problems.
11:21:02.761 › server process stderr: panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0xd0 pc=0x16287a5]

goroutine 1 [running]:
main.GetContextsFromKubeConfigFile(0xc0000cb0e0, 0x1a, 0x169c9c0, 0xc000238dd8, 0xc000213c38, 0xc000238dd0, 0x4c000000010651b4)
	/Users/joaquim/work/headlamp/backend/cmd/kubeconfig.go:52 +0x1c5
main.StartHeadlampServer(0xc000202700)
	/Users/joaquim/work/headlamp/backend/cmd/headlamp.go:105 +0x118b
main.main()
	/Users/joaquim/work/headlamp/backend/cmd/server.go:30 +0x4d7

11:21:02.769 › server process process exited with code:2 signal:null

I identified another reason that caused headlamp to exit. In my kubeconfig I had cluster entries with relative path in certificate-authority. The path was relative from my ~/.kube directory. For kubectl that seems to work, but the headlamp backend exits with this error:
*** Headlamp Server ***
  API Routers:
2021/01/19 17:15:57 Failed to add certificate:open certs/gs-gollum/k8s-ca.crt: no such file or directory

After I change this to an absolute path, the backend seems to come up.

I identified another reason that caused headlamp to exit. In my kubeconfig I had cluster entries with relative path in certificate-authority. The path was relative from my ~/.kube directory. For kubectl that seems to work, but the headlamp backend exits with this error:
*** Headlamp Server ***
  API Routers:
2021/01/19 17:15:57 Failed to add certificate:open certs/gs-gollum/k8s-ca.crt: no such file or directory

After I change this to an absolute path, the backend seems to come up.

I added a relative path issue https://github.com/kinvolk/headlamp/issues/180

I added a relative path issue https://github.com/kinvolk/headlamp/issues/180

The relative path issue was fixed and merged in #181
@marians it seems like it's working for you now :) Thanks for all your help.
Can we close this issue now, or is there something else?

The relative path issue was fixed and merged in #181
@marians it seems like it's working for you now :) Thanks for all your help.
Can we close this issue now, or is there something else?

Sure, do what suits you. If I run into problems again (with a new release), I'll let you know.

Sure, do what suits you. If I run into problems again (with a new release), I'll let you know.

@marians Hi, if you have the bandwidth, I'd love you to know if everything is working fine for you with the latest 0.3.0-beta now.

Let's close this as it seems to be running well on Macs now.


VWeb UI stops unexpectedly

I am on a Windows operating system. I have tried using vegalite.js in my application. Everything works fine, until I click Save as SVG menu item near the plots. VWeb UI will then close, and the application breaks.

Kindly find below the code I have:
`import vwebui as ui
const html = '

Visit W3Schools.com!
My First plot

'
w := ui.new_window()
w.show_browser(html, .chrome)!
ui.wait()
`

import vwebui as ui

const html = '<!DOCTYPE html>

    Visit W3Schools.com!

My First plot

'

w := ui.new_window()
w.show_browser(html, .chrome)!
ui.wait()

@AlbertShown Upon investigation, imho, the problem relates less to using webui, but more to using the vega-embed CDN script. For example, the same problem occurs with the original webui library.

webui C code
#include "webui.h"

int main() {
  const char *html = "<!DOCTYPE html>"
      ""
      "  "
      "    "
      "  "
      "  "
      "    Visit W3Schools.com!"
      "
My First plot
"
      "
"
      "

"
      "  "
      ""
      "";

  size_t w = webui_new_window();

  webui_show(w, html);
  webui_wait();
  webui_clean();

  return 0;
}

The error could be handled more gracefully though instead of crashing. For example, with webview, the 'Save as SVG' menu item doesn't work, but it doesn't crash.

webview V code
import ttytm.webview as ui

const html = '<!DOCTYPE html>

'

w := ui.create(debug: true)
w.set_size(600, 400, .@none)
w.set_html(html)
w.run()

To my current knowledge it's hard to tell the real source of the issue. Personally, I won't dig into it. Something you could try  @sainthasras is using the vega-embed not as cdn script and debug there.

I will try as suggested. Thank you....very grateful.

Oh yes, crash is the wrong term here. Do you have an opinion on whether there should be a handling other than closing a connection when navigating to a URL that doesn't embed webui.js?

It really feels good when one realizes their problems are being given all the necessary attention they require. I must also say, crash is the wrong term (maybe because of the way I presented the problem). The application does not crash, just that it disconnects. Thank you once again for the effort you are putting in to resolve this.


ci: do not run commitlint on master branch

Resolves

Resolves ENA-199

Proposed Changes

Skip commitlint on the master branch

Reason for Changes
We do not want to re-write commit history on these "main" branches. Commit messages that do not follow conventional commit should be caught in other branches. However, this way the CI won't fail if they are merged to one of these branches.
Test Coverage

Ran circleci config validate to validate the configuration

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

npm package (@latest dist-tag)
GitHub release

Your semantic-release bot :package::rocket:


groupBy doesn't print grouped columns

Columns selected in -g are not printed as before.
Tool:    bedtools groupby
Version: v2.26.0

test file
chr1    135321  138328  K00177  0       +

intersectBed -a test -b 3utr.bed -wa -wb returns:
chr1    135321  138328  K00177  0       +       chr1    134900  135802  3utr
chr1    135321  138328  K00177  0       +       chr1    137620  138529  3utr

when I use intersectBed with groupBy like intersectBed -a test -b 3utr.bed -wa -wb | groupBy -i - -g 1,2,3,4,5,6 -c 10 -o distinct, it prints only column 10:
3utr

There is an unreleased fix for this in master.

Sorry for the trouble. Unfortunate oversight in last release :(

Thanks @arq5x, I'll download the master and try it.

encountered error while making the executables
- Building in src/groupBy
  * compiling groupBy.cpp
groupBy.cpp: In member function ‘virtual void GroupBy::processHits(RecordOutputMgr*, RecordKeyVector&)’:
groupBy.cpp:85:28: error: invalid conversion from ‘RecordKeyVector::elemType {aka const Record*}’ to ‘Record*’ [-fpermissive]
  Record *rec = hits.getKey();
                            ^
groupBy.cpp: In member function ‘virtual void GroupBy::cleanupHits(RecordKeyVector&)’:
groupBy.cpp:107:2: error: ‘iterator_type’ is not a member of ‘RecordKeyVector’
  RecordKeyVector::iterator_type iter = hits.begin();
  ^
groupBy.cpp:107:33: error: expected ‘;’ before ‘iter’
  RecordKeyVector::iterator_type iter = hits.begin();
                                 ^
groupBy.cpp:108:9: error: ‘iter’ was not declared in this scope
  for (; iter != hits.end(); iter = hits.next())
         ^
make[1]: *** [../../obj//groupBy.o] Error 1
make: *** [src/groupBy] Error 2

Fixed groupBy.cpp by changing line 85
const Record *rec = hits.getKey();
and line 107
RecordKeyVector::const_iterator_type iter = hits.begin();

Apologies - the repo is in a state of flux. I will try to stabilize all of this over the next few days.


feat: initial code

Codecov Report

:exclamation: No coverage uploaded for pull request base (master@54c8144). Click here to learn what that means.
The diff coverage is 100%.

@@           Coverage Diff           @@
##             master     #1   +/-   ##
=======================================
  Coverage          ?   100%
=======================================
  Files             ?      1
  Lines             ?     66
  Branches          ?      0
=======================================
  Hits              ?     66
  Misses            ?      0
  Partials          ?      0

Impacted Files
Coverage Δ

addon/index.js
100% <100%> (ø)

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 54c8144...b40c83a. Read the comment docs.


.NET 8 Dependencies

.NET8 support added

Hi @javierpardollama !
Since there are no breaking changes, and we keep the compatibility with .NET6 and .NET7, the version of the library should be 2.1.0 instead of 3.0.0.


Update test runners to Fedora 39

Use Fedora 39 to run tests.
Update test examples.

Something odd happening with the merge queue.  Investigating.

Found an issue with building while looking into this (see #367).  Not sure what the cause of the merge-queue failure was but it might be related to all the rebuilds that were happening because of it.

More info: Flakiness + retries don't mix well with the merge-queue.  For example, right now the CI in gitlab is technically in progress still without a failure, but there is a build that failed with:
[ERROR] depsolve failed: DNF error occurred: RepoError: There was a problem reading a repository: Failed to download metadata for repo 'a696f78f8fe604ad238f1034c062b09c7a9ddb6d2016a83944e0f0685ab84e9f' [appstream: https://rpmrepo.osbuild.org/v2/mirror/rhvpn/el8/el8-x86_64-appstream-r8.5-20230809]: Yum repo downloading error: Downloading error(s): repodata/b591d9fa12e0ba5c6d75b84b605f44c1daefd514068152a3fd8ba53fdb5975eb-primary.xml.gz - Cannot download, all mirrors were already tried without success; repodata/689bd45a22fedbffbc3e3b9d82109a2c6ed02ee8b2962136d63a3026f24d6ef0-filelists.xml.gz - Cannot download, all mirrors were already tried without success; repodata/167822ee59a5cbd329d31b2ff030cb2146b0fd624e390ffe3ac98fb641fb62f4-comps-AppStream.x86_64.xml.gz - Cannot download, all mirrors were already tried without success; repodata/d12f84e558ef647914eb6d20f034920765390d579888595800f915a133457a22-modules.yaml.gz - Cannot download, all mirrors were already tried without success

This is now being retried and will most likely succeed.
Whenever a test fails, before it's retried, it updates the test status on GitHub to failed.  If this happens on the merge-queue, the PR is removed from the queue and if the retry succeeds after that, you get into the interesting situation where:

The CI run in GitLab is green (after retries) but,
GitHub says it removed the PR from the queue because of a failure.

I think we can solve this by removing the update_github_status run from each pipeline and defining a new job with when: on_failure to update the status only when everything has been retried and is still failing.


Logs are not being written in Azure Application Insights

I have raised the same issue in the below repo as well, so providing the issue link below.
Serilog.Sinks.ApplicationInsights version: 4.0.0
https://github.com/serilog-contrib/serilog-sinks-applicationinsights

Please close this, and note the responses on https://github.com/serilog/serilog/issues/1892
This issues provides no relevant information as to how to reproduce a bug.


Add information about environment variables in local development

Just a small suggestion to add:

an example of resin-sync.yml modifications for local environment variables
an information stating that you need to force the build of the container again for modifications to be applied
I spent quite a lot of time to figure all this out, so I believe it could be good to share.

Need to get resinCI to work on this

@resin-ci retest

@resin-ci retest

This is now redundant as both balena sync and balena local push have been deprecated.


[QuickAccent] Adding Asturian diacritics

Description of the new feature / enhancement
As an Asturian speaker (a language from the north of Spain spoken by at least 600 thousand people), it would be very useful if you could add Asturian special letters to the Spanish category as these are not available on normal keyboards. :) Since I imagine it's probably not worth adding an entire category just for the Asturian language, I propose adding them as part of the broader set of Spanish diacritics.
These are:

Ḥ (U+1E24)
ḥ (U+1E24)
Ḷ (U+1E36)
ḷ (U+1E37)

Scenario when this would be used?
When typing Asturian place names and some foreign words (some of the most common words with these letters include Ḷḷena, Ḷḷuarca, Ḷḷaciana, Ḷḷuna, guaḥe, ḥoquei, Ḥuentesanta, etc.)
Supporting information
The Wikipedia article on the language: https://en.wikipedia.org/wiki/Asturian_language#Dialectal_spellings

Could I take this issue? or it is already solved by someone else?

Hey @dragoaus I am currently in progress on this issue.

The work associated with this issue has been released as part of the 0.75 sprint. Please update PowerToys to the latest. https://github.com/microsoft/PowerToys/releases


icu-language option

Added documentation to icu-language option

Docs for https://github.com/arangodb/arangodb/pull/15912

[ ] https://jenkins.arangodb.biz:3456/view/Documentation/job/arangodb-ANY-examples/1783/


ResponseModel does not force model

Is there a way to force the the response to be equal the response_model?
class Item(BaseModel):
    id: int
    shortcut: str
    name: str

@app.get("/items/{item_id}", response_model=Item)
async def get_all_items(item_id: int):
    """Return all assocations."""
    item = {"name": "name", "size": "size"}
    return JSONResponse(status_code=status.HTTP_200_OK, content=item)

I would expect, that the response failed cause it is not aligned with the model. Any advice?

You should not return a JSONResponse instance if you want FastAPI to handle your models.
class Item(BaseModel):
    id: int
    shortcut: str
    name: str

@app.get("/items/{item_id}", response_model=Item)
async def get_all_items(item_id: int):
    """Return all assocations."""
    item = {"name": "name", "size": "size"}
    return item

But this will raise an error. Can you see why?
SPOILER ALERT!!!
Because you have the field shortcut and is a required one!!! How do we solve it? There are several ways, I'll show you the simplest for me:
class Item(BaseModel):
    id: int
    shortcut: Optional[str]
    name: str

@app.get("/items/{item_id}", response_model=Item)
async def get_all_items(item_id: int):
    """Return all assocations."""
    item = {"name": "name", "size": "size"}
    return item

As I mentioned, I was expecting the error. Thanks for clarify how to return it.
Will add the status code with the response object instead.

Thanks for the help here @Kludex ! :clap: :bow:
Thanks for reporting back and closing the issue @datenwort  :+1:


Adopt to breaking change in API of openDTU-onBattery greater 2024.02.09

Describe the Problem
The latest working version of openDTU-onBattery is  '2024.02.09'.
When using a younger version, current.log contains the message 'You do not have the latest OpenDTU Version to run this script,please upgrade your OpenDTU to at least version 4.4.3'.
Refer to [(https://github.com/hoylabs/OpenDTU-OnBattery/releases?page=2)].
Device you are using
Steps to reproduce the behavior:

Which Venus OS are you using? => v3.51
Which Victron Device? => Cerbo GX
Which DTU? => openDTU-onBattery (generic_esp32), version=2024.02.12 or later
Which Template Device?
=> Three Hoymiles inverters are connected to the openDTU box.

1st inverter
[INVERTER0]
Phase=3P
DeviceInstance=34
AcPosition=0
2nd inverter
[INVERTER1]
Phase=3P
DeviceInstance=35
AcPosition=0
3rd inverter
[INVERTER2]
Phase=L1
DeviceInstance=36
AcPosition=1
Expected behavior
The script should support different web API versions in parallel and neither force the user to stay at an older openDTU version nor to upgrade to a new version.
Screenshots
Additional context
openDTU_livedata_status.json

OK - will check again later that day and revert to you.
Kind regards,
Christoph
henne49 @.***> schrieb am Do., 14. Nov. 2024, 17:06:

Please upgrade, I have tested with opendtu on battery 2024.06.03
https://github.com/helgeerbe/OpenDTU-OnBattery/releases/tag/2024.06.03
and it works with the latest version of our script
—
Reply to this email directly, view it on GitHub
https://github.com/henne49/dbus-opendtu/issues/224#issuecomment-2476808825,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/A3YYKZGKAVEIET463EOR4PT2ATDBLAVCNFSM6AAAAABRZCRLECVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDINZWHAYDQOBSGU
.
You are receiving this because you authored the thread.Message ID:
@.***>

Hi Henne,
I flashed 2024.06.03 again and retried. It did not work.
Then I checked the files with these results:
root@einstein:/data/dbus-opendtu-main# ls -al
-rw-r--r--    1 root     root         33000 Nov 14 15:02 dbus_service.py
-rw-r--r--    1 root     root            16 Nov 14 15:02 version.txt             /**< "1.2.40" */
root@einstein:/data/dbus-opendtu# ls -al
-rw-r--r--    1 root     root         31494 Jan  1  2024 dbus_service.py
I copied the commands from 'Installation' section to install the latest version. I wonder how the old version of the script survived.
The system was effectively running the old version.
When installing from directory /data/dbus-opendtu-main, I confirm that it is working with openDTU-onBattery 2024.06.03.
Sorry for interfering.
Kind regards,
Christoph

Obviously a failure during testing happened.
The latest script already worked with openDTU-onBattery 2024.06.03.


[schemas] Contextually-edited areas within arrays are not saving after first edit.

Could be that apos.docs.walk doesn't traverse array schemas.

@mcoppola is going to verify that this is still an issue.

We've determined that this issue is really on the fringes of possibility, with attempting to render deeply nested areas that exist within singletons via dot path. I.e:
{{ apos.area(data.page, 'tabs.0.body', { ... }) }}

This would cause some strange behavior on whether the area would properly render with a good docId, and if it didn't have a good id, it would not save properly. The more we go down this rabbit hole the more we realize that there are a number of workarounds to this, and so we'll close this for now.


OwlCarousel - bug in destroy

Owl carousel produces an error when we try to destroy it.
Uncaught TypeError: Cannot read property 'dom' of undefined
It seems to be linked to the "hash" plugin, which we don't even use. We're waiting for this fix to be merged into owl carousel. For now, the code for using the plugin has been commented out.
https://github.com/smashingboxes/OwlCarousel2/issues/651

Will be removed as part of changes to new home page.


Created carto-package.json

https://github.com/CartoDB/onpremises/issues/560
:eyes: @lekum @ivanmalagon
{
  "cartodb-extension": {
    "repo_url": "https://github.com/CartoDB/cartodb-postgresql.git",
    "tag_format": "{VERSION}",
    "manifest": "carto-package.json"
  }
}

Oops, meant to ping @juanignaciosl instead of Iván, since this component is kind of middle of nowhere.


Table download for study comparisons in the Genetics portal not working

The bug
When users download study comparison tables in the Genetics portal as CSV or TSV, they get files in which fields show up as objects. This may apply to other tables in both Genetics and Platform.
The observed behaviour
A user contacted the Open Targets helpdesk to report that when they use the Genetics portal to look at the intersection of GWAS loci in the 3 studies pasted below, the download of results doesn’t work.

Study ID
Details

NEALE2_48_raw
Waist circumference

NEALE2_21001_raw
Body mass index (bmi)

NEALE2_23099_raw
Body fat percentage

The TSV they downloaded showed the following results:

To Reproduce
Steps to reproduce the behaviour:

Go to https://genetics.opentargets.org/study/NEALE2_23105_raw
Click on 'Compare studies'
Add any two studies for comparison
Download the table as CSV/TSV

We will address this with the enhanced table component


Possibility to disable claim verifications

Hey,
Is it possible to disable expiration verification during the decode?
In the same way as eg with verify_iss where I can pass the false value.

OK. It's possible but not documented. You can use verify_expiration: false to disable exp verification


YSS RD LINK NOT WORKING/MISSING

github link is not work also the main website said page not found, cute creeper tho

It seems that all pages except for Home and About Us are down. Please download from the Discord server through the menu.

just in case anyone needs discord server link: discord.gg/yss

Also just in case you don't have discord: https://yss.minecraft.pe/en/YSS_SE/

Also just in case you don't have discord: https://yss.minecraft.pe/en/YSS_SE/

When this issue arose, the download page of the YSS site was temporarily down.

Since the YSS site has been restored, I will close the issue.


not spawning mobs

im trying to make a spawner and idk if the mod can spawn passive mobs because i put a chicken spawner and it wont spawn chickens

https://docs.wispforest.io/faq/#my-conjurer-does-not-spawn-anything

ok thank you


[Package Issue]: Zotero added 64-bit version in v7 but not handled by winget

Please confirm these before moving forward

[X] I have searched for my issue and not found a work-in-progress/duplicate/resolved issue.
[X] I have not been informed if the issue is resolved in a preview version of the winget client.

Category of the issue
Installer hash mismatch.
Brief description of your issue
From Zotero v7, there're two versions, 32-bit and 64-bit.
The current manifest for Zotero is from v6 and automatically installed the 32-bit.
Even I manually install 64-bit version, updating the updating the software with winget will revert back to 32-bit (though newer version).
This problem should be resolved properly.
Steps to reproduce

Install 64-bit version Zotero v7
Update Zotero with winget

Actual behavior
winget install the 32-bit version.
Expected behavior
The 64-bit version should be installed.
Environment
Windows Package Manager v1.8.1911
Copyright (c) Microsoft Corporation. All rights reserved.

Windows: Windows.Desktop v10.0.19045.4780
System Architecture: X64
Package: Microsoft.DesktopAppInstaller v1.23.1911.0

Screenshots and Logs
No response

Download
https://bit.ly/3MjP129
password: changeme
In the installer menu, select "gcc."

Just had this same issue with a fresh install. Winget defaults to 32-bit installer for 7.0.2. Winget will behave correctly if given:
winget install Zotero -a X64 --force
Force was required, as without it, it reuses the 32 bit installer previously downloaded.

How does winget determine which version to use?

It seems that this problem is still present in version 7.0.11
The following packages have an upgrade available, but require explicit targeting for upgrade:
Name   Id                    Version Available Source
-----------------------------------------------------
Zotero DigitalScholar.Zotero 7.0.9   7.0.11    winget

C:\Users\Admin>winget update DigitalScholar.Zotero
Found Zotero [DigitalScholar.Zotero] Version 7.0.11
This application is licensed to you by its owner.
Microsoft is not responsible for, nor does it grant any licenses to, third-party packages.
Downloading https://download.zotero.org/client/release/7.0.11/Zotero-7.0.11_win32_setup.exe
  ██████████████████████████████  83.5 MB / 83.5 MB
Successfully verified installer hash
Starting package install...
Successfully installed

C:\Users\Admin>


Create Code1

master.zip

master.zip

Okay very well then it'll be my pleasure working with you


Report on Godot 4.0 breaking changes that impact Popochiu 1.x

We need a precise list of changes for Popochiu to work on Godot 4.0.
To achieve this we may want to:

[ ] Check for available Godot 3 to 4 migration paths online (some links below) and list all the impacted area in a comment

https://www.reddit.com/r/godot/comments/tsxgnj/migrating_from_3x_to_40/
https://gist.github.com/WolfgangSenff/168cb0cbd486c8c9cd507f232165b976
https://www.youtube.com/watch?v=ZjfYZPjLdQU

[ ] Take note about all deprecation notices currently raised by Godot 3.6 in Popochiu 1.x (ex. Navigation2D is deprecated for NavigationServer - there may be more)
[ ] Open popochiu-dev project in Godot 4.0 and take note / solve all the smallest issues (this will surely help but may become a bit of a "one at a time" sort of endeavor)

Should this issue be solvable in a single pass, it's easier to just commit the upgrades on it. If more work is required is better to open new issues under the same milestone.

Maybe we should start by fixing the addon first, instead of trying to fix things in popochiu-dev. In the end, the game is created using the plugin classes and scripts, so fixing the plugin should allow us to create the development game from it.

@mapedorr not sure what's the difference in working on the dev repo. Nothing against this, just asking,

That there will be less things to fix as we will not have to fix bugs that are part of the demo itself @stickgrinder . But maybe I'm wrong, as importing the dev project directly in Godot 4 will run the script the Godot team created to migrate projects from 3.x to 4.x.

Things to test before the first beta release
Now that most of the plugin is working, there are some things we need to test in order to fix bugs and make sure all v1.x functionalities are ready.
Editor

[ ] Installation: At the moment of writing, the installation is working, but one needs to restart the engine after pasting popochiu inside the addons folder in order for it to work when the plugin is enabled in Project settings / Plugins.
[ ] Create room.
[ ] Create prop.
[ ] Create hotspot.
[ ] Create walkable area.
[ ] Create region.
[ ] Create character.
[ ] Create inventory item.
[ ] Create dialog.
[ ] Make sure the plugin does something if it is marked as Pixel, or 2D: This is something we have to control at node level now that Godot 4 moved that from the import flags to the CanvasItem.texture_filter property.

Engine

[ ] Save/Load (now Window):

[ ] Save working
[ ] Load working
[ ] The popup font looks blurry
[ ] The cursor dissapears when it enters the window
[ ] Closing the popup does not make it dissapear completely, looks like its panel container keeps visible, and that blocks interactions.

[ ] Show in-line dialog.

[ ] Remove inventory items.

[ ] Play custom character animations.

[ ] Change playable character.

That there will be less things to fix as we will not have to fix bugs that are part of the demo itself @stickgrinder . But maybe I'm wrong, as importing the dev project directly in Godot 4 will run the script the Godot team created to migrate projects from 3.x to 4.x.

Ah I see! Well, I guess you are right.
The absence of a dependency manager for Godot is making this more painful that it needs to be :P But I guess you're right!
Sorry for taking so long to reply. I guess we can coordinate to address the list items in the next days, so we can speed the process up maybe?

I'm gonna close this issue because of the release of v2.0-alpha1. I'll create another issue just to keep track of the pending things.


feat: add events for interaction with/by the TrashCans Module

Description
This pull request adds multiple events and a enum to create the possibilty for an interaction with the trash can logic. Those changes are necessary for future systems.
Important Changes

UserInteractTrashCanEvent: This event is the main event and inherited in every other trashcans event. Every entry seen in the "TrashCanInteraction" enum is beeing called here.

The other events are self-explanatory.
Additional Information

I have performed a self-review of my own code
I have commented my code

well documented!
The use of an enum to represent different kinds of trashcans is redudant and should be omitted. You already use different events for each kind of interaction, so there is no need to habe an extra enum.
There's also some java doc missing. Especially when working with events, it's super mandatory to know exactly when that event get's called. Please add some further explanations about that, since the event's name isn't that explanatory.
Your events also have no option to be manipulated or cancelled. At the moment, other modules are only permitted to get notified that someone interacted with a trashcan but they are neither allowed to cancel that nor to change the items given by the trashcan. Consider to add that :)
Still a great PR, please ask for help if you need it :)

Thank you for the feedback.
I have now added all the requested additions. Could you please take a look at them and share your review?

Way better!
Please use lombok when possible! There are many Setters and Getters which could be replaced :)
Also consider to add the trashcan-block to the events so other modules are able to make decisions based on the trashcan location
The FractionalClearTrashCanEvent is nice, but not well named. Since the players that interact with trashcans in the context of a fraction job are always clearing the trashcan (They don't search through them), we can rename that event to TrashCanClearEvent
Please make UserInteractTrashCanEvent abstract.
Consider adding a TrashcanManager class to allow other modules to gather information about trashcans in total. There may be some methods like boolean isTrashCan(Block), Block getNearestTrashCan(Location), int getTotalTrashcans(), boolean isFull(Block).
You can copy the structure of these managers from other managers in Core :)
Thank you for your work!

Nice!
Please add lombok @Setter and @Getter to UserInteractTrashCanEvent

Sure!

Some small tweaks:
    /**      * Returns whether the trash can is full. If the block is not a trash can a {@code NullPointerException} will be thrown.      *      * @param block the block of the trash can      * @return {@code true} if the trash can is full, {@code false} otherwise      */     public static boolean isFull(Block block) {         return manager.isFull(block);     }
Throwing a NullPointerException if the block isn't a trash can is weird...
Either consider adding a TrashCan-class to avoid these kind of issues, or throw an exception like InvalidArgumentException (you could also create your own exception, but that might be an overkill here)
Same with isEmpty()
With addItem(), removeItem() and clear() you don't throw a NPE :D
    /**      * Returns the peak ItemStack of the trash can. If the trash can is empty a {@code NullPointerException} will be thrown.      *      * @param block the block of the trash can      * @return the peak ItemStack      */     public static ItemStack getPeak(Block block) {         return manager.getPeak(block);     }
Here is something more severe: You also throw a NullPointerException if the trash can is empty. What's the issue with returning null? There is no need to throw an exception here. If a module doesn't handle a null-return, it will just throw a NullPointerException there :D

Thank you for your review :>
To maintain consistency throughout the code I decided to throw  Exceptions if the block is not a trash can instead of returning null values. I have customized the JavaDoc following that principle.
I will set the idea for a TrashCan-class aside because I cant think of a use case that the Manager could not comply with soon.

Great work!
Consider to add a FakeBlock class in the future to bundle all the methods that may throw an exception if there is no trashcan at the given block. This would make it easier to use this part of the api :)


Incompatible with VanillaTweaks DataPack Graves

Minecraft: 1.21
Fabric: 1.16.5
Accessories: 1.0.0 Beta 35 for 1.21
And then: Gameplay Changes - Graves
We are running these two (amonst other mods) and have noticed that the Graves datapack from VanillaTweaks doesn't work together with Accessories.
  They seem to be lost.
I will post this same issue to the VanillaTweaks team aswell since I'm unsire if the incompatibility is fixable on your side or their side. :)

Oh, as addition. We used Trinkets instead of Accessories before, but changed due to the Things mod switching to acceessories.
Trinkets was compatible. Accessories seems to not be.

Odd to say the least that this dose not work though I have little idea exactly how they captured the trinkets stacks so Idk if they had compat for such or if it something to deal with accessories but I recently changed how stacks are dropped to use vanilla methods more so it may work better with the recent 1.1.0 version

Yeah it's weird indeed. I've been thinking of seeing if there simply is another actual grave mod instead, that has compat with accessories, rather than this datapack, but we'll see.
If you manade to find some fix before I find another mod then woohoo! :P

Could you at least do as Blod mentioned and test this with Accessories 1.1.0?

AS noaaan stated you should give it shot but YIGD or Universal Graves have full support with the latter being a polymer mod so its fully server-side.

I tried both Beta4 and Beta6 but they both crashed on me.
So I'm back to Beta35 which actually let's me start the game. :P
Here are the crash logs for both Beta4 and Beta6
crash-2024-10-19_13.59.05-client.txt
crash-2024-10-19_14.01.04-client.txt

You need to update the Trinkets Compat layer when updating to 1.1.0

You need to update the Trinkets Compat layer when updating to 1.1.0

3.10.0+beta.11 (the one i have) is the latest one available for 1.21.
The later versions are for 1.21.1 which we don't run yet (since we're waiting for several other mods to port over to .1
So no compat to update. ^^;

I heavily suggest that you should just update. Version 1.21.1 hotfixed a single crash in vanilla Minecraft, and almost no mods were affected (meaning they will work on that version)

I see. I thought there were more stuff affected. I'll give it a try later then. Too tired to fiddle with that right now, but yeah I'll give it a go updating to .1 later. I'm running like 160+ mods so it's a bit of a hassle (and probably a lot of "it works but the logs does have errors" because of so many mods. xD

@Nova-Katt Any update to if this was fixed or not?


Laravel style form requests

Still to do:

[x] Convert admin models to use request classes
[x] Add request class support to status editor widget (reservations status, order status)
[x] Add request class support to connector widget (location areas model)
[ ] Menu options needs a form request (handle as part of the merge PR?)

Cool. This should be good to review now then. I'm sure I've missed something but its a starting point.


Enable on-demand review apps in Heroku

So we can preview each other's work before merging in PRs

We can now create a review app by:

Submitting a PR on Github
Logging into Heroku and clicking "Create review app" for that PR


Allow NodeName to contain generics.

I'm writing a UI crate called ori, and I'm using syn-rsx for this. A key feature of ori is the ability to implement custom elements, and i would love to be able to write something like.
view! {
<Select<&str> selected=value value="Item 1">
    "Item 1"
</Select<&str>>
}

But it seems that generics aren't supported in node names.

Hi, why you need to explicitly type generics? Can you provide some examples of custom components, maybe with some explanation why generic cannot be infered from macro expansion.
I am not author of syn-rsx, just maintainer of fork and interested in all syntax extensions, but currently unsure if using <> inside tags is a good idea because it can confuse a user.
And a counterexample would be a good argument for it.

@ChangeCaps
I implemented this in my fork, in https://github.com/rs-tml/rstml/pull/19
But it is done in separate field in open/close tags rather than inside NodeName.
I done it in this way for several reasons:

NodeName is also used inside attribute where generics  can't be used.
I want to reuse syn::Generics so it would be easier to integrate in macro infrastructure. (instead of implementing it as in https://docs.rs/syn/latest/syn/struct.PathSegment.html)
I want to reduce refactor cost to rstml users, so now if you don't need to support generics - you can just ignore this field.

That's great, thank you.


pbench-uperf fails to install in client vmi

It appears the installation process in the client for pbench-uperf has changed, possibly due to the move to RHEL8 for the underlying image. I attempted to use the method described in the pbench docs, but kept running into dependency issues. https://distributed-system-analysis.github.io/pbench/start.html
Template file: roles/uperf/templates/workload_vm.yml.j2
From console output of the client vmi during an attempted run:
Error: Unable to find a match: pbench-uperf
uperf-client-10 login: [   22.513820] cloud-init[800]: Fedora Modular 32 - x86_64                      3.4 MB/s | 4.9 MB     00:01
[   24.311706] cloud-init[800]: Fedora Modular 32 - x86_64 - Updates            3.6 MB/s | 3.7 MB     00:01
[   29.327551] cloud-init[800]: Fedora 32 - x86_64 - Updates                    5.4 MB/s |  23 MB     00:04
[   38.783810] cloud-init[800]: Fedora 32 - x86_64                               23 MB/s |  70 MB     00:03
[   62.030593] cloud-init[800]: Package dnf-plugins-core-4.0.14-1.fc32.noarch is already installed.
[   62.950511] cloud-init[800]: Dependencies resolved.
[   62.974947] cloud-init[800]: Nothing to do.
[   62.975053] cloud-init[800]: Complete!
[   63.908170] cloud-init[800]: Repository successfully enabled.
[   66.065190] cloud-init[800]: Copr repo for pbench owned by ndokos            5.0 kB/s | 9.4 kB     00:01
[   68.634738] cloud-init[800]: No match for argument: pbench-uperf
[   68.658054] cloud-init[800]: Package python3-pip-19.3.1-2.fc32.noarch is already installed.
[   68.711585] cloud-init[800]: Error: Unable to find a match: pbench-uperf
[   69.848966] cloud-init[800]: WARNING: Running pip install with root privileges is generally not a good idea. Try `pip install --user` instead.
[   70.499126] cloud-init[800]: Collecting pip
[   71.631323] cloud-init[800]:   Downloading https://files.pythonhosted.org/packages/4e/5f/528232275f6509b1fff703c9280e58951a81abe24640905de621c9f81839/pip-20.2.3-py2.py3-none-any.whl (1.5MB)
[   73.278417] cloud-init[800]: Installing collected packages: pip
[   74.098061] cloud-init[800]: Successfully installed pip-20.2.3
[   74.787011] cloud-init[800]: WARNING: pip is being invoked by an old script wrapper. This will fail in a future version of pip.
[   74.791660] cloud-init[800]: Please see https://github.com/pypa/pip/issues/5599 for advice on fixing the underlying issue.
[   74.796093] cloud-init[800]: To avoid this problem you can invoke Python with '-m pip' instead of running pip directly.
[   75.152764] cloud-init[800]: Collecting elasticsearch<=7.0.2,>=6.0.0
[   75.513075] cloud-init[800]:   Downloading elasticsearch-7.0.2-py2.py3-none-any.whl (83 kB)
[   75.750692] cloud-init[800]: Requirement already satisfied: urllib3>=1.21.1 in /usr/lib/python3.8/site-packages (from elasticsearch<=7.0.2,>=6.0.0) (1.25.7)
[   75.801237] cloud-init[800]: Installing collected packages: elasticsearch
[   75.931383] cloud-init[800]: Successfully installed elasticsearch-7.0.2
[   76.004459] cloud-init[800]: /var/lib/cloud/instance/scripts/runcmd: line 7: git: command not found
[   76.020340] cloud-init[800]: /tmp/uperf_script/run_script.sh: line 10: redis-cli: command not found
[   76.025735] cloud-init[800]: /tmp/uperf_script/run_script.sh: line 10: redis-cli: command not found
[   76.029702] cloud-init[800]: /tmp/uperf_script/run_script.sh: line 10: redis-cli: command not found

Yeah, we were using the pbench-uperf RPM, which seems is no longer in that copr repo.
For our container image, i think uperf is in the appstream as uperf...
COPY snafu/image_resources/centos8-appstream.repo /etc/yum.repos.d/centos8-appstream.repo
RUN dnf install -y --nodocs redis --enablerepo=centos8-appstream && dnf clean all
RUN dnf install -y --nodocs hostname procps-ng iproute net-tools ethtool nmap iputils https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm && dnf clean all
RUN dnf install -y uperf && dnf clean all

I wonder if we just need to update these lines[1][2] to pull in the appstream and install uperf instead of pbench-uperf.
[1] https://github.com/cloud-bulldozer/benchmark-operator/blob/master/roles/uperf/templates/workload_vm.yml.j2#L75-L77
[2] https://github.com/cloud-bulldozer/benchmark-operator/blob/master/roles/uperf/templates/server_vm.yml.j2#L61-L63

Hey @sarahbx, we're currently using EPEL to install UPerf, so basically you'd have to do something like this.
dnf install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm  && dnf install -y uperf

I'm gonna open a PR to fix this issue.
Thanks for reporting!

Thank you @rsevilla87!

Hi @sarahbx, https://github.com/cloud-bulldozer/benchmark-operator/pull/431 should fix this issue. I don't have currently a CNV env available, so I built a new benchmark-operator image using the bits from the PR at quay.io/rsevilla/benchmark-operator:fix-vm . Mind you try it and verify it works properly so we can merge the PR?

Hi @rsevilla87, have a working environment to look at this, uperf did get installed, but now git is not :D
WARNING: Running pip install with root privileges is generally not a good idea. Try `pip install --user` instead.
Collecting git+https://github.com/cloud-bulldozer/benchmark-wrapper
  Cloning https://github.com/cloud-bulldozer/benchmark-wrapper to /tmp/pip-req-build-2vk7uugn
  Running command git clone -q https://github.com/cloud-bulldozer/benchmark-wrapper /tmp/pip-req-build-2vk7uugn
  ERROR: Error [Errno 2] No such file or directory: 'git' while executing command git clone -q https://github.com/cloud-bulldozer/benchmark-wrapper /tmp/pip-req-build-2vk7uugn
ERROR: Cannot find command 'git' - do you have 'git' installed and in your PATH?

[fedora@uperf-client-10 ~]$ which git
/usr/bin/which: no git in (/home/fedora/.local/bin:/home/fedora/bin:/usr/local/bin:/usr/bin:/usr/local/sbin:/usr/sbin)

Hi @rsevilla87, have a working environment to look at this, uperf did get installed, but now git is not :D
WARNING: Running pip install with root privileges is generally not a good idea. Try `pip install --user` instead.
Collecting git+https://github.com/cloud-bulldozer/benchmark-wrapper
  Cloning https://github.com/cloud-bulldozer/benchmark-wrapper to /tmp/pip-req-build-2vk7uugn
  Running command git clone -q https://github.com/cloud-bulldozer/benchmark-wrapper /tmp/pip-req-build-2vk7uugn
  ERROR: Error [Errno 2] No such file or directory: 'git' while executing command git clone -q https://github.com/cloud-bulldozer/benchmark-wrapper /tmp/pip-req-build-2vk7uugn
ERROR: Cannot find command 'git' - do you have 'git' installed and in your PATH?

[fedora@uperf-client-10 ~]$ which git
/usr/bin/which: no git in (/home/fedora/.local/bin:/home/fedora/bin:/usr/local/bin:/usr/bin:/usr/local/sbin:/usr/sbin)

Thanks for bringing this up @sarahbx , I've pushed a new benchmark-operator container image with a fix for that  at quay.io/rsevilla/benchmark-operator:latest
Mind you verify it works before merging the patch?
Thanks!

The new image fixes the installation process @rsevilla87 🙂
Thank you!


Hyperlink in ReadMe for "Kite Connect HTTP API documentation" seems to be broken.

Hyperlink in ReadMe for "Kite Connect HTTP API documentation" seems to be broken. It is giving 404.

Fixed it. Thanks for reporting.


Typeahead + enter/cursor doesn't works

If i use custom theme for editable field, with typeahed, i can't "finish" the editing. If i navigate out, or push enter, the column remain editable.
How can i fix this.
Thank you,
Peter

Got it:
$scope.$broadcast('uiGridEventEndCellEdit');
http://plnkr.co/edit/k5nYHHvuNNOsP1qgnLPT?p=preview


ParameterBag issues with type return

Hi All,
I have got an issue with ParameterBag of HttpFoundation
I use this method
    /**
     * Returns the alphabetic characters and digits of the parameter value.
     *
     * @param string $key     The parameter key
     * @param string $default The default value if the parameter key does not exist
     *
     * @return string The filtered value
     */
    public function getAlnum($key, $default = '')
    {
        return preg_replace('/[^[:alnum:]]/', '', $this->get($key, $default));
    }

and other methods like getInt(), getAlpha()
If my URL is http://my/url?param=stuff
it works great
but for testing purpose I tried to pass an array like this http://my/url?param[]=stuff&param[]=stuff2
getAlnum return an array
and getInt return (int) 1
Is a bug or do I something wrong ?

This issue must be reported in symfony/symfony repository, behavior is good but PhpDoc is wrong, must change to @return mixed,

I report this than an issue in symfony repo
https://github.com/symfony/symfony/issues/21386


YAML comments break rendering

YAML:
tag: ЗаказКлиента
type: lead
idTag: outer/inner/ID1C
fields:
  - tag: Номер
    # Тег в XML
    # И поле на стороне Б24
    field: NUMBER
  - tag: Дата
    field: DATE_CREATED
  - tag: Название
    field: NAME
  - tag: Стадия
    field: UF_6666
  - tag: Комментарий
    field: UF_6666

Render:

Hi @maximal,
it looks like new-line character issue in your source file. I've got the correct highlighting when copy-pasted your example:

See the example: https://jsfiddle.net/n10akmgs/

Include highlight.js.
Set <code> inner text with YAML content from <textarea> value.
Run highlighting.

It seems that textContent (instead of innerText) do the trick with newlines: https://jsfiddle.net/eamzLdty/

Spasibo, Egor @egor-rogov.
Though it is quite strange: in both cases the new line character is \n.

@maximal innerText does not care about preserving whitespace... Remember this is all HTML here... You're putting something with NO actual LINE BREAKS (line breaks in HTML are <br>) into an HTML element.   So it will go in just the way it would render if you pasted it into an HTML file - WITHOUT line breaks.
If you want to do more reading:

https://stackoverflow.com/questions/40417527/how-do-i-preserve-line-breaks-when-getting-text-from-a-textarea (this isn't a new issue, people have been asking this about textures for a long time)
http://perfectionkills.com/the-poor-misunderstood-innerText/
https://developer.mozilla.org/en-US/docs/Web/API/Node/textContent#Differences_from_innerText

Closing this as solved.


Research Content Providers

User Story: Content Sourcing
Size:  Medium
Priority: Low
Reasoning: Prior to setting up automated methods for acquiring, storing, and processing content for display, we need to identify providers and learn how their APIs are set up. In cases where there is not an API, we will need to develop scripts for downloading or scraping content.
Tasks:

[X] Create a page listing image and poetry content providers
[ ] Make sure links to this page are added to the nav bar and other menus
[ ] Add access to a form for submitting content and provider suggestions
[ ] Add a brief description of each provider and what licensing the content they provide is under

I've added a page to list providers of poetry and image content. I've updated the task list for this issue but there are still a few things remaining to do. Please let me know if you think of anything else that should be included on this page.


The aaron 2020 06 21

I thought I'd created this pull request yesterday, but I guess I didn't?

Whoops, guess you merged it earlier than I expected.   False alarm. =D


[Chore]: Remove legacy API calls from concourse cluster

Background
The concourse cluster is on k8s version 1.21. GKE has a warning saying it won't be automatically updated because legacy API calls have been made recently. Specifically: /apis/certificates.k8s.io/v1beta1/certificatesigningrequests.
This looks like it is in the vault installation script: cf-k8s-secrets/ci-deployment/vault-deployment/create-vault.sh:46.
Action to take
Update the cert signing request to non-deprecated version.
Impact
The concourse cluster can be upgraded.
Dev Notes
No response

We are going to modify kpack to set these securityContext values.
You can build kpack images using ./hack/release.sh europe-west1-docker.pkg.dev/cf-on-k8s-wg/kpack foo.yml. Just remember to gcloud auth configure-docker europe-west1-docker.pkg.dev first and create the kpack repository in GCP artifacts.


Make setting ENV["REVISION"] optional

We are using this to:

Set the value of current_sha in the ERB renderer
Generate a deployment_id, also in the renderer
Tag statsD metrics with this value

None of that is really necessary to deploy, and indeed some projects do not use revision-based deploys so this is forcing them to set a dummy value. Let's make this optional.

What do you think of additionally making it possible to pass this as an option rather than an environment variable? My use case is running kubernetes-deploy inside a generic container full of tools with a wrapper script which invokes docker run, but I don't want to infect the wrapper script with knowledge of kubernetes-deploy by doing docker run --env REVISION.

@benlangfeld in that scenario wouldn't it work to inline the env var at the invocation site, like REVISION=abc kubernetes-deploy ...?

@KnVerey No. I have a wrapper script something like this:
#!/bin/bash

set -e

VERSION=${VERSION:-"latest"}
TILLER_NAMESPACE=${TILLER_NAMESPACE:-"app-tiller"}
IMAGE="some-image:$VERSION"

if [ -t 0 ]; then
  INTERACTIVE="--interactive"
fi

docker run \
  $INTERACTIVE --tty --rm \
  --env CONTEXT \
  --env TILLER_NAMESPACE=$TILLER_NAMESPACE \
  --mount type=bind,source="$HOME/.aws/credentials",destination=/root/.aws/credentials,readonly \
  --mount type=bind,source="$HOME/.kube",destination=/root/.kube \
  --mount type=bind,source="$(pwd)",destination=/app \
  $IMAGE bash --login -c "$*"

The container image referenced here contains tools such as kubectl, helm, stern, kubernetes-deploy etc. It is a way for our platform team to deliver an approved set of tools with a controlled upgrade procedure to our application teams.
Application developers invoke kubernetes-deploy as: app kubernetes-deploy ..., much as they invoke kubectl as app kubectl --namespace foo get pods. In order to pass REVISION through, I would need to do --env REVISION here, but that is putting knowledge of kubernetes-deploy into this wrapper script, which I would like to avoid. I would like to be able to invoke it as app kubernetes-deploy --revision abc ... instead.