Skip to content

Commit c397a29

Browse files
authored
Merge pull request #13 from rush-db/feat/update-authorizaion-header
Bump version & moved to uv
2 parents 8944288 + 3a444b3 commit c397a29

File tree

12 files changed

+1175
-751
lines changed

12 files changed

+1175
-751
lines changed

.env.example

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
# RushDB Configuration
2-
RUSHDB_TOKEN=your_api_token_here
2+
RUSHDB_API_KEY=your_api_token_here
33
RUSHDB_URL=http://localhost:3000

.github/workflows/ci.yml

Lines changed: 23 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,14 @@ name: Python SDK CI/CD
22

33
on:
44
push:
5-
branches: [ main ]
5+
branches: [main]
66
pull_request:
7-
branches: [ main ]
7+
branches: [main]
88
release:
99
types: [published]
1010

1111
jobs:
12-
lint:
12+
test:
1313
runs-on: ubuntu-latest
1414
strategy:
1515
matrix:
@@ -23,28 +23,30 @@ jobs:
2323
with:
2424
python-version: ${{ matrix.python-version }}
2525

26-
- name: Install Poetry
27-
uses: snok/install-poetry@v1
26+
- name: Install uv
27+
uses: astral-sh/setup-uv@v4
2828
with:
29-
version: 1.7.1
30-
virtualenvs-create: true
31-
virtualenvs-in-project: true
29+
version: "latest"
3230

3331
- name: Install dependencies
3432
run: |
35-
poetry install --no-interaction --no-root
33+
uv sync --dev
3634
3735
- name: Run linters
3836
run: |
39-
poetry run black . --check
40-
poetry run isort . --check
41-
poetry run ruff check .
42-
poetry run mypy src/rushdb
37+
uv run black . --check
38+
uv run isort . --check
39+
uv run ruff check .
40+
uv run mypy src/rushdb
41+
42+
- name: Run tests
43+
run: |
44+
uv run pytest
4345
4446
publish:
4547
if: startsWith(github.ref, 'refs/tags/v')
4648
runs-on: ubuntu-latest
47-
needs: lint
49+
needs: test
4850

4951
steps:
5052
- uses: actions/checkout@v4
@@ -54,20 +56,18 @@ jobs:
5456
with:
5557
python-version: "3.11"
5658

57-
- name: Install Poetry
58-
uses: snok/install-poetry@v1
59+
- name: Install uv
60+
uses: astral-sh/setup-uv@v4
5961
with:
60-
version: 1.7.1
61-
virtualenvs-create: true
62-
virtualenvs-in-project: true
62+
version: "latest"
6363

6464
- name: Install dependencies
6565
run: |
66-
poetry install --no-interaction --no-root
66+
uv sync --dev
6767
6868
- name: Build and publish
6969
env:
70-
POETRY_PYPI_TOKEN_PYPI: ${{ secrets.PYPI_TOKEN }}
70+
UV_PUBLISH_TOKEN: ${{ secrets.PYPI_TOKEN }}
7171
run: |
72-
poetry build
73-
poetry publish
72+
uv build
73+
uv publish

.gitignore

Lines changed: 55 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
# Dependencies
12
node_modules
23
dist
34
*.log
@@ -15,4 +16,57 @@ coverage
1516
.rollup.cache
1617
cjs
1718
esm
18-
packages/javascript-sdk/types
19+
packages/javascript-sdk/types
20+
21+
# Python
22+
__pycache__/
23+
*.py[cod]
24+
*$py.class
25+
*.so
26+
.Python
27+
build/
28+
develop-eggs/
29+
dist/
30+
downloads/
31+
eggs/
32+
.eggs/
33+
lib/
34+
lib64/
35+
parts/
36+
sdist/
37+
var/
38+
wheels/
39+
share/python-wheels/
40+
*.egg-info/
41+
.installed.cfg
42+
*.egg
43+
MANIFEST
44+
45+
# Virtual environments
46+
.env
47+
.venv
48+
env/
49+
venv/
50+
ENV/
51+
env.bak/
52+
venv.bak/
53+
54+
# Testing
55+
.coverage
56+
.pytest_cache/
57+
.tox/
58+
htmlcov/
59+
.nox/
60+
61+
# uv
62+
.uv/
63+
64+
# IDE
65+
.vscode/
66+
.idea/
67+
*.swp
68+
*.swo
69+
70+
# OS
71+
.DS_Store
72+
Thumbs.db

CONTRIBUTING.md

Lines changed: 41 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -7,23 +7,28 @@ Thank you for your interest in contributing to RushDB! To ensure a smooth contri
77
When reporting an issue, include the following information:
88

99
1. **Minimum Reproducible Data Set**
10-
- Provide a small JSON or CSV dataset if the issue is related to the core, dashboard, or SDK.
11-
- Ensure the dataset highlights the problem clearly.
10+
11+
- Provide a small JSON or CSV dataset if the issue is related to the core, dashboard, or SDK.
12+
- Ensure the dataset highlights the problem clearly.
1213

1314
2. **RushDB Version**
14-
- Specify the version of RushDB you are using:
15-
- **Cloud**: Mention if you are using the latest cloud version.
16-
- **Self-hosted**: Provide the tag from Docker Hub or the SDK version.
15+
16+
- Specify the version of RushDB you are using:
17+
- **Cloud**: Mention if you are using the latest cloud version.
18+
- **Self-hosted**: Provide the tag from Docker Hub or the SDK version.
1719

1820
3. **Steps to Reproduce**
19-
- Give a detailed explanation of how to reproduce the issue.
20-
- Include any configurations, commands, or environment settings.
21+
22+
- Give a detailed explanation of how to reproduce the issue.
23+
- Include any configurations, commands, or environment settings.
2124

2225
4. **Query Examples**
23-
- If applicable, include specific queries that trigger the error.
26+
27+
- If applicable, include specific queries that trigger the error.
2428

2529
5. **Minimum Repository (if SDK-related)**
26-
- For issues related to the SDK, a minimal GitHub repository demonstrating the bug may be required.
30+
31+
- For issues related to the SDK, a minimal GitHub repository demonstrating the bug may be required.
2732

2833
## Submitting Changes
2934

@@ -42,21 +47,41 @@ For urgent issues or further assistance, you can reach out directly:
4247

4348
We appreciate your contributions and look forward to your feedback!
4449

45-
---
46-
## Poetry commands
50+
---
4751

52+
## Development Commands
53+
54+
```bash
55+
# Install dependencies
56+
uv sync --dev
4857
```
49-
poetry run isort . --check
58+
59+
```bash
60+
# Check import sorting
61+
uv run isort . --check
5062
```
5163

64+
```bash
65+
# Type checking
66+
uv run mypy src/rushdb
5267
```
53-
poetry run mypy src/rushdb
68+
69+
```bash
70+
# Code formatting
71+
uv run black .
5472
```
5573

74+
```bash
75+
# Linting
76+
uv run ruff check .
5677
```
57-
poetry run black .
78+
79+
```bash
80+
# Run tests
81+
uv run pytest
5882
```
5983

84+
```bash
85+
# Run tests with coverage
86+
uv run pytest --cov
6087
```
61-
poetry run ruff check .
62-
```

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ pip install rushdb
2727
from rushdb import RushDB
2828

2929
# Initialize the client
30-
db = RushDB("YOUR_API_TOKEN")
30+
db = RushDB("RUSHDB_API_KEY")
3131

3232
# Create a record
3333
user = db.records.create(

0 commit comments

Comments
 (0)