Lacking CONTRIBUTING.MD #32

Closed
opened 2026-02-16 05:16:10 -05:00 by yindo · 5 comments
Owner

Originally created by @Sachin-Bhat on GitHub (Jul 19, 2024).

Hello everyone,

I believe that the project currently lacks instructions on contributing to the project. Would greatly appreciate if there are instructions on setting up poetry and the test environment. This can also help new contributors write and see if their tests work.

Cheers,
Sachin

Originally created by @Sachin-Bhat on GitHub (Jul 19, 2024). Hello everyone, I believe that the project currently lacks instructions on contributing to the project. Would greatly appreciate if there are instructions on setting up poetry and the test environment. This can also help new contributors write and see if their tests work. Cheers, Sachin
yindo closed this issue 2026-02-16 05:16:10 -05:00
Author
Owner

@amotl commented on GitHub (Jan 29, 2025):

Hi @Sachin-Bhat,

while working on GH-157, the outcome and response to your request is attached below.

With kind regards,
Andreas.

Development Sandbox

Acquire sources and create virtualenv.

git clone https://github.com/langchain-ai/langchain-postgres
cd langchain-postgres
uv venv --python=3.13
source .venv/bin/activate

Install package, editable.

poetry install --with dev,test,lint
pip install greenlet

Start PostgreSQL/PGVector.

docker run --rm -it --name pgvector-container \
  -e POSTGRES_USER=langchain \
  -e POSTGRES_PASSWORD=langchain \
  -e POSTGRES_DB=langchain \
  -p 6024:5432 pgvector/pgvector:pg16 \
  postgres -c log_statement=all

Invoke test cases.

pytest -vvv
@amotl commented on GitHub (Jan 29, 2025): Hi @Sachin-Bhat, while working on GH-157, the outcome and response to your request is attached below. With kind regards, Andreas. ### Development Sandbox Acquire sources and create virtualenv. ```shell git clone https://github.com/langchain-ai/langchain-postgres cd langchain-postgres uv venv --python=3.13 source .venv/bin/activate ``` Install package, editable. ```shell poetry install --with dev,test,lint pip install greenlet ``` Start PostgreSQL/PGVector. ```shell docker run --rm -it --name pgvector-container \ -e POSTGRES_USER=langchain \ -e POSTGRES_PASSWORD=langchain \ -e POSTGRES_DB=langchain \ -p 6024:5432 pgvector/pgvector:pg16 \ postgres -c log_statement=all ``` Invoke test cases. ```shell pytest -vvv ```
Author
Owner

@amotl commented on GitHub (Jan 29, 2025):

Hi again. GH-158 includes a relevant patch that adds this information to the repository.

@amotl commented on GitHub (Jan 29, 2025): Hi again. GH-158 includes a relevant patch that adds this information to the repository.
Author
Owner

@eyurtsev commented on GitHub (Feb 4, 2025):

Merged

@eyurtsev commented on GitHub (Feb 4, 2025): Merged
Author
Owner

@alberto-agudo commented on GitHub (Jul 8, 2025):

Hi everyone,

I have recently tried to follow the indications of the DEVELOPMENT.md file in a directory from scratch and it seems they return some errors:

git clone https://github.com/langchain-ai/langchain-postgres
cd langchain-postgres
uv venv --python=3.13
source .venv/bin/activate

Cloning into 'langchain-postgres'...
remote: Enumerating objects: 846, done.
remote: Counting objects: 100% (507/507), done.
remote: Compressing objects: 100% (269/269), done.
remote: Total 846 (delta 415), reused 251 (delta 238), pack-reused 339 (from 1)
Receiving objects: 100% (846/846), 951.16 KiB | 1.81 MiB/s, done.
Resolving deltas: 100% (509/509), done.
Updating files: 100% (61/61), done.
Using CPython 3.13.5
Creating virtual environment at: .venv
Activate with: source .venv/bin/activate

poetry install --with dev,test,lint

This is the first crash

The Poetry configuration is invalid:

  • The fields ['authors', 'description', 'name', 'version'] are required in package mode.

which I've solved through

uv sync --group test

Resolved 55 packages in 1.13s
Prepared 1 package in 1.39s
Installed 47 packages in 58.77s

On the other hand, it seems like the Docker container snippet doesn't work properly with pytest. After running the container, pytest tests fail because they can't connect to the DB instance. I think this is related with the port exposed under this config (6024) for the host, because using docker-compose up pgvector, as specified here https://github.com/langchain-ai/langchain-postgres/blob/18b1bcdb75ed152da717e3d624e1ed822d17d60f/tests/utils.py#L9-L21 does work, and this config exposes port 5432 on the host.

Thanks.

Best,
Alberto.

@alberto-agudo commented on GitHub (Jul 8, 2025): Hi everyone, I have recently tried to follow the indications of the `DEVELOPMENT.md` file in a directory from scratch and it seems they return some errors: ```bash git clone https://github.com/langchain-ai/langchain-postgres cd langchain-postgres uv venv --python=3.13 source .venv/bin/activate ``` > Cloning into 'langchain-postgres'... remote: Enumerating objects: 846, done. remote: Counting objects: 100% (507/507), done. remote: Compressing objects: 100% (269/269), done. remote: Total 846 (delta 415), reused 251 (delta 238), pack-reused 339 (from 1) Receiving objects: 100% (846/846), 951.16 KiB | 1.81 MiB/s, done. Resolving deltas: 100% (509/509), done. Updating files: 100% (61/61), done. Using CPython 3.13.5 Creating virtual environment at: .venv Activate with: source .venv/bin/activate ```bash poetry install --with dev,test,lint ``` **This is the first crash** > The Poetry configuration is invalid: > - The fields ['authors', 'description', 'name', 'version'] are required in package mode. which I've solved through ```bash uv sync --group test ``` >Resolved 55 packages in 1.13s Prepared 1 package in 1.39s Installed 47 packages in 58.77s On the other hand, it seems like the Docker container snippet doesn't work properly with pytest. After running the container, pytest tests fail because they can't connect to the DB instance. I think this is related with the port exposed under this config (6024) for the host, because using `docker-compose up pgvector`, as specified here https://github.com/langchain-ai/langchain-postgres/blob/18b1bcdb75ed152da717e3d624e1ed822d17d60f/tests/utils.py#L9-L21 does work, and this config exposes port 5432 on the host. Thanks. Best, Alberto.
Author
Owner

@amotl commented on GitHub (Jul 8, 2025):

Hi Alberto. Thanks a stack for your report. Would you be able to turn that into a patch so we can update the documentation fluently when applicable?

@amotl commented on GitHub (Jul 8, 2025): Hi Alberto. Thanks a stack for your report. Would you be able to turn that into a patch so we can update the documentation fluently when applicable?
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: langchain-ai/langchain-postgres#32