chore: update CredentialProvider

Added StringMomentoTokenProvider
Added static functions, fromEnvironmentVariable and fromString
Added some test to test out the above

Closes #100

Looks good. Can you document the StringMomentoProvider class and fromEnvironmentVariable method as well?

This looks good but there is a lot of duplicated code between the two providers. In other SDKs we had the EnvMomentoTokenProvider inherit from StringMomentoTokenProvider since the only extra thing it does is read a stering from an environment variable. I think doing the same here would simplify and make this more maintainable. The node SDK is a good model for this pattern.

This looks good but there is a lot of duplicated code between the two providers. In other SDKs we had the EnvMomentoTokenProvider inherit from StringMomentoTokenProvider since the only extra thing it does is read a stering from an environment variable. I think doing the same here would simplify and make this more maintainable. The node SDK is a good model for this pattern.

@pgautier404
I wanted to discuss this with you, so sounds good!

@pgautier404 @cprice404
Thank you for the feedback!
After talking to Pete, it makes sense to keep ICredentialProvider and implement it in CredentialProvider to add flexibility to our interface.
I added back ICredentialProvider and updated CredentialProvier accordingly.
Also updated the examples so that we use CacheClient and CredentialProvider::fromEnvironmentVariable.
Ah, also updated CredentialProvider return type to ICredentialProvier type.


No aarch64 support

OS Platform and Distribution
Ubuntu
Compiler version
No response
Programming Language and version
python 3.10
Installed using virtualenv? pip? Conda?(if python)
pip
MediaPipe version
No response
Bazel version
No response
XCode and Tulsi versions (if iOS)
No response
Android SDK and NDK versions (if android)
No response
Android AAR (if android)
None
OpenCV version (if running on desktop)
No response
Describe the problem
pip3 install mediapipe fails because there is no aarch64 wheel file available

Complete Logs
RUN pip3 install matplotlib mediapipe:
|  #55 0.892 Collecting matplotlib
|  #55 0.987   Downloading matplotlib-3.7.1-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (11.3 MB)
|  #55 1.126      ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 11.3/11.3 MB 96.9 MB/s eta 0:00:00
|  #55 1.197 ERROR: Could not find a version that satisfies the requirement mediapipe (from versions: none)
|  #55 1.197 ERROR: No matching distribution found for mediapipe

Hello @AustinDeric,
Could you pease confirm that OS you are trying to build the MediaPipe? Thank you

@AustinDeric,
For now, We do not have the official AArch64 wheels in Python. Please be assured, We will be supporting the Raspberry Pi And task is in already in roadmap. However, We can not provide any timeline to be available in the documentation. Thank you


Type conversion issues

long[] numbers;
numbers = [999,95,889];
Error - int[] cannot be converted to long[]

double[] numbers;
numbers = [99.99,4.5,23.56];
Error - float[] cannot be converted to double[]

long and double types are no longer exists. Hence closing the issue.


Syntax highlighting broken for Markdown mode

Syntax highlighting does not work Markdown mode
It only works in the blue theme.

Exactly the same here!


Setup flake8-annotations-complexity plugin.

https://github.com/best-doctor/flake8-annotations-complexity

Superseded by #627


npm install npm-run-all --save-dev Corrupted issue

Is this from me, Or is this in all npm install issue ?

Looks like a npm's problem.
npm-run-all doesn't depend on hoek both directly and indirectly, but the error message is about hoek package.


Upgrade org.apache.maven.plugins:maven-release-plugin 3.0.0 -> 3.0.1

This PR contains the following updates:

Package
Type
Update
Change

org.apache.maven.plugins:maven-release-plugin
build
patch
3.0.0 -> 3.0.1

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

Suggested commit message:
Upgrade maven-release-plugin 3.0.0 -> 3.0.1

See:
- https://github.com/apache/maven-release/releases/tag/maven-release-3.0.1
- https://github.com/apache/maven-release/compare/maven-release-3.0.0...maven-release-3.0.1


[CPP-80] Make query diagnostic (and associated qhelp) about many fiel…

…ds in aggregates a bit more friendly.
The query message and qhelp are slightly reworded:
ql:  "struct aa contains 28 fields, which is too many" -->
"struct 'aa' contains 28 fields; we recommend refactoring to 15 fields or fewer"
qhelp "...is a sign that the struct lacks cohesion (i.e., serves a single purpose)" ==>
"...is a sign that the struct may lack cohesion (i.e., serve a single purpose)"
Since this is my first pull request, any guidance on generating future pull requests will be appreciated.

 Thank you for your submission, we really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.You have signed the CLA already but the status is still pending? Let us recheck it.


curl: enable ca-bundle if activated http3 protocol

Description of changes
Enable option --with-ca-bundle if activated http3 protocol.
Fallback is not supported by HTTP3, see - https://github.com/curl/curl/issues/8696
Needed add test curl with http3 protocol?
@ajs124
Things done

Built on platform(s)

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

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

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

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

[ ] (Package updates) Added a release notes entry if the change is major or breaking
[ ] (Module updates) Added a release notes entry if the change is significant
[ ] (Module addition) Added a release notes entry if adding a new NixOS module
[ ] (Release notes changes) Ran nixos/doc/manual/md-to-db.sh to update generated release notes

[ ] Fits CONTRIBUTING.md.

Does this need to go to staging? Or rather, does this rely on changes already in staging? Because it seems like this only affects curlHTTP3, so it could probably just go to master.

Does this need to go to staging? Or rather, does this rely on changes already in staging? Because it seems like this only affects curlHTTP3, so it could probably just go to master.

Changed to master branch.


Imap-backup

Unable to get folders list.  it doesn't work with godaddy accounts.  It can't get the folders list.

Hello.
Unfortunately, I don't have configuration info for GoDaddy.
To get this working, you'll need to set the 'server' entry for GoDaddy's email servers in imap-backup setup. Once you've done that, try 'test connection'.
If that works, great - send me the server entry and I will add it to the list of known configurations.
If it doesn't work, you'll need to edit ~/.imap-backup/config.json and set server_options, to indicate things like the port that GoDaddy expects.

{
"accounts": [
{
"username"<EMAIL_ADDRESS>"password": "xxxxxxxxxx",
"local_path": "/Users/xxxxxx/.imap-backup/xxx_xxx.com",
"folders": [
{"name": "inbox"},
{"name": "INBOX"},
{"name": "Sent Items"}
],
"server": "imap.secureserver.net"
}
],
"debug": true
}

You don't do anything to throttle do you?  I am noticing it takes exactly 36 seconds per email message to download.  Godaddy swears up and down that they are  not throttling on their end, in spite of the fact that traceroutes get hung up inside their domain.

No, imap-backup does not do any throttling.
If it's downloading with the config you posted, then GoDaddy is using port 993 over SSL. The problem is that GD handles a myriad of domains, so I can't really add auto setup.

I'll close this issue as it looks like the connection is now working.

Is there any way to get increased logging to detail the timing of the messaging going back and forth?  The logging provided is not as informative as it could be.

Currently, with debug logging enabled, you get a timestamp when each message download completes along with the number of bytes in the message body. I think that should be enough for most people's use.
If you need more detailed information, I think this could be dealt with in two ways:

you could use the existing version, but monitor the "shape" of network traffic via wireshark or other similar network analysis tools,
otherwise, I'm always willing to discuss pull requests :-)

Unfortunately my Ruby foo is not that good.  I would probably screw up your code base.


deeplexicon in NanoPreproessSimple

Hi,
I've been trying to use NanoPreprocessSimple since I had basecalled data already.
However, everytime I tried, I got an error saying " StreamExecutor device (0): ,
/usr/local/lib/python3.7/site-packages/pandas/compat/init.py:117: UserWarning: Could not import the lzma module. Your installed Python is incomplete. Attempting to use lzma compression will result in a RuntimeError."
By searching the problem, I found the people says this is the problem of pandas and downgrade version will work or
install "xz" will work. Both tried, but did not dissolve this situation.
More puzzling thing is deeplexicon itself works on my system (mac OS Catalina, python is from anaconda3).
So I am wondering what could be done.
If you could help me with, I greatly appreciate it.
Thank you so much...
yh

Hi, we recommend to use MoP with singularity or docker images for overcoming this kind of issues.

Hi,
thank you for your comment and recommendation! I am afraid this might be very basic question.
But I'm sorry that I am not familiar with MoP.
would you explain to me a bit more? I am using with docker for NanoPreprocessSimple.
Thank you so much.
yh

So you are using docker and get this kind of error? Can you write down the command line you are using for launching nanopreprocess, please?

command line is
"nextflow run nanopreprocess_s.nf -with-docker"
yh

Hi, it looks like in Mac you need to mount /Users directory in docker:
https://www.nextflow.io/docs/latest/docker.html#
You might want to try singularity too:
https://sylabs.io/singularity-desktop-macos/
L

Hi,
The link you provided is a bit old info and with current docker, /Users directory is automatically mounted.
But I realized that docker tries to search python library which doesn't exist. So I tried to solve this.
With my knowledge I couldn't fix this at this point.
I will keep trying and meantime, I downloaded singularity and tried with it, but again, I got an error.
That says,
For input string: ""
-- Check script 'nanopreprocess_s.nf' at line: 172 or see '.nextflow.log' file for more details
Could you help with this?
For your info, with docker "MultiFast5 files detected!" was printed correctly.
yh

Hi,
It might be solved even though this may not be ideal solution.
I struggled with docker, but I realized I have conda env that deeplexicon works.
So I wrote conda path to deeplexicon env into nextflow script.
It is still running, but at least start to process of demultiplexing.
Thank you so much for your help.
If you could find better solutions, I would be happy to try.
yh

Hi, in principle docker - singularity should be the best option but I did not test them in Mac OS. Have you tried singularity?

Dear @yasukoh I tested the pipeline on a Mac OSX. I had to do some small changes since Docker doesn't mount symbolic links. If you do a git pull it should work. Let me know, please

Hi, Thank so much for changes.
I downloaded again and tried. But I got the same error as before.
Is it possibly the problem of only my system??
yh

I don't get it. With Docker you should not see your local environment. So your python environment should be "hidden".  Can you please start from scratch and reinstall MoP and try again? The warning you described at the beginning are ok. Let me know.

Hmm. OK, I will uninstall all and re-install everything again.
Give me a bit of time. I will let you know.
Thank you so much for your help.

No, it didn't work.
I got the same error. I didn't copy all of error message before, so the following is the whole message of error.
With that, you might be able to point out something I missed.
Error executing process > 'demultiplexing_with_deeplexicon (deeplexicon-0)'
Caused by:
Process demultiplexing_with_deeplexicon (deeplexicon-0) terminated with an error exit status (137)
Command executed:
ln -s deeplexicon/* .
deeplexicon.py -f multi -p ./ -s 0.9 -m resnet20-final.h5  -b 4000 -v > 0_demux.tsv
Command exit status:
137
Command output:
(empty)
Command error:
2020-08-09 03:03:20.796665: I tensorflow/core/platform/cpu_feature_guard.cc:141] Your CPU supports instructions that this TensorFlow binary was not compiled to use: AVX2 FMA
2020-08-09 03:03:20.814887: I tensorflow/core/platform/profile_utils/cpu_utils.cc:94] CPU Frequency:<PHONE_NUMBER> Hz
2020-08-09 03:03:20.816158: I tensorflow/compiler/xla/service/service.cc:150] XLA service 0x5650c1f1d6f0 executing computations on platform Host. Devices:
2020-08-09 03:03:20.816373: I tensorflow/compiler/xla/service/service.cc:158]   StreamExecutor device (0): ,
/usr/local/lib/python3.7/site-packages/pandas/compat/init.py:117: UserWarning: Could not import the lzma module. Your installed Python is incomplete. Attempting to use lzma compression will result in a RuntimeError.
warnings.warn(msg)
Using TensorFlow backend.
info: Verbose mode active - dumping info to stderr
info: DeePlexiCon: 1.0.0
info: arg list: Namespace(batch_size=4000, config=None, form='multi', model='resnet20-final.h5', path='./', segment=None, squiggle=None, threshold=0.9, verbose=True, version=None)
info: Please install GPU version of TF
WARNING:tensorflow:From /usr/local/lib/python3.7/site-packages/tensorflow/python/framework/op_def_library.py:263: colocate_with (from tensorflow.python.framework.ops) is deprecated and will be removed in a future version.
Instructions for updating:
Colocations handled automatically by placer.
WARNING:tensorflow:From /usr/local/lib/python3.7/site-packages/tensorflow/python/ops/math_ops.py:3066: to_int32 (from tensorflow.python.ops.math_ops) is deprecated and will be removed in a future version.
Instructions for updating:
Use tf.cast instead.
.command.sh: line 3:     8 Killed                  deeplexicon.py -f multi -p ./ -s 0.9 -m resnet20-final.h5 -b 4000 -v > 0_demux.tsv
Work dir:
/Users/yh/master_of_pores/NanoPreprocessSimple/work/a4/66129c8d5866b413e9d39310e00854
Tip: you can try to figure out what's wrong by changing to the process work dir and showing the script file named .command.sh
Does this help?
I greatly appreciate your help.
yh

Ah ok, this looks more a problem with resources. Can you add -profile local and adapt the maximum memory to the one of your system?
The file to be changed is nextflow.global.config

Sorry, I should have copied all of the error log from the beginning.
Could I clarify what should I do?
I modified the part of memory size of local section in nextflow.global.config file to fit to my system.
local {
process {
executor = 'local'
cpus = 1
memory = '8GB'    -----  this number
and add to command line -profile local as
"/nextflow run nanopreprocess_s.nf -profile local -with-docker"
By changing these I still get the same error..
What do I still miss??

Definitely my mistake. I am sorry. I forgot to allocate more memory to docker itself.
Once I changed memory allocation of docker, it seems to start demultiplexing.
Thank you so much for your help.
yh

You are welcome!


Proposal notification

Desktop:

Mobile:

Will clear when user clicks 'Proposals' (stored in local storage)
"Non-core" proposals will only show a notification after being open for 30 minutes or longer
Fetches on load only (no polling)

30 minutes hardly give us any time to remove the proposal, I'd move that up to a couple of hours


Fix typo in database query by user id

The rateUser function establishes the targetUser of the rating based on the user sending it.
To do that it has to get both users involved in the trade and compare them against the id of the function caller.
A typo in the query to database caused that the requested users were always the buyers of the order.
Fixes #155

LGTM 🤖


How to enable cookies through nuxt middleware?

Due to the limitation of GDPR, cookies cannot be enabled for all users.
But I can know whether the user is allowed through other cookies
So I want to enable cookies dynamically, For example, nuxt middleware.
Is there any way?
Thanks

You can disable the cookie (detectBrowserLanguage.useCookie) but I'm not sure how this will affect the detectBrowserLanguage logic. Would need to check the code. You could potentially implement custom logic to store that cookie when needed.
That said, even with GDPR you should be able to treat this cookie as "essential" and not have to avoid setting it.

When the detectBrowserLanguage. useCookie is set to false, thesetLocaleCookie is invalid. Actively set i18n_ Redirected cookies and redirects do not work.

That said, even with GDPR you should be able to treat this cookie as "essential" and not have to avoid setting it.

Exactly. Functional cookies are exempted from needing to be disabled because of GDPR.

Yes, given the above, I don't see the need to do address this.


ci: fuzzers in the Github Actions CI.

issues #7
The changes:

Add fuzzing.yml ci file.
Change the diffutils dependency of the original fuzz module to diffutilslib.

There are still problems:

Although the CI is passing, it doesn't seem to be testing properly.
Noticed that both the Windows build and macOS before I forked didn't work.

Excellent, thanks!
It isn't perfect but a good start :)


Face encoding generated for my pet

I am trying to find face encodings for an area. For an image it is able to find face encodings that too for a dog facing backwards.

`
from deepface import DeepFace
#from deepface.basemodels import VGGFace, OpenFace, Facenet, FbDeepFace
from deepface.basemodels import Facenet
from deepface.commons import functions, realtime, distance as dst
model = Facenet.loadModel()
input_shape = (160,160)
model_name = 'Facenet'
distance_metric = 'cosine'
threshold = functions.findThreshold(model_name, distance_metric)
def get_face_encodings(file_name):
try:
img1 = functions.detectFace(file_name,input_shape)
img1_representation = model.predict(img1)[0,:]
print(img1_representation)
return img1_representation
except:
return []
face_encoding = get_face_encodings(file)
`
Try it yourself  , it sometimes find face encodings for me when I am facing against the camera

detectFace function will return exception if it cannot detect a face. So, you cannot apply deepface for those kind of tasks.

so I am assuming I cannot use this to detect face

BTW, you can pass enforce_detection argument to detectFace function. Its default value is True. If you set this to False, then it would not enforce you to detect face.

but this doesnt solve above problem

Can we open this issue and rather fix it.


Wilsonbekwame (volwassen) deelnemers

This question:
Wilsonbekwaamheid
Maakt jouw onderzoek gebruik van wilsonbekwame (volwassen) deelnemers?
...only pops up if you tick any of the age groups in the previous question ("Uit welke leeftijdscategorie(ën) bestaat je deelnemersgroep?"). I think this is a bug? The question should always be asked if an age group older than 15 years is ticked.
It should, btw, read: Maakt jouw onderzoek gebruik van wilsonbekwame volwassen deelnemers? (The extra info also mentions adults only).

Possible non-issue?

The question should always be asked if an age group older than 15 years is ticked.

I'm pretty sure this is the current behaviour. Needs clarification on what exactly should be changed.
However, the textual change can be added to 4.0

Currently this only pops up for the age group:

16-17
18-69
70+

Within the portal, we currently say 16 - 17 are adults. Is this not desired?


Support authentication for REST sources

Description of the new feature / enhancement
I would like to be able to authenticate access to REST sources.
As an enterprise standing up a private REST source I want to be able to authenticate users.
Related to:

microsoft/winget-cli-restsource/issues/100

There are several authentication mechanisms being considered:

#1919
#1339
Azure Active Directory (AAD) based authentication
AuthN / AuthZ

Note: We are working on anonymous access to the Microsoft Store source.

#1585

Proposed technical implementation details
No response

Related to:

https://github.com/microsoft/winget-cli-restsource/issues/100

Not sure if this is the right place to ask this but seeing that this Issue is the one I'm being referred to I wanted to ask if I could start working on this and create a pr once done?


Notifications: Error viewing notifications

Notice: Trying to get property of non-object in /home/ciboonex/public_html/trident/modules/base/profile/classes/BxBaseModProfilePrivacy.php on line 24
Notice: Trying to get property of non-object in /home/ciboonex/public_html/trident/modules/base/groups/classes/BxBaseModGroupsPrivacyNotifications.php on line 27
Fatal error: Call to a member function isAdmin() on a non-object in /home/ciboonex/public_html/trident/modules/base/groups/classes/BxBaseModGroupsPrivacyNotifications.php on line 27

First I thought it's only when you are visiting it as an account, instead of a profile.
But it the error appears everytime, as long as there is a notification for me.


DropDown frame is CGRectZero after calling show

Hi Kevin,
Thanks again for supporting this open source library. It's very well written in my opinion and I've had an easy time using it. I do have DropDown working successfully from Objective-C in one table view controller that is static-grouped and the first child of a navigation controller in a tabbar controller. Yesterday I attempted to add it a second view controller which is loaded dynamically and presented modally, which are the only differences that I can see between the uses of it.
- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath {
    SQFBFriendTableViewCell *cell = [self.tableView dequeueReusableCellWithIdentifier:[SQFBFriendTableViewCell reuseIdentifier]];
    ... // some switching to detect the correct section, but the routing is correct

    self.multiplePhoneNumbersMenu = [[DropDown alloc] init];
    self.multiplePhoneNumbersMenu.textFont = [UIFont gothamBookAtSize:16];
    self.multiplePhoneNumbersMenu.textColor = [UIColor squadColorGrey103];
    self.multiplePhoneNumbersMenu.anchorView = cell;

     // this offset is from my implementation in the other tableview controller, toggling it has no effect on the issue
    CGFloat offset = self.multiplePhoneNumbersMenu.anchorView.plainView.bounds.size.height;
    self.multiplePhoneNumbersMenu.bottomOffset = CGPointMake(0, offset);
    self.multiplePhoneNumbersMenu.topOffset = CGPointMake(0, -offset);

    self.multiplePhoneNumbersMenu.dataSource = @[ @"Hello world" ];
    @weakify(self);
    self.multiplePhoneNumbersMenu.selectionAction = ^(NSInteger index, NSString * _Nonnull item) {
        @strongify(self);
        ... // does stuff
    };

    [self.multiplePhoneNumbersMenu show];
    // breakpoint here po's the frame as 0,0,0,0. the cell selection is highlighted, but the DropDown never appears
}

po self.multiplePhoneNumbersMenu
<DropDown.DropDown: 0x158641170; frame = (0 0; 0 0); alpha = 0; animations = { opacity=<CABasicAnimation: 0x1581db490>; }; layer = <CALayer: 0x1585247d0>>

I feel like I'm possibly missing something basic, but the implementation is mostly parallel to the one in my other class is the working. Any insight that you can offer would be appreciated. Thanks again!
~Mark

Hello @markedwardmurray,
Thanks for using this library!

It's very well written in my opinion and I've had an easy time using it.

Stop flattering me 🤗
Could you show me the code for your drop down, please?
What's the anchorView you're using?
I have in the internal computeLayout function this line (719):
guard let window = UIWindow.visibleWindow() else { return (0, 0, 0, 0, 0, false, direction) }

where visibleWindow is implement this way:
static func visibleWindow() -> UIWindow? {
	var currentWindow = UIApplication.sharedApplication().keyWindow

	if currentWindow == nil {
		let frontToBackWindows = Array(UIApplication.sharedApplication().windows.reverse())

		for window in frontToBackWindows {
			if window.windowLevel == UIWindowLevelNormal {
				currentWindow = window
				break
			}
		}
	}

	return currentWindow
}

So maybe there's a problem there. Can you check it out?
Thanks!

It would appear that visibleWindow() is worked correctly:
// line 569
(lldb) po window
▿ Optional<UIWindow>
  - Some : <UIWindow: 0x14cd55820; frame = (0 0; 375 667); autoresize = W+H; gestureRecognizers = <NSArray: 0x14cd56b60>; layer = <UIWindowLayer: 0x14cd53690>>

// line 581
(lldb) po self.anchorView
▿ Optional<AnchorView>
  - Some : <SQFBFriendTableViewCell: 0x14d256c00; baseClass = UITableViewCell; frame = (0 56; 375 48); autoresize = W; layer = <CALayer: 0x14e7acb40>>

However, computeLayout() seems to get called a total of 4 times, with the first call failing to retrieve the window. I would assume this first time is the initialization call?

There is indeed several calls to computeLayout but there is always one just before showing the drop down. So this is the one that matters. (Not taking into account keyboard appearances and device rotations)
And what do you have for value in showfunction when you put breakpoints on line 761:
if !layout.canBeDisplayed {
	hide()
	return (layout.canBeDisplayed, layout.offscreenHeight)
}

and below, at line 780:
return (layout.canBeDisplayed, layout.offscreenHeight)

Mmm, yes. It trips on line 761 and calls the hide() on 762

I probably did something wrong. Using an alert controller action sheet for the time being instead

Hello @markedwardmurray!
I was thinking that maybe the problem comes from the anchorView that is a UITableViewCell. Because its frame origin is going to be relative to the table view and not the actual window.
Could you simply put a breakpoint on the return statement of the computeLayoutBottomDisplay function and check those values (just after calling show):

maxY
windowMaxY
offscreenHeight
self.tableHeight

Thanks a lot!

Thanks for staying engaged! I had to move on for the time being, however. I'll check out my old commit later on my own time, hopefully by the end of the week.

+1 I had this problem too, but with a UITextField instead. The first time calling -show, dropdown didn't appear but after that it works fine.
[DropDown startListeningToKeyboard];
[DropDown appearance].textFont = [UIFont systemFontOfSize:14];
_domainDropDown = [[DropDown alloc] init];
_domainDropDown.anchorView = _txtDomain;
_domainDropDown.dataSource = @[ kSkyDomainSuffix, kOrionDomainSuffix ];
weakify(self);
[_domainDropDown setSelectionAction:^(NSInteger index, NSString * _Nonnull item) {
    strongify(self);
    self.currentDomain = item;
    [(UIButton *)self.txtDomain.rightView setTitle:item forState:UIControlStateNormal];
}];

Also, if I set dropdown `anchorView` to textfield's `rightView`, it will never appear.

Having the same issue with a UITextField, but in my case it nevers shows. The canBeDisplayed property value is always false no matter what I try.

Hey @kientux, @mradzinski !
Thanks for using this library :)
Could you try what I suggested here
It would really help 👍

Because of this
DispatchQueue.main.async {
			//HACK: If not done in dispatch_async on main queue `setupUI` will have no effect
			self.updateConstraintsIfNeeded()
			self.setupUI()
		}

my dropdown.show() is not working.
As I debugged, I noticed that I am calling show, which then calls setShowedState, but a while after that setup is happening and calling setHiddentState.
So that I had to enclose my sropdown.show() into the same closure
DispatchQueue.main.async {} to make it work. However still things like offset aren't working properly.
Any ideas why the HACK has to be present in library.

Hello @kevin-hirsch , finally got back into it. I'm currently running version 1.0.1 with a few Swift 2.3 conversions made locally. The output on a 4.7 inch iPhone in computeBottomLayoutDisplay is:
maxY: 1343.98750305176,
windowMaxY: 647.0,
offscreenHeight:<PHONE_NUMBER>51758,
self.tableHeight: 132.0

The anchor view is a UIButton in a cell of a static-grouped tableview on a settings screen. (This is the one I previously had working that has now stopped appearing).
The DropDown is working fine in other view controllers in which I am using the navigation bar as the anchor view, which prints:

Having the same issue, even drop downs in demo code have (0,0,0,0) frames :(

same issue , is there any update or workaround for this ?

+1 same issue as described by markedwardmurray

I'm having the same problem

Hello everyone,
This should now be fixed, could you try and confirm, please? :)
Until a new version of the pod is released, you can use the latest commit by doing:
pod 'DropDown', :git => 'https://github.com/AssistoLab/DropDown', :commit => 'f326a13'

@kevin-hirsch I can confirm this is fixed now, thanks!

DropDown frame is CGRectZero after calling show


Choose two branches to see what

Pull Request Test Coverage Report for Build 370584426

0 of 0   changed or added relevant lines in 0 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage decreased (-0.06%) to 94.676%

Totals

Change from base Build 366226614:
-0.06%

Covered Lines:
1960

Relevant Lines:
2031

💛  - Coveralls


use ripple animation for new pad dialog buttons

also removes the selected class when dialog closes (0eb8b7b)

Random, ex post facto thought: did you consider using three buttons (Dart, Dart + HTML, Flutter), rather than two and a switch?


Instance unresponsive, pods not restarting

Hi,
The current way of doing healthchecks seems somewhat insufficient for auto-healing.
Our instance became unreponsive to commands such as GET, SET, MONITOR etc but the healthchecks were still succeeding (ping/pong).
My suggestion therefore is that the current healthcheck should either be user-configurable or a more thorough healtcheck could be done such as incrementing a value.

Hi @thecodeassassin , I think this is the wrong repo for this issue as the healthcheck is defined here https://github.com/dragonflydb/dragonfly/blob/main/tools/docker/healthcheck.sh. Please open an issue in the dragonfly repo.
I agree with your observation that healthcheck can be improved. Feel free to open a PR!


Main window not unhiding on Windows 7 when clicking tray icon

The application once minimized to tray seems to be unable to re-show for me. Clicking the taskbar icon or right/left clicking the tray icon just re-hides or attempts to show the application.
Here's an example of me spamming right and left click, I get one flash of the application window in the lower right but it quickly disappears again.

If I force-relocate the invisible-but-focused window to another monitor with Win+Shift+Left/Right, I get a blank cutout of where the window should be in the lower right of the screen.
Win 7 Pro SP1
Quadro K610M
3 Monitors
my log id: 4178e4cfa78f8a69e6115f1c

Thanks for the report and sorry for the delay. I have some questions, if
you are still experiencing this.

are you using a non-default/non-Aero theme on Win7? If so, it seems like
a known Electron thing:
https://github.com/electron/electron/issues/1821#issuecomment-314049688.
Does it re-appear if you switch back to Aero?
if you unplug the monitors and reboot, does the window appear?

Thanks,
Steve
On Fri, Oct 13, 2017 at 4:58 PM, Keith Kjer<EMAIL_ADDRESS>wrote:

The application once minimized to tray seems to be unable to re-show for
me. Clicking the taskbar icon or right/left clicking the tray icon just
re-hides or attempts to show the application.
Here's an example of me spamming right and left click, I get one flash of
the application window in the lower right but it quickly disappears again.
[image: keybase_render_issue]
https://user-images.githubusercontent.com/2738686/31570297-41fa22ee-b037-11e7-9c0e-e22f37afb7f4.gif
If I force-relocate the invisible-but-focused window to another monitor
with Win+Shift+Left/Right, I get a blank cutout of where the window should
be in the lower right of the screen.
Win 7 Pro SP1
Quadro K610M
3 Monitors
my log id: 4178e4cfa78f8a69e6115f1c
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/keybase/client/issues/9049, or mute the thread
https://github.com/notifications/unsubscribe-auth/AA0ovdhlI6qs9PjRK5t5dErfkOP2QWFCks5sr_kcgaJpZM4P5LRV
.

I experience the same issue with the latest Keybase and  Win7/Classic theme. Can't unplug the monitors since this is a laptop, window does not appear after the reboot. Running Aero is not an option.


ransomware detection- Grafana

my customers ask for ransomware detection protection alerts.
There is currently no alerting for SPP for ransomware detection.
do you have a way to implement this feature in the SPPmon code calculate it and store the calculated results in a new Influx table that Grafana can easily graph?
Send a report/ alert.
Thank you in advance,
Amichay.

Thanks for the feature-request. I've noted it, but I am not sure if it is going to be part of the 1.0 or 1.1 release.
As far as I know an attack is noticeable by a xx% increase in the incremental backup. This should be possible to implement.

Thanks for the feature-request. I've noted it, but I am not sure if it is going to be part of the 1.0 or 1.1 release.
As far as I know an attack is noticeable by a xx% increase in the incremental backup. This should be possible to implement.


Mention VMSS, VMAS and VMH, at least to indicate if they conform to virtual machine limits or not

Virtual machine scale set, virtual machine availability set and virtual machine host resources likely have the same limits as virtual machine, yet they not mentioned in the Compute section. Please at least indicate if they follow the exact same rules are virtual machine naming, or include them explicitly in this doc if they have their own unique rules.

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

ID: 0e540bb6-9f72-0529-28ea-ae82bc869835
Version Independent ID: 24e71392-985b-59fb-1552-46395b169612
Content: Naming conventions for Azure resources - Best practices for cloud applications
Content Source: docs/best-practices/naming-conventions.md
Service: architecture-center
Sub-service: cloud-fundamentals
GitHub Login: @telmosampaio
Microsoft Alias: pnp

@softwarecraft Thank you for your feedback! We will review and provide an update as appropriate.


Update the properties of Azure Active Directory.

As title.

Hi, @backwind1233 , @saragluna , please help to review this PR when you have time.


[BUG] 2.80.3 Excellent performance 300+FPS, 2.88.8 poor performance 30+FPS

Description
The headline says that I upgraded my recent SkiaSharp and performed very well on the old 2.80.3. Not 2.88.8
!

Code
    private void numRefreshDelay_ValueChanged(object sender, EventArgs e)
    {
        var mapName = cboRefreshMap.SelectedItem.ToString();
        var value = (int)numRefreshDelay.Value;

        if (value != _config.AutoRefreshSettings[mapName])
        {
            _config.AutoRefreshSettings[mapName] = value;
            //Config.SaveConfig(_config);
        }
    }

    private void cboRefreshMap_SelectedIndexChanged(object sender, EventArgs e)
    {
        var mapName = cboRefreshMap.SelectedItem.ToString();
        numRefreshDelay.Value = _config.AutoRefreshSettings[mapName];
    }

    private void lstViewPMCHistory_SelectedIndexChanged(object sender, EventArgs e)
    {

    }

    private void frmMain_Load(object sender, EventArgs e)
    {

    }
}
#endregion

}
Expected Behavior
No response
Actual Behavior
No response
Version of SkiaSharp
2.88.3 (Current)
Last Known Good Version of SkiaSharp
2.88.2 (Previous)
IDE / Editor
Visual Studio Code (Windows)
Platform / Operating System
tvOS, Windows
Platform / Operating System Version
win10 64x
Devices
No response
Relevant Screenshots
No response
Relevant Log Output
No response
Code of Conduct

[X] I agree to follow this project's Code of Conduct

You need to set all bitmaps immutable, and if you are using SKGLView, you need to increase the GPU resource cache limit to something like 768 MB (the exact amount depends on your app).


Fix localization issues.

Fix localization issues.
Makes examples localizable
Enables auto-ellipsis on text that may be truncated in check boxes.
These were all reported on the internal tracker.

Anyone can merge after reviewing this


Istio starts terminating during prestop hook

Bug Description
We know that there is an existing bug in Istio where the sidecar starts terminating immediately, because there is no concept of dependencies between containers during shutdown. This in turn leads to some downtime during scaledown and rollout.
As a workaround, we tried adding a prestop hook to our main container, so that it could shut down cleanly before the sidecar receives SIGTERM.
However, what we observed is that requests during the prestop hook execution still fail. My assumption is the sidecar observes the pod enter the terminating state, and prematurely starts terminating connections.
Connections must not be terminated or otherwise prevented until the sidecar itself receives SIGTERM.
Version
$ istioctl version
client version: 1.10.5
control plane version: 1.10.5
data plane version: 1.10.5 (31 proxies)

$ kubectl version --short
Client version: v1.19.15
Server version: v1.19.13-eks-8df270

Additional Information
No response

@rittneje https://github.com/istio/istio/pull/36633

This is because pod termination process is like:
kubelet execute the same container kill procedure for all the containers concurrently.

run prestop hook
send SIGTERM
SIGKILL if container does not exit after a duration(can be configured, 30s default)

To me the Kubernetes docs imply that pre-stop hooks will be invoked (and completed) prior to SIGTERM. https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#pod-termination
Also, I am wondering if we can simplify all of this by having the sidecar host a listener, perhaps a Unix domain socket. At startup my container will connect to that listener, and close this connection after graceful cleanup (or just let the kernel do it). Meanwhile, when the sidecar receives SIGTERM, it closes this listener, then waits for all of those connections to close, and only then does it start draining envoy. This I think will keep things very simple in my container. I won't need to rely on pre-stop hooks, and Istio won't need to guess when my container is done.

We are already doing similar work.

Is there a PR or something I can track for that? Is there any ETA in terms of the release schedule?

@hzxuzhonghu I've seen lots of references to different environment variables and such to essentially control how long the sidecar will wait to drain Envoy. However, ultimately they are all predicated on guessing when the main container is finished. What I am proposing above with the UDS does not involve any such guessing, and thus will be much more useful.

There is also /quitquitquit that you can call, it is same to send SIGTERM, which is intended for jobs

Can you elaborate on that? Is /quitquitquit an executable within the sidecar container? How and when would I call it?


Fatal Error in BeatSyncConsole: Error reading JToken from JsonReader

Logs:
[BeatSyncConsole - Info]: Running the latest release of BeatSyncConsole.
[BeatSyncConsole - Info]: configs\BeatSyncConsole.json not found, creating a new one.
[BeatSyncConsole - Info]: configs\BeatSync.json not found, creating a new one.
Would you like to replace the existing configs\BeatSync.json with a new one? (Y/N):
y
No song paths found in configs\BeatSyncConsole.json, should I search for game installs? (Y/N):
y
[BeatSyncConsole - Info]:   Steam: C:\Program Files (x86)\Steam\steamapps\common\Beat Saber
[BeatSyncConsole - Info]: Found 1 game install, enabling for BeatSyncConsole: Steam: C:\Program Files (x86)\Steam\steamapps\common\Beat Saber
[BeatSyncConsole - Info]: Using the following targets:
[BeatSyncConsole - Info]:   GameInstall: C:\Program Files (x86)\Steam\steamapps\common\Beat Saber
You have BeastSaber feeds enabled that require your bsaber.com username, enter your username:
*********
[BeatSyncLib - Warn]: History file not found at C:\Program Files (x86)\Steam\steamapps\common\Beat Saber\UserData\BeatSyncHistory.json
[BeatSyncConsole - Info]: Hashing songs in 'C:\Program Files (x86)\Steam\steamapps\common\Beat Saber\Beat Saber_data\CustomLevels'...
[BeatSyncConsole - Error]: Fatal Error in BeatSyncConsole: Error reading JToken from JsonReader. Path '', line 1, position 1670.
   at Newtonsoft.Json.Linq.JToken.ReadFrom(JsonReader reader, JsonLoadSettings settings)
   at Newtonsoft.Json.Linq.JToken.Parse(String json, JsonLoadSettings settings)
   at BeatSyncLib.Utilities.Util.GenerateHash(String songDirectory, String existingHash) in /home/runner/work/BeatSync/BeatSync/BeatSyncLib/Utilities/Util.cs:line 182
   at BeatSyncLib.Hashing.SongHasher.<>c__DisplayClass18_0.<GetSongHashDataAsync>b__0() in /home/runner/work/BeatSync/BeatSync/BeatSyncLib/Hashing/SongHasher.cs:line 111
   at System.Threading.Tasks.Task`1.InnerInvoke()
   at System.Threading.Tasks.Task.<>c.<.cctor>b__274_0(Object obj)
   at System.Threading.ExecutionContext.RunFromThreadPoolDispatchLoop(Thread threadPoolThread, ExecutionContext executionContext, ContextCallback callback, Object state)
--- End of stack trace from previous location where exception was thrown ---
   at System.Threading.ExecutionContext.RunFromThreadPoolDispatchLoop(Thread threadPoolThread, ExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Threading.Tasks.Task.ExecuteWithThreadLocal(Task& currentTaskSlot, Thread threadPoolThread)
--- End of stack trace from previous location where exception was thrown ---
   at BeatSyncLib.Hashing.SongHasher.<>c__DisplayClass17_0.<<HashDirectoryAsync>b__1>d.MoveNext() in /home/runner/work/BeatSync/BeatSync/BeatSyncLib/Hashing/SongHasher.cs:line 55
--- End of stack trace from previous location where exception was thrown ---
   at BeatSyncLib.Hashing.SongHasher.HashDirectoryAsync() in /home/runner/work/BeatSync/BeatSync/BeatSyncLib/Hashing/SongHasher.cs:line 95
   at BeatSyncConsole.Program.CreateJobBuilderAsync(Config config) in /_/BeatSyncConsole/Program.cs:line 87
   at BeatSyncConsole.Program.Main(String[] args) in /_/BeatSyncConsole/Program.cs:line 200
Stopping LogManager.
Press Enter to continue...```

Wrong repository, but will be fixed in next version. https://github.com/Zingabopp/BeatSync/actions/runs/181411866


Release baresip version 0.5.0

testing and documentation ..

@alfredh, looks like I'll open a couple of pull request that I would prefer to be reviewed before 0.5.0 is cut.

Looks like I am done with testing.  With an exception below everything seems fine on OpenBSD-current.
I experience an issue when using libv4l2: baresip picks YU12 (V4L2_PIX_FMT_YUV420), and my video is distorted (topmost line is just repeated over and over).  I blame libv4l2 which is very buggy here (eg. it hides all native formats of my webcam), but I would appreciate if you could make a test build of baresip which forces YU12 and see whether your image is distorted.

version 0.5.0 is now released:
https://github.com/alfredh/baresip/releases/tag/v0.5.0
Announcement email:
http://lists.creytiv.com/pipermail/re-devel/2016-December/001154.html


Add installation instructions for Arch Linux

As requested in #296, this changeset adds installation instructions for Arch Linux.

Out of curiosity, do I need to do anything other than tag a new release to update arch?

Short answer: No, not at all.
More info:
Arch Linux has a very robust user-submitted repository called the AUR. These are packages written and maintained by community members (instead of the distribution's core contributors).
These AUR packages' maintenance, when not maintained by upstream contributors, are the responsibliity of the community member to update. Typically, a well-prepared maintainer might subscribe to a feed of some sort (e.g. Github Releases, an RSS feed, email list, etc.) in order to know when to update a package.

Sounds great! Thanks for adding support and for sending in the documentation PR.


ENH: spatial.distance: extending _distance_pybind with additional metrics

Reference issue

Continues https://github.com/scipy/scipy/pull/14640
What does this implement/fix?

Additional information

Performance differences with main,
| Change   | Before [55069599] <main>   | After [b57ba9b2] <pybind11_dist>   |   Ratio | Benchmark (Parameter)                                   |
|----------|----------------------------|------------------------------------|---------|---------------------------------------------------------|
| +        | 16.8±0μs                   | 43.4±0μs                           |    2.59 | spatial.Xdist.time_cdist(10, 'cosine')                  |
| +        | 25.3±0μs                   | 56.2±0μs                           |    2.22 | spatial.Xdist.time_pdist(100, 'cosine')                 |
| +        | 21.7±0μs                   | 40.5±0μs                           |    1.87 | spatial.Xdist.time_pdist(10, 'cosine')                  |
| +        | 34.8±0μs                   | 63.5±0μs                           |    1.83 | spatial.Xdist.time_cdist(100, 'cosine')                 |
| -        | 2.43±0ms                   | 1.96±0ms                           |    0.81 | spatial.Xdist.time_cdist(1000, 'cosine')                |
| -        | 2.62±0ms                   | 1.96±0ms                           |    0.75 | spatial.Xdist.time_cdist(1000, 'correlation')           |
| -        | 1.27±0ms                   | 887±0μs                            |    0.7  | spatial.Xdist.time_pdist(1000, 'cosine')                |
| -        | 1.42±0ms                   | 907±0μs                            |    0.64 | spatial.Xdist.time_pdist(1000, 'correlation')           |
| -        | 82.3±0μs                   | 45.5±0μs                           |    0.55 | spatial.Xdist.time_pdist(10, 'correlation')             |
| -        | 85.3±0μs                   | 41.4±0μs                           |    0.49 | spatial.Xdist.time_cdist(10, 'correlation')             |
| -        | 112±0μs                    | 54.8±0μs                           |    0.49 | spatial.Xdist.time_cdist(100, 'correlation')            |
| -        | 99.2±0μs                   | 41.9±0μs                           |    0.42 | spatial.Xdist.time_pdist(100, 'correlation')            |
| -        | 505±0μs                    | 71.3±0μs                           |    0.14 | spatial.XdistWeighted.time_pdist(10, 'cosine')          |
| -        | 554±0μs                    | 52.2±0μs                           |    0.09 | spatial.XdistWeighted.time_pdist(10, 'correlation')     |
| -        | 1.27±0ms                   | 80.2±0μs                           |    0.06 | spatial.XdistWeighted.time_cdist(10, 'cosine')          |
| -        | 1.19±0ms                   | 61.0±0μs                           |    0.05 | spatial.XdistWeighted.time_cdist(10, 'correlation')     |
| -        | 3.57±0ms                   | 58.0±0μs                           |    0.02 | spatial.XdistWeighted.time_cdist(20, 'cosine')          |
| -        | 2.16±0ms                   | 46.6±0μs                           |    0.02 | spatial.XdistWeighted.time_pdist(20, 'correlation')     |
| -        | 1.87±0ms                   | 43.9±0μs                           |    0.02 | spatial.XdistWeighted.time_pdist(20, 'cosine')          |
| -        | 4.16±0ms                   | 50.7±0μs                           |    0.01 | spatial.XdistWeighted.time_cdist(20, 'correlation')     |
| -        | 104±0ms                    | 77.1±0μs                           |    0    | spatial.XdistWeighted.time_cdist(100, 'correlation')    |
| -        | 86.8±0ms                   | 91.4±0μs                           |    0    | spatial.XdistWeighted.time_cdist(100, 'cosine')         |
| -        | 50.2±0ms                   | 63.9±0μs                           |    0    | spatial.XdistWeighted.time_pdist(100, 'correlation')    |
| -        | 42.0±0ms                   | 82.4±0μs                           |    0    | spatial.XdistWeighted.time_pdist(100, 'cosine')         |

SOME BENCHMARKS HAVE CHANGED SIGNIFICANTLY.
PERFORMANCE DECREASED.

Performance difference between this branch and pybind11_dist_ (based on https://github.com/scipy/scipy/pull/21263#issuecomment-2251367073),
| Change   | Before [5ae12deb] <pybind11_dist_>   | After [fa227c73] <pybind11_dist>   |   Ratio | Benchmark (Parameter)                           |
|----------|--------------------------------------|------------------------------------|---------|-------------------------------------------------|
| -        | 1.94±0ms                             | 1.74±0ms                           |    0.89 | spatial.Xdist.time_cdist(1000, 'cosine')        |
| -        | 87.9±0μs                             | 52.7±0μs                           |    0.6  | spatial.Xdist.time_cdist(100, 'cosine')         |
| -        | 91.2±0μs                             | 49.1±0μs                           |    0.54 | spatial.Xdist.time_cdist(10, 'cosine')          |

| -        | 75.8±0μs                             | 67.5±0μs                           |    0.89 | spatial.XdistWeighted.time_cdist(20, 'cosine')          |
| -        | 106±0μs                              | 78.5±0μs                           |    0.74 | spatial.XdistWeighted.time_cdist(100, 'cosine')         |
| -        | 76.9±0μs                             | 67.0±0μs                           |    0.87 | spatial.XdistWeighted.time_cdist(10, 'cosine')          |

cc @fancidev for visibility

This looks like a very nice addition!
I’m just a little worried about the added complexity to the already complex implementation. Could there be a way to simplify the code while keeping performant?
If the input vectors are already normalized (i.e. their length is one), then the cosine distance boils down to is a simple vector inner product, and the “cdist” between two matrices is simply matrix multiplication. This is exactly how scikit-learn implements cosine distance — it normalizes the input matrices and then computes a matrix multiplication.
Is such simplified code performant? I did a quick test and it was twice fast as the current SciPy implementation starting from “moderate sized” input (a few dozen vector and a few dozen elements per vector). I find this not unexpected as matrix multiplication is usually a heavily optimized operation, while the current cosine distance code employs no “instruction level parallelism”.
So I’d suggest to try normalize the input matrices first (possibly from Python code, for convenience), and then call the C++ routine with normalized matrices as input. The existing infrastructure would be adequate to handle this. An added benefit would be that premature numeric overflow could be avoided (if a carefully written norm function is called).
What do you think?

I think your idea makes sense. Here's the pure Python implementation for unweighted cosine,
XA = XA.astype(np.float64)
XB = XB.astype(np.float64)
x_rownorm_a = np.linalg.norm(XA, axis=1)
y_rownorm_a = np.linalg.norm(XB, axis=1)
XA = XA/np.tile(np.reshape(x_rownorm_a, (x_rownorm_a.shape[0], 1)), XA.shape[1])
XB = XB/np.tile(np.reshape(y_rownorm_a, (y_rownorm_a.shape[0], 1)), XB.shape[1])
cosine = np.matmul(XA, XB.T)
cosine = np.where(np.fabs(cosine) > 1., np.copysign(1, cosine), cosine)

return np.subtract(1., cosine, out=out)

Sounds cool! FYI you could pass keepdims=True in np.linalg.norm to make the return value suitable for division in the next step.
Also could use std::clamp in C++ to constrain the return value.

So I do normalisation of XA and XB at two levels. One at Python level (in pybind11_dist_) and one in C++ level (this branch, by unrolling loops by a factor of 4). So, this branch performs much better (by significant margins, see the results I posted in the description of this PR) than pybind11_dist_. So I will keep the approach in this PR. IMO, more code is worth having considering the gains we are seeing.

Thanks for the comparison. Let me try run a benchmark between your PR and a simplified version and come back with feedback.

Thanks for the comparison. Let me try run a benchmark between your PR and a simplified version and come back with feedback.

I’m happy to confirm that I observed similar performance comparison as you posted in the top post: Normalization performed in C++ is much faster than normalization performed in Python for input scale up to a few hundred vectors times a few elements per vector. For large scale input, the two have the same speed.
I “think” normalization in Python proves slow because numpy.linalg.norm is coded in Python and hence rather inefficient in terms of overhead. Plus, it does not avoid premature overflow; so there seems no reason to use it in favor of the (straightforward) C++ implementation.
The overall logic of the PR looks good to me.  My main concern is how to achieve the same result with less code duplication. The PR only touches cdist; if pdist is also handled, more code duplication would result. This seems a bit overwhelming to me.
It appears the main bottleneck is that the existing infrastructure does not provide a way to process the input after its dtype is determined. (If the dtype is known in advance, it would not be too difficult to factor the code to avoid the duplication.) Let me think how to enhance the infrastructure to support that.
Meanwhile, let me leave some comments in the code review for discussion.

Well we can add an extra argument in the signature of cdist in distance_pybind.cpp. Something like, normalise_input. If true then normalise it (inside an if condition). Very lite weight and shouldn't affect performance at all. Let me see if that works.

I did this for cdist and will do it for pdist. The code works just fine and without any performance effects.

Adding the normalise_input and centralise_input parameters sounds a good idea! It looks quite lean now.
Maybe they could be factorized into a Preprocessor parameter, in similar fashion to the Distance objects:
struct CosinePreprocessor {
template
operator()(x /* StridedView2D */) …
};
Another thing is that the input arrays, if not copied, should be kept unchanged to avoid surprise to the caller. Therefore the const_casts in the code has to be changed to avoid mutating the input but instead return a copy and mutate the copy.
For that matter, the original C code does not normalize the input but rather computes the norms and divide them in the distance calculation. This likely improves performance for small scale input (by reducing the copy overhead), but it seems not at all straightforward to implement in the existing infrastructure because the Distance objects are called without any “index” parameter (and adding such a parameter would not be “natural”). If you have any good idea to avoid the normalization it would be interesting to see! But the current performance improvement looks already good to me.
The performance drop for tiny-scale input probably comes from the memory-write overhead during normalization. While I don’t care so much (or at all) about the performance of tiny-scale input, an (orthogonal) way to compensate for some of the performance is to unroll the norm calculation. Your code already does the unrolling within a row; but if you look closely in the implementation of transform_reduce_2d, it unrolls across rows. The reason I think is that

Separately, I’m surprised to find that correlation distance does the centering against the row mean instead of the column mean. (The production code already does that and this PR retains that behavior.) Let me try find some reference (for or against) this behavior and open a separate PR if needed.

Therefore the const_casts in the code has to be modified to return a copy instead.

I tried creating a copy in C++ code inside pdist_impl but it gives errors in while copying the data from original to the new copy. So, I create a np.float64 of the inputs at Python level (some assertion tests fail if I don't do so). See, _distance_pybind_pdist_cosine, _distance_pybind_cdist_cosine, _distance_pybind_cdist_correlation, and _distance_pybind_pdist_correlation in the diff of this PR.

Another thing is that the input arrays, if not copied, should be kept unchanged to avoid surprise to the caller. (And it’s possible for the input array to refer to readonly memory in which case writing to it would crash the program.)

There are tests for this in scipy. If the original input is modified some tests fail saying that the original input was modified. As I explained above when we call cdist and pdist functions for cosine, correlation, I already create a copy for XA and XB. Therefore no such tests fail. So we are safe here.
For all other metrics the const_cast isn't used at all. Its only used for cosine and correlation.

I think it's great to migrate all remaining metrics from C to C++, but I personally find it easier to review if each metric, or each group of related metrics, are migrated in a separate PR.
Separately, if you run the benchmarks locally via python dev.py bench, I'd suggest to delete the two occurrences of --quick in dev.py. The presence of this switch makes the benchmark run only once, which makes the result less reliable. By removing this switch, the benchmarks are run repeatedly and averaged to produce a more reliable result.

I think it's great to migrate all remaining metrics from C to C++, but I personally find it easier to review if each metric, or each group of related metrics, are migrated in a separate PR.

Other than the metrics I am adding here in this PR, all others have been migrated to C++ infrastructure. The ones I am adding here are tricky and need different forms of pre-processing. So a good design of pre-processing needs all the remaining distance metrics (4 in number I think) to be added at the same time.
To make reviewing easy for you, what I can do is to add changes in each file in separate commits. I will also add comments for each change so that it is for you to understand. Let me know if that works. Creating separate PRs would be tricky for me.

Separately, if you run the benchmarks locally via python dev.py bench, I'd suggest to delete the two occurrences of --quick in dev.py. The presence of this switch makes the benchmark run only once, which makes the result less reliable. By removing this switch, the benchmarks are run repeatedly and then averaged to produce a more reliable result.

Done locally. You can see the updated description. The performance gains are significant.

With C++ computation of inverse covariance matrix we are seeing significant performance gains in mahalanobis distance.

I have added changes in each file in a separate commit for easy reviewing. I will be out of office tomorrow. But once I come back I will leave comments explaining each change in this PR for additional help.
Meanwhile please feel free to suggest any change.
We are seeing excellent performance gains overall.

I think it's great to migrate all remaining metrics from C to C++, but I personally find it easier to review if each metric, or each group of related metrics, are migrated in a separate PR.

My personal opinion is that changes here should go in full inside SciPy's main branch. However, to make reviewing easy for you I can create separate PRs for each metric in my own fork and you can review it there. What do you say? Once all the PRs in my fork are merged then I can create a new PR here in SciPy and we can merge it directly. Let me know if it makes sense.
I have no problems in creating and merging separate PRs directly in SciPy. Just that changes for each metric are linked with others especially the pre-processing part.

Thanks for the comments. I think no need to split into separate PRs now that you’ve already included them in one. Btw I’m not a maintainer so I cannot approve your changes; I’m just taking a look out of curiosity and hope to provide some useful comments. Hope you don’t mind! :-)

Hope you don’t mind! :-)

All review comments are welcome by me. I will address them as early as possible. Please let me know of any possible improvements.

Btw I’m not a maintainer so I cannot approve your changes; I’m just taking a look out of curiosity and hope to provide some useful comments. Hope you don’t mind! :-)

@fancidev your reviews here are much appreciated, as is your investigation of other spatial.distance topics (and everything else you contribute). I'd encourage you to continue. Also, I sent you an invite for the triage team so you have more permissions on this repo - that was overdue I think.

Thanks very much for your trust and support! @rgommers

All review comments are welcome by me. I will address them as early as possible. Please let me know of any possible improvements.

Among the points I raised in the inline reviews, two technical points are worth addressing I think:

Avoid using const_cast to cast from const to non-const. Although it “works” in the current way the code is written, it could silently break if changes are made in the future. After all, writing to memory obtained from const_cast (that casts away constness) leads to undefined behavior in C++ anyway.

Wrap new/delete in an RAII object such as std::vector. The current code “works”, but it could silently leak memory if changes are made in the future that throws an exception before delete.

The key question that needs decision, in my opinion, is what sort of code complexity (resulting from micro-optimization) we’re ready to accept in return for code execution speed gain. This is a totally subjective topic so I could only provide my own view to kick off the discussion. (By micro-optimization I mean optimizations that don’t change the big O complexity but reduce the constant factor.)
The main optimizations in the PR are (1) porting certain operations from Python to C++, and (2) unrolling certain loops in C++ to take advantage of instruction level parallelism (ILP).

I have resolved reviews which are addressed by me. There is only one left https://github.com/scipy/scipy/pull/21263#discussion_r1714070803

In my opinion, the key question that needs decision is what sort of additional code complexity we’re ready to accept in return for code execution speed gain.

True. For very large sized inputs benefits of ILP start to vanish. However for small sized inputs they show up (
can be seen in the benchmarks). I think multiple calls with small scale inputs can show performance differences. Say for example, a million calls to the function with each call having small sized inputs. Then performance gains in each call will add up and the overall timings will be improved. So there ILP will definitely help.

For lesser code duplication, I have used ForceUnroll to manually unroll loops. Now this PR is completely ready from my side. @fancidev If you can review and give it a green light then it would be great. Thanks.


Link in hover item is invalid

Issue Type: Bug
In a TypeScript project, I have this line in a file:
const path = require("path");

require("path") will have red squiggly lines under it. If I hover over the element, I get a popover describing the issue as:

Require statement not part of import statement.eslint@typescript-eslint/no-var-requires

The last part of which is a link that, when clicked, leads to an invalid URL:
https://github.com/typescript-eslint/typescript-eslint/blob/v%5Bobject%20Object%5D/packages/eslint-plugin/docs/rules/no-var-requires.md

Extension version: 2.1.20
VS Code version: Code 1.56.2 (054a9295330880ed74ceaedda236253b4f39a335, 2021-05-12T17:13:13.157Z)
OS version: Windows_NT x64 10.0.19042
Remote OS version: Linux x64 5.4.72-microsoft-standard-WSL2
Remote OS version: Linux x64 5.4.72-microsoft-standard-WSL2
Remote OS version: Linux x64 5.4.72-microsoft-standard-WSL2

System Info

Item
Value

CPUs
Intel(R) Core(TM) i7-6850K CPU @ 3.60GHz (12 x 3592)

GPU Status
2d_canvas: enabledgpu_compositing: enabledmultiple_raster_threads: enabled_onoop_rasterization: enabledopengl: enabled_onrasterization: enabledskia_renderer: enabled_onvideo_decode: enabledvulkan: disabled_offwebgl: enabledwebgl2: enabled

Load (avg)
undefined

Memory (System)
63.87GB (25.42GB free)

Process Argv
--folder-uri=vscode-remote://wsl+Ubuntu/home/oliver/fairmanager/fairmanager/core-web3 --remote=wsl+Ubuntu --crash-reporter-id 05565d81-cfc4-40de-88df-1c479bbe1bcd

Screen Reader
no

VM
0%

Item
Value

Remote
WSL: Ubuntu

OS
Linux x64 5.4.72-microsoft-standard-WSL2

CPUs
Intel(R) Core(TM) i7-6850K CPU @ 3.60GHz (12 x 3591)

Memory (System)
50.11GB (29.96GB free)

VM
0%

Item
Value

Remote
WSL: Ubuntu

OS
Linux x64 5.4.72-microsoft-standard-WSL2

CPUs
Intel(R) Core(TM) i7-6850K CPU @ 3.60GHz (12 x 3591)

Memory (System)
50.11GB (29.96GB free)

VM
0%

Item
Value

Remote
WSL: Ubuntu

OS
Linux x64 5.4.72-microsoft-standard-WSL2

CPUs
Intel(R) Core(TM) i7-6850K CPU @ 3.60GHz (12 x 3591)

Memory (System)
50.11GB (29.96GB free)

VM
0%

The version information in that link seems broken. The setup seems to depend on which version are installed. So can you please provider me with a GitHub repository I can clone that demos what you are seeing.

This project should show the issue in source/test.js: https://github.com/oliversalzburg/vscode-eslint-version-repro
I'm assuming this is possibly connected to yarn/PnP, if it hasn't come up before.

Thanks for the test case. It has nothing to do with yarn. If that would cause problems than ESLint wouldn't work at all.

I looked at it and I already get a broken URI from @typescript-eslint/eslint-plugin

There is nothing I can do about that. Can you please report the issue against @typescript-eslint/eslint-plugin


[FEATURE] Active directory authentication

A custom implementation of the Spring authentication provider for
active directory servers is added.
The security configuration is enhanced so that environment variables
can be used to switch to Active Directory authentication.
A custom implementation of the Active Directory authentication
provider is used because the ActiveDirectoryLdapAuthenticationProvider
that comes with the spring framework is marked final and can not be
extended, see: http://goo.gl/qNBSNo.

Thank you for your effort, but we implemented the authentication via Active Directory now ourselves - without need to extend the ActiveDirectoryLdapAuthenticationProvider, because the application uses LDAP only for authentication, but not for authorization.
It's now to possible to use authentication via Active directory by starting the application with parameter -Dspring.profiles.active=activeDirectory
Provided that the two configuration properties for Active Directory Base and LDAP URL are set. (have a look at the README)
Please feel free to test the functionality and to give us feedback! :)

Works like a charm. Thank you very much :)


How to parse json that contains only array

Hi!
I am having problem with parsing json object like {[...,...]} which contains only array. Constructor init?(json: JSON) is not firing at all.

there’s different syntax for creating models from JSON arrays
check out: https://github.com/hkellaway/Gloss#model-objects-from-json-arrays

there’s different syntax for creating models from JSON arrays
check out: https://github.com/hkellaway/Gloss#model-objects-from-json-arrays

oh, i'm sorry. Overlooked that.


What about a list of libraries that work well with Bootstrap and extend its components/features?

Prerequisites

[X] I have searched for duplicate or closed feature requests
[X] I have read the contributing guidelines

Proposal
A list everyone could contribute to, that collects useful libraries that extend Bootstraps functionality, like new components.
Some ideas:

https://github.com/snapappointments/bootstrap-select for custom select elements
https://github.com/Eonasdan/tempus-dominus for Date/time picker widget
https://github.com/lekoala/bootstrap5-autocomplete for autocomplete component
https://github.com/lekoala/bootstrap5-tags for selectable tags
https://github.com/dealfonso/power-buttons for confirmation dialogs and more
https://github.com/kartik-v/bootstrap-star-rating for star rating component
and there are probably many more!

Motivation and context
Many features that these libraries above provide are currently not implemented in Bootstrap, and probably won't be because of the work that comes with maintaining so many features.
Providing a list of good working libraries/plugins that fill those missing features would be very helpful to all Bootstrap users and could close some issues on this repo...

Thanks for opening this feature request @AgentSmith0. I'll let other maintainers give their thoughts, but on my side, I think that can be useful for Bootstrap users to have some links to external libraries, but also external tools, in our documentation.
However, if we do that, I think we'd need to define some rules like if we reference "everything" that's suggested by users, if we have rather a curated list based on some criteria (number of stars or whatever), etc.

In my opinion, https://github.com/snapappointments/bootstrap-select and https://github.com/Eonasdan/tempus-dominus should be natively implemented in the library. I really miss these features.

Yes, the Select component is necessary in almost every project. While Bootstrap Select is a good library, if someone is looking for a Select2 Bootstrap 5 theme, they can use the following: https://apalfrey.github.io/select2-bootstrap-5-theme/


[SPARK-46672][BUILD] Upgrade log4j2 to 2.22.1

What changes were proposed in this pull request?
This pr aims to upgrade log4j2 from 2.22.0 to 2.22.1.
Why are the changes needed?
The new version contains some bug fixes:

Fix NPE in CloseableThreadContext
Fix NPE in RollingFileManager

And 2.22.1 is generated using JDK 17, the full release note as follows:

https://github.com/apache/logging-log4j2/releases/tag/rel%2F2.22.1

Does this PR introduce any user-facing change?
No
How was this patch tested?
Pass GitHub Actions
Was this patch authored or co-authored using generative AI tooling?
No

Thanks @dongjoon-hyun ~


Allow uploading a file to an open transaction

We can currently only upload 1 file per transaction, this allows more flexibility.

Released 0.3.0


Support for multiple shells.

Feature Request
if you work with multiple clusters, you often want to associate one terminal window to a cluster. With kubectx and many other tools including kubecm this is not possible.  A few tools where this is possible, they use subshells, which has its set of issues.
Describe the solution you'd like
it should be possible to have multiple shells that use different Kubernetes contexts
Describe alternatives you've considered
I am currently using a combination of different tools to accomplish this.
kubens and https://github.com/danielfoehrKn/kubeswitch
Additional context
Add any other context or screenshots about the feature request here.

@Vad1mo Good idea, but kubecm is only used to manage kubeconfig, if you want to specify the current shell's cluster, you need to modify the current-context field in kubeconfig.
To implement this, you need multiple copies of the kubeconfig file, and then specify in kubectl to use that configuration file.
just like:
kubectl get pod --kubeconfig .kube/config

You can use alias to simplify this command above.
Edit your .zshrc( or .bashrc) file like this:
...
alias k1='kubectl --kubeconfig .kube/config1'
alias k2='kubectl --kubeconfig .kube/config2'

After that you can use different commands to operate different clusters.
k1 get pod
k2 get pod


Add opale-messenger app

Hi !
I'd like my project to be added to this list.
The reasons why it should be included : https://github.com/DavidMellul/Opale-Messenger
In summary, it's a wrapper for Facebook Messenger, but it comes with the android-like bubble.
Thank you in advance.
Cheers.

Thanks for submitting. What is an "android-like bubble"?

Hey !
By android-like bubble I mean, when you're on Messenger on your Android, you have a bubble (maybe it's not like that it's called ? ).
Here is an image of what I'm talking about :

Thank you for your consideration.


Added new command to list, add & delete build tags

Fixes #215

@dhilmathy  Delete the existing test recording. Clear the python client cache (.vsts folder in your homepath).
Run this test individually e.g.
pytest ./tests/test_pipelinesBuildTagTest.py
The issue is the recording does not have the options call which is cached in .vsts folder. So the test might succeed in live mode but will fail in recording.
I will update this is docs and try to add some script probably so others don't got through the pain.
Feel free to suggest changes in the docs to improve the experience for new contributors.

@dhilmathy  Raised a PR in your repo with the recording. https://github.com/dhilmathy/azure-devops-cli-extension/pull/1
This should give you access to the recording with the test account.
We have an open issue to make test authoring easy. I am taking note of the issues you faced. Hopefully we will improve the experience soon.


Xaml warning: Resource '{x:Type MahApps.Metro.Controls.MetroWindow}' is not found

Describe the bug
I am not sure when this warning started to be emitted. But noticed it today. When creating a custom window style and attempting to base it from the MetroWindowStyle, I am getting Resource '{x:Type MahApps.Metro.Controls.MetroWindow}' is not found.
Steps to reproduce
The xaml resources header is
<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:controls="http://metro.mahapps.com/winfx/xaml/controls"
    xmlns:mah="http://metro.mahapps.com/winfx/xaml/controls"
...
>

The custom style:
    <Style
        x:Key="CustomMetroWindow"
        TargetType="{x:Type controls:MetroWindow}"
        BasedOn="{StaticResource {x:Type controls:MetroWindow}}">
        <Setter Property="ShowTitleBar" Value="True" />
        <Setter Property="Height" Value="600" />
        <Setter Property="Width" Value="1024" />
        <Setter Property="FontFamily" Value="Roboto" />
    </Style>

It is on the BasedOn line that the warning is being emitted.
There should not be a warning emitted for this, I would have thought.  I have obviously done something wrong or something has changed.
I get the warning in both rider and visual studio with resharper
Environment
MahApps.Metro version: v2.4.10
Windows build number: Windows 11 Pro, version 21H2, Build 22000.2538
JetBrains Rider: 2023.3.2
Visual Studio: 2022  17.8.0
JetBrains ReSharper 2023.3.2
Target Framework: .Net 8.0

Is it probalby a controls lib that doesn't reference MahApps on it's own?

This is directly in my wpf application with a main window, not in a controls lib and directly references mahapps.

ah wait looks like MetroWindow does not support this feature to inherit the style. Check original styles for reference.

I think this issue is not related to MahApps itself. Yes, it's not nice to see this, but at the end it's a waning and is a designer xaml parsing issue. One suggestion is to put the style in the App.xaml and use it then with DynamicResource.
<mah:MetroWindow x:Class="MetroDemo.MainWindow"
                 xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
                 xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
                 xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
                 xmlns:mah="http://metro.mahapps.com/winfx/xaml/controls"
...
                 Style="{DynamicResource CustomMetroWindow}"
...


"lucide-react" Check error

This is a duplicate of #1171 and #1163.
@atleugim linked the relevant issue on the lucide-icons repository here: https://github.com/shadcn-ui/ui/issues/1163#issuecomment-1671961549

This issue has been automatically closed because it received no activity for a while. If you think it was closed by accident, please leave a comment. Thank you.


Memory Issue

I'm receiving this message in the Xcode console:
Message from debugger: Terminated due to memory issue
My device is an iPhone 6 Plus with the latest software v9.3.3
My settings in the iPokeGo settings menu are Pokémon, PokéStops, Gyms and Show Timer ON
I forgot to mention that this message is appearing and the app is force quitting when changing scan location.

@blackhattristar can you try things with the code from PR #125 ? I've been debugging and profiling that a lot today and when running on device I haven't seen it go above ~150 megs. Still high, but the memory seems to be under control now and never seems to go high enough to get terminated.

I would recommend scanning in a location like New York City and then try to run a scan at your current location. The app should terminate. At least with the latest version for me, when PokeStops is on and I have PokeStops on the map and then long press to scan, the app freezes and then terminates. I'll take a look at the code from PR #125

@blackhattristar can you email me a server running scans in NYC that I can point to to test?
I'm running 8x step-8 scans in my city, which gets me up up to 150megs, but yeah I can guess that NYC might be a lot worse. 😭 Might be hard to optimize for but I'd suspect we need to start only showing annotations in the visible region.

I think the problem is that the map is retaining the PokeStops on the map. If I scan in NYC and then scan in CA, the app is going to terminate because it can't handle all those PokeStops. It will retain the ones that appeared in NYC. I'm running -st 10 in Manhattan, NYC

Your app doesn't terminate when changing scan locations while having PokeStops on?

It hasn't for me, nope. That might be suburbia life though (although I do have a few large regions scanned for a few hundred stops).

That has me at 92 megs, with stops and pokemon enabled. (pokemon not recently scanned in south position)

If you're up for the test, you could always try and maneuver over to NYC and scan there to see if it's just me or... Maybe submit a pull request / update the master with the changes you've made to your app to help memory usage? Maybe your version is working but not the latest version on GitHub may have problems when trying to scan multiple populated locations.

There's a pull request in with all the changes I've been making today, just waiting for it to be merged into master.  I don't have merge rights.

Very cool. I look forward to testing the updates. Let me know if you try scanning in Manhattan. Trust me, you'll be blown away by the amount of PokeStops and Lured PokeStops there are.

On Jul 31, 2016, at 9:55 PM, Curtis Herbert<EMAIL_ADDRESS>wrote:
There's a pull request in with all the changes I've been making today, just waiting for it to be merged into master. I don't have merge rights.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.

In the meantime, when I get home I'm going to try some of the code fixes from PR #125 and see if anything helps. I'll let you know if the problem continues.

@parrots @blackhattristar Now merged

@istornz @parrots Looks like the problem still persists. When I turn PokéStops on and try to scan the map, the app terminates.

@blackhattristar Strange, I have an iPhone 6 Plus too and I can see a lot of annotation on the map...
May be try to delete all app in background.

@istornz Very strange. I don't know how I could be the only one with this issue :p
Have you tried scanning Manhattan, New York City and then scanning your current location? The map is retaining the information on the PokéStops. Which means if I scan in a heavily populated area and then scan in a totally different state, the memory issue arises because the map is retaining those PokéStops in the heavily populated area. Is there any way around this?

There is no problem with scanning as long as PokéStops is turn OFF. :(

@istornz @parrots Is there any way to cluster the PokéStops?

@blackhattristar clustering is possible, but not without a lot of work. Apple doesn't provide a built-in way to do this. There are some third party solutions, but nothing that'd we'd be able to just drop in.
Some ideas on doing it manually here: https://robots.thoughtbot.com/how-to-handle-large-amounts-of-data-on-maps
For now we might want to consider just disabling non-lured pokestops through an option


APIv2: Blinds position/lamella setting fails

I haven't managed to understand, hence fix the source of this issue I'm getting:
[547411987152] [Errno None] Can not write request body for http://<IP_ADDRESS>/api/v1/shade/1 :
Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/components/websocket_api/commands.py", line 205, in handle_call_service
    await hass.services.async_call(
  File "/usr/src/homeassistant/homeassistant/core.py", line 1910, in async_call
    task.result()
  File "/usr/src/homeassistant/homeassistant/core.py", line 1950, in _execute_service
    await cast(Callable[[ServiceCall], Awaitable[None]], handler.job.target)(
  File "/usr/src/homeassistant/homeassistant/helpers/entity_component.py", line 226, in handle_service
    await service.entity_service_call(
  File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 811, in entity_service_call
    future.result()  # pop exception if have
    ^^^^^^^^^^^^^^^
  File "/usr/src/homeassistant/homeassistant/helpers/entity.py", line 1034, in async_request_call
    await coro
  File "/usr/src/homeassistant/homeassistant/helpers/service.py", line 851, in _handle_entity_call
    await result
  File "/config/custom_components/dingz/cover.py", line 93, in async_stop_cover
    await self._dingz_session.blind_stop(self._index)
  File "/config/custom_components/dingz/api.py", line 747, in blind_stop
    await self._post_plain(f"/shade/{index}/stop", **kwargs)
  File "/config/custom_components/dingz/api.py", line 657, in _post_plain
    async with self.__post_request(path, data) as resp:
  File "/usr/local/lib/python3.11/site-packages/aiohttp/client.py", line 1141, in __aenter__
    self._resp = await self._coro
                 ^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/aiohttp/client.py", line 560, in _request
    await resp.start(conn)
  File "/usr/local/lib/python3.11/site-packages/aiohttp/client_reqrep.py", line 899, in start
    message, payload = await protocol.read()  # type: ignore[union-attr]
                       ^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/site-packages/aiohttp/streams.py", line 616, in read
    await self._waiter
aiohttp.client_exceptions.ClientOSError: [Errno 104] Connection reset by peer

This happens when I'm clicking to set a blind or lamella position; the POST request doesn't go through.

This might be fixed in the new version. Can you give it a shot, @OdyX?

Yay. I had to resetup the whole thing (and can't seem to manage to access blinds' position in UI), but this all works again, thanks a lot!

Sorry about having to re-do the entire setup, but after 2 years of not being able to work on this it was easier to just start from scratch.

[...] can't seem to manage to access blinds' position in UI

Can you elaborate on this? Would love to get this fixed as well.

Here is what state looks like with the first motor (index 0) fully opened, and the second one (index 1) fully closed:
{"dimmers":[],"blinds":[{"moving":"stop","position":100,"lamella":100,"readonly":false,"index":{"relative":0,"absolute":0}},{"moving":"stop","position":0,"lamella":0,"readonly":false,"index":{"relative":1,"absolute":1}}],"led":{"on":false,"hsv":"0;0;100","rgb":"FFFFFF","mode":"hsv","ramp":1023},"sensors":{"brightness":10,"light_state":"night","light_state_lpf":"night","room_temperature":25,"uncompensated_temperature":37.125,"temp_offset":6,"cpu_temperature":63.33,"puck_temperature":37,"fet_temperature":36.1,"input_state":null,"pirs":[null,{"enabled":false,"motion":false,"mode":"idle","light_off_timer":0,"suspend_timer":0}],"power_outputs":[{"value":0},{"value":0},{"value":0},{"value":0}]},"dyn_light":{"mode":"night"},"thermostat":{"active":false,"state":"off","mode":"off","enabled":false,"target_temp":21,"min_target_temp":17,"max_target_temp":31,"temp":25},"wifi":{"version":"2.0.21","mac":"mac","ssid":"ssid","ip":"<ip>.235","mask":"<IP_ADDRESS>","gateway":"<ip>.1","dns":"<ip>.2","static":false,"connected":true},"cloud":{"aws":"connected"},"time":"2023-08-21 19:23:54","config":{"timestamp":0}}
Here is what it looks like with one motor and two outputs:
`
closed
{"dimmers":[{"on":false,"output":0,"ramp":0,"readonly":false,"index":{"relative":0,"absolute":2}},{"on":false,"output":0,"ramp":0,"readonly":true,"index":{"relative":1,"absolute":3}}],"blinds":[{"moving":"stop","position":0,"lamella":0,"readonly":false,"index":{"relative":0,"absolute":0}}],"led":{"on":false,"hsv":"0;0;100","rgb":"FFFFFF","mode":"rgb","ramp":501},"sensors":{"brightness":0,"light_state":"night","light_state_lpf":"night","room_temperature":28.5,"uncompensated_temperature":40.25,"temp_offset":6,"cpu_temperature":65,"puck_temperature":39,"fet_temperature":38.8,"input_state":null,"pirs":[null,{"enabled":false,"motion":false,"mode":"idle","light_off_timer":0,"suspend_timer":0}],"power_outputs":[{"value":0},{"value":0},{"value":0},{"value":0}]},"dyn_light":{"mode":"night"},"thermostat":{"active":false,"state":"off","mode":"off","enabled":false,"target_temp":21,"min_target_temp":17,"max_target_temp":31,"temp":28.5},"wifi":{"version":"2.0.21","mac":"mac","ssid":"ssid","ip":".231","mask":"<IP_ADDRESS>","gateway":".1","dns":".2","static":false,"connected":true},"cloud":{"aws":"disconnected"},"time":"2023-08-21 20:15:34","config":{"timestamp":1690205913}}
opening
{"dimmers":[{"on":false,"output":0,"ramp":0,"readonly":false,"index":{"relative":0,"absolute":2}},{"on":false,"output":0,"ramp":0,"readonly":true,"index":{"relative":1,"absolute":3}}],"blinds":[{"moving":"up","position":33,"lamella":100,"readonly":false,"index":{"relative":0,"absolute":0}}],"led":{"on":false,"hsv":"0;0;100","rgb":"FFFFFF","mode":"rgb","ramp":501},"sensors":{"brightness":7,"light_state":"night","light_state_lpf":"night","room_temperature":28.5,"uncompensated_temperature":40.3125,"temp_offset":6,"cpu_temperature":65.56,"puck_temperature":39,"fet_temperature":38.8,"input_state":null,"pirs":[null,{"enabled":false,"motion":false,"mode":"idle","light_off_timer":0,"suspend_timer":0}],"power_outputs":[{"value":82.9},{"value":0},{"value":0},{"value":0}]},"dyn_light":{"mode":"night"},"thermostat":{"active":false,"state":"off","mode":"off","enabled":false,"target_temp":21,"min_target_temp":17,"max_target_temp":31,"temp":28.5},"wifi":{"version":"2.0.21","mac":"mac","ssid":"ssid","ip":".231","mask":"<IP_ADDRESS>","gateway":".1","dns":".2","static":false,"connected":true},"cloud":{"aws":"disconnected"},"time":"2023-08-21 20:16:37","config":{"timestamp":1690205913}}
open
{"dimmers":[{"on":false,"output":0,"ramp":0,"readonly":false,"index":{"relative":0,"absolute":2}},{"on":false,"output":0,"ramp":0,"readonly":true,"index":{"relative":1,"absolute":3}}],"blinds":[{"moving":"stop","position":100,"lamella":100,"readonly":false,"index":{"relative":0,"absolute":0}}],"led":{"on":false,"hsv":"0;0;100","rgb":"FFFFFF","mode":"rgb","ramp":501},"sensors":{"brightness":14,"light_state":"night","light_state_lpf":"night","room_temperature":28.5,"uncompensated_temperature":40.375,"temp_offset":6,"cpu_temperature":65.56,"puck_temperature":39,"fet_temperature":38.7,"input_state":null,"pirs":[null,{"enabled":false,"motion":false,"mode":"idle","light_off_timer":0,"suspend_timer":0}],"power_outputs":[{"value":0},{"value":0},{"value":0},{"value":0}]},"dyn_light":{"mode":"night"},"thermostat":{"active":false,"state":"off","mode":"off","enabled":false,"target_temp":21,"min_target_temp":17,"max_target_temp":31,"temp":28.5},"wifi":{"version":"2.0.21","mac":"mac","ssid":"ssid","ip":".231","mask":"<IP_ADDRESS>","gateway":".1","dns":".2","static":false,"connected":true},"cloud":{"aws":"disconnected"},"time":"2023-08-21 20:17:25","config":{"timestamp":1690205913}}
`
So far I've never seen a mqtt index issue with the shades. I've seen it with the lights, but it's usually after I play for too long with the UI, and fixed with a reboot of the dingz; so I'm assuming this is a bug.
Thanks !

@letienne, thanks, this is exactly what I needed.
I just released a beta release v0.3.2 if you want to try it out. I will implement MQTT support for the covers before creating a full release.
One more question though, if you have the time. Can you give me the output of http://<host>/api/v1/output_config. I'm trying to find out if the motors show up there as well. The integration tries to use the name that the user assigned in the dingz config for the home assistant entities, but I'm not sure how that works for blinds / motors.
Right now the integration is using the name of the output with the corresponding index. Does that work on your end?

sure output_config appears to be giving the outputs config (such as lights, switches). The blinds output is:
http:///api/v1/blind_config which returns:
{"blinds":[{"active":true,"name":"","type":"blind","min_value":0,"max_value":100,"def_blind":0,"def_lamella":80,"groups":"z","auto_calibration":true,"shade_up_time":62.45,"shade_down_time":61.66,"invert_direction":true,"lamella_time":1.8,"step_duration":300,"step_interval":1200,"state":"Initialised"},{"active":true,"name":"","type":"blind","min_value":0,"max_value":100,"def_blind":0,"def_lamella":80,"groups":"z","auto_calibration":true,"shade_up_time":180,"shade_down_time":180,"invert_direction":false,"lamella_time":1.8,"step_duration":300,"step_interval":1200,"state":"Not initialised"}]}
The "active":true is wrong, there is only one motor active in the above config.
(same for the lights, my dingz with 2 motors (and 0 lights) states that the 4 outputs are active -_-)
Thanks !

@letienne, the full release is out now. Thanks for your help!

Thank you, looking good :)
I'll let you know if something goes wrong.

I noticed some stderr on my container :
ValueError: '0' is not a valid MotorMotion
2023-08-23 00:06:53.311 ERROR (MainThread) [homeassistant.util.logging] Exception in _handle_mqtt_motor when handling msg on 'dingz//dz1f-4b/state/motor/0': '{"motion":"0","position":0,"lamella":52}'

it looks like the motion value is sent as string and not as int...

Wow, I guess that's just yet another issue with the documentation.  Why even use an enum if they end up sending it as a string...
Anyway, the fix for this is straight forward.
Can you check that it's always a string and not just when the value is 0?

Sorry...
Logger: homeassistant.setup
Source: loader.py:821
First occurred: 9:20:35 PM (1 occurrences)
Last logged: 9:20:35 PM
Setup failed for custom integration dingz: Unable to import component: Exception importing custom_components.dingz
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/loader.py", line 813, in get_component
ComponentProtocol, importlib.import_module(self.pkg_path)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/importlib/init.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "", line 1204, in _gcd_import
File "", line 1176, in _find_and_load
File "", line 1147, in _find_and_load_unlocked
File "", line 690, in _load_unlocked
File "", line 940, in exec_module
File "", line 241, in _call_with_frames_removed
File "/config/custom_components/dingz/init.py", line 7, in
from .shared import Shared
File "/config/custom_components/dingz/shared.py", line 256, in
class MotorMotion(IntEnum):
File "/config/custom_components/dingz/shared.py", line 264, in MotorMotion
def parse(cls, value: str | int | "MotorMotion") -> "MotorMotion":
^~~~~
TypeError: unsupported operand type(s) for |: 'types.UnionType' and 'str'
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/setup.py", line 215, in _async_setup_component
component = integration.get_component()
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/src/homeassistant/homeassistant/loader.py", line 821, in get_component
raise ImportError(f"Exception importing {self.pkg_path}") from err
ImportError: Exception importing custom_components.dingz

@letienne, that's on me... I made a seemingly minor change just before releasing the previous version and didn't bother to test it. You know the rest :)

0.4.2 seems to be the one :) thanks !

Awesome, thanks. (And sorry for not being active on that front.)


Question about hyparams in tutorial-notebooks

Why don't the .yaml files in the tutorial-notebooks have hyperparameters "stats_dir"?

Only ROME and MEMIT require stats_dir

Thanks for your answering, but I found that ROME's examples in [tutorial-notebooks] do not have stats_dir? btw, may I ask what is the effect of this hyperparameter? I have not yet make this file "./data/stats", but it seems that my program still can run?

If there is no ./data/stats, the accuracy of your results will be lower.


added paragraph highlighting (e.g., notes) details

Adding greater description for using notes, warnings, and tips.
@jseldess Pretty minor; take a quick look? Also think it closes an old issue.
Closes #48

This change is

http://cockroach-docs-review.s3-website-us-east-1.amazonaws.com/12a43d93708089f27452bf8756a8858ca219043e/


Add environments structure to Conventional Directory Structure

In the writing-helmfile.md file here we already have a Conventional Directory Structure for per-release files like this:
  values:
  - "./config/heapster/values.yaml"
  - "./config/heapster/{{ .Environment.Name }}.yaml"
  secrets:
  - "./config/heapster/secrets.yaml"
  - "./config/heapster/{{ .Environment.Name }}-secrets.yaml"

But there is missing information about directory structure for environments files (per-environment values and secrets files). Will be good to add them too.
We already have below some examples like this:
environments:
  stage:
    values:
    - env/stage.yaml
  prod:
    values:
    - env/prod.yaml

But in main readme file we have another structure example:
environments:
  default:
    values:
    - environments/default/values.yaml
  production:
    values:
    - environments/production/values.yaml
    secrets:
    - environments/production/secrets.yaml

So maybe let's select one most common option as convention and describe it?

Also will be good to describe convention about structure of environments secrets, how to pass them to release's values files. Maybe something like this? environments/default/secrets.yaml
global:
   globalSecret1: secret
releases:
  release1:
    release1secret: secret


Brocfile.js outputPaths CSS ignored

I'm setting the path in outputPaths as specified in the docs, it was working fine for everything when I was using css, but since I installed foundation-sass and sass compiler, now that parameter is being ignored, and my compiled app.scss is going to /assets/app-name.css Any ideas on how to fix this? Thanks!

It looks very much like an issue with foundation-sass. Also it's not clear what you mean by "sass compiler". I'd suggest you post this issue on foundation-sass.


CI: Add tracker story automation

[#177985308]
Signed-off-by: Neil Hickey<EMAIL_ADDRESS>Thanks for submitting a PR to DRATs.

@dependabot merge

@dependabot merge

@dependabot merge

@dependabot merge


Compose Simple- and DiscoveryClientRouteLocator

As requested #1448 was split up in two parts. This is the follow up with the second commit.
With this commit an AbstractZuulRouteLocator is added. This allows us
to remove the logic for simple routes from DiscoveryClientRouteLocator
by not extending the SimpleRouteLocator. The behaviour for the simple
and discovery routes is from now on composed and not inherited. This
follows the "favor composition over inheritance" principle and makes
the code (especially for the DiscoveryClientRouteLocator) a bit less
twisted.

sigh ... I'll fix the build...

fixed.

Current coverage is 74.29% (diff: 81.59%)

Merging #1617 into master will increase coverage by 0.02%

@@             master      #1617   diff @@
==========================================
  Files           194        195     +1
  Lines          6038       6035     -3
  Methods           0          0
  Messages          0          0
  Branches        911        909     -2
==========================================
- Hits           4485       4484     -1
+ Misses         1226       1221     -5
- Partials        327        330     +3

Powered by Codecov. Last update 66da2d8...18fc7ca

So reviewing this a bit more. I'm not super convinced this is helpful. Most of the functionality just moved from Simple -> Abstract. I don't see big benefits from this. I was thinking more along the lines of a true composite.

Problem here was both, the simple and the discovery rules both depend heavily on the ZuulRoute.
Imho to decompose the RouteLocator in a true composite it may be needed to have a "StaticZuulRoute" and a "DiscoveryZuulRoute" but this would be a lot more to do. Imho the current ZuulRoute is a bit unfortunate in supplying both concepts (e.g. getLocation()), but decomposing the ZuulRoute would mean to break compatibility for the configuration.

Sure, a true composite would be much more work.  What is the advantage of the changes here?

You should be able to do this on your own with the interface.
This module has entered maintenance mode. This means that the Spring Cloud team will no longer be adding new features to the module. We will fix blocker bugs and security issues, and we will also consider and review small pull requests from the community.


Mask + Canvas Render

Hi, again,
Does canvas renderer have issues with masks? I did a simple mask animation which works well when renderer is SVG and when switched to the canvas, I see masks which are supposed to be hidden.
CanvasMask.aep.zip
Thanks!

check this PR, see if its related to you and if you are able to contribute. Thanks https://github.com/bodymovin/bodymovin/pull/382

track masks are not supported in the canvas renderer.
Only regular AE masks in add mode

Hi!
What is a regular AE Mask and how would you mask something without track matte mask?
Do you mean Merge Paths inside shape layers with add mode?
Another question, does html renderer supports track matte masks?

if you right click on the layer > Mask >New Mask you will get a clipping mask.
Does that work for your case?

Hernan, thank you for this hint (mask in add mode)! It works very fine now!!!!!!!! Will pay for bodymovin, great work!!!