AttributeError: 'Gitlab' object has no attribute 'getmergerequestchanges'

hi,
my gitlab version is 7.4,  I use pyapi-gitlab API :
1 . >>> import gitlab
2.  >>> git = gitlab.Gitlab("https://gitlab.host.com",verify_ssl=False)
3.  >>> git.login(user='gitlab',password='123456')
/usr/lib/python2.6/site-packages/requests/packages/urllib3/connectionpool.py:768: InsecureRequestWarning: Unverified HTTPS request is being made. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.org/en/latest/security.html
InsecureRequestWarning)
True
then, git merge request:

git.createmergerequest('44','develop','master','this is a test')
/usr/lib/python2.6/site-packages/requests/packages/urllib3/connectionpool.py:768: InsecureRequestWarning: Unverified HTTPS request is being made. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.org/en/latest/security.html
InsecureRequestWarning)
{u'downvotes': 0, u'target_branch': u'master', u'description': None, u'title': u'this is a test', u'created_at': u'2015-05-03T13:51:13.419+08:00', u'source_branch': u'develop', u'updated_at': u'2015-05-03T13:51:13.419+08:00', u'labels': [], u'iid': 17, u'state': u'opened', u'assignee': None, u'author': {u'username': u'gitlab', u'state': u'active', u'avatar_url': u'https://secure.gravatar.com/avatar/4160ab6efe7636cc4e576a4c47b40032?s=40&d=identicon', u'name': u'\u7ba1\u7406\u5458', u'id': 3}, u'milestone': None, u'upvotes': 0, u'target_project_id': 44, u'project_id': 44, u'id': 574, u'source_project_id': 44}

git.getmergerequestchanges('44','574')
Traceback (most recent call last):
File "", line 1, in
AttributeError: 'Gitlab' object has no attribute 'getmergerequestchanges'

why AttributeError ? please help me thanks!

I update gitlab to 7-8, it is ok! thanks

sorry, It still did not work.
I use linux curl  command is ok:
curl --header "PRIVATE-TOKEN: t3cZ5R7zzz8Rt-zzBYsb" "http://gitlab.host.com/api/v3/projects/44/merge_request/574/changes"
{"id":574,"iid":17,"project_id":44,"title":"this is a test","description":null,"state":"opened","created_at":"2015-05-03T05:51:13.000Z","updated_at":"2015-05-03T05:51:24.000Z","target_branch":"master","source_branch":"develop","upvotes":0,"downvotes":0,"author":{"name":"管理员","username":"gitlab","id":3,"state":"active","avatar_url":"http://gitlab.usport.cc/uploads/user/avatar/3/2-2.jpg"},"assignee":null,"source_project_id":44,"target_project_id":44,"labels":[],"milestone":null,"changes":[{"old_path":"123.txt","new_path":"123.txt","a_mode":"100644","b_mode":"0","diff":"--- a/123.txt\n+++ /dev/null","new_file":false,"renamed_file":false,"deleted_file":true},{"old_path":"abc.txt","new_path":"abc.txt","a_mode":"100644","b_mode":"100644","diff":"--- a/abc.txt\n+++ b/abc.txt\n@@ -1 +1 @@\n-123\n\ No newline at end of file\n+abc\n\ No newline at end of file","new_file":false,"renamed_file":false,"deleted_file":false},{"old_path":"test3.txt","new_path":"test3.txt","a_mode":"0","b_mode":"100644","diff":"--- /dev/null\n+++ b/test3.txt","new_file":true,"renamed_file":false,"deleted_file":false},{"old_path":"test4.txt","new_path":"test4.txt","a_mode":"0","b_mode":"100644","diff":"--- /dev/null\n+++ b/test4.txt","new_file":true,"renamed_file":false,"deleted_file":false}]}
but use pyapi-gitlab return no attribute error :

git = gitlab.Gitlab("http://gitlab.host.com")
git.login(user='gitlab',password='123456')
True
git.getmergerequestchanges('44','574')
Traceback (most recent call last):
File "", line 1, in
AttributeError: 'Gitlab' object has no attribute 'getmergerequestchanges'

why ?
Now gitlab version is 7-8.

sorry, It still did not work.
I use linux curl  command is ok:
curl --header "PRIVATE-TOKEN: t3cZ5R7zzz8Rt-zzBYsb" "http://gitlab.host.com/api/v3/projects/44/merge_request/574/changes"
{"id":574,"iid":17,"project_id":44,"title":"this is a test","description":null,"state":"opened","created_at":"2015-05-03T05:51:13.000Z","updated_at":"2015-05-03T05:51:24.000Z","target_branch":"master","source_branch":"develop","upvotes":0,"downvotes":0,"author":{"name":"管理员","username":"gitlab","id":3,"state":"active","avatar_url":"http://gitlab.usport.cc/uploads/user/avatar/3/2-2.jpg"},"assignee":null,"source_project_id":44,"target_project_id":44,"labels":[],"milestone":null,"changes":[{"old_path":"123.txt","new_path":"123.txt","a_mode":"100644","b_mode":"0","diff":"--- a/123.txt\n+++ /dev/null","new_file":false,"renamed_file":false,"deleted_file":true},{"old_path":"abc.txt","new_path":"abc.txt","a_mode":"100644","b_mode":"100644","diff":"--- a/abc.txt\n+++ b/abc.txt\n@@ -1 +1 @@\n-123\n\ No newline at end of file\n+abc\n\ No newline at end of file","new_file":false,"renamed_file":false,"deleted_file":false},{"old_path":"test3.txt","new_path":"test3.txt","a_mode":"0","b_mode":"100644","diff":"--- /dev/null\n+++ b/test3.txt","new_file":true,"renamed_file":false,"deleted_file":false},{"old_path":"test4.txt","new_path":"test4.txt","a_mode":"0","b_mode":"100644","diff":"--- /dev/null\n+++ b/test4.txt","new_file":true,"renamed_file":false,"deleted_file":false}]}
but use pyapi-gitlab return no attribute error :

git = gitlab.Gitlab("http://gitlab.host.com")
git.login(user='gitlab',password='123456')
True
git.getmergerequestchanges('44','574')
Traceback (most recent call last):
File "", line 1, in
AttributeError: 'Gitlab' object has no attribute 'getmergerequestchanges'

why ?
Now gitlab version is 7-8.

sorry, It still did not work.
I use linux curl  command is ok:
curl --header "PRIVATE-TOKEN: t3cZ5R7zzz8Rt-zzBYsb" "http://gitlab.host.com/api/v3/projects/44/merge_request/574/changes"
{"id":574,"iid":17,"project_id":44,"title":"this is a test","description":null,"state":"opened","created_at":"2015-05-03T05:51:13.000Z","updated_at":"2015-05-03T05:51:24.000Z","target_branch":"master","source_branch":"develop","upvotes":0,"downvotes":0,"author":{"name":"管理员","username":"gitlab","id":3,"state":"active","avatar_url":"http://gitlab.usport.cc/uploads/user/avatar/3/2-2.jpg"},"assignee":null,"source_project_id":44,"target_project_id":44,"labels":[],"milestone":null,"changes":[{"old_path":"123.txt","new_path":"123.txt","a_mode":"100644","b_mode":"0","diff":"--- a/123.txt\n+++ /dev/null","new_file":false,"renamed_file":false,"deleted_file":true},{"old_path":"abc.txt","new_path":"abc.txt","a_mode":"100644","b_mode":"100644","diff":"--- a/abc.txt\n+++ b/abc.txt\n@@ -1 +1 @@\n-123\n\ No newline at end of file\n+abc\n\ No newline at end of file","new_file":false,"renamed_file":false,"deleted_file":false},{"old_path":"test3.txt","new_path":"test3.txt","a_mode":"0","b_mode":"100644","diff":"--- /dev/null\n+++ b/test3.txt","new_file":true,"renamed_file":false,"deleted_file":false},{"old_path":"test4.txt","new_path":"test4.txt","a_mode":"0","b_mode":"100644","diff":"--- /dev/null\n+++ b/test4.txt","new_file":true,"renamed_file":false,"deleted_file":false}]}
but use pyapi-gitlab return no attribute error :

git = gitlab.Gitlab("http://gitlab.host.com")
git.login(user='gitlab',password='123456')
True
git.getmergerequestchanges('44','574')
Traceback (most recent call last):
File "", line 1, in
AttributeError: 'Gitlab' object has no attribute 'getmergerequestchanges'

why ?
Now gitlab version is 7-8.

sorry, It still did not work.
I use linux curl  command is ok:
curl --header "PRIVATE-TOKEN: t3cZ5R7zzz8Rt-zzBYsb" "http://gitlab.host.com/api/v3/projects/44/merge_request/574/changes"
{"id":574,"iid":17,"project_id":44,"title":"this is a test","description":null,"state":"opened","created_at":"2015-05-03T05:51:13.000Z","updated_at":"2015-05-03T05:51:24.000Z","target_branch":"master","source_branch":"develop","upvotes":0,"downvotes":0,"author":{"name":"管理员","username":"gitlab","id":3,"state":"active","avatar_url":"http://gitlab.usport.cc/uploads/user/avatar/3/2-2.jpg"},"assignee":null,"source_project_id":44,"target_project_id":44,"labels":[],"milestone":null,"changes":[{"old_path":"123.txt","new_path":"123.txt","a_mode":"100644","b_mode":"0","diff":"--- a/123.txt\n+++ /dev/null","new_file":false,"renamed_file":false,"deleted_file":true},{"old_path":"abc.txt","new_path":"abc.txt","a_mode":"100644","b_mode":"100644","diff":"--- a/abc.txt\n+++ b/abc.txt\n@@ -1 +1 @@\n-123\n\ No newline at end of file\n+abc\n\ No newline at end of file","new_file":false,"renamed_file":false,"deleted_file":false},{"old_path":"test3.txt","new_path":"test3.txt","a_mode":"0","b_mode":"100644","diff":"--- /dev/null\n+++ b/test3.txt","new_file":true,"renamed_file":false,"deleted_file":false},{"old_path":"test4.txt","new_path":"test4.txt","a_mode":"0","b_mode":"100644","diff":"--- /dev/null\n+++ b/test4.txt","new_file":true,"renamed_file":false,"deleted_file":false}]}
but use pyapi-gitlab return no attribute error :

git = gitlab.Gitlab("http://gitlab.host.com")
git.login(user='gitlab',password='123456')
True
git.getmergerequestchanges('44','574')
Traceback (most recent call last):
File "", line 1, in
AttributeError: 'Gitlab' object has no attribute 'getmergerequestchanges'

why ?
Now gitlab version is 7-8.

sorry, It still did not work.
I use linux curl  command is ok:
curl --header "PRIVATE-TOKEN: t3cZ5R7zzz8Rt-zzBYsb" "http://gitlab.host.com/api/v3/projects/44/merge_request/574/changes"
{"id":574,"iid":17,"project_id":44,"title":"this is a test","description":null,"state":"opened","created_at":"2015-05-03T05:51:13.000Z","updated_at":"2015-05-03T05:51:24.000Z","target_branch":"master","source_branch":"develop","upvotes":0,"downvotes":0,"author":{"name":"管理员","username":"gitlab","id":3,"state":"active","avatar_url":"http://gitlab.usport.cc/uploads/user/avatar/3/2-2.jpg"},"assignee":null,"source_project_id":44,"target_project_id":44,"labels":[],"milestone":null,"changes":[{"old_path":"123.txt","new_path":"123.txt","a_mode":"100644","b_mode":"0","diff":"--- a/123.txt\n+++ /dev/null","new_file":false,"renamed_file":false,"deleted_file":true},{"old_path":"abc.txt","new_path":"abc.txt","a_mode":"100644","b_mode":"100644","diff":"--- a/abc.txt\n+++ b/abc.txt\n@@ -1 +1 @@\n-123\n\ No newline at end of file\n+abc\n\ No newline at end of file","new_file":false,"renamed_file":false,"deleted_file":false},{"old_path":"test3.txt","new_path":"test3.txt","a_mode":"0","b_mode":"100644","diff":"--- /dev/null\n+++ b/test3.txt","new_file":true,"renamed_file":false,"deleted_file":false},{"old_path":"test4.txt","new_path":"test4.txt","a_mode":"0","b_mode":"100644","diff":"--- /dev/null\n+++ b/test4.txt","new_file":true,"renamed_file":false,"deleted_file":false}]}
but use pyapi-gitlab return no attribute error :

git = gitlab.Gitlab("http://gitlab.host.com")
git.login(user='gitlab',password='123456')
True
git.getmergerequestchanges('44','574')
Traceback (most recent call last):
File "", line 1, in
AttributeError: 'Gitlab' object has no attribute 'getmergerequestchanges'

why ?
Now gitlab version is 7-8.

sorry, It still did not work.
I use linux curl  command is ok:
curl --header "PRIVATE-TOKEN: t3cZ5R7zzz8Rt-zzBYsb" "http://gitlab.host.com/api/v3/projects/44/merge_request/574/changes"
{"id":574,"iid":17,"project_id":44,"title":"this is a test","description":null,"state":"opened","created_at":"2015-05-03T05:51:13.000Z","updated_at":"2015-05-03T05:51:24.000Z","target_branch":"master","source_branch":"develop","upvotes":0,"downvotes":0,"author":{"name":"管理员","username":"gitlab","id":3,"state":"active","avatar_url":"http://gitlab.usport.cc/uploads/user/avatar/3/2-2.jpg"},"assignee":null,"source_project_id":44,"target_project_id":44,"labels":[],"milestone":null,"changes":[{"old_path":"123.txt","new_path":"123.txt","a_mode":"100644","b_mode":"0","diff":"--- a/123.txt\n+++ /dev/null","new_file":false,"renamed_file":false,"deleted_file":true},{"old_path":"abc.txt","new_path":"abc.txt","a_mode":"100644","b_mode":"100644","diff":"--- a/abc.txt\n+++ b/abc.txt\n@@ -1 +1 @@\n-123\n\ No newline at end of file\n+abc\n\ No newline at end of file","new_file":false,"renamed_file":false,"deleted_file":false},{"old_path":"test3.txt","new_path":"test3.txt","a_mode":"0","b_mode":"100644","diff":"--- /dev/null\n+++ b/test3.txt","new_file":true,"renamed_file":false,"deleted_file":false},{"old_path":"test4.txt","new_path":"test4.txt","a_mode":"0","b_mode":"100644","diff":"--- /dev/null\n+++ b/test4.txt","new_file":true,"renamed_file":false,"deleted_file":false}]}
but use pyapi-gitlab return no attribute error :

git = gitlab.Gitlab("http://gitlab.host.com")
git.login(user='gitlab',password='123456')
True
git.getmergerequestchanges('44','574')
Traceback (most recent call last):
File "", line 1, in
AttributeError: 'Gitlab' object has no attribute 'getmergerequestchanges'

Now gitlab version is 7-8.

sorry , my version issue. it is ok

Glad to know :)


[r19.03] powerdns: add patches fixing CVE-2019-10162, CVE-2019-10163

Motivation for this change
https://doc.powerdns.com/authoritative/security-advisories/powerdns-advisory-2019-04.html
https://doc.powerdns.com/authoritative/security-advisories/powerdns-advisory-2019-05.html
Debian have conveniently fished out the right patches for these.
~Note: I have not yet completed a nox-review for this.~ Ok, there aren't any reverse dependencies.
Things done

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

[ ] NixOS
[ ] macOS
[x] other Linux distributions

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

nixos/tests/powerdns.nix is happy for me too (non-nixos linux, x86_64).

Thanks. I backported the patch release instead since there also seem some interesting bugfixes in it: 85f820d6e41a301a06a44cd72430cce0b3e4e5f5

I was kinda trying to avoid that because ... yknow, tiny behaviour changes & all that. Nevermind, though.


AttributeError: class Extension has no attribute 'mro'

Hey Michele,
I am trying to install libstempo but get different errors on different platforms. This is the OSX error that I get:
WARNING: The libstempo API has changed substantially (for the better) from
versions 1.X to 2.X. If you need the older 1.X API, you can get an older libstempo
from https://pypi.python.org/simple/libstempo, or checkout the libstempo1
branch on GitHub - https://github.com/vallis/libstempo/tree/libstempo1
Found tempo2 install in [u'/Users/vkrishnan/T2runtime/'], will use it.
Traceback (most recent call last):
File "setup.py", line 109, in
extra_link_args = linkArgs))
File "/Users/vkrishnan/anaconda/lib/python2.7/site-packages/Cython/Build/Dependencies.py", line 818, in cythonize
aliases=aliases)
File "/Users/vkrishnan/anaconda/lib/python2.7/site-packages/Cython/Build/Dependencies.py", line 648, in create_extension_list
elif isinstance(patterns, basestring) or not isinstance(patterns, collections.Iterable):
File "/Users/vkrishnan/anaconda/lib/python2.7/abc.py", line 144, in instancecheck
return cls.subclasscheck(subtype)
File "/Users/vkrishnan/anaconda/lib/python2.7/abc.py", line 180, in subclasscheck
if issubclass(subclass, scls):
File "/Users/vkrishnan/anaconda/lib/python2.7/abc.py", line 180, in subclasscheck
if issubclass(subclass, scls):
File "/Users/vkrishnan/anaconda/lib/python2.7/abc.py", line 161, in subclasscheck
ok = cls.subclasshook(subclass)
File "/Users/vkrishnan/anaconda/lib/python2.7/site-packages/backports_abc.py", line 66, in subclasshook
mro = C.mro
AttributeError: class Extension has no attribute 'mro'
I tried pip install and setup.puy but both give the same error.  Can you please tell me how to fix it?
My softwares:
conda 4.3.25
Python 2.7.11 :: Anaconda custom (x86_64)
OSX El Capitan 10.11.6
gcc (GCC) 4.9.2 20141029
g++ (GCC) 4.9.2 20141029
Tempo2  2017.03.1
Thanks,
Vivek

Some googling suggested it is a conflict with cython and setuptools which should have been resolved in the versions I am using but doesn't seem like it.
My versions:
setuptools: 36.4.0-py27_1
cython: 0.26-py27_0

Okay, Changing
backports_abc: 0.4-py27_0 --> 0.5-py27_0
tornado:       4.3-py27_0 --> 4.5.2-py27_0
seems to have done the trick.  Sorry for posting the issue too soon! May be this will help others at some point. Please close this issue.
Vivek

@vivekvenkris, I actually just had this problem as well and moving to Cython 0.25 from Cython 0.26 worked as well. Maybe this was done internally when you downgraded tornado?
Either, way @vallis and I should make take a look at this so it will fork for newer Cython versions.


C++ tests on iOS to work with bazel 1.0

Fixes #20880.

Started an adhoc test: https://sponge.corp.google.com/invocation?id=75b5402f-ecd0-46ab-8b60-ca355718207f&searchFor=

The adhoc test is passing. Thanks for the fix!

The adhoc test is passing. Thanks for the fix!
I believe this is the last occurrence of bazel <1.0 in our repository.


Unify all markup (*.md) files into a single README.rst file

Inspired from the README.rst of https://github.com/jkbrzt/httpie

Challenge : Take care while integrating static markup files like README.md and LICENSE.md, with dynamic markup files like SITEMAP.md and RESOURCES.md.

Did not adopt README.rst, but completed README.md & README.md.erb with d7735817b5dc90a119b13ce7a81f74bc4539bc58


Refs #30116 -- Simplified tests related with dictionary order.

Dicts preserve order since Python 3.6.

@hramezani Thanks for checking :+1:


docs: Demonstrate proper bot shutdown.

Summary
Demonstrate proper bot shutdown procedure in the examples.
@z64 told me I was not correctly shutting down my bot, but I'd followed the examples and wiki (which has been updated).
Changed
Updated all the examples to demonstrate proper shutdown using bot.stop when the process is killed. Or, in the case of the shutdown example, before exiting.

Thanks for this!
I am unsure though that this is the best example. We do our best to make the library approachable for beginners, and begin..rescue Interrupt I feel might leave a lot of questions. What I think might be a better approach is one of these:

Keep examples/ focused on discordrb code: Make a !stop command that issues bot.stop.

bot.message(from: ..example ID here.., content: "!stop) do |event|
  event.respond("bye!")
  bot.stop
end

I believe an at_exit handler will also work. This might be preferred over begin..rescue Interrupt. I'm not picky about a one line { ... } over do..end here, I think one line is enough though.

at_exit { bot.stop }
bot.run

For the Wiki, that can be a space to discuss alternative means of exiting - begin..rescue Interrupt, Signal.trap("INT"), with a brief explanation about signals for those reading the Wiki. I'd rather explain that SIGINT is sent when you press CTRL+C, and not have the examples depend on you having read the Wiki to be clued into that.
WDYT?

I didn't know about at_exit. Yes, that is far better.
I do believe that all the examples should demonstrate proper basic bot procedure. at_exit { bot.stop } is less intrusive.


Explain how to update the GitLab Runner in the README

Hi, thanks for this nice Terraform module!
Could you add a section to the README that explains what the best way to update the GitLab Runner is (assuming the user has previously set up a GitLab Runner with this module)?

Thanks, good catch. Would you like to make a proposal via a PR?

Sure, except I'm not sure what the process is. Here's my guess: changing the gitlab_runner_version variable and then running terraform apply might do the trick.

We do not use a very smooth process yet. We currently

bump the version
apply the change
disable the runner (pause) in gitlab
terminate the runner instance, which will trigger the creation of a new agent (via the as group)
enable the the runner in gitlab

OK, thanks, I'll try that once there's a new version with significant improvements. If it works, I'll probably contribute a small PR with the necessary steps in detail.

We do not use a very smooth process yet. We currently
* bump the version

* apply the change

* disable the runner (pause) in gitlab

* terminate the runner instance, which will trigger the creation of a new agent (via the as group)

* enable the the runner in gitlab

Maybe it is easier to just stop the gitlab runner by ssh sudo gitlab-runner stop. It will stop accepting new jobs and wait for all jobs to finish.
Also you should consider terminating all the docker-machine instances. Next week I might work on an ansible script to do all that.

Runner will update now by replacing the auto scaling group, so I will close the issue


[Docs] Add vizro-ai chart examples to docs

Description
Added examples section with one page(chart examples)
Notice

[x] I acknowledge and agree that, by checking this box and clicking "Submit Pull Request":

I submit this contribution under the Apache 2.0 license and represent that I am entitled to do so on behalf of myself, my employer, or relevant third parties, as applicable.
I certify that (a) this contribution is my original creation and / or (b) to the extent it is not my original creation, I am authorized to submit this contribution on behalf of the original creator(s) or their licensees.
I certify that the use of this contribution as authorized by the Apache 2.0 license does not violate the intellectual property rights of anyone else.
I have not referenced individuals, products or companies in any commits, directly or indirectly.
I have not added data or restricted code in any commits, directly or indirectly.

Probably needs these few changes and I'm happy to pick it up tomorrow (Friday) and make edits direct on the branch once you've worked through anything you want to do from these suggestions.

I made a mixture of your and Li's change suggestions.

Agree with the suggestion to bring the graphic to the front in this case!


Adding to Pair docs

👍

Minor nitpick, but otherwise 👍

Given the meaning of indexing in genomics (BWA indexing, BAM indexing, VCF indexing), this section reads confusingly for me. Also, it's unclear how a researchers would want to use this feature.

@sooheelee I see--alternatively, I could move the pair member access syntax directly inside of the Pair Literals section.

The "indexing" jargon overlap is kind of inevitable -- and I don't think the burden of clarifying should be on every WDL technical doc that uses the term (that way lies some amount of madness). For one, it's a term that people familiar with scripting in bioinformatics should already understand. So the problem is really only for newbs. Obviously we want to make sure we help them navigate this stuff, so I would advocate for writing a doc about terminology for researchers looking at scripting for the first time. And when we write up a description of the Pair object for the user docs proper (WDL website/forum) we can make sure to do so in a way that is unambiguous and well furnished with domain-relevant examples.


 Super excited! Feel free to ask me any questions! :bird:

Auto response test

Aprove

I'm getting ready to merge and updating the change log - please @me if any other changes are pushed.

Thanks for getting everyone started on this! I can't wait to get everything rolling this year 🚀


Avoid "ReferenceError: ga is not defined" exception

No need to throw a fatal exception here.

Thanks for the fix


verify.go: Distinguish malicious verification failures from other kinds

Right now, we have the concept of SoftFailure which is used primarily when a header cannot be verified fully against a non-adjacent header (meaning the header could still be valid when applied during adjacent verification). All other failures are treated equally as hard failures. The problem with this is that this verification logic is used by different components (syncer, exchange). What is considered a hard failure for the syncer (incomingNetHead) is different from the exchange (when requesting Head). Therefore, we need an ability to distinguish in VerifyError whether the error was intentionally malicious or not so that the caller knows whether to ignore / drop the header or to punish the peer.

cc @S1nus


fix: pass id into  event instead of slug

The type of this PR is: Bugfix

This PR is related to CX-805
Description
We were passing the artwork slug where we should be passing the artwork ID when tracking taps on the sale home grid. This PR resolves that issue.
What the event looks like now:

PR Checklist (tick all before merging)

[x] I have included screenshots or videos to illustrate my changes, or I have not changed anything that impacts the UI.
[x] I have added tests for my changes, or my changes don't require testing, or I have included a link to a separate Jira ticket covering the tests.
[x] I have documented any follow-up work that this PR will require, or it does not require any.
[x] I have added an app state migration, or my changes do not require one. (What are migrations?)
[x] I have added a CHANGELOG.yml entry or my changes do not require one.

thanks!

thanks for fixing this 🎉


fix(deps): update icr.io/ext/logdna-agent docker tag to v3.10.1-20240827.12afa351b661bc07

This PR contains the following updates:

Package
Update
Change

icr.io/ext/logdna-agent
patch
3.10.1-20240807.70ab6fb75337a3c9 -> 3.10.1-20240827.12afa351b661bc07

Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
👻 Immortal: This PR will be recreated if closed unmerged. Get config help if that's undesired.

[ ] If you want to rebase/retry this PR, check this box

This PR has been generated by Renovate Bot.

/run pipeline

:tada: This issue has been resolved in version 1.28.7 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket:


limit json depth to 128

Closes: #450

I hereby agree to the terms of the CLA available at: https://yandex.ru/legal/cla/

Tests are failing!
Please look at userver/universal/src/formats/json/impl/types_impl.cpp (yes, a tricky one) how rapidjson's Value must be destroyed to avoid stack overflow.

Tests are failing!
Please look at userver/universal/src/formats/json/impl/types_impl.cpp (yes, a tricky one) how rapidjson's Value must be destroyed to avoid stack overflow.

Will do, thanks for the tip!


Two fingers are required to move the slider in accessibility mode

Environment
Description
when accessibility is turned on we need two fingers to move the slider, where as if you see the slider to adjust the volume, it works with single finger slider. This is confusing for a blind user using the accessibility mode in his Andorid device This is an issue only in Android. In iOS it works with single finger swipe.
Reproducible Demo

If you are aware on accessibilities issues, can you check @sharcoux/slider and tell me if you notice any issue with accessibility on iOS and android? Basically it is the web implementation of this slider made compatible with Android and iOS. And as this lib seems half abandoned, it might be good to have a good alternative.

Hello @AnoopN01!
Thank you for reporting this issue. Unfortunately I was unable to reproduce it, so could you please check if the issue you reported still exists on the latest version (v4.1.7)?
I would really appreciate a reproduction example/code snippet for this, optionally a demo 🙏

Closing due to lack of response from an author and no reproduction.


Paying to SBW testnet leads to routing failure

Setup:

LDK sample on desktop
SBW testnet wallet on android
SBW opened towards LDK a channel.

The SBW side info:
Channel details

Remote peer node ID
02ba6795ff89159b58dd95305569355cbad23301e286468410bbb65c5c2f20fd28

Local wallet node ID
023488cfb58a6b46f83bbeb185b4b4b6087de62a5a5141425dd83f37a3a8041201

Channel short ID
2578902323927449600

Funding txid
7cf45c3be6f231f8a60c10716a4048806508705eccf0c0c4b073a2480dfb9dc1

Channel started
2 hours ago

The LDK info:
> listchannels
[
	{
		channel_id: c19dfb0d48a273b0c4c0f0cc5e7008658048406a71100ca6f831f2e63b5cf47c,
		funding_txid: 7cf45c3be6f231f8a60c10716a4048806508705eccf0c0c4b073a2480dfb9dc1,
		peer_pubkey: 023488cfb58a6b46f83bbeb185b4b4b6087de62a5a5141425dd83f37a3a8041201,
		short_channel_id:<PHONE_NUMBER>927449600,
		is_channel_ready: true,
		channel_value_satoshis: 650000,
		local_balance_msat: 800000,
		available_balance_for_send_msat: 150000,
		available_balance_for_recv_msat: 642700000,
		channel_can_send_payments: true,
		public: false,
	},
]
> listpeers
{
	pubkey: 023488cfb58a6b46f83bbeb185b4b4b6087de62a5a5141425dd83f37a3a8041201
},

Payment of invoice produced by LDK is ok. But, when I try to pay invoice produced by SBW, I got:
> sendpayment lntb500n1p33v9sxpp532xw4h2utv0dx8rm0q37kc288crv555evq5sqtpxv22v8w2ar4zqdqqsp57dg9y0fest04hfgs6we7kvxu0wqy7teqxn7csqjtvtnhcsj0dhcsxqy9gcqcqzys9qyysgqrzjq2ax090l3y2ekkxaj5c926f4tjadyvcpu2rydpqshwm9chp0yr7jsg72rgqqqgqqqqqqqqlgqqqqqqqqfq0l22mmx258r0cfgwzqusjjl76zmwyhchum52496snmakalevhkxnk7m5hv0pdvllyd49js50qjpm78634k7xzhxwr9u8gsjc37gjhlsqjywpza
ERROR: failed to find route: Failed to find a path to the given destination

The example of invoice produced by LDK (that is ok):
lntb7u1p33v9dfdqud3jxktt5w46x7unfv9kz6mn0v3jsnp4q2ax090l3y2ekkxaj5c926f4tjadyvcpu2rydpqshwm9chp0yr7jspp5s64ap9480lpxh4tcf6ufcumjx8qy28xelwfg3fy7nhnvgpylhnmssp5llyfacaaefmxdjauqv3s8g7mujhujedx8gsz2ghh0u3ps6ye3qns9qyysgqcqpcxqzjcyr049wn9qwh93mya66ak75c0e6untgr5fyr2fnqu8pe7k8q8rqlz8qn420r2ewv2g07t32sla2fgdnx28m0st9cs30d75pmej9upy8spqn2rr6

Applied the patch (actual I needed to patch the patch to use 0.0.110 version), here the logs:
2022-09-06 03:19:34.079 INFO  [lightning::ln::channelmanager:6965] Successfully loaded channel c19dfb0d48a273b0c4c0f0cc5e7008658048406a71100ca6f831f2e63b5cf47c
2022-09-06 03:19:34.081 TRACE [lightning::chain::chainmonitor:596] Got new ChannelMonitor for channel c19dfb0d48a273b0c4c0f0cc5e7008658048406a71100ca6f831f2e63b5cf47c
2022-09-06 03:19:34.084 TRACE [lightning::chain::chainmonitor:603] Finished persisting new ChannelMonitor for channel c19dfb0d48a273b0c4c0f0cc5e7008658048406a71100ca6f831f2e63b5cf47c
2022-09-06 03:19:34.085 TRACE [lightning_background_processor:318] Calling ChannelManager's timer_tick_occurred on startup
2022-09-06 03:19:40.553 DEBUG [lightning::ln::peer_handler:973] Finished noise handshake for connection with 023488cfb58a6b46f83bbeb185b4b4b6087de62a5a5141425dd83f37a3a8041201
2022-09-06 03:19:40.553 TRACE [lightning::ln::peer_handler:851] Enqueueing message Init { features: [170, 81, 10, 8, 0, 160, 8], remote_network_address: Some(IPv4 { addr: [184, 22, 79, 207], port: 36300 }) } to 023488cfb58a6b46f83bbeb185b4b4b6087de62a5a5141425dd83f37a3a8041201
2022-09-06 03:19:41.100 INFO  [lightning::ln::peer_handler:1096] Received peer Init message from 023488cfb58a6b46f83bbeb185b4b4b6087de62a5a5141425dd83f37a3a8041201: DataLossProtect: supported, InitialRoutingSync: not supported, UpfrontShutdownScript: not supported, GossipQueries: supported, VariableLengthOnion: supported, StaticRemoteKey: supported, PaymentSecret: supported, BasicMPP: supported, Wumbo: supported, ShutdownAnySegwit: supported, ChannelType: not supported, SCIDPrivacy: not supported, ZeroConf: not supported, unknown flags: supported
2022-09-06 03:19:41.100 DEBUG [lightning::ln::channelmanager:6169] Generating channel_reestablish events for 023488cfb58a6b46f83bbeb185b4b4b6087de62a5a5141425dd83f37a3a8041201
2022-09-06 03:19:41.100 TRACE [lightning::ln::channel:5325] Enough info to generate a Data Loss Protect with per_commitment_secret 8b43fdb784d62df50997c5e518a5bfc6ae00848d80dc0e4429e06edf3892523f for channel c19dfb0d48a273b0c4c0f0cc5e7008658048406a71100ca6f831f2e63b5cf47c
2022-09-06 03:19:41.100 DEBUG [lightning::ln::peer_handler:1542] Handling SendChannelReestablish event in peer_handler for node 023488cfb58a6b46f83bbeb185b4b4b6087de62a5a5141425dd83f37a3a8041201 for channel c19dfb0d48a273b0c4c0f0cc5e7008658048406a71100ca6f831f2e63b5cf47c
2022-09-06 03:19:41.100 TRACE [lightning_background_processor:352] Persisting ChannelManager...
2022-09-06 03:19:41.101 TRACE [lightning::ln::peer_handler:851] Enqueueing message ChannelReestablish { channel_id: [193, 157, 251, 13, 72, 162, 115, 176, 196, 192, 240, 204, 94, 112, 8, 101, 128, 72, 64, 106, 113, 16, 12, 166, 248, 49, 242, 230, 59, 92, 244, 124], next_local_commitment_number: 7, next_remote_commitment_number: 6, data_loss_protect: Present(DataLossProtect { your_last_per_commitment_secret: [139, 67, 253, 183, 132, 214, 45, 245, 9, 151, 197, 229, 24, 165, 191, 198, 174, 0, 132, 141, 128, 220, 14, 68, 41, 224, 110, 223, 56, 146, 82, 63], my_current_per_commitment_point: PublicKey(02020202020202020202020202020202020202020202020202020202020202ffcee50f772e0a9972250d4b61b3e5beb95de897c73b4ed1cc35ed013accf1c840) }) } to 023488cfb58a6b46f83bbeb185b4b4b6087de62a5a5141425dd83f37a3a8041201
2022-09-06 03:19:41.101 TRACE [lightning::ln::peer_handler:851] Enqueueing message GossipTimestampFilter { chain_hash:<PHONE_NUMBER>33ea01ad0ee984209779baaec3ced90fa3f408719526f8d77f4943, first_timestamp:<PHONE_NUMBER>, timestamp_range:<PHONE_NUMBER> } to 023488cfb58a6b46f83bbeb185b4b4b6087de62a5a5141425dd83f37a3a8041201
2022-09-06 03:19:41.104 TRACE [lightning_background_processor:354] Done persisting ChannelManager.
2022-09-06 03:19:41.608 TRACE [lightning::ln::peer_handler:1135] Received message ChannelReestablish(ChannelReestablish { channel_id: [193, 157, 251, 13, 72, 162, 115, 176, 196, 192, 240, 204, 94, 112, 8, 101, 128, 72, 64, 106, 113, 16, 12, 166, 248, 49, 242, 230, 59, 92, 244, 124], next_local_commitment_number: 7, next_remote_commitment_number: 6, data_loss_protect: Present(DataLossProtect { your_last_per_commitment_secret: [49, 58, 51, 184, 239, 3, 245, 235, 37, 95, 190, 91, 154, 67, 8, 71, 136, 247, 81, 101, 142, 236, 249, 120, 11, 57, 117, 223, 75, 156, 183, 97], my_current_per_commitment_point: PublicKey(3aa42a1dcaa84b806ab1bb440861729d38f8711898da08a5389933bdae323504da9e55ea46c119a786c15d6ef75f9daaf4b9997cd1e15b8a4d63344c194a53f9) }) }) from 023488cfb58a6b46f83bbeb185b4b4b6087de62a5a5141425dd83f37a3a8041201
2022-09-06 03:19:41.609 TRACE [lightning::ln::channel:5221] Creating an announcement_signatures message for channel c19dfb0d48a273b0c4c0f0cc5e7008658048406a71100ca6f831f2e63b5cf47c
2022-09-06 03:19:41.609 TRACE [lightning::ln::channel:5225] Cannot create an announcement_signatures as channel is not public.
2022-09-06 03:19:41.609 DEBUG [lightning::ln::channel:3940] Reconnected channel c19dfb0d48a273b0c4c0f0cc5e7008658048406a71100ca6f831f2e63b5cf47c with no loss
2022-09-06 03:19:41.609 TRACE [lightning::ln::channelmanager:2384] Attempting to generate channel update for channel c19dfb0d48a273b0c4c0f0cc5e7008658048406a71100ca6f831f2e63b5cf47c
2022-09-06 03:19:41.609 TRACE [lightning::ln::channelmanager:2393] Generating channel update for channel c19dfb0d48a273b0c4c0f0cc5e7008658048406a71100ca6f831f2e63b5cf47c
2022-09-06 03:19:41.610 TRACE [lightning::ln::peer_handler:1577] Handling SendChannelUpdate event in peer_handler for node 023488cfb58a6b46f83bbeb185b4b4b6087de62a5a5141425dd83f37a3a8041201 for channel<PHONE_NUMBER>927449600
2022-09-06 03:19:41.610 TRACE [lightning_background_processor:352] Persisting ChannelManager...
2022-09-06 03:19:41.610 GOSSIP [lightning::ln::peer_handler:849] Enqueueing message ChannelUpdate { signature:<PHONE_NUMBER>eecc1adfd402cb594f580eda368a446fb753ab77c6f6bcfa30b1da714d89200220148faac5a276abe45984c52aa4559d8a501371ebcaae278cbedfc22557698855, contents: UnsignedChannelUpdate { chain_hash:<PHONE_NUMBER>33ea01ad0ee984209779baaec3ced90fa3f408719526f8d77f4943, short_channel_id:<PHONE_NUMBER>927449600, timestamp:<PHONE_NUMBER>, flags: 1, cltv_expiry_delta: 72, htlc_minimum_msat: 1000, htlc_maximum_msat: 585000000, fee_base_msat: 1000, fee_proportional_millionths: 0, excess_data: [] } } to 023488cfb58a6b46f83bbeb185b4b4b6087de62a5a5141425dd83f37a3a8041201
2022-09-06 03:19:41.613 TRACE [lightning_background_processor:354] Done persisting ChannelManager.
2022-09-06 03:19:56.458 TRACE [lightning::routing::router:867] Searching for a route from payer 02ba6795ff89159b58dd95305569355cbad23301e286468410bbb65c5c2f20fd28 to payee 027055478b3545fae61415803dd234aabafbb3e35545a29ff5a802090f616270bf with MPP and 1 first hops overriding the network graph
2022-09-06 03:19:56.458 TRACE [lightning::routing::router:971] Building path from 027055478b3545fae61415803dd234aabafbb3e35545a29ff5a802090f616270bf (payee) to 02ba6795ff89159b58dd95305569355cbad23301e286468410bbb65c5c2f20fd28 (us/payer) for value 75000 msat.
2022-09-06 03:19:56.458 TRACE [lightning::routing::router:1464] Starting main path collection loop with 0 nodes pre-filled from first/last hops.
2022-09-06 03:19:56.458 TRACE [lightning::routing::router:1464] Starting main path collection loop with 0 nodes pre-filled from first/last hops.
2022-09-06 03:19:56.458 TRACE [lightning::routing::router:1631] Have now collected 0 msat (seeking 225000 msat) in paths. Last path loop did not find a new path.

Hmm, that log says you're trying to pay 027055478b3545fae61415803dd234aabafbb3e35545a29ff5a802090f616270bf, but the peer the channel is with is 023488cfb58a6b46f83bbeb185b4b4b6087de62a5a5141425dd83f37a3a8041201. Thus, because 027055478b3545fae61415803dd234aabafbb3e35545a29ff5a802090f616270bf does not have any public channels we of course have no route to that peer?

The 027055478b3545fae61415803dd234aabafbb3e35545a29ff5a802090f616270bf can have a private channel to 023488cfb58a6b46f83bbeb185b4b4b6087de62a5a5141425dd83f37a3a8041201. So if there are hints in the route should we build path via the dead end?

Is SBW trying to be too-clever and signing invoices with a random key? That won't work for your channel counteraprty being the one to pay you - obviously a route hint that says "hey, I have a channel with you" is/should be ignored if we don't actually have a channel with the node in the invoice.

I found related part of SBW. It indeed creates random 32 bytes and derive one-time key to sign the invoice.
val prExt = LNParams.cm.makePrExt(toReceive = manager.resultMsat, description, allowedChans = cs, Crypto.sha256(preimage), randomBytes32)

  def makePrExt(toReceive: MilliSatoshi, description: PaymentDescription, allowedChans: Seq[ChanAndCommits], hash: ByteVector32, secret: ByteVector32): PaymentRequestExt = {
    val hops = allowedChans.map(_.commits.updateOpt).zip(allowedChans).collect { case Some(usableUpdate) ~ ChanAndCommits(_, commits) => usableUpdate.extraHop(commits.remoteInfo.nodeId) :: Nil }
    val pr = PaymentRequest(LNParams.chainHash, Some(toReceive), hash, secret, LNParams.secret.keys.fakeInvoiceKey(secret), description.invoiceText, LNParams.incomingFinalCltvExpiry, hops.toList)
    PaymentRequestExt.from(pr)
  }

https://github.com/btcontract/wallet/blob/master/app/src/main/java/com/btcontract/wallet/BaseActivity.scala#L745

I see that Eclair has the same behavior in the setup. I need to check another setup:

SBW Alice
LDK Kevin
LDK Charlie
SBW Bob
Alice has a private channel to Kevin. Kevin has a public channel to Charlie. Bob has private channel to Charlie.

Alice -> LDK -> Bob payments should work normally.


Hello, I separated two Twitch accounts with commas, but only the first account will progress with the drop, and the second account has no response.

And it doesn't seem to automatically claim drops

Try changing browsers parameter in config to true,. And see how the second account works and tell me what troubles with it.
    "browsers": true,

The first image shows my two accounts, while the second image shows that only one account is watching and the second account has no response

How can see the thread works means the problem is not in this software

Okay, but I have another question. It seems like it can watch automatically, but it cannot automatically claim drops。May I ask if my settings are not turned on?

I checked reason this problem. Its happen because twitch changed drops-claim method. I haven't time to fix this now. Try use other similar app.


Bitwise operations take ownership

I am not sure if this an issue or something due to a lack of Rust knowledge, but there seems to be a lack of way for efficient bitwise comparisons.  When trying to do something like xor'ing two BitVecs, ownership is moved for the XOR:
        let bv2 = bv::bitvec![0, 0, 0, 0, 1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0];
        let t = bv1 ^ bv2;
        assert_eq!(t.count_ones(), 3);
        let t2 = bv2 ^ bv1;
        assert_eq!(t2.count_ones(), 3);

This fails due to a moved bv1 and bv2. I think this is due to the bitxor trait.
From what I can tell the only way around this is to clone bv1 and bv2 for every operation, which can have performance implications when dealing with a large number of large bitvectors.
Looking at creating a slice like the following doesn't work due to a lack of xor for bitslice.
        let bv1 = bv::bitvec![0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
        let bv2 = bv::bitvec![0, 0, 0, 0, 1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0];
        let b1: &bv::BitSlice = &bv1[..];
        let b2: &bv::BitSlice = &bv2[..];

        let t = b1 ^ b2;
        assert_eq!(t.count_ones(), 3);

Am I missing something obvious or will a borrowed xor need to be hand rolled?
Thanks!

The standard library implements Arith<Rhs=&Self>; I do not. That is a bug on my part due to merely not having pasted in enough trait boilerplate, and since you're the first person to be stung by its absence, I just haven't moved it up the todo list.

Oh, I see what happened. I implement Arith<Rhs = impl Iterator<Item = bool>>, but BitSlice recently changed to be Iterator<Item = &bool>. You should be able to do BitVec ^ BitVec.iter().copied(). I'll still expand the implementation surface to accept iterators over borrows.

Thanks for the fast response!
I am not sure I followed the potential solution 100%, but either side of the ^ seems to move, which means both sides have to copied.
This fails to bv1 being moved

        let bv1 = bv::bitvec![0, 0, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0];
        let bv2 = bv::bitvec![0, 0, 0, 0, 1, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0];
        let t = bv1 ^ bv2.iter().copied();
        assert_eq!(t.count_ones(), 3);
        let t2 = bv2 ^ bv1.iter().copied();
        assert_eq!(t2.count_ones(), 3);

Yes, the left hand side always moves. This is because BitVec is a heap allocation, and preserving the source while creating a new output store would cause a new allocation to occur. You will need to write bv1.clone() ^ rhs in order to explicitly duplicate the source vector before acting on it. I do not plan to change that behavior, as implicit allocations are generally considered poor form.
This is an unfortunate consequence of not having any Copy types corresponding to direct arrays; I only have borrowed slices and owned allocations.
I should note that the expression let out = lhs.clone() ^ rhs.iter().copied(); only results in one copy event; the expression .iter().copied() merely produces bool instead of &bool when traversing. It's a free operation that only exists to satisfy the type checker.
I'll still rework the trait surface to accept BitVec sigil &BitVec, but the left-hand side will always need to be explicitly cloned in order to retain the original vector.

Depending on your goals, using BitVec's arithmetic operations may also be the wrong thing to do. These operations are provided in order to make working with any bit sequence easier, but in order to do this, they are much slower than the equivalent loop on their underlying storage would be.
If you control the construction of both BitVecs, and know that they are of the same type parameters, this code is uglier, much more narrowly usable, but much faster:
let bv1: BitVec<_, _> = make();
let bv2: BitVec<_, _> = make();
let out: Vec<_> = bv1.as_slice().clone();

for ((lhs, rhs), dst) in bv1.as_slice().iter().copied()
  .zip(bv2.as_slice().iter().copied())
  .zip(out.iter_mut())
{
  *dst = lhs ^ rhs;
}

This specialization can't be put in the trait implementation, or I wouldn't even mention it.

Thanks much! I was thinking since the output of XOR is new that it could have been stack allocated without any modification of LHS/RHS.
I wasn't aware of .iter().copied() so that is good to know.
Your second suggestion seems good. I really want for now a count of XOR bits between controlled bitvectors  (looking for K bitvectors with the smallest hamming distance from a reference bitvec), but I will need a way later of generating AND/XOR bitvec's quickly.

I am vaguely working on a way to have array types, but without const-generics they are a lot harder to do.
I completely forgot that BitVec::into_vec exists. It only reëncodes the vector handle without doing anything to the actual owned buffer, so feel free to move between Vec/slice and BitVec/BitSlice types liberally as needed. Bulk operations like Boolean arithmetic are better done with ordinary Vec/slice(at least until I get specialization), and you can easily move betweenstdandbitvec` types to get the behavior best suited to any particular need.

Update: coherence rules disallow neighboring impls of BitAnd<I: Iterator<Item = bool>> and BitAnd<I: Iterator<Item = &bool>>, despite the fact that the trait system does not a type to implement Iterator twice.
I will add documentation to the README and to each trait to more clearly explain the movement of the left argument and how to construct right arguments.

This behavior remains correct as it stands; the op= sigil can be used to borrow its arguments rather than move them, at the cost of explicitly declaring where the new memory is allocated.


Make passing a block to method that doesn't accept a block an error in typed: strict

https://sorbet.run/#%23 typed%3A strict
extend T%3A%3ASig

sig {params(s%3A String).void}
def hello(s)
  puts(s)
end

sig {void}
def main
  hello('foo') do
    puts('bar')
  end
end

This was implemented at some point, but I don't remember which PR. The example in the issue correctly errors, as requested.


refactor: add versions & multi-instance docusaurus

Fixes DOC-69
Changes

Moved vcluster part to /vcluster
Moved platform part to /platform
Removed versioning for overview
Added versioning for vcluster part (v0.20 & v0.19)
Added versioning for platform part (v4.0 & v3.4)

This is failing due to a lot of broken markdown links (npm run build).  I checked out the PR and am working on fixing the links.

I fixed the compile errors by changing to relative links, which is recommended by Docusaurus for versioned docs.
Moved the fragments and partials to vcluster and platform; this is a quick fix and needs to be cleaned up since the platform doesn't use most of the fragments that vcluster does

Get Started "Get Started" section should be on the 1st level along with "What are virtual clusters" to act as a quick starting point. I understand it will be duplicated inside the vCluster section but currently "What are virtual clusters?" is also duplicated that way and it seems fine.

I moved Get Started to the vCluster section because Get Started contains links to pages int the vCluster section as well as partials. Docusaurus has limitations.

We can't use relative links between docs sets. Overview, vcluster, and platform are all different docs sets. To link to content in a different docs set, we have to use a full URL link not a relative file link.
Partials must live in the docs set that uses them, especially since the partial/fragment is versioned with the docs set.

Also, there are no plans to version the "Overview" landing page. One option would be to make docs site landing page (Overview section) a brief overview of the 2 products rather than repeating the "What are virtual clusters" content.


Need way to use ExcludeVersion in Nuget.config

I am using Nuget integrated with Visual Studio 2017.  I don't see a way to change the command line parameters for Nuget.  I need to have -ExcludeVersion option used when I download packages via Nuget in Visual Studio.  Is there a way to enable this command-line option via Nuget.config.  If not, I would like to submit this for a feature request.

Hey @varnk,
There's no way to achieve that today, and we don't really think we want to support that at this point.
Your question is about packages.config and at this point we're focusing on PackageReference experiences primarily.
Furthermore, the packages folder is meant to be shared among projects, something that NuGet reads, but if we exclude the version we'd be breaking some of those Visual Studio project tied experiences.


Fix warning messags in tests; update rlocus/pzmap limits

This PR fixes some warning messages that were showing up due to bad default limits in root locus plots and pole-zero diagrams.
(There are still a few warnings that show up in unit tests, but these seem to be due to some deprecations that matplotlib needs to fix and some strange "divide by zero" errors in computing determinants that must be in numpy or openblas.)

coverage: 94.416% (-0.009%) from 94.425%
when pulling dea3821e5f49ff1db4a43436f48787cabfaf7500 on murrayrm:fix_warnings-30Mar2024
into 4d878a966ca576f53b0d2ae9fd93ce598f60d748 on python-control:main.


Fix for #119. Strip the concatenation garbage.

Now I see you did the same in one command... rebasing mine.

This will be merged as part of #122.


the double note after image

is it coded in or is it a script

i want the script for it is bad :(

is it coded in or is it a script

its hard coded into the game and as far as i know there isnt really any way to replicate it into a script


[IMP] Switch from versioneer-518 to versioneer?

Is your enhancement request related to a problem? Please describe.
According to https://github.com/python-versioneer/versioneer-518/issues/5, it might be the case that versioneer can do everything that versioneer-518 can do. Without looking into it deeply, it has a "Build-time dependency mode" that is also not vendored.
I am working on packaging and use build to build this package. By default, it will validate that all declared build dependencies are present, and I'm hoping to skip packaging versioneer-518 if it is obsolete.
Describe the solution you'd like
I'm not too familiar with versioneer and how this project uses it, but do you think it would be possible to switch over?

versioneer, in combination with bunmpversion, helps us bump/set release version, as well as setting up the sdk as editable package during dev. On release a specific version of the SDK package, a static _version.py file is generated and used for the actual build. Maybe you are building with the _verdion.py file in the repo, hence the versioneer dependency is detected?

During bumping version for release. the SDK version is stored is in fact stored in bumpversion cfg file


HDDS-2788. Fix the wrong source link in docs

What changes were proposed in this pull request?
Fix the wrong source link in ozone docs site
What is the link to the Apache JIRA
https://issues.apache.org/jira/browse/HDDS-2788

Thanks @jiwq for the report and contribution.
LGTM.

Thanks @cxorm and @adoroszlai for the review.


PageChooser field in admin view gives error on clicking button to link a page

Whenever I try to link a page using the PageChooserField in admin view, I get the error - "Uncaught TypeError: container.modal is not a function" in the console, which is from the file "modal-workflow.js". The modal never shows up and the same case is true for the ImageChooserPanel as well. Any idea what's wrong?
Thanks.

Hmm, can't really see what might be causing that - the modal function should be defined by /static/wagtailadmin/js/vendor/bootstrap-modal.js. What do you get if you enter $('body').modal on the console?
Also, what browser and Wagtail version are you running?

Closing for now due to lack of info - please update this ticket if you can provide the requested details.

I have encountered this issue as well.  From what I can gather, this issue is probably outside the scope of wagtail.
I am using the django-address package so that I have an auto-completing/geocoding address field and form widget on one of my snippets.  The widget that I'm pulling uses the Google Places API.  Any snippet I have that has an ImageChooserPanel and this address field is causing the issue Uncaught TypeError:container.modal is not a function when I click the ImageChooserPanel button.
$('body').modal returns undefined.  Clicking the ImageChooserPanel button appears to append the modal div correctly.
I'm using Wagtail 2.0 and Chrome.  Any hunches on why this behavior would happen?  As far as I can tell, the JS loaded by Google isn't doing anything to inhibit the bootstrap-modal js.
Thanks for your time!

Hi @corysutyak,
You might have a better response asking on Stack Overflow - we can't really do general troubleshooting here.


[breadcrumb] should reflect a navigation role

notice, due to vivid avoiding the practice of mutating host, and rather utilize it as service, we skip the template syntax / tag causing the breadcrumb to reflect only as list role
https://github.com/microsoft/fast/blob/0e94e9cdecc82986af91d94713df313f7bdca8aa/packages/web-components/fast-foundation/src/breadcrumb/breadcrumb.template.ts#L14
we should implement such role as a wrapper in template

@YonatanKra 👆

I believe automated checks would have thrown on that
see
https://github.com/Vonage/vivid-3/blob/2422ecd643bce34929c16ef02e5e80a8cf73c1a2/libs/components/src/lib/calendar/calendar.spec.ts#L312-L327

I believe automated checks would have thrown on that see
https://github.com/Vonage/vivid-3/blob/2422ecd643bce34929c16ef02e5e80a8cf73c1a2/libs/components/src/lib/calendar/calendar.spec.ts#L312-L327

No it does not:


Constraint: insert one object type or the other, but not both.

Schema migration error: InternalServerError: UnresolvedReferenceError: reference to an undefined item default::NULL in default::CourseDeployment@std::expression@@(((.school IS NOT NULL) AND (.user IS NULL))
OR ((.school IS NULL) AND (.user IS NOT NULL)))
Hint: This is most likely a bug in EdgeDB. Please consider opening : reference to an undefined item default::NULL in default::CourseDeployment@std:
an issue ticket at https://github.com/edgedb/edgedb/issues/new?templal IS NULL) AND (.user IS NOT NULL)))te=bug_report.md

EdgeDB Version: 4.0-rc.2+f457342
EdgeDB CLI Version: EdgeDB CLI 4.1.0+127aeb9
OS Version: Windows 10 Home

Steps to Reproduce:

insert one object type or the other, but not both.

Schema:
  required course: Course;
  school: School;
  user: User;
  audience: Audience;
  link stageDeployment := .<courseDeployment [is StageDeployment];
  constraint expression on (
  (__subject__.school IS NOT NULL AND __subject__.user IS NULL)
  OR
  (__subject__.school IS NULL AND __subject__.user IS NOT NULL)
);

}```

constraint expression on ( (exists(subject.school)  AND not exists(subject.user)) OR (exists(subject.school)  AND not exists(subject.user)) ); worked just fine

The ISE wrapping is a (usability) bug though.

Message improved in #7351


Toggling find features from command palette doesn't work

VSCode Version: 1.39.2
OS Version: OSX 10.14.6 (Darwin x64 18.7.0)

Steps to Reproduce:

Open search box with cmd+f
Use keyboard shortcuts to try to toggle "find using regex" and "find using whole word" - the buttons toggle correctly
Try toggling from the palette - it doesn't work

We didn't expose those commands for the Find Widget in the editor, the commands you see are from Terminal. @Tyriar we may want to add Terminal prefixes for them.

Oh both these commands are meant for the terminal?

Apparently there are 2 terminal commands, one with prefix and one without 🤷♂

@Tyriar There are two entries defined in terminal.contribution.ts for toggling regex find. I tried removing one of those and the extra command did not show up in the command palette. I'm not sure whether this is the correct way for doing this. Will be happy to raise a PR for the same.
Refer:
https://github.com/microsoft/vscode/blob/master/src/vs/workbench/contrib/terminal/browser/terminal.contribution.ts#L518
actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(ToggleRegexCommand, ToggleRegexCommand.ID, ToggleRegexCommand.LABEL, {
	primary: KeyMod.Alt | KeyCode.KEY_R,
	mac: { primary: KeyMod.CtrlCmd | KeyMod.Alt | KeyCode.KEY_R }
}, KEYBINDING_CONTEXT_TERMINAL_FIND_WIDGET_FOCUSED), 'Terminal: Toggle find using regex');

https://github.com/microsoft/vscode/blob/master/src/vs/workbench/contrib/terminal/browser/terminal.contribution.ts#L522
actionRegistry.registerWorkbenchAction(new SyncActionDescriptor(ToggleRegexCommand, ToggleRegexCommand.ID_TERMINAL_FOCUS, ToggleRegexCommand.LABEL, {
	primary: KeyMod.Alt | KeyCode.KEY_R,
	mac: { primary: KeyMod.CtrlCmd | KeyMod.Alt | KeyCode.KEY_R }
}, KEYBINDING_CONTEXT_TERMINAL_FOCUS), 'Terminal: Toggle find using regex', category);

@sohailrajdev97 thanks for looking into it and the offer, I put a PR together as it needed some experimentation to figure out the right fix https://github.com/microsoft/vscode/pull/83091


flutter build ios-framework add2app not work

Flutter (Channel stable, 2.5.0, on macOS 13.0 22A380 darwin-x64, locale zh-Hans-CN)
I want to add flutter app to the ios native app, then I use flutter build ios-framework command build frameworks , then I got

my pubspec.yaml just dependencies path_provider: ^2.0.4 and  fijkplayer: ^0.10.1
then my ios native app depend the frameworks but build error

@Gaoxichao
Please provide a completed and minimal reproducible code sample along with detailed Steps to reproduce (steps & commands you executed) so that we may verify this.
Also, as far as I can see, you are using the old Flutter version 2.5.0, the latest Flutter stable is 3.3.10 and the master is 3.7.0. Please try upgrading them and retry to see if this issue still reproduces.
Thank you!


Issue with using clasp after v2.4.0 release

Issue with using clasp after the new release (v2.4.0)
fs.js:498
  handleErrorFromBinding(ctx);
  ^

Error: ENOENT: no such file or directory, open 'package.json'
    at Object.openSync (fs.js:498:3)
    at Object.readFileSync (fs.js:394:35)
    at file:///usr/local/lib/node_modules/@google/clasp/node_modules/ts2gas/src/index.js:35:35
    at ModuleJob.run (internal/modules/esm/module_job.js:152:23)
    at async Loader.import (internal/modules/esm/loader.js:177:24)
    at async Object.loadESM (internal/process/esm_loader.js:68:5) {
  errno: -2,
  syscall: 'open',
  code: 'ENOENT',
  path: 'package.json'
}

Seems to be dependency issue with ts2gas.
Downgrading to v2.3.2 helped solve the issue.
Expected Behavior
clasp login/ any command would not work
Actual Behavior
clasp login etc to work.
Steps to Reproduce the Problem
Just install clasp and try to use it

npm i @google/clasp -g
clasp --help

Specifications

Node version (node -v): v14.17.0
Version (clasp -v):  v2.4.0
OS (Mac/Linux/Windows): Mac

Same error on linux

Same error on Windows

Created an empty package.json file as a workaround.
echo "{}" > package.json

The issue seems to be in latest ts2gas

Seeing the same problem but with a slightly different error message while accessing clasp through the google cloud editor.
`/usr/local/nvm/versions/node/v12.14.1/lib/node_modules/@google/clasp/build/src/index.js:2
import why from 'wtfnode'; // should be your first require
^^^^^^
SyntaxError: Cannot use import statement outside a module
at Module._compile (internal/modules/cjs/loader.js:891:18)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:991:10)
at Module.load (internal/modules/cjs/loader.js:811:32)
at Function.Module._load (internal/modules/cjs/loader.js:723:14)
at Function.Module.runMain (internal/modules/cjs/loader.js:1043:10)
at internal/main/run_main_module.js:17:11`
@sanjeevdialpad 's workaround was successful

Seeing the same problem but with a slightly different error message while accessing clasp through the google cloud editor.
/usr/local/nvm/versions/node/v12.14.1/lib/node_modules/@google/clasp/build/src/index.js:2
import why from 'wtfnode'; // should be your first require
^^^^^^

SyntaxError: Cannot use import statement outside a module
    at Module._compile (internal/modules/cjs/loader.js:891:18)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:991:10)
    at Module.load (internal/modules/cjs/loader.js:811:32)
    at Function.Module._load (internal/modules/cjs/loader.js:723:14)
    at Function.Module.runMain (internal/modules/cjs/loader.js:1043:10)
    at internal/main/run_main_module.js:17:11

@sanjeevdialpad 's workaround was successful

I had that error but it went away when I either upgraded node or npm (I upgraded both with sudo npm install -g npm@latest && sudo npm install -g node@latest
Still have the main error in this issue.

Any word/update on the fix for the original issue?

I was not able to reproduce the issue. Hence I am unsure if/how to fix https://github.com/grant/ts2gas

I got "ENOENT: no such file or directory, open 'package.json'" message after renaming code.gs to code.ts and run "clasp push".
To resolv this problem i have put https://github.com/google/clasp/blob/master/package.json in root of my project.


how to remove leading / from frame_id

I'm using robot localization package and it doesn't like the "/" on the frame id. I've read some stuff on the closed issues, but I'm not sure how to correct this. I've installed from binaries on kinetic and it uses the "/"
Do I need to install from source? which branch is used for kinetic and have this issue solved?
Thank

There is no way to configure the driver to not use the leading / prefix. If you wish to install from source, ROS kinetic uses the kinet-devel branch, and you can edit the static method get_frame_id() to remove the prefix https://github.com/ros-drivers/nmea_navsat_driver/blob/42310d4b3894a45af0efd921582791ab8a17d53f/src/libnmea_navsat_driver/driver.py#L199-L211


544/satellite-15mins

Pull Request
Description

change satellte, hrvsatellite and optical flow to 15 mins timescale
have configuration option for this 15 mins

Fixes #544
How Has This Been Tested?

normal unittests

added extra tests

[ ] No

[ ] Yes

Checklist:

[ ] My code follows OCF's coding style guidelines
[ ] I have performed a self-review of my own code
[ ] I have made corresponding changes to the documentation
[ ] I have added tests that prove my fix is effective or that my feature works
[ ] I have checked my code and corrected any misspellings

Codecov Report

Merging #566 (71ea7dd) into main (3f8d877) will increase coverage by 0.06%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##             main     #566      +/-   ##
==========================================
+ Coverage   90.09%   90.15%   +0.06%
==========================================
  Files          42       42
  Lines        2757     2774      +17
==========================================
+ Hits         2484     2501      +17
  Misses        273      273

Impacted Files
Coverage Δ

nowcasting_dataset/config/model.py
92.81% <100.00%> (+0.24%)
:arrow_up:

...a_sources/optical_flow/optical_flow_data_source.py
100.00% <100.00%> (ø)

...et/data_sources/satellite/satellite_data_source.py
82.81% <100.00%> (+1.14%)
:arrow_up:

nowcasting_dataset/manager.py
80.39% <100.00%> (ø)

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 9e29dc3...71ea7dd. Read the comment docs.


ESP32 Arduino OpenThreadCLI examples for M5NanoC6

ESP32 Arduino OpenThreadCLI examples for M5NanoC6
The aim is to offer some examples compatible with this board using the OpenThread protocol.
OpenThread COAP examples

COAP Lamp
COAP Switch

I will check it out, thanks for contributing.


Error when file contains too many symbols

Describe the bug
See screenshot below:

System information

OS: Linux
Neovim version: NVIM v0.7.0-dev+863-g8f27c4a04
AerialInfo:

Aerial Info
-----------
Filetype: lua
Configured backends:
  lsp (supported) (attached)
  treesitter (supported)
  markdown (not supported) [Filetype is not markdown]
Show symbols: Class, Constructor, Enum, Function, Interface, Method, Struct

This is a bit mis-leading as the error is happening in a work environment where I cannot copy/paste from easily.
To Reproduce
Steps to reproduce the behavior:

Run :AerialToggle in a file with a large number of symbols

Not a minimal configuration, however this is what I use:
  require("aerial").setup({
    close_behavior = "close",
    default_bindings = true,
    default_direction = "float",
    diagnostics_trigger_update = true,
    highlight_mode = "split_width",
    highlight_on_jump = 300,
    link_tree_to_folds = true,
    link_folds_to_tree = false,
    manage_folds = "auto",
    max_width = 40,
    min_width = 10,
    nerd_font = "auto",
    open_automatic = false,
    post_jump_cmd = "normal! zz",
    close_on_select = true,
    update_when_errors = true,
    float = {
      max_height = 500,
      min_height = 4,
    },
    filter_kind = {
      "Class",
      "Constructor",
      "Enum",
      "Function",
      "Interface",
      "Method",
      "Struct",
    },
    icons = {
      Class = "",
      ClassCollapsed = "",
      Function = "",
      Constant = "",
      Collapsed = "▶",
    },
  })

Screenshots
See above.
Additional context
I will add some debug logs and attempt to figure out what the arguments that it is passing to open the floating window are, versus the actual size of the window itself.

@stevearc as noted above, I will debug a bit later and try to add more information. Just reporting for now before I forget; followup will be in a few hours after work.

Should be fixed now. I think it was just a simple error where a divide-by-2 led us to passing in a float to an API that only takes ints.

Awesome, will verify in a bit. Thanks.

Works for me, thanks for the fix.


e2e limits_file_watcher_on_docker

What is this test trying to assert? That we can observe filesystem changes when running within a docker container?

Yes,
Limitador has some coding regarding watching files in dockerized envs https://github.com/Kuadrant/limitador/blob/main/limitador-server/src/main.rs#L268-L289
This e2e test makes sure it works and nothing broke it.


Query series doesn't work

I'm trying to create dashboard from scratch but it seems automatic series search is not working when I'm writting a Series name on it, it doesn't refresh with existent series:

In grafana 2.6 and influxdb 0.8 datasource it works OK:

Same behaviour with latest Grafana version (3.0.2). Also, I cannot use any aggregation clause in query editor

See pull request #8 , Series search is working now.


Passing self.pane.get_path() as argument should be changed

The little plugin did not work for me because self.pane.get_path() returns a string that has a scheme e.g. "file://" at the beginning.
Simple fix:
scheme, path = splitscheme(self.pane.get_path())
subprocess.call(r'C:\Program Files\Git\git-bash.exe --cd="{cd}"'.format(cd=path))

Thanks, done


live configuration

Might be interesting to have a link on each page in the footer to allow the user to configure the proxy

and if they provide a certificate, it can even be on a per user or remembered as a site preference


Docker error configuration with own images (or how to configure with cap'n image)

I'm trying to configure captainhook to run inside my docker container with my custom docker image with PHP 7.2
# run inside my container
cd /var/ww/html/project && vendor/bin/captainhook install -f --container <my_container> -r docker

( /var/www/html/project   is a docker shared folder with my git project)
If I check the git hooks configurations I found this (example)
FILE: .git/hooks/commit-msg
#!/usr/bin/env bash
docker exec <my_container> ./ndor/bin/captainhook-run commit-msg "$@"%

And the problem seems in this file:  src/Hook/Template/Builder.php because the "vendor path configuration" is based on captainhook docker images.
Question: how do you configure captainhook with your images?

Also, the captainhook-run is forced with relative path in docker container src/Hook/Template/Docker.php
return '#!/usr/bin/env bash' . PHP_EOL .
            'docker exec ' . $this->container . ' ./' . $this->binaryPath . ' ' . $hook . ' "$@"';

because we have ./ before the binaryPath
For me it's ok, just be sure that we have to configure with cap'n docker images and not with other.

Hi, thanks for the nice piece of software.
The issue here is pretty real and I can see that it's caused by the improper use of the ltrim() function. The method in question is CaptainHook\App\Hook\Template::build()
    public static function build(InputInterface $input, Config $config, Repository $repository): Template     {         ...             $cwd = getcwd();             $repoPath   = ltrim((string) realpath($repository->getRoot()), $cwd . DIRECTORY_SEPARATOR);             $vendorPath = ltrim((string) realpath(getcwd() . '/vendor'), $cwd . DIRECTORY_SEPARATOR);             return new Docker(                 $repoPath,                 $vendorPath,                 IOUtil::argToString($input->getOption('container'))             );         }
In the example provided by @giuseppemorelli ltrim will be called on the following strings:
$vendorPath = ltrim("/var/ww/html/project/vendor", "/var/ww/html/project/");
and this will result in a string ndor. But how come? The answer is on https://www.php.net/manual/en/function.ltrim.php
When you specify a charachter mask to ltrim, the function will start testing charachters one by one from the left side of the string with the charachter mask. If it finds a match it removes the charachter from the string, if the charachter is not present in the charachter mask the function stops and returns the trimmed string.
In our case /var/ww/html/project/ is removed from the string character by character, the next is v from vendor, and it is present in the character mask so it gets removed too, same goes for the e. The next character n is not found in the mask, so the trimmed string ndor is returned.
I would propose to replace the ltrim() function with a method simillar to this one:
`
private function removeFromLeft(string $string, string $prefix): string
{
if (substr($string, 0, strlen($prefix)) == $prefix) {
$string = (string) substr($string, strlen($prefix));
}
return $string;

}
I wanted to submit a PR, but couldn't find contribution instructions, also a quick grep revealed usage of ltrim() in two other files:
./src/Hook/Template/Docker.php:        $this->binaryPath = ltrim(
./src/Storage/Util.php:        return explode(DIRECTORY_SEPARATOR, ltrim($path, DIRECTORY_SEPARATOR));
`
Docker can use the new method, it's extending Template, but Util will also require the method. An architecture decision has to be made - make the method static and put it in a separate class, or just duplicate.

Thanks for your feedback.
I think the Docker.php and Util.php usages of ltrim are fine since the character-list argument contains only one character.
But for the Template::build method it is completely wrong.
I took the liberty of using your code and putting it in the ´Storage\Utilclass and calling it inTemplate::build`.
I'm not at all a docker expert so I'm completely relying on people who know what they are doing ;)
What you are proposing makes sense to me, so currently it is used like this
captain hook install --mode=docker --container=FOO

and you would propose to use it like the following
captainhook install --mode=docker --command="docker exec FOO"

@icanhazstring what do you think about this?

Thanks, @sebastianfeldmann. You are spot on about the usage of ltrim().
And I can see that you've got absolutely right my docker idea ;)

I fixed the ltrim issue. I'm waiting for @icanhazstring s feedback. If he agrees I'll change the --container --command` stuff and release a new version and update the documentation.
@giuseppemorelli
If you want a quick fix in the meantime, "all" you have to do is fix the bash scripts in your local .git directory and put in the correct docker-exec command. I know it's a bit tedious to fix them manually but if you want to move forward quickly it's your best bet.
I'll keep this issue updated if I make any changes or new releases.

Hi everyone.
@dimitar-ivanov-tryzens you are absolutely right. When I implemented the docker support I didn't take into account other more custom container. Which your change would do, thanks!
So I am totally fine with the change so ppl can use the container they want and also change the entrypoint into their container (which is currenty fixed in the captainhook container).
So - go ahead @sebastianfeldmann 👍

If you want a quick fix in the meantime, "all" you have to do is fix the bash scripts in your local .git directory and put in the correct docker-exec command. I know it's a bit tedious to fix them manually but if you want to move forward quickly it's your best bet.
I'll keep this issue updated if I make any changes or new releases.

Thanks @sebastianfeldmann !
Is not a problem for me because I'm just testing this new feature :)
Thanks all for the support!

@giuseppemorelli @dimitar-ivanov-tryzens
I just release version 4.4.3 with the fix for the original ltrim issue.
Please be aware that the --container option is gone.
Now you have to use --run-mode=docker --run-exec="docker exec CONTAINER_NAME"
With the --run-exec option you can customize your docker execution command.
Just as suggested you can for example choose between:

"docker exec MY_CONTAINER_NAME"
"docker run --rm -v $(pwd):/var/www/html MY_IMAGE_NAME"
"docker-compose -f docker/docker-compose.yml run --rm MY_SERVICE_NAME"

I hope this helps and provides the flexibility you need.

Thanks, @sebastianfeldmann, speedy reaction! I'll give it a go tomorrow, and report back.

I have tested a few options, and they work as expected, good work! Thanks

Thanks for the feedback and your support


Subscribe to state changes outside of React

Hey @RichardLindhout! I am still very happy with this tiny but powerful library :)
I'd like to listen for state changes to trigger side effects (e.g. logging, tracking). For now I need to this in store.set itself, but I'd like to have this side effect free.
Maybe something along those lines:
const unsubscribe = myRidgeStore.subscribe((prevState, newState) => {
  // side effects here
})

Unfortunately onSet doesn't suffice as it happens after the state already has changed, I would also be fine with another option at store creation.
But in my opinion the approach I suggested is a little bit more approachable.
Thanks :)

I think your approach is nice. Can be added fairly easily I think

Will try to add within two weeks

Let me know if I can help you in any way :)

Let me know if I can help you in any way :)

I forgot this, I think it would be great but maybe the newest first since you don't always need the previous one
myRidgeStore.subscribe((new) => {}
myRidgeStore.subscribe((new, old) => {}

I forgot this, I think it would be great but maybe the newest first since you don't always need the previous one
myRidgeStore.subscribe((new) => {}
myRidgeStore.subscribe((new, old) => {}

const unsubscribe = myRidgeStore.subscribe((new) => {}
unsubscribe()

const unsubscribe = myRidgeStore.subscribe((new) => {}
unsubscribe()

I forgot this, I think it would be great but maybe the newest first since you don't always need the previous one

Totally makes sense! Also, the unsubscribe part looks good to me

I forgot this, I think it would be great but maybe the newest first since you don't always need the previous one

Totally makes sense! Also, the unsubscribe part looks good to me

Hey dan-lee would this also be fine?
onSet: (newState, prevState) => {

    },
    ```

    Because it will be more difficult than I though to support this new feature without increasing the bundle and small bundle is one the selling points

Hey dan-lee would this also be fine?
onSet: (newState, prevState) => {

    },
    ```

    Because it will be more difficult than I though to support this new feature without increasing the bundle and small bundle is one the selling points

Yeah, this could work, but unfortunately wouldn't be very helpful as the side effects could not be implemented separately.
We've worked around by implementing subscribe to the ridge state with a Proxy object and nanoevents:
import { newRidgeState, StateWithValue } from 'react-ridge-state'
import { createNanoEvents } from 'nanoevents'

type Subscriber<T> = (data: { newState: T }) => void

export interface SubscribeState<T> extends StateWithValue<T> {
  subscribe: (subscriber: Subscriber<T>) => void
}

export const createState = <T>(initialValue: T) => {
  const events = createNanoEvents<{
    CHANGE: Subscriber<T>
  }>()

  const ridgeState = newRidgeState<T>(initialValue, {
    onSet: (newState) => {
      events.emit('CHANGE', { newState })
    },
  })

  return new Proxy<typeof ridgeState>(ridgeState, {
    get: (target, prop) => {
      if (prop === 'subscribe') {
        return (sub: Subscriber<T>) => {
          return events.on('CHANGE', sub)
        }
      }

      return Reflect.get(target, prop)
    },
  }) as SubscribeState<T>
}


Extra click needed to start editing MDX field

Description
When clicking into an MDX field (from another textarea field), I need to click into the MDX editor twice
https://www.loom.com/share/e549eb061b36499a9609487aa7a36ad1
Steps to reproduce

Create a local copy of the tina cloud starter,
Go to http://localhost:3000/posts/voteForPedro
Click between "exerpt" & "body" fields

Expected result
Should be able to start editing immediately
Environment
Tinacms Package Versions
├──<EMAIL_ADDRESS>├──<EMAIL_ADDRESS>├──<EMAIL_ADDRESS>├──<EMAIL_ADDRESS>

I noticed in your loom that you try to click in the field, i find attempting to tab between certain fields doesn't work (might be related)


"Meet the Composable Architecture" tutorial

We want to start writing more tutorials for the library, especially for the new navigation tools coming, but to get us started let's get a basic "Essentials" tutorial in place. It walks through the basics of creating a TCA feature, layering on side effects, and writing tests.
I think it's pretty hard to review this PR without running it in Xcode/DocC.

This is fantastic. I've been learning by working through the case studies, but this looks a lot better.


Prepare for new release of Bitbucket

Workflow links: https://github.com/atlassian-labs/atlassian-slack-integration-server/actions/runs/258701120, https://github.com/atlassian-labs/atlassian-slack-integration-server/actions/runs/258701433.

Implemented in #50.


Dom diff on dynamic segment change is problematic

I've been having a world of trouble maintaining correct state after modifying the dynamic segment of a component that has children with state. A good example is an edit page posts/123/edit which renders Post, which in turn renders PostForm. The problem arrises from the nested components not mounting as per usual when the dynamic segment is changed on the URL, and instead relying on componentWillReceiveProps at the parent level. This results in the parent component content changing but not its children, when changing the address to posts/124/edit.
I could be doing something horribly wrong, but as far as I know I'm not engaging in any bizarro component composition patterns. Would it be possible to provide a global off switch for this that can be passed to Router.run that would perform a normal transition?
Thanks.

What kind of issue do you have? You can give explicit key to child stateful component, based on current props. Or you can implement componentWillReceiveProps in child components and reset state there when post ID changes.

I am using keys but the problem persists. I'll try to get an example up this afternoon, baby naps willing. :) But your comment on implementing componentWillReceiveProps on child components is a good one, because I feel that's where another issue with this implementation lies: every component has to do double duty on setting up state depending on how it was mounted, normally or via a segment change. I wonder if the optimization is worth it, and that's why I'd like to be able to disable it altogether.

You can add key to RouteHandler in root route handler. See example here: https://github.com/rackt/react-router/blob/master/UPGRADE_GUIDE.md (find "addHandlerKey" on page).

The other thing I'll point out is that the behaviour is inconsistent on some of my pages. For several URL changes in the edit example, the form component will re-render correctly, then it'll just stop.

It's hard to say what the issue is without playing with your code. Can you reproduce it on RR examples in the repo?

Will attempt to do so later this aft. In the interim, your suggestion worked! Everything just mounts now. Is this a sanctioned technique? I ask because I didn't see it anywhere in the doc or API. Cheers.

The link above is from the docs (Upgrade Guide, to be specific).

Cool, I'll submit a PR to add it to the overview doc where it talks about dynamic segments.

Please do. Thanks!

PR submitted. I'll still submit an example for the original issue.

Okay here's the gist: https://gist.github.com/uberllama/7226f8e0ea3800a1f517
Try navigating between edit pages by changing the id in the address bar (1,2, or 3). You will see that the post title changes, but the form state does not. There's nothing out of the react norm here as far as state handling goes.

I think the problem is your Input retaining state. It only reads props.value once, at the time of the mount, but disregards any changes to it and uses its own local state instead.
Adding
        componentWillReceiveProps: function(nextProps) {
          if (nextProps.value !== this.state.value) {
            this.setState({ value: this.props.value })
          }
        },

to Input helps but it's more of a workaround. Instead, you should remove local state from Input, add onChange to it and update post in parent component, so new data flows down to the input. This way, when post is replaced by another post, data will also flow down.

I'll close this out but feel free to reopen if I missed something.

Again though, I don't think this is a realistic proposition (no pun intended). You're saying that in order to use react-router in its default behaviour, every component must act on componentWillReceiveProps for state handling, in the event that its included by another component that's subject to dynamic segment switching.

Further to my last comment, I would argue that the safer default option for react-router would be to re-mount by default, and allow opting into dom diffing when a dynamic segment changes. This would mean less code overhead and tricky bugs.

cc @ryanflorence @mjackson

Let's reopen this and wait for owners to say their word! On one hand, I agree it can sometimes be problematic, on the other hand, I don't feel that router should behave differently than other React components by default.

Thanks Dan, I certainly don't want to be pushy. :) Just presenting my experiences.

After further reflection, I'm going to close this myself. :)

You probably realized this already but blowing the state away can be just as unexpected as keeping it. For example, you don't want to re-mount a seach page on each keypress. Same goes for tabbed pages.


[User study] Go through feedback

Go back to Mid-project review feedback if relevant and go through the new user study feedback.

Also document the changes made


Destructured Parameters' Default Values Aren't Type Checked

/**
 * @param {{x: number}=} param1
 */
function foo({x = "not a number"} = {}) { // passes
  alert(x);
}

foo(); // passes

foo({x: "also not a number"}); // doesn't pass

It would seem that when you use destructured paramaters with a default value that contradicts the type of that parameter, the compiler doesn't complain when it should.

I would imagine at best, the function's definition would produce a warning, at at least the call that invokes the function with the mis-typed default parameter.

@MatrixFrog would know more about plans for typechecking ES6.  Right now, it happens after transpilation, which transforms the code to
/**
 @param {{x:number}=} param1
 */
function foo(param1) {
  var $jscomp$destructuring$var0 = param1 === undefined ? {} : param1;
  var x = $jscomp$destructuring$var0.x === undefined ? "not a number" : $jscomp$destructuring$var0.x;
  alert(x);
}
foo();
foo({x:"also not a number"});

It's not obvious from the output (even with preserve type annotations turned on) whether the $jscomp$destructuring$var0 is typed or not.  If it were given the same type as the parameter then I would expect a type error.  If it's just left to infer the type, then it's clear why there's no error for this.

As I said on the other discussion about this, we should probably put a type annotation on x (and maybe on $jscomp$destructuring$var0 too). If someone wanted to do this as a 20% contribution that would be very appreciated. Otherwise I can probably do it sometime in the next week or so.

This is fixed now, I think since v20181028.
The compiler warns
input0:4: WARNING - default value has wrong type
found   : string
required: number
function foo({x = "not a number"} = {}) { // passes
              ^^^^^^^^^^^^^^^^^^

in the original example.


Convert LoadManager to use std::thread (RIPD-236)

Switching LoadManagerImp from using beast::Thread to std::thread.
Reviewers: @vinniefalco, @seelabs.

@seelabs I believe I've addressed the destructor issue that you pointed out.
I guess the main question I can see remaining is the responsiveness if the destructor runs before isStopping() starts returning true.  With the current implementation there will be between 1 and 2 seconds of latency between setting mStop and when the thread exist.  I could reduce that to between 0 and 1 seconds by reading mStop in a lock at the bottom of run()'s while loop.  I wasn't convinced the reduced latency in an error case was worth the added complexity.  But I can change that if you think it's worthwhile.  Thanks for your thoughts.

:+1: (I agree that added complexity to bring down latency in an error case isn't worth it).

I agree that added complexity to bring down latency in an error case isn't worth it.

Squashed and rebased to 0.29.1-b10.

Rebased to sit on top of pull request #1289.  getApp() calls removed.

Only the top-most commit is relevant.

Rebased to 0.30.0-b1.

Current coverage is 49.18%

Merging #1281 into develop will decrease coverage by -0.01% as of 114b226

@@            develop   #1281   diff @@
=======================================
  Files           958     958
  Stmts         65620   65638    +18
  Branches          0       0
  Methods           0       0
=======================================
+ Hit           32280   32284     +4
  Partial           0       0
- Missed        33340   33354    +14

Review entire Coverage Diff as of 114b226

Powered by Codecov. Updated on successful CI builds.

Can we please devirtualize LoadManager in a commit marked FOLD?

Rebased to 0.30.1-b1.  Added fold that de-virtualizes LoadManger.  Renamed member variables to use trailing underscore.

:+1:

Merged as caa4ed31de27fed7d2dd720fac6e5f5ce33bf45d.


Memory leak when building cpp using optimization (O3)

When the -O3 flag is set in the .bazelrc, a memory leak occures in several tests.
.bazelrc
test --test_output=errors --action_env="GTEST_COLOR=1"

# Force bazel output to use colors (good for jenkins) and print useful errors.
common --color=yes

build --cxxopt='-std=c++14'

A memory leak solver PR is here #101

Fixed in #108.


please migrate to the new Fedora translation platform

Hello, the Fedora project migrates its translation platform to Weblate [1].
This tool directly interact with your git repository, and requires us to know:

[mandatory] which branch is your development branch?
[mandatory] have you merged latest translation from Zanata and locked the project?
[info] Weblate will handle updates when pot file changes, don't edit po files for this [2]
[optional] what is the license of translation? (please use a code from https://spdx.org/licenses/)
[optional] do you have any announcement/warning you would like to display to the translators? (it will be displayed in Weblate)
[optional] do you need us to activate any specific checks? (this is a setting per component [3])
[optional] do you need us to automatically detect new translation files? (typical usecase: website translation with one translation file per page)

Please note:

For github and gitlab hosted projects, Weblate open pull request. For other git hosting, you'll have to add a key to allow commits.
In Weblate's vocable, one project is a group of component. Each component is a translation file. You can have many projects or many components or both.
You can change your mind over time, just reach<EMAIL_ADDRESS>
[1] https://communityblog.fedoraproject.org/fedora-localization-platform-migrates-to-weblate/
[2] https://docs.weblate.org/en/latest/admin/continuous.html#avoiding-merge-conflicts
[3] https://docs.weblate.org/en/latest/user/checks.html#translation-checks

kind reminder, Zanata removal is in a few weeks, https://fedoraproject.org/wiki/Changes/Zanata_removal


Add possibility to change Language on the fly

Same way as iOS does.

https://developer.android.com/about/versions/13/features/app-languages

QA passed


Black font on black background when you run Try Haxe locally

It fixes this issue :

Maybe it would be better to just add a CSS?

I'm on it

Thanks !


How do we deal with URL's that aren't working temporarily?

Tests may fail due to a valid URL that isn't available. This can be confusing if someone is trying to test out a code change. Can a way be designed that enables datasets to be skipped in testing?

Current iteration for handling this completed in issue beb9e513ae4b0f62cfe47feab4ec8bd8c6b93f74


improve the performance of fs.Open() by unzipping in fs.New() and simplifying http.File wrapper

Please consider reviewing and merging https://github.com/rakyll/statik/pull/22 before this PR. I'd like to rebase this branch after that PR is merged to take advantage of the additional test coverage.
Benchmark results (from benchmark in https://github.com/rakyll/statik/pull/22):
master:
$ go test -v -bench=. -run=^$ github.com/rakyll/statik/fs
BenchmarkOpen-4   	  500000	      2398 ns/op
PASS
ok  	github.com/rakyll/statik/fs	1.237s

this PR:
$ go test -v -bench=. -run=^$ github.com/rakyll/statik/fs
BenchmarkOpen-4   	10000000	       137 ns/op
PASS
ok  	github.com/rakyll/statik/fs	1.526s

@rakyll I have read and signed a Google CLA.

Thanks!


Guidance on Error response

Hi,
What I used to do for error responses is use the Microsoft.AspNetCore.Mvc.ProblemDetails standard class (https://tools.ietf.org/html/rfc7807) to wrap the errors.
I understand that there isn't any hook at the moment in FastEndpoints itself to  change the style of error responses. So best thing to do is use the standard middleware to "convert" the errors then? Or would it be a future feature to have a kind of global hook to catch the error responses? The IPostProcessor or AfterHandle are not called if you end the request in the PreProcess for example. So it seems that the standard middleware is the only option?

check out v2.21.0-beta4
config has now been moved to it's own class with the ability to specify a func for building the error response. that should do the trick. you can return any serializable object from the func and it will be sent instead of the default error response.
https://github.com/dj-nitehawk/FastEndpoints/blob/983eb4328f16c8c89b7fa16a7c1b6369a7997a0e/Web/Program.cs#L24-L29

Very cool! Thanks.
Not sure if I am asking to much :-) but would it also be possible to change the content type in such cases as well?
According to the referred rfc, you should return context.Response.ContentType = "application/problem+json";
If it's too much work to change all of that, it's ok :-)

fixed in beta6 release.

Not sure if I am asking to much

definitely not. these are great improvements that i've overlooked ;-)


How to use "middleware" to detect session expiration at client side?

I try to follow the documentation about  to use the "middleware" to detect the session expiration (link). But I don't understand how this "client" will connect and get informed about the expiration. I assume you need to call a "subscribe" after the "client" has been setup? Or does the "client" automatically subscribe somehow?
import { ConnectClient, InvalidSessionMiddleware } from '@hilla/frontend';
const client = new ConnectClient({
  prefix: 'connect',
  middlewares: [
    new InvalidSessionMiddleware(async () => {
    console.log("Session Expired !");
    ...
    }),
  ],
});

// what to do with the client ???
client.subscribe( ??? )

Ok, I found the documentation that you might have to modify the existing generated client here.  However it looks like that the callback with InvalidSessionMiddleware only get called after the endpoint get called.
Is there a way to ensure that fist the session expiration get checked before the final endpoint get invoked?
import { InvalidSessionMiddleware, LoginResult } from '@hilla/frontend';
import client from 'Frontend/generated/connect-client.default';
if (client.middlewares) {
client.middlewares.push(
	  new InvalidSessionMiddleware(async () => {
	  console.log("Session Expired!");
	  await userStore.logout();
	  return {} as LoginResult;
    }),
	);
}

// calls implicit the generated client with the configured middleware
let users = await BackendUserEndpoint.getAllUsers();


Breadcrumbs location of topology is too close to the new left side navigation

the problem is less severe in other screens (providers/entities) because there are toolbars/filters there.

Changing the padding-left of .breadcrumbs css class to 5px (from 0px) made it much better, however it looks like this setting is coming from an external css and it will also influence all breadcrumbs, not only the one in topology.
@epwinchell please advise.
@miq-bot add_label ui, topology

cc @martinpovolny

@abonas I'll take care of it.

@epwinchell thanks! please tag me so I can see how it was solved.

@miq-bot assign epwinchell


CI for scale-ci-deploy

/rerun aws

!!! Couldn't read commit file !!!

/rerun aws

Results for scale-ci-deploy

Platform
Result
Runtime

aws
PASS
00:50:34

Results for scale-ci-deploy

Platform
Result
Runtime

aws
PASS
00:50:42

Results for scale-ci-deploy

Platform
Result
Runtime

aws
PASS
00:47:08

/rerun azure

Results for scale-ci-deploy

Platform
Result
Runtime

/rerun azure

Results for scale-ci-deploy

Platform
Result
Runtime

/rerun gcp

Results for scale-ci-deploy

Platform
Result
Runtime

gcp
PASS
00:35:43

/rerun all

Results for scale-ci-deploy

Platform
Result
Runtime

aws
PASS
00:43:30

/rerun azure

Results for scale-ci-deploy

Platform
Result
Runtime

azure
PASS
00:53:09

/rerun all

Results for scale-ci-deploy

Platform
Result
Runtime

/rerun gcp

Results for scale-ci-deploy

Platform
Result
Runtime

gcp
PASS
00:31:37

/rerun gcp

/rerun azure

Results for scale-ci-deploy

Platform
Result
Runtime

azure
PASS
00:00:00

/rerun aws

Results for scale-ci-deploy

Platform
Result
Runtime

aws
PASS
00:44:17

/rerun gcp

Results for scale-ci-deploy

Platform
Result
Runtime

gcp
PASS
00:35:41

/rerun gcp

Results for scale-ci-deploy

Platform
Result
Runtime

gcp
PASS
00:00:00

Destroy gcp cluster
PASS
00:03:41

/rerun all

Results for scale-ci-deploy

Platform
Result
Runtime

/rerun aws

Results for scale-ci-deploy

Platform
Result
Runtime

/rerun azure

Results for scale-ci-deploy

Platform
Result
Runtime

/rerun gcp

Results for scale-ci-deploy

Platform
Result
Runtime

/rerun azure

Results for scale-ci-deploy

Platform
Result
Runtime

/rerun aws

Results for scale-ci-deploy

Platform
Result
Runtime

/rerun aws

Results for scale-ci-deploy

Platform
Result
Runtime

aws
PASS
00:42:34

Destroy aws cluster
PASS
00:03:48

/rerun azure

Results for scale-ci-deploy

Platform
Result
Runtime

/rerun azure

Results for scale-ci-deploy

Platform
Result
Runtime

/rerun all

Results for scale-ci-deploy

Platform
Result
Runtime

aws
PASS
00:41:08

Destroy aws cluster
PASS
00:09:50

/rerun azure

Results for scale-ci-deploy

Platform
Result
Runtime

azure
PASS
00:52:13

Destroy azure cluster
PASS
00:07:08

/rerun gcp

Results for scale-ci-deploy

Platform
Result
Runtime

gcp
PASS
00:39:41

Destroy gcp cluster
PASS
00:03:29

/rerun all

Results for scale-ci-deploy

Platform
Result
Runtime

aws
PASS
00:43:21

Destroy aws cluster
PASS
00:04:21

/rerun aws

Results for scale-ci-deploy

Platform
Result
Runtime

aws
PASS
00:46:19

Destroy aws cluster
PASS
00:15:41

/rerun all

Results for scale-ci-deploy

Platform
Result
Runtime

/rerun all

Results for scale-ci-deploy

Platform
Result
Runtime

/rerun all

Results for scale-ci-deploy

Platform
Result
Runtime

aws
PASS
00:38:36

Destroy aws cluster
PASS
00:04:22

azure
PASS
01:03:09

Destroy azure cluster
PASS
00:05:46

gcp
PASS
00:29:32

Destroy gcp cluster
PASS
00:02:38

@amitsagtani97 have made the requested changes , created a common_vars.sh file in /properties_files folder

/rerun azure

Results for scale-ci-deploy

Platform
Result
Runtime

azure
PASS
00:48:33

Destroy azure cluster
PASS
00:06:58

/rerun aws

Results for scale-ci-deploy

Platform
Result
Runtime

aws
PASS
00:43:42

Destroy aws cluster
PASS
00:03:56


Credentials List Status

Sent & claimed make sense. What does draft mean? Is that because the batch is still in draft? If so, should we not include them in the credentials list? Should the credentials list be those that have been sent, claimed, or revoked?

@kayaelle Good questions we should discuss on the next call. Currently a credential record in DRAFT mode corresponds - as you stated - that the batch the record is associated with itself is in draft.


Support embedding a 3.7 broker

Type of change

Enhancement / new feature

Description
Why:
In Kafka 3.7 the MetaProperties has changed package, so the extension fails with an exception at Runtime when it tries to invoke buildMetadataProperties if we have the 3.7 kafka server on the classpath.
This change will be required when we upgrade the extension to compile against 3.7 to support backwards compatibility with Kafka 3.6
Additional Context
Strimzi are preparing to use Kafka 3.7 and this breaks their tests at runtime as we can no longer start up embedded brokers.
Checklist
Please go through this checklist and make sure all applicable tasks have been done

[ ] Write tests
[ ] Make sure all tests pass
[ ] Update documentation
[ ] Reference relevant issue(s) and close them after merging
[ ] Update CHANGELOG.md

Have tested against the strimzi 3.7 PR branch by running the topic-operator tests against a locally built extension snapshot.
[INFO] Results:
[INFO]
[WARNING] Tests run: 134, Failures: 0, Errors: 0, Skipped: 1
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  50.779 s
[INFO] Finished at: 2024-01-12T13:39:54+13:00
[INFO] ------------------------------------------------------------------------