Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
.vscode
__pycache__/
amplitude_data_wrapper.egg-info/
.venv*
Expand Down
1 change: 1 addition & 0 deletions .python-version
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
3.10
44 changes: 0 additions & 44 deletions Makefile

This file was deleted.

2 changes: 1 addition & 1 deletion example.py
Original file line number Diff line number Diff line change
Expand Up @@ -127,4 +127,4 @@
limit=1000,
)
# %%
data.json() # print data as json
data.json() # print data as json
49 changes: 49 additions & 0 deletions justfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
# load env variables
set dotenv-load

# env variables
TESTPYPI_TOKEN := env('TESTPYPI_TOKEN')
PYPI_TOKEN := env('PYPI_TOKEN')
PYPI_PROJECT := "amplitude-data-wrapper"
IMPORT_PROJECT := "amplitude_data_wrapper"

# list recipes
default:
just --list

# install and run
run:
uv run

# install dependencies
install:
uv sync --frozen

# upgrade dependencies
update:
uv lock --upgrade

# check code with ruff
check:
ruff check

# format with ruff
format:
ruff format

# build package
build: check format
rm -rf dist/; \
uv build

# test package can be installed and imported
package-test:
uv run --with {{PYPI_PROJECT}} --no-project -- python -c "import {{IMPORT_PROJECT}}"

# publish on python package index
pypi_publish:
uv publish --token {{PYPI_TOKEN}}

# publish on test python package index
testpypi_publish:
uv publish --index testpypi --token {{TESTPYPI_TOKEN}}
45 changes: 14 additions & 31 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "amplitude-data-wrapper"
version = "0.5.2"
version = "0.5.3"
description = "python wrapper for using the amplitude analytics and taxonomy APIs"
authors = [
{name = "Tobias McVey", email = "tobias.mcvey@nav.no"},
Expand All @@ -9,42 +9,25 @@ readme = "README.md"
requires-python = ">=3.10"
keywords = ["amplitude"]
license = {file = "LICENSE"}

dependencies = [
"requests",
"tqdm"
"requests>=2.32.3",
"tqdm>=4.67.1",
]

[project.optional-dependencies]
[dependency-groups]
dev = [
"ipykernel",
"python-dotenv",
"black",
"twine",
"keyring",
"pip-tools",
"mypy",
"isort"
"ipykernel>=6.29.5",
"keyring>=25.6.0",
"python-dotenv>=1.1.0",
"ruff>=0.11.3",
"twine>=6.1.0",
]

[project.urls]
"Homepage" = "https://github.com/navikt/amplitude-data-wrapper"

[tool.setuptools]
package-dir = {"" = "src"}

[tool.setuptools.packages.find]
where = ["src"]
exclude = ["tests", "testing"]

[build-system]
requires = ["setuptools", "setuptools-scm"]
build-backend = "setuptools.build_meta"

[tool.mypy]
ignore_missing_imports = true

[tool.isort]
profile = "black"
src_paths=["src/taskanalytics_data_wrapper"]
sections=["FUTURE","STDLIB","THIRDPARTY","FIRSTPARTY","LOCALFOLDER"]
[[tool.uv.index]]
name = "testpypi"
url = "https://test.pypi.org/simple/"
publish-url = "https://test.pypi.org/legacy/"
explicit = true
190 changes: 0 additions & 190 deletions requirements/dev.txt

This file was deleted.

18 changes: 0 additions & 18 deletions requirements/main.txt

This file was deleted.

Loading