Failures with initialization, control, feedback, and during idle: various Cannot read properties of undefined

Hello! This is a great plugin, thank you for your work, it is amazing!
Summary
I am reporting a few issues I faced when setting up a bare new Homebridge server with this plugin, no customization, no playing around with JSONs, just following the quick start guides. I think they are interconnected, hence reporting at once. What I have is several Zigbee and Wi-Fi SONOFF devices operated previously through eWeLink: some of them work as expected, while others fail to initialize or update their state.
Issues
Some of my devices successfully initialized and showed information in HomeKit, such as temperature and humidity sensors SNZB-02 and RGB light strip L3-5M-P (PRO version). However, others either A) cannot initialize at all, such as Wi-Fi smart plugs S40TPB, door/window sensors SNZB-04; or B) cannot properly update state which is happening to RGB light strip L3-5M (non-PRO version) which results in suboptimal experience. Light strip L3-5M also reports failed initialization but reacts to controls in HomeKit.
For A) this results in no control and feedback from Wi-Fi smart plugs S40TPB, and door/window sensors SNZB-04. Any external action such as closing the door/window does not result in any logs, which is expected since these devices were not initialized.
For B) light strip L3-5M shows "No Response" in HomeKit in some actions and the state becomes out of sync. External action such as turning the light on or off using the button on the strip does not result in logs either. My first impression this happens when the color changes or the light strip is turned off. Not when turned on or changed brightness.
C) After some random time with no particular external action system fails after another Cannot read properties of undefined and reboots, please see the logs below. Not clear which device update triggers this, but this happens sooner or later.
While I understand these issues are separate, given the seniority of the plugin and support of a wide range of devices I feel like these are all already troubleshooted, and what I faced should be something simple, cross-cutting that is missed.
D) The last thing I observed when clicking on SNZB-01 buttons that were previously configured to trigger certain scenes in eWeLink with the devices that were not initialized in Homebridge, all buttons become unresponsive. This must be something connected to the eWeLink cloud because no related logs/errors were reported in Homebridge.
I am using Libre Computer Sweet Potato AML-S905X-CC-V2 with Raspbian 12 Bookworm (regular, desktop version), again this is a bare new setup done specifically to use this plugin and Homebridge. No CPU or memory overload was observed through Homebridge, all were pretty stable: few % CPU load, ~1.3 GB memory available, ~41 C temperature.
Setup

Libre Computer Sweet Potato AML-S905X-CC-V2 running Raspbian 12 Bookworm (regular, desktop version) with latest updates
Node.js v20.15.0
npm v10.7.0
Homebridge v1.8.3 (latest)
Homebridge UI v4.56.4 (latest)
Homebridge eWeLink v12.3.0 (latest) - the only plugin installed

Installation was done according to these guides:

https://github.com/homebridge/homebridge/wiki/Install-Homebridge-on-Raspbian#installing-homebridge
https://github.com/bwp91/homebridge-ewelink/wiki/Installation#homebridge-ui--hoobs

Devices

SONOFF Zigbee Bridge Pro - works as connected devices shown
3 x SONOFF SNZB-01 Button - works with issues most likely connected to scenarios (see D)
3 x SONOFF SNZB-02 Temp/Humidity Sensor - works
3 x SONOFF SNZB-04 Door/Window Sensor - do not work (see A)
SONOFF L3-5M (non-PRO version) RGB strip - works with issues (see B)
SONOFF L3-5M-P (PRO version) RGB strip - works
3 x SONOFF Smart Plug S40TPB - do not work (see A)

Logs
Please click on Details to show the extended part of the logs.
A) [X] could not be initialised as Cannot read properties of undefined
S40TPB:
[7/15/2024, 10:52:56 AM] [eWeLink] [TV] could not be initialised as Cannot read properties of undefined (reading 'UINT16') at new CurrentConsumption (file:///var/lib/homebridge/node_modules/homebridge-ewelink/lib/utils/eve-chars.js:22:29).

L3-5M:
[7/15/2024, 10:52:56 AM] [eWeLink] [Bedroom Light] could not be initialised as Cannot read properties of undefined (reading 'BOOL') at new FestiveScene (file:///var/lib/homebridge/node_modules/homebridge-ewelink/lib/utils/custom-chars.js:23:29).

SNZB-04:
[7/15/2024, 10:52:56 AM] [eWeLink] [Bedroom Window] could not be initialised as Cannot read properties of undefined (reading 'UINT32') at new ResetTotal (file:///var/lib/homebridge/node_modules/homebridge-ewelink/lib/utils/eve-chars.js:70:29).

Details
[7/15/2024, 10:52:47 AM] Homebridge v1.8.3 (HAP v0.12.2) (Homebridge 5B07) is running on port 51009.
[7/15/2024, 10:52:47 AM] Homebridge v1.8.3 (HAP v0.12.2) (Homebridge 5B07) is running on port 51009.
[7/15/2024, 10:52:49 AM] [Homebridge UI] [HapClient] Discovery :: Found HAP device with username 0E:0D:BB:82:5B:07
[7/15/2024, 10:52:49 AM] [Homebridge UI] [HapClient] Discovery :: Testing 0E:0D:BB:82:5B:07 via http://<IP_ADDRESS>:51009/accessories
[7/15/2024, 10:52:50 AM] [Homebridge UI] [HapClient] Discovery :: Success 0E:0D:BB:82:5B:07 via http://<IP_ADDRESS>:51009/accessories
[7/15/2024, 10:52:50 AM] [Homebridge UI] [HapClient] Discovery :: [<IP_ADDRESS>:51009 (0E:0D:BB:82:5B:07)] Instance Registered
[7/15/2024, 10:52:50 AM] [eWeLink] Fetching devices from eWeLink home/id [My Home] [6376beefdeb588000867e25b].
[7/15/2024, 10:52:55 AM] [eWeLink] LAN monitoring started.
[7/15/2024, 10:52:55 AM] [eWeLink] [Livingroom Sensor] initialising with options {"humidityOffset":0,"logging":"standard","lowBattThreshold":25,"offset":0}.
[7/15/2024, 10:52:55 AM] [eWeLink] [Livingroom Sensor] initialised and LAN mode unavailable as not discovered/supported [1770:ZCL_HA_DEVICEID_TEMPERATURE_SENSOR].
[7/15/2024, 10:52:56 AM] [eWeLink] [Kitchen Sensor] initialising with options {"humidityOffset":0,"logging":"standard","lowBattThreshold":25,"offset":0}.
[7/15/2024, 10:52:56 AM] [eWeLink] [Kitchen Sensor] initialised and LAN mode unavailable as not discovered/supported [1770:ZCL_HA_DEVICEID_TEMPERATURE_SENSOR].
[7/15/2024, 10:52:56 AM] [eWeLink] [LEGO Light] initialising with options {"adaptiveLightingShift":0,"brightnessStep":1,"logging":"standard","offlineAsOff":false}.
[7/15/2024, 10:52:56 AM] [eWeLink] [LEGO Light] initialised and LAN mode unavailable as not discovered/supported [173:L3-5M-P].
[7/15/2024, 10:52:56 AM] [eWeLink] [Bedroom Switch] initialising with options {"logging":"standard","lowBattThreshold":25,"sensorTimeDifference":60}.
[7/15/2024, 10:52:56 AM] [eWeLink] [Bedroom Switch] initialised and LAN mode unavailable as not discovered/supported [1000:zigbee_ON_OFF_SWITCH_1000].
[7/15/2024, 10:52:56 AM] [eWeLink] [Kitchen Switch ] initialising with options {"logging":"standard","lowBattThreshold":25,"sensorTimeDifference":60}.
[7/15/2024, 10:52:56 AM] [eWeLink] [Kitchen Switch ] initialised and LAN mode unavailable as not discovered/supported [1000:zigbee_ON_OFF_SWITCH_1000].
[7/15/2024, 10:52:56 AM] [eWeLink] [ Livingroom Switch ] initialising with options {"logging":"standard","lowBattThreshold":25,"sensorTimeDifference":60}.
[7/15/2024, 10:52:56 AM] [eWeLink] [ Livingroom Switch ] initialised and LAN mode unavailable as not discovered/supported [1000:zigbee_ON_OFF_SWITCH_1000].
[7/15/2024, 10:52:56 AM] [eWeLink] [Bedroom Sensor] initialising with options {"humidityOffset":0,"logging":"standard","lowBattThreshold":25,"offset":0}.
[7/15/2024, 10:52:56 AM] [eWeLink] [Bedroom Sensor] initialised and LAN mode unavailable as not discovered/supported [1770:ZCL_HA_DEVICEID_TEMPERATURE_SENSOR].
[7/15/2024, 10:52:56 AM] [eWeLink] [TV] could not be initialised as Cannot read properties of undefined (reading 'UINT16') at new CurrentConsumption (file:///var/lib/homebridge/node_modules/homebridge-ewelink/lib/utils/eve-chars.js:22:29).
[7/15/2024, 10:52:56 AM] [eWeLink] [Fridge] could not be initialised as Cannot read properties of undefined (reading 'UINT16') at new CurrentConsumption (file:///var/lib/homebridge/node_modules/homebridge-ewelink/lib/utils/eve-chars.js:22:29).
[7/15/2024, 10:52:56 AM] [eWeLink] [A/C] could not be initialised as Cannot read properties of undefined (reading 'UINT16') at new CurrentConsumption (file:///var/lib/homebridge/node_modules/homebridge-ewelink/lib/utils/eve-chars.js:22:29).
[7/15/2024, 10:52:56 AM] [eWeLink] [Bedroom Light] could not be initialised as Cannot read properties of undefined (reading 'BOOL') at new FestiveScene (file:///var/lib/homebridge/node_modules/homebridge-ewelink/lib/utils/custom-chars.js:23:29).
[7/15/2024, 10:52:56 AM] [eWeLink] [Bedroom Window] could not be initialised as Cannot read properties of undefined (reading 'UINT32') at new ResetTotal (file:///var/lib/homebridge/node_modules/homebridge-ewelink/lib/utils/eve-chars.js:70:29).
[7/15/2024, 10:52:56 AM] [eWeLink] [Livingroom Window] could not be initialised as Cannot read properties of undefined (reading 'UINT32') at new ResetTotal (file:///var/lib/homebridge/node_modules/homebridge-ewelink/lib/utils/eve-chars.js:70:29).
[7/15/2024, 10:52:56 AM] [eWeLink] [Door] could not be initialised as Cannot read properties of undefined (reading 'UINT32') at new ResetTotal (file:///var/lib/homebridge/node_modules/homebridge-ewelink/lib/utils/eve-chars.js:70:29).
[7/15/2024, 10:52:56 AM] [eWeLink] ✓ Setup complete. This plugin has been made with ♥ by bwp91, please consider a ☆ on GitHub if you are finding it useful!

B) [X] device update failed as Cannot read properties of undefined
L3-5M:
[7/15/2024, 11:24:54 AM] [eWeLink] [Bedroom Light] device update failed as Cannot read properties of undefined (reading 'BOOL') at new FestiveScene (file:///var/lib/homebridge/node_modules/homebridge-ewelink/lib/utils/custom-chars.js:23:29).

Details
[7/15/2024, 11:24:28 AM] [eWeLink] [Bedroom Light] current state [on].
[7/15/2024, 11:24:38 AM] [eWeLink] [Bedroom Light] current colour [rgb 245 242 255].
[7/15/2024, 11:24:38 AM] [eWeLink] [Bedroom Light] device update failed as Cannot read properties of undefined (reading 'BOOL') at new FestiveScene (file:///var/lib/homebridge/node_modules/homebridge-ewelink/lib/utils/custom-chars.js:23:29).
[7/15/2024, 11:24:42 AM] [eWeLink] [Bedroom Light] current brightness [11%].
[7/15/2024, 11:24:42 AM] [eWeLink] [Bedroom Light] current brightness [100%].
[7/15/2024, 11:24:54 AM] [eWeLink] [Bedroom Light] current state [off].
[7/15/2024, 11:24:54 AM] [eWeLink] [Bedroom Light] device update failed as Cannot read properties of undefined (reading 'BOOL') at new FestiveScene (file:///var/lib/homebridge/node_modules/homebridge-ewelink/lib/utils/custom-chars.js:23:29).

C) TypeError: Cannot read properties of undefined (reading 'markStatus')
[7/15/2024, 11:02:34 AM] TypeError: Cannot read properties of undefined (reading 'markStatus')
    at default.receiveDeviceUpdate (file:///var/lib/homebridge/node_modules/homebridge-ewelink/lib/platform.js:1911:31)
    at EventEmitter.<anonymous> (file:///var/lib/homebridge/node_modules/homebridge-ewelink/lib/platform.js:594:54)
    at EventEmitter.emit (node:events:519:28)
    at file:///var/lib/homebridge/node_modules/homebridge-ewelink/lib/connection/ws.js:230:25
    at Timeout._onTimeout (/var/lib/homebridge/node_modules/homebridge-ewelink/node_modules/chnl/dist/channel.cjs.js:2:4848)
    at listOnTimeout (node:internal/timers:573:17)
    at processTimers (node:internal/timers:514:7)

Details
[7/15/2024, 10:52:56 AM] [eWeLink] ✓ Setup complete. This plugin has been made with ♥ by bwp91, please consider a ☆ on GitHub if you are finding it useful!
[7/15/2024, 10:53:41 AM] [Homebridge UI] [HapClient] Discovery :: Ended
[7/15/2024, 11:02:34 AM] TypeError: Cannot read properties of undefined (reading 'markStatus')
    at default.receiveDeviceUpdate (file:///var/lib/homebridge/node_modules/homebridge-ewelink/lib/platform.js:1911:31)
    at EventEmitter.<anonymous> (file:///var/lib/homebridge/node_modules/homebridge-ewelink/lib/platform.js:594:54)
    at EventEmitter.emit (node:events:519:28)
    at file:///var/lib/homebridge/node_modules/homebridge-ewelink/lib/connection/ws.js:230:25
    at Timeout._onTimeout (/var/lib/homebridge/node_modules/homebridge-ewelink/node_modules/chnl/dist/channel.cjs.js:2:4848)
    at listOnTimeout (node:internal/timers:573:17)
    at processTimers (node:internal/timers:514:7)
[7/15/2024, 11:02:34 AM] TypeError: Cannot read properties of undefined (reading 'markStatus')
    at default.receiveDeviceUpdate (file:///var/lib/homebridge/node_modules/homebridge-ewelink/lib/platform.js:1911:31)
    at EventEmitter.<anonymous> (file:///var/lib/homebridge/node_modules/homebridge-ewelink/lib/platform.js:594:54)
    at EventEmitter.emit (node:events:519:28)
    at file:///var/lib/homebridge/node_modules/homebridge-ewelink/lib/connection/ws.js:230:25
    at Timeout._onTimeout (/var/lib/homebridge/node_modules/homebridge-ewelink/node_modules/chnl/dist/channel.cjs.js:2:4848)
    at listOnTimeout (node:internal/timers:573:17)
    at processTimers (node:internal/timers:514:7)
[7/15/2024, 11:02:34 AM] TypeError: Cannot read properties of undefined (reading 'markStatus')
    at default.receiveDeviceUpdate (file:///var/lib/homebridge/node_modules/homebridge-ewelink/lib/platform.js:1911:31)
    at EventEmitter.<anonymous> (file:///var/lib/homebridge/node_modules/homebridge-ewelink/lib/platform.js:594:54)
    at EventEmitter.emit (node:events:519:28)
    at file:///var/lib/homebridge/node_modules/homebridge-ewelink/lib/connection/ws.js:230:25
    at Timeout._onTimeout (/var/lib/homebridge/node_modules/homebridge-ewelink/node_modules/chnl/dist/channel.cjs.js:2:4848)
    at listOnTimeout (node:internal/timers:573:17)
    at processTimers (node:internal/timers:514:7)
[7/15/2024, 11:02:34 AM] Got SIGTERM, shutting down Homebridge...
[7/15/2024, 11:02:39 AM] [HB Supervisor] Homebridge Process Ended. Code: 143, Signal: null
[7/15/2024, 11:02:44 AM] [HB Supervisor] Restarting Homebridge...

Hi @loginov-rocks
Please can you try updating to the beta version I just pushed, 12.3.1-beta.0?
There is some instructions here if you need them, but the screenshots are a little out of date for the UI!
https://github.com/homebridge/homebridge/wiki/How-to-Install-Alternate-Plugin-Versions

Hi @bwp91 ! Brilliant, thank you for such a quick response! Installed v12.3.1-beta.2 - everything works flawlessly! Can't confirm whether the C) was fixed since it has appeared only after some time, but looking at the change you did this seems indeed to be something cross-cutting, so hopefully it's fixed as well. Thank you again!


added test coverage using nyc

This adds NYC / ISTANBUL as coverage instrumenting. I currently open this PR into master and would keep it open until we have a working branching strategy

One note: nyc is the successor for istanbul so it's all good


Help for decoding after loading the model

Hello I am trying the translate_ende_wmt32k problem given in the walk-through. Trained the model and during inference I don't want to decode file on a whole but want to decode sentence by sentence as they come so that I load the model only once and wait for input to decode them as they come. Any help on how it could be done ?
Thanks.

You can try --decode_interactive https://github.com/tensorflow/tensor2tensor/blob/master/tensor2tensor/bin/t2t_decoder.py#L54
(or t2t query server).


Poetry

@Didayolo, @bbearce
Question 1
In the project we have these two files:

pyproject.toml
poetry.lock

When I want to update a package, I should update pyproject.toml right?
Question 2
In the Dockerfile the specified python version is 3.9 but in pyproject.toml it is ^3.10. Is this inconsistent or on purpose?
Question 3
In the Dockerfile we have these lines:
COPY pyproject.toml ./
COPY poetry.lock ./

RUN poetry install

This means we are copying pyproject.toml  and poetry.lock. Will RUN poetry install regenerate the lock file?

I am asking these because I am updating a package bpython in pyproject.toml and I am rebuilding the django container which gives me this error:
[+] Building 2.9s (13/14)
 => [internal] load build definition from Dockerfile                                                                                0.0s
 => => transferring dockerfile: 32B                                                                                0.0s
 => [internal] load .dockerignore                                                                                0.0s
 => => transferring context: 34B                                                                                0.0s
 => [internal] load metadata for docker.io/library/python:3.9                                                                                2.1s
 => [auth] library/python:pull token for registry-1.docker.io                                                                                0.0s
 => [1/9] FROM docker.io/library/python:3.9@sha256:47d6f16aa0de11f2748c73e7af8d40eaf44146c6dc059b1d0aa1f917f8c5cc58                                                                 0.0s
 => [internal] load build context                                                                                0.0s
 => => transferring context: 1.78kB                                                                                0.0s
 => CACHED [2/9] RUN apt-get update && apt-get install -y gcc build-essential && rm -rf /var/lib/apt/lists/*                                                                        0.0s
 => CACHED [3/9] RUN curl -sSL https://install.python-poetry.org | python3 -                                                                                0.0s
 => CACHED [4/9] RUN poetry config virtualenvs.create false                                                                                0.0s
 => CACHED [5/9] RUN poetry config virtualenvs.in-project false                                                                                0.0s
 => [6/9] COPY pyproject.toml ./                                                                                0.0s
 => [7/9] COPY poetry.lock ./                                                                                0.0s
 => ERROR [8/9] RUN poetry install                                                                                0.7s
------
 > [8/9] RUN poetry install:
#0 0.383 The currently activated Python version 3.9.19 is not supported by the project (^3.10).
#0 0.383 Trying to find and use a compatible version.
#0 0.420 Using python3.11 (3.11.2)
#0 0.421 Skipping virtualenv creation, as specified in config file.
#0 0.490 Installing dependencies from lock file
#0 0.634
#0 0.634 pyproject.toml changed significantly since poetry.lock was last generated. Run `poetry lock [--no-update]` to fix the lock file.
------
failed to solve: executor failed running [/bin/sh -c poetry install]: exit code: 1
(base) ihsanullah@Pixel-io codabench %

Are you using the updated version of the Dockerfile.flower? #1520
No, but I have already built the flower from the dockerfile in #1520. I am just trying to build django by deleting the image and then running docker-compose up -d

Question 1: "When I want to update a package, I should update pyproject.toml right?"
Yes for both. We need to edit the toml file and then we need to recreate the lock file. It is a little complex but here is a quick way to do it:
When services are running, make change to pyproject.toml, as it is mounted in with -v flag. Then regenerate lock with:
docker compose exec django poetry lock

because it is mounted in, it should be available in the codabench directory.
It gets a little more complex if you change the python version of Dockerfile. In that case, build docker image with new python and use new image with above command.
Question 2: Inconsistent and should be 3.9 or something more speccific.
Question 3: No, poetry install will install the lock packages exactly as they are. To regenerate lock file we need poetry lock.


Postgres UNNEST in query! macro does not allow Optionals

Bug Description
Postgres UNNEST in query! macro does not allow Optionals.  I want to insert a Vec<Option<String>> but only a Vec<String> is allowed.  I checked on discord and no one seemed to have a way around this.
I think adding built-in support for Optional into the macro for unnest would be very useful.  Additionally I think it could be useful to add some kind of type override like you can for selecting data, 'data as "data:? text[]" or similar.
Minimal Reproduction
CREATE TABLE public.unnest_test (
	id int4 NOT NULL GENERATED ALWAYS AS IDENTITY,
	"data" text NULL,
	CONSTRAINT temp_pk PRIMARY KEY (id)
);

#[tokio::main]
async fn main() {
    let db_conn = std::env::var("DATABASE_URL").unwrap();
    let pool = sqlx::postgres::PgPoolOptions::new()
        .max_connections(5)
        .connect(&db_conn)
        .await
        .unwrap();

    // works
    // let data: Vec<String> = vec![];

    // fails
    let data: Vec<Option<String>> = vec![];

    sqlx::query!(
        r#"
            INSERT INTO unnest_test (data)
            SELECT * FROM UNNEST($1::text[])
        "#,
        data.as_slice(),
    )
    .execute(&pool)
    .await
    .unwrap();
}

Info

SQLx version: "0.7.1"
SQLx features enabled: "postgres", "runtime-tokio"
Database server and version: PostgreSQL 15.4 on x86_64-pc-linux-gnu, compiled by gcc (GCC) 12.3.1 20230508 (Red Hat 12.3.1-1), 64-bit
Operating system: Fedora Linux 37 (Workstation Edition)
rustc --version: rustc 1.72.0 (5680fa18f 2023-08-23)

There is already an issue for this here https://github.com/launchbadge/sqlx/issues/576.
A good fix for this is here https://github.com/launchbadge/sqlx/issues/576#issuecomment-1531611544.


Bug: !info doesn't work with replies

!info gets no params with replies. I don't know why.

Was this only in twitch or does it also happen in discord?


T337002 api

I've moved all API classes into a separate folder,
as I felt like grouping modules improves readability.
APIs themselves had storage logic which I extracted and put
in another folder. I was originally going with an interface
to the storage to allow for other storage methods than
log entries, but the code was too tightly coupled with it,
so I've left that for another day. Added dependency injection
for all services and used ServiceOptions for config vars.

https://gerrit.wikimedia.org/r/c/mediawiki/extensions/Thanks/+/921397


hashes-equal? no longer returns #t when actual is empty.

There was a minor problem with 'hashes-equal?'. When actual is empty it would always return #t.

Thanks. Can you rebase?

No problem!  I rebased, let me know if there is a problem.

Thanks!


OpenAI's legacy completion API causes that stop words do not work, patches are attached.

Checked other resources

[X] I added a very descriptive title to this issue.
[X] I searched the LangChain documentation with the integrated search.
[X] I used the GitHub search to find a similar question and didn't find it.
[X] I am sure that this is a bug in LangChain rather than my code.
[X] The bug is not resolved by updating to the latest stable version of LangChain (or the specific integration package).

Example Code
The patches are listed below:
diff -x *.pyc -r ~/venv/lib/python3.9/site-packages/langchain_openai/llms/base.py langchain_openai/llms/base.py
207c207,210
<             values["client"] = openai.OpenAI(**client_params).completions
---
>             client = openai.OpenAI(**client_params)
>             completion = client.chat.completions
>             values["client"] = completion
>             #values["client"] = openai.OpenAI(**client_params).completions
340c343,352
<                 response = self.client.create(prompt=_prompts, **params)
---
>                 from openai.types.chat.chat_completion_user_message_param import ChatCompletionUserMessageParam
>
>                 umessage = ChatCompletionUserMessageParam(content=_prompts[0], role = "user")
>                 messages=[umessage,]
>                 response = self.client.create(messages=messages, **params)
>                 #response = self.client.create(prompt=_prompts, **params)
454c466,467
<                         text=choice["text"],
---
>                         #text=choice["text"],
>                         text=choice["message"]["content"],

Error Message and Stack Trace (if applicable)

Given an input question, first create a syntactically correct postgresql query to run, then look at the results of the query and return the answer.
Use the following format:

Question: Question here
SQLQuery: SQL Query to run
SQLResult: Result of the SQLQuery
Answer: Final answer here

how many tasks?

SQLQuery:SELECT COUNT(*) FROM tasks
SQLResult:
count
-----
3
Answer: There are 3 tasks in the tasks table.(psycopg2.errors.SyntaxError) syntax error at or near ":"
LINE 2: SQLResult:
                 ^

[SQL: SELECT COUNT(*) FROM tasks
SQLResult:
count
-----
3
Answer: There are 3 tasks in the tasks table.]
(Background on this error at: https://sqlalche.me/e/20/f405)
Traceback (most recent call last):
  File "/Users/marvel/venv/lib/python3.9/site-packages/sqlalchemy/engine/base.py", line 1969, in _exec_single_context
    self.dialect.do_execute(
  File "/Users/marvel/venv/lib/python3.9/site-packages/sqlalchemy/engine/default.py", line 922, in do_execute
    cursor.execute(statement, parameters)
psycopg2.errors.SyntaxError: syntax error at or near ":"
LINE 2: SQLResult:
                 ^

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/Users/marvel/Nutstore Files/programs/ai/xiaoyi-robot/codes/postgres_agent.py", line 61, in get_prompt
    print(db_chain.run(question))
  File "/Users/marvel/venv/lib/python3.9/site-packages/langchain_core/_api/deprecation.py", line 145, in warning_emitting_wrapper
    return wrapped(*args, **kwargs)
  File "/Users/marvel/venv/lib/python3.9/site-packages/langchain/chains/base.py", line 538, in run
    return self(args[0], callbacks=callbacks, tags=tags, metadata=metadata)[
  File "/Users/marvel/venv/lib/python3.9/site-packages/langchain_core/_api/deprecation.py", line 145, in warning_emitting_wrapper
    return wrapped(*args, **kwargs)
  File "/Users/marvel/venv/lib/python3.9/site-packages/langchain/chains/base.py", line 363, in __call__
    return self.invoke(
  File "/Users/marvel/venv/lib/python3.9/site-packages/langchain/chains/base.py", line 162, in invoke
    raise e
  File "/Users/marvel/venv/lib/python3.9/site-packages/langchain/chains/base.py", line 156, in invoke
    self._call(inputs, run_manager=run_manager)
  File "/Users/marvel/venv/lib/python3.9/site-packages/langchain_experimental/sql/base.py", line 201, in _call
    raise exc
  File "/Users/marvel/venv/lib/python3.9/site-packages/langchain_experimental/sql/base.py", line 146, in _call
    result = self.database.run(sql_cmd)
  File "/Users/marvel/venv/lib/python3.9/site-packages/langchain_community/utilities/sql_database.py", line 436, in run
    result = self._execute(command, fetch)
  File "/Users/marvel/venv/lib/python3.9/site-packages/langchain_community/utilities/sql_database.py", line 413, in _execute
    cursor = connection.execute(text(command))
  File "/Users/marvel/venv/lib/python3.9/site-packages/sqlalchemy/engine/base.py", line 1416, in execute
    return meth(
  File "/Users/marvel/venv/lib/python3.9/site-packages/sqlalchemy/sql/elements.py", line 517, in _execute_on_connection
    return connection._execute_clauseelement(
  File "/Users/marvel/venv/lib/python3.9/site-packages/sqlalchemy/engine/base.py", line 1639, in _execute_clauseelement
    ret = self._execute_context(
  File "/Users/marvel/venv/lib/python3.9/site-packages/sqlalchemy/engine/base.py", line 1848, in _execute_context
    return self._exec_single_context(
  File "/Users/marvel/venv/lib/python3.9/site-packages/sqlalchemy/engine/base.py", line 1988, in _exec_single_context
    self._handle_dbapi_exception(
  File "/Users/marvel/venv/lib/python3.9/site-packages/sqlalchemy/engine/base.py", line 2344, in _handle_dbapi_exception
    raise sqlalchemy_exception.with_traceback(exc_info[2]) from e
  File "/Users/marvel/venv/lib/python3.9/site-packages/sqlalchemy/engine/base.py", line 1969, in _exec_single_context
    self.dialect.do_execute(
  File "/Users/marvel/venv/lib/python3.9/site-packages/sqlalchemy/engine/default.py", line 922, in do_execute
    cursor.execute(statement, parameters)
sqlalchemy.exc.ProgrammingError: (psycopg2.errors.SyntaxError) syntax error at or near ":"
LINE 2: SQLResult:
                 ^

[SQL: SELECT COUNT(*) FROM tasks
SQLResult:
count
-----
3
Answer: There are 3 tasks in the tasks table.]

Description
I followed the article (https://coinsbench.com/chat-with-your-databases-using-langchain-bb7d31ed2e76) to make langchain interact with postgres DB, but I have got error response from OpenAI recently, error message are listed below.

It seems that OpenAI has stopped supporting Completions API and stop words in the request fail to work. OpenAI's suggestions are(https://openai.com/blog/gpt-4-api-general-availability):

Starting today, all paying API customers have access to GPT-4. In March, we introduced the ChatGPT API, and earlier this month we released our first updates to the chat-based models. We envision a future where chat-based models can support any use case. Today we’re announcing a deprecation plan for older models of the Completions API, and recommend that users adopt the Chat Completions API.

So I did some research of current codes and decided to modify langchain_openai/llms/base.py, the modifications are list above. finally it works

System Info
% pip list|grep langchain
langchain                     0.1.5
langchain-community           0.0.17
langchain-core                0.1.18
langchain-experimental        0.0.50
langchain-openai              0.0.5
% pip list|grep openai
langchain-openai              0.0.5
openai                        1.11.1

The issue contains a lot of unnecessary information. As far as I'm aware stop tokens work with current openai chat models.
Test with
model = ChatOpenAI()
model.bind(stop=['my_token'])
model.invoke()

if that fails, feel free to open a minimal issue that's describing the problem precisely.


Let the tag detail bg adapts to the theme color

Before

Dark mode:

Light mode:

After

Dark mode:

Light mode:

Tested theme
Tested on Default theme, Minimal, Things, it could adapts the background color of popup-window to the theme defined color.

thanks for your contribution :)


Fix networking in NodeOS

Related: #144
I shouldn't have to do any manual steps to access the public internet from NodeOS after booting. Whether that means that a 'default' network interface is pre-created, or DHCP is implemented, it doesn't matter, as long as I can access google.com on startup.

Could you be able to describe what need to be fixed? As I said on the other issue, network is working again and the only problem is that you need to set the IP and the route by hand, no DHCP. Is this what you are talking about?

I've updated the description. Hope that makes things clearer!

Ah, ok, much better! :-D Yes, I think we need a DHCP client enabled by default. I have been trying dhcpjs but it's not working don't know why :-(
There are some issues and things that need to be fixed/discussed here regarding networking:

there's only one (or very few) network cards on a system that need to be shared by all the users, and we don't have network isolation (at least until we use LXC containers). If we set one IP, this will be need to be done by root on startup and can't be changed, or someone will need to have administrator permissions, going against the philosofy of NodeOS
we can set a DHCP client and fetch an IP and default gateway on startup, but what happens if people want to set a static IP? How to do it?

The only solution I think is to use a DHCP client by default and allow people to set their own IPs. Linux allow to have several IPs on a single network card, but this IPs need to be on the same address space of the external network and also I don't know how much difficult would be to add the virtual network cards dynamically and only allow to configure one for each user. Also, maybe in that case it would make more sense to have a private LAN on the host machine to connect the users and all of them going to internet through a gateway, similar to how QEmu emulated network works, but here we have NAT problems and so... :-/ What do you think?

http://superuser.com/questions/502793/how-to-bring-network-up-at-boot-time-in-linux
https://www.kernel.org/doc/Documentation/filesystems/nfs/nfsroot.txt
Ok, so Linux kernel allow to define the IP as a boot cmdline argument :-) It would neet to be tested, but this way a DHCP server could be started by default, and allow to set a static IP as a boot param :-)

NodeOS now uses DHCP on boot time and is capable of using npm to install packages, so clossing :-)


Updated Choose a Topic Section.md

Updated "Choose a Topic" section to provide thoughts on how to think about angling your presentation.

[X] I have read freeCodeCamp's contribution guidelines.
[X] My pull request has a descriptive title (not a vague title like Update index.md)
[X] My pull request targets the master branch of freeCodeCamp.
[X] None of my changes are plagiarized from another source without proper attribution.
[X] My article does not contain shortened URLs or affiliate links.

If your pull request closes a GitHub issue, replace the XXXXX below with the issue number.
Closes #XXXXX

I am just trying to learn how to use GitHub and interact with the community.


Pypi Links

You should update the links on the PyPi so they match this repository :)

Done! Thanks for pointing this out to us!


When the text contains Chinese, the semantic mark returned by TsServer is deviated

Bug Report
I want to implement the code coloring function through TSServer, but I found that when the text contains Chinese, the data obtained is biased. If Chinese is not included, then the function is normal.
In the case that the code contains Chinese, each Chinese character will cause the offset of the token to be 1 more than the correct value.
🔎 Search Terms
TsServer
Semantic Token
Classifications
Parsing Chinese error
🕗 Version & Regression Information
TypeScript Version:"4.4.3"

This is a crash

⏯ Playground Link
This is a problem with the grammar parser and cannot provide code examples
💻 Code
This is the Json data communicated with TsServer
Containing Chinese
documentChange:
{
    "arguments": {
        "insertString": "/*中文*/\nclass TestClass{\n\n}",
        "endLine": 4,
        "endOffset": 2,
        "line": 1,
        "offset": 1,
        "file": "C:\\Users\\appeon\\source\\repos\\angularproject22\\angularproject22\\src\\app\\app.component.ts"
    },
    "command": "change",
    "seq": 1511,
    "type": "request"
}

Request-encodedSemanticClassifications-full:
{
    "command": "encodedSemanticClassifications-full",
    "arguments": {
        "start": 0,
        "length": 26,
        "format": "2020",
        "file": "C:\\Users\\appeon\\source\\repos\\angularproject22\\angularproject22\\src\\app\\app.component.ts"
    },
    "seq": 1523,
    "type": "request"
}

Response-encodedSemanticClassifications-full:
{
    "request_seq": 1524,
    "Success": true,
    "Command": "encodedSemanticClassifications-full",
    "Message": null,
    "Metadata": null,
    "PerformanceData": null,
    "Body": {
        "spans": [
            15,
            9,
            257
        ],
        "endOfLineState": 0
    },
    "Seq": 0,
    "Type": "response"
}

Does not contain Chinese
documentChange:
{
    "arguments": {
        "insertString": "/*CN*/\nclass TestClass{\n\n}",
        "endLine": 4,
        "endOffset": 2,
        "line": 1,
        "offset": 1,
        "file": "C:\\Users\\appeon\\source\\repos\\angularproject22\\angularproject22\\src\\app\\app.component.ts"
    },
    "command": "change",
    "seq": 1526,
    "type": "request"
}

Request-encodedSemanticClassifications-full:
{
    "command": "encodedSemanticClassifications-full",
    "arguments": {
        "start": 0,
        "length": 26,
        "format": "2020",
        "file": "C:\\Users\\appeon\\source\\repos\\angularproject22\\angularproject22\\src\\app\\app.component.ts"
    },
    "seq": 1534,
    "type": "request"
}

Response-encodedSemanticClassifications-full:
{
    "request_seq": 1558,
    "Success": true,
    "Command": "encodedSemanticClassifications-full",
    "Message": null,
    "Metadata": null,
    "PerformanceData": null,
    "Body": {
        "spans": [
            13,
            9,
            257
        ],
        "endOfLineState": 0
    },
    "Seq": 0,
    "Type": "response"
}

As can be seen from the above data, the length of the text sent is consistent with the content of the semantic markup request.
However, in the case of including Chinese, the data obtained with semantic markup is biased
🙁 Actual behavior

🙂 Expected behavior

Excuse me, VSCode also uses TSServer, but why is there no such problem? Seeing that this problem has been postponed to the 4.6.0 version of the plan. Can you tell us some information about this problem and see if we can temporarily solve this problem with other solutions, thank you!


Update OnLoadEvent typings

This exposes the target property of the onLoadEvent.
Our use case for needing this is that when the image loads, we take the target (which is the react tag) and pass it over the bridge into Obj-C code so that we can grab a reference to the UIImageView and perform some manipulations.

I don't really understand the use case. Could you show some example code?
If this was done, would it make sense to do the same thing for other events?


请教如何处理

描述问题
报错：selenium.common.exceptions.WebDriverException: Message: 'chromedriver' executable needs to be in PATH. Please see https://sites.google.com/a/chromium.org/chromedriver/home

重现步骤
python run.py

截图&日志
C:\Users\Administrator\AppData\Local\Programs\Python\Python36\python.exe C:/Users/Administrator/12306/run.py
Using TensorFlow backend.
C:\Users\Administrator\AppData\Local\Programs\Python\Python36\lib\site-packages\tensorflow\python\framework\dtypes.py:516: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
_np_qint8 = np.dtype([("qint8", np.int8, 1)])
C:\Users\Administrator\AppData\Local\Programs\Python\Python36\lib\site-packages\tensorflow\python\framework\dtypes.py:517: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
_np_quint8 = np.dtype([("quint8", np.uint8, 1)])
C:\Users\Administrator\AppData\Local\Programs\Python\Python36\lib\site-packages\tensorflow\python\framework\dtypes.py:518: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
_np_qint16 = np.dtype([("qint16", np.int16, 1)])
C:\Users\Administrator\AppData\Local\Programs\Python\Python36\lib\site-packages\tensorflow\python\framework\dtypes.py:519: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
_np_quint16 = np.dtype([("quint16", np.uint16, 1)])
C:\Users\Administrator\AppData\Local\Programs\Python\Python36\lib\site-packages\tensorflow\python\framework\dtypes.py:520: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
_np_qint32 = np.dtype([("qint32", np.int32, 1)])
C:\Users\Administrator\AppData\Local\Programs\Python\Python36\lib\site-packages\tensorflow\python\framework\dtypes.py:525: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
np_resource = np.dtype([("resource", np.ubyte, 1)])
C:\Users\Administrator\AppData\Local\Programs\Python\Python36\lib\site-packages\tensorboard\compat\tensorflow_stub\dtypes.py:541: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
_np_qint8 = np.dtype([("qint8", np.int8, 1)])
C:\Users\Administrator\AppData\Local\Programs\Python\Python36\lib\site-packages\tensorboard\compat\tensorflow_stub\dtypes.py:542: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
_np_quint8 = np.dtype([("quint8", np.uint8, 1)])
C:\Users\Administrator\AppData\Local\Programs\Python\Python36\lib\site-packages\tensorboard\compat\tensorflow_stub\dtypes.py:543: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
_np_qint16 = np.dtype([("qint16", np.int16, 1)])
C:\Users\Administrator\AppData\Local\Programs\Python\Python36\lib\site-packages\tensorboard\compat\tensorflow_stub\dtypes.py:544: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
_np_quint16 = np.dtype([("quint16", np.uint16, 1)])
C:\Users\Administrator\AppData\Local\Programs\Python\Python36\lib\site-packages\tensorboard\compat\tensorflow_stub\dtypes.py:545: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
_np_qint32 = np.dtype([("qint32", np.int32, 1)])
C:\Users\Administrator\AppData\Local\Programs\Python\Python36\lib\site-packages\tensorboard\compat\tensorflow_stub\dtypes.py:550: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
np_resource = np.dtype([("resource", np.ubyte, 1)])

检查当前版本为: 1.1.110
检查当前python版本为：3.6.1rc1，目前版本只支持3.6以上
12306刷票小助手，最后更新于2019.09.09，请勿作为商业用途，交流群号： 1群：286271084(已满)
2群：649992274(已满)
3群：632501142(已满)
4群: 606340519(已满)
5群: 948526733(已满)
6群: 608792930(未满)
7群: 660689659(已满)
当前配置：
出发站：深圳北
到达站：贺州
乘车日期：2019-10-01
坐席：二等座
是否有票优先提交：True
乘车人：['*****']
刷新间隔: 随机(1-3S)
僵尸票关小黑屋时长: 5
下单接口: 2
下单模式: 2
预售踩点时间:13:00:00

cookie获取中
Traceback (most recent call last):
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python36\lib\site-packages\selenium\webdriver\common\service.py", line 76, in start
stdin=PIPE)
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python36\lib\subprocess.py", line 707, in init
restore_signals, start_new_session)
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python36\lib\subprocess.py", line 990, in _execute_child
startupinfo)
FileNotFoundError: [WinError 2] 系统找不到指定的文件。
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:/Users/Administrator/12306/run.py", line 20, in
run()
File "C:/Users/Administrator/12306/run.py", line 8, in run
select_ticket_info.select().main()
File "C:\Users\Administrator\12306\init\select_ticket_info.py", line 149, in main
getDrvicesID(self)
File "C:\Users\Administrator\12306\config\getCookie.py", line 17, in getDrvicesID
driver = webdriver.Chrome(executable_path=TickerConfig.CHROME_PATH)
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python36\lib\site-packages\selenium\webdriver\chrome\webdriver.py", line 68, in init
self.service.start()
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python36\lib\site-packages\selenium\webdriver\common\service.py", line 83, in start
os.path.basename(self.path), self.start_error_message)
selenium.common.exceptions.WebDriverException: Message: 'chromedriver' executable needs to be in PATH. Please see https://sites.google.com/a/chromium.org/chromedriver/home
进程已结束，退出代码 1
环境信息

windows 10
PyCharm9.2
python3.6.1rc1
订票小助手版本 1.1.101

额外的备注
加过PATH的变量：C:\Users\Administrator\AppData\Local\Programs\Python\Python36\chromedriver.exe

在QQ群里得到处理了！

怎么解决的？我也遇到了

加载对应版本的chromedriver.exe


Add workflows

@alt-how we are using an action helm/chart-releaser-action I have read through the action and cant find any suspicious, not that i expected to.
@altinnadmin can you verify that either all actions are allowed or this action is in the whitelist

@alt-how we are using an action helm/chart-releaser-action I have read through the action and cant find any suspicious, not that i expected to.
Neither did I when I briefly looked through the sh file.

can you verify that either all actions are allowed or this action is in the whitelist

@tjololo Should work fine, when you have write permissions to the repo you should be able to add any action.


add support for ms access

There is an entity framework provider for Microsoft Access.

EntityFrameworkCore.Jet
JetEntityFrameworkProvider

Please add Microsoft Access support to this repository. Thanks.

Hello @kkordinia ,
Unfortunately, we currently have too many requests to add support to new providers. I added it to our internal wish list but to be honest, I don't think it will ever happen.
Best Regards,
Jon

Sponsorship
Help us improve this library
Performance Libraries
context.BulkInsert(list, options => options.BatchSize = 1000);
Entity Framework Extensions • Bulk Operations •  Dapper Plus
Runtime Evaluation
Eval.Execute("x + y", new {x = 1, y = 2}); // return 3
C# Eval Function • SQL Eval Function


Error when adding a comment in a SCSS file

Uncaught TypeError: Cannot read property 'includes' of undefined
/Applications/Atom.app/Contents/Resources/app.asar/node_modules/text-buffer/lib/text-buffer.js:810
Hide Stack Trace
TypeError: Cannot read property 'includes' of undefined
at searchCommentRow (/Users/Drawcard/.atom/packages/block-comment-plus/lib/block-comment-plus.js:114:18)
at /Users/Drawcard/.atom/packages/block-comment-plus/lib/block-comment-plus.js:41:26
at TextBuffer.module.exports.TextBuffer.transact (/Applications/Atom.app/Contents/Resources/app.asar/node_modules/text-buffer/lib/text-buffer.js:805:18)
at atom-text-editor.toggle (/Users/Drawcard/.atom/packages/block-comment-plus/lib/block-comment-plus.js:17:10)
at CommandRegistry.module.exports.CommandRegistry.handleCommandEvent (/Applications/Atom.app/Contents/Resources/app.asar/src/command-registry.js:260:29)
at CommandRegistry.handleCommandEvent (/Applications/Atom.app/Contents/Resources/app.asar/src/command-registry.js:3:61)
at CommandRegistry.module.exports.CommandRegistry.dispatch (/Applications/Atom.app/Contents/Resources/app.asar/src/command-registry.js:160:19)
at module.exports._executeCallback (/Users/Drawcard/.atom/packages/tool-bar/lib/tool-bar-button-view.coffee:69:23)
at space-pen-button. (/Users/Drawcard/.atom/packages/tool-bar/lib/tool-bar-button-view.coffee:29:7)
at space-pen-button.jQuery.event.dispatch (/Applications/Atom.app/Contents/Resources/app.asar/node_modules/atom-space-pen-views/node_modules/space-pen/node_modules/jquery/dist/jquery.js:4435:9)
at space-pen-button.elemData.handle (/Applications/Atom.app/Contents/Resources/app.asar/node_modules/atom-space-pen-views/node_modules/space-pen/node_modules/jquery/dist/jquery.js:4121:28)

It seems to happen when doing the following:

Placing the text cursor point after a line that contains a // before it, in a SCSS file - eg:
// Someone's comment ``][```
Toggling the Block Comment via menu

Fixed, thank you!


Facing issue in deploying Azure Security and Compliance Blueprint - HIPAA/HITRUST Health Data and AI

Hi,
I am reviewing your "Azure Security and Compliance Blueprint - HIPAA/HITRUST Health Data and AI"
solution. While I am trying to deploy the solution facing issue below.
after running
.\deploy.ps1 -deploymentPrefix hipo  -tenantId 98bb49c0-16c0-4e5d-a7f4-bb008c5c8c0b -tenantDomain aaptbhatt004outlook -subscriptionId 41ad2986-f5c7-427b-b766-1968d0a923bc -globalAdminUsername aaptbhatt004outlook.onmicrosoft.com -deploymentPassword #######
11:35:38 AM - Resource Microsoft.KeyVault/vaults 'hipo-los-kv-dev' failed with message '{
"error": {
"code": "VaultAlreadyExists",
"message": "The name 'hipo-los-kv-dev' is already in use."
}
}'
At C:\Users\aapta\AppData\Local\Packages\Microsoft.MicrosoftEdge_8wekyb3d8bbwe\TempState\Downloads\Health-Data-and-AI-Blueprint-master\Deployment\scripts\pshscripts\PshFunctions.ps1:462
char:5

$jobOutput = Get-Job -Name $jobName | Select-Object -Last 1 | Rec ...

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

CategoryInfo          : NotSpecified: (:) [New-AzureRmResourceGroupDeployment], Exception
FullyQualifiedErrorId : Microsoft.Azure.Commands.ResourceManager.Cmdlets.Implementation.NewAzureResourceGroupDeploymentCmdlet
PSComputerName        : localhost

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

ID: 18cf2e85-c024-e71d-853e-ef482209c528
Version Independent ID: 4c94dc1b-4029-b88a-6579-16fff17cee20
Content: Azure Health Analytics Blueprint
Content Source: articles/security/blueprints/azure-health.md
Service: security
GitHub Login: @jomolesk
Microsoft Alias: jomolesk

@aaptbhatt It appears that the script is trying to create a Key Vault using the name of an existing Key Vault. If you run the deployment multiple times, you should use the -prefix switch to avoid this issue.
@vasivara-MSFT Please close this issue; it is unrelated to Microsoft Docs content.

@aaptbhatt We will now proceed to close this thread. If there are further questions regarding this matter, please reopen it and we will gladly continue the discussion.


Better build priority

Problem: for the fastFiller, the first container should be build before the extensions, however the second container should only be built for the extensions it serves, and not when those extensions are not ready to be built. This issue extends to other parts of build order logic

We could place for / build for 1 RCL at a time, however we want things like towers, storage to be prioritized, and factory, labs, extractor not so much
We could hypothetically add a build priority property to planning data, but this seems impractical in terms of internal complexity and reasonable assignment
Other options?

Currently I'm just looking for ideas on how to solve this problem. Thanks

Okay
Op vr 22 sep 2023 om 08:14 schreef Carson @.***>

Currently I'm just looking for ideas on how to solve this problem. Thanks
—
Reply to this email directly, view it on GitHub
https://github.com/The-International-Screeps-Bot/The-International-Open-Source/issues/703#issuecomment-1730858043,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AK4CTASKVFMGBKHD7BVH75TX3UUDZANCNFSM6AAAAAA5CS7PO4
.
You are receiving this because you were assigned.Message ID:
<The-International-Screeps-Bot/The-International-Open-Source/issues/703/1730858043
@github.com>

@CarsonBurke
We could create while planning the order we construct it.
Some construction sites like the fast filler container should block until its build.


tests: Add extra cleanup code

Signed-off-by: Stéphane Graber<EMAIL_ADDRESS>

@brauner should be good to go


Update screen_protector.dart

Fixed IOS compile issue
Flutter SDK version : 2.10.5

Thank you for fix issue :)


istioctl proxy-status not showing patch version

Just upgraded to 1.0.1, including all side cars, but they're still showing as 1.0.0:
eg:
❯ istioctl proxy-status
PROXY                                                                    CDS        LDS        EDS               RDS        PILOT                            VERSION
elastic-heartbeat-java-app-b4bf94bd-mbp46.elastic-heartbeat-java-app     SYNCED     SYNCED     SYNCED (100%)     SYNCED     istio-pilot-7784df98d8-dpmzg     1.0.0
ingress-nginx-external-controller-6fc57cc9c4-flxmp.ingress-nginx         SYNCED     SYNCED     SYNCED (100%)     SYNCED     istio-pilot-7784df98d8-dpmzg     1.0.0
ingress-nginx-internal-controller-54fbd99b5f-bcldg.ingress-nginx         SYNCED     SYNCED     SYNCED (100%)     SYNCED     istio-pilot-7784df98d8-dm62z     1.0.0
mike-istio-test-pod.default                                              SYNCED     SYNCED     SYNCED (100%)     SYNCED     istio-pilot-7784df98d8-dm62z     1.0.0
oauth-redis-proxy-5cf64d7bf4-9n89t.ingress-nginx                         SYNCED     SYNCED     SYNCED (100%)     SYNCED     istio-pilot-7784df98d8-dm62z     1.0.0
oauth-redis-proxy-5cf64d7bf4-h479l.ingress-nginx                         SYNCED     SYNCED     SYNCED (100%)     SYNCED     istio-pilot-7784df98d8-dpmzg     1.0.0
oauth2-proxy-79b9d6644d-fwbzv.ingress-nginx                              SYNCED     SYNCED     SYNCED (100%)     SYNCED     istio-pilot-7784df98d8-dm62z     1.0.0
platform-testing-6b5f989b5-hv9z9.platform-testing                        SYNCED     SYNCED     SYNCED (100%)     SYNCED     istio-pilot-7784df98d8-dpmzg     1.0.0
shippr-simple-5c9d9b7b68-n27hr.shippr-simple                             SYNCED     SYNCED     SYNCED (100%)     SYNCED     istio-pilot-7784df98d8-dpmzg     1.0.0

Purely cosmetic I guess.

@Stono I'll take a look.
Cheers
-steve

@Stono thanks for the report.  This has been merged to the release-1.0 branch and will be available in the next z stream (Istio 1.0.2).  The problem did not exist in master.

@sdake fyi see #15094 - where this problem still exists in 1.2.0


Remove references to malloc.h

malloc.h is deprecated: https://stackoverflow.com/questions/12973311/difference-between-stdlib-h-and-malloc-h. Tensorflow does not build on my friend's M1 Mac because of this (@carlthome, he is very sad about this).

I can confirm that this change made minimal.cc work with the CMake instructions as per the tutorial on a MacBook Air M1.

Great @mihaimaruseac! 👏
Please ping if further action is needed from us to get this in!
What's up with all the failed checks? 🤔

There are conflicts. Can you please resolve them?

The second occurrence of #include <malloc.h> seems to have been replaced by #include <memory>. Now there's only one mention of "malloc.h" left, for Linux builds only. Maybe not worth merging anymore.

It still shows as having conflicts...
If you can build without the remaining replacement, let's close the PR


Migrate to nicklaw5/helix

Add dependency to nicklaw5/helix
Ensure BotChannel Stream is always initialized
Remove points usages
Remove old webhook calls
Migrate to nicklaw5-helix and from webhooks to eventsub

Currently testing this in production

[ ] Migrate away from Webhook HostPrefix and just use Web.Host + Web.Secure


[vite] Internal server error: Cannot set headers after they are sent to the client

[vite] Internal server error: Cannot set headers after they are sent to the client
      at new NodeError (node:internal/errors:372:5)
      at ServerResponse.setHeader (node:_http_outgoing:576:11)
      at send (/home/user/projects/my_project/node_modules/.pnpm/registry.npmmirror.com+vite@2.9.13/node_modules/vite/dist/node/chunks/dep-80fe9c6b.js:57369:9)
      at viteIndexHtmlMiddleware (/home/user/projects/my_project/node_modules/.pnpm/registry.npmmirror.com+vite@2.9.13/node_modules/vite/dist/node/chunks/dep-80fe9c6b.js:57779:28)

The options of virtualHtml is:
{
  pages: { index: '/index.html', button: '/lib/button/index.html' },
  indexPage: 'button'
}

Looks like it caused by this:
https://github.com/windsonR/vite-plugin-virtual-html/blob/7fe8d8100d1863ce176b96ae1b93f6ba6b88ec6e/src/plugin.ts#L51
maybe you can test this.
use res.end to replace res.write in src/plugin.js.

long time no response, so close this issue.


Fix: XAUTOCLAIM after a TRIM with pending messages returns nil

Description

Running a XAUTOCLAIM after a TRIM while messages are pending results in Redis returning an array with nil as the unique element.
<IP_ADDRESS>:6379> XAUTOCLAIM stream group user 0 0-0 COUNT 1
1) "1689008209763-0"
2) 1) (nil)

The generic transformer will then crash here trying to iterate on null with TypeError: .for is not iterable
You can reproduce the issue with this:
const id = await client.XADD("stream", "*", { foo: "bar" });
await client.XREADGROUP("group", "consumer-1", { key: "stream", id: ">" });
await client.XTRIM("stream", "MAXLEN", 0);
await client.XAUTOCLAIM("stream", "group", "consumer-2", 0, id); // <- Will crash

Checklist

[x] Does npm test pass with this change (including linting)?
[x] Is the new or changed code fully tested?
[x] Is a documentation update included (if this change modifies existing APIs, or introduces new ones)?

@Calyhre Nice catch! but only XAUTOCLAIM can return null, not XCLAIM and XRANGE, so the change shouldn't be made in the transformStreamMessagesReply function (which all of them are using).
I've already fixed it in the v5 (see https://github.com/redis/node-redis/pull/2485/commits/c9dae346a295030adc10c46d1b7bf26bc4b46bc5), but I guess we need to backport it to v4 as well...

@leibale Nice! I also noticed the issue disappeared in Redis V7.

but only XAUTOCLAIM can return null, not XCLAIM and XRANGE, so the change shouldn't be made in the transformStreamMessagesReply function (which all of them are using).

I moved the fix to it's own method in xAutoClaim to not pollute the other methods. Let me know what you think.

@Calyhre actually both XCLAIM and XAUTOCLAIM might return null before redis 7, see here for more details and why it has changed.
I've fixed it in v5 (see 8369448d05b2782d766bc30326f3423c319de504), wanna backport it one last time? :pray:

@leibale Alright, I think I ended up porting a very similar fix to the one you did on V5. Let me know what you think.
I do have one doubt though: It seems right to me to reflect the differences between Redis versions (returning null or not based on Redis answer), but the end type is not version dependent. Using Redis V7, x[Auto]Claim messages will be typed with as StreamMessageReply | null even though null is not possible anymore in this case.
This might be complicated, but should the typing be dependent of the Redis server version?

@Calyhre Thanks for working on that! :)
Regarding the deiffrences bettwen Redis versions -

@Calyhre Thanks for working on that! I'll review it next week :)
Regarding the differences between Redis versions - at the moment all the "command interfaces" are implemented with Redis 5-7.2 in mind. We might split the commands into their own sub-package at some point, then we'll be able to publish @redis/${redis-version}-commands or something like that... (BTW, we have the exact same problem with command arguments, for example, SET with NX and GET is only supported in Redis 7+, but we show it for all users regardless of their Redis version...)

Codecov Report
Patch coverage: 100.00% and project coverage change: -3.94 :warning:

Comparison is base (a7d5bc7) 95.70% compared to head (b85577a) 91.76%.

:exclamation: Current head b85577a differs from pull request most recent head 8a8bec6. Consider uploading reports for the commit 8a8bec6 to get more accurate results

:exclamation: Your organization is not using the GitHub App Integration. As a result you may experience degraded service beginning May 15th. Please install the Github App Integration for your organization. Read more.
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #2565      +/-   ##
==========================================
- Coverage   95.70%   91.76%   -3.94%
==========================================
  Files         456      456
  Lines        4561     4565       +4
  Branches      524      525       +1
==========================================
- Hits         4365     4189     -176
- Misses        127      307     +180
  Partials       69       69

Impacted Files
Coverage Δ

packages/client/lib/commands/XAUTOCLAIM.ts
100.00% <100.00%> (ø)

packages/client/lib/commands/XCLAIM.ts
100.00% <100.00%> (ø)

...ckages/client/lib/commands/generic-transformers.ts
94.27% <100.00%> (-5.73%)
:arrow_down:

... and 41 files with indirect coverage changes

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.

@Calyhre redis@4.6.9/<EMAIL_ADDRESS>is on npm :tada:

Awesome thank you! And sorry for committing the hard coded redis test urls 🤦

@Calyhre I'll take PRs where all I need to do is remove "hard coded redis tests URLs" any day.. ;) Thank you!


Error when collecting GitHub issue labels in tag 0.5.0

Describe the bug
Error when collecting GitHub issue labels in tag 0.5.0
To Reproduce
Steps to reproduce the behavior:

Follow the README to install DevLake 0.5.0 by docker-compose
Configure the Github endpoint and token
Trigger the collection of 'DevLake' project
[ [  {    "Plugin": "github",    "Options": {      "repositoryName": "lake",      "owner": "merico-dev"    }  } ] ]
Input command docker-compose logs -f devlake to see logs
see error

Expected behavior
Successfully collect GitHub issue labels.
Screenshots

[retry 2] indicates a Network Connection failure,  try GITHUB_PROXY...
BTW. did your pipeline show a FAIL status correctly?

To be addressed on #1032


Remove DatabaseBackup.backup_supported? method

We only run on PostgreSQL and we are getting more intimate with it as
time moves forward.  We can always add this back in if necessary in the
future.
@jrafanie Please review. :scissors:

?w=1 helps for app/views/ops/_diagnostics_database_tab.html.haml


Create zadilkhwaja.json

resolves #1327
Checklist for profile addition

[x] fix: add <zadilkhwaja>.
[x] You've added file named your-username.json in the profiles directory.
[x] You've linked the PR to the correct issue.

Hi @Panquesito7 please check now. Also I've sent request to join team maintainer for this repo can you please accept it? Is there any specific requirement that I've to meet to be a maintainer?

Hi @Panquesito7 please check now. Also I've sent request to join team maintainer for this repo can you please accept it? Is there any specific requirement that I've to meet to be a maintainer?

Hey! I suggest we discuss this somewhere else. Not sure this PR fits for that. Thanks.


Respect X-Forwarded-Proto header

Consider a typical setup on docker farm:
Remote user > (HTTPS) > nginx frontend at docker host > (HTTP) > docker container.
This is a perfectly secure setup (unencrypted traffic never hits the physical network), however phpLDAPAdmin will generate a warning: "This web connection is unencrypted."
phpLDAPAdmin docker image must respect X-Forwarded-Proto and disable the warning if the header is set to "https".

Thanks i didn't known that :)
can you provide the apache configuration and i make a fix ? (or make a pull request ?)


Chore/record tracking delay in perception sim

Types of PR

[ ] New Features
[x] Upgrade of existing features
[ ] Bugfix

Description
This PR enables to record tracking delay information to check computation burden.
It aims to record following float64 messages.
/perception/object_recognition/tracking/multi_object_tracker/debug/cyclic_time_ms
/perception/object_recognition/tracking/multi_object_tracker/debug/elapsed_time_from_sensor_input_ms
/perception/object_recognition/tracking/multi_object_tracker/debug/processing_time_ms

How to review this PR
Others

@YoshiRi Is it intentional to add https://github.com/tier4/driving_log_replayer/blob/995004388b2a4fdafb73fb49456962495a88802b/driving_log_replayer/scripts/perception_tracking_scenario_evaluator_node.py?

Sorry, that was my mistake. I removed it.


Add discord button to settings menu

Added a discord button to the settings menu so that users can also find the link after the welcome screen. Styling might not be perfect and very brute-forced. Icon retrieved from https://discord.com/branding.

Styling is now less brute-forced 😉


1.1.0 release

New features in #94. Target date: 2019-06-18.

Issues for 1.1 are closed, still on track for the 18th.

@sgillies, There is a depreciation warning for collections imported at line 4

mercantile/init.py:4: DeprecationWarning: Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated, and in 3.8 it will stop working
from collections import Sequence

Maybe we could use this release to take care of this ?
I'll be happy to submit a PR

1.1.0 is on PyPI now: https://mercantile.readthedocs.io/en/latest/changelog.html#id1.


Add missing requeue to Datacenter decommission

What this PR does:
Decommissioning datacenter is missing a requeue after scaling down is done, but the pods haven't been removed yet. This can cause the operator to remove PVCs before Cassandra has properly shutdown (it has 30s wait after decommission).
Which issue(s) this PR fixes:
Fixes #
Checklist

[ ] Changes manually tested
[ ] Automated Tests added/updated
[ ] Documentation added/updated
[x] CHANGELOG.md updated (not required for documentation PRs)
[x] CLA Signed:  DataStax CLA

@burmanm can you please create an issue for this?


Function for adding hosts/employees to Guest

Could you please add a function for adding hosts/employees to Guest. This could open the gate for integration with HR management platforms like Kronos. Need an alternative to manual user creation, CSV upload or Azure AD SCIM snyc.

Would you also be able to have a function that would get the list of hosts, and another to delete? that way one could potentially write a script that runs daily to sync the list with a 3rd party directory (different than Azure AD)

[ ] Add-VerkadaWorkplaceEmployee
[ ] Get-VerkadaWorkplaceEmployee
[ ] Remove-VerkadaWorkplaceEmployee
[ ] Read-VerkadaWorkplaceEmployees

specifying site by name should probably use the public API in the future, but for simplicity for now it will use the front end apis since the rest of these functions will be using the front end APIs.


[BUG] Power state not updated at wake up

Go Hass Agent Version
Go Hass Agent: v10.5.1
Describe the bug
Power state is not update in Home Assistant at wake up from Suspsended mode.
go-hass-agent try to update sensor.state but network is not yet ready after wake up so there is an error. Even after network ready go-hass-agent do not try again to update sensor state in error.
Result is Home Assistant does not receive update about sensor state that change only once just after wake up and before network is up.
In log file attached :

Line 45 : power_state is set to "Suspended"
Line 46 : PC is wake up and some error appear due to network not yet up
Line 47 : Power stateupdate is in error, still no network
Line 92 : Network is up, sensore state is updated but no retry on previous error

I automate an action at PC wake up on Home Assistant. Because of this issue it does work.
Issue seems appear if PC is une suspended mode for a long time. If I wake up my PC 2 minutes after suspended mode power state is updated.
To Reproduce
Steps to reproduce the behaviour:

Do suspend your PC
Wait a long time
Wake up PC
See error = power state not updated

Expected behaviour
Power state update after PC wake up. 2 options maybe, wait for network before sending any sensor.state update, or retry previous sensor.state update that failed. Especially sensor.state that change little like Power State.
Screenshots
N/A
Logs
A log will be very helpful to look into this bug report. To get the log:
go-hass-log.txt
Desktop (please complete the following information):

OS: Linux Mint
Distribution : Mint
Version : 22

Hey thanks for trying out Go Hass Agent and reporting this bug!
Also thanks for the detailed walkthrough, I can clearly see the problem. For all sensor updates, I don't do any retries if an update fails to get sent to Home Assistant. In nearly all cases, this is fine, as you'll get new data on the next poll. However, in this case, you definitely do want to send the existing update otherwise the power state is wrong as you've discovered.
I'll have to have a think about how I can implement this. I'll leave this bug open as a tracker and I'll update when I've got a fix.
Cheers.

Hey there, I've spent some time looking at this over my weekend and I believe https://github.com/joshuar/go-hass-agent/commit/b10367941aa487f6ee7cf9eaaa8179d51121a133 should fix this issue. At least in my testing, after suspend my power state sensor is updating correctly. This will go into the next release :tada:

Hi,
Good news, thank you.
I will try to build it to test before release.
I hope the exponential mechanism will not increase too much the delay. If so the automation on home assistant will be too late.
Another way could be to wait for an active connection before sending requests, but I don't know if there is a reliable way to detect it.

All good today, multiple wake up and sensor was updated as expected.
I will keep this version few days to be sure.


⚠ Bofrost.lu has degraded performance

In f7d4eff, Bofrost.lu (https://www.bofrost.lu) experienced degraded performance:

HTTP code: 200
Response time: 897 ms

Resolved: Bofrost.lu performance has improved in 5109674 after 6 minutes.


Can't build anything from nixos-unstable if 'src' is a directory

Describe the bug
For any package whose src is a directory, it fails when I try to build locally from nixos-unstable.
This is happens whether src is a path, or fetchFromGitHub, or anything that is a /nix/store/... directory.
I think this is due to the coreutils 9.4 update, which we could rollback (see below).
After a bisect, it turned out to be the glibc upgrade 2.38-44 -> 2.39-5 8b24908a76ac20bb12503c7a32ee4d3cea245a74 done in #287594
Steps To Reproduce
Steps to reproduce the behavior:

Run the kernel linuxKernel.packages.linux_lqx from stable (nixos-23.11)
run nix build -L 'nixpkgs/nixos-unstable#lsof' --rebuild

Expected behavior
Those packages build.
"Screenshots"
# nix build -L 'nixpkgs/nixos-unstable#lsof' --rebuild
lsof> Running phase: unpackPhase
lsof> unpacking source archive /nix/store/snvdq7fanjnd8kadmi3p8i2ivsqjmp3x-source
lsof> cp: setting permissions for 'source': Invalid argument
lsof> do not know how to unpack source archive /nix/store/snvdq7fanjnd8kadmi3p8i2ivsqjmp3x-source

# nix build -L 'nixpkgs/nixos-unstable#htop' --rebuild
htop> Running phase: unpackPhase
htop> unpacking source archive /nix/store/yw4lq506x7aimb4b6ifrdmga3x9n9xsv-source
htop> cp: setting permissions for 'source': Invalid argument
htop> do not know how to unpack source archive /nix/store/yw4lq506x7aimb4b6ifrdmga3x9n9xsv-source

Additional context
I am running on the Linux 6.5.11-lqx2 kernel, which is linuxKernel.packages.linux_lqx from stable (nixos-23.11).
From my debugging, this seems due to a regression in glibc, which changed the way they do chmod:
# With coreutils from nixos-23.11 (tried it manually outside the Nix sandbox)
/nix/store/59mv7mybz16jjvnkz4z5shqgaqm4k009-coreutils-full-9.3/bin/cp -pr --reflink=auto -- /nix/store/...-vim vim
# Success!

# With coreutils from nixos-unstable (tried both inside and outside the Nix sandbox)
/nix/store/ifzwv2xqwdnv1gz87rxkizi67py5p3vj-coreutils-9.4/bin/cp -pr --reflink=auto -- /nix/store/...-vim vim
# Error:
# /nix/store/ifzwv2xqwdnv1gz87rxkizi67py5p3vj-coreutils-9.4/bin/cp: setting permissions for 'vim': Invalid argument

Running coreutils from nixos-23.11 under strace gives this:
mkdirat(AT_FDCWD, "vim", 0555)          = 0
newfstatat(AT_FDCWD, "vim", {st_mode=S_IFDIR|0555, st_size=4096, ...}, AT_SYMLINK_NOFOLLOW) = 0
openat(AT_FDCWD, "vim", O_RDONLY|O_NOFOLLOW|O_CLOEXEC|O_PATH) = 3
newfstatat(3, "", {st_mode=S_IFDIR|0555, st_size=4096, ...}, AT_EMPTY_PATH) = 0
chmod("/proc/self/fd/3", 040755)        = 0
close(3)                                = 0

And coreutils from nixos-unstable under strace gives this:
mkdirat(AT_FDCWD, "vim", 0555)          = 0
newfstatat(AT_FDCWD, "vim", {st_mode=S_IFDIR|0555, st_size=4096, ...}, AT_SYMLINK_NOFOLLOW) = 0
fchmodat2(AT_FDCWD, "vim", 040755, AT_SYMLINK_NOFOLLOW) = -1 EINVAL (Invalid argument)

According to the fchmodat manpage, EINVAL is returned when "Invalid flag specified in flags", which here is AT_SYMLINK_NOFOLLOW.
Above we can see:

AT_SYMLINK_NOFOLLOW: If pathname is a symbolic link, do not dereference it: instead operate on the link itself.  This flag is not currently implemented.

Notify maintainers
Maintainers from glibc:
@edolstra @Ma27 @connorbaker
@vcunat might also be interested.
Metadata
Please run nix-shell -p nix-info --run "nix-info -m" and paste the result.
[user@system:~]$ nix-shell -p nix-info --run "nix-info -m"
 - system: `"x86_64-linux"`
 - host os: `Linux 6.5.11-lqx2, NixOS, 23.11 (Tapir), 23.11.20240328.219951b`
 - multi-user?: `yes`
 - sandbox: `yes`
 - version: `nix-env (Nix) 2.18.1`
 - channels(root): `""`
 - channels(minijackson): `""`
 - nixpkgs: `/nix/store/9fpv0kjq9a80isa1wkkvrdqsh9dpcn05-source`

Add a :+1: reaction to issues you find important.

glibc probably slightly changed the syscalls it uses and now exposes some artifact of nix sandbox where seccomp filters are applied.

I'm not sure the Nix sandbox has an effect in this case. If I run this outside of the sandbox:
nix shell 'nixpkgs/nixos-unstable#coreutils'

cp -pr -- /nix/store/<any-path> foo
# -> cp: setting permissions for 'foo': Invalid argument

which arguably may be an even bigger problem than not being able to build packages.
Another example:
nix shell 'nixpkgs/nixos-unstable#coreutils'

mkdir foo
chmod 400 foo
cp -pr foo bar
# -> cp: setting permissions for 'bar': Invalid argument

This is closely related, I believe: https://github.com/NixOS/nixpkgs/issues/300635

This seems to be a problem with linux_lxq from 23.11: when I fire up a VM with this kernel from 23.11 and a coreutils from unstable, I get a lot of Invalid argument errors just as you reported.
However, when I do the same with linux_lxq from 24.05, I don't.
To double-check I ran strace -e fchmodat2 cp -pr /nix/store/something-that-is-a-directory/ . and I got the following output:
fchmodat2(AT_FDCWD, "007fsdh8i9nks8fpjysa638mf7sb7a4l-libffi-3.4.6", 040700, AT_SYMLINK_NOFOLLOW) = 0
fchmodat2(AT_FDCWD, "007fsdh8i9nks8fpjysa638mf7sb7a4l-libffi-3.4.6/lib", 040700, AT_SYMLINK_NOFOLLOW) = 0

cc @999eagle @JerrySM64 who have touched the zen kernels most recently. Is there any chance to backport the lqx variant to 23.11 (or identify & backport the patch that solved our issue)?

I don't really know how we'd identify the patch that solves this except through bisecting (which would take a lot of compile time for these kernel updates I think), so I've opened #302588 to backport all current lqx/zen updates to 23.11.

I don't really know how we'd identify the patch that solves this except through bisecting (which would take a lot of compile time for these kernel updates I think), so I've opened #302588 to backport all current lqx/zen updates to 23.11.

Thanks for that! I had a few minutes to update the kernels. They will also be backported (A thing I actually thought about a couple months ago).

The lqx backport was merged and will appear on the stable channel in probably a few days. Closing.

Thanks a lot! I'll test it then.


Fix nightly build errors

Figure out why this is failing and fix it: https://github.com/Bathtor/rust-executors/runs/3900967772?check_suite_focus=true

Seems to have been a broken cargo cache.
Fixed it by changing the cache key (which is apparently the only way to "reset" cache on Github Actions atm).


SQL Editor tear off and tear off add to previous tearoff

System information:

Operating system (distribution) and version Linux Mint 12
DBeaver version 20
Additional extensions

Connection specification:

Database name and version
Driver name
Do you use tunnels or proxies (SSH, SOCKS, etc)? No

Describe the problem you're observing:
When you tear off an SQL editor from the main window, the cursor becomes the circle with slash, indicating the operation cannot happen. But it does.
After having one editor torn off, tearing off another and adding to the previous (put 2 tabs in that window), same cursor behavior.
Steps to reproduce, if exist:
Include any warning/errors/backtraces from the logs

@higgsja could you provide a video with the issue?


fAnaHis1 test EAR

Assembly review request

ToLID: Anaecypris hispanica
Species: fAnaHis1
Project: ERGA-Pilot
Affiliation: ERGA/IZW

ok

no

No

Hi @SaimMomin12, do you agree to review this assembly?
Please reply to this message only with Yes or No by 28-Aug-2024 at 15:39 CET


Campaign: Publishing Registered Reports

This campaign will ask researchers to pledge to submit a single Registered Report to a journal if and when a pre-specified threshold of community support has been met (e.g. X researchers have signed a pledge). Some of the parameters we will need to work out:

Should we target a particular field (e.g., Psychology) or make the campaign open to researchers in all fields?

What should be the threshold for pledge activation (e.g., pledges activate when 100 researchers have signed the pledge)? (this should be considered in conjunction with [1] above)

Should there be a time limit on the pledge (e.g., people have to submit the RR within 2 years of their pledge activating)?

Should the campaign expire within some period if it doesn't reach threshold (e.g. if we don't reach threshold within a year, take the campaign down)?

Any other considerations?

Note: If you're interested in joining this campaign and would like to be notified when it goes live, please add your name here

Should we target a particular field (e.g., Psychology) or make the campaign open to researchers in all fields?

My initial intuition on this is that it should be cross-field because the number of pledges overall will higher and seeing higher numbers might be more motivating to those involved and to people who are thinking of pledging. Plus, if it were me, I don't think I'd care too much if it was someone from my field or not who made the pledge

2. What should be the threshold for pledge activation (e.g., pledges activate when 100 researchers have signed the pledge)? (this should be considered in conjunction with [1] above)

If one field, I'd lean toward the 100 pledge threshold but it were across many fields, I'd lean more to 200 or so.

3. Should there be a time limit on the pledge (e.g., people have to submit the RR within 2 years of their pledge activating)?

I think a time limit would be good because it's a clear goal and might prompt a bit of urgency. 2 years (maybe 3) seems reasonable too

4. Should the campaign expire within some period if it doesn't reach threshold (e.g. if we don't reach threshold within a year, take the campaign down)?

Could take it down, but another option is to have the option to extend it if current pledgers want to.

Thanks for your thoughts @samgrobson!

My initial intuition on this is that it should be cross-field because the number of pledges overall will higher and seeing higher numbers might be more motivating to those involved and to people who are thinking of pledging. Plus, if it were me, I don't think I'd care too much if it was someone from my field or not who made the pledge

Good to know! The existing OA campaigns were designed to be discipline specific, because that's the level the collective action problem is operating at -- it wouldn't do you much good if you're the only psychology researcher in the cohort when pledges go live, because you'd be supporting OA psych journals on your own. Seems to me that the same general principle applies here, but perhaps it's less of an issue because publishing a Registered Report is less likely to make or break your career (compared to boycotting all non-OA journals). Personally I'm happy to go with either direction, as these new campaigns will very much be trial and error to see what works/doesn't, but would be good to hear what others think too.

Could take it down, but another option is to have the option to extend it if current pledgers want to.

I like that idea -- get the pledgers to decide, or ask them to renew their pledge if the campaign expires. I only just started thinking about expiry dates, bc I noticed they use them elsewhere (Kickstarter and Collaction), and suspect it might help ppl sign by giving them peace of mind that their pledge won't suddenly activate many years down the track when they're in a very different situation.

Someone raised a good point in this thread that we need to make it easy for people to see what journals they'll be able to publish in when taking this pledge. The best resource I've found so far is from the Center for Open Science (you need to click the second tab called 'Participating Journals'), but it's not currently broken down by research field so a little difficult to navigate

Should we target a particular field (e.g., Psychology) or make the campaign open to researchers in all fields?

It may be helpful to share the current journals that accept Registered Reports across fields. I think there are already helpful lists of these on some OSF pages. For example, there are about 10 neuroscience journals accepting RRs, but perhaps only 1 biology journal. That should help people decide their thresholds.

Should there be a time limit on the pledge (e.g., people have to submit the RR within 2 years of their pledge activating)?

I agree 3 years seems reasonable. Considering the review process can take much longer with RRs.

Should the campaign expire within some period if it doesn't reach threshold (e.g. if we don't reach threshold within a year, take the campaign down)?

It's good to have a fixed end time to encourage timeliness and mark a point at which time to evaluate success of the campaign. Maybe after 1 year, assess number of pledges, after 3 years, assess pledge activations, after 5 years, assess successful action and trends in RR publishing?

Any other considerations?

What are the perceived risks of an RR? I personally think it's pretty risk free, However certain studies may be geared towards an RR, such as a clinical trial or a paper where you fear null results not being published. The time cost seems to be the biggest down side, which is offset for larger studies, but perhaps not for smaller experimental designs.
Where to spread the word about the campaign? I wonder if we can start getting a list of upcoming conferences and events from the community who would be happy to share or ask if we can share the campaign?

Maybe after 1 year, assess number of pledges, after 3 years, assess pledge activations, after 5 years, assess successful action and trends in RR publishing?

Just to clarify, there will only be one activation timepoint for this campaign (whenever we get X pledges), unlike the OA campaigns which allow user-defined thresholds (#5 #6 #7). So we will know how many pledges have activated (X) if we get there at all. But yes, it would be good to track compliance so we can assess our impact in years to come.

What are the perceived risks of an RR? I personally think it's pretty risk free, However certain studies may be geared towards an RR, such as a clinical trial or a paper where you fear null results not being published. The time cost seems to be the biggest down side, which is offset for larger studies, but perhaps not for smaller experimental designs.

Time is a factor, for sure (but this is offset somewhat by the guarantee you'll get published). Another perceived risk could be that not all journals offer RR, and so you're limiting yourself to those that do. That may be fine in fields where prestigious journals offer RR, but in others, you could be shooting yourself in the foot. But I agree with you that RRs are relatively risk-free (compared to publishing in OA journals), and so the main reasons for pledging to this campaign are probably more about joining a supportive community than solving a game-theoretic collective action problem (as per the OA campaigns). Brian Nosek suggested we need something to 'pull' people in, so I thought it could be useful if we offer some kind of support to pledgers, e.g. a webinar showing newbies how to do an RR (perhaps @evomellor could speak to whether this is possible/available?). We could also set up some kind of communication channel for the new community to share resources and discuss ideas/obstacles? This is a big part of why it would be great to have people who have already completed RRs join the campaign, so they can help others who are new to the process.

Where to spread the word about the campaign? I wonder if we can start getting a list of upcoming conferences and events from the community who would be happy to share or ask if we can share the campaign?

I've drafted a communication strategy here, which is geared mostly toward mailing lists, slack workspaces and twitter at this stage. But conferences would also be great if people are presenting their work anyway and feel comfortable adding a slide at the end of their talk. I'd be happy to make a new slide specifically for this campaign if so.

I'm also in favour of it being across disciplines.

Someone raised a good point in this thread that we need to make it easy for people to see what journals they'll be able to publish in when taking this pledge. The best resource I've found so far is from the Center for Open Science (you need to click the second tab called 'Participating Journals'), but it's not currently broken down by research field so a little difficult to navigate. FOK has partnered with COS, so they might be willing to amend this list to make it more user-friendly, e.g. broken down by research field.

We're hoping to make the database of RRs that I'm creating available sometime early next year, and we've been coding journal subject areas in it, so should be able to filter by this.

We're hoping to make the database of RRs that I'm creating available sometime early next year, and we've been coding journal subject areas in it, so should be able to filter by this

Brilliant, and great to know! Just to clarify, is this a database of journals that offer RR format, or articles that have been published under the RR format?
Also curious what subject taxonomy you're using. For FOK I'm thinking we will use the Fields of Research taxonomy, because this is what the Dimensions database uses to classify articles and so would allow us to classify articles/people automatically using the Dimensions database. If you happen to be using the same taxonomy it would be super handy for filtering according to each user, but not the end of the world if not (and sounds like you've already started coding)

Brilliant, and great to know! Just to clarify, is this a database of journals that offer RR format, or articles that have been published under the RR format?

Articles published as RRs (and matched sample of regular research articles), not a list of journals.

Also curious what subject taxonomy you're using. For FOK I'm thinking we will use the Fields of Research taxonomy, because this is what the Dimensions database uses to classify articles and so would allow us to classify articles/people automatically using the Dimensions database

We don't stick 100% to that specific taxonomy but the vast majority would conform to it. Some journals kind of fit under multiple areas, and we have a journal or two that at the moment are just coded as 'Interdisciplinary' as their scope is very broad and difficult to pin down to even any one or two broad areas.
It probably is a lot more efficient to just see if journal subject areas can be added to the existing COS list of journals or similar, as our detailed database of the articles will take a while to be finished, and is limited anyway to the journals that have already published stage 2 RRs, rather than all of the journals that offer RRs.


gui-apps/hyprshot: add 1.3.0

Since 1.3.0 hyprshot can utilize hyprpicker utility, which present only in guru repository. It leads to CI fails
So what you can suggest to do in such case?

Hmm, I'm happy to let you move hyprshot to guru.


/notes/{id} returns {"items": ....}

Should this API call return just the items themselves without the {"items": ....}
Example:
{"fileName": "111.txt", "id": 11, "text": "asdfasdf"}

@gkowalski It looks like the schema is correctly defined. Did openapi-generator incorrectly generated of this path? I think that we have been using the response schema below from the start.
get:
  tags:
    - Note
  summary: Get a clinical note by ID
  description: Returns the clinical note for a given ID
  operationId: "notes.read"
  parameters:
    - name: id
      in: path
      description: The ID of the clinical note to fetch
      required: true
      schema:
        type: string
  responses:
    '200':
      description: Success
      content:
        application/json:
          schema:
            $ref: ../../commons/components/schemas/Note.yaml
    '403':
      description: Forbidden
    '404':
      description: Note not found


[web] Render markdown (or at least a meaningful subset of it) in comments

In comments, the most major Markdown-ish features should be rendered in the web interface: bold, italic, underline, and monospace highlight with backticks. (Links and images are not really needed.) There are definitely some NodeJS libs that can render Markdown to inline HTML.

This is a pretty popular lib for it, we should deffo try it: https://www.npmjs.com/package/markdown-it


Remove required from yamls and associated functions

Overview

Remove the required field from yaml specs and assume that all columns specified in the spec are required. Adjusts checkSpec() and CombineSpec() appropriately.
Also changes experimental flags to stable for FlagOverTime and report table creation functions
Test Notes/Sample Code

Connected Issues

Closes #1936
Closes #1948

LGTM, depending on which PR we merge first, the additional removal of required: true for study yaml will be needed as well

Thanks, @zdz2101 - i'm going to merge this in first and then remove the required: true fields for #1957


alternate for @cl.langchain_factory(use_async=True)

hi, what is the alternate/substitute for @cl.langchain_factory(use_async=False) in version 0.6.3?

Hello, here is the migration guide https://docs.chainlit.io/guides/migration/0.6.0

Then you can fallback to the sync implementation like so:
cl.user_session.set("llm_chain", qa_generator.qa_chain)
cb = cl.LangchainCallbackHandler(
    stream_final_answer=True, answer_prefix_tokens=["FINAL", "ANSWER"]
)

# Retrieve the chain from the user session
llm_chain = cl.user_session.get("llm_chain")
acall = cl.make_async(llm_chain)
res = await acall(
    input_str,callbacks = [cb] )

hi thanks,  but i still cannot get the streaming of final answer
there is no error while running the code, but streaming is not hapenning

Final answer streaming is conditioned by the answer_prefix_tokens. Which means your chain has to always include this prefix before the final answer. If it does not and your chain has a single step you can manually force  streaming.

hi, i am still unable to get the streaming running.
here is my code.please suggest if i need to do something more
model = AutoGPTQForCausalLM.from_quantized(model_path,
model_basename=model_basename,
use_safetensors=True,
trust_remote_code=True,
device_map='auto',
use_triton=False,
load_in_8bit=True,
quantize_config=None,
streaming=True)
streamer = TextStreamer(tokenizer)
pipe = pipeline(
"text-generation",
model=model,
tokenizer=tokenizer,
max_new_tokens=512,
temperature=0.0,
top_p=0.95,
repetition_penalty=1.15,
streamer=streamer
)
@cl.on_message
async def run(input_str):
cb = cl.LangchainCallbackHandler(
stream_final_answer=True, answer_prefix_tokens=["Helpful Answer:","result"]
)
cb.answer_reached = True
print('user question',input_str)
# Retrieve the chain from the user session
llm_chain = cl.user_session.get("llm_chain")
res = await cl.make_async(llm_chain)(
    input_str,callbacks = [cb] #callbacks=[cl.ChainlitCallbackHandler()]
)

for i in res["source_documents"]:
    print(f"***Page***: {i.metadata['page']} \n***Source***: {i.metadata['source']} \n***Context***:{i.page_content}")
await cl.Message(content=res["result"]).send()

What is the behavior you observe? Are the intermediate steps streamed and only the final answer is not streamed? Or is streaming not working at all?

both intermediate and final answers are not streamed

I see, as I said in my previous message could you provide the full snippet of code? I would like to reproduce on my machine to help you resolve this issue.

unfortunately i cannot share the complete code as it contains some sensitive information :(

I understand, a minimum reproducible case then? Like the imports, the llm instantiation with a random llm chain?

Chainlit does not force a specific langchain version. You can freely upgrade your langchain installation independently of chainlit's

I understand, a minimum reproducible case then? Like the imports, the llm instantiation with a random llm chain?

from gc import callbacks
import os
import langchain
import langchain.text_splitter
import torch
from transformers import LlamaTokenizer, LlamaForCausalLM, pipeline, TextStreamer, AutoTokenizer,AutoModelForCausalLM
from langchain.llms import HuggingFacePipeline, llamacpp
from langchain.vectorstores import Chroma, FAISS
from langchain.text_splitter import (
RecursiveCharacterTextSplitter,
CharacterTextSplitter,
TokenTextSplitter,
)
from langchain import PromptTemplate, LLMChain
from langchain.schema import Document
from langchain.chains import RetrievalQA
from langchain.document_loaders import DirectoryLoader, PyPDFLoader
from langchain.embeddings import HuggingFaceInstructEmbeddings
import textwrap
import chainlit as cl
from chainlit.sync import asyncify
from typing import List
template = """
You are a helpful AI assistant. Provide the answer for the following question:
Question: {question}
Answer:
"""
model_basename = "longchat-7b-16k-GPTQ-4bit-128g.no-act.order"
model = AutoGPTQForCausalLM.from_quantized(model_path,
model_basename=model_basename,
use_safetensors=True,
trust_remote_code=True,
device_map='auto',
use_triton=False,
load_in_8bit=True,
quantize_config=None,
streaming=True)
tokenizer = AutoTokenizer.from_pretrained(model_path)
streamer = TextStreamer(tokenizer)
pipe = pipeline(
"text-generation", model=model, tokenizer=tokenizer, max_new_tokens=50, batch_size=8, streamer=streamer
)
llm = HuggingFacePipeline(pipeline=pipe)
@cl.on_chat_start
async def main():
prompt = PromptTemplate(template=template, input_variables=["question"])
llm_chain = LLMChain(prompt=prompt, llm=llm)
cl.user_session.set("llm_chain", llm_chain)

return llm_chain

<EMAIL_ADDRESS>@cl.on_message
async def run(input_str):
# res = agent(input_str)
cb = cl.LangchainCallbackHandler(
    stream_final_answer=True, stream_prefix=True, answer_prefix_tokens=["Answer"]
)
cb.answer_reached = True
print('user question :',input_str)

# Retrieve the chain from the user session
llm_chain = cl.user_session.get("llm_chain")
res = await cl.make_async(llm_chain)(
    input_str,callbacks = [cb] #callbacks=[cl.ChainlitCallbackHandler()]
)
print(res)
await cl.Message(content=res["text"]).send()

The answer is streamed to stdout, but not onto chainlit UI

the model is taken from https://huggingface.co/TheBloke/LongChat-7B-GPTQ

I am able to reproduce with the following code:
from langchain.llms import HuggingFacePipeline
from transformers import AutoTokenizer, TextStreamer
from langchain import PromptTemplate, LLMChain
import transformers
import torch

import chainlit as cl

template = """
You are a helpful AI assistant. Provide the answer for the following question:

Question: {question}
Answer:
"""

@cl.cache
def load_llama():
    model = "meta-llama/Llama-2-7b-chat-hf"
    tokenizer = AutoTokenizer.from_pretrained(model)
    streamer = TextStreamer(tokenizer, skip_prompt=True)
    pipeline = transformers.pipeline(
        "text-generation",
        model=model,
        tokenizer=tokenizer,
        torch_dtype=torch.float16,
        trust_remote_code=True,
        device_map="auto",
        max_length=1000,
        do_sample=True,
        top_k=10,
        num_return_sequences=1,
        eos_token_id=tokenizer.eos_token_id,
        streamer=streamer,
        use_auth_token=True,
    )

    llm = HuggingFacePipeline(
        pipeline=pipeline,
        model_kwargs={"temperature": 0},
    )
    return llm

llm = load_llama()

@cl.on_chat_start
async def main():
    prompt = PromptTemplate(template=template, input_variables=["question"])
    llm_chain = LLMChain(prompt=prompt, llm=llm)
    cl.user_session.set("llm_chain", llm_chain)

    return llm_chain

@cl.on_message
async def run(input_str):
    cb = cl.AsyncLangchainCallbackHandler(
        stream_final_answer=True, answer_prefix_tokens=["Answer"]
    )
    cb.answer_reached = True

    # Retrieve the chain from the user session
    llm_chain = cl.user_session.get("llm_chain")  # type: LLMChain
    res = await llm_chain.acall(input_str, callbacks=[cb])

The problem is that the langchain callback on_llm_new_token method is never called, only on_llm_start and on_llm_end. However the response is correctly streamed to the stdout. It seems to be a langchain issue.


Make it compatible with kaminari 1.0

In kaminari 1.0 they removed method deprecated num_pages in favor of total_pages. Issue: #148

Sorry I've only now just gotten this - Since this adds a min requirement on kaminari, I'll bump our version as well and aim to get this out shortly.

Any chance we can get this merged in? It seems to be an easy fix.