Repository: ynqa/pandavro (language: python)

Issue:
Does the fastavro dependency version need to be pinned?
`setup.py` has:
```python
    install_requires=[
        # fixed versions.
        'fastavro==1.5.1',
        'pandas>=1.1',
        # https://pandas.pydata.org/pandas-docs/version/1.1/getting_started/install.html#dependencies
        'numpy>=1.15.4',
    ],
```

This causes a dependency resolution failure for me because I'm using another package that requires `fastavro>=1.5.4`.

Would it be possible to relax that requirement to be `'fastavro>=1.5.1`


Discussion / hints:
I submitted a fix in #42 
I would like to +1 this. 

Relaxing this pinned requirement would also be helpful in making `pandavro` compatible with Python 3.11 and beyond, because `fastavro==1.5.1` only supports up to Python 3.10 ([see docs](https://pypi.org/project/fastavro/1.5.1/))

Fix patch:
diff --git a/.github/workflows/python-package.yml b/.github/workflows/python-package.yml
index 188eb72..9295c64 100644
--- a/.github/workflows/python-package.yml
+++ b/.github/workflows/python-package.yml
@@ -16,18 +16,17 @@ jobs:
     strategy:
       fail-fast: false
       matrix:
-        python-version: ["3.8", "3.9", "3.10"]
+        python-version: ["3.7", "3.8", "3.9", "3.10", "3.11"]
 
     steps:
     - uses: actions/checkout@v3
     - name: Set up Python ${{ matrix.python-version }}
-      uses: actions/setup-python@v3
+      uses: actions/setup-python@v4
       with:
         python-version: ${{ matrix.python-version }}
     - name: Install dependencies
       run: |
         python -m pip install --upgrade pip
-        python -m pip install -e .[tests]
-    - name: Test with pytest
-      run: |
-        pytest -v tests
+        python -m pip install tox tox-gh-actions
+    - name: Test with tox
+      run: tox p
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
new file mode 100644
index 0000000..ca45f11
--- /dev/null
+++ b/CONTRIBUTING.md
@@ -0,0 +1,7 @@
+# Contributing
+
+We provide a Makefile to ease with setting up a development environment.
+
+- `make init` will setup a simple python virtual env and install the package
+- `make test` will run the test suite with the current environment
+- `make test-all` will run all the tests accross different environments with `tox`
diff --git a/Makefile b/Makefile
new file mode 100644
index 0000000..15561e0
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,33 @@
+SHELL = /bin/bash
+
+.DEFAULT_GOAL := all
+
+## help: Display list of commands
+.PHONY: help
+help: Makefile
+	@sed -n 's|^##||p' $< | column -t -s ':' | sed -e 's|^| |'
+
+## all: Run all targets
+.PHONY: all
+all: init style test
+
+## init: Bootstrap dev env.
+.PHONY: init
+init:
+	python3 -m venv ./venv
+	./venv/bin/pip install -e .[tests]
+
+## test: Shortcut to launch all the test on all environments
+.PHONY: test
+test:
+	./venv/bin/pytest
+
+## test-all: Shortcut to launch all the test on all environments
+.PHONY: test-all
+test-all:
+	./venv/bin/tox p
+
+## clean: Remove temporary files
+.PHONY: clean
+clean:
+	-rm -rf .mypy_cache ./**/.pytest_cache venv
diff --git a/setup.py b/setup.py
index 0fcd6b9..ab410f8 100644
--- a/setup.py
+++ b/setup.py
@@ -18,14 +18,14 @@
     packages=find_packages(exclude=['example']),
     install_requires=[
         # fixed versions.
-        'fastavro~=1.5.1',
+        'fastavro>=1.5.1,<2.0.0',
         'pandas>=1.1',
         # https://pandas.pydata.org/pandas-docs/version/1.1/getting_started/install.html#dependencies
         'numpy>=1.15.4',
     ],
     extras_require={
-        'tests': ['pytest==7.1.2'],
+        'tests': ['pytest==7.3.2', 'tox==4.6.0'],
     },
     # https://pandas.pydata.org/pandas-docs/version/1.1/getting_started/install.html#python-version-support
-    python_requires='>=3.6.1',
+    python_requires='>=3.7.0',
 )
diff --git a/tox.ini b/tox.ini
new file mode 100644
index 0000000..fb68ae3
--- /dev/null
+++ b/tox.ini
@@ -0,0 +1,24 @@
+[tox]
+envlist =
+    # pandas 2.0 doesn't support python 3.7
+    py37-pandas{1}-fastavro{15,16,17,1},
+    py{38,39,310,311}-pandas{1,2}-fastavro{15,16,17,1},
+
+[gh-actions]
+python =
+    3.7: py37
+    3.8: py38
+    3.9: py39
+    3.10: py310
+    3.11: py311
+
+[testenv]
+deps =
+    pytest
+    pandas1: pandas >=1.1, <2
+    pandas2: pandas >=2.0.0, <3.0.0
+    fastavro15: fastavro >=1.5.1, <1.6.0
+    fastavro16: fastavro >=1.6.0, <1.7.0
+    fastavro17: fastavro >=1.7.0, <1.8.0
+    fastavro1: fastavro >=1.7.0, <2.0.0
+commands = pytest


Test patch:
diff --git a/tests/pandavro_test.py b/tests/pandavro_test.py
index 161e3dd..01db48e 100644
--- a/tests/pandavro_test.py
+++ b/tests/pandavro_test.py
@@ -7,7 +7,13 @@
 import numpy as np
 import pandas as pd
 import pytest
-from pandas.util.testing import assert_frame_equal
+
+try:
+    # pandas >2.0
+    from pandas.testing import assert_frame_equal
+except ImportError:
+    # previous version of pandas
+    from pandas.util.testing import assert_frame_equal
 
 import pandavro as pdx