map is no longer available in Terraform 1.x

After being deprecated, the map() function is no longer available in the newest versions of Terraform, so this will fail under Terraform 1.0.1, for example:
https://github.com/terraform-aws-modules/terraform-aws-lambda/blob/62ebcd4c239b79853ce928bcfead1bc3b0b533c7/modules/deploy/main.tf#L28
On my Terraform 1.0.1 environment, I tried replacing this map(k, v) call with either tomap({ k = v }) or tomap({ k: v }) - but neither of them works (even though they are recommended in docs, both are broken because the k bound variable from the for expression becomes the literal string "k" rather than e.g. 'BeforeAllowTraffic' - it seems the bound variable is missed and treated as a bare string).
I found zipmap([k], [v]) does work.

Thanks a lot for opening this issue! The trick is to wrap k in brackets to tell Terraform that the value should be evaluated.
Fixed in #171

v2.6.0 has been just released.


nsh:support wait command to wait task exit.

Summary
'wait' command will block nsh from running until pid1 and pid2 finish. This is useful for parallel requirements to perform certain tasks
Impact
nsh
Testing
usage like:
  nsh> sleep 10 &
  [5:100]
  nsh>set pid1=$!
  nsh>sleep 15 &
  [6:100]
  nsh>set pid2=$!
  nsh>wait $pid1 $pid2

[Experimental Bot, please feedback here]
This PR description, while introducing a potentially useful feature, does not meet the NuttX requirements. Here's why and how to improve it:
Missing Information

Why is this change necessary?  The summary states the "what" (adds a 'wait' command) but not the "why." Is there a specific use case or limitation in NSH this addresses?  Explain the motivation behind the change.
What functional part of the code is changed? Is this a new NSH command? A modification to existing shell logic? Be specific about which files/modules are affected.
How does the change work? A brief explanation of the implementation is needed. Does 'wait' use polling, signals, or another mechanism to monitor processes?
Impact details are insufficient:

User Impact:  While "nsh" is mentioned, clarify if users need to change existing scripts or commands due to this addition.
Build Impact: Will any build configurations or dependencies be affected by this change?
Other Impacts:  The remaining impact sections (hardware, documentation, security, compatibility) lack any assessment.  Even if the answer is "NO," state it explicitly.

Testing is inadequate:

Build Host details are missing:  Provide the specific operating system, CPU architecture, and compiler used for testing.
Target details are missing: Specify the target architecture (e.g., simulated, RISC-V, ARM) and board configuration used for validation.
Testing logs are absent: Provide actual output from your tests both before and after the change.  This demonstrates the problem the PR solves and that the solution works.

How to Improve

Expand the Summary:  Clearly articulate the problem this PR addresses and its benefits.
Detail Code Changes: Briefly explain the technical implementation of the 'wait' command.
Complete the Impact Assessment:  Address each impact category, even if the answer is "NO."
Provide Comprehensive Testing Information: Include specific details about your build host and target environments. Include actual testing logs to demonstrate the change's effectiveness.

By providing this missing information, you'll create a much stronger PR that's more likely to be reviewed and merged.


Express feature updates. See individual commits.

We have a new contributor: vim 😉

Haha I was thinking the same thing.

Although to be truly accurate it should be :w1qq!1111!!wtf!


Enabling Scheduled posts in blog

For a production build, turn off --buildFuture
We run a build each morning, to publish anything scheduled
No one has to merge things on release day manually

If this is merged, we can test it with this PR: https://github.com/pulumi/docs/pull/13674


How do the sample format conversion work in 0.5.7

Get this error when calling out, the call do connect. Running a simple USB sound card on a Raspberry Pi. Call is between two baresip, same config.
call: connecting to<EMAIL_ADDRESS>call: SIP Progress: 180 Ringing (/)
alsa: cannot set sample rate to 8000 Hz (Invalid argument)
alsa: init failed: err=-22
alsa: could not reset player 'default' (Invalid argument)
audio: Set audio decoder: opus 48000Hz 2ch
audio: player started with sample format S16LE
audio: Set audio encoder: opus 48000Hz 2ch
audio: source started with sample format S16LE
audio tx pipeline:        alsa ---> vumeter ---> opus
audio rx pipeline:        alsa <--- vumeter <--- opus
sip:****@*****: Call established: *****@*****
stream: audio: SSRC changed 4e0f -> 36ff5243 (496 bytes from *******)
[0:00:22] audio=129083/128229 (bit/s)                       [==========      ]  [

My config for audio, have tried  various combinations of sample rates..
# Audio
#audio_path             /usr/local/share/baresip
audio_player            alsa,hw:1,0
audio_source            alsa,hw:1,0
audio_alert             no
audio_srate             8000-48000
audio_channels          1-2
ausrc_srate             48000
auplay_srate            48000
ausrc_channels          2
auplay_channels         2
#audio_txmode           poll            # poll, thread
audio_level             no
ausrc_format            s16             # s16|float|s24_3le
auplay_format           s16             # s16|float|s24_3le

# Audio codec Modules (in order)
module                  opus.so
module                  g722.so
module                  g711.so

Last, how do I disable baresip from playing dial up tones and ring signals? How to use "audio_alert" ?
Thanks!

As you use ausrc_srate and auplay_srate you may have locked the USB sound card at 48000 but the incoming call needs 8000Hz.
Try to disable these values in the config file:
#ausrc_srate             48000
#auplay_srate           48000
When no alert signals at all is needed, one way could be to set the audio_alert to alsa,null:
audio_alert             alsa,null
You may also want to use "plughw" instead of "hw" for the audio_player/source as ALSA then automatically may help you to convert the data in the plug-in layer to a format supported by the sound card:
audio_player            alsa,plughw:1,0
audio_source           alsa,plughw:1,0

Perhaps, the below values would work for you?
Audio
#audio_path             /usr/local/share/baresip
audio_player            alsa,plughw:1,0
audio_source           alsa,plughw:1,0
audio_alert              alsa,null
audio_srate             8000-48000
audio_channels          1-2
#ausrc_srate             48000
#auplay_srate            48000
#ausrc_channels          2
#auplay_channels         2
#audio_txmode           poll            # poll, thread
audio_level             no
ausrc_format            s16             # s16|float|s24_3le
auplay_format           s16             # s16|float|s24_3le

Having a closer look, it seems like you need to disable ringback in the config file:
ringback_disabled       true    #true / false

try the device alsa,default
you can also use the ALSA tools to list the supported sample rates
of your sound card.


Find example L2 Products for SDAP integration

Determine which product(s) we should ingest into SDAP for SBG analysis examples. Work with SBG team to confirm that correct product(s).

We will use the terrestrial ecology products from sister as a validation product.
These are not accessible to the public, but i've gained access and uploaded them to the Unity-SBG-Dev environment:
S3 bucket: unity-sbg-dev-data
prefix: urn:nasa:unity:sbg:dev:SISTER-L2B_VEGBIOCHEM
These are not available in U-DS data search currently.


drivers: gpio: miwu: Add miwu and gpio drivers in npcx7 series.

Add Multi-Input Wake-Up Unit (MIWU) and GPIO driver implementations in Nuvoton npcx7 series..
It is separated into three commits. First, commit introduces MIWU which provides signal conditioning such as 'Level' and 'Edge' trigger type and grouping of NVIC's external interrupt sources. It's crucial since many devices such as gpio, timer, eSPI VW signals relies on it for interrupt handling. Beside gpio driver implementation, the other commits also demonstrate how we handle wake-up signals of gpio and uart by MIWU api functions.

From the build error report, it shows "gen_isr_tables.py: error: multiple registrations at table_index 61 for irq 61 (0x3d)".  Dig the source of gen_isr_table, the root cause is that the test suit also uses IRQ61 (https://github.com/zephyrproject-rtos/zephyr/blob/master/tests/kernel/gen_isr_table/src/main.c#L283) which is the same as miwu2 group2 interrupt.
Hi @ioannisg
Might I know what is the purpose of the test suite? Is the workaround moving TEST_NUM_IRQS to unused IRQ? Thanks.

Hi @sjg20 :
I left two comments for further discussion and resolved the others in this PR. Putting a comment at the top of miwu driver is a good idea since it's not a popular hardware device. Thanks for reviewing it.

Looks interesting, but there's no public information I can find on the board or its MCU, or where to buy the board.

Hi @pabigot:
Thanks for your comments in this PR. Regarding the npcx board, our PM will contact you privately.
Hi @michalsch:
Could you help with this? Thanks.

Looks interesting, but there's no public information I can find on the board or its MCU, or where to buy the board.

Hi @pabigot:
Thanks for your comments in this PR. Regarding the npcx board, our PM will contact you privately.

Thanks.  But my main point is an ongoing concern with adopting into mainline Zephyr hardware (boards, SoCs, shields) that are not generally available.  This introduces a near-permanent maintenance burden as tree-wide refactoring often requires their code be changed, but the people making those changes can't easily verify functionality.  I really hate changing something when I can't verify I didn't break it; so I have 26 Zephyr target boards spanning almost all SoC families.  More than half of those are not of interest to the people who fund most of my Zephyr work.
When the documentation is also not available it becomes a bigger problem.
Note that this is my personal view, which others may or may not share.  There is no documented policy in Zephyr providing non-technical criteria for adding new content.  Since this target has already been accepted clearly the new peripheral implementations must go in.  But the level of review I can give is seriously impeded by lack of technical documentation and the ability to test.

Thanks. But my main point is an ongoing concern with adopting into mainline Zephyr hardware (boards, SoCs, shields) that are not generally available. This introduces a near-permanent maintenance burden as tree-wide refactoring often requires their code be changed, but the people making those changes can't easily verify functionality. I really hate changing something when I can't verify I didn't break it; so I have 26 Zephyr target boards spanning almost all SoC families. More than half of those are not of interest to the people who fund most of my Zephyr work.
When the documentation is also not available it becomes a bigger problem.
Note that this is my personal view, which others may or may not share. There is no documented policy in Zephyr providing non-technical criteria for adding new content. Since this target has already been accepted clearly the new peripheral implementations must go in. But the level of review I can give is seriously impeded by lack of technical documentation and the ability to test.

I think your concern about testing wide-scale changes/refactors is valid. I know I have heard something about a hardware test matrix that we can run tests on that is distributed out to different chip vendors; would adding more testing for the npcx product line address some of your concerns here? @nashif for more details on test matix.

@pabigot and @jett:
Regarding test suites, boards, and documentation during refactoring, I fully understand what you concern. Each time I did changes for comments from code review, passing the related driver test suite is necessary before I submitting them. I think it's OK to provide npcx7m6fb evaluation boards.
Regarding the document or the datasheet of Nuvoton EC, I need further discussion with our PM. (Basically, they are provided under NDA.)

@jettr @pabigot

Thanks. But my main point is an ongoing concern with adopting into mainline Zephyr hardware (boards, SoCs, shields) that are not generally available.

This was already discussed in multiple occasions and the consensus was that support for unreleased hardware and missing documentation of the hardware is acceptable as long ad the drivers, SoCs and boards are being actively maintained with someone available to answer any technical questions. If this changes over time and some hardware becomes unmaintained and it prevents us from moving forward because of lack of response or broken support, we will then reserve the right to disable or remove such support.
Supporting hardware that is still unreleased is often related to product development and is an indicator that the project is doing well in general :) Linux is full of drivers and hardware support that is still not released, there is no way we can make progress only with release hardware (that is maybe how we started 5 years ago, but we are way beyond that).

Can you make a sweep through all of the remaining open comments and address them, please?

@jettr I have swept all remaining comments. Most of them are resolved and related changes were updated. But a few comments are still open and I gave replies for further discussions. Please check them, thanks.

@jettr @pabigot

Thanks. But my main point is an ongoing concern with adopting into mainline Zephyr hardware (boards, SoCs, shields) that are not generally available.

This was already discussed in multiple occasions and the consensus was that support for unreleased hardware and missing documentation of the hardware is acceptable as long ad the drivers, SoCs and boards are being actively maintained with someone available to answer any technical questions. If this changes over time and some hardware becomes unmaintained and it prevents us from moving forward because of lack of response or broken support, we will then reserve the right to disable or remove such support.
Supporting hardware that is still unreleased is often related to product development and is an indicator that the project is doing well in general :) Linux is full of drivers and hardware support that is still not released, there is no way we can make progress only with release hardware (that is maybe how we started 5 years ago, but we are way beyond that).

Sorry for the delay. Was OOO and had to catch-up.
Datasheet can be provided under NDA as ML mentioned.
We can provide boards but I assume they are meaningless without the datasheet.


Add gitattributes to normalize line endings in repo

Summarize the change in the pull request title
@aczechowski This is big and messy, so it might be easier for you to do it yourself on your internal repo.

Add .gitignore from https://github.com/MicrosoftDocs/feedback/issues/362#issuecomment-403932911
git rm -rf --cached . removes all files from the git index, but leaves them on the disk
git add . add back the files looking at the .gitattributes and .gitignore settings
Commit the re-encoded files

@nschonni : Thanks for your contribution! The author, @aczechowski, has been notified to review your proposed change.

@nschonni thanks for the contribution, but as you said, it's big and messy. I'm doing some other repo work today, so I'm going to close this PR. I'll do some more research, and will try to fix it otherwise.


How to change the applicatian name on giving permission screen?

How to set the application name on that permission screen, I want to use my App name instead of project-xxxxxxx ?

GoogleSignin.configure({
scopes: ['https://www.googleapis.com/auth/drive.readonly'], // what API you want to access on behalf of the user, default is email and profile
webClientId: '', // client ID of type WEB for your server (needed to verify user ID and offline access)
offlineAccess: true, // if you want to access Google API on behalf of the user FROM YOUR SERVER
hostedDomain: '', // specifies a hosted domain restriction
loginHint: '', // [iOS] The user's ID, or email address, to be prefilled in the authentication UI if possible. See docs here
forceConsentPrompt: true, // [Android] if you want to show the authorization prompt at each login.
accountName: '', // [Android] specifies an account name on the device that should be used
iosClientId: '', // [iOS] optional, if you want to specify the client ID of type iOS (otherwise, it is taken from GoogleService-Info.plist)
});

hello, you can change the name in firebase project settings: see this https://stackoverflow.com/questions/50604741/firebase-change-app-name-which-display-on-google-sign-in-alert


Access minScale property of MapState

MapState has public property maxScale but does not have minScale, even though ZoomPanRotateState has it (as a private property). It would be great to make it accesible for reading from MapState as it can be set to some non-trivial values by Fit or Fill MinimumScaleModes. Personally I need this for some scale-dependent animations to normalize the scale.

I believe the reason why the minScale hasn't been added is, as you mention, because it depends on other inputs such as MinimumScaleMode. However, it should be possible to have the minScale backed by a State, or accessible as a Flow. I will have a look.

I've created the branch min-scale, where I added two apis :

one the get the current min scale
one the get the min scale as a Flow

If it's ok for you I'll merge

@p-lr Could you please publish the current library version to Maven?

@TimPushkin It's done, and should be available on maven servers in 1 hour or so.


Update nir, test-runner, tools, util to 0.4.2

Updates

org.scala-native:nir
org.scala-native:test-runner
org.scala-native:tools
org.scala-native:util

from 0.4.0 to 0.4.2.
GitHub Release Notes - Version Diff
I'll automatically update this PR to resolve conflicts as long as you don't change it yourself.
If you'd like to skip this version, you can just close this PR. If you have any feedback, just mention me in the comments below.
Configure Scala Steward for your repository with a .scala-steward.conf file.
Have a fantastic day writing Scala!

Files still referring to the old version number
The following files still refer to the old version number (0.4.0).
You might want to review and update them manually.
contrib/bloop/test/src/mill/contrib/bloop/BloopTests.scala
docs/antora/modules/ROOT/pages/Thirdparty_Plugins.adoc
readme.adoc
scalanativelib/test/src/HelloNativeWorldTests.scala

Ignore future updates
Add this to your .scala-steward.conf file to ignore future updates of this dependency:
updates.ignore = [ { groupId = "org.scala-native" } ]

labels: library-update, early-semver-minor, semver-spec-patch, old-version-remains

Not forward compatible.


update README

It used to say its not ready for use. This is not correct. It is ready for use.

@mikelodder7 — tests are failing (obviously unrelated to this). Looks like something with BLSFul. Fix first, or just merge the text change?


[EXCLUSIVE CLIP] Pragya Nagra Video Original

A private video allegedly featuring Malayalam actress Pragya Nagra has sparked online discussions, raising serious concerns about celebrity privacy and digital safety. The video’s authenticity remains unverified, and Pragya Nagra ] has not yet commented on the matter.
This incident is part of a broader trend of leaked personal videos involving social media personalities and entertainers. In recent months, several public figures have experienced similar privacy breaches, including Pakistani influencers like Minahil Malik, Kanwal Aftab, Mathira Mohammad, and others.
🔴 ➤► WATCH THE VIDEO HERE✅👉 https://shorturl.at/H0aYQ (VideoLink)
🔴 ➤► WATCH THE VIDEO HERE✅👉 https://shorturl.at/H0aYQ (VideoLink)
Background on Pragya Nagra
Pragya Nagra is a talented actress from the South Indian film industry. Originally from a Punjabi family in Haryana’s Ambala district, she completed her education in Delhi before transitioning from modeling to acting. Recently, she appeared in the Telugu film Laggam, released in October 2024.
The ongoing situation highlights the critical need for improved digital privacy protections for public figures and the potential psychological and professional consequences of unauthorized content distribution.


I need a way to run my chroot

Please paste the output of the following command here: sudo edit-chroot -all

sudo sh ./edit-chroot -all
name: bionic
encrypted: yes, locked
Unmounting /media/removable/USB Drive/chroots/bionic...
Please describe your issue:
sudo sh ./startcli
Enter encryption passphrase for bionic:
Entering /media/removable/USB Drive/chroots/bionic...
Cannot execute /bin/bash: Permission denied
Unmounting /media/removable/USB Drive/chroots/bionic...
I need a way to execute crouton in external device

Now this happened!!!
sh: 0: getcwd() failed: No such file or directory
sh: 0: getcwd() failed: No such file or directory

yes you may need to remount and change the exec privs
it run without errors after remount new crouton need to update privs
chronos@localhost / $ sudo mount -o remount,exec,suid,nosymfollow /media/removable/sd200
chronos@localhost / $ sudo mount -o remount,exec,suid,symfollow /tmp
every time my machine start i have to do this i set up a script all i use is external devices
/tmp is causing problems

i still have this after i did those commands:
Enter encryption passphrase for bionic:
Entering /media/removable/USB Drive/chroots/bionic...
Cannot execute /bin/bash: Permission denied
Unmounting /media/removable/USB Drive/chroots/bionic...

yes the fS is protected and bash runs in /tmp so maybe the experts can chime in, you have to look at you FS now

I just tried this command:
chronos@localhost /media/removable/USB Drive/bin $  sudo bash startcli -b
A command must be specified in order to run in the background.

And this...
chronos@localhost /media/removable/USB Drive/bin $ sudo sh ./enter-chroot bionic
Enter encryption passphrase for bionic:
Entering /media/removable/USB Drive/chroots/bionic...
Cannot execute /bin/sh
Unmounting /media/removable/USB Drive/chroots/bionic...

Maybe a new installation of crouton?

I didn't set the key file yet on this installation but I came with this in my new chroot:
name: bionic_two
encrypted: no
Entering /media/removable/USB Drive/chroots/bionic_two...
crouton: version 1-20220111101058~master:a9eafaee
release: bionic
architecture:
targets: core,cli-extra
host: version 14588.123.0 (Official Build) stable-channel octopus
kernel: Linux localhost 4.14.254-18805-g12d6850827f5 #1 SMP PREEMPT Wed May 18 19:53:03 PDT 2022 x86_64 x86_64 x86_64 GNU/Linux
freon: yes
Unmounting /media/removable/USB Drive/chroots/bionic_two...

ok very good, you can look at the FS system with Just the shell not  enter-chroot to look at the FS. no issue then check the status of bash
crosh> shell
chronos@localhost / $ cd /media/removable/sd200/
chronos@localhost /media/removable/sd200 $ pwd
/media/removable/sd200
chronos@localhost /media/removable/sd200 $ cd bull
chronos@localhost /media/removable/sd200/bull $ cd chroots
chronos@localhost /media/removable/sd200/bull/chroots $ pwd
/media/removable/sd200/bull/chroots
chronos@localhost /media/removable/sd200/bull/chroots $ cd bullseye
chronos@localhost /media/removable/sd200/bull/chroots/bullseye $ ls
bin  boot  dev  etc  home  lib  media  mnt  opt  proc  root  run  sbin  srv  sys  tmp  usr  var
chronos@localhost /media/removable/sd200/bull/chroots/bullseye $ cd bin
bash: cd: bin: Too many levels of symbolic links
chronos@localhost /media/removable/sd200/bull/chroots/bullseye $ pe
chronos@localhost /media/removable/sd200/bull/chroots/bullseye $ cd bin
chronos@localhost /media/removable/sd200/bull/chroots/bullseye/bin $ ls bash
bash
chronos@localhost /media/removable/sd200/bull/chroots/bullseye/bin $ ls -la bash
-rwxr-xr-x. 1 root root 1282512 Aug  4  2021 bash
chronos@localhost /media/removable/sd200/bull/chroots/bullseye/bin $
it the same with FS
crosh> shell
chronos@localhost / $ cd /usr/local/bin
chronos@localhost /usr/local/bin $ more pe
sudo mount -o remount,exec,suid,dev,nosymfollow /media/removable/sd200/
sudo mount -o remount,exec,suid,dev,symfollow /media/removable/sd200/
sudo mount -o remount,exec,suid,symfollow /tmp
sudo mount -o remount,exec,suid,symfollow /
chronos@localhost /usr/local/bin $ more enter-chroot
#!/bin/sh -e
Copyright (c) 2016 The crouton Authors. All rights reserved.
Use of this source code is governed by a BSD-style license that can be
found in the LICENSE file.
set -e
APPLICATION="${0##*/}"
BACKGROUND=''
BINDIR="dirname "\readlink -f -- "$0"`"" CHROOTS="readlink -m -- "$BINDIR/../chroots"`"
KEYFILE=''
LOGIN=''
NAME=''
TARGET=''
USERNAME='1000'
TMPXMETHOD=''
NOLOGIN=''
SETUPSCRIPT='/prepare.sh'
USAGE="$APPLICATION [options] [command [args...]]
Enters an installed Debian-based chroot for running alongside Chromium OS.
By default, it will log into the primary user on the first chroot found.
You can specify a command and parameters to run instead of an interactive shell.
Options:
-b          Fork and run the specified command silently in the background.
-c CHROOTS  Directory the chroots are in. Default: $CHROOTS
-l          Make the command part of a login. Parameters are passed directly
to the chroot command, and a call to su is appended.
-k KEYFILE  Override the auto-detected encryption key location.
-n NAME     Name of the chroot to enter. Default: first one found in CHROOTS
-t TARGET   Only enter the chroot if it contains the specified TARGET.
--More--(3%)
chroot has special status you have to command the files a bit different
IE
-rwxr-xr-x. 1 root root 1282512 Aug  4  2021 bash
chronos@localhost /media/removable/sd200/bull/chroots/bullseye/bin $ ./bash
bash: ./bash: No such file or directory
chronos@localhost /media/removable/sd200/bull/chroots/bullseye/bin $ pwd
/media/removable/sd200/bull/chroots/bullseye/bin
chronos@localhost /media/removable/sd200/bull/chroots/bullseye/bin $ /media/removable/sd200/bull/chroots/bullseye/bin/bash
bash: /media/removable/sd200/bull/chroots/bullseye/bin/bash: No such file or directory
chronos@localhost /media/removable/sd200/bull/chroots/bullseye/bin $
read
you have to configure chroot
chronos@localhost /media/removable/sd200/bull/chroots $ sudo chroot bullseye
(bullseye)root@localhost:/# bash -v
System-wide .bashrc file for interactive bash(1) shells.
To enable the settings / commands in this file for login shells as well,
this file has to be sourced in /etc/profile.
see you under multiple chroots many processes, this is the file system for me
sda                                                                  8:0    1  29.3G  0 disk
|-sda1                                                               8:1    1   9.8G  0 part /media/removable/root
|-sda2                                                               8:2    1   8.8G  0 part /media/removable/tmp
`-sda3                                                               8:3    1  10.7G  0 part /media/removable/home
sdb                                                                  8:16   1 183.3G  0 disk /media/removable/sd200
for crouton
mmcblk0                                                            179:0    0  58.2G  0 disk
|-mmcblk0p1                                                        179:1    0  50.1G  0 part /mnt/stateful_partition
the mount enter-chroot defines
bindmount /dev
bindmount /dev/pts
bindmount /dev/shm
bindmount /tmp /tmp exec
bindmount /proc
tmpfsmount /var/run 'noexec,nosuid,mode=0755,size=10%'
tmpfsmount /var/run/lock 'noexec,nosuid,nodev,size=5120k'
bindmount /var/run/dbus /var/host/dbus
bindmount /var/run/shill /var/host/shill
bindmount /var/lib/timezone /var/host/timezone
for m in /lib/modules/*; do
if [ -d "$m" ]; then
bindmount '-o ro' "$m"
it is a machine
crosh.txt
crosh  shell.txt

update:
sh: 0: getcwd() failed: Input/output error
sh: 0: Can't open ./startcli

@Arvin2A,
There is no need whatsoever to remount anything if you use the default location under /usr/local/bin to install your crouton scripts. If your crouton chroots are located on external media just see the built-in -c option when launching your desktop, see below:

-c CHROOTS  Directory the chroots are in. Default: /usr/local/chroots

Hope this helps,
-DennisLfromGA

This guy just has scripts in an external drive and is failing to execute them. He made a reddit post but then deleted it. He completely reinstalled crouton and the chroot, and is just trying to use chroot, without the proper steps outlined above, to access the chroot.  I couldn't talk sense into him
Reddit post  is here for more context. Probably good to close since its user error.
https://www.reddit.com/r/Crouton/comments/uyai9r/cannot_execute_binbash_permission_denied_need/?utm_medium=android_app&utm_source=share

I successfully entered the chroot but now I am moving to a new problem in installing. I am opening a new issue post in github

Anyone else run into permissions errors when trying to run chroot independently of crouton? I set the permissions to chronos for the user, group for /bin/bash. I still receive permissions errors when trying to execute chroot commands also with sudo stating permission denied with /bin/bash & with other means.
This seems like the OS is malfunctioning entirely with permissions in this case maybe due to OS changes.
Seems like a possible solution is to reinstall bash somehow to a different location then re-executing bash.
If there is a better repository to post this, please let me know. I did see the crostini repo however since it's dated 2018 I didn't see it being that relevant.


Installing from Visual Studio 2015 breaks... a lot!

Hello!  (Visual Studio 2015 Enterprise) All I did was go to Tools => Extensions and Updates and update TypeScript from version <IP_ADDRESS> to <IP_ADDRESS>.  That was the only update I did.  When I then restart Visual Studio and open my solution, I am presented with a number of errors:
The JavaScriptWebExtensionsPackage package did not load correctly.
Upon loading (at least one, but not all) a web forms page, I am presented with this error:
The Visual Studio language support for Style has not been installed.  Code-editing Intellisense will not be available..."
Then - and this is a bit weird - I have a section of the page I want to move elsewhere - cut and paste.  As soon as I cut I get this:
Error HRESULT E_FAIL has been returned from a call to a COM component.
The code I was cutting is removed, however it was not put into the clipboard - to recover it I have to not save the file.  To make this more interesting, I have tried cutting and pasting each component of that code and each individual one works fine, but not all of them together.  Here is what I'm cutting:

Login

Temp Bobblejob Button
Login with Bobblejob API

The error appears to be on pasting as I can successfully copy.
In the event viewer, I can see 8 errors all at once, though this doesn't happen every time I try this, but they seem likely related.  The first of which is this:
Windows cannot open the 64-bit extensible counter DLL ASP.NET_64_2.0.50727 in a 32-bit environment. Contact the file vendor to obtain a 32-bit version. Alternatively if you are running a 64-bit native environment, you can open the 64-bit extensible counter DLL by using the 64-bit version of Performance Monitor. To use this tool, open the Windows folder, open the System32 folder, and then start Perfmon.exe.
This might seem a lot and some of it rather obscure - I was running my project perfectly fine, working away, and then remembered to take a look at Typescript (I've not used it before) and installed the update.  Then everything fell to pieces.  I've tried repairing Visual Studio and the problem persists.  I've tried uninstalling the ASP.net windows components and reinstalling them and this still doesn't resolve the issue.
Please please please can you quickly show me how to remove the typescript update or roll back to the previous version.  Otherwise, to put it politely, I'm really quite scrwd and unable to work even half as productively as I need to.
Thank you.

The content I'm cutting is HTML, which isn't encoded by GitHub it seems - you'd need to view source to get what I mean - apologies for the poor formatting.

You can use this to present HTML code:
```html
<html-code>
    Your codes
</html-code>
```

This is not caused by updating TypeScript update. this is causes by updating "Tools for Universal Windows Apps Development"
Please follow the steps in https://github.com/Microsoft/TypeScript/issues/4238#issuecomment-129060370 to restore your JavaScript support.

@SaschaNaz I added the tag you suggested there but it doesn't appear to have worked.  :-/
@mhegazy Thanks for the response!  I ended up uninstalling VS and reinstalling it again.  There is clearly a clash of some kind - but fair enough if the bug is on the universal apps side.  Regardless the issue is resolved.  Thanks!


WIP Update Buffer32, Char & CList

This PR needs a last syntax check before merging

This PR needs a last syntax check before merging

All good


is this program still on maintainance, does it support to transfer itk image to svs format

Question
is this program still on maintainance, does it support to transfer itk image to svs format?
or is there any other way to write the itk::TileMergeImageFilter->GetOutput() to svs format

the ITKIOOpenSlide does not support write to svs format, this is my test result
Parameters:

inputImage = 'E:/data/CMU-1.ndpi'
outputImage = 'E:/data/CMU-1.svs'
shouldFail = false
compress = false
approximateStreaming = false
stream = 0
level = 0
associatedImage = ''
downsample = 0
Error:
itk::ImageFileWriterException (000000DA126FF9C0)
Location: "unknown"
File: E:\projects\ITK\Modules\IO\ImageBase\include\itkImageFileWriter.hxx
Line: 118
Description:  Could not create IO object for writing file E:/data/CMU-1.svs
  Tried to create one of the following:
    JPEGImageIO
    PNGImageIO
    TIFFImageIO
  You probably failed to set a file suffix, or
    set the suffix to an unsupported type.

test code:
#include <algorithm>
#include <cstdlib>
#include <cstring>
#include <iostream>
#include <sstream>

#include "itkImageFileReader.h"
#include "itkImageFileWriter.h"
#include "itkOpenSlideImageIO.h"
#include "itkImage.h"
#include "itkRGBAPixel.h"
#include "itkMetaDataObject.h"

#include "itkOpenSlideImageIOFactory.h"
#include "itkImageIOFactory.h"

bool ParseValue(const char *p_cValue, std::string &strCommand, std::string &strValue) {
  strCommand.clear();
  strValue.clear();

  if (p_cValue == NULL)
    return false;

  const char *p = strchr(p_cValue, '=');

  if (p == NULL) {
    strCommand = p_cValue;
    return true;
  }

  // is p the beginning or end of the string?
  if (p == p_cValue)
    return false;

  strCommand.assign(p_cValue, (p-p_cValue));
  strValue = p+1;

  return true;
}
int main(int argc, char **argv)
{
  using PixelType = itk::RGBAPixel<unsigned char>;
  using ImageType = itk::Image<PixelType, 2>;
  using ReaderIOType = itk::OpenSlideImageIO;
  using ReaderType = itk::ImageFileReader<ImageType>;
  using WriterType = itk::ImageFileWriter<ImageType>;

  if( argc < 3 ) {
    std::cerr << "Usage: " << argv[0] << " inputImage outputImage [command1 command2 ...]\n";
    return EXIT_FAILURE;
  }

  //const char * const p_cArg0 = argv[0];
  const char * const p_cInputImage = argv[1];
  const char * const p_cOutputImage = argv[2];

  argc -= 3;
  argv += 3;

  bool bShouldFail = false;
  bool bUseCompression = false;
  bool bApproximateStreaming = false;
  unsigned int uiNumStreams = 0; // 0 means no streaming
  int iLevel = 0;
  std::string strAssociatedImageName;
  double dDownsampleFactor = 0.0; // 0 means no down sample

  for (int i = 0; i < argc; ++i) {
    std::string strCommand;
    std::string strValue;

    if (!ParseValue(argv[i], strCommand, strValue)) {
      std::cerr << "Error: Could not parse value '" << argv[i] << "'." << std::endl;
      return EXIT_FAILURE;
    }

    if (strCommand == "shouldFail") {
      bShouldFail = true;
    }
    else if (strCommand == "compress") {
      bUseCompression = true;
    }
    else if (strCommand == "approximateStreaming") {
      bApproximateStreaming = true;
    }
    else if (strCommand == "level") {
      if (strValue.empty()) {
        std::cerr << "Error: Expected level parameter." << std::endl;
        return EXIT_FAILURE;
      }

      char *p = NULL;
      iLevel = strtol(strValue.c_str(), &p, 10);
      if (*p != '\0') {
        std::cerr << "Error: Could not parse level '" << strValue << "'." << std::endl;
        return EXIT_FAILURE;
      }
    }
    else if (strCommand == "associatedImage") {
      if (strValue.empty()) {
        std::cerr << "Error: Expected associated image name." << std::endl;
        return EXIT_FAILURE;
      }

      strAssociatedImageName = strValue;
    }
    else if (strCommand == "downsample") {
      if (strValue.empty()) {
        std::cerr << "Error: Expected downsample factor." << std::endl;
        return EXIT_FAILURE;
      }

      char *p = NULL;
      dDownsampleFactor = strtod(strValue.c_str(), &p);
      if (*p != '\0') {
        std::cerr << "Error: Could not parse downsample factor '" << strValue << "'." << std::endl;
        return EXIT_FAILURE;
      }
    }
    else if (strCommand == "stream") {
      if (strValue.empty()) {
        std::cerr << "Error: Expected number of streams." << std::endl;
        return EXIT_FAILURE;
      }

      char *p = NULL;
      uiNumStreams = strtoul(strValue.c_str(), &p, 10);
      if (*p != '\0') {
        std::cerr << "Error: Could not parse number of streams '" << strValue << "'." << std::endl;
        return EXIT_FAILURE;
      }
    }
    else {
      std::cout << "Error: Unknown command '" << argv[i] << "'." << std::endl;
      return EXIT_FAILURE;
    }
  }

  const int iFailCode = (bShouldFail ? EXIT_SUCCESS : EXIT_FAILURE);
  const int iSuccessCode = (iFailCode == EXIT_FAILURE ? EXIT_SUCCESS : EXIT_FAILURE);

  std::cout << "Parameters:\n" << std::endl;
  std::cout << "inputImage = '" << p_cInputImage << '\'' << std::endl;
  std::cout << "outputImage = '" << p_cOutputImage << '\'' << std::endl;
  std::cout << "shouldFail = " << std::boolalpha << bShouldFail << std::endl;
  std::cout << "compress = " << std::boolalpha << bUseCompression << std::endl;
  std::cout << "approximateStreaming = " << std::boolalpha << bApproximateStreaming << std::endl;
  std::cout << "stream = " << uiNumStreams << std::endl;
  std::cout << "level = " << iLevel << std::endl;
  std::cout << "associatedImage = '" << strAssociatedImageName << '\'' << std::endl;
  std::cout << "downsample = " << dDownsampleFactor << std::endl;

  ReaderIOType::Pointer p_clImageIO = ReaderIOType::New();
  ReaderType::Pointer p_clReader = ReaderType::New();
  WriterType::Pointer p_clWriter = WriterType::New();

  p_clImageIO->SetFileName(p_cInputImage);

  p_clReader->SetImageIO(p_clImageIO);
  p_clReader->SetFileName(p_cInputImage);

  p_clWriter->SetInput(p_clReader->GetOutput());
  p_clWriter->SetFileName(p_cOutputImage);

  try {
    p_clImageIO->ReadImageInformation();
  }
  catch (itk::ExceptionObject &e) {
    std::cerr << "Error: " << e << std::endl;
    return iFailCode;
  }

  if (strAssociatedImageName.size() > 0)
    p_clImageIO->SetAssociatedImageName(strAssociatedImageName);
  else
    p_clImageIO->SetLevel(iLevel);

  if (dDownsampleFactor > 0.0 && !p_clImageIO->SetLevelForDownsampleFactor(dDownsampleFactor))
    return iFailCode;

  if (uiNumStreams > 0) {
    if (!p_clImageIO->CanStreamRead())
      return iFailCode;

    p_clImageIO->UseStreamedReadingOn();
    p_clImageIO->SetApproximateStreaming(bApproximateStreaming);

    itk::ImageIOBase::Pointer p_clWriterIO = itk::ImageIOFactory::CreateImageIO(p_cOutputImage, itk::IOFileModeEnum::WriteMode);
    if (!p_clWriterIO) {
      std::cerr << "Error: Could not create ImageIO for output image '" << p_cOutputImage << "'." << std::endl;
      return iFailCode;
    }

    if (bUseCompression)
      std::cout << "Warning: Compression may disable streaming." << std::endl;

    p_clWriterIO->UseStreamedWritingOn();

    p_clWriter->SetImageIO(p_clWriterIO);
    p_clWriter->SetNumberOfStreamDivisions(uiNumStreams);
  }

  // XXX: Just so you know, this might disable streaming
  p_clWriter->SetUseCompression(bUseCompression);

  try {
    p_clWriter->Update();
  }
  catch (itk::ExceptionObject &e) {
    std::cerr << "Error: " << e << std::endl;
    return iFailCode;
  }

  // Use this to compress output images when updating tests
  //CompressImageFile(p_cOutputImage);

  return iSuccessCode;
}

Since openslide itself cannot write slide format images, neither can ITKIOOpenSlide. You're unfortunately limited to only reading slide images.

Aha! I remembered coming across the C/C++ library libvips that can write slide images. There's also BioFormats but that's Java. Maybe I could write an ITKIOVIPS or something like that! But I'm already strapped for time and often not even working on pathology projects (I'm working mostly with radiology images these days).

Aha! I remembered coming across the C/C++ library libvips that can write slide images. There's also BioFormats but that's Java. Maybe I could write an ITKIOVIPS or something like that! But I'm already strapped for time and often not even working on pathology projects (I'm working mostly with radiology images these days).

that will be great if there are iovips or iosvs! I have found a repo  use libvips to generate svs, but I don't know how to combine it with itk or itk montage.

Unfortunately, it doesn't look like libvips can write .svs files either.
https://github.com/libvips/pyvips/issues/69
I guess the workaround is to write a pyramidal tiff image. See the issue with code for the workaround.

Aha! I remembered coming across the C/C++ library libvips that can write slide images. There's also BioFormats but that's Java. Maybe I could write an ITKIOVIPS or something like that! But I'm already strapped for time and often not even working on pathology projects (I'm working mostly with radiology images these days).

i build SCIFIO ImageIO successfully, it did not support write svs format surprisingly

writeSCIFIO is not set on i guess in the RunTest so the SetImageIO did not trigger

then i enable write-scifio by running
SCIFIOTestDriver.exe itkSCIFIOImageIOTest e:/data/CMU-1.ndpi e:/data/CMU-1_trans.svs --write-scifio
get some errors in java code, still can not recognize svs format
reader->GetUseStreaming(): 1
done checking streaming usage

itk::ExceptionObject<PHONE_NUMBER>F6EE08)
Location: "unknown"
File: F:\build_io_scifio\src\itkSCIFIOImageIO.cxx
Line: 180
Description: ITK ERROR: SCIFIOImageIO(000001D4EAB1D040): SCIFIOImageIO exited abnormally. Exception in thread "main" loci.formats.UnknownFormatException: Unknown file format: e:/data/CMU-1_trans.svs
        at loci.formats.ImageWriter.getWriter(ImageWriter.java:158)
        at loci.formats.ImageWriter.setId(ImageWriter.java:462)
        at io.scif.itk.SCIFIOITKBridge.write(SCIFIOITKBridge.java:555)
        at io.scif.itk.SCIFIOITKBridge.executeCommand(SCIFIOITKBridge.java:203)
        at io.scif.itk.SCIFIOITKBridge.executeCommand(SCIFIOITKBridge.java:115)
        at io.scif.itk.SCIFIOITKBridge.waitForInput(SCIFIOITKBridge.java:90)
        at io.scif.itk.SCIFIOITKBridge.executeCommand(SCIFIOITKBridge.java:170)
        at io.scif.itk.SCIFIOITKBridge.main(SCIFIOITKBridge.java:774)


Add NGINX Support for Auth Listener

Have gone with email auth for now but we can add an http server later. I can't find any VSA webhooks anyway so there is only the auth to listen for.

Hello again.
I don't know if it will give you any help on what and how you were thinking to implement it, but I did some google search, copy and past and tweaks and here you are a "sort of working" new VSA_Auth.py working from ../PythonVSA.
U hope it will help... cheers
import configparser
from types import resolve_bases
import requests
import os,sys
import logging
import datetime
import smtplib
from email.mime.text import MIMEText
from email.mime.multipart import MIMEMultipart
from http.server import HTTPServer, BaseHTTPRequestHandler
from http import HTTPStatus
from time import sleep
import re
from imaplib import IMAP4_SSL
import email
import socket
from PythonVSA import Auth

from http.server import HTTPServer, BaseHTTPRequestHandler, SimpleHTTPRequestHandler
import ssl
import requests
import pathlib
import json
from urllib.parse import urlparse, parse_qs
from datetime import datetime, timedelta
import ipaddress

# def start_server():
#     # Setup stuff here...
#     server.serve_forever()

# # start the server in a background thread
# thread.start_new_thread(start_server)

# print('The server is running but my script is still executing!')

# https://gist.github.com/bloodearnest/9017111a313777b9cce5
def _generateSelfSignedCert(hostname, ip_addresses=None, key=None):
    """Generates self signed certificate for a hostname, and optional IP addresses."""
    from cryptography import x509
    from cryptography.x509.oid import NameOID
    from cryptography.hazmat.primitives import hashes
    from cryptography.hazmat.backends import default_backend
    from cryptography.hazmat.primitives import serialization
    from cryptography.hazmat.primitives.asymmetric import rsa

    # Generate our key
    if key is None:
        key = rsa.generate_private_key(
            public_exponent=65537,
            key_size=2048,
            backend=default_backend(),
        )

    name = x509.Name([
        x509.NameAttribute(NameOID.COMMON_NAME, hostname)
    ])

    # best practice seem to be to include the hostname in the SAN, which *SHOULD* mean COMMON_NAME is ignored.
    alt_names = [x509.DNSName(hostname)]

    # allow addressing by IP, for when you don't have real DNS (common in most testing scenarios
    if ip_addresses:
        for addr in ip_addresses:
            # openssl wants DNSnames for ips...
            alt_names.append(x509.DNSName(addr))
            # ... whereas golang's crypto/tls is stricter, and needs IPAddresses
            # note: older versions of cryptography do not understand ip_address objects
            alt_names.append(x509.IPAddress(ipaddress.ip_address(addr)))

    san = x509.SubjectAlternativeName(alt_names)

    # path_len=0 means this cert can only sign itself, not other certs.
    basic_contraints = x509.BasicConstraints(ca=True, path_length=0)
    now = datetime.utcnow()
    cert = (
        x509.CertificateBuilder()
        .subject_name(name)
        .issuer_name(name)
        .public_key(key.public_key())
        .serial_number(1000)
        .not_valid_before(now)
        .not_valid_after(now + timedelta(days=10*365))
        .add_extension(basic_contraints, False)
        .add_extension(san, False)
        .sign(key, hashes.SHA256(), default_backend())
    )
    cert_pem = cert.public_bytes(encoding=serialization.Encoding.PEM)
    key_pem = key.private_bytes(
        encoding=serialization.Encoding.PEM,
        format=serialization.PrivateFormat.TraditionalOpenSSL,
        encryption_algorithm=serialization.NoEncryption(),
    )

    with open('cert_key.pem','w') as keyFile:
        keyFile.write(key_pem.decode('UTF-8'))

    with open('cert_fullchain.pem','w') as fullchainFile:
        fullchainFile.write(cert_pem.decode('UTF-8') + key_pem.decode('UTF-8'))

class Callback_LocalHTTPS(BaseHTTPRequestHandler):
    def do_GET(self):
        print('GET Request received...')
        try:
            oauthcode = parse_qs(urlparse(self.requestline).query)['code'][0].split(' ')[0]

            data={ "grant_type": "authorization_code",
                    "code": oauthcode,
                    "redirect_uri": redirect_uri,
                    "client_id": client_id,
                    "client_secret": client_secret }

            response = requests.post(f"{vsa_uri}/api/v1.0/authorize",data=data)

            try:
                ktoken = json.loads(response.text)
                config['Auth']['access_token'] = ktoken['access_token']
                config['Auth']['token_type'] = ktoken['token_type']
                config['Auth']['expires_in'] = str(ktoken['expires_in'])
                config['Auth']['refresh_token'] = ktoken['refresh_token']

                with open(fullpath, 'w') as configfile:
                    print(f"{config['Auth']['access_token']}")
                    config.write(configfile)

            except Exception as e:
                print(f"No Token found... {e}")

            self.send_response(HTTPStatus.OK)
            self.send_header("Content-Type", "text/html")
            self.end_headers()
            self.wfile.write(b"OAuth2 Token generated... you can go back to terminal...")

            input("Access Token written on 'config.ini', Press <CTRL>+<C> 2 times to exit")
        except:
            print("No code found...\n")
        return

def doInitialAuth(code, config):
    vsa_uri = config['VSA']['vsa_uri']
    client_id = config['VSA']['client_id']
    client_secret = config['VSA']['client_secret']
    authendpoint = vsa_uri + "/api/v1.0/authorize"
    redirect_uri = config['Listener']['redirect_uri']

    r = requests.post(authendpoint, json={
        "grant_type": "authorization_code",
        "code": code,
        "redirect_uri": redirect_uri,
        "client_id": client_id,
        "client_secret": client_secret})
    print("First refresh token:")
    print(r.text)
    if(r.status_code == 400):
        print("An error has occurred")
        print(r.text)
        exit()
    refreshtoken = r.json()['refresh_token']
    print("Got token:")
    print(refreshtoken)
    print("Response code:")
    print(str(r.status_code))
    config['Auth'] = r.json()
    config['Auth']['refreshed_at'] = datetime.datetime.now().strftime("%Y%m%d%H%M")
    with open(fullpath, 'w') as configfile:
        config.write(configfile)
    Auth.doRefresh(refreshtoken)

def getInfobyMail():
    msg = MIMEMultipart('mixed')
    msg['Subject'] = "PythonVSA Authentication"
    msg['From'] = smtp_emailfrom
    msg['To'] = smtp_emailto
    text = f"""\
        Please follow this link to authenticate your new integration:  {urlforuser}

        Once you have authorized you will be redirected to a page that doesn't load/resolve. Copy the address from your address bar and reply to this email with it."""
    msg.attach(MIMEText(text))

    print(f"Trying to connect to {urlforuser}...")
    smtp_server = smtplib.SMTP(smtp_server, smtp_port)
    smtp_server.ehlo()
    smtp_server.starttls()
    smtp_server.ehlo()
    smtp_server.login(smtp_username, smtp_password)
    smtp_server.sendmail(smtp_emailfrom, smtp_emailto, msg.as_string())
    smtp_server.close()

    print(f"Waiting {imap_refresh_interval} seconds to give a chance to respond.")
    sleep(imap_refresh_interval)

    connection = IMAP4_SSL(imap_server, imap_port)
    connection.login(imap_username, imap_password)
    typ, data = connection.select('INBOX')
    typ, data = connection.search(None, '(UNSEEN)')

    if(data == [b'']):
        print(f"No emails found. Checking again every {imap_refresh_interval} seconds.")
        i = 0
        while i < 5:
            i = i + 1
            print(f"Checking {5 - i} more times.")
            sleep(imap_refresh_interval)
            typ, data = connection.search(None, '(UNSEEN)')
            if(data[0] != b''):
                break

    for num in data[0].split():
        typ, data = connection.fetch(num, '(RFC822)')
        try:
            msg = email.message_from_bytes(data[1][1])
        except(IndexError):
            msg = email.message_from_bytes(data[0][1])

        typ, data = connection.store(num, '+FLAGS', '\\Seen')
        pattern = r'https://.*\/\?code(=[\w\d]{34})'
        pattern1 = r'https://.*\/\?code(=[\w\d]{32})'
        try:
            match = re.match(pattern, msg._payload)
            matchraw = re.match(pattern1, msg._payload)
        except(TypeError):
            print("It appears we have a message with a format we can't understand. Deleting.")
            continue
        if(match):
            code = match.group(1)
            code = code.replace("=3D", "")
            connection.close()
            connection.logout()
            doInitialAuth(code, config)
        elif(matchraw):
            connection.close()
            connection.logout()
            doInitialAuth(code, config)
        else:
            print("Didn't find URL. Deleting.")

# from somewhere I forgot and didn't save found on google
def startLocalHTTPSCallback(config):

    ssl_key = pathlib.Path("./cert_key.pem").expanduser()
    ssl_cert = pathlib.Path("./cert_fullchain.pem").expanduser()

    print("Setting Up Local Callback Server...")
    httpHandlerFB = SimpleHTTPRequestHandler

    # server_address = (listen_ip, server_port)
    # httpd = HTTPServer(server_address, httpHandlerFB)
    httpd = HTTPServer((config['Listener']['listen_ip'], int(config['Listener']['listen_port'])), Callback_LocalHTTPS)
    # I can comment out the following line and it'll work
    httpd.socket = ssl.wrap_socket(httpd.socket, keyfile=ssl_key, certfile=ssl_cert, server_side=True)
    print(f"Server started at localhost: {config['Listener']['listen_ip']}")
    httpd.serve_forever()

if __name__ == "__main__":
    #Dev var
    os.environ['OAUTHLIB_INSECURE_TRANSPORT'] = '1'
    logging.getLogger().setLevel(logging.DEBUG)

    # Init config
    config = configparser.ConfigParser()
    fullpath = os.getcwd() + "/PythonVSA/config.ini"
    config.read(fullpath, encoding='utf-8')
    try:
        client_id = config['VSA']['client_id']
        client_secret = config['VSA']['client_secret']
        vsa_uri = config['VSA']['vsa_uri']

        redirect_uri = config['Listener']['redirect_uri']
        listen_ip = config['Listener']['listen_ip']
        listen_port = config['Listener']['listen_port']

        smtp_username = config['Email']['smtp_username']
        smtp_password = config['Email']['smtp_password']
        smtp_emailfrom = config['Email']['smtp_emailfrom']
        smtp_emailto = config['Email']['smtp_emailto']
        smtp_server = config['Email']['smtp_server']
        smtp_port = int(config['Email']['smtp_port'])
        imap_username = config['Email']['imap_username']
        imap_password = config['Email']['imap_password']
        imap_email = config['Email']['imap_email']
        imap_server = config['Email']['imap_server']
        imap_port = int(config['Email']['imap_port'])
        imap_refresh_interval = int(config['Email']['imap_refresh_interval'])

    except(KeyError):
        print("A required variable is missing from the configuration. Please check config.ini. ")
        pass

    print(f"Go to your VSA under System > Server Configuration > OAuth Clients and [+Register Client]")
    print(f"- Choose anything to your 'Client Name', prefer something that will make sense like PythonVSA")
    print(f"- By now, it will work only if you run VSA_Auth.py from your computer, so the 'Redirect_Url' should be https://localhost:8443")
    print(f"- For eMail, use something that is working and you have access and configured in the `config.ini`")
    input(f"When you are ready, please, press <ENTER>")

    urlforuser = vsa_uri + "/vsapres/web20/core/login.aspx?response_type=code&redirect_uri=" + redirect_uri + "&client_id=" + client_id
    print("")
    print("Now, please visit this link and copy the entire resulting URL.")
    print(urlforuser)

    # TODO: This this and configure options to use argparse
    # getInfobyMail()

    # prepare
    print("Generating Temporary SSL Certificates for the local server...")
    _generateSelfSignedCert('localhost')

    startLocalHTTPSCallback(config)


Update prepare_sector_network.py

It's a bit more than just excluding the solid biomass. So some more egon-specific tuning is already included so it is overdue to merge it to our master and follow up with other changes in other feature branches.

The commits look fine, should I test this branch again?

I tested it on our server. should work fine!


Error on unicode character

We were trying to run bias detector on text available here. Bias detector fails because it cannot handle unicode character. The first sentence which fails is:
But to do that, you need facts and data – two things that the British migration debate has lacked this summer.
If I remove the hyphen with an ascii minus sign, it works:
But to do that, you need facts and data - two things that the British migration debate has lacked this summer.
/Users/aman/Work/colab/NewsFrames/bias-detector/bsd/bsdetector/bias.py:186: UnicodeWarning: Unicode equal comparison failed to convert both arguments to Unicode - interpreting them as being unequal
  if w in feat_list:
/Users/aman/Work/colab/NewsFrames/bias-detector/bsd/bsdetector/bias.py:189: UnicodeWarning: Unicode equal comparison failed to convert both arguments to Unicode - interpreting them as being unequal
  if b in feat_list:
/Users/aman/Work/colab/NewsFrames/bias-detector/bsd/bsdetector/bias.py:192: UnicodeWarning: Unicode equal comparison failed to convert both arguments to Unicode - interpreting them as being unequal
  if t in feat_list:
Traceback (most recent call last):
  File "newsframe.py", line 48, in <module>
    csv_normalized_bias_components(sentences)
  File "newsframe.py", line 33, in csv_normalized_bias_components
    print to_csv(compute_normalized_bias_components(s))
  File "newsframe.py", line 20, in compute_normalized_bias_components
    features = bias.extract_bias_features(sentence)
  File "/Users/aman/Work/colab/NewsFrames/bias-detector/bsd/bsdetector/bias.py", line 354, in extract_bias_features
    count = count_phrase_freq(coherence, txt_lwr)
  File "/Users/aman/Work/colab/NewsFrames/bias-detector/bsd/bsdetector/bias.py", line 200, in count_phrase_freq
    if phrase in txt_lwr:
UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 40: ordinal not in range(128)

Also tried handling utf-8 before passing it to bias detector as suggested in readme. However, the error remains, except the error now mentions unicode character differently.
UnicodeEncodeError: 'ascii' codec can't encode character u'\u2013' in position 40: ordinal not in range(128)

I think this might fix the issue:
Try explicitly converting to acsii from utf-8 (so that the external modules can work on them), and tell Python to ignore the unknown characters...
Insert the following line to the "extract_bias_features" function (insert at line 333), and change the following line to reference the 'atext' variable when preserving hyphens:
332    features = OrderedDict()
333    asciitext = text.decode('ascii', 'ignore') # ignore conversion errors between utf-8 and ascii
334    text_nohyph = asciitext.replace("-", " ")  # preserve hyphenated words as seperate tokens

In my limited quick test (only on the sample sentence you posted) it seemed to work...

thanks @cjhutto, @sapraaman let's try again with the new version of BSD.
if it doesn't work, i did figure out the other thing that was making it break, so if we're still having issues:

’ instead of '  \xe2\x80\x99 instead of \x27
search for example for ...bear them out. When you’re...

I noticed this diff:
@@ -330,7 +331,8 @@ liwc_work = ref_lexicons.list('ref_liwc_work')

 def extract_bias_features(text):
     features = OrderedDict()
-    text_nohyph = text.replace("-", " ")  # preserve hyphenated words as seperate tokens
+	acsiitext = text.decode('ascii', 'ignore') # ignore conversion errors between utf-8 and ascii
+    text_nohyph = acsiitext.replace("-", " ")  # preserve hyphenated words as separate tokens
     txt_lwr = str(text_nohyph).lower()
     words = ''.join(ch for ch in txt_lwr if ch not in '!"#$%&()*+,-./:;<=>?@[\]^_`{|}~').split()
     unigrams = sorted(list(set(words)))

ignore means that utf-8 characters that aren't in ascii will be silently dropped.
https://docs.python.org/3/howto/unicode.html#the-string-type

In addition, one can create a string using the decode() method of bytes. This method takes an encoding argument, such as UTF-8, and optionally an errors argument.
The errors argument specifies the response when the input string can’t be converted according to the encoding’s rules. Legal values for this argument are 'strict' (raise a UnicodeDecodeError exception), 'replace' (use U+FFFD, REPLACEMENT CHARACTER), 'ignore' (just leave the character out of the Unicode result), or 'backslashreplace' (inserts a \xNN escape sequence). The following examples show the differences:

I don't think this is what you want. This is probably fine for punctuation that doesn't terminate a sentence. But, I think you would want to correctly handle utf characters by choosing the most appropriate ascii version for everything else. The lexicons used by the algorithm are ASCII so words containing non-ascii characters would not be correctly characterized anyway.

Silently dropping Unicode or UTF-8 characters that are unknown to ASCII is not the ideal solution, but note that "replace" and "backslashreplace" to not resolve the issue.  We might need to look into something like Unidecode to do a translation... which would mean adding another external to our requirements.txt

Yes that makes sense. But in order to handle text with accent or foreign language words, the model would need to be trained with those in the training data.
There are three levels of unicode support:

Code doesn't crash: ignore gets us here
Code maps unicode to ascii and is best effort.
Code handles unicode and gives "correct" answers for texts using foreign characters.

I think we need more diverse training data to get to 3.


Maint: update change log - post release 0.1.5

as title says.

@dipinknair can you add the action to check the changelog before PR merge?

@dipinknair can you add the action to check the changelog before PR merge?

@koubaa  It is there already.


simple-bar-spaces.jsx: Something went wrong...

Macbook Air M1
Mac OS 12.2
Yabai works as expected. simple-bar-data.jsx also works.
How do I fix this?

@Jean-Tinland I'm ready to work on it a submit a pr, just need some directions on where to start :)

Ok, in my case it was fixed by changing default path to yabai from /usr/local/bin/yabai to whatever which yabai showed.

I would like to chime in and say I'm facing the same issue on a M1 mac, and the proposed solution didn't work for me. I know it isn't fully supported but I'd be super happy to contribute as a tester of this awesome bar. :)

@B1T3X try to change it in settings.Js file. I had changed it in index.Jsx and had the same problem


Prisma migrate drops manually created partitioned tables

Bug description
I'm using Prisma ORM for PostgreSQL and trying to partition a couple of my tables so I need modifying my SQL files manually. I used prisma migrate dev --create-only, created partitions tables then ran prisma migrate dev (as this page suggests).
It successfully applies my changes along its own, however after first migration applied the prisma prompts for another migration in which it tries to delete all created tables:
Prisma schema loaded from prisma\schema.prisma
Datasource "db": PostgreSQL database "omnichannel", schema "public" at "localhost:5432"

Applying migration `20220518160933_init`

The following migration(s) have been applied:

migrations/
  └─<PHONE_NUMBER>0933_init/
    └─ migration.sql
√ Enter a name for the new migration: ... init2

new migration contains tries to drop partition tables:
  - You are about to drop the `Customer_18` table. If the table is not empty, all the data it contains will be lost.
  - ...

How to reproduce

Run prisma migrate dev --create-only
Change create SQL file from

-- CreateTable
CREATE TABLE "Customer" (
    "id" TEXT NOT NULL,
    "namespaceId" TEXT NOT NULL,
    "createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP,
    "updatedAt" TIMESTAMP(3) NOT NULL,

    CONSTRAINT "Customer_pkey" PRIMARY KEY ("namespaceId","id")
)

to this:
-- CreateTable
CREATE TABLE "Customer" (
    "id" TEXT NOT NULL,
    "namespaceId" TEXT NOT NULL,
    "createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP,
    "updatedAt" TIMESTAMP(3) NOT NULL,

    CONSTRAINT "Customer_pkey" PRIMARY KEY ("namespaceId","id")
) PARTITION BY HASH ("namespaceId");

CREATE TABLE "Customer_0" PARTITION OF "Customer" FOR VALUES WITH (MODULUS 2, REMAINDER 0);
CREATE TABLE "Customer_1" PARTITION OF "Customer" FOR VALUES WITH (MODULUS 2, REMAINDER 1);

Run prisma migrate dev
See that another migration will be created after first migration has been applied, which will drop just created partition tables:

/*
  Warnings:

  - You are about to drop the `Customer_0` table. If the table is not empty, all the data it contains will be lost.
  - You are about to drop the `Customer_1` table. If the table is not empty, all the data it contains will be lost.
*/

Expected behavior
It should not drop tables that have been created by custom migrations.
Prisma information
model Customer {
  id          String               @default(cuid())
  namespaceId String
  createdAt   DateTime             @default(now())
  updatedAt   DateTime             @updatedAt

  @@id([namespaceId, id])
}

Environment & setup

OS: Windows
Database: PostgreSQL
Node.js version: 16.15.0

Prisma Version
prisma                  : 3.14.0
@prisma/client          : Not found
Current platform        : windows
Query Engine (Node-API) : libquery-engine 2b0c12756921c891fec4f68d9444e18c7d5d4a6a (at<EMAIL_ADDRESS>Migration Engine        : migration-engine-cli 2b0c12756921c891fec4f68d9444e18c7d5d4a6a (at<EMAIL_ADDRESS>Introspection Engine    : introspection-core 2b0c12756921c891fec4f68d9444e18c7d5d4a6a (at<EMAIL_ADDRESS>Format Binary           : prisma-fmt 2b0c12756921c891fec4f68d9444e18c7d5d4a6a (at<EMAIL_ADDRESS>Default Engines Hash    : 2b0c12756921c891fec4f68d9444e18c7d5d4a6a
Studio                  : 0.460.0

That is unfortunately expected behavior of Migrate as long as it does not understand partitioned tables.
You can probably add fake, empty models to your schema file that are ignore in Prisma Client to avoid them being dropped as a workaround:
model Customer_0 {
  @@ignore
}

Let me know if this works.

Let me know if this works.

Thank you for reply however unfortunately it did not work and threw this error:
Error: P3006

Migration `20220523185041_init` failed to apply cleanly to the shadow database.
Error:
db error: ERROR: relation "Customer_0" already exists
   0: sql_migration_connector::validate_migrations
             at migration-engine\connectors\sql-migration-connector\src\lib.rs:272
   1: migration_core::state::DevDiagnostic
             at migration-engine\core\src\state.rs:250

Also in this boat, except we dynamically create/drop partitions.
We have a telemetry table that partitions 12 months into future and 24 months into past resulting in 36 dynamic tables. Older partitions are dropped and moved to an archive.
This means to use prisma migrate it either needs to introspect 36 partitions and add them as tables and update them every time partitions are added/dropped or find some hacky way around it to avoid it trying to drop 36 tables every migration that's created.
Please can we get support for it to ignore partitions in the prisma migrate command? Yes this is a underused feature, but its very common in larger companies and larger databases (the last 3 I've worked at).

Please can we get support for it to ignore partitions in the prisma migrate command?

Open an appropriate feature issue or make sure that an existing one has enough information for us to understand what is really needed for you. Thanks.

I prefer partitioned tables to be ignored automatically. Who wants to write @@ignore for 30-40 tables.

We improved Introspection for partitioned tables in 4.10.0, optimally this would also have a positive impact on this. Please test it and let us know. Thanks!

Please add support for table partitions this is a very used feature

That is unfortunately expected behavior of Migrate as long as it does not understand partitioned tables.
You can probably add fake, empty models to your schema file that are ignore in Prisma Client to avoid them being dropped as a workaround:
model Customer_0 {
  @@ignore
}

Let me know if this works.

☹
What is the state of this?
I really love Prisma, it's the best ORM I've ever seen.
Would be very glad to be able to safely use table partitions with it.
This unsafe behavior (even if it is expected) is really problematic.
Idk if you plan to fully standardize partitions support in Prisma ORM at the moment, but could you try to estimate if it could be possible to, at least, stabilize this drop tables issue within something like 6 months? ^^'

We improved Introspection for partitioned tables in 4.10.0, optimally this would also have a positive impact on this. Please test it and let us know. Thanks!

Oh, sorry!
Would be very glad to "Early adopt" this. Could you tell me more?


Add support for /tpaccept when receiving a /tpahere request

So far every single person who has received a /tpahere request for the first time attempts to use /tpaccept to accept the request. As of now, /tpahere can only be accepted by clicking the chat. Would appreciate this being added sooner than the other requests. Thanks!

oh i forgot to add that this will be high priority then

fixed here https://github.com/0PandaDEV/Nextron/commit/a24ac6162894e545733cff4f510bb9d8fe327cde


vienna-tech:0.1.0

I am submitting

[x] a new package/template
[ ] an update for a package

Description: Explain what the package does and why it's useful.

I have read and followed the submission guidelines and, in particular, I

[x] selected a name that isn't the most obvious or canonical name for what the package does
[x] added a typst.toml file with all required keys
[x] added a README.md with documentation for my package
[x] have chosen a license and added a LICENSE file or linked one in my README.md
[x] tested my package locally on my system and it worked
[x] excluded PDFs or README images, if any, but not the LICENSE

[x] ensured that my package is licensed such that users can use and distribute the contents of its template directory without restriction, after modifying them through normal use.

Thank you :)


ranging frame format with standard MAC layer

Hi @thotro,
I want to try to implement the MAC layer according to the IEEE 802.15.4 standard.
I don't really understand the current frame format for a message.
When we send a message, we call the setData which writes bytes on TX_BUFFER register.
So if i understand well, for now we fill the content of "Data" that we can see on the right of the Figure 31 below ?

That mean when we send a POLL in setting data[0]=POLL we set the first byte of this portion of frame ?

So now according to the figure 34, we need to create this frame using software in order to make the data variable following the structure.
Cheers,
Léopold
EDIT: Finally I found the response for my question... It's in the 11.4 section :-) "The DW1000 transmits data from the TX_BUFFER in a frame with data length as specified in the TFLEN and TFLE fields of the Register file: 0x08 – Transmit Frame Control, inserting the 2-octet FCS as the last two octets of the data payload. The DW1000 will not do any other MAC level transmit processing. So, it is up to the host system software to prepare the correctly formatted frame conforming to the IEEE 802.15.4 standard MAC if this is required."
But I let the message, i think it can be interesting to understand how frame works in the radio protocole !

Yes, that's the plan for MAC: doing it by hand! :-) As you wrote, currently we simply set the TX data buffer, decide on data length according to frame check settings and that's it.
Only a subset of MAC messages needs to be implemented and in general I think its pretty straight forward - luckily the format is not really complex. The driver's "setData()" function should be overloaded to also take an instance of a "MACMessage" (or the like); more specifically one of its concrete sub-types.
In the end we are able to do auto-acknowledgement and frame filtering with it - two really great features.
Just let me know what I can do to assist: First draft, actual programming, code review, testing or maybe nothing at all? ;-)

Here for the general ranging frame format we need to implement too !

Yes we could do that. For the payload portion of MAC we can follow this format (the rest is plain MAC), although it is not part of this figure and we need to process it on the host-system anyway.
Another viewpoint of this issue: I would be curious to see if the payload of these messages corresponds to the messages implemented in the TREK and eval board of Decawave; since there are already requests here on the repo to be capable to mix code/device "vendors" in the future.

yes it’s to meet the IEEE 802.15.4 standard ! « […] The general message format, shown at the top of Figure 3, is the IEEE 802.15.4 standard encoding for a data frame.  […] ». It’s in the « aps013_dw1000_and_two_way_ranging.pdf » page 6 :-)


Easier method of setting

Under Montioring > Diagnostics setting > you can set the AppInsights Key directly which is significantly easier then downloading the JSON template and redeploying.

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

ID: f622e23a-a292-a3a3-3a09-2cd3d8ba3b1d
Version Independent ID: c1da0084-d981-4096-9036-4a6d08fa0f7a
Content
Content Source
Service: application-insights

@goatmale - Thanx for your feedback! I have assigned the issue to the content author to investigate this further.

@amanarneja can you reassign this one to me. I will coordinate with @ramach-msft on getting this issue addressed.

@mrbullwinkle  - Done :) all yours.

#in-process

@goatmale Thank you for your feedback. We have updated the doc to include the following info: For Virtual Machines an alternative to the json based steps above is to navigate in the Azure portal to Virtual Machines > Diagnostic Settings > Sinks > Set send diagnostic data to Application Insights to Enabled and either select an Application Insights account or a specific ikey. Let me know if this addresses your feedback, and I will have them close out this issue? Thanks again!

We are going to close out this issue, but if we missed anything please don't hesitate to open a new issue. Thanks again for helping make our docs better!

#please-close


Add 'has_projects' to the list of valid repo options

Quotting https://developer.github.com/v3/repos/#edit
has_projects  boolean  Either true to enable projects for this
                       repository or false to disable them. Default:
                       true. Note: If you're creating a repository in an
                       organization that has disabled repository
                       projects, the default is false, and if you pass
                       true, the API returns an error.

Coverage increased (+2.2%) to 97.79% when pulling aefdf664746aefe599a2e44d2f2e6a51d908dec4 on smortex:enable-has_projects into d3dc6a526fbfedcdb616d2963cf8e8395201a14f on piotrmurach:master.

Hey Romain,
Thanks for your contribution!
I would say that validating options was a bad choice on my part. The GitHub api is a moving target where options change constantly and keeping things up to date is a chore. So what I would suggest if you could do is to completely remove all the options and checks against them. This will be future proof.

@piotrmurach I can certainly do this.  Do you want it to happen only for the Github::Client::Repos class or for all classes of the gem?


Can't disable Lua lexer through properties

With Scintillua installed in SciTE (Sc1, single file), I can't disable a Lua lexer resetting the property lexer.$(file.patterns.name)=name to the original lexilla lexer.
It seems to me that a recent commit in lexilla https://github.com/ScintillaOrg/lexilla/commit/e4817a112aca6fbf51a513d5d477c6eea7000b63 breaks the Scintillua behavior and a default Lua lexer is always created and set after been called by Lexilla::MakeLexer.
Any suggestions on how to get around this ?

I cannot think of a way to get around this other than removing or renaming lexers/lua.lua.

I'm going to close this because it's a special case of using the statically linked version of SciTE that does not have lexer namespacing. This is ultimately a SciTE/Lexilla issue, not a Scintillua issue because it simply uses the tools Lexilla provides.


Provide Haproxy with Lua support

Issue description
At the moment Haproxy is built without the support of external Lua scripts. I managed to build a Haproxy with Lua support with the following config:
nixpkgs.config.packageOverrides = pkgs : rec {
  haproxy = pkgs.haproxy.overrideDerivation (oldAttrs : {
    buildInputs = oldAttrs.buildInputs ++ [pkgs.lua5_3];
    preConfigure = oldAttrs.preConfigure + ''makeFlags+=" USE_LUA=yes LUA_LIB=${pkgs.lua5_3}/lib LUA_INC=${pkgs.lua5_3}/include"'';
  });
};

Is there interest in having Haproxy with Lua support in nixpkgs? If so, I would like to contribute this as it seems like a nice first-starter.
Technical details

System: (NixOS: nixos-version, Ubuntu/Fedora: lsb_release -a, ...)

16.09.1829.c88e67d (Flounder)

Nix version: (run nix-env --version)

nix-env (Nix) 1.11.7

Nixpkgs version: (run nix-instantiate --eval '<nixpkgs>' -A lib.nixpkgsVersion)

"16.09.1829.c88e67d"

I have no concerns and it seems to be also adopted by other downstream distributions.

The solution I would like to see in general is to by default include all dependencies (or alternatively those used by popular distributions), but allow flags to be passed to disable features.
This way it's possible to first get something working and then in production disable unneeded features.

Implemented by #24380.


Add BSP support to the example repository

This is atop #14, but should not be merged until 2.12.0 is late in release candidates.

Updated based on latest docs.


CNV-46751: Prevent deletion of pod network on Instancetype VM

Backport of https://github.com/kubevirt-ui/kubevirt-plugin/pull/1728
Jira: https://issues.redhat.com/browse/CNV-46751

/lgtm

/cherry-pick release-4.16


QUESTION: React does not appear in the programming languages filter

Why React does not appear in the programming language filter?
Is it a bug?

Hey! React is a framework (not a programming language) in JavaScript (a programming language). Perhaps you can use other filters to filter for React?

Thank You @darensin01 for the quick answer!
Yes, React is a framework and so is Vue. Vue is listed in the programming language filter but React don´t. 😔
I did not find a good way to filter React projects other than filtering by JavaScript or TypeScript and checking each result...

Actually, the programming language filter is based on this:

which can be found on every Github Repo.
Not sure why Vue is listed as a programming language though...
Perhaps you can search for React issues through the Issue label filter?

Thank You for the explanation @darensin01 !
Well... I tried the Issue label filter but It lists a very small number of issues.
I would like to Thank You again for the attention!


Analytics events for open category accordions at location detail pages - subsequent visualization edits

@jbeard4 connect this up, even if it's not connected to the visualization.
@doobneek1 have a go at visualizations.

These have been set up.


fix(Controller): ensure controller colliders scale with custom rigidbody collider

The custom rigid body collider object also needs to be scaled to match
the parent object's scale.

There were the following issues with your Pull Request

Commit: 3279d6f9b0f042e14fac3a3d69520e2eadf1366b
Your subject line is longer than 72 characters

Guidelines are available at https://github.com/thestonefox/SteamVR_Unity_Toolkit

This message was auto-generated by https://gitcop.com

Noticed my problem was fixed 2 days ago, but I think scaling needs to happen if you set the collider yourself. No good way for me to review this yet, so I'll leave it up to you if this is needed or not.

fixed an issue with the PlayerPresence collider too. Appended it on here. Hopefully I didn't screw it up.


GridsearchCV with prescattered data

During a recent debug session with @TomAugspurger we thought that dask-ml could take advantage of data which was pre-scatter:

client.scatter(data, broadcast=True)

Current understanding is that dask-ml will not take advantage of pre-scatter data as the call to KFold will chop up data and not see the cached data on the workers.

Looking at these, I notice we have a different prefix.
from distributed import Client
import dask_ml.model_selection
import numpy as np
from sklearn import svm, datasets

client = Client()
client

iris = datasets.load_iris()

parameters = {'kernel': ['linear', 'rbf'], 'C': [1, 10]}
svc = svm.SVC()
clf = dask_ml.model_selection.GridSearchCV(svc, parameters)

xx = client.scatter(iris.data, broadcast=True)
yy = client.scatter(iris.target, broadcast=True)

clf.fit(iris.data, iris.target)

key = list(clf.dask_graph_)[2]
print(clf.dask_graph_[key])
print(xx.key)

(<function dask_ml.model_selection.methods.cv_split(cv, X, y, groups, is_pairwise, cache)>,
 StratifiedKFold(n_splits=3, random_state=None, shuffle=False),
 'array-b44c3d00069ed183d60844351ba8bd54',
 'array-b87288d64805cff577d3bfad8f4d5829',
 None,
 False,
 True)
'ndarray-b44c3d00069ed183d60844351ba8bd54'

So we have ndarray-<token> for the scatter (from dask / distributed), and array-<token> for the version built by dask-ml.

I would like to see this as well. dask-ml should scatter data after kfold.

I won't be able to work on this now, but if this is not closed by the end of Oct, I'll take a look at this.


Allow few-shot examples for query planner to be read from a file.

This PR moves us towards a configuration-file based approach to customizing Luna behavior for individual customers. Instead of the few-shot planner examples being hardcoded in Python, they can be specified as a YAML file that can be loaded by the app and passed to the Luna planner.
Currently this file is only read by the query-ui app, but if we like this approach, I can do a follow up to incorporate this functionality into the LlmPlanner class directly.
To make this simpler, I also switched up some of the data types being used for planner examples and OpenSearch schema to be Pydantic models so we could get automatic JSON and YAML support. This reduces the amount of ad hoc serialization/deserialization code we need to write.
The idea here is that for a given customer deployment, we would write a (new) lunaconfig.yml file containing the schema and few-shot example query plans, and when running the Luna UI we would point it at this file.

I'm closing this PR in favor of #852 which provides similar customization by modifying a Python file instead, which I like better.


added tool to replace values based on corrections

As promised for "fun": a client-specific kiba-extend transform class that does something similar (plus a little extra, due to other issues that were present in the data)
https://gist.github.com/kspurgin/cd5e8a4ee5f5fef96429ec7fd57c5fc8
(Not offered as a suggestion that you use a kiba-extend transform instead, just as an example of another approach)


Making sure both the landing images have the same dimensions.

I've added 2 extra transparent pixel rows to the top, and compressed the result image.


Performance degradation in SslContextBuilder.build() on Java 11 for mTLS connections

Expected behavior
When we build an SslContext for a Client using SslContextBuilder, no matter the parameters we set for the builder, running it on Java 11 takes 2x or 3x more time than on Java 8.
An average of 30 runs of the below code on Java 8 shows an average of 500 ms, when the same is run on JDK11, it takes up to 1500 ms.
Actual behavior
Ideally Java 11 and Java 8 performance should be similar.
Minimal yet complete reproducer code (or URL to code)
SslContextBuilder sslContextBuilder = SslContextBuilder.forClient()
                    .trustManager(rootCACert)
                    .ciphers(null)
                    .sessionCacheSize(0)
                    .sessionTimeout(0)
                    .sslProvider(SslProvider.OPENSSL) // or SslProvider.JDK, doesn't matter
                    .clientAuth(ClientAuth.REQUIRE);

sslContextBuilder.build();

Netty version
4.1.50.Final, 4.1.64.Final
JVM version (e.g. java -version)
openjdk1.8.0_172, openjdk_11.0.8_11.41.54
OS version (e.g. uname -a)
MacOS 19.6.0 Darwin Kernel

@Ghatage Did you profile where the time is spent ? Also please upgrade to the latest Java8 and Java11 version. It may be that this is related to the fact that TLSv1.3 was only added in later releases.

import io.netty.handler.ssl.ClientAuth;
import io.netty.handler.ssl.SslContextBuilder;
import io.netty.handler.ssl.SslProvider;
import io.netty.handler.ssl.util.InsecureTrustManagerFactory;

import javax.net.ssl.SSLException;

public class Main {

    public static void main(String[] args) throws SSLException {

        long started = System.currentTimeMillis();

        for (int i = 0; i < 100; i++) {
            SslContextBuilder sslContextBuilder = SslContextBuilder.forClient()
                    .trustManager(InsecureTrustManagerFactory.INSTANCE)
                    .ciphers(null)
                    .sessionCacheSize(0)
                    .sessionTimeout(0)
                    .sslProvider(SslProvider.JDK) // or SslProvider.JDK, doesn't matter
                    .clientAuth(ClientAuth.REQUIRE);

            sslContextBuilder.build();
        }

        System.out.println(System.currentTimeMillis() - started);
    }
}

Output: 1515

100 runs on Java 11 took 1515ms.

You should use openjmh for benchmarks otherwise these are not representative.

package bench;

import io.netty.handler.ssl.ClientAuth;
import io.netty.handler.ssl.SslContextBuilder;
import io.netty.handler.ssl.SslProvider;
import io.netty.handler.ssl.util.InsecureTrustManagerFactory;
import org.openjdk.jmh.annotations.Benchmark;
import org.openjdk.jmh.annotations.BenchmarkMode;
import org.openjdk.jmh.annotations.Mode;
import org.openjdk.jmh.annotations.Scope;
import org.openjdk.jmh.annotations.State;
import org.openjdk.jmh.annotations.Warmup;
import org.openjdk.jmh.runner.Runner;
import org.openjdk.jmh.runner.RunnerException;
import org.openjdk.jmh.runner.options.Options;
import org.openjdk.jmh.runner.options.OptionsBuilder;

import javax.net.ssl.SSLException;

@State(Scope.Benchmark)
@BenchmarkMode(Mode.All)
@Warmup(iterations = 5)
public class Main {

    public static void main(String[] args) throws RunnerException {
        Options opt = new OptionsBuilder()
                .include(Main.class.getSimpleName())
                .build();

        new Runner(opt).run();
    }

    @Benchmark
    public void benchmark() throws SSLException {
        SslContextBuilder sslContextBuilder = SslContextBuilder.forClient()
                .trustManager(InsecureTrustManagerFactory.INSTANCE)
                .ciphers(null)
                .sessionCacheSize(0)
                .sessionTimeout(0)
                .sslProvider(SslProvider.JDK)
                .clientAuth(ClientAuth.REQUIRE);

        sslContextBuilder.build();
    }
}

Output:
Benchmark                           Mode      Cnt      Score      Error  Units
Main.benchmark                     thrpt       25  51754.424 ± 1542.800  ops/s
Main.benchmark                      avgt       25     ≈ 10⁻⁵              s/op
Main.benchmark                    sample  6570048     ≈ 10⁻⁵              s/op
Main.benchmark:benchmark·p0.00    sample              ≈ 10⁻⁵              s/op
Main.benchmark:benchmark·p0.50    sample              ≈ 10⁻⁵              s/op
Main.benchmark:benchmark·p0.90    sample              ≈ 10⁻⁵              s/op
Main.benchmark:benchmark·p0.95    sample              ≈ 10⁻⁵              s/op
Main.benchmark:benchmark·p0.99    sample              ≈ 10⁻⁵              s/op
Main.benchmark:benchmark·p0.999   sample              ≈ 10⁻⁴              s/op
Main.benchmark:benchmark·p0.9999  sample              ≈ 10⁻⁴              s/op
Main.benchmark:benchmark·p1.00    sample               0.004              s/op
Main.benchmark                        ss        5      0.001 ±    0.001   s/op

@hyperxpro Can you also please do a diff with JDK8 ?

Benchmark        Mode  Cnt       Score      Error  Units
Main.benchmark  thrpt   25  136732.943 ± 8462.465  ops/s

openjdk version "1.8.0_292"
OpenJDK Runtime Environment Corretto-8.292.10.1 (build 1.8.0_292-b10)
OpenJDK 64-Bit Server VM Corretto-8.292.10.1 (build 25.292-b10, mixed mode)

Well, Java 11 is almost 3x slower.
@normanmaurer Is it some sort of regression or something?

@hyperxpro no idea... I will check that said I have some other more pressing things to do atm and as the context should not build frequently I don'T think its a super urgent thing. If you feel like it attach a profiler and check where the time is spent.

Cool, Lemme try to tackle this.

as the context should not build frequently

@normanmaurer we uncovered this through a use case where a client that uses netty to connect to a large number of clusters. We started to see SSL connection timeouts and further debugging led to finding this.
@hyperxpro Thanks for benchmarking. Do let me know if you need assistance, we're keen on getting this as performant on JDK11 as it is on JDK8.

@normanmaurer we uncovered this through a use case where a client that uses netty to connect to a large number of servers. We started to see SSL connection timeouts and further debugging led to finding this.

@Ghatage even with this use case you should create one SslContext and share it between the clients.

@normanmaurer In Gatling, we simulate lots of virtual users and each must have its own SslContext to generate the correct number of SSLSessions. So there's a use case :)

@slandelle I am not saying there is no use-case but that it is limited :) And if there is an issue its not a regression but something that exists "forever". That said I agree we should try to fix it but I am not sure how fast I can spend time on this.

My use case is super exotic. I'll try to investigate as soon as I can find some time to.

Actually there is another use case noticed by @mpnikhil.
In most places for security purposes, certificates are rotated on a routine basis.
Each one of those would require re-loading the new certs and building a new context. So it's not like once we create a context we're done.
Although not as intensive, its still a drag which would apply to most non-specific use cases IMO.

@Ghatage yep... that said I think I would do this with a KeyManager implementation that can reload certs.

Anyone did investigate this yet ?

Well, this one fell off my radar. I will get back by this weekend with some updates.

After some JMH based debugging, I'm confident enough to say something is wrong with Java KeyStore and TrustManager modules.
Without specifiying TrustManager:
    @Benchmark
    public void benchmark() throws SSLException {
        SslContextBuilder sslContextBuilder = SslContextBuilder.forClient()
//                .trustManager(InsecureTrustManagerFactory.INSTANCE)
                .ciphers(null)
                .sessionCacheSize(0)
                .sessionTimeout(0)
                .sslProvider(SslProvider.JDK)
                .clientAuth(ClientAuth.REQUIRE);

        sslContextBuilder.build();
    }

Iteration   1: 4861.249 ops/s
Iteration   2: 5818.805 ops/s
Iteration   3: 5870.319 ops/s
Iteration   4: 4974.623 ops/s
Iteration   5: 5150.790 ops/s

---------------------------
Using InsecureTrustManagerFactory:
    @Benchmark
    public void benchmark() throws SSLException {
        SslContextBuilder sslContextBuilder = SslContextBuilder.forClient()
                .trustManager(InsecureTrustManagerFactory.INSTANCE)
                .ciphers(null)
                .sessionCacheSize(0)
                .sessionTimeout(0)
                .sslProvider(SslProvider.JDK)
                .clientAuth(ClientAuth.REQUIRE);

        sslContextBuilder.build();
    }

Iteration   1: 32064.983 ops/s
Iteration   2: 46749.689 ops/s
Iteration   3: 46800.643 ops/s
Iteration   4: 47705.184 ops/s
Iteration   5: 47665.037 ops/s

@normanmaurer PTAL

Well we just set the TrustManagerFactory and thats it in this scenario. You will need to attach a profiler to understand where all the time is spent. I suspect its inside some JDK internals.


Postal code prefixes for Puerto Rico and Slovenia don't match what's in the format

https://i18napis.appspot.com/address/data/PR has the prefix listed as "PR", according to the format string and online guidelines, it should be "PR ".
https://i18napis.appspot.com/address/data/SI has the prefix listed as "SI-" but the format uses "SI- ", I was unable to confirm which is preferred.

Yes, "PR " is correct, but that's not what the dataset has, it has "PR".
See: https://www.gstatic.com/chrome/autofill/libaddressinput/chromium-i18n/ssl-address/data/PR

@vwmax Can this be reopened? postprefix for PR is currently PR, but I think it should be PR  (with a space).

Reopened. Taking another look. Will circle back.


Support ansible --diff option

For easier diff generation I moved all cluster configuration gathering from *_need_update to separate method get_topic_config. I tried to preserve checks logic, the only major change is in replication factor check.
Didn't add diff for ACL resources, as they are not updated, but added/deleted only.

Rebased on current master

Thanks! I will review your PR before the end of the week.


[dev/flutter2] Web doesn't support screen sharing

Describe the bug
Documentation hints that screen sharing is supported for web, but when trying to start screen sharing an exception is thrown.
To Reproduce
Run the screen share example. Try to share the screen.
Expected behavior
An exception is thrown:
Error: PlatformException(ErrorCode.NotSupported, null, null, null)
at Object.throw_ [as throw] (http://localhost:57109/dart_sdk.js:5041:11)
at rtc_engine.RtcEngine.__.startScreenCaptureByWindowId (http://localhost:57109/packages/agora_rtc_engine/src/rtc_engine_extension_web.dart.lib.js:2899:17)
at video_call._State.new._startScreenShare (http://localhost:57109/packages/buzz_flutter/src/pages/video_call.dart.lib.js:991:22)
at _startScreenShare.next ()
at http://localhost:57109/dart_sdk.js:37403:33
at _RootZone.runUnary (http://localhost:57109/dart_sdk.js:37274:59)
at _FutureListener.thenAwait.handleValue (http://localhost:57109/dart_sdk.js:32530:29)
at handleValueCallback (http://localhost:57109/dart_sdk.js:33057:49)
at Function._propagateToListeners (http://localhost:57109/dart_sdk.js:33095:17)
at _Future.new.[_completeWithValue] (http://localhost:57109/dart_sdk.js:32943:23)
at async._AsyncCallbackEntry.new.callback (http://localhost:57109/dart_sdk.js:32964:35)
at Object._microtaskLoop (http://localhost:57109/dart_sdk.js:37526:13)
at _startMicrotaskLoop (http://localhost:57109/dart_sdk.js:37532:13)
at http://localhost:57109/dart_sdk.js:33303:9
Desktop (please complete the following information):
Chrome / web

Got it working.


Add UV sensor family si114x

Code based on the UPM project, following the datasheet
specification for the si1145/6/7 products, it does NOT
the datasheet for the si1141/2/3, that are completely
different products with the same family name.
differences from v3: i2c api completely modified, had to rework almost everything.
Signed-off-by: Tomaz Canabrava<EMAIL_ADDRESS>

Fixes done on top on PR #1938

PR #1938 was merged.


Migrate back to chromium-edge-launcher since Windows fix was merged

Summary:
The Windows fix was merged and published. We no longer need to use the fork.
Changelog:
[INTERNAL] [FIXED] - Fix experimental debugger launch flow with Edge on Windows
Test Plan:
n/a

cc @acoates-ms

@motiz88 Any idea why this was backed out?

Yeah, there was an issue with our internal Flow config referencing the old libdef file name. I'll fix and reland.


Progress callback?

Is there a way to set a "progress callback function" either before or when invoking CImageResizer::resizeImage()?
I would like to show a progress control in my program while AVIR is resizing a large image. Went looking for a callback in AVIR that would indicate progress while resizing, can't see anything.
Is there a progress reporting method available?
Thanks!

Sorry, no such callback is available, and it's not planned for implementation as even a very large images usually resize in less than a second on a modern processor.

Thanks Aleksey!
I am getting about 1.8 seconds to scale images on the order of 15000x15000 image down to 2160x2160.
This is on a Ryzen 3600X with RAM at 3200.
Is this slow? Your answer suggests it should be faster. Perhaps I am doing something wrong...

Are you using multi-threading? But even if not, 1.8 seconds is not exactly much to justify adding a progress indication.

I am not using multithreading. Didn't know I could. I will look at that.
The 1.8 seconds is very subjective. I think your AVIR software is fast and the image quality is superior. Some people who have tested my program tell me the 1.8 seconds is enough that they would feel better with a progress bar rather than just a Windows hour glass indicator. But it's not very very important feature. If I can cut the time by 2 or 4 times using more cores that will be perfect.
Thanks again!

Used your Multithreading How To doc and added multithreading to the resize. Very nice, 4 threads, cut the time to about 30% of single thread.
This is a very elegant library you've made here. Your thread pool concept implementation is very nice.


Cross build with Scala 2.11.8 and 2.12.0

Workaround a Scala 2.12.0 compiler bug in the fields phase
by adding a type annotation.
Update to recent versions of dependencies
Remove a rule for the experimental Akka streams API. This rule and
test need to be reworked for the stable release of Akka streams as
the API has changed.
Enable cross building using sbt-doge. This is needed because we have
a SBT plugin subproject, which must be build once only with Scala
2.10 even when cross building the rest with 2.11/2.12.
The magic incantation is sbt -J-Xmx2G ';+test;+publishLocal'.
Enable cross building in the Travis CI config, using a suitable
JDK in each case.

Review by @SethTisue

outstanding!

Fixes #74 #79

Compiler regression lodged as: https://github.com/scala/scala-dev/issues/268


[TC-338] Raw remap text for mid tier server

Right now for each Delivery Service there is a spot for "Raw remap text". Right now it only applies this text to edges. We also need to ability to apply this to the mid tier caches too
moved from https://github.com/Comcast/traffic_control/issues/1543
Author: Dan Kirkwood
JIRA Link: https://issues.apache.org/jira/browse/TC-338

originally filed by @jpappa200 -- no clear need for this feature.   If needed by someone, a new issue should be created with background info.