8000 reorder query region hosts & fix ok call & fix ci by lihsai0 · Pull Request #437 · qiniu/python-sdk · GitHub
[go: up one dir, main page]

Skip to content

reorder query region hosts & fix ok call & fix ci #437

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jul 28, 2023
Merged
Changes from 1 commit
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
Prev Previous commit
change ci to miniconda for old python compatible
  • Loading branch information
lihsai0 committed Jul 27, 2023
commit 8768bc3d8f26a3e3ee441ace384898761a114dea
38 changes: 22 additions & 16 deletions .github/workflows/ci-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,36 +6,42 @@ jobs:
fail-fast: false
max-parallel: 1
matrix:
python_version: ['2.7', '3.4.10', '3.5', '3.6', '3.7', '3.8', '3.9']
python_version: ['2.7', '3.4', '3.5', '3.6', '3.7', '3.8', '3.9']
runs-on: ubuntu-20.04
steps:
- name: Checkout repo
uses: actions/checkout@v2
with:
ref: ${{ github.ref }}
- name: Setup python
if: ${{ matrix.python_version != '3.4.10' }}
uses: actions/setup-python@v2
- name: Setup miniconda
uses: conda-incubator/setup-miniconda@v2
with:
auto-update-conda: true
channels: conda-forge
python-version: ${{ matrix.python_version }}
architecture: x64
- name: Setup python manually
if: ${{ matrix.python_version == '3.4.10' }}
activate-environment: qiniu-sdk
auto-activate-base: false
- name: Setup pip
shell: bash -l {0}
env:
PYTHON_SOURCE_URL: https://www.python.org/ftp/python/${{ matrix.python_version }}/Python-${{ matrix.python_version }}.tgz
PYTHON_VERSION: ${{ matrix.python_version }}
PIP_BOOTSTRAP_SCRIPT_PREFIX: https://bootstrap.pypa.io/pip
run: |
cd /tmp
curl -s -L "$PYTHON_SOURCE_URL" | tar -zxf - -C ./
cd Python-${{ matrix.python_version }}
./configure --enable-optimizations
make
sudo make install
echo 'export PATH="/opt/python/bin:$PATH"' >> $HOME/.bashrc
MAJOR=$(echo "$PYTHON_VERSION" | cut -d'.' -f1)
MINOR=$(echo "$PYTHON_VERSION" | cut -d'.' -f2)
# reinstall pip by some python(<3.7) not compatible
if ! [[ $MAJOR -ge 3 && $MINOR -ge 7 ]]; then
cd /tmp
wget -qLO get-pip.py "$PIP_BOOTSTRAP_SCRIPT_PREFIX/$MAJOR.$MINOR/get-pip.py"
python get-pip.py --user
fi
- name: Install dependencies
shell: bash -l {0}
run: |
python -m pip install --upgrade pip
pip install "coverage<7.2" flake8 pytest pytest-cov freezegun requests scrutinizer-ocular codecov
python -m pip install --ignore-installed "coverage<7.2" flake8 pytest pytest-cov freezegun requests scrutinizer-ocular codecov
- name: Run cases
shell: bash -l {0}
env:
QINIU_ACCESS_KEY: ${{ secrets.QINIU_ACCESS_KEY }}
QINIU_SECRET_KEY: ${{ secrets.QINIU_SECRET_KEY }}
Expand Down
0