🐛 Strange bug with pasting sudo password via SSH on Linux 🐧

Windows Terminal version
1.15.2713.0
Windows build number
10.0.22621.608
Other Software
kmatuszak@ubuntu:~$ bash --version
GNU bash, version 5.0.17(1)-release (x86_64-pc-linux-gnu)

kmatuszak@ubuntu:~$ sudo -V
Sudo version 1.8.31
Sudoers policy plugin version 1.8.31
Sudoers file grammar version 46
Sudoers I/O plugin version 1.8.31

kmatuszak@ubuntu:~$ ssh -V
OpenSSH_8.2p1 Ubuntu-4ubuntu0.5, OpenSSL 1.1.1f  31 Mar 2020

kmatuszak@ubuntu:~$ uname -r
5.15.0-48-generic

kmatuszak@ubuntu:~$ lsb_release -sd
Ubuntu 20.04.5 LTS

Steps to reproduce

Connect to an Ubuntu server with password set to HtJy*&fPMS4@K84C$RJfFT9*$#SR4E52 via SSH using Windows Terminal
Authenticate using your username and password by pasting the password, this will work fine
Try to run any sudo command which will ask for your sudo password, for example: sudo apt update && sudo apt upgrade -y
Paste your sudo password either by CTRL+V or CTRL+SHIFT+V

Expected Behavior
Password should be accepted, but it is not:
kmatuszak@ubuntu:~$ sudo apt update && sudo apt upgrade -y
[sudo] password for kmatuszak:
Sorry, try again.
[sudo] password for kmatuszak:

Actual Behavior
Password is not accepted either if pasted by CTRL+V or CTRL+SHIFT+V, but it works fine when typed by hand. Also password is accepted just fine if pasted in PuTTY. Other passwords also work just fine if pasted in Windows Terminal. The same password works just fine for initial authentication when connecting to an SSH server, but not for authenticating when running sudo.

In my case Ctrl-V pasted the first password symbol, Ctrl-Shift-V and Shift-Insert full password.
In /etc/sudoers Defaults pwfeedback to view typed password as asterics. Try Shift-Insert

I'm having the exact same issue with the Windows Terminal Preview (1.16.2642.0) since 2 weeks.
It's intermittent, I have more sucess with the right click, in the shell, right click will paste the correct password, but the not with the sudo prompt.
Same pwd works with remmina from the same WSL2 Ubuntu.

If you paste the password into just the normal prompt, does it appear as you'd expect?
I'm wondering if this is related to an issue I'm seeing with 1.15.2712.0 where the content I'm pasting is randomly being encased with other special formatting.
E.g. in one program, copying the text br256 turns into ^[[200~br256^[[201~
This only started happening in the last week or so and doesn't happen with the preview release 1.16.2641.0 (or at least I'm not triggering some big to cause it to happen)
Essentially what I'm getting at is when you paste the copied password, is it inserting extra text unknowingly?

It is not pasting any extra text, the password appears at is should. As I said, pasted password works fine for initial authentication when connecting to the ssh server, but not for authenticating in sudo.

Any news on this? Either an ETA or some mitigation steps? Windows Terminal is basically useless with ssh in this state.

Those of you that are seeing pasted text surrounded by ^[[200~ and ^[[201~, that is because your shell (or perhaps some application or plugin) has enabled bracketed paste mode.
This might be the OP's problem too. When you're attempting to connect to the server, bracketed paste mode assumedly wouldn't be enabled, so you could paste the password without any problem. But if something enables bracketed paste mode after you've logged in, then any future attempt to paste the password could fail. You can probably confirm that by trying to paste into showkey -a since that'll show you any escape sequences surrounding the text.
You can try manually disabling bracketed paste mode by executing printf "\e[?2004l". Although that assumes there isn't something in your shell that is constantly re-enabling that mode.

Those of you that are seeing pasted text surrounded by ^[[200~ and ^[[201~, that is because your shell (or perhaps some application or plugin) has enabled bracketed paste mode.
This might be the OP's problem too. When you're attempting to connect to the server, bracketed paste mode assumedly wouldn't be enabled, so you could paste the password without any problem. But if something enables bracketed paste mode after you've logged in, then any future attempt to paste the password could fail. You can probably confirm that by trying to paste into showkey -a since that'll show you any escape sequences surrounding the text.
You can try manually disabling bracketed paste mode by executing printf "\e[?2004l". Although that assumes there isn't something in your shell that is constantly re-enabling that mode.

Disabling bracketed paste does solve the issue, at least for the current ssh session. I wonder why I never had this problem before with Windows Terminal.

@Gliptal I don't know much about Linux, so I'm not speaking with any authority here, but I've been doing some reading, and it appears that Bash and the GNU Readline library have recently (in the last year or two) enabled bracketed paste mode by default (see here).
So my theory is that maybe your home system has recently got the new Bash or Readline that enables bracketed paste (and thus is perfectly capable of parsing pasted strings with the bracketing escape sequences). However, the system that you ssh into may still have an older version of Readline, so it isn't expecting those bracketed escape sequences, and doesn't know to strip them.
If that's the case, the solution may just be to disable bracketed paste mode on your home system. Otherwise it's possible you could also fix the issue by enabling it on the remote system (assuming it's already supported there but just not enabled by default).

@j4james

You can try manually disabling bracketed paste mode by executing printf "\e[?2004l". Although that assumes there isn't something in your shell that is constantly re-enabling that mode.

Thanks, it seem to work on my side, I tried the bind method for the current session and it didn't work. (bind 'set enable-bracketed-paste off')
But adding this set enable-bracketed-paste off to my $HOME/.inputrc and then closing and re-opening a new terminal worked.. 👍👍

Moving some notes:

In this particular case I might be able to help with one fact: The host I'm seeing this issue on (the Brocade ICX6610 switch) hasn't had a firmware update for years. It did not used to default to bracketed paste, but now it seems to. I would suggest this is something that has just changed recently (i.e. in the last few months) in either WT, PSReadLine or OpenSSH?
Edit: Further to that, it still works without defaulting to bracketed paste once SSH'd in, if I connect via Putty rather than WT.

@SteveL-MSFT, did y'all recently light up bracketed paste support or somesuch? If so... is it being turned off before process launch? We're seeing an increase in reports of an issue where it's on in places where it shouldn't be.
(Just spitballing, nothing conclusive yet)

@j4james
Something strange is still going on. the set enable-bracketed-paste off to my $HOME/.inputrc seem to work only in the first instance of my terminal, If I open a new instance as a tab in the terminal then the problem is back! this makes no sense at all.
This bug is so weird...

Could one (or many!) of you share a repro with the debug tap enabled + script running? Please note that this will capture any data you type into Terminal and any data that comes back out of the application.

Enable the terminal debug tap and launch a terminal with it open.

This will capture all I/O from the Terminal side into a split pane.

In bash, run script

This will capture all I/O from the client application side into a file named typescript.

Reproduce the issue
exit from inside bash-inside-script
Share the typescript file and the backlog from the split debugging pane, either here or via private e-mail to the address on my GitHub profile

This may help us in pinning down exactly where in the stack the issue is.
Thanks!

Since my initial comment I've only experienced this maybe twice since, with daily 9-5 use of Terminal across multiple remote SSH servers.
Using the command someone had posted previously to turn off bracket mode manually with the printf command did work for me.
I haven't figured out what the pattern is to trigger this, which makes it near impossible to reproduce on command unfortunately.

For those of you that are getting this problem intermittently, it may be because you've run some application that has re-enabled bracketed paste mode. More specifically, I've seen reports of this issue with the Midnight Commander editor mcedit. If that's your problem (i.e. you're using mcedit), there's a stackoverflow answer with a hack for working around the issue. That's from several years ago, though, so I'm not certain it still applies.

Were we the murderer? wsl showkey -a run from a CMD tab, or a pwsh tab, with a Ubuntu-18.04 default distro all get bracketed paste sequences. Hmm.

Hmmm
diff --git a/src/terminal/adapter/adaptDispatch.cpp b/src/terminal/adapter/adaptDispatch.cpp
index 549d4b3f3..400096db0 100644
--- a/src/terminal/adapter/adaptDispatch.cpp
+++ b/src/terminal/adapter/adaptDispatch.cpp
@@ -978,23 +978,7 @@ bool AdaptDispatch::_SetInputMode(const TerminalInput::Mode mode, const bool ena
     // impact on the actual connected terminal. We can't remove this check,
     // because SSH <=7.7 is out in the wild on all versions of Windows <=2004.

-    // GH#12799 - If the app requested that we disable focus events, DON'T pass
-    // that through. ConPTY would _always_ like to know about focus events.
-
-    return !_api.IsConsolePty() ||
-           !_api.IsVtInputEnabled() ||
-           (!enable && mode == TerminalInput::Mode::FocusEvent);
-
-    // Another way of writing the above statement is:
-    //
-    // const bool inConpty = _api.IsConsolePty();
-    // const bool shouldPassthrough = inConpty && _api.IsVtInputEnabled();
-    // const bool disabledFocusEvents = inConpty && (!enable && mode == TerminalInput::Mode::FocusEvent);
-    // return !shouldPassthrough || disabledFocusEvents;
-    //
-    // It's like a "filter" left to right. Due to the early return via
-    // !IsConsolePty, once you're at the !enable part, IsConsolePty can only be
-    // true anymore.
+    return !_api.IsConsolePty() || !_api.IsVtInputEnabled();
 }

Probably because you're using a debug build which uses the debug allocator that sets these fields to 0xCD by default to indicate uninitialized memory. These fields were never initialized since their introduction which might help explain various bugs, as their initial value in Release builds is then entirely random/undefined. Nice find!

Yikes, apologies to all the innocent shells I was assuming were to blame for this. Maybe this is a good time to move towards initializing everything in the class header, which I think might help avoid issues like this (see CPPCoreGuidelines).

Hmm... I think something is messed up with our WinRT AuditMode... If you put this:
struct MyStruct
{
    int value;
    MyStruct() {} // C26495, MyStruct::value is uninitialized
};

Anywhere into the AtlasEngine project for instance and run an AuditMode it'll produce a C26495 error. If you do the same in Terminal.cpp no error pops up. I'm trying to figure out why that happens, but if anyone got a good guess, let me know!

https://github.com/microsoft/terminal/blob/62b34cf6f77199df306999f89a5f57368cfa5059/src/cascadia/TerminalCore/lib/terminalcore-lib.vcxproj#L21
Uh...

$(SolutionDir)src\cascadia\TerminalCore

Oh...

But even with that fixed, it still doesn't catch this bug for the Terminal class in particular, which is kind of weird.

This should have been fixed by #14345, no?


TravisCI - Specify required android components and enable caching to speed up build

I will use this branch to setup CI. Some of the builds are failed because of emulator taking long time to start.
I have explicitly specified some components, emulator image and version of build tools and android SDK.
cc @aleffert @nasthagiri @shahidtamboli

@aleffert Android tests now run on Travis with Android-16.
We need to input one user account (email and password) in unit tests, so should we add that to the config or let it be in the unit tests? Please suggest.
JIRA: https://openedx.atlassian.net/browse/MOB-1272

@rohan-dhamal-clarice awesome to see this. I'm a little confused though. Are unit tests actually connecting to the production server? They should be running against mock network data (for some options see http://stackoverflow.com/questions/393099/mocking-http-server and if they already are doing that, then obviously don't worry about it).
If we are using stubbed network responses, we can use a made up username/password and just stick it in with the test data. Since it's not a real account, it won't matter that it's included. It might make sense to just use one standard test account for consistency, in which case we could make a test config and add it to that. Alternately Config has a constructor that takes an in memory map and we could use that too.

@aleffert We don't use mocked network data at the moment but I will change the test cases to use it. In that case we will not require anything from the Config.

@aleffert I will update tests to use mocked server on another branch and merge this PR.


ob run: doesn't respect the port in config/common/route

Changing the port in config/common/route has no effect:
Backend running on port 50469
Port 8000 is being used by process ID 16492. Please kill that process or change the port in config/common/route.

I believe #7 fixes this.

Closing as invalid because I just understood that this is by design.
We should instead of have something like ob run -p ... to change the local server's port.


How to install plugins with pip?

With awscli v1 installed with pip, you can simply pip install the plugin.
With awscli v2 installed with homebrew, you can install a plugin with the bundled pip:
/usr/local/opt/awscli/libexec/bin/pip install awscli-plugin-endpoint

However, is it possible to install a plugin for awscli installed with this asdf plugin? I don't see any bundled pip.

Short answer, yes it's possible. Longer answer, it depends and homebrew is using a different method that makes supporting plugins easier.
In https://github.com/asdf-vm/asdf-plugins/issues/222 we discussed whether for v2 to build from source (which is what homebrew is doing, and how it gets a bundled pip) or use the prebuilt binaries that come with all batteries included. We opted to go the latter route as relying on a recent python available on the system path can come with other challenges.
The good news is that with v2, I don't think that matters. According to https://awscli.amazonaws.com/v2/documentation/api/latest/topic/config-vars.html#plugins and https://github.com/wbingli/awscli-plugin-endpoint/issues/15, you should be able to install plugins using the --no-deps option with your regular python/pip (whether that's ASDF managed or not) and simply point ~/.aws/config to your plugin. For example:
$ pip install --no-deps awscli-plugin-endpoint
$ pip show awscli-plugin-endpoint

Name: awscli-plugin-endpoint
Version: 0.4
Summary: Endpoint plugin for AWS CLI
Home-page: https://github.com/wbingli/awscli-plugin-endpoint
Author: Wenbing Li
Author-email<EMAIL_ADDRESS>License: UNKNOWN
Location: /home/metricmike/.asdf/installs/python/3.9.6/lib/python3.9/site-packages
Requires: awscli
Required-by:

so my ~/.aws/config should look like:
$ cat ~/.aws/config

[default]
region = us-east-1
output = json

[plugins]
cli_legacy_plugin_path = /home/metricmike/.asdf/installs/python/3.9.6/lib/python3.9/site-packages
endpoint = awscli_plugin_endpoint

I don't think it matters if the awscli python version (currently 3.8 for 2.2.22) and the plugin python version (3.9.6 in this example) matter, but it's something to be aware of.
For v1, I would probably recommend not using this tool, as all I'm doing is creating a virtualenv and pip installing awscli there (see https://github.com/MetricMike/asdf-awscli/blob/main/lib/utils.bash#L107-L114).


[fireabase_auth] ERROR_REQUIRES_RECENT_LOGIN has more precedence than ERROR_EMAIL_ALREADY_IN_USE.

ERROR_REQUIRES_RECENT_LOGIN has more precedence than ERROR_EMAIL_ALREADY_IN_USE.
I tried to change the email of the user with another user's email, as a test, and I got ERROR_REQUIRES_RECENT_LOGIN which would take the user to new login process, just later to find out that other email he probably has is already in use. I believe It would be more correct if ERROR_EMAIL_ALREADY_IN_USE had more precedence.

Consolidating under #1223 - we'll be looking at parsing native error messages & codes and bubbling these up to the Dart layer in a consistent cross-platform format.


Fix and un-ignore test, install IPFS on Travis

This test depends on IPFS so it was ignored, install IPFS on Travis so we can run it on CI.

Alright, tests have passed. This is good to go.

@Jannis Since Travis was getting stuck specifically on this test, I'm worried that it might be flaky, I'll try to improve it and see if Travis succeeds consistently.

Removed uses of wait which is always suspicious, all green, hopefully it wasn't just chance and the flakiness is gone.


Question: any way to set registry proxy for sealos build？

Detailed description of the question.
Some charts with gcr images in operators can't be built without a registry proxy.
Some reference materials you see.
No response

HTTP_PROXY=socket5://<IP_ADDRESS>:7890 SEALOS_REGISTRY_SYNC_EXPERIMENTAL=true sealos build xxxxx
using main sealos version

https://github.com/containers/skopeo/issues/1433

That does work! Maybe we need to improve the documentation about this.


Cannot start service cadvisor: listen tcp <IP_ADDRESS>:9093: bind: address already in use

Hi,
dockprom was working fine in our server, but now, after rebooting the PC and pushing the last commits, I have this:
user@server:~/monitoring/dockprom$ ADMIN_USER=admin ADMIN_PASSWORD=admin docker-compose up -d
Creating network "dockprom_monitor-net" with driver "bridge"
Creating cadvisor     ... error
Creating nodeexporter ...
Creating caddy        ...
Creating grafana      ...
Creating caddy        ... error
Creating pushgateway  ...
Creating nodeexporter ... done

Creating grafana      ... done
Creating prometheus   ... done
Creating pushgateway  ... done
Creating alertmanager ... done

ERROR: for caddy  Cannot start service caddy: driver failed programming external connectivity on endpoint caddy (41431f8005c71d44b06a8525eb40508791abf0f37982e01d8c89a75f2dd8185d): Error starting userland proxy: listen tcp <IP_ADDRESS>:9093: bind: address already in use

ERROR: for cadvisor  Cannot start service cadvisor: error while creating mount source path '/var/lib/docker': mkdir /var/lib/docker: read-only file system
ERROR: Encountered errors while bringing up the project.

more info:
user@server:~/monitoring/dockprom$ docker ps -a
CONTAINER ID        IMAGE                        COMMAND                  CREATED             STATUS              PORTS               NAMES
5bfe75a2d7dd        grafana/grafana:6.2.5        "/setup.sh"              58 seconds ago      Up 56 seconds       3000/tcp            grafana
fc043e7d576f        prom/alertmanager:v0.18.0    "/bin/alertmanager -…"   58 seconds ago      Up 53 seconds       9093/tcp            alertmanager
ad185595a0dd        prom/pushgateway:v0.9.0      "/bin/pushgateway"       58 seconds ago      Up 54 seconds       9091/tcp            pushgateway
d4f7715d661e        stefanprodan/caddy           "/sbin/tini -- caddy…"   58 seconds ago      Created                                 caddy
df1aad89f777        prom/prometheus:v2.11.1      "/bin/prometheus --c…"   58 seconds ago      Up 55 seconds       9090/tcp            prometheus
95811735cb09        prom/node-exporter:v0.18.1   "/bin/node_exporter …"   58 seconds ago      Up 56 seconds       9100/tcp            nodeexporter
f1a0dbc3a3a5        google/cadvisor:v0.33.0      "/usr/bin/cadvisor -…"   58 seconds ago      Created             8080/tcp            cadvisor

It looks to me like you have modified your docker-compose.yml to expose caddy to port 9093 on the host and that port appears to already be in use.
Can you paste your full docker-compose.yml and the output of sudo lsof -i :9093?

Thank you @nightah  for your feedback,
It's strange, because my docker-compose.yml was not modified as you can see in my git status:
On branch master
Your branch is up to date with 'origin/master'.

Untracked files:
  (use "git add <file>..." to include in what will be committed)

        run.sh

nothing added to commit but untracked files present (use "git add" to track)

I've just added a bash script containing:
ADMIN_USER=admin ADMIN_PASSWORD=admin docker-compose up -d

Here's the contents of my docker-compose:
cat docker-compose.yml
version: '2.1'

networks:
  monitor-net:
    driver: bridge

volumes:
    prometheus_data: {}
    grafana_data: {}

services:

  prometheus:
    image: prom/prometheus:v2.12.0
    container_name: prometheus
    volumes:
      - ./prometheus/:/etc/prometheus/
      - prometheus_data:/prometheus
    command:
      - '--config.file=/etc/prometheus/prometheus.yml'
      - '--storage.tsdb.path=/prometheus'
      - '--web.console.libraries=/etc/prometheus/console_libraries'
      - '--web.console.templates=/etc/prometheus/consoles'
      - '--storage.tsdb.retention.time=200h'
      - '--web.enable-lifecycle'
    restart: unless-stopped
    expose:
      - 9090
    networks:
      - monitor-net
    labels:
      org.label-schema.group: "monitoring"

  alertmanager:
    image: prom/alertmanager:v0.18.0
    container_name: alertmanager
    volumes:
      - ./alertmanager/:/etc/alertmanager/
    command:
      - '--config.file=/etc/alertmanager/config.yml'
      - '--storage.path=/alertmanager'
    restart: unless-stopped
    expose:
      - 9093
    networks:
      - monitor-net
    labels:
      org.label-schema.group: "monitoring"

  nodeexporter:
    image: prom/node-exporter:v0.18.1
    container_name: nodeexporter
    volumes:
      - /proc:/host/proc:ro
      - /sys:/host/sys:ro
      - /:/rootfs:ro
    command:
      - '--path.procfs=/host/proc'
      - '--path.rootfs=/rootfs'
      - '--path.sysfs=/host/sys'
      - '--collector.filesystem.ignored-mount-points=^/(sys|proc|dev|host|etc)($$|/)'
    restart: unless-stopped
    expose:
      - 9100
    networks:
      - monitor-net
    labels:
      org.label-schema.group: "monitoring"

  cadvisor:
    image: google/cadvisor:v0.33.0
    container_name: cadvisor
    volumes:
      - /:/rootfs:ro
      - /var/run:/var/run:rw
      - /sys:/sys:ro
      - /var/lib/docker/:/var/lib/docker:ro
      #- /cgroup:/cgroup:ro #doesn't work on MacOS only for Linux
    restart: unless-stopped
    expose:
      - 8080
    networks:
      - monitor-net
    labels:
      org.label-schema.group: "monitoring"

  grafana:
    image: grafana/grafana:6.3.3
    container_name: grafana
    volumes:
      - grafana_data:/var/lib/grafana
      - ./grafana/datasources:/etc/grafana/datasources
      - ./grafana/dashboards:/etc/grafana/dashboards
      - ./grafana/setup.sh:/setup.sh
    entrypoint: /setup.sh
    environment:
      - GF_SECURITY_ADMIN_USER=${ADMIN_USER:-admin}
      - GF_SECURITY_ADMIN_PASSWORD=${ADMIN_PASSWORD:-admin}
      - GF_USERS_ALLOW_SIGN_UP=false
    restart: unless-stopped
    expose:
      - 3000
    networks:
      - monitor-net
    labels:
      org.label-schema.group: "monitoring"

  pushgateway:
    image: prom/pushgateway:v0.9.1
    container_name: pushgateway
    restart: unless-stopped
    expose:
      - 9091
    networks:
      - monitor-net
    labels:
      org.label-schema.group: "monitoring"

  caddy:
    image: stefanprodan/caddy
    container_name: caddy
    ports:
      - "3000:3000"
      - "9090:9090"
      - "9093:9093"
      - "9091:9091"
    volumes:
      - ./caddy/:/etc/caddy/
    environment:
      - ADMIN_USER=${ADMIN_USER:-admin}
      - ADMIN_PASSWORD=${ADMIN_PASSWORD:-admin}
    restart: unless-stopped
    networks:
      - monitor-net
    labels:
      org.label-schema.group: "monitoring"

sudo lsof -i :9093
COMMAND    PID USER   FD   TYPE DEVICE SIZE/OFF NODE NAME
docker-pr 2881 root    4u  IPv6  36138      0t0  TCP *:9093 (LISTEN)

sudo netstat -pna | grep 9093
tcp6       0      0 :::9093                 :::*                    LISTEN      2881/docker-proxy

docker ps -a
CONTAINER ID        IMAGE                        COMMAND                  CREATED              STATUS              PORTS               NAMES
741ceac72462        grafana/grafana:6.3.3        "/setup.sh"              About a minute ago   Up About a minute   3000/tcp            grafana
333beb895cc0        prom/node-exporter:v0.18.1   "/bin/node_exporter …"   About a minute ago   Up About a minute   9100/tcp            nodeexporter
ea98e5472c81        prom/alertmanager:v0.18.0    "/bin/alertmanager -…"   About a minute ago   Up About a minute   9093/tcp            alertmanager
8b5f5129012a        prom/pushgateway:v0.9.1      "/bin/pushgateway"       About a minute ago   Up About a minute   9091/tcp            pushgateway
bd54ce4e7806        stefanprodan/caddy           "/sbin/tini -- caddy…"   About a minute ago   Created                                 caddy
52609461a3c2        prom/prometheus:v2.12.0      "/bin/prometheus --c…"   About a minute ago   Up About a minute   9090/tcp            prometheus
37d4ddd2016a        google/cadvisor:v0.33.0      "/usr/bin/cadvisor -…"   About a minute ago   Created             8080/tcp            cadvisor

I assume if you do a docker-compose down and docker-compose up -d same issue occurs?
It looks like the caddy issue has to do with the port 9093 already being in use, though it seems to suggest that a container has reserved it based on the information you have provided.
Can you provide the output of the netstat and lsof after bringing down the stack please?
Also can you provide the output of sudo ls -lah /var/lib/docker the cadvisor issue seems to be separate to the caddy issue.

@andrewssobral In some cases systemctrl restart docker can help. I have a similar problem with caddy on ARM try to remove caddy from stack.

Hi @nightah and @mr47 , sorry for my delayed feedback, I was on vacation.
@mr47 is right, it was a docker problem from my side, I reinstalled docker because something was corrupted, now everything is working fine.
I am closing this issue.


Extension: Reload button jumps from index 1 to 2 in this case

Testing #14288

have a disabled extension that also shows an update

click on enable

=> the reload button is now moved to the right

This is a moot point now that we have Disable/Enable/Uninstall in the menu


Some docummented options are not working for php artisan test

Laravel Version
11.6.0
PHP Version
8.2.6
Database Driver & Version
No response
Description
Options -v, -vv, -vvv, --verbose, -n, --no-intercation are documented (listed in php artisan help test) but not working for the test command. I verified that the other commands do work.
Related to: #49290, #45699, #45340, #44373 and maybe #41951, #38140.
Steps To Reproduce
To reproduce call php artisan test [option] with any of the above options, e.g.
$ php artisan test -vv
PHPUnit 11.1.3 by Sebastian Bergmann and contributors.

Unknown option "-v"

The test command is provided by the nunomaduro/collision package and any issue should be reported at https://github.com/nunomaduro/collision/issues


Documentation Fixes

This PR addresses issue #52 by adding detailed setup guides for OS X, the two currently supported LTS versions of Ubuntu, and Arch Linux (because why not).
I tested everything on my local system using docker to get the different versions of Ubuntu, and booted my laptop into OS X v10.9 for the OS X instructions. They seem to be correct from those tests, and with the latest changes in develop I can easily run the unit tests on all three (everything passes).
I ended up not really saying much about selecting your compiler since the reality is that each system sort of has its own "best compiler" with the exception of Arch (for whom I doubt an install guide is even really necessary).

Assigning @smassung mainly for proofreading and other comments/suggestions. Feel free to merge if you think it's ready, or suggest changes I can make before it's mergable.

Should I add a guide for EWS/EngrIT-managed systems, since we might expect some UIUC users?

Yes, EWS guide would be great

Added.

Can confirm EWS guide works on that system


Video and Audio have Two different keys for decryption

What command to use if the video and audio of the stream have two different keys to decryption?

You can pass multi KID-KEY pairs:
--key KID1:KEY1 --key KID2:KEY2

But i want to mux with -M format=mp4  in one file after decryption the video and audio

thank you , it is working :)


Meteor 1.2: error: Conflict: Constraint<EMAIL_ADDRESS>is not satisfied by less 2.5.0_2.

*<EMAIL_ADDRESS><- ryanswrt:autoform-slingshot 1.0.0

Why does this package depend on less anyway? It's adding bloat to builds when people use SCSS and there isn't a significant amount of less that autoform adds. It should probably be an optional add-on package.

I get this error in a completely different package as well, but it's due to the meteor update to 1.2 version. Any ideas how to fix it so that I can update my meteor version?

+1


Failure to run any edpm target

The dataplane operator is replaced by the openstack operator and the
edpm targets are cloning the openstack operator as a dataplane
directory:
Cloning repo: git clone  -b main https://github.com/openstack-k8s-operators/openstack-operator.git dataplane-operator

Which would cause this error later:
error: must build at directory: not a valid directory: evalsymlink failure on '/home/stack/install_yamls/out/operator/openstack-operator/config/samples/dataplane/preprovisioned' : lstat /home/stack/install_yamls/out/operator/openstack-operator: no such file or directory
make: *** [Makefile:795: edpm_deploy_prep] Error 1

closed by https://github.com/openstack-k8s-operators/install_yamls/pull/862


Add post reading time and word count

Fixes #862.
Changes:

Adds Word Count and Reading Time estimate to the editor.
Adds a Setting to view Word Count and Reading Time estimate on the editor or not.
Adds NPM package "reading-time".

@bonustrack

Hi thanks for the contribution,
Idk how useful this would be for the user if this is only in the editor.... Usually in blog websites, the time to read is on the article itself for users to know how long it will take to read the article..
See in medium:

I think word count make sense in the editor, and reading time in the post.

So add reading time to post, should I keep it on the editor as well?

Also, should I add reading time to the preview, full post, or both? And should there be a setting?

@Kennybll We don't need it on the preview and I don't think we need a setting for it.

Okay, should I commit to here or add another pull request?

@bonustrack @jm90m

you can just commit here and make updates here. There's no point in making another PR. Maybe rename the PR to to whatever it is your changing & edit description.

Okay I added the Reading Time Estimate to the Posts Page.

I can make a copy/rewrite for busy.org under the helpers folder. @jm90m

@jm90m that was my recommendation to use this library. I've looked the options and this one seem to be the best to do the job. It's a really small job so i'm not surprise it's not been updated for a year and i don't see an issue about it. I prefer to use a library and not make our codebase more complex or bigger.

@bonustrack sounds good, we can keep the library then.

Okay.

@bonustrack Hold on before you possibly merge. I looked at how many words reading-time says there is. I think it maybe adding tags or something, because on one post it had 3 links and 2 photos, yet when I debugged it said 7 words. That's incorrect. I think I can add the options parameter with a function than skips over the tags. I don't know. I'll look into it if you want.

Nevermind it handle markdown link fine.

Sorry for all the commits, I'm try to get through the linting process.

You can check for lint errors locally using npm run lint and npm run test.
There is precommit hook so they should be run before every commit.

@bonustrack @jm90m, @Sekhmet  thinks we shouldn't have a setting, what do you think?

I don't think a settings option for this is necessary, usually users will always want to see their word count.

@bonustrack @jm90m @Sekhmet, that should do it, I think.

There @bonustrack

@Kennybll

Can we have this style for the time to read:

Using a bullet similar than CommentFooter__bullet class
It would be nice to hide the reading time indicator if the content is less than 1000 characters.

I don't think that removing indicator for short posts is useful. It might be confusing for users to see that some posts have it and some posts don't.

@Kennybll can you run npm run test and npm run lint before committing? This would help you find problems locally, without need of pushing it to repo.

There we go @bonustrack @Sekhmet. The reason I wasn't using local lint was because my command prompt kept saying "Expected linebreaks to be 'LF' but found 'CRLF'" but I fixed that for the future.

@Kennybll Word count on editor should be aligned to right

@bonustrack Woops when I changed Editor____readingTime to Editor__reading_time, I didn't change Editor.less, sorry It should work now.

@Sekhmet  added it to en.json


contact.md missing

contact.md is referenced in CODE_OF_CONDUCT.md for reporting conduct violations but is missing in the repository.

Good catch, and an easy fix. Thanks!


Add processor tests

Current dependencies on/for this PR:

main

PR #55   👈

This comment was auto-generated by Graphite.


The "No provider for NestedOptionHost" error occurs when using DxDataGrid in a custom Angular component

devexteme version: 16.2.6
devextreme-angular version: 16.2.6

[x] bug
I am trying to create a new data-grid component wrapping dx-data-grid, so that I can set default options for data-grid by default so that other developers will use that.
Something like below
my-data-table.html
<dx-data-grid #myGrid [dataSource]="dataSource">
<ng-content select-"dxi-column"></ng-content>
</dx-data-grid>

my-data-table.ts
@Component({
selector: 'app-my-data-table',
templateUrl: './my-data-table.html',
styleUrls: ['./my-data-table.less']
})
export class MyDataTableComponent {

@ViewChild('myGrid') myGrid: DxDataGridComponent;
@Input() dataSource: any;
}

and in my test component using it as below
<app-my-data-table [dataSource]="expenseClaims">
<dxi-column dataField="Title" caption="Title"></dxi-column>
</app-my-data-table>

but when I compile the code and open the page I get this error in console
Error: Template parse errors: No provider for NestedOptionHost ("le [dataSource]="expenseClaims" > [ERROR ->]<dxi-column dataField="Title" caption="Title"></dxi-column>
Also I imported NestedOptionHost, DxiColumnComponent in my module imports, still same issue

https://plnkr.co/edit/PF84xdL6rnQEmmlKirox?p=preview

Hi,

We don't officially support extending our components and wouldn't recommend doing this because the internal API may be changed after any release without any warning. So, you will be fully responsible for all issues (if there are any) and will likely need to constantly make some additional work after we do some changes in our widgets or integration package.

If you're still going to extend our components, I recommend you refer to the node_modules/devextreme-angular/ui folder to see our source code and investigate how it works.

If your task is simply to define some default options at the widget level, you can use a public API for this. Please take a look at the following How to set default options for dxDataGrid in an Angular app

For anyone coming here in the future, I have successfully created a wrapper around the dx-data-grid. A working example for Angular v 8.x can be found here:
https://stackblitz.com/edit/dev-express-grid-wrapper

For anyone coming here in the future, I have successfully created a wrapper around the dx-data-grid. A working example for Angular v 8.x can be found here:
https://stackblitz.com/edit/dev-express-grid-wrapper

hello were you able to wrap other components such as dxo-paging?

@Mimis40, I was using your grid-wrapper implementation, so I needed to update the version of devExtreme. From there the table enters an infinite loop and extends the memory.
Have you had this problem?
Trying to find the problem I noticed that the loop happens when the directive finds the property '@Input () public dataField ?: string;'.

@eliseurm and @sadra74
I have uploaded a version of what I'm currently using that works with angular 11. As a bonus, I also included an example of how to get dev extreme to work with Observables, instead of Differed/Promises. The table wrapper has evolved a lot since I last posted, so forgive me for that.
https://stackblitz.com/edit/angular-11-dev-express-grid-wrapper?file=src/app/app.component.ts

@eliseurm and @sadra74
I have uploaded a version of what I'm currently using that works with angular 11. As a bonus, I also included an example of how to get dev extreme to work with Observables, instead of Differed/Promises. The table wrapper has evolved a lot since I last posted, so forgive me for that.
https://stackblitz.com/edit/angular-11-dev-express-grid-wrapper

I've tried to use your approach, but many of the grid functions don't work, like updating rows, column width set, alignment and stuff, did you notice that? or is it on purpose?

@eliseurm and @sadra74 I have uploaded a version of what I'm currently using that works with angular 11. As a bonus, I also included an example of how to get dev extreme to work with Observables, instead of Differed/Promises. The table wrapper has evolved a lot since I last posted, so forgive me for that.
https://stackblitz.com/edit/angular-11-dev-express-grid-wrapper

Hey there. Thanks a lot for that example, it really did help me creating something similar. However what I tried is to customize the grid's toolbar using a custom template. I set the toolbar in 21.2.4 to this setting:
toolbar: {visible: true, items: [{location: 'after', template: 'toolbarTmpl'}]},
and in my wrapper I setup my template like this:

Toolbar Template test.

However the template doesn't get rendered but only shows "toolbarTmpl". Other cell templates work fine in the wrapper. They also show up in the respected setTempalte methods etc.
Any idea on that / or would you care to test if a custom template works for you ?

@eliseurm and @sadra74 I have uploaded a version of what I'm currently using that works with angular 11. As a bonus, I also included an example of how to get dev extreme to work with Observables, instead of Differed/Promises. The table wrapper has evolved a lot since I last posted, so forgive me for that.
https://stackblitz.com/edit/angular-11-dev-express-grid-wrapper

Hi @mikerentmeister,  I need your help again.
After upgrading from devExtreme 21.2.5 my grids stopped working.
We actually need devExtreme to take care of this and implement a way to wrap columns.
In the meantime, if you can make your solution update available, I would be eternally grateful. :)

@eliseurm
https://stackblitz.com/edit/angular-11-dev-express-grid-wrapper-khtmsu?file=src/app/table/table.component.html
My company decided to move to IgniteUi a few months ago for various reasons. I have put our code for the wrapper in this example (but didn't update the dependencies in the package.json). This code works for us Angular 13.1.2 with DevExtreme 21.2.3, while we work on converting our code base to the new library. I cannot guarantee that it will work in StackBlitz, because I know StackBlitz has had some issues with Agnular 13, and DevExtreme is not ivy supported yet. Good luck.
Please also note that now my table.component now uses OnPush change detection, wheras in previous samples it did not,


Create: 977-Squares-Of-A-Sorted-Array.py

File(s) Modified: 977-Squares-Of-A-Sorted-Array.py
Language(s) Used: python
Submission URL: https://leetcode.com/submissions/detail/817227192/

Thanks for contributing!


Minor refactoring: removed unused Depends.

Minor refactoring: removed unused Depends.
Thank you for contributing to the Cohere Toolkit!

[ ] PR title: "area: description"

Where "area" is whichever of interface, frontend, model, tools, backend, etc. is being modified. Use "docs: ..."  for CI changes.
Example: "deployment: add Azure model option"

[ ] PR message: Delete this entire checklist and replace with

Description: a description of the change
Issue: the issue # it fixes, if applicable
Dependencies: any dependencies required for this change

[ ] Add tests and docs: Please include testing and documentation for your changes

[ ] Lint and test: Run make lint and make run-tests

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

Welcome @Phodaie! Your contribution is appreciated - the changes are already part of #71  but I don't think it would hurt to merge them and get a first contribution in.
Make sure you run make lint to format your changes, and we can go ahead and approve + merge your changes

Will submit a linted version


FND-359 - Eliminate unused imports in Analytics

Signed-off-by: Elisa Kendall<EMAIL_ADDRESS>Description
Removed several unused imports to clean up the analytics ontology
Fixes: #1690
Checklist:

[x] I'm familiar with the FIBO developer quide. My contribution meets all the requirements described there.
[x] My contribution follows the principles of best practices for FIBO.
[x] My changes have been reconciled with latest master and no merge conflicts remain.
[x] This PR is related to exactly one issue. The issue is referenced by using a GitHub keyword such as "fixes", "closes", or "resolves".
[x] Hygiene tests have been applied by a PR with "(WIP)" in title.
[x] The issue has been tested locally using a reasoner (for ontology changes).

Can/do we have a hygiene test for unused imports?

Not yet, but I will add to the list of things-to-do. You may also raise an issue about this.


WFLY-16378 Upgrade to Hibernate Search 6.1.5.Final

https://issues.redhat.com/browse/WFLY-16378

Thanks @yrodiere


Update fs2-job to 0.0.8

Updates com.slamdata:fs2-job from 0.0.7 to 0.0.8.
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 @scala-steward in the comments below.
Have a fantastic day writing Scala!

Ignore future updates
Add this to your .scala-steward.conf file to ignore future updates of this dependency:
updates.ignore = [ { groupId = "com.slamdata", artifactId = "fs2-job" } ]

labels: semver-patch

I just bumped into this and I'm wondering if we should autobump fs2-job-version (file is already in master) or let @scala-steward do it.

@jsantos17 The autobump mechanism is better


"Unable to reach api.nylas.com, retrying" message on connecting to different WiFi network

I'm a student, and therefore I travel from home to school every day. When I get to school after having Nylas work properly at home, I get the error message here (https://i.imgur.com/G2kIAl8.png). However, it works fine after a suspend cycle at home or at school. Same deal coming home from school in the afternoon, leading me to believe it's a problem with switching networks.
What operating system are you using?
I'm using Arch Linux with kernel 4.5.4-1-ck, and GNOME desktop environment.
What version of N1 are you using?
I'm using n1 0.4.33-1 (the binary version from the AUR), which is the latest version.

Bug?
Do you have any third-party plugins installed?
None other than themes
Is the issue related to a specific email provider (Gmail, Exchange, etc.)?
I don't believe so, this looks like a Nylas server issue. I use a school Google Apps for Education account and a personal Gmail account.
Is the issue reproducible with a particular attachment, message, signature, etc?
Here's a screenshot of the message: https://i.imgur.com/G2kIAl8.png

@saligrama Hm... that sounds like it might just be the brief lack of connectivity when you've switched networks, not an error. Does it persist?

@jackiehluo It persists, and gives me the same message after trying again. If you killall the process and restart it then it works.

Having exactly the same problem here also. Had to kill the process and restart. I checked my internet connection and all was good. Other applications could connect. The only thing that happened was that the wifi access point changed when I went from home to the office.
I am also on archlinux and no plugins installed in n1.

It's also worth mentioning that if reconnecting to the same SSID after a disconnection (i.e., a sleep/wake cycle) it works as expected. Problem only arises after connecting to a different network.

Hmm - @fish22 are you experiencing this on Linux as well? This may b an issue with the way the network interface is exposed to NodeJS. N1 just tries to make an HTTPS request to our servers. If it works properly when reconnecting to the same SSID, but doesn't work when connecting to a different one, it may be something pretty low-level.

Archlinux too, same problem. I'm switching between two WiFi networks and LAN wired connection. Also I'm using Network Manager to switch connections.

Got the same problem… Manjaro Linux (Arch based)
Everytime I switch from Univesity to Home Wifi Nylas won't sync.
its super annoying -.-

Same problem here - Fedora24 .

Same problem here - Fedora24 and N1 0.4.52

Ugh, same problem. Just ran across it setting up an Amazon Echo, when you have to connect to the devices wifi and then switched back to home network.
Used System Monitor to kill all Nylas functions, reopened Nylas, seems to work for now.
Antergos (Arch Linux)

I do too.
Hoped you fixed it when you moved from N1 -> Mail 2.0..
But it seems its just a repacked N1 client, because all the bugs that was with the N1 client still exist in this version.
Eg
This pullrequest #3238 which fixes #3219 #2809 with the signature editor.
This #2243 #3015 #1146 connectivity bug.
Is there a roadmap, or a timeline on how soon you are gonna fix it ?


feat(calendar-range): add custom container width prop

https://jira.moscow.alfaintra.net/browse/DS-6692
Добавлена возможность изменять ширину контейнера календаря

Pull Request Test Coverage Report for Build<PHONE_NUMBER>4
Details

5 of 5 (100.0%)  changed or added relevant lines in 2 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage increased (+0.01%) to 82.602%

Totals

Change from base Build<PHONE_NUMBER>2:
0.01%

Covered Lines:
10352

Relevant Lines:
11463

💛  - Coveralls


MVC draft docs

Greetings, I would like to request draft docs for MVC.  We are currently implementing an MVC 6 solution at my client.  Thanks!

This isn't the right venue to request draft docs. You can register for individual doc stubs.


Intermittent errors from ASP.NET Core 2.2.0 application

Raised as possibly related to #4398.
Intermittently when running the test suite for an existing ASP.NET Core 2.1.6 application that has been ported to ASP.NET Core 2.2.0 with in-process IIS hosting, requests fail. Both applications are hosted on Amazon EC2 instances running Windows Server Core 2012 R2.
The specific requests that fail are HTTP GET requests from an ASP.NET 4.6.1 application that acts as a proxy for the ASP.NET Core application.
Requests are made as standard HTTP 1.1 using HttpClient, rather than with HTTP/2 (at least, not explicitly).
The flow of the tests are as following:

Perform an HTTP GET for an entity, which returns an HTTP 200.
Perform an HTTP POST against the entity, which returns an HTTP 204.
Re-perform the same HTTP GET to validate the HTTP POST took effect by inspecting the response.

When the request to validate the POST is made within the ASP.NET 4.6.1 proxy application, the following exception occurs:
System.AggregateException: One or more errors occurred. ---> System.Net.Http.HttpRequestException: An error occurred while sending the request. ---> System.Net.WebException: The server committed a protocol violation. Section=ResponseStatusLine
   at System.Net.HttpWebRequest.EndGetResponse(IAsyncResult asyncResult)
   at System.Net.Http.HttpClientHandler.GetResponseCallback(IAsyncResult ar)
   --- End of inner exception stack trace ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Refit.RequestBuilderImplementation`1.<>c__DisplayClass13_0`1.<<BuildCancellableTaskFuncForMethod>b__0>d.MoveNext()
   --- End of inner exception stack trace ---
   at System.Threading.Tasks.Task`1.GetResultCore(Boolean waitCompletionNotification)
  <snipped application stack trace>
---> (Inner Exception #0) System.Net.Http.HttpRequestException: An error occurred while sending the request. ---> System.Net.WebException: The server committed a protocol violation. Section=ResponseStatusLine
   at System.Net.HttpWebRequest.EndGetResponse(IAsyncResult asyncResult)
   at System.Net.Http.HttpClientHandler.GetResponseCallback(IAsyncResult ar)
   --- End of inner exception stack trace ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at Refit.RequestBuilderImplementation`1.<>c__DisplayClass13_0`1.<<BuildCancellableTaskFuncForMethod>b__0>d.MoveNext()<---

Requests directly to the ASP.NET Core 2.2.0 application from the tests (which are in the same code base and are .NET Core 2.2.0 also) do not exhibit this behaviour and behave as expected, i.e. they pass.
It appears that something is behaving differently in the server's responses that is causing the ASP.NET application to reject the responses to the requests, as this behaviour has never been observed before in this test suite with previous versions of ASP.NET Core.
At this time due to the size and nature of the two applications involved, I cannot provide a simple repro.
Upon changing the web.config file of the ASP.NET Core application to use out-of-process hosting, the tests no longer fail.
For reference, this is the web.config of the application when deployed to the server:
<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <system.webServer>
    <httpProtocol>
      <customHeaders>
        <remove name="X-Powered-By" />
      </customHeaders>
    </httpProtocol>
    <urlCompression doDynamicCompression="true" doStaticCompression="true" />
    <handlers>
      <add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModuleV2" resourceType="Unspecified" />
    </handlers>
    <aspNetCore processPath="dotnet" arguments=".\Application.dll" stdoutLogEnabled="false" stdoutLogFile=".\logs\stdout" hostingModel="inprocess" />
  </system.webServer>
</configuration>

This actually may be the same issue in #4398
Few things I would check:

I think the ASP.NET 461 application is probably using a WinHttpClientHandler underneath the HttpClient which will upgrade requests to HTTP/2 if available. If you can, check the first GET HttpResponse and see if is HTTP/2.
Add the recommended workaround to your app and see if that fixes your problem.

As it's easier in my particular setup, as a first step I'll try adding the workaround now and see what happens.

I just checked our IIS logs and there's no references to HTTP/2 there. All the requests to the ASP.NET Core application are listed as HTTP/1.1 for cs-version.

If it helps and/or is relevant, the ASP.NET 4.6.1 application uses ServicePointManager.FindServicePoint() to specify a ConnectionLeaseTimeout value, and sets ConnectionClose = false on the HttpClient's DefaultRequestHeaders property.
Just thought I'd mention it in case that might contribute to the intermittent nature of the issue from my observations.

I don't think ServicePointManager.FindServicePoint() is relevant.
Try the workaround for now and see if you continue getting failures. If the issue is fixed, this issue may affect HTTP/1.1 too.

Cool - I'll try that tomorrow and see how I get on.

Having applied the middleware workaround from #4398 to our application and re-running the tests multiple times, the ASP.NET 4.6.1 application is no longer throwing the exceptions when In-Process hosting is enabled.
That would seem to suggest that this is another manifestation of the same bug and isn't specific to HTTP/2.

We're patching this (#4398).


chore(analytics): use useFocusEffect for screen event

Description
To ensure relevant UI is on screen before triggering analytics events, use useFocusEffect.
PR Checklist

[x] I have tested my changes on iOS and Android.
[x] I hid my changes behind a feature flag, or they don't need one.
[x] I have included screenshots or videos, or I have not changed the UI.
[x] I have added tests, or my changes don't require any.
[x] I added an app state migration, or my changes do not require one.
[x] I have documented any follow-up work that this PR will require, or it does not require any.
[x] I have added a changelog entry below, or my changes do not require one.

To the reviewers 👀

[ ] I would like at least one of the reviewers to run this PR on the simulator or device.

Changelog updates
Changelog updates

Cross-platform user-facing changes

iOS user-facing changes

Android user-facing changes

Dev changes

chore(analytics): use ProvideScreenTrackingWithCohesionSchema for screen event

Need help with something? Have a look at our docs, or get in touch with us.

This PR contains the following changes:

Dev changes (chore(analytics): use ProvideScreenTrackingWithCohesionSchema for screen event)

  Generated by :no_entry_sign: dangerJS against 0c88c2767299f2f8cda626766ca13376daa1343e


[Testing API] Cannot read property 'removePeek' of null

Does this issue occur when all extensions are disabled?: Yes/No

Version: 1.57.0-insider (user setup)
Commit: bf84ee619e0b67443d0307c04348fa575bc3c363
Date: 2021-06-07T12:46:22.208Z
Electron: 12.0.9
Chrome: 89.0.4389.128
Node.js: 14.16.0
V8: <IP_ADDRESS>-electron.0
OS: Windows_NT x64 10.0.19043
Steps to Reproduce:

Use the test-provider-sample and open the test explorer
Test navigation is working now in the test explorer
Run 2 + 2 = 5
Every time changing the focus from the 2 + 2 = 5 to o another node from test explorer, you can see the navigation is not working, ang an error message Cannot read property 'removePeek' of null can be observed in the developer tools

https://user-images.githubusercontent.com/6193897/121110626-737bad00-c7c2-11eb-8fdb-b38458233cee.mp4
//cc @connor4312

this is fixed already in the upcoming vs code insiders


Improve compatibility profile performance and make profiles a part of central configuration

Compatibility profiles are currently very slow to start up and use opaque and duplicated configurations across rules.
Instead:

They should be more modular so they can be more easily read in
They should ideally have a custom parser for speed
Rather than being configured by name, they should be specified by PS and OS version and defaults should be implicitly listed in each PSSA version
Profiles should be lazily taken from NuGet rather than distributed with PSSA

We are using PSScriptAnalyzer in our GitLab street and currently experiencing the issue described here:
After opening a new PowerShell session, the initial Invoke-ScriptAnalyzer with the following settings takes more than 25 secondes:
Measure-Command {
    Invoke-ScriptAnalyzer -Path .\Test -Settings @{
        IncludeDefaultRules = $true
        CustomRulePath = "$InjectionHunterPath", "$SSORulesPath"
        Rules = @{
            PSUseCompatibleCommands = @{
                Enable = $true
                TargetProfiles = @(
                    'win-8_x64_10.0.17763.0_5.1.17763.316_x64_4.0.30319.42000_framework',
                    'win-8_x64_10.0.17763.0_7.0.0_x64_3.1.2_core'
                )
            }
            PSUseCompatibleSyntax = @{
                Enable = $true
                TargetVersions = @(
                    '5.1',
                    '7.0'
                )
            }
        }
    }
}

Any successive invocation takes less than .5 seconds.
Is there any way to workaround this?
PSScriptAnalyzer version: 1.20
PowerShell version table (it also happens on PowerShell 7):
Name                           Value
----                           -----
PSVersion                      5.1.19041.2673
PSEdition                      Desktop
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0...}
BuildVersion                   10.0.19041.2673
CLRVersion                     4.0.30319.42000
WSManStackVersion              3.0
PSRemotingProtocolVersion      2.3
SerializationVersion           <IP_ADDRESS>

Is there any way to workaround this issue?

The performance issues here occur because the profiles are stored in very large JSON files, which are parsed using reflection with Newtonsoft code. There's probably also some large object heap involvement too. Those files have to be loaded up on cold start, and even parsing them lazily doesn't avoid the huge memory consumption that probably drives much of the performance issues.
A workaround might be to amortise cold starts by turning this into a service shared across CI workers.
An interim solution would be to change out the JSON parsing code to use pre-generated stream parsing, probably using Microsoft's JSON parsing library.
The best solution would be to convert the compatibility profiles into a Sqlite DB and ship PSSA with bindings for that

@rjmholt,

A workaround might be to amortise cold starts by turning this into a service shared across CI workers.

Thank you for the feedback. Unfortunately, this is quiet hard for us to implement.
Anyways, as we actually only using the script analyzer to automatically generate issues/emails on a commit and do not preventing it from still building a merge request, we now have script analyzer completely asynchrone with the rest.
From the reply from @bergmeister

I don't think so although I cannot speak for PS team. Your referenced issue is isolated to the workings of compatibility rules and not related to PSSA rewrite

Does that mean that I actually should create a separate issue for this?

Unfortunately, this is quiet hard for us to implement.

Yeah PSSA as a service is just something I suggest if no changes will be made to the compatibility rules. I suspect it would be easier to implement than rewriting the compatibility rules yourself.
I no longer work at Microsoft so I don't know what the plans or processes are beyond what you know already, but I don't imagine a separate issue would help here

I'm also observing a performance issue which is related to the cold start. In my case, every time I run the tests, they start in a fresh PS Session, so I'm always hitting the fresh start penalty. Usually, the delay out of initialization is longer than all the PSSA related tests. It would be great, if there was a way to trigger the cold start process in the very beginning (i.e. before all the other tests and prep tasks) so that it would run asynchronously (i.e. in a separate thread or runspace) and by the time my script gets to running PSSA tests, those large JSONs should already be loaded, i.e.:
1. Initialize-PSSA (starts init task in the background and returns back the prompt on the main thread)
2. Prepare the folder for the tests (cleanup artifacts folder, check dependencies and update if needed, etc.)
3. Start all the other Tests (leaving PSSA tests to the end)
4. Wait-PSSAInit (a cmdlet that would hold the main thread until the PSSA is fully initialized)
5. Run PSSA Tests
... other steps ...


Feature Request:  Support ROS pointclouds from Ouster 128-beam LIDAR

Ouster's OS0-128 outputs 128 lines of resolution in a standard pointcloud2 msg on the ROS topic, "/os_cloud_node/points".  Per the link below, the ROS node assumes the standard Velodyne pointcloud topic and 16/32/64 projections.  Feature request is to add support for 128-beam ROS pointclouds on arbitrary topics.
https://github.com/PRBonn/depth_clustering/blob/fe9d6675b213926815bf2bbde593b28b55be4b98/examples/ros_nodes/save_clusters_node.cpp#L40-L68

Thanks for the suggestion! I will not have the time to work on this, but I am happy to review a PR about it.


size: strip envoy api's v2 protos

According to my most recent binary size test the compiled v2 protos accounted for ~10% of the compiled binary (v3 equivalently accounting for another 10%).
Given that Envoy Mobile has migrated to using only v3 config we should investigate creating an option in envoy to only compile in the protos for the currently in use api version. Although here we are talking about v2 and v3 specifically, this solution should apply to subsequent version changes.
@htuch and @lizan will have good ideas about how to go about doing this in agreement with Envoy's vision for api usage, so we should connect with them.
My rough idea for getting started is:

Right now all the api_proto_package targets for v3 contain their v2 counter parts. For instance, here. There should be a bazel option to not include that dependency. This would get us started in not including the v2 protos at compile time.
For runtime we need to look a bit more if dropping the protos is safe.

Last I checked, call sites of this getEarlierVersionDescriptor check for null, so we should be able to not have the v2 protos safely.
We need to see how xDS subscriptions decide which version to use with upstream servers, and make sure the correct setting gets applied to only speak one version of the api, and for that version to be the same as the currently "in use" api.

These are all my current thoughts on this space. Nothing too fleshed out, but enough to get started. @buildbreaker I am assigning to you, as discussed internally, while I am out.

After running a fresh analysis 10/2020 this issue continues to be the greatest investment we can make. Compiled protos account ~34% of the binary size so dropping v2 protos should see a >15% reduction.

@junr03 given the plan to remove v2 in Q1 next year, do you think it makes sense to add this support to minify now or wait?


[e2e]: nodejs workflow_dispatch main default slsa3

Repo: https://github.com/slsa-framework/example-package/tree/main
Run: https://github.com/slsa-framework/example-package/actions/runs/5899486821
Workflow file: https://github.com/slsa-framework/example-package/tree/main/.github/workflows/e2e.nodejs.workflow_dispatch.main.default.slsa3.yml
Workflow runs: https://github.com/slsa-framework/example-package/actions/workflows/e2e.nodejs.workflow_dispatch.main.default.slsa3.yml
Trigger: workflow_dispatch
Branch: main
Date: Fri Aug 18 06:26:02 UTC 2023

Repo: https://github.com/slsa-framework/example-package/tree/main
Run: https://github.com/slsa-framework/example-package/actions/runs/5909902675
Workflow file: https://github.com/slsa-framework/example-package/tree/main/.github/workflows/e2e.nodejs.workflow_dispatch.main.default.slsa3.yml
Workflow runs: https://github.com/slsa-framework/example-package/actions/workflows/e2e.nodejs.workflow_dispatch.main.default.slsa3.yml
Trigger: workflow_dispatch
Branch: main
Date: Sat Aug 19 06:24:28 UTC 2023
Tests are passing now. Closing this issue.


[Bug]: Numpy issue with Google Cloud Compute deployment example

What happened?
I'm getting the following error in a totally new clean installation:
server  | ValueError: Unable to compare versions for numpy>=1.17: need=1.17 found=None. This is unusual. Consider reinstalling numpy.
I tested this code in the past, and it was working without any issues, and I didn't make any changes to it.
On startup.sh I can see the images are using fixed versions so I don't understand what changed. @Alw3ys maybe can help me with that?
I've created a video showing it: https://user-images.githubusercontent.com/632625/233413553-904c6685-f301-4bcf-8a52-b1968b5e84d2.mp4
Versions
Using docker-compose with /chroma/examples/deployments/google-cloud-compute/startup.sh
Relevant log output
root@debian:~# mkdir test
root@debian:~# cd test
root@debian:~/test#
root@debian:~/test# cat << EOF > docker-compose.yaml
version: "3.9"
services:
  server:
    container_name: server
    image: ghcr.io/chroma-core/chroma:0.3.14
    volumes:
      - ./index_data:/index_data
    environment:
      - CHROMA_DB_IMPL=clickhouse
      - CLICKHOUSE_HOST=clickhouse
      - CLICKHOUSE_PORT=8123
    ports:
      - '8000:8000'
    depends_on:
      - clickhouse
  clickhouse:
    container_name: clickhouse
    image: clickhouse/clickhouse-server:22.9-alpine
    volumes:
      - ./clickhouse_data:/bitnami/clickhouse
      - ./backups:/backups
      - ./config/backup_disk.xml:/etc/clickhouse-server/config.d/backup_disk.xml
      - ./config/chroma_users.xml:/etc/clickhouse-server/users.d/chroma.xml
    environment:
      - ALLOW_EMPTY_PASSWORD=yes
      - CLICKHOUSE_TCP_PORT=9000
      - CLICKHOUSE_HTTP_PORT=8123
    ports:
      - '8123:8123'
      - '9000:9000'
EOF

mkdir config
cat << EOF > config/backup_disk.xml
<clickhouse>
    <storage_configuration>
        <disks>
            <backups>
                <type>local</type>
                <path>/etc/clickhouse-server/</path>
            </backups>
        </disks>
    </storage_configuration>
    <backups>
        <allowed_disk>backups</allowed_disk>
        <allowed_path>/etc/clickhouse-server/</allowed_path>
    </backups>
</clickhouse>
EOF

cat << EOF > config/chroma_users.xml
<clickhouse>
    <profiles>
        <default>
            <allow_experimental_lightweight_delete>1</allow_experimental_lightweight_delete>
            <mutations_sync>1</mutations_sync>
        </default>
    </profiles>
</clickhouse>
EOF

docker compose up
[+] Running 3/3
 ✔ Network test_default  Created                                                                                0.1s
 ✔ Container clickhouse  Created                                                                                1.7s
 ✔ Container server      Created                                                                                5.1s
Attaching to clickhouse, server
clickhouse  | <jemalloc>: Number of CPUs detected is not deterministic. Per-CPU arena disabled.
clickhouse  | <jemalloc>: Number of CPUs detected is not deterministic. Per-CPU arena disabled.
clickhouse  | <jemalloc>: Number of CPUs detected is not deterministic. Per-CPU arena disabled.
clickhouse  | <jemalloc>: Number of CPUs detected is not deterministic. Per-CPU arena disabled.
clickhouse  | <jemalloc>: Number of CPUs detected is not deterministic. Per-CPU arena disabled.
clickhouse  | <jemalloc>: Number of CPUs detected is not deterministic. Per-CPU arena disabled.
clickhouse  | <jemalloc>: Number of CPUs detected is not deterministic. Per-CPU arena disabled.
clickhouse  | <jemalloc>: Number of CPUs detected is not deterministic. Per-CPU arena disabled.
clickhouse  | <jemalloc>: Number of CPUs detected is not deterministic. Per-CPU arena disabled.
clickhouse  | <jemalloc>: Number of CPUs detected is not deterministic. Per-CPU arena disabled.
clickhouse  | Processing configuration file '/etc/clickhouse-server/config.xml'.
clickhouse  | Merging configuration file '/etc/clickhouse-server/config.d/backup_disk.xml'.
clickhouse  | Merging configuration file '/etc/clickhouse-server/config.d/docker_related_config.xml'.
clickhouse  | Logging trace to /var/log/clickhouse-server/clickhouse-server.log
clickhouse  | Logging errors to /var/log/clickhouse-server/clickhouse-server.err.log
server      | Rebuilding hnsw to ensure architecture compatibility
clickhouse  | Processing configuration file '/etc/clickhouse-server/config.xml'.
clickhouse  | Merging configuration file '/etc/clickhouse-server/config.d/backup_disk.xml'.
clickhouse  | Merging configuration file '/etc/clickhouse-server/config.d/docker_related_config.xml'.
clickhouse  | Saved preprocessed configuration to '/var/lib/clickhouse/preprocessed_configs/config.xml'.
clickhouse  | Processing configuration file '/etc/clickhouse-server/users.xml'.
clickhouse  | Merging configuration file '/etc/clickhouse-server/users.d/chroma.xml'.
clickhouse  | Saved preprocessed configuration to '/var/lib/clickhouse/preprocessed_configs/users.xml'.
server      | Collecting hnswlib
server      |   Downloading hnswlib-0.7.0.tar.gz (33 kB)
server      |   Installing build dependencies: started
server      |   Installing build dependencies: finished with status 'done'
server      |   Getting requirements to build wheel: started
server      |   Getting requirements to build wheel: finished with status 'done'
server      |   Preparing metadata (pyproject.toml): started
server      |   Preparing metadata (pyproject.toml): finished with status 'done'
server      | Collecting numpy
server      |   Downloading numpy-1.24.2-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (17.3 MB)
server      |      ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 17.3/17.3 MB 197.3 MB/s eta 0:00:00
server      | Building wheels for collected packages: hnswlib
server      |   Building wheel for hnswlib (pyproject.toml): started
server      |   Building wheel for hnswlib (pyproject.toml): finished with status 'done'
server      |   Created wheel for hnswlib: filename=hnswlib-0.7.0-cp310-cp310-linux_x86_64.whl size=2155705 sha256=bef74688b38cadce5ddd19770e999779728ce6395a2971f7c595d0661c7ba9bf
server      |   Stored in directory: /tmp/pip-ephem-wheel-cache-284r50te/wheels/36/5e/06/bba7cbc79ef454a94746ba051381601575597e1b324b1221da
server      | Successfully built hnswlib
server      | Installing collected packages: numpy, hnswlib
server      |   Attempting uninstall: numpy
server      |     Found existing installation: numpy 1.24.2
server      |     Uninstalling numpy-1.24.2:
server      | ERROR: Could not install packages due to an OSError: [Errno 22] Invalid argument: '/usr/local/lib/python3.10/site-packages/numpy-1.24.2.dist-info/'
server      |
server      |
server      | [notice] A new release of pip available: 22.3.1 -> 23.1
server      | [notice] To update, run: pip install --upgrade pip
server      | 2023-04-20 15:15:25 INFO     chromadb.telemetry.posthog Anonymized telemetry enabled. See https://docs.trychroma.com/telemetry for more information.
server      | 2023-04-20 15:15:25 INFO     chromadb        Running Chroma using direct local API.
server      | 2023-04-20 15:15:25 INFO     chromadb        Using Clickhouse for database
server      | 2023-04-20 15:15:25 INFO     uvicorn.error   Started server process [33]
server      | 2023-04-20 15:15:25 INFO     uvicorn.error   Waiting for application startup.
server      | 2023-04-20 15:15:25 INFO     uvicorn.error   Application startup complete.
server      | 2023-04-20 15:15:25 INFO     uvicorn.error   Uvicorn running on http://<IP_ADDRESS>:8000 (Press CTRL+C to quit)

server      | 2023-04-20 15:15:38 WARNING  chromadb.api.models.Collection No embedding_function provided, using default embedding function: SentenceTransformerEmbeddingFunction
server      | 2023-04-20 15:15:39 ERROR    chromadb.server.fastapi Unable to compare versions for numpy>=1.17: need=1.17 found=None. This is unusual. Consider reinstalling numpy.
server      | Traceback (most recent call last):
server      |   File "/usr/local/lib/python3.10/site-packages/anyio/streams/memory.py", line 94, in receive
server      |     return self.receive_nowait()
server      |   File "/usr/local/lib/python3.10/site-packages/anyio/streams/memory.py", line 89, in receive_nowait
server      |     raise WouldBlock
server      | anyio.WouldBlock
server      |
server      | During handling of the above exception, another exception occurred:
server      |
server      | Traceback (most recent call last):
server      |   File "/usr/local/lib/python3.10/site-packages/starlette/middleware/base.py", line 43, in call_next
server      |     message = await recv_stream.receive()
server      |   File "/usr/local/lib/python3.10/site-packages/anyio/streams/memory.py", line 114, in receive
server      |     raise EndOfStream
server      | anyio.EndOfStream
server      |
server      | During handling of the above exception, another exception occurred:
server      |
server      | Traceback (most recent call last):
server      |   File "/chroma/./chromadb/server/fastapi/__init__.py", line 50, in catch_exceptions_middleware
server      |     return await call_next(request)
server      |   File "/usr/local/lib/python3.10/site-packages/starlette/middleware/base.py", line 46, in call_next
server      |     raise app_exc
server      |   File "/usr/local/lib/python3.10/site-packages/starlette/middleware/base.py", line 36, in coro
server      |     await self.app(scope, request.receive, send_stream.send)
server      |   File "/usr/local/lib/python3.10/site-packages/starlette/middleware/exceptions.py", line 75, in __call__
server      |     raise exc
server      |   File "/usr/local/lib/python3.10/site-packages/starlette/middleware/exceptions.py", line 64, in __call__
server      |     await self.app(scope, receive, sender)
server      |   File "/usr/local/lib/python3.10/site-packages/fastapi/middleware/asyncexitstack.py", line 21, in __call__
server      |     raise e
server      |   File "/usr/local/lib/python3.10/site-packages/fastapi/middleware/asyncexitstack.py", line 18, in __call__
server      |     await self.app(scope, receive, send)
server      |   File "/usr/local/lib/python3.10/site-packages/starlette/routing.py", line 680, in __call__
server      |     await route.handle(scope, receive, send)
server      |   File "/usr/local/lib/python3.10/site-packages/starlette/routing.py", line 275, in handle
server      |     await self.app(scope, receive, send)
server      |   File "/usr/local/lib/python3.10/site-packages/starlette/routing.py", line 65, in app
server      |     response = await func(request)
server      |   File "/usr/local/lib/python3.10/site-packages/fastapi/routing.py", line 231, in app
server      |     raw_response = await run_endpoint_function(
server      |   File "/usr/local/lib/python3.10/site-packages/fastapi/routing.py", line 162, in run_endpoint_function
server      |     return await run_in_threadpool(dependant.call, **values)
server      |   File "/usr/local/lib/python3.10/site-packages/starlette/concurrency.py", line 41, in run_in_threadpool
server      |     return await anyio.to_thread.run_sync(func, *args)
server      |   File "/usr/local/lib/python3.10/site-packages/anyio/to_thread.py", line 31, in run_sync
server      |     return await get_asynclib().run_sync_in_worker_thread(
server      |   File "/usr/local/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 937, in run_sync_in_worker_thread
server      |     return await future
server      |   File "/usr/local/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 867, in run
server      |     result = context.run(func, *args)
server      |   File "/chroma/./chromadb/server/fastapi/__init__.py", line 136, in create_collection
server      |     return self._api.create_collection(
server      |   File "/chroma/./chromadb/api/local.py", line 69, in create_collection
server      |     return Collection(
server      |   File "/chroma/./chromadb/api/models/Collection.py", line 56, in __init__
server      |     self._embedding_function = ef.SentenceTransformerEmbeddingFunction()
server      |   File "/chroma/./chromadb/utils/embedding_functions.py", line 9, in __init__
server      |     from sentence_transformers import SentenceTransformer
server      |   File "/usr/local/lib/python3.10/site-packages/sentence_transformers/__init__.py", line 3, in <module>
server      |     from .datasets import SentencesDataset, ParallelSentencesDataset
server      |   File "/usr/local/lib/python3.10/site-packages/sentence_transformers/datasets/__init__.py", line 3, in <module>
server      |     from .ParallelSentencesDataset import ParallelSentencesDataset
server      |   File "/usr/local/lib/python3.10/site-packages/sentence_transformers/datasets/ParallelSentencesDataset.py", line 4, in <module>
server      |     from .. import SentenceTransformer
server      |   File "/usr/local/lib/python3.10/site-packages/sentence_transformers/SentenceTransformer.py", line 11, in <module>
server      |     import transformers
server      |   File "/usr/local/lib/python3.10/site-packages/transformers/__init__.py", line 26, in <module>
server      |     from . import dependency_versions_check
server      |   File "/usr/local/lib/python3.10/site-packages/transformers/dependency_versions_check.py", line 41, in <module>
server      |     require_version_core(deps[pkg])
server      |   File "/usr/local/lib/python3.10/site-packages/transformers/utils/versions.py", line 123, in require_version_core
server      |     return require_version(requirement, hint)
server      |   File "/usr/local/lib/python3.10/site-packages/transformers/utils/versions.py", line 117, in require_version
server      |     _compare_versions(op, got_ver, want_ver, requirement, pkg, hint)
server      |   File "/usr/local/lib/python3.10/site-packages/transformers/utils/versions.py", line 45, in _compare_versions
server      |     raise ValueError(
server      | ValueError: Unable to compare versions for numpy>=1.17: need=1.17 found=None. This is unusual. Consider reinstalling numpy.
server      | 2023-04-20 15:15:39 INFO     uvicorn.access  <IP_ADDRESS>:54840 - "POST /api/v1/collections HTTP/1.1" 500

Hi Claudio! Seems like you hit a bump. :)
I've watched the video, first of all I want to make you aware that script is not indented to be manually, terraform will execute it on start when deploying with terraform apply - See reference here
Nonetheless from what I see it seems to be an issue with that version of chroma. Have you tried with latest? 0.3.22.dev36
Simply replace ghcr.io/chroma-core/chroma:0.3.14 to ghcr.io/chroma-core/chroma:0.3.22.dev36

I tried before with 0.3.15 and now with 0.3.22.dev36 and I'm getting the same:

I skipped Terraform because I'm not using GCP, but I follow your recommendation of using the chroma repository directly and it's working now. Thank you !!


incremental ci build processes

Important issue where we can explore this on CI: https://github.com/tenstorrent/tt-metal/issues/11442

Is this a duplicate of #11442 ?

YA I guess so


Fixes 4665: improve error responses for upload apis

Summary
This fixes the error responses for the upload APIs
Testing steps

Create an upload with a size of 0 or less. You should see this error in the response:

{
    "errors": [
        {
            "status": 400,
            "title": "error creating upload",
            "detail": "upload size must be greater than 0"
        }
    ]
}

Create an upload with a size greater than 0 and upload a chunk with the wrong Content-Range start and end bytes. You should see this error in the response:

{
    "errors": [
        {
            "status": 400,
            "title": "error uploading chunk",
            "detail": "uploading file chunk: 400 Bad Request: {\"non_field_errors\":[\"Chunk size does not match content range.\"]}"
        }
    ]
}

Try to upload a chunk without a file in the request. You should see a 400 response code instead of a 500

/retest

small nitpick, everything else works great and looks great

Hi
In [6]: ls -laZ /tmp/testaa
-rw-r--r--. 1 sjw sjw unconfined_u:object_r:user_tmp_t:s0 7056 Sep 10 13:44 /tmp/testaa

In [7]: app.content_sources.rest_client.repositories_api.create_upload({"size": 7056})
2024-09-12 11:35:53.099 [    INFO] [iqe.base.rest_client] REST: POST https://ee-mnkask2u.apps.crc-eph.r9lp.p1.openshiftapps.com/api/content-sources/v1/repositories/uploads/ with query params [] and x-rh-insights-request-id=a<>9
Out[7]:
{'created': '2024-09-12T10:35:53.047322Z',
 'last_updated': '2024-09-12T10:35:53.04734Z',
 'size': 7056,
 'upload_uuid': '0191e5cd-c356-7b62-b659-0103ea715995'}

In [8]: with open('/tmp/testaa', 'rb') as file:
   ...:     response = app.content_sources.rest_client.repositories_api.upload_chunk('0191e5cd-c356-7b62-b659-0103ea715995', 'bytes 0-666/*', file, 'f78250d172b47cead1373a996a4cab330fb8d7d2aa59d864355ea7ef5767706
   ...: 5')
   ...:

<snip traceback>
HTTP response body: {"errors":[{"status":400,"title":"error uploading chunk","detail":"uploading file chunk: 400 Bad Request: {\"non_field_errors\":[\"Chunk size does not match content range.\"]}"}]}

In [11]: app.content_sources.rest_client.repositories_api.create_upload({"size": 0})
2024-09-12 11:41:34.239 [    INFO] [iqe.base.rest_client] REST: POST https://ee-mnkask2u.apps.crc-eph.r9lp.p1.openshiftapps.com/api/content-sources/v1/repositories/uploads/
<snip traceback>
HTTP response body: {"errors":[{"status":400,"title":"error creating upload","detail":"upload size must be greater than 0"}]}


Added resizeable window functions

Added the resizeable and set_resizeable functions to check and set whether the window is resizeable. Tested to work as intended on MacOS 14.5 and Windows 11 computers.
The original libui-ng project opts for the UK spelling "resizeable" as opposed to the US spelling "resizable". I've opted to stick with the former for consistency with the base project, but a spellchecker may mark it as misspelled.

Thanks for the contribution! I must have missed those functions.


Add import blueprint button.

In the new HA update they announce My Home Assistant buttons, so I'm adding it here.

Great call, I'm loving these buttons!

me too!


Django 3.0 Support?

Just curious if there is a version of this out there (or plans for this) that will be supporting Django 3.0.
Currently looking to tryout the 3.0 features and since this forked worked with 2.2 I wasn't sure if 3.0 support would be added.

Yes there are definitely plans to support Django 3.0. I've created #19 with some initial testing and fixes.

@OskarPersson great!  I figured there would be plans, excited to see once it gets all squared away and give it a shot.

Django 3.0 has been released now.


Allow a RequestReader to be used as a Finagle Service

In this case I might be missing something obvious which makes this PR obsolete. But I was wondering about the ways to combine a reader with Finagle Services and found examples like this in the documentation:
val user: RequestReader[User] = for {
  name <- RequiredParam("name")
  age <- RequiredParam("age").as[Int]
  city <- OptionalParam("city")
} yield User(name, age, city.getOrElse("Novosibirsk"))

val service = new Service[HttpRequest, Json] {
  def apply(req: HttpRequest) = for {
    u <- user(req)
  } yield Json.obj(
    "name" -> u.name,
    "age" -> u.age,
    "city" -> u.city
  )
}

This shows the use of a reader inside a service implementation. This is convenient for small and simple services, but for a bigger application I might prefer to have the reader itself as a pluggable service:
case class MyRequest(request: HttpRequest)

val userReader: RequestReader[User] = ???

val userService: Service[MyRequest, User] = userReader.asService[MyRequest]

val profileService: Service[User, UserProfile] = ???

userService ! profileService ! TurnIntoHttp[UserProfile]

The reader becomes usable as a Finagle service through "fixing" the request type it can handle.
This way, apart from using the reader inside a service implementation, it can also be composed
with existing services that only deal with domain objects and not with anything HTTP.
This PR implements the asService[Req] method shown above.
Is this a bad idea? Can the same be achieved by other means?
If this PR is seen as useful it would be cool to squeeze it into 0.5.0.

Coverage increased (+0.05%) to 91.1% when pulling bec94ee468ec5a84c1347509d405d23876c35c88 on Sphonic:reader-as-service into 8e42d7e36700951b268d96527e2801fb13b574ad on finagle:master.

Coverage increased (+0.05%) to 91.1% when pulling bec94ee468ec5a84c1347509d405d23876c35c88 on Sphonic:reader-as-service into 8e42d7e36700951b268d96527e2801fb13b574ad on finagle:master.

Coverage increased (+0.05%) to 91.1% when pulling bec94ee468ec5a84c1347509d405d23876c35c88 on Sphonic:reader-as-service into 8e42d7e36700951b268d96527e2801fb13b574ad on finagle:master.

Coverage increased (+0.05%) to 91.1% when pulling 3a46d5db7f6e8d724269fbf50ff96198eadcb2b4 on Sphonic:reader-as-service into 8e42d7e36700951b268d96527e2801fb13b574ad on finagle:master.

Coverage increased (+0.05%) to 91.1% when pulling 58d0ccb1aa0adcffec90cf9a70909212797ccb8a on Sphonic:reader-as-service into 8e42d7e36700951b268d96527e2801fb13b574ad on finagle:master.

Coverage increased (+0.05%) to 91.1% when pulling 58d0ccb1aa0adcffec90cf9a70909212797ccb8a on Sphonic:reader-as-service into 8e42d7e36700951b268d96527e2801fb13b574ad on finagle:master.

Coverage increased (+0.05%) to 91.1% when pulling 1cee39c3e2e4a5022be0688bc1a2dcde641b9c5c on Sphonic:reader-as-service into 8e42d7e36700951b268d96527e2801fb13b574ad on finagle:master.

I generally like the idea. I think we can merge this into 0.5.0. I was just wondering if it's possible to use an implicit conversion here.

Your question about implicits made me think about it. I'm not sure the idea is mature enough, so I would not mind if you want to keep it open for 0.6.0. The reason is that, unless I'm overlooking something, I think asService[Req] currently only makes sense if Req is not a custom type. In which case it is often the first service, so that we cannot easily use an implicit.
But I would not know how to use asService with a custom request type. Because then the reader would potentially spit out some domain object and the additional information of the custom request is lost for the subsequent service. And while it is possible to use custom request objects with readers, there currently is no easy way to access any information from the custom request inside the reader.
This might be something where we need to wait for the most elegant usage patterns to emerge.

Yeah. I see. Let's postpone this for the next release then.

Closing this as these ideas are superseded by the new direction.


Support Java 17 LTE

We should probably have a version of the action that supports Java 17 now that it's the latest long term support release.
This probably means coming up with a new tagging scheme, something like jbangver-javaver, eg 0.83.0-11, 0.83.1-17 and a tag 0.83.1 that refers to one of those, for now it should probably remain 11.

Now I use https://gist.github.com/maxandersen/f077f1d356c42eeb395a8811d6152f3a to build Hello.java Docker image with Java 17.  it's some slow to download JDK 17 by JBang.

+1 on finding way to build multiple versions per java and publish.

Hi! We require JDK 21. As a workaround, we have checked out the repo and made this change to the Dockerfile and pushed the image to our own image registry:
FROM eclipse-temurin:21-jdk-alpine

As proposed earlier we also have chosen a suffix indicating the JRE flavor and release: jbang-action:v0.113.0-temurin21
Maybe something like this could be achieved with a GHA matrix based build, and keeping JDK 11 the default for backwards compatibility when no Java release suffix is present.

I have start at https://github.com/jbangdev/jbang/pull/1654 but haven't had time to finish it.
Ps. In github actions I recommend using setup-jbang rather than the container image these days. It allows setting up specific java version with caching using setup-java.

Just adding the link for easy reference: https://github.com/marketplace/actions/setup-jbang


Fixed Built Doc Files from zipping.

As the upload-artifact action already zips the file, the prior manual compression in the file is unnecessary and leads to "double compression" which is only uncompressed once during deployment stage. Hence, the lines of manual compression were omitted to fix this issue.

Uploading the doc artifact now takes 13 min instead of 35 sec. Not zipping the doc artifact fixes the deployment, so we can zip it when we don't need to deploy.

Pinging here @MaxJPRey. I know PyAEDT run into a similar issue at some point but after checking their CI/CD pipelines it looks like they are no longer compressing the artifact.
I guess we could add an input parameter in pyansys actions to unzip the different artifacts.

Pinging here @MaxJPRey. I know PyAEDT run into a similar issue at some point but after checking their CI/CD pipelines it looks like they are no longer compressing the artifact.
I guess we could add an input parameter in pyansys actions to unzip the different artifacts.

Agreed to expose the argument to unzip the content.

I just opened https://github.com/pyansys/actions/issues/143 to implement this.

Now that the decompress logic got added in the pyansys/actions, could you use the decompress_artifact input variable, @alikasim72?

Updated the code by adding back the compression code lines and setting the decompress_artifact to True.


Fixed statement + work towards three lines lemma

I (hopefully) fixed the statement of the three lines lemma (minus writing the hypothesis of vanishing at infinity nicely in case 1) and split it into the different cases. I almost proved the general statement assuming the others, and the general statement on the unit strip assuming the previous ones.

Thanks!


Unsupported operand type(s) for +: 'int' and 'NoneType'

We are seeing the following error when trying to generate a report using the SparkCompare class
[/local_disk0/.ephemeral_nfs/envs/pythonEnv-b98b2871-d4e2-49c1-aaf2-bf7393cece46/lib/python3.9/site-packages/datacompy/sparkcompare.py](https://file+.vscode-resource.vscode-cdn.net/local_disk0/.ephemeral_nfs/envs/pythonEnv-b98b2871-d4e2-49c1-aaf2-bf7393cece46/lib/python3.9/site-packages/datacompy/sparkcompare.py) in report(self, file)
    854         self._merge_dataframes()
    855         self._print_num_of_rows_with_column_equality(file)
--> 856         self._print_row_matches_by_column(file)

[/local_disk0/.ephemeral_nfs/envs/pythonEnv-b98b2871-d4e2-49c1-aaf2-bf7393cece46/lib/python3.9/site-packages/datacompy/sparkcompare.py](https://file+.vscode-resource.vscode-cdn.net/local_disk0/.ephemeral_nfs/envs/pythonEnv-b98b2871-d4e2-49c1-aaf2-bf7393cece46/lib/python3.9/site-packages/datacompy/sparkcompare.py) in _print_row_matches_by_column(self, myfile)
    687             if self.columns_match_dict[key][MatchType.MISMATCH.value]
    688         }
--> 689         columns_fully_matching = {
    690             key: self.columns_match_dict[key]
    691             for key in self.columns_match_dict

[/local_disk0/.ephemeral_nfs/envs/pythonEnv-b98b2871-d4e2-49c1-aaf2-bf7393cece46/lib/python3.9/site-packages/datacompy/sparkcompare.py](https://file+.vscode-resource.vscode-cdn.net/local_disk0/.ephemeral_nfs/envs/pythonEnv-b98b2871-d4e2-49c1-aaf2-bf7393cece46/lib/python3.9/site-packages/datacompy/sparkcompare.py) in (.0)
    690             key: self.columns_match_dict[key]
    691             for key in self.columns_match_dict
--> 692             if sum(self.columns_match_dict[key])
...
TypeError: unsupported operand type(s) for +: 'int' and 'NoneType'

Here is a sample of the base dataset

Here is a sample of the compare dataset

Would be helpful to get some minimal code to reproduce the error. Can you potentially convert the above screenshots of datasets into some actual code and share how you are calling datacompy so I could reproduce it locally?

Hello,
We are facing the same issue, it is caused by a simple .report(file). The issue appears on certain datasets and not all of them for the same code.
master_frame = spark.read.options(header=True, compression="gzip", sep=";")
    .csv(path, schema)
candidate_frame = spark.read.options(header=True, compression="gzip", sep=";")
    .csv(path1, schema)

comparison = datacompy.SparkCompare(
            spark,
            master_frame,
            candidate_frame,
            join_columns=[
                "col1",
                "col2",
                "col3",
                "col4",
                "col5",
                "col6",
                "col7",
            ],
        )

today = datetime.date.today()
report_name = f"report_{today}.txt"

with open(
    f"s3://{path}/reports/{today.year}/{today.month:02d}/{today.day:02d}/{report_name}",
    "w",
) as f:
    f.write(
        f"Report CSV Compare : {today.year}/{today.month:02d}/{today.day:02d}"
    )
    mic_comparison.report(file=f)

Sorry for the delay. I’m at PyCon and PyData this week. I’ll take a look at this next week or later this week when I have some time.

So circling back to this. I'm able to recreate the issue with the following minimal code:
from datacompy import SparkCompare
from pyspark.sql import SparkSession
from pyspark.sql.types import *

spark = SparkSession.builder.appName(
  "test").getOrCreate()

schema = StructType(
   [
       StructField('a', IntegerType(), True),
       StructField('b', StringType(), True),
       StructField('c', IntegerType(), True),
   ]
 )

sdf1 = spark.createDataFrame(
    [
        (1, None , 1),
        (2, None , 2),
        (3, None , 3),
    ],
    schema=schema
)

sdf2 = spark.createDataFrame(
    [
        (1, None , 1),
        (2, None , 2),
        (3, None , 3),
    ],
    schema=schema
)

compare = SparkCompare(spark_session=spark, base_df=sdf1, compare_df=sdf2, join_columns=["a", "b"])

I believe this has to do with the fact the current version of the SparkCompare is NOT null safe. You can see this issue: #147. I do have a refactor in the following PR/Branch sitting for review (#195)
I did try and change the compare here to be null safe and I think it fixes the issue.
Changing this line: https://github.com/capitalone/datacompy/blob/develop/datacompy/sparkcompare.py#L454 to look like this:
                ["A." + name + "<=>B." + name for name in self._join_column_names]

stops the error as far as I have tested.
I have a small fix on this branch. Can you test it out to see if this fixes your issue. We have a larger refactor in the works so I'm happy to cut a quick release until that is ready.

@jpvillemalard @mwa28 If you have time to test out v0.9.0 once it is released. I think it should address your issue.

Thank you for your time and the fix. We will be sure to do so once released.


MINOR: Use the correct processor id in the processor thread name

This restores the behaviour before 1265d7cb7.

Tests passed locally.

Thanks for the patch. LGTM

This restores the behaviour before 1265d7cb7.


fix logos to scroll from middle

Proposed changes
fixes for https://github.com/pulumi/docs/issues/12460 discussion

Unreleased product version (optional)

Related issues (optional)

@shughes26 is this still an active PR? Should it be merged?

Merged in a different PR